Browse Source

Merge branch '测试' into 国际化适配

# Conflicts:
#	packageA/activity/index.js
xiaohaizhao 1 year ago
parent
commit
96a5a9f5d5

+ 18 - 2
packageA/options/index.js

@@ -5,6 +5,9 @@ Page({
             "pageNumber": 1,
             "pageSize": 20,
             "pageTotal": 1,
+            "where": {
+                "condition": ""
+            }
         },
         result: [],
         list: []
@@ -45,7 +48,8 @@ Page({
         let {
             pageNumber,
             pageTotal,
-            pageSize
+            pageSize,
+            where
         } = this.data.paging;
         if (init) {
             pageNumber = 1;
@@ -61,7 +65,8 @@ Page({
                 "typename": this.data.item.optionNmae,
                 "parameter": {
                     "siteid": wx.getStorageSync('siteP').siteid
-                }
+                },
+                where
             }
         }).then(res => {
             console.log("可选项查询", res)
@@ -96,4 +101,15 @@ Page({
     onReachBottom() {
         this.getList();
     },
+    onSearch({
+        detail
+    }) {
+        this.data.paging.where.condition = detail;
+        this.getList(true);
+    },
+    onClear() {
+        this.onSearch({
+            detail: ""
+        })
+    }
 })

+ 3 - 0
packageA/options/index.wxml

@@ -1,3 +1,6 @@
+<view style="position: sticky; top: 0px; z-index: 999; background-color: #F4F5F7; padding-bottom: 20rpx;">
+    <van-search custom-class='search' value="{{ paging.where.condition }}" shape="round" background="#fff" placeholder="请输入搜索关键字" bind:search='onSearch' bind:clear='onClear' />
+</view>
 <van-checkbox-group value="{{ result }}" bind:change="onChange">
     <van-cell-group>
         <van-cell wx:for="{{ list }}" wx:key="value" title="{{ item.value }}" label="{{item.remarks}}" value-class="value-class" clickable data-item="{{ item }}" bind:click="toggle">

+ 16 - 0
packageA/project/index.js

@@ -61,6 +61,21 @@ Page({
         });
         this.getList();
         let filtratelist = [{
+            label: "部门",
+            index: null,
+            showName: "depname", //显示字段
+            valueKey: "departmentid", //返回Key
+            selectKey: "departmentid", //传参 代表选着字段 不传参返回整个选择对象
+            value: "", //选中值
+            type: 'multilevelClass',
+            list: await _Http.basic({
+                "id": 20230620102004,
+                "content": {},
+            }).then(res => {
+                console.log("获取部门", res)
+                return res.data.dep
+            })
+        }, {
             label: "项目类型",
             index: null,
             showName: "value", //显示字段
@@ -145,6 +160,7 @@ Page({
         })
 
     },
+    onReady() {},
     /* 处理搜索 */
     onSearch({
         detail

+ 1 - 1
packageA/publicClue/distribution.js

@@ -107,7 +107,7 @@ Page({
                 title: res.data,
                 icon: "none"
             });
-            res.data = res.data.filter(v => v.userid != wx.getStorageSync('userMsg').userid)
+            // res.data = res.data.filter(v => v.userid != wx.getStorageSync('userMsg').userid)
             this.setData({
                 list: res.pageNumber == 1 ? res.data : this.data.list.concat(res.data),
                 "params.content.pageNumber": res.pageNumber + 1,

+ 1 - 1
pages/trace/index.js

@@ -138,7 +138,7 @@ Component({
         index
       } = e.currentTarget.dataset;
       wx.navigateTo({
-        url: `/packageA/expenseBreakdown/index?ownertable=${this.data.ownertable}&ownerid=${item.sys_datafollowupid}&isAdmin=${this.data.isAdmin}&item=${
+        url: `/packageA/expenseBreakdown/index?ownertable=${item.ownertable}&ownerid=${item.sys_datafollowupid}&isAdmin=${this.data.isAdmin}&item=${
           JSON.stringify(item)
         }`,
       })