From c96f71b55d1cf81dc7119202b31678e0368087cb Mon Sep 17 00:00:00 2001 From: luxiaotao1123 <t1341870251@163.com> Date: 星期二, 24 十二月 2024 11:04:54 +0800 Subject: [PATCH] # --- zy-acs-flow/src/i18n/en.js | 4 - zy-acs-manager/src/main/java/com/zy/acs/manager/core/scheduler/KernelScheduler.java | 7 +++ version/db/sqlIndex | 5 ++ zy-acs-flow/src/i18n/zh.js | 3 - zy-acs-manager/src/main/java/com/zy/acs/manager/manager/entity/Segment.java | 44 +++------------------- zy-acs-flow/src/page/segment/SegmentList.jsx | 1 6 files changed, 19 insertions(+), 45 deletions(-) diff --git a/version/db/sqlIndex b/version/db/sqlIndex index a9a58f0..43914a2 100644 --- a/version/db/sqlIndex +++ b/version/db/sqlIndex @@ -9,6 +9,9 @@ CREATE INDEX idx_loc_sts_uuid ON man_loc_sts(uuid); CREATE INDEX idx_task_sts_uuid ON man_task_sts(uuid); CREATE INDEX idx_task_type_uuid ON man_task_type(uuid); +CREATE INDEX idx_task_seq_num ON man_task(seq_num); +CREATE INDEX idx_task_agv_id ON man_task(agv_id); +CREATE INDEX idx_task_agv_id_task_sts ON man_task(agv_id, task_sts); CREATE INDEX idx_zone_uuid ON man_zone(uuid); CREATE INDEX idx_agv_detail_agv_id ON man_agv_detail(agv_id); -CREATE INDEX idx_config_flag ON sys_config(flag); \ No newline at end of file +CREATE INDEX idx_config_flag ON sys_config(flag); diff --git a/zy-acs-flow/src/i18n/en.js b/zy-acs-flow/src/i18n/en.js index 3c88ba4..5d14c6c 100644 --- a/zy-acs-flow/src/i18n/en.js +++ b/zy-acs-flow/src/i18n/en.js @@ -119,7 +119,6 @@ operation: 'Operation', config: 'Config', tenant: 'Tenant', - role: 'Role', userLogin: 'Token', base: 'Base', warehouse: 'Warehouse', @@ -217,7 +216,6 @@ }, user: { username: "username", - password: "password", password: "password", confirmPwd: "confirm password", nickname: "nickname", @@ -494,6 +492,7 @@ endNode: "end node", posType: "type", backpack: "backpack", + algoTime: "algo time", state: "state", segDesc: "seg no", }, @@ -676,7 +675,6 @@ MOVE: 'MOVE', TO_CHARGE: 'TO_CHARGE', TO_STANDBY: 'TO_STANDBY', - TO_CHARGE: 'TO_CHARGE', LOC_TO_LOC: 'LOC_TO_LOC', LOC_TO_STA: 'LOC_TO_STA', STA_TO_LOC: 'STA_TO_LOC', diff --git a/zy-acs-flow/src/i18n/zh.js b/zy-acs-flow/src/i18n/zh.js index dfe1730..d592db5 100644 --- a/zy-acs-flow/src/i18n/zh.js +++ b/zy-acs-flow/src/i18n/zh.js @@ -119,7 +119,6 @@ operation: '鎿嶄綔鏃ュ織', config: '閰嶇疆鍙傛暟', tenant: '绉熸埛绠$悊', - role: '瑙掕壊绠$悊', userLogin: '鐧诲綍鏃ュ織', base: '鍩虹妗f', warehouse: '浠撳簱绠$悊', @@ -493,6 +492,7 @@ endNode: "浣滀笟鑺傜偣", posType: "浣滀笟绫诲瀷", backpack: "鑳岀瘬", + algoTime: "绠楁硶鑰楁椂", state: "鐘舵��", segDesc: "浣滀笟缂栧彿", }, @@ -673,7 +673,6 @@ control: { type: { MOVE: '绉诲姩', - TO_CHARGE: '鍘诲厖鐢�', TO_STANDBY: '鍘诲緟鏈轰綅', TO_CHARGE: '鍘诲厖鐢�', LOC_TO_LOC: '搴撲綅鍒板簱浣�', diff --git a/zy-acs-flow/src/page/segment/SegmentList.jsx b/zy-acs-flow/src/page/segment/SegmentList.jsx index 23ad4aa..d1d49af 100644 --- a/zy-acs-flow/src/page/segment/SegmentList.jsx +++ b/zy-acs-flow/src/page/segment/SegmentList.jsx @@ -220,6 +220,7 @@ </ReferenceField> <TextField source="posType" label="table.field.segment.posType" sortable={false} /> <NumberField source="backpack" label="table.field.segment.backpack" sortable={false} /> + <NumberField source="algoTime" label="table.field.segment.algoTime" sortable={false} /> <ReferenceField source="endNode" label="table.field.segment.endNode" reference="code" link={false} sortable={false}> <TextField source="data" /> </ReferenceField> diff --git a/zy-acs-manager/src/main/java/com/zy/acs/manager/core/scheduler/KernelScheduler.java b/zy-acs-manager/src/main/java/com/zy/acs/manager/core/scheduler/KernelScheduler.java index 79e4062..817151f 100644 --- a/zy-acs-manager/src/main/java/com/zy/acs/manager/core/scheduler/KernelScheduler.java +++ b/zy-acs-manager/src/main/java/com/zy/acs/manager/core/scheduler/KernelScheduler.java @@ -119,7 +119,12 @@ for (Segment segment : segments) { long startTime = System.currentTimeMillis(); trafficService.trigger(segment); - log.info("traffic calculation spend {} ms", System.currentTimeMillis() - startTime); + long algoTime = System.currentTimeMillis() - startTime; + log.info("traffic calculation spend {} ms", algoTime); + if (segment.getState().equals(SegmentStateType.RUNNING.toString())) { + segment.setAlgoTime((int) algoTime); + segmentService.updateById(segment); + } } } catch (Exception e) { diff --git a/zy-acs-manager/src/main/java/com/zy/acs/manager/manager/entity/Segment.java b/zy-acs-manager/src/main/java/com/zy/acs/manager/manager/entity/Segment.java index 2264979..9f7cb82 100644 --- a/zy-acs-manager/src/main/java/com/zy/acs/manager/manager/entity/Segment.java +++ b/zy-acs-manager/src/main/java/com/zy/acs/manager/manager/entity/Segment.java @@ -89,6 +89,12 @@ private Integer backpack; /** + * 绠楁硶鑰楁椂 + */ + @ApiModelProperty(value= "绠楁硶鑰楁椂") + private Integer algoTime; + + /** * 杩涘害 */ @ApiModelProperty(value= "杩涘害") @@ -143,44 +149,6 @@ private String memo; public Segment() {} - - public Segment(String uuid,Long travelId,Long taskId,Long agvId,Integer serial,Long startNode,Long endNode,String state,Integer status,Integer deleted,Long tenantId,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo) { - this.uuid = uuid; - this.travelId = travelId; - this.taskId = taskId; - this.agvId = agvId; - this.serial = serial; - this.startNode = startNode; - this.endNode = endNode; - this.state = state; - this.status = status; - this.deleted = deleted; - this.tenantId = tenantId; - this.createBy = createBy; - this.createTime = createTime; - this.updateBy = updateBy; - this.updateTime = updateTime; - this.memo = memo; - } - -// Segment segment = new Segment( -// null, // 缂栧彿 -// null, // 浠诲姟缁� -// null, // 浠诲姟 -// null, // AGV -// null, // 搴忓彿 -// null, // 璧峰鑺傜偣 -// null, // 鐩爣鑺傜偣 -// null, // 杩涘害 -// null, // 鐘舵�乕闈炵┖] -// null, // 鏄惁鍒犻櫎[闈炵┖] -// null, // 绉熸埛 -// null, // 娣诲姞浜哄憳 -// null, // 娣诲姞鏃堕棿[闈炵┖] -// null, // 淇敼浜哄憳 -// null, // 淇敼鏃堕棿 -// null // 澶囨敞 -// ); public String getTravelId$(){ TravelService service = SpringUtils.getBean(TravelService.class); -- Gitblit v1.9.1