#
luxiaotao1123
2022-04-07 82e858eff40dc40f1d3288949681e1535c8fc6b3
static/js/object/StaTask.js
@@ -1,10 +1,10 @@
import {InitPallet, InitGoods} from './StoreGoods.js';
// 输送线当前运行状态对象
function StaTask(staData, object) {
    let that = this;
    that.object = object;
    that.no = 0;
    that.run = false;
@@ -13,10 +13,17 @@
    that.inlet = -1;
    that.outlet = -1;
    that.position = null;
    let init = function () {
        that.no = staData.no;
        that.inlet = staData.inlet;
        that.outlet = staData.outlet;
        let item = getArrVal(conveyObjects.objects, "no", that.no+"");
        if (!that.position && item) {
            that.position = item.position;
        }
    }
    init();
@@ -31,8 +38,8 @@
            // 1.入库第一站 【新增】
            if (that.inlet === 1) {
                InitPallet(that.object, [{wrkNo: staData.wrkNo}], {position: that.position}, 2);
                InitGoods(that.object, [{wrkNo: staData.wrkNo}], {position: that.position}, 2);
            // 2.来自其他站点的货物 【移动】
            } else {
@@ -52,7 +59,7 @@
        // 实时更新
        that.loaded = staData.loaded;
        that.run = true;
        // that.run = true;
    }