#
whycq
2024-07-22 e01dae65d8ea58d2cf8519aaac4ceba79b9c82a0
#
3个文件已修改
89 ■■■■■ 已修改文件
manifest.json 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/phyz/orderOut/orderCheck.vue 82 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/phyz/orderOut/orderOutSelect.vue 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
manifest.json
@@ -2,8 +2,8 @@
    "name" : "中扬WMS",
    "appid" : "__UNI__DA5854D",
    "description" : "",
    "versionName" : "20240701A",
    "versionCode" : 121,
    "versionName" : "20240722A",
    "versionCode" : 122,
    "transformPx" : false,
    /* 5+App特有相关 */
    "app-plus" : {
pages/phyz/orderOut/orderCheck.vue
@@ -1,31 +1,33 @@
<template>
    <view>
        <view class="list shop-car">
        <view class="list shop-car" v-for="item in dataList">
            <view class="list-left">
                <view class="detl-threeCode" style="padding: 16rpx 0;">{{data.csocode}}</view>
                <view>库位:{{data.locNo}}</view>
                <view>编号:{{data.matnr}}</view>
                <view>名称:{{data.maktx}}</view>
                <view>自由项:{{data.containerCode}}</view>
                <view>规格:{{data.specs}}</view>
                <view>批号:{{data.batch}}</view>
                <view>库存数量:{{count}}</view>
                <view class="detl-threeCode" style="padding: 16rpx 0;">{{item.csocode}}</view>
                <view>库位:{{item.locNo}}</view>
                <view>编号:{{item.matnr}}</view>
                <view>名称:{{item.maktx}}</view>
                <view>自由项:{{item.containerCode}}</view>
                <view>规格:{{item.specs}}</view>
                <view>批号:{{item.batch}}</view>
                <view>库存数量:{{item.count}}</view>
                <view class="detl-threeCode" style="display: flex;padding: 32rpx 0;align-items: center;font-size: 24px;">
                    <view>出库数量:{{data.anfme}}</view>
                    <view style="margin-left: 50rpx;" @click="revise()">
                    <view>出库数量:{{item.anfme}}</view>
                    <view style="margin-left: 50rpx;" @click="revise(item)">
                        <uni-icons type="compose" size="30" color="#fff"></uni-icons>
                    </view>
                </view>
                
                <view class="detl-threeCode" style="display: flex;padding: 0 0 32rpx 0;font-size: 24px;">出库站:
                    <view class="dropdown" @click="toggleDropdown(data)">
                        <input type="text" style="width: 270rpx;font-size: 20px;" v-model="data.agvStaNo" placeholder="请选择出库站" placeholder-style="color: #fff">
                        <uni-icons :type="data.isOpen ? 'top' : 'bottom'" color="#fff" style="margin-left: 10rpx;"></uni-icons>
                        <scroll-view scroll-y="ture" class="dropdown-content" v-if="data.isOpen">
                            <view class="dropdown-item" v-for="option in data.agvStaNos" @click="selected(option,data)">{{option}}</view>
                    <view class="dropdown" @click="toggleDropdown(item)">
                        <view style="height: 100%;width: 100%; position: fixed;background-color: rgba(0,0,0,.4);left:0;top:0" v-if = "item.isOpen"></view>
                        <input type="text" style="width: 270rpx;font-size: 20px;" v-model="item.agvStaNo" placeholder="请选择出库站" placeholder-style="color: #fff">
                        <uni-icons :type="item.isOpen ? 'top' : 'bottom'" color="#fff" style="margin-left: 10rpx;"></uni-icons>
                        <scroll-view scroll-y="ture" class="dropdown-content" v-if="item.isOpen">
                            <view class="dropdown-item" v-for="option in options" @click="selected(option,item)">{{option}}</view>
                        </scroll-view>
                    </view>
                </view>
                <button @click="combConfirm(item)" :disabled="combDis">立即出库</button>
            </view>
        </view>
        <!-- 弹窗 -->
@@ -36,7 +38,7 @@
                    <view class="title">出库数量</view>
                    <view class="popup-item">
                        <view>
                            <uni-number-box :value="data.anfme" :step='1' :min="0" :max="count" color="#747474" @change="changeValue" />
                            <uni-number-box :value="data.anfme" :step='1' :min="0" :max="maxCount" color="#747474" @change="changeValue" />
                        </view>
                        
                    </view>
@@ -53,11 +55,12 @@
                </view>
            </uni-popup>
        </view>
        <view style="height: 100rpx;"></view>
        <!-- 底部操作按钮 -->
        <view class="buttom">
        <!-- <view class="buttom">
            <button size="mini" @click="reset('warn')">稍后处理</button>
            <button size="mini" type="primary" @click="combConfirm('warn')" :disabled="combDis">立即出库</button>
        </view>
        </view> -->
    </view>
</template>
@@ -68,9 +71,11 @@
                baseUrl: '',
                token: '',
                data: {},
                dataList: [],
                option: '',
                count: 0,
                combDis: false
                options: [],
                combDis: false,
                maxCount: 0
            }
        },
        onShow() {
@@ -80,17 +85,27 @@
            // const eventChannel = this.$scope.eventChannel; // 兼容APP-NVUE
            const eventChannel = this.getOpenerEventChannel();
            // 监听acceptDataFromOpenerPage事件,获取上一页面通过eventChannel传送到当前页面的数据
            eventChannel.on('mat', function(data) {
                let ids = [data.mat.id]
                _this.getPakoutList(ids,data.mat.locNo)
            // eventChannel.on('mat', function(data) {
            //     let ids = [data.mat.id]
            //     _this.getPakoutList(ids,data.mat.locNo)
            // })
            eventChannel.on('item', function(data) {
                let ids = [data.item.id]
                _this.getPakoutList(ids)
            })
        },
        methods: {
            max() {
                 this.data.anfme = this.count
                this.data.anfme = this.data.count
            },
            toggleDropdown(item) {
                this.options = []
                item.isOpen = !item.isOpen;
                for    (let k of item.agvStaNos) {
                    console.log(k);
                    this.options.push(k)
                }
                console.log(this.options);
            },
            selected(option,item) {
                item.agvStaNo = option
@@ -105,17 +120,16 @@
                    method: 'POST',
                    success(res) {
                        res = res.data
                        console.log(res);
                        if (res.code === 200) {
                            for (let k of res.data) {
                                if (locNo == k.locNo) {
                                if (k.locNo != null) {
                                    k['isOpen'] = false
                                    _this.count = k.anfme
                                    k['count'] = k.anfme
                                    k.anfme = 0
                                    _this.data = k
                                    return
                                    _this.dataList.push(k)
                                }
                            }
                            console.log(_this.dataList);
                        } else if (res.code == 403) {
                            uni.showToast({ title: res.msg, icon: "error", position: 'top' })
                            setTimeout(() => { uni.reLaunch({ url: '../../login/login' }); }, 1000);
@@ -125,7 +139,9 @@
                    }
                })
            },
            revise() {
            revise(item) {
                this.data = item
                this.maxCount = item.count
                this.$refs.addItem.open()
            },
            addClose() {
@@ -138,7 +154,7 @@
            changeValue(value) {
                this.data.anfme = value
            },
            combConfirm() {
            combConfirm(item) {
                let _this = this
                _this.combDis = true
                if (_this.data.anfme == 0) {
@@ -147,7 +163,7 @@
                }
                uni.showLoading({})
                let combList = []
                combList.push(_this.data)
                combList.push(item)
                uni.request({
                    url: `${_this.baseUrl}/out/pakout/auth`,
                    header: {'token': uni.getStorageSync('token')},
pages/phyz/orderOut/orderOutSelect.vue
@@ -203,7 +203,8 @@
                }
                let _this = this
                uni.navigateTo({
                    url: './orderList',
                    // url: './orderList',
                    url: './orderCheck',
                    success(res) {
                        res.eventChannel.emit('item', {
                            item: item