chenhaozhe
2025-12-23 4c6c099abe1028225451d6eea83ea01590279a83
模具领料出库单 添加 往来单位 缓存
3个文件已修改
49 ■■■■ 已修改文件
manifest.json 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pages/MJGL/mujulingliaochukudan/MouldProdOutBill.vue 33 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
utils/common.js 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
manifest.json
@@ -2,8 +2,8 @@
    "name" : "智云LMES",
    "appid" : "__UNI__B002F49",
    "description" : "",
    "versionName" : "2.0.34",
    "versionCode" : 234,
    "versionName" : "2.0.39",
    "versionCode" : 239,
    "transformPx" : false,
    /* 5+App特有相关 */
    "app-plus" : {
pages/MJGL/mujulingliaochukudan/MouldProdOutBill.vue
@@ -62,7 +62,7 @@
                <view class="title">往来单位:</view>
                <view class="right" v-show="showHSourceBillNo">
                    <uni-combox :candidates="arrayHSelectType" placeholder="请选择" v-model="hform.HSupName"
                        @input="" ></uni-combox>
                        @input="HSupNameChange" ></uni-combox>
                </view>
                <view class="right" v-show="!showHSourceBillNo">
                    <input name="HSupName" disabled v-model="hform.HSupName" placeholder="" />
@@ -257,7 +257,33 @@
            BillListPopupVue
        },
        methods: {
            HSupNameChange(e) {
                let index = this.arrayHSelectType.findIndex(el => el == e)
                let HSupInfo = this.HSelectTypeList[index]
                console.log('HSupInfo: ',HSupInfo);
                this.hform.HSupID =  HSupInfo.HItemID
                this.hform.HSupName = HSupInfo['部门名称'] || HSupInfo['客户名称'] || HSupInfo['供应商名称']
                const pages = getCurrentPages()
                // 获取页面栈中的最后一个元素,也就是当前显示的页面
                const currentPage = pages[pages.length - 1]
                // 选择源单类型后 缓存当前页面选择
                uni.setStorageSync(`${currentPage.route.split("/").pop()}_${this.hform.HBillType}`, {
                    HSupName: HSupInfo['部门名称'] || HSupInfo['客户名称'] || HSupInfo['供应商名称'],
                    HSupID: HSupInfo.HItemID
                })
            },
            loadCache(){
                const pages = getCurrentPages()
                // 获取页面栈中的最后一个元素,也就是当前显示的页面
                const currentPage = pages[pages.length - 1]
                // 选择源单类型后 缓存当前页面选择
                let cache = uni.getStorageSync(`${currentPage.route.split("/").pop()}_${this.hform.HBillType}`)
                this.hform.HSupID = cache.HSupID
                this.hform.HSupName = cache.HSupName
            },
            //扫码
            toScanCode() {
                var mpaasScanModule = uni.requireNativePlugin("Mpaas-Scan-Module")
@@ -1077,6 +1103,9 @@
                  } else if(this.hform.TypeName === '客户') {
                    
                  }
                  this.$nextTick(() => {
                      this.loadCache()
                  })
                  
                }, 300);
                uni.$on('BillSelectComplete', (e) => {
utils/common.js
@@ -477,12 +477,12 @@
        
        let FieldListCache = Array(FieldList)
        
        RoleList.forEach(role => {
            console.log(FieldListCache.filter(field => !role.test(field.ColmCols)))
            FieldListCache = FieldListCache.filter(field => !role.test(field.ColmCols))
        })
        let list1 = FieldListCache.filter(elem => role[0].test(elem.ColmCols))
        console.log('list1: ',list1);
        // RoleList.forEach(role => {
        //     console.log(FieldListCache.filter(field => !role.test(field.ColmCols)))
        //     FieldListCache = FieldListCache.filter(field => !role.test(field.ColmCols))
        // })
        
        return {
            status: true,