add new processor

This commit is contained in:
2025-11-13 20:43:35 +08:00
parent f00cee7410
commit 00a3f0f1e9
15 changed files with 961 additions and 1 deletions

View File

@@ -172,6 +172,11 @@ func (s *FormConfigServiceImpl) getDTOStruct(ctx context.Context, apiCode string
"IVYZ8I9J": &dto.IVYZ8I9JReq{},
"JRZQ0L85": &dto.JRZQ0L85Req{},
"COMBHZY2": &dto.COMBHZY2Req{},
"QCXG8A3D": &dto.QCXG8A3DReq{},
"QCXG6B4E": &dto.QCXG6B4EReq{},
"QYGL2B5C": &dto.QYGL2B5CReq{},
"JRZQ2F8A": &dto.JRZQ2F8AReq{},
"JRZQ1E7B": &dto.JRZQ1E7BReq{},
}
// 优先返回已配置的DTO
@@ -271,6 +276,8 @@ func (s *FormConfigServiceImpl) parseValidationRules(validateTag string) string
frontendRules = append(frontendRules, "姓名格式")
case rule == "validUSCI":
frontendRules = append(frontendRules, "统一社会信用代码格式")
case rule == "validEnterpriseName" || rule == "enterprise_name":
frontendRules = append(frontendRules, "企业名称格式")
case rule == "validBankCard":
frontendRules = append(frontendRules, "银行卡号格式")
case rule == "validDate":
@@ -357,6 +364,9 @@ func (s *FormConfigServiceImpl) generateFieldLabel(jsonTag string) string {
"page_size": "每页数量",
"use_scenario": "使用场景",
"auth_authorize_file_code": "授权文件编码",
"plate_no": "车牌号",
"plate_type": "号牌类型",
"vin_code": "车辆识别代号VIN码",
}
if label, exists := labelMap[jsonTag]; exists {
@@ -394,6 +404,9 @@ func (s *FormConfigServiceImpl) generateExampleValue(fieldType reflect.Type, jso
"page_size": "10",
"use_scenario": "1",
"auth_authorize_file_code": "AUTH123456",
"plate_no": "京A12345",
"plate_type": "01",
"vin_code": "LSGBF53M8DS123456",
}
if example, exists := exampleMap[jsonTag]; exists {
@@ -440,6 +453,9 @@ func (s *FormConfigServiceImpl) generatePlaceholder(jsonTag string, fieldType st
"page_size": "请输入每页数量1-100",
"use_scenario": "请选择使用场景",
"auth_authorize_file_code": "请输入授权文件编码",
"plate_no": "请输入车牌号",
"plate_type": "请选择号牌类型01或02",
"vin_code": "请输入17位车辆识别代号VIN码",
}
if placeholder, exists := placeholderMap[jsonTag]; exists {
@@ -488,6 +504,9 @@ func (s *FormConfigServiceImpl) generateDescription(jsonTag string, validation s
"page_size": "请输入每页数量范围1-100",
"use_scenario": "使用场景1-信贷审核2-保险评估3-招聘背景调查4-其他业务场景99-其他",
"auth_authorize_file_code": "请输入授权文件编码",
"plate_no": "请输入车牌号",
"plate_type": "号牌类型01-小型汽车02-大型汽车(可选)",
"vin_code": "请输入17位车辆识别代号VIN码Vehicle Identification Number",
}
if desc, exists := descMap[jsonTag]; exists {