对接优化接口,实现玻璃优化中,选择工程,选择原料玻璃,优化玻璃分割
| | |
| | | export default { |
| | | serverUrl:"localhost:8086", |
| | | serverUrlTemp:"10.153.19.150:8079", |
| | | serverUrlOptimize:"10.153.19.150:8078", |
| | | //serverUrl:"192.168.1.199:8086" |
| | | } |
| New file |
| | |
| | | import axios from 'axios' |
| | | import config from '../../config' |
| | | import useUserInfoStore from '@/stores/userInfo' |
| | | const userStore=useUserInfoStore() |
| | | const request = axios.create({ |
| | | baseURL: `http://${config.serverUrlOptimize}`, // 注意!! 这里是全局统一加上了 后端接口前缀 前缀,后端必须进行跨域配置! |
| | | timeout: 60000 |
| | | }) |
| | | |
| | | |
| | | |
| | | // |
| | | |
| | | // request 拦截器 |
| | | // 可以自请求发送前对请求做一些处理 |
| | | // 比如统一加token,对请求参数统一加密 |
| | | request.interceptors.request.use(config => { |
| | | config.headers['Content-Type'] = 'application/json;charset=utf-8'; |
| | | if(userStore.user){ |
| | | config.headers['satoken'] = userStore.user.token; |
| | | } |
| | | // 设置请求头 |
| | | return config |
| | | }, error => { |
| | | return Promise.reject(error) |
| | | }); |
| | | |
| | | // response 拦截器 |
| | | // 可以在接口响应后统一处理结果 |
| | | request.interceptors.response.use( |
| | | response => { |
| | | let res = response.data |
| | | //传递报错信息,把报错信息传递到pinia中 |
| | | userStore.setResponseCode(parseInt(res.code),res.msg) |
| | | if((res.code != 200 && res.code != '200')){ |
| | | if(response.config.responseType !== 'blob'){ |
| | | return Promise.reject(res.code) |
| | | } |
| | | } |
| | | |
| | | // 如果是返回的文件 |
| | | if (response.config.responseType === 'blob') { |
| | | return res |
| | | } |
| | | // 兼容服务端返回的字符串数据 |
| | | if (typeof res === 'string') { |
| | | res = res ? JSON.parse(res) : res |
| | | } |
| | | return res; |
| | | }, |
| | | error => { |
| | | console.log('err' + error) // for debug |
| | | return Promise.reject(error) |
| | | } |
| | | ) |
| | | |
| | | |
| | | export default request |
| | | |
| | |
| | | import {Connection} from "@element-plus/icons-vue"; |
| | | import {useRoute, useRouter} from "vue-router"; |
| | | import useOrderInfoStore from "@/stores/sd/order/orderInfo"; |
| | | import requestOptimize from "@/utils/requestOptimize"; |
| | | |
| | | const router = useRouter() |
| | | const orderInfo = useOrderInfoStore() |
| | |
| | | isRunning.value = true; |
| | | intervalId = setInterval(() => { |
| | | seconds.value++; |
| | | progress.value += 1; |
| | | if (progress.value >= 100) { |
| | | progress.value = 100; |
| | | clearInterval(intervalId); |
| | | // 最大只到99% |
| | | if (progress.value < 99) { |
| | | progress.value += 1; |
| | | } |
| | | }, 1000); |
| | | } |
| | | |
| | | // 发送请求到真实接口 |
| | | requestOptimize.post('/api/optimize', props.optimizeData, {timeout: 300000}) |
| | | .then((response) => { |
| | | // 处理响应数据 |
| | | if (response.code === 200 && response.data) { |
| | | // 解析接口返回的数据 |
| | | const result = response.data; |
| | | |
| | | mockData.value = { |
| | | code: 200, |
| | | data: [{ |
| | | "projectNo": "P25051501", |
| | | "totalQuantity": 3, |
| | | "glassTotalQuantity": 52, |
| | | "glassTotalArea": "22.65", |
| | | "avgCutRate": "91.06", |
| | | "lastCutRate": "85.06", |
| | | "validCutRate": "95.63", |
| | | "layouts": [{ |
| | | "width": 3285.0, |
| | | "height": 2125.0, |
| | | "stockId": 1, |
| | | "realWidth": 3300.0, |
| | | "realHeight": 2140.0, |
| | | "usageRate": "0.9595522", |
| | | "stockCode": "138", |
| | | "upTrim": 0.0, |
| | | "downTrim": 15.0, |
| | | "leftTrim": 15.0, |
| | | "rightTrim": 0.0, |
| | | "quantity": 1, |
| | | "glassQuantity": 0, |
| | | "glassArea": 0.0, |
| | | "materialType": 1, |
| | | "mergeId": 1, |
| | | "glassDetails": [{ |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1100.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1102.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 17, |
| | | "stockSort": 1, |
| | | "polySort": 1, |
| | | "x": 0.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 0.0, |
| | | "Y": 1086.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 0.0, |
| | | "Y": 2125.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1102.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1102.0, |
| | | "Y": 2125.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1102.0, |
| | | "Y": 1086.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1102.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1098.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1100.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 21, |
| | | "stockSort": 1, |
| | | "polySort": 2, |
| | | "x": 1102.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 1102.0, |
| | | "Y": 1086.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1102.0, |
| | | "Y": 2125.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2202.0, |
| | | "Y": 2125.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2202.0, |
| | | "Y": 1086.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1058.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1060.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 5, |
| | | "stockSort": 1, |
| | | "polySort": 3, |
| | | "x": 2202.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2202.0, |
| | | "Y": 1086.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2202.0, |
| | | "Y": 2125.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1060.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3262.0, |
| | | "Y": 2125.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3262.0, |
| | | "Y": 1086.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1060.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1098.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1100.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 21, |
| | | "stockSort": 1, |
| | | "polySort": 4, |
| | | "x": 0.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 0.0, |
| | | "Y": 47.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 0.0, |
| | | "Y": 1086.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1100.0, |
| | | "Y": 1086.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1100.0, |
| | | "Y": 47.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1098.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1100.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 21, |
| | | "stockSort": 1, |
| | | "polySort": 5, |
| | | "x": 1100.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 1100.0, |
| | | "Y": 47.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1100.0, |
| | | "Y": 1086.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2200.0, |
| | | "Y": 1086.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2200.0, |
| | | "Y": 47.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1058.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1060.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 5, |
| | | "stockSort": 1, |
| | | "polySort": 6, |
| | | "x": 2200.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2200.0, |
| | | "Y": 47.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2200.0, |
| | | "Y": 1086.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1060.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3260.0, |
| | | "Y": 1086.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3260.0, |
| | | "Y": 47.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1060.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 25.0, |
| | | "realHeight": 1086.0, |
| | | "width": 25.0, |
| | | "height": 1086.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 1, |
| | | "polySort": 1, |
| | | "x": 3260.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 3260.0, |
| | | "realHeight": 47.0, |
| | | "width": 3260.0, |
| | | "height": 47.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 1, |
| | | "polySort": 2, |
| | | "x": 0.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 23.0, |
| | | "realHeight": 1039.0, |
| | | "width": 23.0, |
| | | "height": 1039.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 1, |
| | | "polySort": 3, |
| | | "x": 3262.0, |
| | | "y": 1086.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }] |
| | | }, { |
| | | "width": 3285.0, |
| | | "height": 2125.0, |
| | | "stockId": 2, |
| | | "realWidth": 3300.0, |
| | | "realHeight": 2140.0, |
| | | "usageRate": "0.9530787", |
| | | "stockCode": "138", |
| | | "upTrim": 0.0, |
| | | "downTrim": 15.0, |
| | | "leftTrim": 15.0, |
| | | "rightTrim": 0.0, |
| | | "quantity": 1, |
| | | "glassQuantity": 0, |
| | | "glassArea": 0.0, |
| | | "materialType": 1, |
| | | "mergeId": 2, |
| | | "glassDetails": [{ |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1085.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1087.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 20, |
| | | "stockSort": 2, |
| | | "polySort": 1, |
| | | "x": 0.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 0.0, |
| | | "Y": 1086.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 0.0, |
| | | "Y": 2125.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1087.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1087.0, |
| | | "Y": 2125.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1087.0, |
| | | "Y": 1086.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1087.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1055.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1057.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 8, |
| | | "stockSort": 2, |
| | | "polySort": 2, |
| | | "x": 1087.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 1087.0, |
| | | "Y": 1086.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1087.0, |
| | | "Y": 2125.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1057.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2144.0, |
| | | "Y": 2125.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2144.0, |
| | | "Y": 1086.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1057.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1098.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1100.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 21, |
| | | "stockSort": 2, |
| | | "polySort": 3, |
| | | "x": 2144.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2144.0, |
| | | "Y": 1086.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2144.0, |
| | | "Y": 2125.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3244.0, |
| | | "Y": 2125.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3244.0, |
| | | "Y": 1086.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1098.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1100.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 21, |
| | | "stockSort": 2, |
| | | "polySort": 4, |
| | | "x": 0.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 0.0, |
| | | "Y": 47.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 0.0, |
| | | "Y": 1086.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1100.0, |
| | | "Y": 1086.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1100.0, |
| | | "Y": 47.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1100.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1065.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1067.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 9, |
| | | "stockSort": 2, |
| | | "polySort": 5, |
| | | "x": 1100.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 1100.0, |
| | | "Y": 47.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1100.0, |
| | | "Y": 1086.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1067.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2167.0, |
| | | "Y": 1086.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2167.0, |
| | | "Y": 47.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1067.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1065.0, |
| | | "realHeight": 1037.0, |
| | | "width": 1067.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 9, |
| | | "stockSort": 2, |
| | | "polySort": 6, |
| | | "x": 2167.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2167.0, |
| | | "Y": 47.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2167.0, |
| | | "Y": 1086.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1067.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3234.0, |
| | | "Y": 1086.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3234.0, |
| | | "Y": 47.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1067.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 51.0, |
| | | "realHeight": 1086.0, |
| | | "width": 51.0, |
| | | "height": 1086.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 2, |
| | | "polySort": 1, |
| | | "x": 3234.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 3234.0, |
| | | "realHeight": 47.0, |
| | | "width": 3234.0, |
| | | "height": 47.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 2, |
| | | "polySort": 2, |
| | | "x": 0.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 41.0, |
| | | "realHeight": 1039.0, |
| | | "width": 41.0, |
| | | "height": 1039.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 2, |
| | | "polySort": 3, |
| | | "x": 3244.0, |
| | | "y": 1086.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }] |
| | | }, { |
| | | "width": 3755.0, |
| | | "height": 2835.0, |
| | | "stockId": 3, |
| | | "realWidth": 3770.0, |
| | | "realHeight": 2850.0, |
| | | "usageRate": "0.8505788", |
| | | "stockCode": "117", |
| | | "upTrim": 0.0, |
| | | "downTrim": 15.0, |
| | | "leftTrim": 15.0, |
| | | "rightTrim": 0.0, |
| | | "quantity": 1, |
| | | "glassQuantity": 0, |
| | | "glassArea": 0.0, |
| | | "materialType": 1, |
| | | "mergeId": 3, |
| | | "glassDetails": [{ |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1037.0, |
| | | "realHeight": 908.0, |
| | | "width": 1039.0, |
| | | "height": 910.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 19, |
| | | "stockSort": 3, |
| | | "polySort": 2, |
| | | "x": 0.0, |
| | | "y": 1007.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 0.0, |
| | | "Y": 1828.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 1828.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 910.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 918.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 0.0, |
| | | "Y": 918.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 910.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1037.0, |
| | | "realHeight": 1005.0, |
| | | "width": 1039.0, |
| | | "height": 1007.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 18, |
| | | "stockSort": 3, |
| | | "polySort": 1, |
| | | "x": 0.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 0.0, |
| | | "Y": 2835.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 2835.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1007.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 1828.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 0.0, |
| | | "Y": 1828.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1007.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1037.0, |
| | | "realHeight": 810.0, |
| | | "width": 1039.0, |
| | | "height": 812.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 12, |
| | | "stockSort": 3, |
| | | "polySort": 3, |
| | | "x": 0.0, |
| | | "y": 1917.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 0.0, |
| | | "Y": 918.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 918.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 812.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 106.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 0.0, |
| | | "Y": 106.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 812.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1037.0, |
| | | "realHeight": 908.0, |
| | | "width": 1039.0, |
| | | "height": 910.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 19, |
| | | "stockSort": 3, |
| | | "polySort": 5, |
| | | "x": 1039.0, |
| | | "y": 1032.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 1039.0, |
| | | "Y": 1803.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 1803.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 910.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 893.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 893.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 910.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1037.0, |
| | | "realHeight": 1030.0, |
| | | "width": 1039.0, |
| | | "height": 1032.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 10, |
| | | "stockSort": 3, |
| | | "polySort": 4, |
| | | "x": 1039.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 1039.0, |
| | | "Y": 2835.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 2835.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1032.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 1803.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 1803.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1032.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 1037.0, |
| | | "realHeight": 823.0, |
| | | "width": 1039.0, |
| | | "height": 825.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 13, |
| | | "stockSort": 3, |
| | | "polySort": 6, |
| | | "x": 1039.0, |
| | | "y": 1942.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 1039.0, |
| | | "Y": 893.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 893.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 68.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 1039.0, |
| | | "Y": 68.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 823.0, |
| | | "realHeight": 1037.0, |
| | | "width": 825.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 13, |
| | | "stockSort": 3, |
| | | "polySort": 7, |
| | | "x": 2078.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2078.0, |
| | | "Y": 1796.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 2835.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2903.0, |
| | | "Y": 2835.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2903.0, |
| | | "Y": 1796.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 823.0, |
| | | "realHeight": 1037.0, |
| | | "width": 825.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 13, |
| | | "stockSort": 3, |
| | | "polySort": 9, |
| | | "x": 2078.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2078.0, |
| | | "Y": 757.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2078.0, |
| | | "Y": 1796.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2903.0, |
| | | "Y": 1796.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2903.0, |
| | | "Y": 757.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 823.0, |
| | | "realHeight": 1037.0, |
| | | "width": 825.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 13, |
| | | "stockSort": 3, |
| | | "polySort": 8, |
| | | "x": 2903.0, |
| | | "y": 0.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2903.0, |
| | | "Y": 1796.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2903.0, |
| | | "Y": 2835.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3728.0, |
| | | "Y": 2835.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3728.0, |
| | | "Y": 1796.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": false, |
| | | "isRotate": false, |
| | | "realWidth": 823.0, |
| | | "realHeight": 1037.0, |
| | | "width": 825.0, |
| | | "height": 1039.0, |
| | | "processId": "NG24090106A003", |
| | | "layer": 2, |
| | | "totalLayer": 1, |
| | | "orderSort": 13, |
| | | "stockSort": 3, |
| | | "polySort": 10, |
| | | "x": 2903.0, |
| | | "y": 1039.0, |
| | | "markIcon": "{\"trademark\":\"3C\",\"xImage\":false,\"yImage\":false,\"tag\":true,\"tag2\":true,\"tag3\":true,\"xMargin\":30,\"yMargin\":30,\"location\":\"右下\"}", |
| | | "patchState": 0, |
| | | "rackNo": "0", |
| | | "glassPoint": [{ |
| | | "X": 2903.0, |
| | | "Y": 757.0, |
| | | "theta": 1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 0, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 2903.0, |
| | | "Y": 1796.0, |
| | | "theta": 0.0, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 3, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3728.0, |
| | | "Y": 1796.0, |
| | | "theta": -1.5707963267948966, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 1039.0, |
| | | "index": 2, |
| | | "L": 1.0 |
| | | }, { |
| | | "X": 3728.0, |
| | | "Y": 757.0, |
| | | "theta": 3.1415926535897931, |
| | | "angle": 1.5707963705062866, |
| | | "distance": 825.0, |
| | | "index": 1, |
| | | "L": 1.0 |
| | | }] |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 1039.0, |
| | | "realHeight": 106.0, |
| | | "width": 1039.0, |
| | | "height": 106.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 3, |
| | | "polySort": 1, |
| | | "x": 0.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 27.0, |
| | | "realHeight": 2835.0, |
| | | "width": 27.0, |
| | | "height": 2835.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 3, |
| | | "polySort": 2, |
| | | "x": 3728.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 1039.0, |
| | | "realHeight": 68.0, |
| | | "width": 1039.0, |
| | | "height": 68.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 3, |
| | | "polySort": 3, |
| | | "x": 1039.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }, { |
| | | "isRemain": true, |
| | | "isRotate": false, |
| | | "realWidth": 1650.0, |
| | | "realHeight": 757.0, |
| | | "width": 1650.0, |
| | | "height": 757.0, |
| | | "processId": null, |
| | | "layer": 0, |
| | | "totalLayer": 0, |
| | | "orderSort": 0, |
| | | "stockSort": 3, |
| | | "polySort": 4, |
| | | "x": 2078.0, |
| | | "y": 0.0, |
| | | "markIcon": null, |
| | | "patchState": 0, |
| | | "rackNo": null, |
| | | "glassPoint": null |
| | | }] |
| | | }] |
| | | }] |
| | | } |
| | | // 更新 store 数据 |
| | | orderInfo.optimizeData.optimalResults = result.layouts[0]; |
| | | orderInfo.optimizeData.originalFilm = originalFilm.value; |
| | | |
| | | // 更新利用率 |
| | | totalUtilizationRate.value = result.avgCutRate; |
| | | tailPieceRate.value = result.lastCutRate; |
| | | |
| | | // 显示成功提示 |
| | | ElMessage.success('优化完成'); |
| | | } else { |
| | | // 显示失败提示 |
| | | ElMessage.error(response.msg || '优化失败'); |
| | | } |
| | | }) |
| | | .catch((error) => { |
| | | // 捕获网络错误 |
| | | console.error('优化请求失败:', error); |
| | | ElMessage.error('网络异常,请检查接口'); |
| | | }) |
| | | .finally(() => { |
| | | // 在请求完成时将进度条设为100% |
| | | progress.value = 100; |
| | | // 启用按钮 |
| | | document.getElementById("start").disabled = false; |
| | | // 显示完成按钮 |
| | | document.getElementById("complete").style.display = "block"; |
| | | // 停止定时器 |
| | | pauseTimer(); |
| | | }); |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | }; |
| | | |
| | | const pauseTimer = () => { |
| | | if (isRunning.value) { |
| | | clearInterval(intervalId); |
| | |
| | | }; |
| | | |
| | | watch( |
| | | ()=> [progress.value], |
| | | ([newValue])=> { |
| | | if(progress.value===10){ |
| | | orderInfo.optimizeData.optimalResults=mockData.value.data[0] |
| | | mockData.value.data[0].layouts.forEach(items=>{ |
| | | () => progress.value, |
| | | (newValue) => { |
| | | if (newValue === 10) { |
| | | // 根据接口返回的 layouts 数据构建版图统计 |
| | | const layouts = orderInfo.optimizeData.optimalResults.layouts; |
| | | originalFilm.value = []; |
| | | |
| | | // 根据唯一标识(如 id)查找是否已存在 |
| | | const existingItem = originalFilm.value.find(item => item["width"] === items["width"]&&item["height"] === items["height"]); |
| | | layouts.forEach(items => { |
| | | const existingItem = originalFilm.value.find( |
| | | item => item.width === items.width && item.height === items.height |
| | | ); |
| | | |
| | | if (existingItem) { |
| | | // 存在:数量加1(假设字段为 count) |
| | | existingItem.count += 1; |
| | | } else { |
| | | // 不存在:新增到数组(初始化 count=1) |
| | | const array={ |
| | | width:items["width"], |
| | | height:items["height"], |
| | | upTrim:items["upTrim"], |
| | | downTrim:items["downTrim"], |
| | | leftTrim:items["leftTrim"], |
| | | rightTrim:items["rightTrim"], |
| | | stockCode:items["stockCode"], |
| | | count:1 |
| | | } |
| | | originalFilm.value.push(array); |
| | | originalFilm.value.push({ |
| | | width: items.width, |
| | | height: items.height, |
| | | upTrim: items.upTrim, |
| | | downTrim: items.downTrim, |
| | | leftTrim: items.leftTrim, |
| | | rightTrim: items.rightTrim, |
| | | stockCode: items.stockCode, |
| | | count: 1 |
| | | }); |
| | | } |
| | | |
| | | }) |
| | | orderInfo.optimizeData.originalFilm=originalFilm.value |
| | | totalUtilizationRate.value=mockData.value.data[0].avgCutRate |
| | | tailPieceRate.value=mockData.value.data[0].lastCutRate |
| | | pauseTimer() |
| | | document.getElementById("complete").style.display="block" |
| | | document.getElementById("start").disabled=false |
| | | }); |
| | | } |
| | | }); |
| | | } |
| | | ); |
| | | |
| | | |
| | | </script> |
| | | |
| | |
| | | <div id="box"> |
| | | <span style="font-size: 20px">优化进度</span> |
| | | <div class="progress-bar"> |
| | | <el-progress :percentage="progress" |
| | | :text-inside="true" |
| | | :stroke-width="20" |
| | | status="success" |
| | | striped |
| | | striped-flow |
| | | duration="45"/> |
| | | <el-progress :percentage="progress" |
| | | :text-inside="true" |
| | | :stroke-width="20" |
| | | status="success" |
| | | :striped="true" |
| | | :striped-flow="progress < 100" |
| | | :duration="progress < 100 ? 45 : 0" |
| | | /> |
| | | </div> |
| | | <div style="height: 250px; margin-top: 20px; border: 2px solid #e6e6e6; padding: 10px; border-radius: 5px;"> |
| | | <span style="font-weight: bold">当前结果</span><br/> |