Pārlūkot izejas kodu

更新列表标签

xiaohaizhao 2 gadi atpakaļ
vecāks
revīzija
657b9e4510

+ 23 - 4
packageA/setclient/detail.js

@@ -104,7 +104,7 @@ Page({
                         "status": e.detail.name
                     }
                 }).then(res => {
-                    console.log("更改合作模式", res)
+                    console.log("更改合作状态", res)
                     wx.showToast({
                         title: res.msg == '成功' ? '修改成功' : res.msg,
                         icon: "none"
@@ -127,7 +127,7 @@ Page({
         let data = this.data.detail,
             that = this;
         switch (detail.label) {
-            case "更改合作模式":
+            case "更改合作状态":
                 this.setData({
                     changeMode: true
                 })
@@ -368,7 +368,7 @@ Page({
             })
             if (isLeader) tabbarList.push({
                 icon: "icon-dibu-biangengchengjiaozhuangtai",
-                label: "更改合作模式"
+                label: "更改合作状态"
             })
             tabbarList.push({
                 icon: "icon-shanchu",
@@ -546,5 +546,24 @@ Page({
     onReachBottom() {
         this.partialRenewal();
     },
-    onShareAppMessage() {}
+    onUnload() {
+        const page = getCurrentPages().find(v => v.__route__ == 'packageA/setclient/index');
+        if (!page) return;
+        let content = JSON.parse(JSON.stringify(page.data.content));
+        content.pageSize = (content.pageNumber - 1) * content.pageSize;
+        content.pageNumber = 1;
+        _Http.basic({
+            id: '20221012164402',
+            content
+        }).then(res => {
+            console.log("更新客户列表", res);
+            if (res.msg == '成功') {
+                page.setData({
+                    list: res.data,
+                    "content.total": res.total
+                })
+                page.getTags()
+            }
+        })
+    }
 })

+ 3 - 2
packageA/setclient/modules/list/index.wxml

@@ -6,8 +6,9 @@
         <view class="mian">
             <view class="label line-1">{{item.enterprisename}}</view>
             <view class="tag-box">
-                <van-tag custom-class='tag' wx:if="{{item.type}}" wx:for-item='tag' color='#FA8C16' text-color='#fff' round>{{item.type}}</van-tag>
-                <van-tag custom-class='tag' wx:for="{{item.tags.systemtag}}" wx:key="index" wx:for-item='tag' color='#3874f6' text-color='#fff' round>{{tag}}</van-tag>
+                <!-- <van-tag custom-class='tag' wx:if="{{item.type}}" wx:for-item='tag' color='#FA8C16' text-color='#fff' round>{{item.type}}</van-tag> -->
+                <van-tag custom-class='tag' wx:for="{{item.tag_sys}}" wx:key="index" wx:for-item='tag' color='#3874f6' text-color='#fff' round>{{tag}}</van-tag>
+                <!-- <van-tag custom-class='tag' wx:for="{{item.tags.systemtag}}" wx:key="index" wx:for-item='tag' color='#3874f6' text-color='#fff' round>{{tag}}</van-tag> -->
                 <van-tag custom-class='tag' wx:for="{{item.tags.datatag}}" wx:key="index" wx:for-item='tag' color='#FAAB16' text-color='#fff' round>{{tag}}</van-tag>
             </view>
         </view>