Commit 9a40f8af authored by 刘凡's avatar 刘凡

*)修改模板

parent bbb266a7
...@@ -15,7 +15,6 @@ import org.typroject.tyboot.core.restful.utils.ResponseModel; ...@@ -15,7 +15,6 @@ import org.typroject.tyboot.core.restful.utils.ResponseModel;
import java.util.Map; import java.util.Map;
/** /**
* 大屏统计controller * 大屏统计controller
* *
...@@ -39,17 +38,17 @@ public class DPSubController { ...@@ -39,17 +38,17 @@ public class DPSubController {
public ResponseModel<JSONObject> commonQuery(@PathVariable String template, @RequestBody Map<String, Object> param) { public ResponseModel<JSONObject> commonQuery(@PathVariable String template, @RequestBody Map<String, Object> param) {
if (template.equals("company")) { if (template.equals("company")) {
Assert.notNull(param.get("useUnitCode"), "企业统一信用代码不能为空"); Assert.notNull(param.get("useUnitCode"), "企业统一信用代码不能为空");
} else if (template.equals("emergency")){ } else if (template.equals("emergency")) {
Assert.notNull(param.get("id"), "id不能为空"); Assert.notNull(param.get("id"), "id不能为空");
}else if(template.equals("equip")) { } else if (template.equals("equip")) {
param.put("record", param.get("SEQUENCE_NBR")); param.put("record", param.get("SEQUENCE_NBR"));
param.put("equList", param.get("EQU_LIST_CODE")); param.put("equList", param.get("EQU_LIST_CODE"));
Assert.notNull(param.get("record"), "设备ID不能为空"); Assert.notNull(param.get("record"), "设备ID不能为空");
Assert.notNull(param.get("equList"), "设备种类不能为空"); Assert.notNull(param.get("equList"), "设备种类不能为空");
template = template + "_" + param.get("equList"); template = template + "_" + param.get("equList");
} else if (template.equals("issue")){ } else if (template.equals("issue")) {
Assert.notNull(param.get("sequenceNbr"), "sequenceNbr不能为空"); Assert.notNull(param.get("sequenceNbr"), "sequenceNbr不能为空");
}else { } else {
throw new RuntimeException("暂无模板"); throw new RuntimeException("暂无模板");
} }
return ResponseHelper.buildResponse(subService.commonQuery(template, param)); return ResponseHelper.buildResponse(subService.commonQuery(template, param));
......
...@@ -468,8 +468,12 @@ public class DPSubServiceImpl { ...@@ -468,8 +468,12 @@ public class DPSubServiceImpl {
} }
public JSONObject processQRCodeWidget(JSONObject qrcode, JSONObject result) { public JSONObject processQRCodeWidget(JSONObject qrcode, JSONObject result) {
if (qrcode == null){
return qrcode;
}
String problemTime = result.getString("problemTime"); String problemTime = result.getString("problemTime");
String problemStatus = result.getString("problemStatus"); String problemStatus = result.getString("problemStatus");
String color = null; String color = null;
if (!ValidationUtil.isEmpty(problemTime)) { if (!ValidationUtil.isEmpty(problemTime)) {
try { try {
......
...@@ -19,13 +19,13 @@ ...@@ -19,13 +19,13 @@
"key": "devtable", "key": "devtable",
"displayName": "关联设备", "displayName": "关联设备",
"renderType": "table", "renderType": "table",
"formSeq": "", "useAloneApi": true,
"dataConfig": { "dataConfig": {
"api": { "api": {
"httpMethod":"GET", "httpMethod":"GET",
"apiPath":"/jg/safety-problem-tracing/equip/list", "apiPath":"/jg/safety-problem-tracing/equip/list",
"params": { "params": {
"number": 1, "current": 1,
"size": 14, "size": 14,
"sequenceNbr": "{sequenceNbr}" "sequenceNbr": "{sequenceNbr}"
} }
...@@ -47,13 +47,13 @@ ...@@ -47,13 +47,13 @@
"key": "devtable1", "key": "devtable1",
"displayName": "关联企业", "displayName": "关联企业",
"renderType": "table", "renderType": "table",
"formSeq": "", "useAloneApi": true,
"dataConfig": { "dataConfig": {
"api": { "api": {
"httpMethod":"GET", "httpMethod":"GET",
"apiPath":"/jg/safety-problem-tracing/unit/list", "apiPath":"/jg/safety-problem-tracing/unit/list",
"params": { "params": {
"number": 1, "current": 1,
"size": 14, "size": 14,
"sequenceNbr": "{sequenceNbr}" "sequenceNbr": "{sequenceNbr}"
} }
...@@ -88,12 +88,6 @@ ...@@ -88,12 +88,6 @@
{ "key": "equipSuperviseCode", "label": "监管吗" }, { "key": "equipSuperviseCode", "label": "监管吗" },
{ "key": "equipList", "label": "设备种类" } { "key": "equipList", "label": "设备种类" }
] ]
},
"basic": {
"columns": 2,
"datas": [],
"qrcode": {},
"subs": []
} }
} }
} }
\ No newline at end of file
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