Esempio n. 1
0
class Tbls4Flammablesworstcase(BaseRMPModel):
    flammableid = models.CopyFromIntegerField(primary_key=True)
    processchemicalid = models.CopyFromForeignKey(Tbls1Processchemicals,
                                                  on_delete=models.PROTECT)
    analyticalbasis = models.CopyFromCharField(max_length=255, blank=True)
    quantityreleased = models.CopyFromDecimalField(max_digits=6,
                                                   decimal_places=2,
                                                   blank=True)
    endpoint_distance = models.CopyFromDecimalField(max_digits=5,
                                                    decimal_places=1)
    residentialpopulation = models.CopyFromCharField(max_length=9, blank=True)
    pr_schools = models.CopyFromBooleanField()
    pr_residences = models.CopyFromBooleanField()
    pr_hospitals = models.CopyFromBooleanField()
    pr_prisons = models.CopyFromBooleanField()
    pr_publicrecreation = models.CopyFromBooleanField()
    pr_comm_ind = models.CopyFromBooleanField()
    pr_othertype = models.CopyFromCharField(max_length=200, blank=True)
    er_natlstateparks = models.CopyFromBooleanField()
    er_wildlifesactuary = models.CopyFromBooleanField()
    er_fedwilderness = models.CopyFromBooleanField()
    er_othertype = models.CopyFromCharField(max_length=200, blank=True)
    pm_blastwalls = models.CopyFromBooleanField()
    pm_othertype = models.CopyFromCharField(max_length=200, blank=True)
    ptrgraphic = models.CopyFromBooleanField(max_length=12, blank=True)
    cbi_flag = models.CopyFromBooleanField()

    source_file = 'tblS4FlammablesWorstCase'

    class Meta:
        db_table = 'tblS4FlammablesWorstCase'
Esempio n. 2
0
class Tbls3Toxicsaltreleases(models.Model):
    toxicid = models.CopyFromIntegerField(primary_key=True)
    processchemicalid = models.CopyFromForeignKey(
        Tbls1Processchemicals,
        on_delete=models.PROTECT,
    )
    percentweight = models.CopyFromDecimalField(max_digits=4,
                                                decimal_places=1,
                                                blank=True)
    physicalstate = models.CopyFromCharField(max_length=1, blank=True)
    analyticalbasis = models.CopyFromCharField(max_length=255, blank=True)
    scenario = models.CopyFromCharField(max_length=200)
    quantityreleased = models.CopyFromDecimalField(max_digits=5,
                                                   decimal_places=2)
    releaseduration = models.CopyFromDecimalField(max_digits=5,
                                                  decimal_places=2)
    releaserate = models.CopyFromBooleanField(blank=True)
    windspeed = models.CopyFromDecimalField(max_digits=6, decimal_places=2)
    stabilityclass = models.CopyFromCharField(max_length=1, blank=True)
    topography = models.CopyFromCharField(max_length=1, blank=True)
    endpoint_distance = models.CopyFromDecimalField(max_digits=5,
                                                    decimal_places=1)
    residentialpopulation = models.CopyFromCharField(max_length=9, blank=True)
    pr_schools = models.CopyFromBooleanField()
    pr_residences = models.CopyFromBooleanField()
    pr_hospitals = models.CopyFromBooleanField()
    pr_prisons = models.CopyFromBooleanField()
    pr_publicrecreation = models.CopyFromBooleanField()
    pr_comm_ind = models.CopyFromBooleanField()
    pr_othertype = models.CopyFromCharField(max_length=200, blank=True)
    er_natlstateparks = models.CopyFromBooleanField()
    er_wildlifesactuary = models.CopyFromBooleanField()
    er_fedwilderness = models.CopyFromBooleanField()
    er_othertype = models.CopyFromCharField(max_length=200, blank=True)
    pm_dikes = models.CopyFromBooleanField()
    pm_enclosures = models.CopyFromBooleanField()
    pm_berms = models.CopyFromBooleanField()
    pm_drains = models.CopyFromBooleanField()
    pm_sumps = models.CopyFromBooleanField()
    pm_othertype = models.CopyFromCharField(max_length=200, blank=True)
    am_sprinklersystems = models.CopyFromBooleanField()
    am_delugesystems = models.CopyFromBooleanField()
    am_watercurtain = models.CopyFromBooleanField()
    am_neutralization = models.CopyFromBooleanField()
    am_excessflowvalve = models.CopyFromBooleanField()
    am_flares = models.CopyFromBooleanField()
    am_scrubbers = models.CopyFromBooleanField()
    am_emergencyshutdown = models.CopyFromBooleanField()
    am_othertype = models.CopyFromCharField(max_length=200, blank=True)
    ptrgraphic = models.CopyFromCharField(max_length=12, blank=True)
    cbi_flag = models.CopyFromBooleanField()

    source_file = 'tblS3ToxicsAltReleases'

    class Meta:
        db_table = 'tblS3ToxicsAltReleases'
