|
|
|
@ -1,5 +1,6 @@ |
|
|
|
|
package com.dxhy.erp.controller; |
|
|
|
|
|
|
|
|
|
import com.alibaba.fastjson.JSON; |
|
|
|
|
import com.alibaba.fastjson.JSONArray; |
|
|
|
|
import com.alibaba.fastjson.JSONObject; |
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
@ -381,7 +382,6 @@ public class SDNYMainProcessController extends AbstractController { |
|
|
|
|
|
|
|
|
|
R data = new R(1000, "default success"); |
|
|
|
|
data.put("message", "success"); |
|
|
|
|
data.put("data", checkInvoiceResult); |
|
|
|
|
|
|
|
|
|
if (!checkInvoiceResult.containsKey("cyjg")) { |
|
|
|
|
|
|
|
|
@ -397,6 +397,17 @@ public class SDNYMainProcessController extends AbstractController { |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
Object o = checkInvoiceResult.get("invoiceLineList"); |
|
|
|
|
JSONArray jsonArray = JSONObject.parseArray(JSONObject.toJSONString(o)); |
|
|
|
|
for (Object object : jsonArray) { |
|
|
|
|
Map map = JSONObject.parseObject(JSONObject.toJSONString(object), Map.class); |
|
|
|
|
String taxRate = (String) map.get("taxRate"); |
|
|
|
|
if ("0".equals(taxRate) || "*".equals(taxRate) || "**".equals(taxRate) || "***".equals(taxRate) || "不征税".equals(taxRate) || "免税".equals(taxRate)) { |
|
|
|
|
map.put("taxRate","0.00"); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
data.put("data", checkInvoiceResult); |
|
|
|
|
|
|
|
|
|
return ResponseEntity.ok(JSONObject.toJSONString(data)); |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|