瀏覽代碼

Merge branch 'dev' of http://124.70.211.186:3000/sjw/YOS_wechat into dev

codeMan 3 年之前
父節點
當前提交
59a0a7c6c4

+ 13 - 7
components/Yl_filtrate/index.js

@@ -3,16 +3,22 @@ Component({
     properties: {
         show: Boolean,
         handle: Function, //按钮回调函数
-        zIndex:{
-            type:String,
-            value:99999,
+        zIndex: {
+            type: String,
+            value: 99999,
         },
     },
     lifetimes: {
         ready() {
-            getHeight.getHeight('.head', this).then(res => this.setData({
-                listHeight: res - 130
-            }));
+            let windowHeight = 0,
+                that = this;
+            wx.getSystemInfo({
+                success: (res => windowHeight = res.windowHeight)
+            });
+            let query = wx.createSelectorQuery().in(that).select(".head").boundingClientRect();
+            query.exec(res => that.setData({
+                listHeight: (windowHeight - res[0].bottom - 80) * 2
+            }))
         }
     },
     methods: {
@@ -22,7 +28,7 @@ Component({
             } = e.target.dataset;
             if (name) this.triggerEvent("handle", name)
         },
-        onClose(){
+        onClose() {
             this.triggerEvent("handle", "close")
         }
     }

+ 9 - 3
components/Yl_nav/index.js

@@ -31,9 +31,15 @@ Component({
             })
         },
         ready() {
-            getHeight.getHeight('.Yl_head', this).then(res => this.setData({
-                listHeight: res - 130
-            }));
+            let windowHeight = 0,
+                that = this;
+            wx.getSystemInfo({
+                success: (res => windowHeight = res.windowHeight)
+            });
+            let query = wx.createSelectorQuery().in(that).select('.Yl_head').boundingClientRect();
+            query.exec(res => that.setData({
+                listHeight: (windowHeight - res[0].bottom - 80) * 2
+            }))
         }
     },
     methods: {

+ 5 - 5
packageA/activity/index.js

@@ -7,7 +7,7 @@ Page({
      */
     data: {
         navList: [{
-            label: "全部",
+            label: "我负责的",
             icon: "icon-webxialaxuanxiangjiantou",
             color: "",
             width: "",
@@ -27,15 +27,15 @@ Page({
         }],
         classShow: false,
         classActions: [{
-                name: '全部',
-                index: 0
-            }, {
                 name: '我负责的',
                 index: 1
             },
             {
                 name: '我参与的',
                 index: 2
+            }, {
+                name: '我创建的',
+                index: 5
             },
             {
                 name: "我下属负责的",
@@ -51,6 +51,7 @@ Page({
             "version": 1,
             "pageNumber": 1,
             "pageSize": 20,
+            type: 1,
             "where": {
                 "condition": "",
                 "startdate": "",
@@ -75,7 +76,6 @@ Page({
         })
         this.getList();
         this.getTypeList()
-        this.getareaList()
     },
     /* 获取列表 */
     getList(init = false, data) {

+ 5 - 5
packageA/contract/index.js

@@ -23,7 +23,7 @@ Page({
             route: 'type5'
         }],
         navList: [{
-            label: "全部",
+            label: "我负责的",
             icon: "icon-webxialaxuanxiangjiantou",
             color: "",
             width: "",
@@ -43,15 +43,15 @@ Page({
         }],
         classShow: false,
         classActions: [{
-                name: '全部',
-                index: 0
-            }, {
                 name: '我负责的',
                 index: 1
             },
             {
                 name: '我参与的',
                 index: 2
+            }, {
+                name: '我创建的',
+                index: 5
             },
             {
                 name: "我下属负责的",
@@ -63,7 +63,7 @@ Page({
         ],
         content: {
             "nocache": true,
-            "type": 0,
+            "type": 1,
             "version": 1,
             "pageNumber": 1,
             "pageSize": 20,

+ 3 - 3
packageA/offers/addProjectOffer.js

@@ -185,9 +185,9 @@ Page({
             ...this.data.content,
             ...this.selectComponent("#Form").submit()
         };
-        content.sys_enterpriseid = content.sys_enterpriseid[1][0] || '';
-        content.sa_projectid = content.sa_projectid[1][0] || '';
-        content.contactsid = content.contactsid ? content.contactsid[1][0] : '';
+        content.sys_enterpriseid = content.sys_enterpriseid[1][0] || 0;
+        content.sa_projectid = content.sa_projectid[1][0] || 0;
+        content.contactsid = content.contactsid ? content.contactsid[1][0] : 0;
         content.begdate = content.invaliddate[0];
         content.enddate = content.invaliddate[1];
         delete(content.invaliddate)

+ 2 - 2
packageA/offers/addSetclientOffer.js

@@ -150,8 +150,8 @@ Page({
             ...this.data.content,
             ...this.selectComponent("#Form").submit()
         };
-        content.sys_enterpriseid = content.sys_enterpriseid[1][0] || '';
-        content.contactsid = content.contactsid ? content.contactsid[1][0] : '';
+        content.sys_enterpriseid = content.sys_enterpriseid[1][0] || 0;
+        content.contactsid = content.contactsid ? content.contactsid[1][0] : 0;
         content.begdate = content.invaliddate[0];
         content.enddate = content.invaliddate[1];
         delete(content.invaliddate)

+ 5 - 5
packageA/offers/index.js

@@ -15,7 +15,7 @@ Page({
         }],
         typeShow: false,
         navList: [{
-            label: "全部",
+            label: "我负责的",
             icon: "icon-webxialaxuanxiangjiantou",
             color: "",
             width: "",
@@ -35,15 +35,15 @@ Page({
         }],
         classShow: false,
         classActions: [{
-                name: '全部',
-                index: 0
-            }, {
                 name: '我负责的',
                 index: 1
             },
             {
                 name: '我参与的',
                 index: 2
+            }, {
+                name: '我创建的',
+                index: 5
             },
             {
                 name: "我下属负责的",
@@ -55,7 +55,7 @@ Page({
         ],
         content: {
             "nocache": true,
-            "type": 0,
+            "type": 1,
             "version": 1,
             "pageNumber": 1,
             "pageSize": 20,

+ 6 - 6
packageA/project/index.js

@@ -5,7 +5,7 @@ Page({
     data: {
         listHeight: null,
         navList: [{
-            label: "全部",
+            label: "我负责的",
             icon: "icon-webxialaxuanxiangjiantou",
             color: "",
             width: "",
@@ -25,15 +25,15 @@ Page({
         }],
         classShow: false,
         classActions: [{
-                name: '全部',
-                index: 0
-            }, {
                 name: '我负责的',
                 index: 1
             },
             {
                 name: '我参与的',
                 index: 2
+            }, {
+                name: '我创建的',
+                index: 5
             },
             {
                 name: "我下属负责的",
@@ -45,7 +45,7 @@ Page({
         ],
         content: {
             nocache: true,
-            "type": 0,
+            "type": 1,
             "pageNumber": 1,
             "pageSize": 20,
             "where": {
@@ -122,7 +122,7 @@ Page({
                 v.progress = v.stage / v.totalstage * 100;
                 return v
             })
-            
+
             this.setData({
                 'content.pageNumber': res.pageNumber + 1,
                 'content.pageTotal': res.pageTotal,

+ 9 - 3
packageA/project/modules/task/list/index.js

@@ -52,9 +52,15 @@ Component({
         handleAdd(ids) {
             let content = this.data.content;
             content.sa_project_partiesids = ids
-            wx.redirectTo({
-                url: '/packageA/project/modules/task/add?content=' + JSON.stringify(content) + '&taskname=' + this.data.taskname,
-            })
+            if (ids.length) {
+                wx.redirectTo({
+                    url: '/packageA/project/modules/task/add?content=' + JSON.stringify(content) + '&taskname=' + this.data.taskname,
+                })
+            } else {
+                wx.navigateTo({
+                    url: '/packageA/project/modules/task/add?content=' + JSON.stringify(content) + '&taskname=' + this.data.taskname,
+                })
+            }
         },
         viewHistory(e) {
             const {

+ 22 - 3
packageA/saleClue/index.js

@@ -7,7 +7,7 @@ Page({
      */
     data: {
         navList: [{
-            label: "全部",
+            label: "我负责的",
             icon: "icon-webxialaxuanxiangjiantou",
             color: "",
             width: "",
@@ -26,13 +26,32 @@ Page({
             id: "2"
         }],
         classShow: false,
-        classActions: [],
+        classActions: [{
+                name: '我负责的',
+                index: 1
+            },
+            {
+                name: '我参与的',
+                index: 2
+            }, {
+                name: '我创建的',
+                index: 5
+            },
+            {
+                name: "我下属负责的",
+                index: 3
+            }, {
+                name: "我下属参与的",
+                index: 4
+            }
+        ],
         content: {
             "isAll": 0,
             "nocache": true,
             "version": 1,
             "pageNumber": 1,
             "pageSize": 20,
+            type: 1,
             "where": {
                 "condition": "",
             },
@@ -51,7 +70,7 @@ Page({
             insert: wx.getStorageSync('auth').worderclue.options.some(v => v == 'insert'), //查询新增权限
         })
         this.getList()
-        this.getTypeList()
+        // this.getTypeList()
         this.getClueArea()
     },
     /* 获取列表 */

+ 4 - 4
packageA/setclient/index.js

@@ -3,7 +3,7 @@ const _Http = getApp().globalData.http,
 Page({
     data: {
         navList: [{
-            label: "全部",
+            label: "我负责的",
             icon: "icon-webxialaxuanxiangjiantou",
             color: "",
             width: "",
@@ -43,15 +43,15 @@ Page({
         list: [],
         classShow: false, //type类型
         classActions: [{
-                name: '全部',
-                index: 0
-            }, {
                 name: '我负责的',
                 index: 1
             },
             {
                 name: '我参与的',
                 index: 2
+            }, {
+                name: '我创建的',
+                index: 5
             },
             {
                 name: "我下属负责的",

+ 19 - 18
packageA/work/index.js

@@ -11,7 +11,7 @@ Page({
     data: {
         list: [],
         navList: [{
-            label: "全部",
+            label: "我负责的",
             icon: "icon-webxialaxuanxiangjiantou",
             color: "",
             width: "",
@@ -23,24 +23,7 @@ Page({
             width: "",
             id: "sort"
         }],
-        content: {
-            nocache: true,
-            "pageNumber": 1,
-            "pageSize": 20,
-            "isExport": 0,
-            "type": 0,
-            "where": {
-                "condition": "",
-                "startdate": "",
-                "enddate": ""
-            },
-            "sort": []
-        },
-        classShow: false, //type类型
         classActions: [{
-                name: '全部',
-                index: 0
-            }, {
                 name: '我负责的',
                 index: 1
             },
@@ -48,6 +31,10 @@ Page({
                 name: '我参与的',
                 index: 2
             },
+            {
+                name: '我创建的',
+                index: 5
+            },
             {
                 name: "我下属负责的",
                 index: 3
@@ -56,6 +43,20 @@ Page({
                 index: 4
             }
         ],
+        content: {
+            nocache: true,
+            "pageNumber": 1,
+            "pageSize": 20,
+            "isExport": 0,
+            "type": 1,
+            "where": {
+                "condition": "",
+                "startdate": "",
+                "enddate": ""
+            },
+            "sort": []
+        },
+        classShow: false, //type类型
         filter: {
             statusActive: "",
             startdate: "",