| | |
| | | </dependencies> |
| | | |
| | | <build> |
| | | <finalName>jmwcs</finalName> |
| | | <finalName>jgwcs</finalName> |
| | | <plugins> |
| | | <plugin> |
| | | <groupId>org.springframework.boot</groupId> |
| | |
| | | background-color: rgb(157, 217, 162); |
| | | font-size: 10px; |
| | | } |
| | | .uTrack { |
| | | position: absolute; |
| | | display: inline-block; |
| | | border-top: 2px solid #000; |
| | | border-left: 2px solid #000; |
| | | border-bottom: 2px solid #000; |
| | | border-radius: 50px 0 0 50px; |
| | | z-index: 5; |
| | | } |
| | | /* 16 */ |
| | | .btn-16 { |
| | | border: none; |
| | |
| | | var baseUrl = "/jmwcs"; |
| | | var baseUrl = "/jgwcs"; |
| | | |
| | | // 赋值 |
| | | function setVal(el, val) { |
| | |
| | | crns = '', |
| | | track = '', |
| | | tracks = '', |
| | | uTrack = '', |
| | | uTracks = '', |
| | | stn = '', |
| | | barcode = '', |
| | | stns = '', |
| | |
| | | let bLen |
| | | let interval // 间隔数 |
| | | |
| | | if (maxBayNo<35) { |
| | | if (maxBayNo<40) { |
| | | interval = 1 |
| | | bLen = maxBayNo / interval // 库位个数 |
| | | } else { |
| | |
| | | } |
| | | } |
| | | } |
| | | bayWidth = (rackss[i].width / bLen)-4 |
| | | bayWidth = (rackss[i].width / bLen) |
| | | // hpPosition 0 表示货架序号 左->右 1 表示货架序号 左<-右 |
| | | if (mapInfo.hpPosition == 1) { |
| | | bNum = maxBayNo |
| | |
| | | }else { |
| | | bNum = minBayNo |
| | | for (let j = 0; j < bLen; j++) { |
| | | if (i === 0) { |
| | | if (j === 15 || j === 16) { |
| | | bay = "<button class='item' style='width: "+ 80 +"px'>" + bNum + "</button>" |
| | | bays = bays + bay |
| | | bNum = bNum + interval; |
| | | continue |
| | | } |
| | | bay = "<button class='item' style='width: "+ bayWidth +"px'>" + bNum + "</button>" |
| | | bays = bays + bay |
| | | bNum = bNum + interval; |
| | | continue |
| | | } |
| | | if (j === 15) { |
| | | bay = "<button class='item' style='margin-left: 160px;width: "+ bayWidth +"px'>" + (bNum + 4) + "</button>" |
| | | bays = bays + bay |
| | | bNum = bNum + interval + 4; |
| | | continue |
| | | } |
| | | bay = "<button class='item' style='width: "+ bayWidth +"px'>" + bNum + "</button>" |
| | | bays = bays + bay |
| | | bNum = bNum + interval; |
| | |
| | | "px;left: "+ crnss[i].left + |
| | | "px'></div>" |
| | | crns = crns + crn |
| | | } else if(crnss[i].type == 'uTrack'){ |
| | | uTrack = "<div class='uTrack' id='" + crnss[i].id + |
| | | "'style='width:"+ crnss[i].width + |
| | | "px;height: "+ crnss[i].height+ |
| | | "px;top: "+ crnss[i].top + |
| | | "px;left: "+ crnss[i].left + |
| | | "px'>" + crnss[i].text + "</div>" |
| | | uTracks = uTracks + uTrack |
| | | } else { |
| | | track = "<div class='track' id='" + crnss[i].id + |
| | | "'style='width:"+ crnss[i].width + |
| | |
| | | } |
| | | |
| | | } |
| | | floorInfo = racks + rackDescs + tracks + crns + stnArr[0] + floorBtnss + barcodeArr[0] |
| | | floorInfo = racks + rackDescs + tracks + uTracks + crns + stnArr[0] + floorBtnss + barcodeArr[0] |
| | | |
| | | $(".main-part").append(floorInfo) |
| | | $("#line-total").html(total[0]) |
| | |
| | | } |
| | | function changFloor(e) { |
| | | $(".main-part").empty() // 清空节点 |
| | | floorInfo = racks + stnArr[e] +rackDescs + crns + tracks + floorBtnss + barcodeArr[e] |
| | | floorInfo = racks + stnArr[e] +rackDescs + crns + tracks + uTracks + floorBtnss + barcodeArr[e] |
| | | $(".main-part").append(floorInfo) |
| | | $("#line-total").empty() |
| | | $("#line-total").html(total[e]) |
| | |
| | | mapInfo = { |
| | | "mapName": "JXJMWCS", |
| | | "mapName": "XCJGWCS", |
| | | "rackCount": 18, |
| | | "crnCount": 7, |
| | | "stbCount": 77, |
| | |
| | | { |
| | | "type": "rack", |
| | | "id": "rack1", |
| | | "top": 296, |
| | | "top": 100, |
| | | "left": 370, |
| | | "width": 1200, |
| | | "width": 1224, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 15 |
| | | "maxBayNo": 36 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack2", |
| | | "top": 375, |
| | | "top": 130, |
| | | "left": 370, |
| | | "width": 1200, |
| | | "width": 1224, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 15 |
| | | "maxBayNo": 36 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack3", |
| | | "top": 403, |
| | | "top": 160, |
| | | "left": 370, |
| | | "width": 1200, |
| | | "width": 1224, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 15 |
| | | "maxBayNo": 36 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack4", |
| | | "top": 470, |
| | | "top": 190, |
| | | "left": 370, |
| | | "width": 1200, |
| | | "width": 1122, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 15 |
| | | "maxBayNo": 33 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack5", |
| | | "top": 230, |
| | | "left": 403, |
| | | "width": 1104, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 24 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack6", |
| | | "top": 260, |
| | | "left": 403, |
| | | "width": 1104, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 24 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack7", |
| | | "top": 440, |
| | | "left": 403, |
| | | "width": 1242, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 27 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack8", |
| | | "top": 470, |
| | | "left": 403, |
| | | "width": 1242, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 27 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack9", |
| | | "top": 500, |
| | | "left": 403, |
| | | "width": 1242, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 27 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack10", |
| | | "top": 530, |
| | | "left": 403, |
| | | "width": 1242, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 27 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack11", |
| | | "top": 610, |
| | | "left": 403, |
| | | "width": 1242, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 27 |
| | | }, |
| | | { |
| | | "type": "rack", |
| | | "id": "rack12", |
| | | "top": 640, |
| | | "left": 403, |
| | | "width": 1242, |
| | | "height": 26, |
| | | "minBayNo": 1, |
| | | "maxBayNo": 27 |
| | | }, |
| | | ], |
| | | "rackDescs": [ |
| | |
| | | "id": "crn-1", |
| | | "text": "1", |
| | | "top": 334, |
| | | "left": 1417, |
| | | "left": 1552, |
| | | "width": 93, |
| | | "height": 22 |
| | | }, |
| | | { |
| | | "type": "track", |
| | | "type": "uTrack", |
| | | "id": "lb_track2", |
| | | "text": "", |
| | | "top": 452, |
| | | "top": 400, |
| | | "left": 300, |
| | | "width": 1300, |
| | | "height": 2 |
| | | "width": 1400, |
| | | "height": 180 |
| | | }, |
| | | { |
| | | "type": "crane", |
| | | "id": "crn-2", |
| | | "text": "2", |
| | | "top": 440, |
| | | "left": 1417, |
| | | "top": 388, |
| | | "left": 1552, |
| | | "width": 93, |
| | | "height": 22 |
| | | }, |
| | |
| | | "width": 1845, |
| | | "height": 676, |
| | | "floors": [ |
| | | { |
| | | "type": "floor", |
| | | "id": "page_floor1", |
| | | "text": "1F", |
| | | "top": 4, |
| | | "left": 22, |
| | | "width": 1819, |
| | | "height": 668, |
| | | "stns": [ |
| | | { |
| | | "type": "stn", |
| | | "id": "site-105", |
| | | "text": "105", |
| | | "top": 403, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-102", |
| | | "text": "102", |
| | | "top": 377, |
| | | "left": 273, |
| | | "width": 95, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-104", |
| | | "text": "104", |
| | | "top": 377, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-101", |
| | | "text": "101", |
| | | "top": 403, |
| | | "left": 273, |
| | | "width": 95, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-103", |
| | | "text": "103", |
| | | "top": 429, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-100", |
| | | "text": "100", |
| | | "top": 477, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-110", |
| | | "text": "110", |
| | | "top": 376, |
| | | "left": 1512, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-111", |
| | | "text": "111", |
| | | "top": 403, |
| | | "left": 1512, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-112", |
| | | "text": "112", |
| | | "top": 376, |
| | | "left": 1592, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-113", |
| | | "text": "113", |
| | | "top": 403, |
| | | "left": 1592, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-114", |
| | | "text": "114", |
| | | "top": 376, |
| | | "left": 1672, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-115", |
| | | "text": "115", |
| | | "top": 403, |
| | | "left": 1672, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-116", |
| | | "text": "116", |
| | | "top": 350, |
| | | "left": 1672, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-117", |
| | | "text": "117", |
| | | "top": 324, |
| | | "left": 1672, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | ], |
| | | "barcode": [ |
| | | { |
| | | "type": "barcode", |
| | | "id": "barcode-1", |
| | | "text": "", |
| | | "top": 454, |
| | | "left": 192, |
| | | "width": 78, |
| | | "height": 20 |
| | | } |
| | | ] |
| | | }, |
| | | { |
| | | "type": "floor", |
| | | "id": "page_floor1", |
| | | "text": "5F", |
| | | "top": 4, |
| | | "left": 22, |
| | | "width": 1819, |
| | | "height": 668, |
| | | "stns": [ |
| | | { |
| | | "type": "stn", |
| | | "id": "site-505", |
| | | "text": "505", |
| | | "top": 403, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-502", |
| | | "text": "502", |
| | | "top": 377, |
| | | "left": 273, |
| | | "width": 95, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-504", |
| | | "text": "504", |
| | | "top": 377, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-501", |
| | | "text": "501", |
| | | "top": 403, |
| | | "left": 273, |
| | | "width": 95, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-503", |
| | | "text": "503", |
| | | "top": 429, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | { |
| | | "type": "stn", |
| | | "id": "site-500", |
| | | "text": "500", |
| | | "top": 477, |
| | | "left": 193, |
| | | "width": 78, |
| | | "height": 24 |
| | | }, |
| | | ], |
| | | "barcode": [ |
| | | { |
| | | "type": "barcode", |
| | | "id": "barcode-2", |
| | | "text": "", |
| | | "top": 454, |
| | | "left": 192, |
| | | "width": 78, |
| | | "height": 20 |
| | | } |
| | | ] |
| | | }, |
| | | //{ |
| | | // "type": "floor", |
| | | // "id": "page_floor1", |
| | | // "text": "1F", |
| | | // "top": 4, |
| | | // "left": 22, |
| | | // "width": 1819, |
| | | // "height": 668, |
| | | // "stns": [ |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-105", |
| | | // "text": "105", |
| | | // "top": 403, |
| | | // "left": 193, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-102", |
| | | // "text": "102", |
| | | // "top": 377, |
| | | // "left": 273, |
| | | // "width": 95, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-104", |
| | | // "text": "104", |
| | | // "top": 377, |
| | | // "left": 193, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-101", |
| | | // "text": "101", |
| | | // "top": 403, |
| | | // "left": 273, |
| | | // "width": 95, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-103", |
| | | // "text": "103", |
| | | // "top": 429, |
| | | // "left": 193, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-100", |
| | | // "text": "100", |
| | | // "top": 477, |
| | | // "left": 193, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-110", |
| | | // "text": "110", |
| | | // "top": 376, |
| | | // "left": 1512, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-111", |
| | | // "text": "111", |
| | | // "top": 403, |
| | | // "left": 1512, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-112", |
| | | // "text": "112", |
| | | // "top": 376, |
| | | // "left": 1592, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-113", |
| | | // "text": "113", |
| | | // "top": 403, |
| | | // "left": 1592, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-114", |
| | | // "text": "114", |
| | | // "top": 376, |
| | | // "left": 1672, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-115", |
| | | // "text": "115", |
| | | // "top": 403, |
| | | // "left": 1672, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-116", |
| | | // "text": "116", |
| | | // "top": 350, |
| | | // "left": 1672, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // { |
| | | // "type": "stn", |
| | | // "id": "site-117", |
| | | // "text": "117", |
| | | // "top": 324, |
| | | // "left": 1672, |
| | | // "width": 78, |
| | | // "height": 24 |
| | | // }, |
| | | // ], |
| | | // "barcode": [ |
| | | // { |
| | | // "type": "barcode", |
| | | // "id": "barcode-1", |
| | | // "text": "", |
| | | // "top": 454, |
| | | // "left": 192, |
| | | // "width": 78, |
| | | // "height": 20 |
| | | // } |
| | | // ] |
| | | //}, |
| | | ] |
| | | } |
| | | ] |
| | |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | method: 'POST', |
| | | success: function (res) { |
| | | // console.log(res) |
| | | if (res.code === 200) { |
| | | var crns = res.data; |
| | | for (var i = 0; i < crns.length; i++) { |
| | | var crnEl = $("#crn-" + crns[i].crnId); |
| | | crnEl.attr("class", "machine " + crns[i].crnStatus); |
| | | var unit = 0;//($('.item').eq(0).width() + 13) / 2; |
| | | |
| | | var unit = 0; |
| | | if (crns[i].bay < 0 || crns[i].bay === -2) { |
| | | crns[i].bay = 1 |
| | | } |
| | | // crnEl.animate({left: (crns[i].bay * unit) + 'px'}, 1000); |
| | | // crns[i].bay = 15; |
| | | |
| | | var offSet = 0; |
| | | unit = -28.5; |
| | | offSet = 276; //145 |
| | | offSet = 1552; |
| | | |
| | | |
| | | // crnEl.animate({left: offSet + 'px'}, 1000); |
| | | if(crns[i].bay === 1){ |
| | | crnEl.animate({left: offSet + 'px'}, 1000); |
| | | if (i == 1) { |
| | | if (crns[i].bay < 27) { |
| | | crnEl.animate() |
| | | } |
| | | } else { |
| | | crnEl.animate({left: offSet + 'px'}, 1000); |
| | | } |
| | | |
| | | } else { |
| | | crnEl.animate({left: (offSet - unit + (crns[i].bay * unit)) + 'px'}, 1000); |
| | | } |