From 57351e2e19760732ac00225dfa82a2965e1823b5 Mon Sep 17 00:00:00 2001 From: jiazx0107@163.com <jiazx0107@163.com> Date: 星期五, 30 六月 2023 14:32:27 +0800 Subject: [PATCH] 优化出入库信息3 --- igds-inout/src/main/java/com/ld/igds/inout/manager/InoutReportManager.java | 53 ++++++++++++++++++++++++++++++++++++----------------- 1 files changed, 36 insertions(+), 17 deletions(-) diff --git a/igds-inout/src/main/java/com/ld/igds/inout/manager/InoutReportManager.java b/igds-inout/src/main/java/com/ld/igds/inout/manager/InoutReportManager.java index 4abd844..01a5ee0 100644 --- a/igds-inout/src/main/java/com/ld/igds/inout/manager/InoutReportManager.java +++ b/igds-inout/src/main/java/com/ld/igds/inout/manager/InoutReportManager.java @@ -4,13 +4,11 @@ import com.ld.igds.check.dto.CheckItemData; import com.ld.igds.check.service.CoreCheckStandardService; import com.ld.igds.common.CoreCommonService; +import com.ld.igds.common.bar.BarCodeUtils; import com.ld.igds.constant.FoodVariety; import com.ld.igds.inout.InoutBill; import com.ld.igds.inout.InoutConstant; -import com.ld.igds.inout.dto.InoutData; -import com.ld.igds.inout.dto.InoutRecordItemData; -import com.ld.igds.inout.dto.InoutRecordItemParam; -import com.ld.igds.inout.dto.WeightBill; +import com.ld.igds.inout.dto.*; import com.ld.igds.inout.service.InoutRecordItemService; import com.ld.igds.m.dto.NoticeDto; import com.ld.igds.m.service.HInoutNoticeService; @@ -116,6 +114,11 @@ htmlStr = htmlStr.replace("deImpurity", bill.getDeImpurity() + ""); htmlStr = htmlStr.replace("deWet", bill.getDeWet() + ""); + + htmlStr = htmlStr.replace("recordWeight", bill.getRecordWeight() + ""); + htmlStr = htmlStr.replace("deCheck", bill.getDeCheck() + ""); + htmlStr = htmlStr.replace("addCheck", bill.getAddCheck() + ""); + htmlStr = htmlStr.replace("deSum", bill.getDeSum() + ""); htmlStr = htmlStr.replace("settleWeight", new DecimalFormat("0").format(bill.getSettleWeight())); @@ -127,6 +130,7 @@ htmlStr = htmlStr.replace("wet", bill.getWet() + ""); htmlStr = htmlStr.replace("impurity", bill.getImpurity() + ""); + htmlStr = htmlStr.replace("checkStatus", bill.getCheckStatus()); htmlStr = htmlStr.replace("remark", bill.getRemark()); htmlStr = htmlStr.replace("moneyName", bill.getMoneyName()); @@ -261,7 +265,6 @@ bill.setFullTime(DateFormatUtils.format(data.getFullWeightTime(), "yyyy-MM-dd HH:mm:ss")); bill.setSerId(data.getId()); -// bill.setSpecType(StringUtils.isEmpty(data.getSpecType()) ? "鏁g伯" : data.getSpecType()); if ("5016".equals(data.getCompanyId())) { bill.setCompleteTime(DateFormatUtils.format(data.getCompleteTime(), "yyyy-MM-dd")); bill.setSerId(data.getId().substring(2)); @@ -269,7 +272,6 @@ } //瀹㈡埛淇℃伅 - // bill.setCustomerId(data.getCustomerId() == null ? "" : data.getCustomerId()); bill.setCustomerName(data.getCustomerName() == null ? "" : data.getCustomerName()); bill.setUserId(data.getUserId() == null ? "" : data.getUserId()); bill.setUserAddress(data.getUserAddress() == null ? "" : data.getUserAddress()); @@ -300,20 +302,15 @@ bill.setFullWeight(data.getFullWeight()); bill.setEmptyWeight(data.getEmptyWeight()); bill.setNetWeight(data.getNetWeight()); + bill.setDeCheck(data.getDeCheck()); + bill.setAddCheck(data.getAddCheck()); + bill.setRecordWeight(data.getRecordWeight()); + bill.setCheckStatus(data.getCheckStatus().equals(InoutConstant.STATUS_PASS) ? "鍚堟牸" : "涓嶅悎鏍�"); -// bill.setDeWet(data.getDeWet()); -// bill.setDeImpurity(data.getDeImpurity()); -// bill.setDeHandle(data.getDeHandle()); -// bill.setDeOther(data.getDeOther()); -// bill.setDeSum(data.getDeSum() == null ? 0.0 :data.getDeSum()); + bill.setDeHandle(data.getDeHandle()); + bill.setDeOther(data.getDeOther()); bill.setSettleWeight(data.getSettleWeight()); -// if(data.getWet() != null && data.getWet() > 0){ -// bill.setWet(data.getWet() +""); -// } -// if(data.getImpurity() != null && data.getImpurity() > 0){ -// bill.setImpurity(data.getImpurity()+""); -// } bill.setPrice(data.getPrice() == null ? "" : data.getPrice() + ""); if (data.getSettleMoney() <= 0) { @@ -707,6 +704,26 @@ return htmlStr; } + /** + * 鎵撳嵃鎵︽牱鍗曪紝鐩存帴杩斿洖鏉″舰鐮丅ase64鍥剧墖 + * + * @param data + * @return + */ + public String simpleBill(InoutCheckData data) { + + if (null == data.getId()) return null; + if (null == data.getCheckId()) return null; + + if (null == data.getCheckTime()) { + data.setCheckTime(new Date()); + } + + String imgBase64 = BarCodeUtils.getBarCodeImageBase64(data.getId(), data.getCheckId(), "绮簱鎵︽牱鍗曟潯鐮�", DateFormatUtils.format(data.getCheckTime(), "yyyy-MM-dd HH:mm")); + + return imgBase64; + } + public static void main(String[] args) { List<String> result = new ArrayList<>(); result.add("1"); @@ -725,4 +742,6 @@ List<String> strings3 = result.subList(6, 8); System.out.println(strings3); } + + } \ No newline at end of file -- Gitblit v1.9.3