master
parent
b026072ff6
commit
1b09ddb741
|
@ -215,7 +215,7 @@ public class yyUtil {
|
||||||
wmi.setGoodsName(mvgoods.getGoodsName());
|
wmi.setGoodsName(mvgoods.getGoodsName());
|
||||||
wmi.setGoodsUnit(mvgoods.getShlDanWei());
|
wmi.setGoodsUnit(mvgoods.getShlDanWei());
|
||||||
}
|
}
|
||||||
wmi.setGoodsCount(Double.toString(new BigDecimal(proddet.get("iQuantity").toString()).setScale(2, RoundingMode.UP).doubleValue()));
|
wmi.setGoodsCount(Long.toString(new BigDecimal(proddet.get("iQuantity").toString()).setScale(0, RoundingMode.UP).longValue()));
|
||||||
// wmi.setGoodsPrdData(billResult.getData().get(s).getDetail().get(k).getPdProdmadedate2User());
|
// wmi.setGoodsPrdData(billResult.getData().get(s).getDetail().get(k).getPdProdmadedate2User());
|
||||||
// wmi.setOtherId();
|
// wmi.setOtherId();
|
||||||
wmImNoticeIListnew.add(wmi);
|
wmImNoticeIListnew.add(wmi);
|
||||||
|
@ -279,7 +279,7 @@ public class yyUtil {
|
||||||
wmi.setGoodsName(mvgoods.getGoodsName());
|
wmi.setGoodsName(mvgoods.getGoodsName());
|
||||||
wmi.setGoodsUnit(mvgoods.getShlDanWei());
|
wmi.setGoodsUnit(mvgoods.getShlDanWei());
|
||||||
}
|
}
|
||||||
wmi.setGoodsQua(Double.toString(new BigDecimal(proddet.get("iQuantity").toString()).setScale(0, RoundingMode.UP).doubleValue()));
|
wmi.setGoodsQua(Long.toString(new BigDecimal(proddet.get("iQuantity").toString()).setScale(0, RoundingMode.UP).longValue()));
|
||||||
wmomNoticeIListnew.add(wmi);
|
wmomNoticeIListnew.add(wmi);
|
||||||
}
|
}
|
||||||
wmOmNoticeHService.addMain(wmOmNoticeH, wmomNoticeIListnew);
|
wmOmNoticeHService.addMain(wmOmNoticeH, wmomNoticeIListnew);
|
||||||
|
|
|
@ -25,12 +25,12 @@ import com.zzjee.wm.entity.WmToMoveGoodsEntity;
|
||||||
import com.zzjee.wm.entity.WmToUpGoodsEntity;
|
import com.zzjee.wm.entity.WmToUpGoodsEntity;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @ClassName:SmsSendTask 所有信息的发送定时任务类
|
* @ClassName:SmsSendTask 所有信息的发送定时任务类
|
||||||
* @Description: TODO
|
* @Description: TODO
|
||||||
* @author Comsys-skyCc cmzcheng@gmail.com
|
* @author Comsys-skyCc cmzcheng@gmail.com
|
||||||
* @date 2014-11-13 下午5:06:34
|
* @date 2014-11-13 下午5:06:34
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
@Service("smsSendTask")
|
@Service("smsSendTask")
|
||||||
public class SmsSendTask {
|
public class SmsSendTask {
|
||||||
|
@ -43,10 +43,10 @@ public class SmsSendTask {
|
||||||
/* @Scheduled(cron="0 0/1 * * * ?") */
|
/* @Scheduled(cron="0 0/1 * * * ?") */
|
||||||
public void run() {
|
public void run() {
|
||||||
long start = System.currentTimeMillis();
|
long start = System.currentTimeMillis();
|
||||||
String run = ResourceUtil.getConfigByName("timerun");
|
String run = ResourceUtil.getConfigByName("timerun");
|
||||||
if(!run.equals("run")){
|
if(!run.equals("run")){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
org.jeecgframework.core.util.LogUtil
|
org.jeecgframework.core.util.LogUtil
|
||||||
.info("===================消息中间件定时任务开始===================");
|
.info("===================消息中间件定时任务开始===================");
|
||||||
try {//发送消息
|
try {//发送消息
|
||||||
|
@ -77,7 +77,7 @@ public class SmsSendTask {
|
||||||
|
|
||||||
WmInQmlist = systemService.findHql(hql, new Object[] { "N" });
|
WmInQmlist = systemService.findHql(hql, new Object[] { "N" });
|
||||||
for (WmInQmIEntity wmInQmIEntity : WmInQmlist) {
|
for (WmInQmIEntity wmInQmIEntity : WmInQmlist) {
|
||||||
|
|
||||||
if(wmInQmIEntity.getImNoticeId().startsWith("YK")){//越库任务
|
if(wmInQmIEntity.getImNoticeId().startsWith("YK")){//越库任务
|
||||||
wmInQmIEntity.setBinId(wmInQmIEntity.getImNoticeId());
|
wmInQmIEntity.setBinId(wmInQmIEntity.getImNoticeId());
|
||||||
wmInQmIEntity.setBinSta("Y");
|
wmInQmIEntity.setBinSta("Y");
|
||||||
|
@ -91,17 +91,17 @@ public class SmsSendTask {
|
||||||
if(wmInQmIEntity.getTinTj()==null){
|
if(wmInQmIEntity.getTinTj()==null){
|
||||||
wmInQmIEntity.setTinTj("0");
|
wmInQmIEntity.setTinTj("0");
|
||||||
}
|
}
|
||||||
String zuidatiji = null;
|
String zuidatiji = null;
|
||||||
try {
|
try {
|
||||||
if(StringUtil.isEmpty( wmInQmIEntity.getTinTj())){
|
if(StringUtil.isEmpty( wmInQmIEntity.getTinTj())){
|
||||||
zuidatiji = "1";
|
zuidatiji = "1";
|
||||||
}else{
|
}else{
|
||||||
zuidatiji = wmInQmIEntity.getTinTj();
|
zuidatiji = wmInQmIEntity.getTinTj();
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
zuidatiji = "1";
|
zuidatiji = "1";
|
||||||
}
|
}
|
||||||
|
|
||||||
sql = "select binid from wv_avabin where ku_wei_lei_xing <> '不良品区' and zui_da_ti_ji >"
|
sql = "select binid from wv_avabin where ku_wei_lei_xing <> '不良品区' and zui_da_ti_ji >"
|
||||||
+ zuidatiji
|
+ zuidatiji
|
||||||
+ " and ku_wei_shu_xing = (select cf_wen_ceng from mv_goods where goods_code = '"
|
+ " and ku_wei_shu_xing = (select cf_wen_ceng from mv_goods where goods_code = '"
|
||||||
|
@ -116,7 +116,7 @@ public class SmsSendTask {
|
||||||
+ "order by suo_shu_ke_hu desc, shang_jia_ci_xu,binid limit 1";
|
+ "order by suo_shu_ke_hu desc, shang_jia_ci_xu,binid limit 1";
|
||||||
binMap = systemService.findOneForJdbc(sql);
|
binMap = systemService.findOneForJdbc(sql);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (binMap != null) {
|
if (binMap != null) {
|
||||||
wmInQmIEntity.setBinId(binMap.get("binid").toString());
|
wmInQmIEntity.setBinId(binMap.get("binid").toString());
|
||||||
systemService.updateEntitie(wmInQmIEntity);
|
systemService.updateEntitie(wmInQmIEntity);
|
||||||
|
@ -132,7 +132,7 @@ public class SmsSendTask {
|
||||||
MvGoodsEntity.class, "goodsCode",
|
MvGoodsEntity.class, "goodsCode",
|
||||||
wmInQmIEntity.getGoodsId());
|
wmInQmIEntity.getGoodsId());
|
||||||
wmInQmIEntity.setBaseUnit(mvgoods.getBaseunit());
|
wmInQmIEntity.setBaseUnit(mvgoods.getBaseunit());
|
||||||
if (!mvgoods.getBaseunit().equals(mvgoods.getShlDanWei())) {
|
if (!mvgoods.getBaseunit().equals(mvgoods.getShlDanWei())) {
|
||||||
try {
|
try {
|
||||||
wmInQmIEntity.setBaseGoodscount(String.valueOf(Long
|
wmInQmIEntity.setBaseGoodscount(String.valueOf(Long
|
||||||
.parseLong(mvgoods.getChlShl())
|
.parseLong(mvgoods.getChlShl())
|
||||||
|
@ -140,10 +140,10 @@ public class SmsSendTask {
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
// TODO: handle exception
|
// TODO: handle exception
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
wmInQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
wmInQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
||||||
.getZhlKg()) * Long.parseLong(wmInQmIEntity.getQmOkQuat())));
|
.getZhlKg()) * Long.parseLong(wmInQmIEntity.getQmOkQuat())));
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
// TODO: handle exception
|
// TODO: handle exception
|
||||||
}
|
}
|
||||||
|
@ -234,8 +234,8 @@ public class SmsSendTask {
|
||||||
}
|
}
|
||||||
|
|
||||||
// 更新下架商品基本单位基本数量
|
// 更新下架商品基本单位基本数量
|
||||||
|
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
// TODO: handle exception
|
// TODO: handle exception
|
||||||
}
|
}
|
||||||
|
@ -244,7 +244,7 @@ public class SmsSendTask {
|
||||||
List<WmToMoveGoodsEntity> WmToMoveGoodslist = new ArrayList<WmToMoveGoodsEntity>();
|
List<WmToMoveGoodsEntity> WmToMoveGoodslist = new ArrayList<WmToMoveGoodsEntity>();
|
||||||
hql = "from WmToMoveGoodsEntity t where t.orderId is null and t.moveSta = '已完成' ";
|
hql = "from WmToMoveGoodsEntity t where t.orderId is null and t.moveSta = '已完成' ";
|
||||||
WmToMoveGoodslist = systemService.findByQueryString(hql);
|
WmToMoveGoodslist = systemService.findByQueryString(hql);
|
||||||
|
|
||||||
for (WmToMoveGoodsEntity wmToMoveGoodsEntity : WmToMoveGoodslist) {
|
for (WmToMoveGoodsEntity wmToMoveGoodsEntity : WmToMoveGoodslist) {
|
||||||
if(!wmUtil.checkstcok(wmToMoveGoodsEntity.getBinFrom(),wmToMoveGoodsEntity.getTinFrom(),wmToMoveGoodsEntity.getGoodsId(),wmToMoveGoodsEntity.getGoodsProData(),wmToMoveGoodsEntity.getGoodsQua())){
|
if(!wmUtil.checkstcok(wmToMoveGoodsEntity.getBinFrom(),wmToMoveGoodsEntity.getTinFrom(),wmToMoveGoodsEntity.getGoodsId(),wmToMoveGoodsEntity.getGoodsProData(),wmToMoveGoodsEntity.getGoodsQua())){
|
||||||
wmToMoveGoodsEntity.setMoveSta("库存不足");
|
wmToMoveGoodsEntity.setMoveSta("库存不足");
|
||||||
|
@ -284,11 +284,11 @@ public class SmsSendTask {
|
||||||
MvGoodsEntity.class, "goodsCode",
|
MvGoodsEntity.class, "goodsCode",
|
||||||
wmToMoveGoodsEntity.getGoodsId());
|
wmToMoveGoodsEntity.getGoodsId());
|
||||||
wmToDownGoods.setGoodsName(mvgoods.getGoodsName());
|
wmToDownGoods.setGoodsName(mvgoods.getGoodsName());
|
||||||
if(StringUtil.isEmpty(wmToMoveGoodsEntity.getBaseGoodscount())){
|
if(StringUtil.isEmpty(wmToMoveGoodsEntity.getBaseGoodscount())){
|
||||||
wmToDownGoods.setBaseGoodscount(wmToMoveGoodsEntity.getGoodsQua());
|
wmToDownGoods.setBaseGoodscount(wmToMoveGoodsEntity.getGoodsQua());
|
||||||
}else{
|
}else{
|
||||||
wmToDownGoods.setBaseGoodscount(wmToMoveGoodsEntity.getBaseGoodscount());
|
wmToDownGoods.setBaseGoodscount(wmToMoveGoodsEntity.getBaseGoodscount());
|
||||||
}
|
}
|
||||||
wmToDownGoods.setBaseUnit(mvgoods.getBaseunit());//基本单位
|
wmToDownGoods.setBaseUnit(mvgoods.getBaseunit());//基本单位
|
||||||
wmToDownGoods.setGoodsUnit(wmToMoveGoodsEntity.getGoodsUnit());//出货单位
|
wmToDownGoods.setGoodsUnit(wmToMoveGoodsEntity.getGoodsUnit());//出货单位
|
||||||
wmToDownGoods.setGoodsQua(wmToMoveGoodsEntity.getGoodsQua());//出货数量
|
wmToDownGoods.setGoodsQua(wmToMoveGoodsEntity.getGoodsQua());//出货数量
|
||||||
|
@ -324,7 +324,7 @@ public class SmsSendTask {
|
||||||
wmToUpGoodsEntity.setBinId(wmToMoveGoodsEntity.getTinId());
|
wmToUpGoodsEntity.setBinId(wmToMoveGoodsEntity.getTinId());
|
||||||
wmToUpGoodsEntity.setKuWeiBianMa(wmToMoveGoodsEntity.getBinTo());
|
wmToUpGoodsEntity.setKuWeiBianMa(wmToMoveGoodsEntity.getBinTo());
|
||||||
wmToUpGoodsEntity.setCusCode(wmToMoveGoodsEntity.getToCusCode());
|
wmToUpGoodsEntity.setCusCode(wmToMoveGoodsEntity.getToCusCode());
|
||||||
wmToUpGoodsEntity.setActTypeCode("ZY");
|
wmToUpGoodsEntity.setActTypeCode("ZY");
|
||||||
systemService.save(wmToUpGoodsEntity);
|
systemService.save(wmToUpGoodsEntity);
|
||||||
if(!StringUtil.isNotEmpty(wmToMoveGoodsEntity.getOrderTypeCode())){
|
if(!StringUtil.isNotEmpty(wmToMoveGoodsEntity.getOrderTypeCode())){
|
||||||
wmToMoveGoodsEntity.setOrderTypeCode("KCZY");
|
wmToMoveGoodsEntity.setOrderTypeCode("KCZY");
|
||||||
|
@ -335,8 +335,8 @@ public class SmsSendTask {
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
// TODO: handle exception
|
// TODO: handle exception
|
||||||
}
|
}
|
||||||
this.rundowntask();//下架任务
|
this.rundowntask();//下架任务
|
||||||
org.jeecgframework.core.util.LogUtil
|
org.jeecgframework.core.util.LogUtil
|
||||||
.info("===================消息中间件定时任务结束===================");
|
.info("===================消息中间件定时任务结束===================");
|
||||||
long end = System.currentTimeMillis();
|
long end = System.currentTimeMillis();
|
||||||
long times = end - start;
|
long times = end - start;
|
||||||
|
@ -345,7 +345,7 @@ public class SmsSendTask {
|
||||||
public void rundowntask() {
|
public void rundowntask() {
|
||||||
try {// 生成下架任务
|
try {// 生成下架任务
|
||||||
List<WmOmNoticeIEntity> WmOmNoticeIlist = new ArrayList<WmOmNoticeIEntity>();
|
List<WmOmNoticeIEntity> WmOmNoticeIlist = new ArrayList<WmOmNoticeIEntity>();
|
||||||
String hql = "from WmOmNoticeIEntity t where t.planSta = 'N' order by goodsId ,omNoticeId";
|
String hql = "from WmOmNoticeIEntity t where t.planSta = 'N' order by goodsId ,omNoticeId";
|
||||||
WmOmNoticeIlist = systemService.findByQueryString(hql);
|
WmOmNoticeIlist = systemService.findByQueryString(hql);
|
||||||
String usetuopan = ResourceUtil.getConfigByName("usetuopan");
|
String usetuopan = ResourceUtil.getConfigByName("usetuopan");
|
||||||
String prodate = null;
|
String prodate = null;
|
||||||
|
@ -362,8 +362,8 @@ public class SmsSendTask {
|
||||||
prodate= DateUtils.date2Str(wmOmNoticeIEntity.getGoodsProData(),DateUtils.date_sdf);
|
prodate= DateUtils.date2Str(wmOmNoticeIEntity.getGoodsProData(),DateUtils.date_sdf);
|
||||||
}
|
}
|
||||||
if(StringUtil.isNotEmpty(wmOmNoticeIEntity.getBinId())){
|
if(StringUtil.isNotEmpty(wmOmNoticeIEntity.getBinId())){
|
||||||
tuopanma = wmOmNoticeIEntity.getBinId();
|
tuopanma = wmOmNoticeIEntity.getBinId();
|
||||||
}else{
|
}else{
|
||||||
if("no".equals(usetuopan)){
|
if("no".equals(usetuopan)){
|
||||||
tuopanma = ResourceUtil.getConfigByName("tuopanma");
|
tuopanma = ResourceUtil.getConfigByName("tuopanma");
|
||||||
}else{
|
}else{
|
||||||
|
@ -578,136 +578,136 @@ public class SmsSendTask {
|
||||||
.findForJdbc(tsql, mvgoods.getGoodsId(), wmOmQmIEntity.getCusCode());
|
.findForJdbc(tsql, mvgoods.getGoodsId(), wmOmQmIEntity.getCusCode());
|
||||||
if (result != null && result.size() > 0) {
|
if (result != null && result.size() > 0) {
|
||||||
for (int i = 0; i < result.size(); i++) {
|
for (int i = 0; i < result.size(); i++) {
|
||||||
try {
|
try {
|
||||||
Long bin_qua = Long.valueOf(result.get(i)
|
Long bin_qua = Long.valueOf(result.get(i)
|
||||||
.get("goods_qua").toString());
|
.get("goods_qua").toString());
|
||||||
if (bin_qua > 0 && omcountwq > 0) {
|
if (bin_qua > 0 && omcountwq > 0) {
|
||||||
if (omcountwq > bin_qua) {
|
if (omcountwq > bin_qua) {
|
||||||
wmOmQmIEntity.setBinId(result.get(i)
|
wmOmQmIEntity.setBinId(result.get(i)
|
||||||
.get("ku_wei_bian_ma").toString());
|
.get("ku_wei_bian_ma").toString());
|
||||||
wmOmQmIEntity.setTinId(result.get(i)
|
wmOmQmIEntity.setTinId(result.get(i)
|
||||||
.get("bin_id").toString());
|
.get("bin_id").toString());
|
||||||
wmOmQmIEntity.setBaseUnit(result.get(i)
|
wmOmQmIEntity.setBaseUnit(result.get(i)
|
||||||
.get("base_unit").toString());
|
.get("base_unit").toString());
|
||||||
wmOmQmIEntity
|
wmOmQmIEntity
|
||||||
.setBaseGoodscount(result.get(i)
|
.setBaseGoodscount(result.get(i)
|
||||||
.get("goods_qua")
|
.get("goods_qua")
|
||||||
.toString());
|
.toString());
|
||||||
wmOmQmIEntity.setProData(result.get(i)
|
wmOmQmIEntity.setProData(result.get(i)
|
||||||
.get("goods_pro_data").toString());
|
.get("goods_pro_data").toString());
|
||||||
wmOmQmIEntity.setCusName(result.get(i)
|
wmOmQmIEntity.setCusName(result.get(i)
|
||||||
.get("zhong_wen_qch").toString());
|
.get("zhong_wen_qch").toString());
|
||||||
wmOmQmIEntity.setGoodsName(result.get(i)
|
wmOmQmIEntity.setGoodsName(result.get(i)
|
||||||
.get("shp_ming_cheng").toString());
|
.get("shp_ming_cheng").toString());
|
||||||
omcountwq = omcountwq - bin_qua;
|
omcountwq = omcountwq - bin_qua;
|
||||||
if (wmOmNoticeIEntity.getGoodsUnit()
|
if (wmOmNoticeIEntity.getGoodsUnit()
|
||||||
.equals(wmOmNoticeIEntity
|
.equals(wmOmNoticeIEntity
|
||||||
.getBaseUnit())) {
|
.getBaseUnit())) {
|
||||||
wmOmQmIEntity.setQmOkQuat(Long.toString(bin_qua));
|
wmOmQmIEntity.setQmOkQuat(Long.toString(bin_qua));
|
||||||
try {
|
try {
|
||||||
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
||||||
.getTiJiCm()) / Double.parseDouble(mvgoods
|
.getTiJiCm()) / Double.parseDouble(mvgoods
|
||||||
.getChlShl())
|
.getChlShl())
|
||||||
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
||||||
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
||||||
.getZhlKg()) / Double.parseDouble(mvgoods
|
.getZhlKg()) / Double.parseDouble(mvgoods
|
||||||
.getChlShl())
|
.getChlShl())
|
||||||
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
// TODO: handle exception
|
// TODO: handle exception
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
|
||||||
|
try {
|
||||||
|
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
||||||
|
.getTiJiCm())
|
||||||
|
* Long.parseLong(wmOmQmIEntity.getQmOkQuat()) / Long.parseLong(mvgoods
|
||||||
|
.getChlShl())));
|
||||||
|
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
||||||
|
.getZhlKg())
|
||||||
|
* Long.parseLong(wmOmQmIEntity.getQmOkQuat()) / Long.parseLong(mvgoods
|
||||||
|
.getChlShl())));
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO: handle exception
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
|
||||||
|
wmOmQmIEntity
|
||||||
|
.setQmOkQuat(Long.toString(bin_qua
|
||||||
|
));
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO: handle exception
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
systemService.save(wmOmQmIEntity);
|
||||||
} else {
|
} else {
|
||||||
|
wmOmQmIEntity.setBinId(result.get(i)
|
||||||
|
.get("ku_wei_bian_ma").toString());
|
||||||
|
wmOmQmIEntity.setTinId(result.get(i)
|
||||||
|
.get("bin_id").toString());
|
||||||
|
wmOmQmIEntity.setBaseUnit(result.get(i)
|
||||||
|
.get("base_unit").toString());
|
||||||
|
wmOmQmIEntity.setBaseGoodscount(Long
|
||||||
|
.toString(omcountwq));
|
||||||
|
wmOmQmIEntity.setProData(result.get(i)
|
||||||
|
.get("goods_pro_data").toString());
|
||||||
|
wmOmQmIEntity.setCusName(result.get(i)
|
||||||
|
.get("zhong_wen_qch").toString());
|
||||||
|
wmOmQmIEntity.setGoodsName(result.get(i)
|
||||||
|
.get("shp_ming_cheng").toString());
|
||||||
|
if (wmOmNoticeIEntity.getGoodsUnit()
|
||||||
|
.equals(wmOmNoticeIEntity
|
||||||
|
.getBaseUnit())) {
|
||||||
|
wmOmQmIEntity.setQmOkQuat(Long.toString(omcountwq));
|
||||||
|
try {
|
||||||
|
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
||||||
|
.getTiJiCm()) / Double.parseDouble(mvgoods
|
||||||
|
.getChlShl())
|
||||||
|
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
||||||
|
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
||||||
|
.getZhlKg()) / Double.parseDouble(mvgoods
|
||||||
|
.getChlShl())
|
||||||
|
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO: handle exception
|
||||||
|
}
|
||||||
|
|
||||||
try {
|
} else {
|
||||||
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
|
||||||
.getTiJiCm())
|
try {
|
||||||
* Long.parseLong(wmOmQmIEntity.getQmOkQuat()) / Long.parseLong(mvgoods
|
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
||||||
.getChlShl())));
|
.getTiJiCm())
|
||||||
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
* omcountwq / Long.parseLong(mvgoods
|
||||||
.getZhlKg())
|
.getChlShl())));
|
||||||
* Long.parseLong(wmOmQmIEntity.getQmOkQuat()) / Long.parseLong(mvgoods
|
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
||||||
.getChlShl())));
|
.getZhlKg())
|
||||||
} catch (Exception e) {
|
* omcountwq / Long.parseLong(mvgoods
|
||||||
// TODO: handle exception
|
.getChlShl())));
|
||||||
}
|
} catch (Exception e) {
|
||||||
try {
|
// TODO: handle exception
|
||||||
|
}
|
||||||
wmOmQmIEntity
|
|
||||||
.setQmOkQuat(Long.toString(bin_qua
|
|
||||||
));
|
try {
|
||||||
|
|
||||||
} catch (Exception e) {
|
wmOmQmIEntity
|
||||||
// TODO: handle exception
|
.setQmOkQuat(Long.toString(omcountwq));
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO: handle exception
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
systemService.save(wmOmQmIEntity);
|
||||||
|
wmOmNoticeIEntity.setPlanSta("Y");
|
||||||
|
systemService
|
||||||
|
.saveOrUpdate(wmOmNoticeIEntity);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
systemService.save(wmOmQmIEntity);
|
|
||||||
} else {
|
|
||||||
wmOmQmIEntity.setBinId(result.get(i)
|
|
||||||
.get("ku_wei_bian_ma").toString());
|
|
||||||
wmOmQmIEntity.setTinId(result.get(i)
|
|
||||||
.get("bin_id").toString());
|
|
||||||
wmOmQmIEntity.setBaseUnit(result.get(i)
|
|
||||||
.get("base_unit").toString());
|
|
||||||
wmOmQmIEntity.setBaseGoodscount(Long
|
|
||||||
.toString(omcountwq));
|
|
||||||
wmOmQmIEntity.setProData(result.get(i)
|
|
||||||
.get("goods_pro_data").toString());
|
|
||||||
wmOmQmIEntity.setCusName(result.get(i)
|
|
||||||
.get("zhong_wen_qch").toString());
|
|
||||||
wmOmQmIEntity.setGoodsName(result.get(i)
|
|
||||||
.get("shp_ming_cheng").toString());
|
|
||||||
if (wmOmNoticeIEntity.getGoodsUnit()
|
|
||||||
.equals(wmOmNoticeIEntity
|
|
||||||
.getBaseUnit())) {
|
|
||||||
wmOmQmIEntity.setQmOkQuat(Long.toString(omcountwq));
|
|
||||||
try {
|
|
||||||
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
|
||||||
.getTiJiCm()) / Double.parseDouble(mvgoods
|
|
||||||
.getChlShl())
|
|
||||||
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
|
||||||
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
|
||||||
.getZhlKg()) / Double.parseDouble(mvgoods
|
|
||||||
.getChlShl())
|
|
||||||
* Long.parseLong(wmOmQmIEntity.getQmOkQuat())));
|
|
||||||
} catch (Exception e) {
|
|
||||||
// TODO: handle exception
|
|
||||||
}
|
|
||||||
|
|
||||||
} else {
|
|
||||||
|
|
||||||
try {
|
|
||||||
wmOmQmIEntity.setTinTj(String.valueOf(Double.parseDouble(mvgoods
|
|
||||||
.getTiJiCm())
|
|
||||||
* omcountwq / Long.parseLong(mvgoods
|
|
||||||
.getChlShl())));
|
|
||||||
wmOmQmIEntity.setTinZhl(String.valueOf(Double.parseDouble(mvgoods
|
|
||||||
.getZhlKg())
|
|
||||||
* omcountwq / Long.parseLong(mvgoods
|
|
||||||
.getChlShl())));
|
|
||||||
} catch (Exception e) {
|
|
||||||
// TODO: handle exception
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
try {
|
|
||||||
|
|
||||||
wmOmQmIEntity
|
|
||||||
.setQmOkQuat(Long.toString(omcountwq));
|
|
||||||
|
|
||||||
} catch (Exception e) {
|
|
||||||
// TODO: handle exception
|
|
||||||
}
|
|
||||||
}
|
|
||||||
systemService.save(wmOmQmIEntity);
|
|
||||||
wmOmNoticeIEntity.setPlanSta("Y");
|
|
||||||
systemService
|
|
||||||
.saveOrUpdate(wmOmNoticeIEntity);
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}catch (Exception e){
|
||||||
}catch (Exception e){
|
|
||||||
|
|
||||||
}
|
}
|
||||||
//catch jieshu
|
//catch jieshu
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -723,7 +723,7 @@ public class SmsSendTask {
|
||||||
catch (Exception e){
|
catch (Exception e){
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
// TODO: handle exception
|
// TODO: handle exception
|
||||||
|
|
|
@ -85,7 +85,7 @@
|
||||||
}else{
|
}else{
|
||||||
var url = "mdGoodsController.do?doGet&formDate="+batchdate;
|
var url = "mdGoodsController.do?doGet&formDate="+batchdate;
|
||||||
$.ajax({
|
$.ajax({
|
||||||
async : false,
|
async : true,
|
||||||
cache : false,
|
cache : false,
|
||||||
type : 'POST',
|
type : 'POST',
|
||||||
url : url,// 请求的action路径
|
url : url,// 请求的action路径
|
||||||
|
|
|
@ -8,6 +8,7 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
|
||||||
import static org.springframework.test.web.servlet.setup.MockMvcBuilders.webAppContextSetup;
|
import static org.springframework.test.web.servlet.setup.MockMvcBuilders.webAppContextSetup;
|
||||||
|
|
||||||
import com.zzjee.wmutil.uasUtil;
|
import com.zzjee.wmutil.uasUtil;
|
||||||
|
import com.zzjee.wmutil.yyUtil;
|
||||||
import org.jeecgframework.AbstractUnitTest;
|
import org.jeecgframework.AbstractUnitTest;
|
||||||
import org.jeecgframework.core.util.DateUtils;
|
import org.jeecgframework.core.util.DateUtils;
|
||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
|
@ -39,19 +40,20 @@ public class ControllerTestDemo extends AbstractUnitTest{
|
||||||
//测试登录
|
//测试登录
|
||||||
@Test
|
@Test
|
||||||
public void testLogin() throws Exception {
|
public void testLogin() throws Exception {
|
||||||
Map<String, Object> paramMap = new HashMap<String, Object>();
|
yyUtil.getProduct();
|
||||||
paramMap.put("formDate","2017-01-01");
|
// Map<String, Object> paramMap = new HashMap<String, Object>();
|
||||||
paramMap.put("lastUpdateTime","2017-01-01");
|
// paramMap.put("formDate","2017-01-01");
|
||||||
paramMap.put("pi_class","采购验收单");
|
// paramMap.put("lastUpdateTime","2017-01-01");
|
||||||
uasUtil.getProduct(paramMap);
|
// paramMap.put("pi_class","采购验收单");
|
||||||
|
// uasUtil.getProduct(paramMap);
|
||||||
uasUtil.getCustomer(paramMap);
|
//
|
||||||
|
// uasUtil.getCustomer(paramMap);
|
||||||
uasUtil.getVendor(paramMap);
|
//
|
||||||
|
// uasUtil.getVendor(paramMap);
|
||||||
uasUtil.getWarehouse(paramMap);
|
//
|
||||||
|
// uasUtil.getWarehouse(paramMap);
|
||||||
uasUtil.getBil(paramMap);
|
//
|
||||||
|
// uasUtil.getBil(paramMap);
|
||||||
// session.setAttribute("randCode", "1234"); //设置登录验证码
|
// session.setAttribute("randCode", "1234"); //设置登录验证码
|
||||||
// this.mockMvc.perform(post("/loginController.do?checkuser=")
|
// this.mockMvc.perform(post("/loginController.do?checkuser=")
|
||||||
// .param("userName","admin")
|
// .param("userName","admin")
|
||||||
|
|
Loading…
Reference in New Issue