Esempio n. 3
0
class Tbls5Flammablesaltreleases(BaseRMPModel):
    flammableid = models.CopyFromIntegerField(primary_key=True)
    processchemicalid = models.CopyFromForeignKey(
        Tbls1Processchemicals,
        on_delete=models.PROTECT,
    )
    analyticalbasis = models.CopyFromCharField(max_length=255, blank=True)
    scenario = models.CopyFromCharField(max_length=200)
    quantityreleased = models.CopyFromDecimalField(max_digits=5,
                                                   decimal_places=2)
    endpointused = models.CopyFromCharField(max_length=30, blank=True)
    lfl_value = models.CopyFromDecimalField(max_digits=5, decimal_places=1)
    endpoint_distance = models.CopyFromDecimalField(max_digits=5,
                                                    decimal_places=1)
    residentialpopulation = models.CopyFromCharField(max_length=9, blank=True)
    pr_schools = models.CopyFromBooleanField()
    pr_residences = models.CopyFromBooleanField()
    pr_hospitals = models.CopyFromBooleanField()
    pr_prisons = models.CopyFromBooleanField()
    pr_publicrecreation = models.CopyFromBooleanField()
    pr_comm_ind = models.CopyFromBooleanField()
    pr_othertype = models.CopyFromCharField(max_length=200, blank=True)
    er_natlstateparks = models.CopyFromBooleanField()
    er_wildlifesactuary = models.CopyFromBooleanField()
    er_fedwilderness = models.CopyFromBooleanField()
    er_othertype = models.CopyFromCharField(max_length=200, blank=True)
    pm_dikes = models.CopyFromBooleanField()
    pm_firewalls = models.CopyFromBooleanField()
    pm_blastwalls = models.CopyFromBooleanField()
    pm_enclosures = models.CopyFromBooleanField()
    pm_othertype = models.CopyFromCharField(max_length=200, blank=True)
    am_sprinklersystems = models.CopyFromBooleanField()
    am_delugesystems = models.CopyFromBooleanField()
    am_watercurtain = models.CopyFromBooleanField()
    am_excessflowvalve = models.CopyFromBooleanField()
    am_othertype = models.CopyFromCharField(max_length=200, blank=True)
    ptrgraphic = models.CopyFromCharField(max_length=12, blank=True)
    cbi_flag = models.CopyFromBooleanField()

    source_file = 'tblS5FlammablesAltReleases'

    class Meta:
        db_table = 'tblS5FlammablesAltReleases'
