Commit c5e80946 by liuyang

Merge branch 'dev' of http://git.pseer.com/platform/hp-smart into dev-ly

parents f843c170 9b27c1eb
package com.baosight.hpjx.aspect.annotation;
import com.baosight.hpjx.aspect.domain.TCPReceive;
import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.web.controller.WebDispatchController;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
@CrossOrigin
@RestController
@RequestMapping("/tcp")
public class TCPController extends WebDispatchController {
private final static Logger logger = LoggerFactory.getLogger(DocController.class);
@RequestMapping(value = "/receive/api", method = RequestMethod.POST)
public void tcpReceive(TCPReceive tcpReceive) {
logger.info("receive tcp deviceNo: " + tcpReceive.getDeviceNo());
logger.info("receive tcp msgType: " + tcpReceive.getMsgType());
logger.info("receive tcp msgContent: " + tcpReceive.getMsgContent());
}
}
package com.baosight.hpjx.aspect.domain;
public class TCPReceive {
private String deviceNo;
private String msgType;
private String msgContent;
public String getDeviceNo() {
return deviceNo;
}
public void setDeviceNo(String deviceNo) {
this.deviceNo = deviceNo;
}
public String getMsgType() {
return msgType;
}
public void setMsgType(String msgType) {
this.msgType = msgType;
}
public String getMsgContent() {
return msgContent;
}
public void setMsgContent(String msgContent) {
this.msgContent = msgContent;
}
}
...@@ -24,6 +24,7 @@ import com.baosight.iplat4j.core.service.impl.ServiceEPBase; ...@@ -24,6 +24,7 @@ import com.baosight.iplat4j.core.service.impl.ServiceEPBase;
import com.baosight.iplat4j.ed.util.SequenceGenerator; import com.baosight.iplat4j.ed.util.SequenceGenerator;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.text.DecimalFormat;
import java.util.Arrays; import java.util.Arrays;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
...@@ -107,7 +108,9 @@ public class ServiceHPKC004A extends ServiceEPBase { ...@@ -107,7 +108,9 @@ public class ServiceHPKC004A extends ServiceEPBase {
newKc004.setSaleNo(SequenceGenerator.getNextSequence(HPConstant.SequenceId.HPKC004_SALE_NO)); newKc004.setSaleNo(SequenceGenerator.getNextSequence(HPConstant.SequenceId.HPKC004_SALE_NO));
newKc004.setReceiptDate(DateUtils.shortDate()); newKc004.setReceiptDate(DateUtils.shortDate());
newKc004.setAmount(applyAmount); newKc004.setAmount(applyAmount);
newKc004.setWeight(applyAmount.multiply(dbKc011.getUnitWeight()).divide(new BigDecimal("1000"))); DecimalFormat decimalFormat = new DecimalFormat("#.000");
BigDecimal totalWt = new BigDecimal(decimalFormat.format(applyAmount.multiply(dbKc011.getUnitWeight()).divide(new BigDecimal("1000"))));
newKc004.setWeight(totalWt);
newKc004.setRemark(applyRemark); newKc004.setRemark(applyRemark);
newKc004.setKcId(kcId); newKc004.setKcId(kcId);
newKc004.setIsPrint(CommonConstant.YesNo.NO_0); newKc004.setIsPrint(CommonConstant.YesNo.NO_0);
......
...@@ -19,7 +19,7 @@ spring.servlet.multipart.file-size-threshold =0 ...@@ -19,7 +19,7 @@ spring.servlet.multipart.file-size-threshold =0
componentEname=hpjx componentEname=hpjx
projectName=hpjx projectName=hpjx
moduleName=ep moduleName=ep
projectEnv=dev projectEnv=run
platSchema=iplat platSchema=iplat
eplatSchema=EPLAT eplatSchema=EPLAT
lowcodedbSchema=lowcodedb lowcodedbSchema=lowcodedb
......
...@@ -411,7 +411,12 @@ $(function () { ...@@ -411,7 +411,12 @@ $(function () {
}); });
$("#DOWNLOAD").on("click", function (e) { $("#DOWNLOAD").on("click", function (e) {
var href = ctx + "\\HP\\template\\SC\\HPSC002_物料清单.xls"; var href = ctx + "\\HP\\template\\SC\\HPSC002_物料清单-部件.xls";
window.location.href = href;
});
$("#DOWNLOAD2").on("click", function (e) {
var href = ctx + "\\HP\\template\\SC\\HPSC002_物料清单-零件.xls";
window.location.href = href; window.location.href = href;
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment