Merge remote-tracking branch 'origin/fix/20240424'
Showing
2 changed files
with
33 additions
and
5 deletions
... | @@ -1675,15 +1675,30 @@ SE_FSM_MSI_MAP = { | ... | @@ -1675,15 +1675,30 @@ SE_FSM_MSI_MAP = { |
1675 | '签单日期': (2, '签单日期'), | 1675 | '签单日期': (2, '签单日期'), |
1676 | } | 1676 | } |
1677 | 1677 | ||
1678 | def get_page_customer_sign(page_no): | ||
1679 | return (page_no, '客户签名') | ||
1680 | |||
1681 | def get_page_sign_date(page_no): | ||
1682 | return (page_no, '签单日期') | ||
1683 | |||
1678 | SE_FSM_SC_MAP = { | 1684 | SE_FSM_SC_MAP = { |
1679 | '姓名': (1, '姓名'), | 1685 | '姓名': (1, '姓名'), |
1680 | '证件类型': (1, '证件类型'), | 1686 | '证件类型': (1, '证件类型'), |
1681 | '证件号码': (1, '证件号码'), | 1687 | '证件号码': (1, '证件号码'), |
1682 | '总价': (1, '总价'), | 1688 | '总价': (1, '总价'), |
1683 | '客户签名': (12, '客户签名'), | 1689 | '客户签名': get_page_customer_sign, |
1684 | '签单日期': (12, '签单日期'), | 1690 | '签单日期': get_page_sign_date, |
1685 | } | 1691 | } |
1686 | 1692 | ||
1693 | # SE_FSM_SC_MAP = { | ||
1694 | # '姓名': (1, '姓名'), | ||
1695 | # '证件类型': (1, '证件类型'), | ||
1696 | # '证件号码': (1, '证件号码'), | ||
1697 | # '总价': (1, '总价'), | ||
1698 | # '客户签名': (12, '客户签名'), | ||
1699 | # '签单日期': (12, '签单日期'), | ||
1700 | # } | ||
1701 | |||
1687 | SE_FSM_SC2_MAP = { | 1702 | SE_FSM_SC2_MAP = { |
1688 | '姓名': (1, '姓名'), | 1703 | '姓名': (1, '姓名'), |
1689 | '证件类型': (1, '证件类型'), | 1704 | '证件类型': (1, '证件类型'), | ... | ... |
... | @@ -1030,10 +1030,23 @@ class Command(BaseCommand, LoggerMixin): | ... | @@ -1030,10 +1030,23 @@ class Command(BaseCommand, LoggerMixin): |
1030 | 1030 | ||
1031 | elif classify in consts.SE_FSM_CON_MAP: | 1031 | elif classify in consts.SE_FSM_CON_MAP: |
1032 | res = {} | 1032 | res = {} |
1033 | for key, (pno1, key1) in consts.SE_FSM_CON_MAP[classify].items(): | 1033 | # for key, (pno1, key1) in consts.SE_FSM_CON_MAP[classify].items(): |
1034 | # res[key] = page_info_dict.get(str(pno1), {}).get(key1) | ||
1035 | # res.setdefault(consts.IMG_PATH_KEY, dict())[key] = page_info_dict.get(str(pno1), {}).get( | ||
1036 | # consts.IMG_PATH_KEY, '') | ||
1037 | # license_summary[classify] = [res] | ||
1038 | |||
1039 | for key, value in consts.SE_FSM_CON_MAP[classify].items(): | ||
1040 | if callable(value): | ||
1041 | for page_no in page_info_dict.keys(): | ||
1042 | if page_no != 'is_asp' and page_no != '1': | ||
1043 | pno1, key1 = value(int(page_no)) | ||
1034 | res[key] = page_info_dict.get(str(pno1), {}).get(key1) | 1044 | res[key] = page_info_dict.get(str(pno1), {}).get(key1) |
1035 | res.setdefault(consts.IMG_PATH_KEY, dict())[key] = page_info_dict.get(str(pno1), {}).get( | 1045 | res.setdefault(consts.IMG_PATH_KEY, dict())[key] = page_info_dict.get(str(pno1), {}).get(consts.IMG_PATH_KEY, '') |
1036 | consts.IMG_PATH_KEY, '') | 1046 | else: |
1047 | pno1, key1 = value | ||
1048 | res[key] = page_info_dict.get(str(pno1), {}).get(key1) | ||
1049 | res.setdefault(consts.IMG_PATH_KEY, dict())[key] = page_info_dict.get(str(pno1), {}).get(consts.IMG_PATH_KEY, '') | ||
1037 | license_summary[classify] = [res] | 1050 | license_summary[classify] = [res] |
1038 | 1051 | ||
1039 | def rebuild_bs_summary(self, bs_summary, unknown_summary): | 1052 | def rebuild_bs_summary(self, bs_summary, unknown_summary): | ... | ... |
-
Please register or sign in to post a comment