def __init__(self, elem, sid): Master.__init__(self, elem) self.measure_sid = sid self.footnote_type_id = Master.process_null( elem.find("footnote/footnoteType/footnoteTypeId")) self.footnote_id = Master.process_null( elem.find("footnote/footnoteId"))
def get_data(self): self.validity_start_date = Master.process_null( self.elem.find("validityStartDate")) self.validity_end_date = Master.process_null( self.elem.find("validityEndDate")) self.hjid_of_member = int( Master.process_null(self.elem.find("geographicalAreaGroupSid"))) self.get_member_description() self.tbl = [ "Membership start date", Master.format_date(self.validity_start_date), "HJID", self.hjid_of_member, ] if self.validity_end_date == "": self.membership_string = Master.format_date( self.validity_start_date ) + " : " + self.member_description + "\n" self.current_membership_string = Master.format_date( self.validity_start_date ) + " : " + self.member_description + "\n" else: self.membership_string = Master.format_date( self.validity_start_date) + " to " + Master.format_date( self.validity_end_date ) + " : " + self.member_description + "\n"
def __init__(self, elem, quota_definition_sid): Master.__init__(self, elem) self.quota_definition_sid = quota_definition_sid self.quota_suspension_period_sid = Master.process_null(elem.find("sid")) self.suspension_start_date = Master.process_null(elem.find("suspensionStartDate")) self.suspension_end_date = Master.process_null(elem.find("suspensionEndDate")) self.description = Master.process_null(elem.find("description"))
def get_data(self): self.sid = Master.process_null(self.elem.find("sid")) self.critical_state = Master.process_null( self.elem.find("criticalState")) self.critical_threshold = Master.process_null( self.elem.find("criticalThreshold")) self.initial_volume = Master.process_null( self.elem.find("initialVolume")) self.volume = Master.process_null(self.elem.find("volume")) self.maximum_precision = Master.process_null( self.elem.find("maximumPrecision")) self.quota_order_number_id = Master.process_null( self.elem.find("quotaOrderNumber/quotaOrderNumberId")) self.quota_order_number_sid = Master.process_null( self.elem.find("quotaOrderNumber/sid")) self.validity_start_date = Master.process_null( self.elem.find("validityStartDate")) self.validity_end_date = Master.process_null( self.elem.find("validityEndDate")) self.get_balance_events() self.get_sample_comm_codes() change = QuotaDefinitionChange(self.sid, "Quota definition", self.operation) g.change_list.append(change)
def __init__(self, elem): Master.__init__(self, elem) self.footnote_id = Master.process_null(elem.find("footnoteId")) self.footnote_type_id = Master.process_null(elem.find("footnoteType/footnoteTypeId")) for elem in elem.findall('.//footnoteDescriptionPeriod'): self.footnote_description_periods.append(FootnoteDescriptionPeriod(elem, self.footnote_type_id, self.footnote_id))
def __init__(self, elem, sid): Master.__init__(self, elem) self.measure_sid = sid self.excluded_geographical_area = Master.process_null( elem.find("geographicalArea/geographicalAreaId")) self.geographical_area_sid = Master.process_null( elem.find("geographicalArea/sid"))
def get_data(self): if self.operation != "D": self.sid = Master.process_null_float(self.elem.find("sid")) self.condition_sequence_number = Master.process_null( self.elem.find("conditionSequenceNumber")) self.certificate_code = Master.process_null( self.elem.find("certificate/certificateCode")) self.certificate_type_code = Master.process_null( self.elem.find( "certificate/certificateType/certificateTypeCode")) self.certificate = self.certificate_type_code + self.certificate_code self.action_code = Master.process_null( self.elem.find("measureAction/actionCode")) self.condition_code = Master.process_null( self.elem.find("measureConditionCode/conditionCode")) self.get_condition_code_description() self.get_action_code_description() self.output = "" if self.certificate == "": self.certificate = "n/a" self.output += "Certificate: " + self.certificate + ", " self.output += "Condition code: " + self.condition_code + " (" + self.condition_code_description + "), " self.output += "Action code: " + self.action_code + " (" + self.condition_code_description + ")<br /><br />" else: self.output = ""
def __init__(self, elem, sid): Master.__init__(self, elem) self.measure_condition_sid = Master.process_null(elem.find("sid")) self.measure_sid = sid self.condition_code = Master.process_null( elem.find("measureConditionCode/conditionCode")) self.component_sequence_number = Master.process_null( elem.find("conditionSequenceNumber")) self.condition_duty_amount = Master.process_null( elem.find("conditionDutyAmount")) self.condition_monetary_unit_code = Master.process_null( elem.find("monetaryUnit/monetaryUnitCode")) self.condition_measurement_unit_code = Master.process_null( elem.find("measurementUnit/measurementUnitCode")) self.condition_measurement_unit_qualifier_code = Master.process_null( elem.find("measurementUnitQualifier/measurementUnitQualifierCode")) self.action_code = Master.process_null( elem.find("measureAction/actionCode")) self.certificate_type_code = Master.process_null( elem.find("certificate/certificateType/certificateTypeCode")) self.certificate_code = Master.process_null( elem.find("certificate/certificateCode")) for elem in elem.findall('.//measureConditionComponent'): self.measure_condition_components.append( MeasureConditionComponent(elem, self.measure_condition_sid))
def get_data(self): self.new_balance = Master.process_null(self.elem.find("newBalance")) self.old_balance = Master.process_null(self.elem.find("oldBalance")) self.occurrence_timestamp = Master.format_date( self.elem.find("occurrenceTimestamp").text) self.quota_balance_event_string = str( self.occurrence_timestamp) + " - New: " + str( self.new_balance) + " : " + "Old: " + str(self.old_balance)
def __init__(self, elem, quota_definition_sid): Master.__init__(self, elem) self.quota_definition_sid = quota_definition_sid self.quota_blocking_period_sid = Master.process_null(elem.find("sid")) self.blocking_start_date = Master.process_null(elem.find("blockingStartDate")) self.blocking_end_date = Master.process_null(elem.find("blockingEndDate")) self.blocking_period_type = Master.process_null(elem.find("blockingPeriodType")) self.description = Master.process_null(elem.find("description"))
def __init__(self, elem, footnote_type_id, footnote_id, footnote_description_period_sid): Master.__init__(self, elem) self.footnote_description_period_sid = footnote_description_period_sid self.footnote_type_id = footnote_type_id self.footnote_id = footnote_id self.description = Master.process_null(elem.find("description")) self.language_id = Master.process_null( elem.find("language/languageId"))
def __init__(self, elem, certificate_type_code, certificate_code, certificate_description_period_sid): Master.__init__(self, elem) self.certificate_description_period_sid = certificate_description_period_sid self.certificate_type_code = certificate_type_code self.certificate_code = certificate_code self.description = Master.process_null(elem.find("description")) self.language_id = Master.process_null( elem.find("language/languageId"))
def get_data(self): self.footnote_id = Master.process_null(self.elem.find("footnoteId")) self.footnote_type_id = Master.process_null( self.elem.find("footnoteType/footnoteTypeId")) self.validity_start_date = Master.process_null( self.elem.find("validityStartDate")) self.validity_end_date = Master.process_null( self.elem.find("validityEndDate")) self.get_descriptions()
def get_data(self): self.certificate_code = Master.process_null( self.elem.find("certificateCode")) self.certificate_type_code = Master.process_null( self.elem.find("certificateType/certificateTypeCode")) self.validity_start_date = Master.process_null( self.elem.find("validityStartDate")) self.validity_end_date = Master.process_null( self.elem.find("validityEndDate")) self.get_descriptions()
def __init__(self, elem, additional_code_type_id, additional_code, additional_code_sid, additional_code_description_period_sid): Master.__init__(self, elem) self.additional_code_description_period_sid = additional_code_description_period_sid self.additional_code_type_id = additional_code_type_id self.additional_code = additional_code self.additional_code_sid = additional_code_sid self.description = Master.process_null(elem.find("description")) self.language_id = Master.process_null( elem.find("language/languageId"))
def __init__(self, elem, quota_definition_sid): Master.__init__(self, elem) self.quota_definition_sid = quota_definition_sid self.imported_amount = Master.process_null(elem.find("importedAmount")) self.last_import_date_in_allocation = Master.process_null( elem.find("lastImportDateInAllocation")) self.new_balance = Master.process_null(elem.find("newBalance")) self.occurrence_timestamp = Master.process_null( elem.find("occurrenceTimestamp")) self.old_balance = Master.process_null(elem.find("oldBalance"))
def __init__(self, elem): Master.__init__(self, elem) self.quota_order_number_sid = Master.process_null(elem.find("sid")) self.quota_order_number_id = Master.process_null(elem.find("quotaOrderNumberId")) self.validity_start_date = Master.process_null(elem.find("validityStartDate")) self.validity_end_date = Master.process_null(elem.find("validityEndDate")) # Get origins for el in elem.findall('.//quotaOrderNumberOrigin'): self.quota_order_number_origins.append(QuotaOrderNumberOrigin(el, self.quota_order_number_sid))
def get_data(self): self.measure_sid = Master.process_null_int(self.elem.find("sid")) self.measure_generating_regulation_id = Master.process_null( self.elem.find("measureGeneratingRegulationId")) self.geographical_area_id = Master.process_null( self.elem.find("geographicalArea/geographicalAreaId")) self.goods_nomenclature_item_id = Master.process_null( self.elem.find("goodsNomenclature/goodsNomenclatureItemId")) self.measure_type_id = Master.process_null( self.elem.find("measureType/measureTypeId")) self.validity_start_date = Master.process_null( self.elem.find("validityStartDate")) self.validity_end_date = Master.process_null( self.elem.find("validityEndDate")) self.ordernumber = Master.process_null(self.elem.find("ordernumber")) self.additional_code_code = Master.process_null( self.elem.find("additionalCode/additionalCodeCode")) self.additional_code_type_id = Master.process_null( self.elem.find( "additionalCode/additionalCodeType/additionalCodeTypeId")) self.additional_code = self.additional_code_type_id + self.additional_code_code self.get_geographical_area_description() self.get_measure_type_description() self.get_measure_components() self.get_measure_conditions() self.get_measure_excluded_geographical_areas() self.get_footnotes() change = MeasureChange(self.measure_sid, self.goods_nomenclature_item_id, "Measure", self.operation) g.change_list.append(change)
def __init__(self, elem): Master.__init__(self, elem) self.certificate_code = Master.process_null( elem.find("certificateCode")) self.certificate_type_code = Master.process_null( elem.find("certificateType/certificateTypeCode")) for elem in elem.findall('.//certificateDescriptionPeriod'): self.certificate_description_periods.append( CertificateDescriptionPeriod(elem, self.certificate_type_code, self.certificate_code))
def get_data(self): if self.operation != "D": self.footnote_id = Master.process_null( self.elem.find("footnote/footnoteId")) self.footnote_type_id = Master.process_null( self.elem.find("footnote/footnoteType/footnoteTypeId")) else: self.footnote_id = "" self.footnote_type_id = "" self.footnote = self.footnote_type_id + self.footnote_id
def __init__(self, elem, goods_nomenclature_item_id, goods_nomenclature_sid, productline_suffix): Master.__init__(self, elem) self.goods_nomenclature_item_id = goods_nomenclature_item_id self.goods_nomenclature_sid = goods_nomenclature_sid self.goods_nomenclature_indent_sid = Master.process_null( elem.find("sid")) self.productline_suffix = productline_suffix self.number_indents = Master.process_null(elem.find("numberIndents")) self.validity_start_date = Master.process_null( elem.find("validityStartDate"))
def __init__(self, elem, sid): Master.__init__(self, elem) self.measure_sid = sid self.duty_expression_id = Master.process_null( elem.find("dutyExpression/dutyExpressionId")) self.duty_amount = Master.process_null(elem.find("dutyAmount")) self.monetary_unit_code = Master.process_null( elem.find("monetaryUnit/monetaryUnitCode")) self.measurement_unit_code = Master.process_null( elem.find("measurementUnit/measurementUnitCode")) self.measurement_unit_qualifier_code = Master.process_null( elem.find("measurementUnitQualifier/measurementUnitQualifierCode"))
def get_data(self): if self.operation != "D": self.validity_start_date = Master.process_null(self.elem.find("validityStartDate")) self.description = Master.process_null(self.elem.find("goodsNomenclatureDescription/description")) self.tbl = [ "Description start date", Master.format_date(self.validity_start_date), "Description", self.description, ] self.description_string = self.description else: self.tbl = None self.description_string = ""
def __init__(self, elem, goods_nomenclature_item_id, goods_nomenclature_sid, goods_nomenclature_description_period_sid, productline_suffix): Master.__init__(self, elem) self.goods_nomenclature_description_period_sid = goods_nomenclature_description_period_sid self.goods_nomenclature_item_id = goods_nomenclature_item_id self.goods_nomenclature_sid = goods_nomenclature_sid self.productline_suffix = productline_suffix self.description = Master.process_null(elem.find("description")) self.language_id = Master.process_null( elem.find("language/languageId"))
def get_data(self): self.sid = Master.process_null(self.elem.find("sid")) self.geographical_area_id = Master.process_null( self.elem.find("geographicalAreaId")) self.validity_start_date = Master.process_null( self.elem.find("validityStartDate")) self.validity_end_date = Master.process_null( self.elem.find("validityEndDate")) self.parent_geographical_area_group_sid = Master.process_null( self.elem.find("parentGeographicalAreaGroupSid")) self.get_descriptions() self.get_members()
def get_data(self): self.validity_start_date = Master.process_null( self.elem.find("validityStartDate")) self.description = Master.process_null( self.elem.find("geographicalAreaDescription/description")) self.tbl = [ "Description start date", Master.format_date(self.validity_start_date), "Description", self.description, ] self.description_string = Master.format_date( self.validity_start_date) + " : " + self.description + "\n"
def __init__(self, elem, certificate_type_code, certificate_code): Master.__init__(self, elem) self.certificate_type_code = certificate_type_code self.certificate_code = certificate_code self.certificate_description_period_sid = Master.process_null( elem.find("sid")) self.validity_start_date = Master.process_null( elem.find("validityStartDate")) for elem in elem.findall('.//certificateDescription'): self.certificate_descriptions.append( CertificateDescription( elem, self.certificate_type_code, self.certificate_code, self.certificate_description_period_sid))
def __init__(self, elem, goods_nomenclature_item_id, goods_nomenclature_sid, productline_suffix): Master.__init__(self, elem) self.goods_nomenclature_item_id = goods_nomenclature_item_id self.goods_nomenclature_sid = goods_nomenclature_sid self.productline_suffix = productline_suffix self.validity_start_date = Master.process_null( elem.find("validityStartDate")) self.validity_end_date = Master.process_null( elem.find("validityEndDate")) self.footnote_type = Master.process_null( elem.find("footnote/footnoteType/footnoteTypeId")) self.footnote_id = Master.process_null( elem.find("footnote/footnoteId"))
def __init__(self, elem, footnote_type_id, footnote_id): Master.__init__(self, elem) self.footnote_type_id = footnote_type_id self.footnote_id = footnote_id self.footnote_description_period_sid = Master.process_null( elem.find("sid")) self.validity_start_date = Master.process_null( elem.find("validityStartDate")) for elem in elem.findall('.//footnoteDescription'): self.footnote_descriptions.append( FootnoteDescription(elem, self.footnote_type_id, self.footnote_id, self.footnote_description_period_sid))
def __init__(self, elem): Master.__init__(self, elem) self.additional_code_sid = Master.process_null(elem.find("sid")) self.additional_code = Master.process_null( elem.find("additionalCodeCode")) self.additional_code_type_id = Master.process_null( elem.find("additionalCodeType/additionalCodeTypeId")) for elem in elem.findall('.//additionalCodeDescriptionPeriod'): self.additional_code_description_periods.append( AdditionalCodeDescriptionPeriod(elem, self.additional_code_type_id, self.additional_code, self.additional_code_sid))