#
zhou zhou
1 天以前 629c4afb413904f4b6e83ea4d8224fb981da7113
#
2个文件已修改
255 ■■■■ 已修改文件
pages/outbound/container_rebinding/container_rebinding.vue 195 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/outbound/orderOut/orderDetlList.vue 60 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/outbound/container_rebinding/container_rebinding.vue
@@ -6,6 +6,7 @@
                <input
                    placeholder="请扫容器条码"
                    v-model="container"
                    @input="search"
                />
                <!-- <text class='cuIcon-search text-blue' @click="search"></text> -->
            </view>
@@ -18,49 +19,125 @@
            </view>
        </form>
        <view class="cu-list det menu sm-border padding">
        <view
            class="padding-lr margin-top-sm"
            style="padding-bottom: 120upx"
        >
            <block
                v-for="(item, index) in list"
                :key="index"
            >
                <view class="cu-bar bg-white solid-bottom margin-top-sm">
                    <view class="action">
                        <view class="index">
                            {{ index + 1 }}
                <view
                    class="cu-list det menu sm-border margin-bottom-sm"
                    :class="[item.trackCode === barcode && 'act']"
                    :ref="item.trackCode + 'ref'"
                >
                    <view class="cu-bar bg-white solid-bottom">
                        <view class="action">
                            <view class="index">
                                {{ index + 1 }}
                            </view>
                            <view class="text-blue">
                                物料编码:
                                {{ `${item.matnrCode}` }}
                            </view>
                        </view>
                        <view class="text-blue">
                            {{ `${item.maktx}` }}
                        <view
                            class="action"
                            v-if="!isconfirm"
                        >
                            <text
                                @click="remove(index)"
                                class="cuIcon-close text-red"
                                style="font-size: 24px"
                            ></text>
                        </view>
                    </view>
                    <!--     <view class="action" >
                        <text @click="remove(index)" class="cuIcon-close text-red" style="font-size: 24px;"></text>
                    </view> -->
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">ASN:</text>
                    <view class="cu-item">
                        <view class="content">
                            <text class="text-black">物料名称:</text>
                            <text class="text-grey">{{ item.maktx }}</text>
                        </view>
                    </view>
                    <view class="action">
                        <text class="text-grey">{{ item.asnCode }}</text>
                    <view class="cu-item">
                        <view class="content">
                            <text class="text-black">单据编码:</text>
                        </view>
                        <view class="action">
                            <text class="text-grey">
                                {{ item.platOrderCode }}
                            </text>
                        </view>
                    </view>
                </view>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">批次:</text>
                    <view class="cu-item">
                        <view class="content">
                            <text class="text-black">计划跟踪号:</text>
                        </view>
                        <view class="action">
                            <text class="text-grey">
                                {{ item.platWorkCode }}
                            </text>
                        </view>
                    </view>
                    <view class="action">
                        <text class="text-grey">{{ item.batch }}</text>
                    <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>
                <view class="cu-item">
                    <view class="content">
                        <text class="text-black">收货数量:</text>
                    <view class="cu-item">
                        <view class="content">
                            <text class="text-black">
                                单位:
                                <text class="text-grey">
                                    {{ item.unit }}
                                </text>
                            </text>
                        </view>
                        <view class="content">
                            <text class="text-black">
                                收货数量:
                                <text class="text-grey">{{ item.anfme }}</text>
                            </text>
                        </view>
                        <!-- <view class="content">
                            <text class="text-black">已上架数量: <text
                                    class="text-grey ">{{item.workQty + item.qty}}</text></text>
                        </view> -->
                    </view>
                    <view class="action">
                        <text class="text-grey">{{ item.anfme }}</text>
                    <view class="cu-item">
                        <view class="content">
                            <text class="text-black">
                                可用数量:
                                <text class="text-grey">
                                    {{ item.ableQty }}
                                </text>
                            </text>
                        </view>
                    </view>
                    <view class="cu-item">
                        <view class="content">
                            <view class="cu-form-group padding-lr-0">
                                <view class="title text-blue">
                                    <text
                                        class="text-red text-xl vertical-middle"
                                    >
                                        *
                                    </text>
                                    换绑数量:
                                </view>
                                <uni-number-box
                                    style="width: 70%"
                                    :min="0"
                                    :max="item.ableQty"
                                    :decimal="2"
                                    :step="0.01"
                                    v-model="item.inputQty"
                                ></uni-number-box>
                            </view>
                        </view>
                    </view>
                </view>
            </block>
