From d2975044b71928c015775a2ac3dcb931bfe3f518 Mon Sep 17 00:00:00 2001 From: "lj7788@126.com" Date: Wed, 25 Jun 2025 10:36:08 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=AE=A1=E5=88=92BIM?= =?UTF-8?q?=E7=BB=91=E5=AE=9A=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- yanzhu-bigscreen/src/views/bimBriefing.vue | 2 +- yanzhu-bigscreen/src/views/bimManage.vue | 2 +- yanzhu-bigscreen/src/views/bimRoaming.vue | 4 +- .../yanzhu/job/task/AttendanceSzjTask.java | 40 +++- .../controller/UniCallBackController.java | 8 +- yanzhu-ui-vue3/src/App.vue | 3 + .../src/views/bim/sandTableSetting/index.vue | 1 - .../views/manage/plan/bimSelectionDialog.vue | 131 +++++++++++ .../src/views/manage/plan/index.vue | 211 ++++++++++-------- 9 files changed, 298 insertions(+), 104 deletions(-) create mode 100644 yanzhu-ui-vue3/src/views/manage/plan/bimSelectionDialog.vue diff --git a/yanzhu-bigscreen/src/views/bimBriefing.vue b/yanzhu-bigscreen/src/views/bimBriefing.vue index c25051cc..01a59bd0 100644 --- a/yanzhu-bigscreen/src/views/bimBriefing.vue +++ b/yanzhu-bigscreen/src/views/bimBriefing.vue @@ -455,7 +455,7 @@ export default { .then((d) => { this.models = d.rows || []; if (this.models.length == 0) { - this.$modal.msgError("暂无模型,请先关联模型"); + this.$message.error("暂无模型,请先关联模型"); } else { this.models.forEach((item) => { this.addModel(item.lightweightName); diff --git a/yanzhu-bigscreen/src/views/bimManage.vue b/yanzhu-bigscreen/src/views/bimManage.vue index dad73ef7..99c33d11 100644 --- a/yanzhu-bigscreen/src/views/bimManage.vue +++ b/yanzhu-bigscreen/src/views/bimManage.vue @@ -762,7 +762,7 @@ export default { .then((d) => { this.models = d.rows || []; if (this.models.length == 0) { - this.$modal.msgError("暂无模型,请先关联模型"); + this.$message.error("暂无模型,请先关联模型"); } else { this.models.forEach((item) => { this.addModel(item.lightweightName); diff --git a/yanzhu-bigscreen/src/views/bimRoaming.vue b/yanzhu-bigscreen/src/views/bimRoaming.vue index 60524350..ada5c6a4 100644 --- a/yanzhu-bigscreen/src/views/bimRoaming.vue +++ b/yanzhu-bigscreen/src/views/bimRoaming.vue @@ -166,7 +166,7 @@ export default { }, startRoaming(data) { if (!this.modelLoaded) { - this.$message.error("模型未加载完成,请稍后重试"); + this.$message.error("暂无模型,请先关联模型"); return; } let api = bimRoadmApi; @@ -349,7 +349,7 @@ export default { .then((d) => { this.models = d.rows || []; if (this.models.length == 0) { - this.$modal.msgError("暂无模型,请先关联模型"); + this.$modal.error("暂无模型,请先关联模型"); } else { this.models.forEach((item) => { this.addModel(item.lightweightName); diff --git a/yanzhu-modules/yanzhu-job/src/main/java/com/yanzhu/job/task/AttendanceSzjTask.java b/yanzhu-modules/yanzhu-job/src/main/java/com/yanzhu/job/task/AttendanceSzjTask.java index da70b003..e7c30b14 100644 --- a/yanzhu-modules/yanzhu-job/src/main/java/com/yanzhu/job/task/AttendanceSzjTask.java +++ b/yanzhu-modules/yanzhu-job/src/main/java/com/yanzhu/job/task/AttendanceSzjTask.java @@ -81,7 +81,7 @@ public class AttendanceSzjTask { public String getToken(String secret) { log.info("开始查询数智建TOKEN...{}",secret); String key = "attendanceSzjTask.getToken::"+secret; - String token = redisService.getCacheObject(key); + String token = redisService!=null? redisService.getCacheObject(key):""; if(StringUtils.isNotEmpty(token)){ return token; }else{ @@ -92,7 +92,9 @@ public class AttendanceSzjTask { JSONObject jsonObject = JSONObject.parseObject(result); if(jsonObject!=null && jsonObject.getBoolean("success")){ token = jsonObject.getJSONObject("data").getString("token"); - redisService.setCacheObject(key,token,5L,TimeUnit.HOURS); + if(redisService!=null){ + redisService.setCacheObject(key,token,5L,TimeUnit.HOURS); + } return token; } }catch (Exception e){ @@ -102,6 +104,40 @@ public class AttendanceSzjTask { throw new RuntimeException("无效token..."); } + + public static void main(String[] args) { + AttendanceSzjTask task = new AttendanceSzjTask(); + String secret = "185677eed140468fbb7d4dc47c1b2806"; + String token = task.getToken(secret); + task.testEnterpriseQuery(token); + } + + public void testEnterpriseQuery(String token){ + Map headerMap = new HashMap<>(); + headerMap.put("token",token); + Map params = new HashMap<>(); + try { + String result = HttpUtils.sendJSONPost(SZJ_HOST + "v1/api/enterprise/query", JSON.toJSONString(params), headerMap); + JSONObject jsonObject = JSONObject.parseObject(result); + System.out.println(result); + }catch (Exception e){ + + } + } + public int updateAttendanceGroup(JSONObject jsonObject) { + int result = 0; + if (jsonObject != null && jsonObject.getBoolean("success")) { + JSONArray jsonArray = jsonObject.getJSONArray("data"); + if (jsonArray.size() > 0) { + for (int i = 0; i < jsonArray.size(); i++) { + JSONObject json = jsonArray.getJSONObject(i); + QuartzProSubdepts dept = new QuartzProSubdepts(); + + } + } + } + return result; + } /** * 同步单位及班组信息 */ diff --git a/yanzhu-modules/yanzhu-manage/src/main/java/com/yanzhu/manage/controller/UniCallBackController.java b/yanzhu-modules/yanzhu-manage/src/main/java/com/yanzhu/manage/controller/UniCallBackController.java index b7eb6591..8b6f483b 100644 --- a/yanzhu-modules/yanzhu-manage/src/main/java/com/yanzhu/manage/controller/UniCallBackController.java +++ b/yanzhu-modules/yanzhu-manage/src/main/java/com/yanzhu/manage/controller/UniCallBackController.java @@ -20,6 +20,8 @@ import java.util.Date; import java.util.List; import java.util.Map; +import static org.reflections.Reflections.log; + @RestController @RequestMapping("/uni/callback") public class UniCallBackController { @@ -41,10 +43,11 @@ public class UniCallBackController { public AjaxResult recognize(HttpServletRequest request){ String eventCode=request.getParameter("eventCode"); String eventGuid=request.getParameter("eventGuid"); + String projectId=request.getParameter("prjId"); String data=request.getParameter("eventMsg"); switch (eventCode){ case "101004"://上报识别记录 - return doAddAttendance(eventGuid,data); + return doAddAttendance(eventGuid,data,projectId); case "100002"://设备上线 return doDeviceOnLine(eventGuid,data); case "100003"://设备下线 @@ -99,7 +102,8 @@ public class UniCallBackController { * @param data * @return */ - private AjaxResult doAddAttendance(String eventGuid,String data){ + private AjaxResult doAddAttendance(String eventGuid,String data,String prjId){ + log.info("考勤记录同步开始,eventGuid:{},data:{},projectId:{}",eventGuid,data,prjId); JSONObject json=JSONObject.parseObject(data); int type=json.getInteger("type"); if(type==1){// 人员比对结果,1:比对成功 2:比对失败 diff --git a/yanzhu-ui-vue3/src/App.vue b/yanzhu-ui-vue3/src/App.vue index d20e8c54..4b808ccc 100644 --- a/yanzhu-ui-vue3/src/App.vue +++ b/yanzhu-ui-vue3/src/App.vue @@ -107,4 +107,7 @@ a { .blue { color: rgb(30, 144, 255); } +.icon-blue{ + fill:rgb(30, 144, 255) !important; +} \ No newline at end of file diff --git a/yanzhu-ui-vue3/src/views/bim/sandTableSetting/index.vue b/yanzhu-ui-vue3/src/views/bim/sandTableSetting/index.vue index db1692c5..7cbef0d7 100644 --- a/yanzhu-ui-vue3/src/views/bim/sandTableSetting/index.vue +++ b/yanzhu-ui-vue3/src/views/bim/sandTableSetting/index.vue @@ -154,7 +154,6 @@ export default { enabled: item.show ? 1 : 0, }; }); - console.log("-->", adds, updates); let ajaxs = []; if (adds.length > 0) { ajaxs.push(devicePositionAddItems({ items: adds })); diff --git a/yanzhu-ui-vue3/src/views/manage/plan/bimSelectionDialog.vue b/yanzhu-ui-vue3/src/views/manage/plan/bimSelectionDialog.vue new file mode 100644 index 00000000..36da3687 --- /dev/null +++ b/yanzhu-ui-vue3/src/views/manage/plan/bimSelectionDialog.vue @@ -0,0 +1,131 @@ + + + diff --git a/yanzhu-ui-vue3/src/views/manage/plan/index.vue b/yanzhu-ui-vue3/src/views/manage/plan/index.vue index c87c9427..bf3698d8 100644 --- a/yanzhu-ui-vue3/src/views/manage/plan/index.vue +++ b/yanzhu-ui-vue3/src/views/manage/plan/index.vue @@ -2,12 +2,10 @@
- - - + + - + 搜索 重置 @@ -28,51 +26,61 @@ v-hasPermi="['manage:plan:remove']">删除 --> - - - 导入(Project) - + + + 导入(Project) + - - 导出(Project) + + 导出(Project) - + - + - - - - + + + + + + + - - - - - + + + + "