June SE part 2
Showing
3 changed files
with
14 additions
and
9 deletions
... | @@ -1409,7 +1409,7 @@ SE_CORPORATE_ALL_FIELD = ['companyName', 'legalRepName', 'firstIdNo', 'businessL | ... | @@ -1409,7 +1409,7 @@ SE_CORPORATE_ALL_FIELD = ['companyName', 'legalRepName', 'firstIdNo', 'businessL |
1409 | 'taxRegistrationCertificateNo', 'establishmentDate', 'businessLicenseDueDate'] | 1409 | 'taxRegistrationCertificateNo', 'establishmentDate', 'businessLicenseDueDate'] |
1410 | SE_NEW_FIELD = ['vinNo', 'dealer', 'vehicleTransactionAmount'] | 1410 | SE_NEW_FIELD = ['vinNo', 'dealer', 'vehicleTransactionAmount'] |
1411 | SE_USED_FIELD = ['vinNo', 'vehicleTransactionAmount'] | 1411 | SE_USED_FIELD = ['vinNo', 'vehicleTransactionAmount'] |
1412 | SE_NEW_ADD_FIELD = ['customerName', 'idNum', 'dateOfInvoice', 'stamp', '发票联', '发票真伪校验', '新旧版式'] | 1412 | SE_NEW_ADD_FIELD = ['customerName', 'idNum', 'dateOfInvoice', 'stamp', '发票联', '发票真伪校验', '新旧版式', '不含税价校验', '增值税额校验', '价税合计大小写检验'] |
1413 | SE_FPL_VALUE = '发票联' | 1413 | SE_FPL_VALUE = '发票联' |
1414 | SE_STAMP_VALUE = '有' | 1414 | SE_STAMP_VALUE = '有' |
1415 | SE_DYSYR_VALUE = '无' | 1415 | SE_DYSYR_VALUE = '无' |
... | @@ -1717,6 +1717,12 @@ SME_BL_COMPARE_LOGIC = { | ... | @@ -1717,6 +1717,12 @@ SME_BL_COMPARE_LOGIC = { |
1717 | 'businessLicenseDueDate': ('营业期限', 'se_date_compare', {'ocr_split': True, 'long': True, 'ocr_replace': True, 'today': True}, '公司营业期限疑似过期'), | 1717 | 'businessLicenseDueDate': ('营业期限', 'se_date_compare', {'ocr_split': True, 'long': True, 'ocr_replace': True, 'today': True}, '公司营业期限疑似过期'), |
1718 | } | 1718 | } |
1719 | 1719 | ||
1720 | ZW_METHOD = 'mvi_special' | ||
1721 | LOWER_AMOUNT_FIELD = '价税合计小写' | ||
1722 | UPPER_AMOUNT_FIELD = '价税合计大写' | ||
1723 | BHSJ_FIELD = '不含税价' | ||
1724 | ZZSSE_FIELD = '增值税税额' | ||
1725 | |||
1720 | MVI_COMPARE_LOGIC = { | 1726 | MVI_COMPARE_LOGIC = { |
1721 | 'vinNo': ('车辆识别代码', 'se_common_compare', {}, '发票车架号与系统不一致'), | 1727 | 'vinNo': ('车辆识别代码', 'se_common_compare', {}, '发票车架号与系统不一致'), |
1722 | 'dealer': ('销方名称', 'se_contain_compare_2', {'brackets_replace': True}, '发票销货单位名称与系统不一致'), | 1728 | 'dealer': ('销方名称', 'se_contain_compare_2', {'brackets_replace': True}, '发票销货单位名称与系统不一致'), |
... | @@ -1726,14 +1732,13 @@ MVI_COMPARE_LOGIC = { | ... | @@ -1726,14 +1732,13 @@ MVI_COMPARE_LOGIC = { |
1726 | 'dateOfInvoice': ('开票日期', 'se_date_compare_2', {'three_month': True}, '发票开票日期早于首次提交申请日期'), | 1732 | 'dateOfInvoice': ('开票日期', 'se_date_compare_2', {'three_month': True}, '发票开票日期早于首次提交申请日期'), |
1727 | 'stamp': ('销售单位章', 'se_common_compare', {}, '发票无章'), | 1733 | 'stamp': ('销售单位章', 'se_common_compare', {}, '发票无章'), |
1728 | '发票联': ('发票类型', 'se_common_compare', {}, '发票疑似非发票联'), | 1734 | '发票联': ('发票类型', 'se_common_compare', {}, '发票疑似非发票联'), |
1729 | '发票真伪校验': ('发票真伪校验', 'se_common_compare', {}, '发票疑似造假,需人工核算'), | 1735 | # '发票真伪校验': ('发票真伪校验', 'se_common_compare', {}, '发票疑似造假,需人工核算'), |
1736 | '不含税价校验': (BHSJ_FIELD, 'se_common_compare', {}, '发票不含税价疑似错误,需人工核算'), | ||
1737 | '增值税额校验': (ZZSSE_FIELD, 'se_common_compare', {}, '发票增值税额疑似错误,需人工核算'), | ||
1738 | '价税合计大小写检验': ('价税合计大小写检验', 'se_common_compare', {}, '发票价税合计大小写校验疑似错误,需人工核算'), | ||
1730 | '新旧版式': ('新旧版式', 'se_contain_compare_2', {}, '发票版本与打印版式不符'), | 1739 | '新旧版式': ('新旧版式', 'se_contain_compare_2', {}, '发票版本与打印版式不符'), |
1731 | } | 1740 | } |
1732 | ZW_METHOD = 'mvi_special' | 1741 | |
1733 | LOWER_AMOUNT_FIELD = '价税合计小写' | ||
1734 | UPPER_AMOUNT_FIELD = '价税合计大写' | ||
1735 | BHSJ_FIELD = '不含税价' | ||
1736 | ZZSSE_FIELD = '增值税税额' | ||
1737 | 1742 | ||
1738 | UCI_COMPARE_LOGIC = { | 1743 | UCI_COMPARE_LOGIC = { |
1739 | 'vinNo': ('车架号', 'se_common_compare', {}, '二手车发票车架号与系统不一致'), | 1744 | 'vinNo': ('车架号', 'se_common_compare', {}, '二手车发票车架号与系统不一致'), | ... | ... |
This diff is collapsed.
Click to expand it.
... | @@ -123,7 +123,7 @@ class Comparison: | ... | @@ -123,7 +123,7 @@ class Comparison: |
123 | ocr_output = None | 123 | ocr_output = None |
124 | return self.build_res(input_str == ocr_str), ocr_output | 124 | return self.build_res(input_str == ocr_str), ocr_output |
125 | 125 | ||
126 | def mvi_special(self, amount_lower_str, amount_upper_str, bhsj_str, zzsse_str): | 126 | def mvi_special(self, amount_lower_str, amount_upper_str): |
127 | # 不含税价, 增值税税额 | 127 | # 不含税价, 增值税税额 |
128 | try: | 128 | try: |
129 | if float(amount_lower_str) != rmb_handler.to_rmb_lower(amount_upper_str): | 129 | if float(amount_lower_str) != rmb_handler.to_rmb_lower(amount_upper_str): |
... | @@ -131,7 +131,7 @@ class Comparison: | ... | @@ -131,7 +131,7 @@ class Comparison: |
131 | except Exception: | 131 | except Exception: |
132 | return self.RESULT_N | 132 | return self.RESULT_N |
133 | else: | 133 | else: |
134 | return self.SPLIT_STR.join([bhsj_str, zzsse_str, self.RESULT_Y]) | 134 | return self.RESULT_Y |
135 | 135 | ||
136 | def rmb_compare(self, input_str, ocr_str, idx, **kwargs): | 136 | def rmb_compare(self, input_str, ocr_str, idx, **kwargs): |
137 | if not isinstance(ocr_str, str) or not isinstance(input_str, str): | 137 | if not isinstance(ocr_str, str) or not isinstance(input_str, str): | ... | ... |
-
Please register or sign in to post a comment