@@ -144,7 +221,8 @@
            curCode: '',
            agvStationInput: '', // AGV站点输入值
            agvStationName: '',
            buttonPermissions: [] // 按钮权限列表
            buttonPermissions: [], // 按钮权限列表,
            isconfirm: false
        }
    },
    computed: {
@@ -156,41 +234,14 @@
        console.log('当前页面按钮权限:', this.buttonPermissions)
    },
    methods: {
        async checkAgvStation() {
            const that = this
            if (this.container === '' || this.container === null) {
                uni.showToast({
                    title: '容器码为空',
                    icon: 'none',
                    position: 'top'
                })
                return
            }
            const { code, data, msg } = await request('/check/agvStation', {
                transferStationNo: this.agvStationInput
            })
            if (code === 200) {
                this.agvStationName = data.stationName
            } else {
                uni.showToast({
                    title: msg,
                    icon: 'none',
                    position: 'top'
                })
                setTimeout(function () {
                    that.agvStationName = ''
                    that.agvStationInput = ''
                }, 200)
            }
        },
        async search() {
            const { code, data, msg } = await request('/stock/operate/list', {
                barcode: this.container,
                sta: this.barcode
            })
            const { code, data, msg } = await request(
                '/orderOut/taskItemList',
                {
                    containerNo: this.container
                }
            )
            if (code === 200) {
                // const find = this.list.find(el => el.id === data.id);
                // !find &&
                this.list = data
            } else {
                uni.showToast({
@@ -245,11 +296,23 @@
                })
                return
            }
            if (
                this.list === '' ||
                this.list === null ||
                this.list.length === 0
            ) {
                uni.showToast({
                    title: '明细不能为空',
                    icon: 'none'
                })
                return
            }
            const { code, data, msg } = await request(
                '/orderOut/containerRebinding',
                {
                    containerNo: this.container,
                    newContainerNo: this.newContainer
                    newContainerNo: this.newContainer,
                    taskItemList: this.list
                }
            )
            if (code === 200) {
pages/outbound/orderOut/orderDetlList.vue
@@ -15,6 +15,15 @@
                    <text class="header-value">{{ order.wkType$ || '-' }}</text>
                </view>
            </view>
            <view class="header-actions">
                <button
                    class="cu-btn bg-white text-blue round header-btn"
                    :disabled="waveLoading"
                    @click="generateWave"
                >
                    {{ waveLoading ? '生成中...' : '生成波次' }}
                </button>
            </view>
        </view>
        <!-- 搜索框 -->
@@ -140,7 +149,8 @@
            condition: '',
            menuList: [],
            order: '',
            loading: false
            loading: false,
            waveLoading: false
        }
    },
    computed: {
@@ -290,6 +300,44 @@
                this.loading = false
            }
        },
        // 生成波次
        async generateWave() {
            if (!this.order || !this.order.code || this.waveLoading) return
            this.waveLoading = true
            try {
                const res = await request('/orderOut/all/in', {
                    orderNo: this.order.code
                })
                if (res.code === 200) {
                    uni.showToast({
                        title: res.msg || '波次生成成功',
                        icon: 'none',
                        position: 'top'
                    })
                    this.getOrderNoList(this.order)
                } else if (res.code === 403) {
                    uni.showToast({
                        title: res.msg,
                        icon: 'none',
                        position: 'top'
                    })
                    setTimeout(() => {
                        uni.reLaunch({ url: '../login/login' })
                    }, 1000)
                } else {
                    uni.showToast({
                        title: res.msg || '波次生成失败',
                        icon: 'none',
                        position: 'top'
                    })
                }
            } catch (err) {
                // request.js 已经处理了错误提示
            } finally {
                this.waveLoading = false
            }
        },
        // 选择明细进行出库
        chose(item) {
            if (item.ableQty <= 0) {
@@ -339,6 +387,16 @@
    padding: 12rpx 16rpx;
}
.header-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 16rpx;
}
.header-btn {
    min-width: 180rpx;
}
.header-row {
    display: flex;
    justify-content: space-between;