Esempio n. 4
0
class AccChem(BaseRMPModel):
    accchem_id = models.CopyFromIntegerField(
        primary_key=True,
        verbose_name='Accident Chemical Record ID',
        help_text='A unique ID for each accident chemical record.',
    )
    accident = models.CopyFromForeignKey(
        'Accident',
        on_delete=models.PROTECT,
        help_text='The unique ID for each accident record',
    )
    chemical = models.CopyFromForeignKey(
        'ChemCd',
        on_delete=models.PROTECT,
        help_text='The identifying ID for a particular chemical released in an '
                  'accident.',
    )
    quantity_lbs = models.CopyFromIntegerField(
        null=True,
        verbose_name='Amount Released (lbs)',
        help_text='The amount of the substance released in the accident, in '
                  'pounds, to two significant digits.',
    )
    percent_weight = models.CopyFromDecimalField(
        decimal_places=2,
        null=True,
        max_digits=5,
        verbose_name='Percent Weight (Within Mixture)',
        help_text='The percent weight of a chemical within a mixture released '
                  'in an accident.',
    )
    num_acc_flam = models.CopyFromIntegerField(
        null=True,
        verbose_name='Number of Flammable Components',
        help_text='The number of listed flammable component chemicals for this'
                  ' chemical record.',
    )
    cas = models.CopyFromCharField(
        max_length=9,
        verbose_name='CAS number',
        help_text='The identifying CAS number for a chemical.',
    )
    CHEMICAL_TYPE_CHOICES = (
        ('T', 'toxic'),
        ('F', 'flammable'),
    )
    chemical_type = models.CopyFromCharField(
        max_length=1,
        choices=CHEMICAL_TYPE_CHOICES,
        help_text='"The type of chemical.',
    )
Esempio n. 5
0
class Tbls2Toxicsworstcase(BaseRMPModel):
    toxicid = models.CopyFromIntegerField(primary_key=True)
    processchemicalid = models.CopyFromForeignKey(Tbls1Processchemicals,
                                                  on_delete=models.PROTECT)
    percentweight = models.CopyFromDecimalField(max_digits=4,
                                                decimal_places=1,
                                                blank=True)
    physicalstate = models.CopyFromCharField(max_length=1, blank=True)
    analyticalbasis = models.CopyFromCharField(max_length=255, blank=True)
    scenario = models.CopyFromCopyFromBooleanField(blank=True)
    quantityreleased = models.CopyFromDecimalField(max_digits=6,
                                                   decimal_places=2,
                                                   blank=True)
    releaseduration = models.CopyFromDecimalField(max_digits=6,
                                                  decimal_places=2,
                                                  blank=True)
    releaserate = models.CopyFromDecimalField(max_digits=4,
                                              decimal_places=1,
                                              blank=True)
    windspeed = models.CopyFromDecimalField(max_digits=4,
                                            decimal_places=1,
                                            blank=True)
    stabilityclass = models.CopyFromCharField(max_length=1, blank=True)
    topography = models.CopyFromCharField(max_length=1, blank=True)
    endpoint_distance = models.CopyFromDecimalField(max_digits=5,
                                                    decimal_places=1)
    residentialpopulation = models.CopyFromBooleanField(blank=True)
    pr_schools = models.CopyFromBooleanField()
    pr_residences = models.CopyFromBooleanField()
    pr_hospitals = models.CopyFromBooleanField()
    pr_prisons = models.CopyFromBooleanField()
    pr_publicrecreation = models.CopyFromBooleanField()
    pr_comm_ind = models.CopyFromBooleanField()
    pr_othertype = models.CopyFromCharField(max_length=200, blank=True)
    er_natlstateparks = models.CopyFromBooleanField()
    er_wildlifesactuary = models.CopyFromBooleanField()
    er_fedwilderness = models.CopyFromBooleanField()
    er_othertype = models.CopyFromCharField(max_length=200, blank=True)
    pm_dikes = models.CopyFromBooleanField()
    pm_enclosures = models.CopyFromBooleanField()
    pm_berms = models.CopyFromBooleanField()
    pm_drains = models.CopyFromBooleanField()
    pm_sumps = models.CopyFromBooleanField()
    pm_othertype = models.CopyFromCharField(max_length=200, blank=True)
    ptrgraphic = models.CopyFromBooleanField(max_length=12, blank=True)
    cbi_flag = models.CopyFromBooleanField()

    source_file = 'tblS2ToxicsWorstCase'

    class Meta:
        db_table = 'tblS2ToxicsWorstCase'