Sfoglia il codice sorgente

Merge branch 'master' of http://git.dongkesoft.com:9001/iBOSS-2.0-Mini/iboss_wx_app

王英杰 1 anno fa
parent
commit
c443f486e6

+ 3 - 3
i18n/zh-CN.js

@@ -238,7 +238,7 @@ const basicData = {
   catCode: '种类编码',
   catName: '种类名称',
   catName: '种类名称',
-  goodsBatch: '商品批次',
+  goodsBatch: '非标号',
   //基础资料
 
   warehouse: '仓库档案',
@@ -479,13 +479,13 @@ const goodsSku = {
   skuCode: '商品编码',
   skuModel: '商品型号',
   skuName: '商品名称',
-  colorNumber: '号',
+  colorNumber: '非标号',
   subUnitId: '辅助单位',
   sukSpec: '商品规格',
   goodSpec: '规格',
   openingInventoryQty: '期初数量',
   openingInventory: '期初库存',
-  iinventoryBatchNumber: '库存批号',
+  iinventoryBatchNumber: '非标号',
   iinitialCostPrice: '期初成本价',
   purchasePrice: '采购价',
   retailPrice: '零售价',

+ 5 - 4
package-basic-data/pages/org/choose-org/choose-org.js

@@ -31,11 +31,13 @@ Page({
    * @author : 王英杰
    */
   setSearchParams(params) {
-    console.log('tttt',this.data.item);
     params.pageSize = null
     params.currentPage = null
-    params.orgId = this.data.item.editFlag ? (this.data.item.orgId_social || null) : null
-    params.parentId = this.data.item.editFlag ? (this.data.item.parentId_social || null) : null
+    let item = this.data.item;
+    if(item){
+      params.orgId = item.editFlag ? (item.orgId_social || null) : null
+      params.parentId = item.editFlag ? (item.parentId_social || null) : null
+    }
     return params
   },
 
@@ -66,7 +68,6 @@ Page({
       })
     }
     let tableTopData = data.filter(it => it.levelNo == 1);
-    console.log('etableData', tableData);
     this.setData({
       tableData: tableData,
       tableTopData: tableTopData

+ 20 - 1
package-basic-data/pages/org/org.js

@@ -87,7 +87,7 @@ Page({
      * @author : 周兴
      */
   deactivateEnable(e) {
-    if(e.detail == 'right'){
+    if (e.detail == 'right') {
       let item = e.currentTarget.dataset.item
       //执行接口
       this.handleMoreDataIsValid(this.data.service, item, 'orgId')
@@ -150,7 +150,11 @@ Page({
       form.parentId = topOrg.orgId
       form.parentName = topOrg.orgName
     }
+    let popContent = this.data.popContent
+    // 新建时过滤掉部门
+    popContent = popContent.filter(it => it.code != 'orgCode')
     this.setData({
+      popContent: popContent,
       showPop: true,
       editFlag: false,
       popTitle: this.$t('newDepartment'),
@@ -462,7 +466,22 @@ Page({
         }
         let form_ = { ...form }
         form_.editFlag = false
+        let popContent = this.data.popContent
+        let filters = popContent.filter(it => it.code == 'orgCode');
+        // 说明部门编码被过滤掉了,需要加回来
+        if (!filters || filters.length == 0) {
+          popContent.unshift(
+            {
+              code: 'orgCode',
+              type: 'str',
+              name: 'orgCode',
+              required: false,
+              readonly: true
+            })
+        }
+
         this.setData({
+          popContent:popContent,
           form: JSON.stringify(form_),
           popTitle: this.$t('org'),
           showPop: true,

+ 1 - 1
package-basic-data/pages/product-attribute/product-attribute.js

@@ -45,7 +45,7 @@ Page({
     formDataName: mixins.$t('goodsBrandSys'),
     popContent:
       [
-        { code: 'brandCode', type: 'str', title: mixins.$t('brandCode'), required: false, readonly: true, },
+        // { code: 'brandCode', type: 'str', title: mixins.$t('brandCode'), required: false, readonly: true, },
         { code: 'brandName', type: 'str', title: mixins.$t('brandName'), required: true },
         { code: 'shortName', type: 'str', title: mixins.$t('abbreviation'), required: false },
         {

+ 1 - 0
package-sales/pages/choose-sale-org/choose-sale-org.js

@@ -75,6 +75,7 @@ Page({
 setSearchParams(params) {
   params.ids = this.data.id  ?  this.data.id  : []
   params.flgValid = true
+  params.flgBusiness = true
   return params
 },
   /**

+ 13 - 0
package-sales/pages/order-billing/add/add.js

@@ -270,6 +270,8 @@ Page({
     params.deleteItemList = params.deleteList ? params.deleteList : []
     params.salesChannel = params.channelId
     delete params['goodsList']
+
+   
     // return
     return params
   },
@@ -323,6 +325,15 @@ Page({
    * @author : 于继渤
    */
   saveData() {
+     //判断当前主业务部门标识
+     if(!app.globalData.user.flgBusiness){
+      Dialog.confirm({
+        message: '当前部门不是业务部门,请选择业务部门',
+      }).then(() => {
+      }).catch(() => {})
+  
+      return
+    }
     if (this.data.formMode == Constants.formMode.edit) { //编辑
       return this.excute(this.data.service, this.data.service.update, this.data.params);
     } else { //新建
@@ -461,6 +472,8 @@ Page({
       text: app.globalData.user.staffName,
       value: [app.globalData.user.staffId]
     }
+
+
     formData['org'] = {
       text: app.globalData.user.orgName,
       value: [app.globalData.user.orgId]

+ 1 - 0
pages/company/company.js

@@ -151,6 +151,7 @@ Page({
                         app.globalData.user.orgName = staff.orgName
                         app.globalData.user.defaultWhName = staff.defaultWhName
                         app.globalData.user.defaultWhId = staff.defaultWhId
+                        app.globalData.user.flgBusiness = staff.flgBusiness
 
                         // 调转主页--注意有场景值的情况 
                         if (this.data.scene) {