2
schangxiang@126.com
2024-06-22 e6553a15db81babd14d2c85718555e6af996cfb9
2
已修改1个文件
42 ■■■■ 文件已修改
yiqi_pda/pages/outBound/index.vue 42 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
yiqi_pda/pages/outBound/index.vue
@@ -3,8 +3,8 @@
        
        <view class="page-frame with-action-user-row" :style="{height:pageBodyHeight+'px'}" v-if="pageBodyHeight">
            <action-user-row />
            <scan-input-form-item  :inputFocus="inputFocus" v-model="OP80NewCode" class="forma-item" :label="baseTitile"  :msg="msg" :msg-type="msgType"
                @search="onSearchContainter" @clear="onClearContainter" />
            <scan-input-form-item :inputFocus="inputFocus" v-model="OP80NewCode" class="forma-item" :label="baseTitile"
                :msg="msg" :msg-type="msgType" @search="onSearchContainter" @clear="onClearContainter" />
            <view class="with-action-user-row-page-content"  >
                
            
@@ -15,7 +15,8 @@
        <template v-slot:footer>
            <view class="bottom-btns-row">
                <view class="btn-frame right-btn-frame">
                    <u-button :disabled="workPieceData.length<1" type="primary" text="确认出库" @click="outBoundConfirm"></u-button>
                    <u-button :disabled="workPieceData.length<1" type="primary" text="确认出库"
                        @click="outBoundConfirm"></u-button>
                </view>
            </view>
        </template>
@@ -39,7 +40,9 @@
        outBoundWorkPiece,
        getOutBoundWorkPieceInfoCount
    } from '@/api/outBound/index.js'
    import {listbycode} from '@/api/common/index.js'
    import {
        listbycode
    } from '@/api/common/index.js'
    export default {
        name: 'baseInPage',
        components: {
@@ -70,27 +73,43 @@
        onLoad() {
            var _this=this;
            _this._getOutBoundWorkPieceInfoCount();
            this.myInterval=setInterval(function(){ _this._getOutBoundWorkPieceInfoCount();}, 1000*10);
            this.myInterval = setInterval(function() {
                _this._getOutBoundWorkPieceInfoCount();
            }, 1000 * 10);
            //this.myInterval=setInterval(this.myFun(), 3000);
        },
        methods: {
            // 获取工件信息
            async _getOutBoundWorkPieceInfoCount(OP80NewCode) {
                try{
                    let {data}=await getOutBoundWorkPieceInfoCount(null)
                    let {
                        data
                    } = await getOutBoundWorkPieceInfoCount(null)
                    this.ckNumToday =data;
                }catch(e){
                }
                } catch (e) {}
                this.setMsg();
            },
            // 获取工件信息
            async onSearchContainter(OP80NewCode) {
                // if (OP80NewCode.length > 22) {
                //     this.initFocus(100);
                //     uni.showToast({
                //         title: '工件码或成品码长度不正确',
                //         icon: 'error',
                //         duration: 2000,
                //         mask: true
                //     });
                //     return;
                // }
                this.inputFocus=false
                const param = {
                    OP80NewCode: OP80NewCode
                }
                try{
                    let {data}=await getWorkPieceByOP80NewCode(param)
                    let {
                        data
                    } = await getWorkPieceByOP80NewCode(param)
                    if(!this.workPieceData.some(item=>item.workPieceID==data.workPieceID)) {
                        data.addTime=new Date();
                        this.workPieceData.push(data)
@@ -152,7 +171,10 @@
                        title:'提示',
                        content:'当前工件存在非成品,确定强制出库吗?',
                        success:(value)=>{
                            const {confirm,cancel}=value
                            const {
                                confirm,
                                cancel
                            } = value
                            if(confirm) {
                                this.$refs.pwdRef.showModal(this.workPieceData)
                            }