|
|
|
@ -506,17 +506,18 @@ public class BaseInvoiceController extends AbstractController { |
|
|
|
|
@SysLog("调用手工勾选查询接口") |
|
|
|
|
@ResponseBody |
|
|
|
|
public Object sggxcx(@RequestBody Map<String, Object> map) { |
|
|
|
|
// List<TaxOrgCode> orgCodes = getUserInfo().getOrgCodes();
|
|
|
|
|
// log.info("user信息========>{}",getUserInfo());
|
|
|
|
|
// if (orgCodes != null && orgCodes.size() > 0){
|
|
|
|
|
// for (int i = 0; i < orgCodes.size(); i++) {
|
|
|
|
|
// log.info("orgcode=======>{}",orgCodes.get(i));
|
|
|
|
|
// }
|
|
|
|
|
// }else {
|
|
|
|
|
// log.info("未能获得机构代码");
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
String gfsh = (String)map.get("gfsh"); |
|
|
|
|
if(map.get("gfsh") == null || "".equals(map.get("gfsh"))){ |
|
|
|
|
return ResponseEntity.ok(R.error("购方税号不能为空")); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (map.get("companyCode") == null || "".equals(map.get("companyCode"))){ |
|
|
|
|
return ResponseEntity.ok(R.error("组织编码不能为空")); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
String gfsh = (String) map.get("gfsh"); |
|
|
|
|
String companyCode = (String) map.get("companyCode"); |
|
|
|
|
String invoiceType = (String)map.get("invoiceType"); |
|
|
|
|
String invoiceSource = (String)map.get("invoiceSource"); |
|
|
|
|
String kpksrq = (String)map.get("kpksrq"); |
|
|
|
@ -541,7 +542,6 @@ public class BaseInvoiceController extends AbstractController { |
|
|
|
|
String menuId = (String)map.get("menuId"); |
|
|
|
|
String bzdh = (String) map.get("bzdh"); |
|
|
|
|
String inAccountStatus = (String) map.get("inAccountStatus"); |
|
|
|
|
String companyCode = (String) map.get("companyCode"); |
|
|
|
|
String suspendStatus = (String) map.get("suspendStastus"); |
|
|
|
|
String suspendDate = (String) map.get("suspendDate"); |
|
|
|
|
String bzr = (String) map.get("bzr"); |
|
|
|
@ -550,22 +550,13 @@ public class BaseInvoiceController extends AbstractController { |
|
|
|
|
suspendDate = suspendDate.substring(0,7); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// //所属机构列表
|
|
|
|
|
// List<String> orgCodes = null;
|
|
|
|
|
// if (map.get("orgCodes") !=null){
|
|
|
|
|
// orgCodes = (List<String>) map.get("orgCodes");
|
|
|
|
|
// }else {
|
|
|
|
|
// List<TaxOrgCode> taxOrgCodes = getUserInfo().getOrgCodes();
|
|
|
|
|
// if (taxOrgCodes != null && taxOrgCodes.size() > 0){
|
|
|
|
|
// for (TaxOrgCode taxOrgCode : taxOrgCodes) {
|
|
|
|
|
// orgCodes.add(taxOrgCode.getOrgCode());
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Map<String, Object> pramsMap = new HashMap<>(32); |
|
|
|
|
// pramsMap.put("orgCodes",orgCodes);
|
|
|
|
|
|
|
|
|
|
pramsMap.put("companyCode",companyCode); |
|
|
|
|
pramsMap.put("gfsh", gfsh); |
|
|
|
|
pramsMap.put("bzdh", bzdh); |
|
|
|
|
pramsMap.put("inAccountStatus", inAccountStatus); |
|
|
|
|
pramsMap.put("company", company); |
|
|
|
@ -606,8 +597,6 @@ public class BaseInvoiceController extends AbstractController { |
|
|
|
|
pramsMap.put("accountPeriod", accountPeriod); |
|
|
|
|
log.info("accountPeriod:{}",accountPeriod); |
|
|
|
|
} |
|
|
|
|
// pramsMap.put("accountPeriod", map.get("accountPeriod"));
|
|
|
|
|
// String inAccountStatus = (String)map.get("inAccountStatus");
|
|
|
|
|
|
|
|
|
|
if (sfkrz != null) { |
|
|
|
|
if (!"99".equals(sfkrz)) { |
|
|
|
@ -629,34 +618,6 @@ public class BaseInvoiceController extends AbstractController { |
|
|
|
|
pramsMap.put("taxRate",taxRate); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//所属组织
|
|
|
|
|
// List<String> companyCodeList = new ArrayList<>();
|
|
|
|
|
// if (StringUtils.isNotBlank(companyCode) && !"99".equals(companyCode)){
|
|
|
|
|
// companyCodeList.add(companyCode);
|
|
|
|
|
// }else {
|
|
|
|
|
// companyCodeList = getUserInfo().getCompanyCodes();
|
|
|
|
|
// log.info("获取到的组织信息{}",companyCodeList);
|
|
|
|
|
// }
|
|
|
|
|
List<String> companyCodes = getUserInfo().getCompanyCodes(); |
|
|
|
|
|
|
|
|
|
if (StringHelper.isNotBlank(companyCode) && "99".equals(companyCode)){ |
|
|
|
|
pramsMap.put("companyCodes",companyCodes); |
|
|
|
|
log.info("组织机构====>{}",pramsMap.get("companyCodes")); |
|
|
|
|
} |
|
|
|
|
if (StringUtils.isNotBlank(companyCode)){ |
|
|
|
|
pramsMap.put("companyCode",companyCode); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<String> gfshList = new ArrayList<>(); |
|
|
|
|
if (!"99".equals(gfsh) && StringUtils.isNotBlank(gfsh)) { |
|
|
|
|
gfshList.add(gfsh); |
|
|
|
|
log.info("手工认证有税号"); |
|
|
|
|
} else { |
|
|
|
|
gfshList = getGfshList(gfshList,companyCodes); |
|
|
|
|
log.info("手工认证无税号{}",gfshList); |
|
|
|
|
} |
|
|
|
|
pramsMap.put("gfsh", gfshList); |
|
|
|
|
|
|
|
|
|
if (!StringUtils.isBlank(invoiceType)) { |
|
|
|
|
if (!"99".equals(invoiceType)) { |
|
|
|
|