zjj
2025-05-13 d435ab589006cf9909501a69e55a3778d2dcca70
#AGV启动入库
4个文件已修改
104 ■■■■■ 已修改文件
pages/AGV/AGVStaBind.vue 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/AGV/StaUnBind.vue 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/AGV/StartInTask.vue 79 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/home/index.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/AGV/AGVStaBind.vue
@@ -40,18 +40,11 @@
                    </view>
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">供应商批次:</text>
                    </view>
                    <view class="action">
                        <text class="text-grey">{{item.splrBatch}}</text>
                    </view>
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">库存批次:</text>
                        <text class="text-black">批次:</text>
                    </view>
                    <view class="action">
                        <text class="text-grey ">{{item.batch}}</text>
pages/AGV/StaUnBind.vue
@@ -38,19 +38,9 @@
                        <text class="text-grey ">{{item.asnCode}}</text>
                    </view>
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">供应商批次:</text>
                    </view>
                    <view class="action">
                        <text class="text-grey">{{item.splrBatch}}</text>
                    </view>
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">库存批次:</text>
                        <text class="text-black">批次:</text>
                    </view>
                    <view class="action">
                        <text class="text-grey ">{{item.batch}}</text>
pages/AGV/StartInTask.vue
@@ -5,7 +5,14 @@
                <view class="title">接驳站</view>
                <input placeholder="请扫描接驳站条码" v-model="barcode" ></input>
                <text class='cuIcon-search text-blue' @click="search"></text>
            </view>
            </view>
            <view class="cu-form-group">
                <view class="title">目标库区</view>
                <view style="width: 75%;">
                    <uni-data-select style="min-width: 50%; max-width: 100%;" v-model="whAreaId" :localdata="range"
                        placement="bottom" @change="selChange"></uni-data-select>
                </view>
            </view>
        </form>
        <view class="flex solid-bottom padding-sm justify-between">
            <view class="text-blue">容器码:{{container}}</view>
@@ -38,19 +45,9 @@
                        <text class="text-grey ">{{item.asnCode}}</text>
                    </view>
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">供应商批次:</text>
                    </view>
                    <view class="action">
                        <text class="text-grey">{{item.splrBatch}}</text>
                    </view>
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">库存批次:</text>
                        <text class="text-black">批次:</text>
                    </view>
                    <view class="action">
                        <text class="text-grey ">{{item.batch}}</text>
@@ -73,30 +70,10 @@
        <view class="cu-bar btn-group foot">
            <button class="cu-btn text-blue line-blue shadow" @click="clear">清空</button>
            <button class="cu-btn bg-blue shadow-blur" @click="confirm">解绑</button>
            <button class="cu-btn bg-blue shadow-blur" :disabled="repeatClick" @click="confirm">启动</button>
        </view>
        <uni-popup ref="popup" class="cu-popup">
            <view class="popup-content">
                <view class="head">
                    <text>推荐</text>
                    <text class='cuIcon-close text-red close' @click="close"></text>
                </view>
                <div class="body">
                    <view class="cu-list grid col-3 no-border">
                        <view class="item" v-for="el in range">
                            <view class="cu-btn round  sm" :class="[el===curCode?'bg-blue':'line-blue']"
                                @click="itemChange(el)">{{el}}</view>
                        </view>
                    </view>
                </div>
                <view class="cu-bar btn-group ">
                    <button class="cu-btn bg-blue shadow-blur" @click="popupSubmit">提交</button>
                </view>
            </view>
        </uni-popup>
    </view>
</template>
@@ -120,14 +97,20 @@
                container: '',
                list: [],
                range: [],
                curCode: ''
                curCode: '',
                whAreaId:'',
                repeatClick: false,
            }
        },
        computed: {
            ...mapState('user', ['dynamicFields']),
        },
        mounted() {},
        methods: {
        methods: {
            selChange(val) {
                uni.setStorageSync('whAreaId', val)
            },
            async search() {
                let that = this
                const {
@@ -141,7 +124,12 @@
                    if(data.list.length >0){
                        that.container = data.barcode                        
                        that.list = data.list
                    }
                    }
                    that.range = data.warehouseAreasList.map(item => ({
                        value: item.id,
                        text: item.name
                    }));
                    that.whAreaId = data.area
                } else {
                    uni.showToast({
                        title: msg,
@@ -183,17 +171,26 @@
                    })
                    return ;
                }
                if(this.whAreaId === '' || this.whAreaId ===null){
                    uni.showToast({
                        title: "目标库区不能为空",
                        icon: "none",
                    })
                    return ;
                }
                this.repeatClick = true
                const {
                    code,
                    data,
                    msg
                } = await request('/AGV/staUnBind',{
                        sta: this.barcode
                } = await request('/AGV/task/start',{
                        sta: this.barcode,
                        area: this.whAreaId
                    }
                )
                if (code === 200) {
                    uni.showToast({
                        title: '解绑成功'
                        title: '启动成功'
                    })
                    this.clear()
                } else {
@@ -202,7 +199,7 @@
                        icon: "none",
                    })
                }
                this.repeatClick = false
            },
pages/home/index.vue
@@ -108,7 +108,7 @@
                </navigator>
            </view>
            <view class="cu-item">
                <navigator hover-class='none' url="/pages/AGV/AGVStaBind" navigateTo>
                <navigator hover-class='none' url="/pages/AGV/StartInTask" navigateTo>
                    <view class="cuIcon-punch text-blue">
                    </view>
                    <text>启动入库</text>