update 新料号标签打印页面,由MQ改为直接调打印机
This commit is contained in:
parent
8290916c8d
commit
71b82def92
@ -22,7 +22,7 @@ db.Prd.url=jdbc:oracle:thin:@192.168.1.73:1526/test
|
|||||||
db.Prd.username=ziwms_sap_test
|
db.Prd.username=ziwms_sap_test
|
||||||
db.Prd.password=adm2024
|
db.Prd.password=adm2024
|
||||||
#MQ
|
#MQ
|
||||||
mq.url=192.168.1.73:5672
|
#mq.url=192.168.1.73:5672
|
||||||
mq.username=zimes
|
#mq.username=zimes
|
||||||
mq.password=adm2024
|
#mq.password=adm2024
|
||||||
mq.virtual-host=/zimes
|
#mq.virtual-host=/zimes
|
@ -94,12 +94,12 @@ public class StorageController {
|
|||||||
public AjaxResult getLocationName2(@RequestBody JSONObject in ) throws Exception {
|
public AjaxResult getLocationName2(@RequestBody JSONObject in ) throws Exception {
|
||||||
|
|
||||||
StorageSpec storageSpec = JSON.toJavaObject(in, StorageSpec.class);
|
StorageSpec storageSpec = JSON.toJavaObject(in, StorageSpec.class);
|
||||||
//String erplocation = storageSpec.getErpLocation();
|
String erplocation = storageSpec.getErpLocation();
|
||||||
String erpLocation = storageSpec.getErpLocation();
|
//String erpLocation = storageSpec.getErpLocation();
|
||||||
String areaName = "";
|
String areaName = "";
|
||||||
// String commitDate = storageSpec.getCommitDate();
|
// String commitDate = storageSpec.getCommitDate();
|
||||||
//判断条码是否存在且状态是在库
|
//判断条码是否存在且状态是在库
|
||||||
//String sql = "SELECT m.STORAGENAME ,m.DESCRIPTION || m.STORAGENAME DESCRIPTION FROM STORAGESPEC m WHERE m.ERPLOCATION = :ERPLOCATION ORDER BY STORAGENAME ";
|
String sql = "SELECT m.STORAGENAME ,m.DESCRIPTION || m.STORAGENAME DESCRIPTION FROM STORAGESPEC m WHERE m.ERPLOCATION = :ERPLOCATION ORDER BY STORAGENAME ";
|
||||||
/*String sql = " SELECT\n" +
|
/*String sql = " SELECT\n" +
|
||||||
"\tm.STORAGENAME,\n" +
|
"\tm.STORAGENAME,\n" +
|
||||||
"\tm.STORAGENAME || ' ' || m.DESCRIPTION DESCRIPTION \n" +
|
"\tm.STORAGENAME || ' ' || m.DESCRIPTION DESCRIPTION \n" +
|
||||||
@ -110,6 +110,7 @@ public class StorageController {
|
|||||||
"\tAND m.AREANAME =:AREANAME\n" +
|
"\tAND m.AREANAME =:AREANAME\n" +
|
||||||
"ORDER BY\n" +
|
"ORDER BY\n" +
|
||||||
"\tSTORAGENAME ";*/
|
"\tSTORAGENAME ";*/
|
||||||
|
/*
|
||||||
String sql = " SELECT * FROM ( " +
|
String sql = " SELECT * FROM ( " +
|
||||||
" SELECT\n" +
|
" SELECT\n" +
|
||||||
"\tm.STORAGENAME,\n" +
|
"\tm.STORAGENAME,\n" +
|
||||||
@ -122,6 +123,8 @@ public class StorageController {
|
|||||||
"ORDER BY\n" +
|
"ORDER BY\n" +
|
||||||
"\tSTORAGENAME" +
|
"\tSTORAGENAME" +
|
||||||
" ) WHERE ROWNUM <= 50 ";
|
" ) WHERE ROWNUM <= 50 ";
|
||||||
|
*/
|
||||||
|
/*
|
||||||
switch (erpLocation) {
|
switch (erpLocation) {
|
||||||
case "1010":
|
case "1010":
|
||||||
case "1020":
|
case "1020":
|
||||||
@ -142,9 +145,13 @@ public class StorageController {
|
|||||||
default :
|
default :
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
Map<String, Object> bindMap = new HashMap<String, Object>();
|
Map<String, Object> bindMap = new HashMap<String, Object>();
|
||||||
|
bindMap.put("ERPLOCATION",erplocation);
|
||||||
|
/*
|
||||||
bindMap.put("SITENAME","SDK");
|
bindMap.put("SITENAME","SDK");
|
||||||
bindMap.put("AREANAME",areaName);
|
bindMap.put("AREANAME",areaName);
|
||||||
|
*/
|
||||||
List<Map<String,Object>> list = IDMFrameServiceProxy.getSqlTemplate().queryForList(sql, bindMap);
|
List<Map<String,Object>> list = IDMFrameServiceProxy.getSqlTemplate().queryForList(sql, bindMap);
|
||||||
|
|
||||||
if(Objects.isNull(list) || list.isEmpty()) {
|
if(Objects.isNull(list) || list.isEmpty()) {
|
||||||
|
@ -1831,7 +1831,7 @@ public class BSLabelServiceImpl extends CommonServiceDAO<BSLabelKey, BSLabel> im
|
|||||||
String printer = printName == null || "".equals(printName) ? getDefaultPrinter() : printName;// "\\\\ZXYNB10810864P.boe.com.cn\\TSC MA3400P";
|
String printer = printName == null || "".equals(printName) ? getDefaultPrinter() : printName;// "\\\\ZXYNB10810864P.boe.com.cn\\TSC MA3400P";
|
||||||
String server = "LabelRequestURL";
|
String server = "LabelRequestURL";
|
||||||
String requestUrl = getRequestUrlByServer(server);
|
String requestUrl = getRequestUrlByServer(server);
|
||||||
requestUrl = "0980b551-20a2-49ba-a1e8-950331ff9827";
|
// requestUrl = "0980b551-20a2-49ba-a1e8-950331ff9827";
|
||||||
List<String> params = getLabelAssignParameter("testLabel002");
|
List<String> params = getLabelAssignParameter("testLabel002");
|
||||||
String labelUrl = "";
|
String labelUrl = "";
|
||||||
String labelPath = getLabelAbsolutePath(labelAddress);
|
String labelPath = getLabelAbsolutePath(labelAddress);
|
||||||
@ -1918,7 +1918,8 @@ public class BSLabelServiceImpl extends CommonServiceDAO<BSLabelKey, BSLabel> im
|
|||||||
labelPrintPET.setStartTime("");
|
labelPrintPET.setStartTime("");
|
||||||
labelPrintPET.setEndTime("");
|
labelPrintPET.setEndTime("");
|
||||||
log.info("***************************PrintLabel Assign params is : " + params.toString());
|
log.info("***************************PrintLabel Assign params is : " + params.toString());
|
||||||
labelUrl = labelPrintRabbitMQ(labelPrintPET, requestUrl, pr, params);
|
//labelUrl = labelPrintRabbitMQ(labelPrintPET, requestUrl, pr, params);
|
||||||
|
labelUrl = labelPrint(labelPrintPET, requestUrl, pr, params);
|
||||||
log.info("***************************PrintLabel Use URL is : " + requestUrl);
|
log.info("***************************PrintLabel Use URL is : " + requestUrl);
|
||||||
}else {
|
}else {
|
||||||
throw new CustomException(CustomExceptionCode.DATA_NOT_FOUND,"Undefined Execute Type : ");
|
throw new CustomException(CustomExceptionCode.DATA_NOT_FOUND,"Undefined Execute Type : ");
|
||||||
@ -1994,7 +1995,8 @@ public class BSLabelServiceImpl extends CommonServiceDAO<BSLabelKey, BSLabel> im
|
|||||||
obj.setSupplierno(queryForListProduct.get(0).get("supplierNo") != null ? queryForListProduct.get(0).get("supplierNo").toString() : "");
|
obj.setSupplierno(queryForListProduct.get(0).get("supplierNo") != null ? queryForListProduct.get(0).get("supplierNo").toString() : "");
|
||||||
obj.setDescription(queryForListProduct.get(0).get("description") != null ? queryForListProduct.get(0).get("description").toString() : "");
|
obj.setDescription(queryForListProduct.get(0).get("description") != null ? queryForListProduct.get(0).get("description").toString() : "");
|
||||||
log.info("***************************PrintLabel Assign params is : " + params.toString());
|
log.info("***************************PrintLabel Assign params is : " + params.toString());
|
||||||
labelUrl = labelPrintRabbitMQ(obj, requestUrl, pr, params);
|
//labelUrl = labelPrintRabbitMQ(obj, requestUrl, pr, params);
|
||||||
|
labelUrl = labelPrint(obj, requestUrl, pr, params);
|
||||||
log.info("***************************PrintLabel Use URL is : " + requestUrl);
|
log.info("***************************PrintLabel Use URL is : " + requestUrl);
|
||||||
}else if ("胶水原材.btw".equals(labelAddress)){
|
}else if ("胶水原材.btw".equals(labelAddress)){
|
||||||
qeuryLabelDatasql = "SELECT\r\n" +
|
qeuryLabelDatasql = "SELECT\r\n" +
|
||||||
@ -2066,7 +2068,8 @@ public class BSLabelServiceImpl extends CommonServiceDAO<BSLabelKey, BSLabel> im
|
|||||||
obj.setSupplierno(queryForListProduct.get(0).get("supplierNo") != null ? queryForListProduct.get(0).get("supplierNo").toString() : "");
|
obj.setSupplierno(queryForListProduct.get(0).get("supplierNo") != null ? queryForListProduct.get(0).get("supplierNo").toString() : "");
|
||||||
obj.setDescription(queryForListProduct.get(0).get("description") != null ? queryForListProduct.get(0).get("description").toString() : "");
|
obj.setDescription(queryForListProduct.get(0).get("description") != null ? queryForListProduct.get(0).get("description").toString() : "");
|
||||||
log.info("***************************PrintLabel Assign params is : " + params.toString());
|
log.info("***************************PrintLabel Assign params is : " + params.toString());
|
||||||
labelUrl = labelPrintRabbitMQ(obj, requestUrl, pr, params);
|
//labelUrl = labelPrintRabbitMQ(obj, requestUrl, pr, params);
|
||||||
|
labelUrl = labelPrint(obj, requestUrl, pr, params);
|
||||||
log.info("***************************PrintLabel Use URL is : " + requestUrl);
|
log.info("***************************PrintLabel Use URL is : " + requestUrl);
|
||||||
}else {
|
}else {
|
||||||
throw new CustomException(CustomExceptionCode.DATA_NOT_FOUND, "未找到对应的标签模板");
|
throw new CustomException(CustomExceptionCode.DATA_NOT_FOUND, "未找到对应的标签模板");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user