From e4d88a0d0ed7d9d2a4616a81db061323e2edad00 Mon Sep 17 00:00:00 2001 From: e Date: Tue, 18 Sep 2018 07:34:15 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=89=E6=96=B9=E5=AE=A2=E6=88=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../web/system/sms/util/task/SmsSendTask.java | 26 ++++++++++++++----- .../webpage/com/zzjee/wm/wmToUpGoodsList.jsp | 4 ++- 2 files changed, 23 insertions(+), 7 deletions(-) diff --git a/src/main/java/org/jeecgframework/web/system/sms/util/task/SmsSendTask.java b/src/main/java/org/jeecgframework/web/system/sms/util/task/SmsSendTask.java index 94c72d31..5059ab66 100644 --- a/src/main/java/org/jeecgframework/web/system/sms/util/task/SmsSendTask.java +++ b/src/main/java/org/jeecgframework/web/system/sms/util/task/SmsSendTask.java @@ -485,7 +485,13 @@ public class SmsSendTask { System.out.print(tsql); if (resultt != null && resultt.size() > 0) { - String goodprodata = resultt.get(0).get("goods_pro_data").toString(); + String goodprodata = null; + try{ + goodprodata = resultt.get(0).get("goods_pro_data").toString(); + + }catch (Exception e){ + + } String hiti = "0"; try { hiti = Long.toString(Long.parseLong(mvgoods.getMpCengGao()) * Long.parseLong(mvgoods.getMpDanCeng()) * Long.parseLong(mvgoods.getChlShl())); @@ -503,17 +509,22 @@ public class SmsSendTask { tsqlz = tsqlz + " and ws.goods_id = ? " - + " and ws.cus_code = ? " - + " and ws.goods_pro_data = ? " + + " and ws.cus_code = ? "; + if(StringUtil.isEmpty(goodprodata)){ + tsqlz = tsqlz + + " and ws.goods_pro_data = '"+ goodprodata +"'"; + } + + tsqlz = tsqlz + " and (ws.base_goodscount + 0) = ? " + " group by ws.ku_wei_bian_ma,ws.bin_id,ws.goods_id,mb.qu_huo_ci_xu, ws.goods_pro_data having sum(ws.base_goodscount) > 0 order by ws.goods_pro_data , ws.goods_qua ,mb.qu_huo_ci_xu,ws.create_date desc"; List> resultz = systemService - .findForJdbc(tsqlz, mvgoods.getGoodsId(), wmOmQmIEntity.getCusCode(), goodprodata, hiti); + .findForJdbc(tsqlz, mvgoods.getGoodsId(), wmOmQmIEntity.getCusCode(), hiti); System.out.print("****************tsqlz" + tsqlz); if (resultz != null && resultz.size() > 0) { for (int i = 0; i < resultz.size(); i++) { - + try{ Long bin_qua = Long.valueOf(resultz.get(i) .get("goods_qua").toString()); if (omcountwq >= bin_qua && omcountwq > 0) { @@ -576,7 +587,10 @@ public class SmsSendTask { systemService.save(wmOmQmIEntity); } - } + }catch (Exception e){ + + } + } } } } diff --git a/src/main/webapp/webpage/com/zzjee/wm/wmToUpGoodsList.jsp b/src/main/webapp/webpage/com/zzjee/wm/wmToUpGoodsList.jsp index 81f1fe22..dc087b3e 100644 --- a/src/main/webapp/webpage/com/zzjee/wm/wmToUpGoodsList.jsp +++ b/src/main/webapp/webpage/com/zzjee/wm/wmToUpGoodsList.jsp @@ -14,7 +14,9 @@ - + + +