فهرست منبع

添加仓库设置打印、客户管理编辑判断

mxx 3 سال پیش
والد
کامیت
f92940349c

+ 5 - 3
src/views/houseSelfCollect/acquisitionManagement.vue

@@ -7,7 +7,7 @@
           <el-option v-for="item in warehouseList" :key="item.id" :label="item.warehouseName" :value="item.id">
           <el-option v-for="item in warehouseList" :key="item.id" :label="item.warehouseName" :value="item.id">
           </el-option>
           </el-option>
         </el-select>
         </el-select>
-        <el-checkbox v-model="checked" @change="allowEdit" :disabled="!userJurisdiction">允许手动编辑重量</el-checkbox>
+        <el-checkbox v-model="checked" @change="allowEdit" :disabled="!userJurisdictionAllow">允许手动编辑重量</el-checkbox>
       </div>
       </div>
       <el-button type="primary" @click="newAcquisition('','','新增')">新增</el-button>
       <el-button type="primary" @click="newAcquisition('','','新增')">新增</el-button>
     </div>
     </div>
@@ -87,7 +87,8 @@
         selectVal: '',
         selectVal: '',
         goodsNameList: [],
         goodsNameList: [],
         warehouseList: [],
         warehouseList: [],
-        userJurisdiction:false
+        userJurisdiction:false,
+        userJurisdictionAllow:true
       }
       }
     },
     },
     activated() {
     activated() {
@@ -106,7 +107,8 @@
     },
     },
     methods: {
     methods: {
       getUserJurisdiction(){
       getUserJurisdiction(){
-         this.userJurisdiction = getHp('acquisitionManagement.acquisition.allow')
+         this.userJurisdiction = getHp('acquisitionManagement.acquisition.view')
+         this.userJurisdictionAllow =  getHp('acquisitionManagement.acquisition.allow')
       },
       },
       handleSizeChange(val) {
       handleSizeChange(val) {
         console.log(`每页 ${val} 条`)
         console.log(`每页 ${val} 条`)

+ 4 - 2
src/views/houseSelfCollect/acquisitionManagementAdd.vue

@@ -559,7 +559,10 @@ tableRowClassName ({ row, rowIndex }) {
         }
         }
       },
       },
       //打印
       //打印
-      print() {},
+      print() {debugger
+        localStorage.setItem('pricePrintList', JSON.stringify(this.baseInfoForm.detailPrints));
+        window.location.href = "../../../static/print.html?name=" + this.baseInfoForm.goodsName
+      },
       validate() {
       validate() {
         let that = this
         let that = this
         function _baseWaterValidate(min, max, saveNum, point, type) {
         function _baseWaterValidate(min, max, saveNum, point, type) {
@@ -892,7 +895,6 @@ tableRowClassName ({ row, rowIndex }) {
       },
       },
       // 构造查看粮价设置数据
       // 构造查看粮价设置数据
       makeLookPriceList() {
       makeLookPriceList() {
-        debugger
         this.selectVal = this.baseInfoForm.goodsName
         this.selectVal = this.baseInfoForm.goodsName
         let _priceList = this.baseInfoForm.details
         let _priceList = this.baseInfoForm.details
         let _checkList = []
         let _checkList = []

+ 9 - 1
src/views/houseSelfCollect/customerManagement.vue

@@ -45,7 +45,7 @@
       <el-table-column prop="address" label="操作" width="300">
       <el-table-column prop="address" label="操作" width="300">
         <template slot-scope="scope">
         <template slot-scope="scope">
           <el-button size="mini" @click="createCustomer(scope.row, 2)">查看</el-button>
           <el-button size="mini" @click="createCustomer(scope.row, 2)">查看</el-button>
-          <el-button size="mini" @click="createCustomer(scope.row, 3)">编辑</el-button>
+          <el-button size="mini" @click="createCustomer(scope.row, 3)" v-show="isEdit">编辑</el-button>
           <el-button size="mini" type="danger" @click="handleDelete(scope.row, '')">删除</el-button>
           <el-button size="mini" type="danger" @click="handleDelete(scope.row, '')">删除</el-button>
         </template>
         </template>
       </el-table-column>
       </el-table-column>
@@ -80,6 +80,7 @@
         pageSize: 10,
         pageSize: 10,
         deptBudgetTotal: 0,
         deptBudgetTotal: 0,
         deptCircularPage: {},
         deptCircularPage: {},
+        isEdit:true
       }
       }
     },
     },
     activated() {
     activated() {
@@ -165,6 +166,13 @@
           .toPromise()
           .toPromise()
           .then((response) => {
           .then((response) => {
             this.customertList = response.records
             this.customertList = response.records
+            for(let i=0;i<response.records.length;i++){
+              if(response.records[i].compId==sessionStorage.getItem('ws-pf_compId')){
+                this.isEdit = true
+              }else{
+                 this.isEdit = false
+              }
+            }
             this.deptBudgetTotal = response.total
             this.deptBudgetTotal = response.total
           })
           })
       },
       },