cdk
2025-09-10 a683d399538b38ba07a8ef89efd1320bfc0818f8
增加agv点位
已修改2个文件
42 ■■■■■ 文件已修改
H5/Cpdbsj.aspx 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/Js/Cpbdsj.js 28 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/Cpdbsj.aspx
@@ -159,6 +159,16 @@
                    </template>
                </van-field>
                <van-field
                    ref="AgvDw"
                    v-model="AgvDw"
                    label="点位"
                    placeholder="请选择点位"
                    autofocus="true"
                    @click.native="selectDW">
                </van-field>
                <van-field
                    ref="xtName"
                    v-model="xtName"
@@ -199,6 +209,8 @@
        </div>
        <van-action-sheet v-model="show" :actions="actions" @select="onSelect" ></van-action-sheet>
        <van-action-sheet v-model="showAgvDw" :actions="actionsAgvDw" @select="onSelectAgvDw" ></van-action-sheet>
        <van-tabs color="#000" title-active-color="#0283EF">
            <van-tab title="箱明细" class="mySolid font">
@@ -253,5 +265,5 @@
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolder4" Runat="Server">
    <script src="Js/Cpbdsj.js?<%=12111111421514 %>"></script>
    <script src="Js/Cpbdsj.js?<%=1212111421515 %>"></script>
</asp:Content>
H5/Js/Cpbdsj.js
@@ -32,7 +32,10 @@
            actions: [],//列表的值
            xtName: "",//线体名称
            xtNum: "",//线体编号
            AgvDw: "",//AGV点位
            agvChecked: false,//是否勾选AGV
            showAgvDw: false,//点位展示
            actionsAgvDw: [],//列表AGV点位
        }
    },
    mounted() {
@@ -43,6 +46,13 @@
        };
    },
    methods: {
        handleAgvPositions(positionStr) {
            if (!positionStr) return [];
            // 将字符串按逗号分割并转换为选项数组
            return positionStr.split(',').map(pos => ({
                name: pos.trim() // 去除可能的空格
            }));
        },
        getKbBarInfo() {
            var that = this;
            that.isLoading = true;
@@ -52,13 +62,18 @@
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        console.log(json.data.tbBillList.kbBarInfo[0].agvPostion);
                        that.KbBarInfo = json.data.tbBillList.kbBarInfo[0];
                        that.DAA001 = that.KbBarInfo.daA001;
                        that.KbBarMxInfo = json.data.tbBillList.kbBarMxInfo;
                        that.$refs.XBar.focus();
                        that.XbarInfo = [];
                        that.XBar = "";
                        that.AgvDw = json.data.tbBillList.kbBarInfo[0].agvPostion.split(',')[0];
                        that.actionsAgvDw = that.handleAgvPositions(json.data.tbBillList.kbBarInfo[0].agvPostion);
                    }
                    else {
                        that.$playSound('error');
@@ -371,6 +386,16 @@
            this.xtName = action.name;  // 绑定name到xtName字段
            this.show = false;
        },
        onSelectAgvDw(action) {
            this.AgvDw = action.name;
            this.showAgvDw = false;
        },
        selectDW() {
            this.showAgvDw = true;
        },
        //获取可呼叫AGV的线体
        selectXt() {
            this.show = true;
@@ -449,7 +474,8 @@
            that.isLoading = true;
            that.AxiosHttp("post", 'Womdaa/handleAGVInspection', {
                KbBar: that.KbBar,
                userAccount: that.userInfo.loginAccount
                userAccount: that.userInfo.loginAccount,
                AgvDw: that.AgvDw
            }, false)
                .then(function (res) {
                    var json = res;