|
|
@@ -364,30 +364,30 @@ public class IVController {
|
|
|
McException.exceptionAccess(serial + "已存在, 请勿重复提交!");
|
|
|
}
|
|
|
// prd 仅仅识别增值税普通发票
|
|
|
- if (dto.getName().contains("普通发票")) {
|
|
|
- String serialTips = serial + "有疑问";
|
|
|
- try {
|
|
|
- // ppExt: 识别与验真后抬头对比 [全电票, 新版本识别接口, 返回名称为: 电子发票(普通发票) 不包含全电标识, 发类型为: 全电发票. 注意取值]
|
|
|
- Map rsp = txyInvoice.doVatInvoiceVerifyNew(dto.getKindName(), dto.getCode(), invoiceNo, dto.getDate(), String.valueOf(dto.getAmount()), dto.getCheckCode(), String.valueOf(dto.getExcludingTax()), serialTips);
|
|
|
- Map invoice = (Map) rsp.get("Invoice");
|
|
|
- McException.assertAccessException(!dto.getBuyerName().equals(guyuanNameRepalce(invoice.get("BuyerName").toString())), serialTips + ", 购买方名称不匹配!");
|
|
|
- McException.assertAccessException(!dto.getBuyerTaxId().equals(invoice.get("BuyerTaxCode")), serialTips + ", 购买方税号不匹配!");
|
|
|
- McException.assertAccessException(!dto.getSellerName().equals(guyuanNameRepalce(invoice.get("SellerName").toString())), serialTips + ", 销售方名称不匹配!");
|
|
|
- McException.assertAccessException(!dto.getSellerTaxId().equals(invoice.get("SellerTaxCode")), serialTips + ", 销售方税号不匹配!");
|
|
|
- } catch (TencentCloudSDKException e) {
|
|
|
- log.error(e.getMessage(), e);
|
|
|
- // prd: 上传发票为假发票时,提示:该发票有疑问,请联系财务人员
|
|
|
- String message = e.getMessage();
|
|
|
- // ppExt: 已经是新版本接口, 过滤提示 [官方答复: 提示不会检测您是否使用的是新版,所有的用户都会提示, 忽略即可]
|
|
|
- if (message.contains("温馨提示")) {
|
|
|
- message = message.split("温馨提示")[0];
|
|
|
- }
|
|
|
- if (message.contains("发票不存在")) {
|
|
|
- message = "有疑问,请联系财务人员";
|
|
|
- }
|
|
|
- McException.exceptionAccess(serial + message);
|
|
|
- }
|
|
|
- }
|
|
|
+// if (dto.getName().contains("普通发票")) {
|
|
|
+// String serialTips = serial + "有疑问";
|
|
|
+// try {
|
|
|
+// // ppExt: 识别与验真后抬头对比 [全电票, 新版本识别接口, 返回名称为: 电子发票(普通发票) 不包含全电标识, 发类型为: 全电发票. 注意取值]
|
|
|
+// Map rsp = txyInvoice.doVatInvoiceVerifyNew(dto.getKindName(), dto.getCode(), invoiceNo, dto.getDate(), String.valueOf(dto.getAmount()), dto.getCheckCode(), String.valueOf(dto.getExcludingTax()), serialTips);
|
|
|
+// Map invoice = (Map) rsp.get("Invoice");
|
|
|
+// McException.assertAccessException(!dto.getBuyerName().equals(guyuanNameRepalce(invoice.get("BuyerName").toString())), serialTips + ", 购买方名称不匹配!");
|
|
|
+// McException.assertAccessException(!dto.getBuyerTaxId().equals(invoice.get("BuyerTaxCode")), serialTips + ", 购买方税号不匹配!");
|
|
|
+// McException.assertAccessException(!dto.getSellerName().equals(guyuanNameRepalce(invoice.get("SellerName").toString())), serialTips + ", 销售方名称不匹配!");
|
|
|
+// McException.assertAccessException(!dto.getSellerTaxId().equals(invoice.get("SellerTaxCode")), serialTips + ", 销售方税号不匹配!");
|
|
|
+// } catch (TencentCloudSDKException e) {
|
|
|
+// log.error(e.getMessage(), e);
|
|
|
+// // prd: 上传发票为假发票时,提示:该发票有疑问,请联系财务人员
|
|
|
+// String message = e.getMessage();
|
|
|
+// // ppExt: 已经是新版本接口, 过滤提示 [官方答复: 提示不会检测您是否使用的是新版,所有的用户都会提示, 忽略即可]
|
|
|
+// if (message.contains("温馨提示")) {
|
|
|
+// message = message.split("温馨提示")[0];
|
|
|
+// }
|
|
|
+// if (message.contains("发票不存在")) {
|
|
|
+// message = "有疑问,请联系财务人员";
|
|
|
+// }
|
|
|
+// McException.exceptionAccess(serial + message);
|
|
|
+// }
|
|
|
+// }
|
|
|
}));
|
|
|
return McR.success();
|
|
|
}
|