|
|
@@ -972,9 +972,26 @@ public class StoreLawFirmServiceImpl extends ServiceImpl<LawFirmMapper, LawFirm>
|
|
|
if (!StringUtils.hasText(excelVo.getCreditCode())) {
|
|
|
return "第" + rowIndex + "行:统一社会信用代码不能为空";
|
|
|
}
|
|
|
+
|
|
|
+ // 校验统一社会信用代码位数(18位)
|
|
|
+ if (StringUtils.hasText(excelVo.getCreditCode())) {
|
|
|
+ String creditCode = excelVo.getCreditCode().trim();
|
|
|
+ if (creditCode.length() != 18) {
|
|
|
+ return "第" + rowIndex + "行:统一社会信用代码[" + creditCode + "]长度不正确,必须是18位,当前为" + creditCode.length() + "位";
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
if (!StringUtils.hasText(excelVo.getDirectorName())) {
|
|
|
return "第" + rowIndex + "行:负责人姓名不能为空";
|
|
|
}
|
|
|
+
|
|
|
+ // 校验手机号码位数(11位)
|
|
|
+ if (StringUtils.hasText(excelVo.getPhone())) {
|
|
|
+ String phone = excelVo.getPhone().trim();
|
|
|
+ if (phone.length() != 11) {
|
|
|
+ return "第" + rowIndex + "行:联系电话[" + phone + "]长度不正确,必须是11位,当前为" + phone.length() + "位";
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
// 校验收款账号(不允许逗号分隔,必须是单个16位或19位账号)
|
|
|
if (StringUtils.hasText(excelVo.getPaymentAccount())) {
|