#
zjj
2024-04-23 01a2d01abeadef5488a100ddf58a22dbcf7b95d6
src/main/webapp/views/console.html
@@ -24,10 +24,13 @@
                <img src="../static/images/zy-logo.png" alt="中扬" height="44" width="80">
            </div>
        </div>
        <!-- 货架 + 堆垛机 + 入库站点 -->
        <div class="main-part">
        <div style="width: 1000px;height: 800px;overflow: hidden">
            <!-- 货架 + 堆垛机 + 入库站点 -->
            <div class="main-part">
            </div>
        </div>
        <div id="body">
            <!-- 总开关 -->
            <div class="system-state">
@@ -344,7 +347,6 @@
            url: baseUrl + '/console/barcode/output/site',
            method: 'GET',
            success: function (res) {
                console.log(res)
                if (res.code === 200) {
                    tData = eval(res.data);
                    if (tData.length <= 5) {
@@ -589,27 +591,30 @@
            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 = 60;
                        offSet = 350;
                        unit = -28.5;
                        offSet = 1552;
                        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);
                        }
@@ -634,7 +639,7 @@
                if (res.code === 200) {
                    var barcodes = res.data;
                    for (var i = 0; i < barcodes.length; i++) {
                        $("#code-decoder-data-" + barcodes[i].barcodeId).html(barcodes[i].codeValue);
                        $("#barcode-"+barcodes[i].barcodeId).html(barcodes[i].codeValue ? barcodes[i].codeValue : "--");
                    }
                } else if (res.code === 403) {
                    parent.location.href = baseUrl + "/login";