Browse Source

任务新建选择关联应用

xiaohaizhao 2 years ago
parent
commit
5aa45d932d

+ 3 - 1
app.json

@@ -156,7 +156,9 @@
                 "publicClue/modules/follow/insert",
                 "invoiceforecast/modules/orderForm/row",
                 "invoiceforecast/modules/orderForm/select",
-                "setclient/contacts"
+                "setclient/contacts",
+                "work/synchronization",
+                "select/clue/select"
             ]
         }
     ],

+ 144 - 0
packageA/select/clue/select.js

@@ -0,0 +1,144 @@
+const _Http = getApp().globalData.http;
+
+Page({
+    data: {
+        params: {}, //请求体
+        result: [], //返回结果
+        radio: false, //是否为单选
+        idname: "sat_orderclueid", //idkey
+        showName: "enterprisename_customer", //表单用 显示名称
+    },
+    onLoad(options) {
+        if (options.params) {
+            let params = JSON.parse(options.params);
+            if (!params.content.pageNumber || !params.content.pageTotal) {
+                params.content.pageNumber = 1;
+                params.content.pageTotal = 1;
+            }
+            this.setData({
+                params
+            });
+        }
+        if (options.title) wx.setNavigationBarTitle({
+            title: options.title,
+        })
+        this.setData({
+            radio: options.radio ? true : false,
+            idname: options.idname || this.data.idname,
+            showName: options.showName || this.data.showName,
+        });
+        this.getList()
+    },
+    getList(init = false) {
+        //init 用于初始化分页
+        if (init.detail != undefined) init = init.detail;
+        let params = this.data.params;
+        if (init) params.content.pageNumber = 1;
+        if (params.content.pageNumber > params.content.pageTotal) return;
+        params.content.isAll = 0;
+        _Http.basic(params).then(res => {
+            console.log("选择线索列表", res)
+            this.selectComponent('#ListBox').RefreshToComplete();
+            if (res.msg != '成功') return wx.showToast({
+                title: res.data,
+                icon: "none"
+            })
+            this.setData({
+                'params.content.pageNumber': res.pageNumber + 1,
+                'params.content.pageTotal': res.pageTotal,
+                'params.content.total': res.total,
+                list: res.pageNumber == 1 ? res.data : this.data.list.concat(res.data)
+            })
+            this.getTags();
+        })
+    },
+    /* 获取列表标签 */
+    getTags() {
+        let list = this.data.list,
+            ownerids = list.map(v => v.sat_orderclueid);
+        _Http.basic({
+            "id": 20221018102001,
+            "content": {
+                nocache: true,
+                "ownertable": "sat_orderclue",
+                ownerids
+            }
+        }).then(res => {
+            console.log("标签", res)
+            for (let key in res.data) {
+                let index = list.findIndex(v => v.sat_orderclueid == key);
+                list[index].tags = res.data[key]
+            };
+            console.log(list)
+            this.setData({
+                list
+            })
+        })
+    },
+    /* 删除项 */
+    deteleItem(id) {
+        this.setData({
+            list: this.data.list.filter(v => v[this.data.idname] != id),
+            "params.content.total": this.data.params.content.total - 1
+        })
+    },
+    /* 选中 */
+    changeResult(e) {
+        let {
+            id
+        } = e.currentTarget.dataset, result = this.data.result;
+        if (this.data.radio) {
+            result = [id];
+        } else {
+            result.some(v => v == id) ? result = result.filter(v => v != id) : result.push(id)
+        }
+        this.setData({
+            result
+        });
+        if (this.data.radio) this.submit();
+    },
+    /* 提交 */
+    submit() {
+        let result = this.data.result,
+            obj = this.data.radio ? {
+                id: result,
+                item: this.data.list.find(value => value[this.data.idname] == result),
+                value: [this.data.list.find(value => value[this.data.idname] == result)[this.data.showName], result]
+            } : {
+                result,
+                list: result.map(v => this.data.list.find(value => value[this.data.idname] == v)),
+                value: [result.map(v => {
+                    let data = this.data.list.find(value => value[this.data.idname] == v);
+                    return data ? data[this.data.showName] : ""
+                }), result]
+            }
+        getApp().globalData.handleSelect && getApp().globalData.handleSelect(obj)
+    },
+    /* 开始搜索 */
+    startSearch({
+        detail
+    }) {
+        let condition = this.data.content ? this.data.content.where.condition : this.data.params.content.where.condition;
+        if (detail == condition) return;
+        this.setData({
+            'content.where.condition': detail,
+            'params.content.where.condition': detail
+        });
+        this.getList(true);
+    },
+    /* 取消搜索 */
+    onClear() {
+        this.setData({
+            'content.where.condition': "",
+            'params.content.where.condition': ""
+        });
+        this.getList(true);
+    },
+    onReady() {
+        this.selectComponent("#ListBox").setHeight(".total", this);
+    },
+    onUnload() {
+        //回收数据
+        getApp().globalData.handleSelect = null;
+    }
+})

+ 4 - 0
packageA/select/clue/select.json

@@ -0,0 +1,4 @@
+{
+    "usingComponents": {},
+    "navigationBarTitleText": "选择线索"
+}

+ 132 - 0
packageA/select/clue/select.scss

@@ -0,0 +1,132 @@
+page {
+    height: 100vh;
+    overflow: hidden;
+}
+
+.total {
+    height: 60rpx;
+    line-height: 60rpx;
+    font-size: 24rpx;
+    font-family: PingFang SC-Regular, PingFang SC;
+    color: #666666;
+    padding-left: 30rpx;
+}
+
+.setclient-list-item {
+    width: 100vw;
+    background-color: #fff;
+    box-sizing: border-box;
+    padding-left: 30rpx;
+
+    .con {
+        display: flex;
+        align-items: center;
+        width: 100%;
+        border-bottom: 1px solid #EFEFEF;
+        box-sizing: border-box;
+        padding: 10rpx 0;
+        padding-bottom: 14rpx;
+
+        .mian {
+            flex: 1;
+            min-height: 60rpx;
+            width: 0;
+            font-family: PingFang SC-Regular, PingFang SC;
+
+            .title {
+                width: 100%;
+                position: relative;
+                display: flex;
+                height: 42rpx;
+                align-items: center;
+                box-sizing: border-box;
+
+                >text {
+                    display: inline-block;
+                    width: 80%;
+                    font-size: 30rpx;
+                    color: #333333;
+                }
+
+                .status {
+                    position: absolute;
+                    right: 0rpx;
+                    width: 132rpx;
+                    height: 40rpx;
+                    border-radius: 20rpx 0px 0px 20rpx;
+                    box-sizing: border-box;
+                    padding-left: 30rpx;
+                    line-height: 40rpx;
+                    font-size: 24rpx;
+                    font-family: PingFang SC-Regular, PingFang SC;
+                    color: #FFFFFF;
+                }
+            }
+
+            .tag-box {
+                display: flex;
+                align-items: center;
+                width: 90%;
+                overflow: hidden;
+                margin-bottom: 4rpx;
+
+                .datatag,
+                .systemtag {
+                    flex-shrink: 0;
+                    margin-top: 6rpx;
+                    background: #FAAB16;
+                    color: #ffffff;
+                    margin-right: 10rpx;
+                    display: flex;
+                    align-items: center;
+                    height: 30rpx;
+                    font-size: 18rpx;
+                    padding: 0 10rpx;
+                    border-radius: 20rpx;
+                    font-family: PingFang SC-Regular, PingFang SC;
+                }
+
+                .systemtag {
+                    background: #FA8C16;
+                }
+            }
+
+            .exp {
+                font-size: 24rpx;
+                color: #666666;
+                margin-top: 6rpx;
+            }
+        }
+    }
+}
+
+.footer {
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
+    padding: 0 30rpx;
+    position: fixed;
+    width: 100vw;
+    height: 130rpx;
+    background: #FFFFFF;
+    box-shadow: 0px -4rpx 16rpx 2rpx rgba(150, 157, 165, 0.16);
+    bottom: 0;
+    box-sizing: border-box;
+
+    .count {
+        font-size: 28rpx;
+        font-family: PingFang SC-Regular, PingFang SC;
+        color: #333333;
+    }
+
+    .but {
+        width: 156rpx;
+        height: 90rpx;
+        background: #3874F6;
+        border-radius: 8rpx;
+        font-size: 28rpx;
+        font-family: PingFang SC-Bold, PingFang SC;
+        font-weight: bold;
+        color: #FFFFFF;
+    }
+}

+ 60 - 0
packageA/select/clue/select.wxml

@@ -0,0 +1,60 @@
+<van-search class="search" value="{{ params.content.where.condition }}" shape="round" placeholder="请输入搜索关键词" bind:search='startSearch' bind:clear='onClear' />
+<Yl_ListBox id='ListBox' bind:getlist='getList'>
+    <view class="total">共{{params.content.total}}个</view>
+    <navigator class="setclient-list-item" url="#" wx:for="{{list}}" wx:key="{{idname}}" data-id="{{item[idname]}}" bindtap="changeResult">
+        <view class="con">
+            <van-checkbox wx:if="{{!radio}}" value="{{ handle.isCheck(item[idname],result) }}" shape="square" icon-size='28rpx' />
+            <view class="mian">
+                <view class="title line-1">
+                    <text class="line-1">{{item.enterprisename_customer || " --"}}</text>
+                    <view class="status" style="background-color: {{backColor.getColor(item.status)}};">{{item.status}}</view>
+                </view>
+                <view class="tag-box">
+                    <view class="systemtag" wx:for="{{item.tags.systemtag}}" wx:key="item">{{item}}</view>
+                    <view class="datatag" wx:for="{{item.tags.datatag}}" wx:key="item">{{item}}</view>
+                </view>
+                <view class="exp line-1">省市县:{{item.province?item.province+item.city+item.county:" --"}}</view>
+                <view class="exp line-1">联系人:<text>{{item.name||' --'}}</text></view>
+                <view class="exp line-1">联系方式:<text>{{item.phonenumber || '--'}}</text></view>
+                <view class="exp line-1">领域:<text>{{item.tradefield || '--'}}</text></view>
+                <view class="exp line-1">市场活动:{{item.campaign_name?item.campaign_name:"--"}}</view>
+            </view>
+        </view>
+    </navigator>
+    <view style="height: 230rpx;" />
+    <My_empty wx:if="{{!list.length}}" />
+</Yl_ListBox>
+
+<view style="height: 130rpx;" />
+<block wx:if="{{!radio}}">
+    <view class="footer">
+        <view class="count">
+            已选:{{result.length}}
+        </view>
+        <van-button custom-class='but' disabled='{{result.length==0}}' bind:click="submit">确定</van-button>
+    </view>
+    <wxs module="handle">
+        module.exports = {
+            isCheck: function (id, list) {
+                return list.some(function (v) {
+                    return v == id
+                });
+            },
+        }
+    </wxs>
+</block>
+<wxs module="backColor">
+    module.exports.getColor = function (status) {
+        var color = null;
+        if (status == '待跟进') {
+            color = '#FA8C16';
+        } else if (status == '跟进中') {
+            color = '#52C41A';
+        } else if (status == '已转化') {
+            color = '#F60909';
+        } else {
+            color = '#BBBBBB';
+        };
+        return color
+    }
+</wxs>

+ 181 - 13
packageA/work/add.js

@@ -26,7 +26,8 @@ Page({
             placeholder: "",
             valueName: "remarks",
             checking: "base",
-            required: false
+            required: false,
+            slot: "synchronization"
         }, {
             label: "执行人",
             error: false,
@@ -88,17 +89,22 @@ Page({
             checking: "base",
             required: true
         }],
-        "content": {
-            "sys_taskid": 0
-        },
+        synchronization: null, //同步任务内容参数
         disabled: true
     },
     onLoad(options) {
+        let content = {
+            "sys_taskid": 0,
+            "ownertable": "sys_task",
+            "ownerid": options.ownerid || 0,
+        };
+        // 详情中进入
         if (options.data) {
             wx.setNavigationBarTitle({
-              title: '编辑任务',
+                title: '编辑任务',
             })
             let data = JSON.parse(options.data);
+            console.log(data)
             if (options.group) {
                 let group = JSON.parse(options.group)
                 let leader = group.findIndex(v => v.userid == data.leader[0].userid);
@@ -133,10 +139,13 @@ Page({
                 checking: "base",
                 required: false
             }]);
+            content = {
+                "sys_taskid": data.sys_taskid,
+                "ownertable": data.ownertable || "sys_task",
+                "ownerid": data.ownerid || 0,
+            }
             this.setData({
-                "content.sys_taskid": data.sys_taskid,
-                "content.ownertable": data.ownertable || "sys_task",
-                "content.ownerid": data.ownerid || 0,
+                content,
                 isReset: false,
                 disabled: false,
                 form: form.map(v => {
@@ -144,10 +153,55 @@ Page({
                     return v
                 })
             })
+        } else if (options.ownertable) {
+            content = {
+                "ownertable": options.ownertable || "sys_task",
+                "ownerid": options.ownerid || 0
+            }
+            this.setData({
+                synchronization: content
+            })
+        } else {
+            //可修改情况
+            if (["sys_task", "sat_orderclue", "sa_customers", "sa_project"].includes(content.ownertable)) {
+                let form = this.data.form,
+                    synchronization = content.ownertable != 'sys_task' ? {
+                        "ownertable": content.ownertable,
+                        "ownerid": content.ownerid,
+                    } : null;
+                form.splice(1, 0, {
+                    label: "关联应用",
+                    error: false,
+                    errMsg: "",
+                    hint: "",
+                    type: "radio",
+                    value: content.ownertable,
+                    radioList: [{
+                        id: 'sa_customers',
+                        name: '我的客户'
+                    }, {
+                        id: 'sa_project',
+                        name: '项目商机'
+                    }, {
+                        id: 'sat_orderclue',
+                        name: '销售线索'
+                    }, {
+                        id: 'sys_task',
+                        name: '不关联'
+                    }],
+                    valueName: "ownertable", //绑定的字段名称
+                    required: false, //必填
+                    interrupt: true,
+                    disabled: content.ownerid != 0
+                });
+                if (content.ownertable != 'sys_task') this.setSelectAppRoute(form, content.ownertable, content.ownerid != 0)
+                this.setData({
+                    form
+                })
+            }
         }
-        if (options.ownertable) this.setData({
-            "content.ownertable": options.ownertable || "sys_task",
-            "content.ownerid": options.ownerid || 0
+        this.setData({
+            content
         })
     },
     /* 打断处理form */
@@ -209,7 +263,6 @@ Page({
                 temporary.item.value = data.value;
                 form[temporary.index] = temporary.item;
                 wx.navigateBack()
-                this.selectComponent("#Form").confirm();
                 break;
             case '协助人':
                 index = form.findIndex(v => v.label == '执行人');
@@ -220,10 +273,125 @@ Page({
                 form[temporary.index] = temporary.item;
                 wx.navigateBack()
                 break;
+            case '关联应用':
+                this.setSelectAppRoute(form, data.value)
+                this.setData({
+                    synchronization: null
+                })
+                break;
+            case '关联数据':
+                form[temporary.index].value = data.value;
+                wx.navigateBack()
+                this.setData({
+                    synchronization: {
+                        "ownertable": form[temporary.index - 1].value,
+                        "ownerid": data.id[0]
+                    }
+                })
+                break;
         };
         this.setData({
             form
         })
+        this.selectComponent("#Form").confirm();
+    },
+    startSynchronization() {
+        console.log("开始同步", this.data.synchronization)
+        wx.navigateTo({
+            url: '/packageA/work/synchronization?data=' + JSON.stringify(this.data.synchronization),
+        });
+        _Http.selectSync = (item, ownertable) => {
+            let form = this.data.form,
+                index = form.findIndex(v => v.label == '任务内容');
+            if (index != -1) {
+                if (ownertable == 'sat_orderclue') {
+                    form[index].value = `跟进类型:${item.followupmode}\n跟进内容:${item.content}`;
+                } else {
+                    form[index].value = `跟进类型:${item.type}\n跟进对象:${item.contacts ? item.contacts.join(","):""}\n${item.content}`;
+                }
+            }
+            this.setData({
+                form
+            })
+            wx.navigateBack()
+        }
+    },
+    setSelectAppRoute(form, ownertable, disabled = false) {
+        let owneridIndex = form.findIndex(v => v.valueName == 'ownerid');
+        if (ownertable == "sys_task") {
+            if (owneridIndex != -1) form.splice(owneridIndex, 1);
+        } else {
+            let data = {
+                label: "关联数据",
+                error: false,
+                errMsg: "",
+                type: "route",
+                url: "",
+                value: "",
+                query: "&radio=true",
+                interrupt: true,
+                valueName: "ownerid",
+                checking: "base",
+                required: true,
+                disabled
+            };
+            switch (ownertable) {
+                case "sa_project":
+                    data.params = {
+                        "id": 20221020143502,
+                        "content": {
+                            "nochace": true,
+                            "pageNumber": 1,
+                            "pageSize": 20,
+                            "where": {
+                                "condition": ""
+                            },
+                            "type": 1,
+                            "deleted": 0
+                        }
+                    }
+                    data.placeholder = "选择项目商机";
+                    data.url = "/packageA/select/project/select";
+                    break;
+                case "sa_customers":
+                    data.params = {
+                        "content": {
+                            isExport: 0,
+                            "pageNumber": 1,
+                            "pageSize": 20,
+                            "where": {
+                                "condition": ""
+                            },
+                            "type": 1,
+                            "deleted": 0,
+                            "isend": 0
+                        },
+                        "id": 20221012164402,
+                    }
+                    data.placeholder = "选择我的客户";
+                    data.url = "/packageA/select/setclient/select";
+                    break;
+                case "sat_orderclue":
+                    data.params = {
+                        "content": {
+                            "pageNumber": 1,
+                            "pageSize": 20,
+                            "where": {
+                                "condition": ""
+                            },
+                            "type": 1
+                        },
+                        "id": 20221101094502,
+                    }
+                    data.placeholder = "选择销售线索";
+                    data.url = "/packageA/select/clue/select";
+                    break;
+            };
+            form.splice(2, owneridIndex == -1 ? 0 : 1, data);
+        }
+        this.setData({
+            form
+        })
     },
     submit() {
         this.setData({
@@ -235,12 +403,12 @@ Page({
         };
         content.leaderuserid = content.principal[1][0];
         delete(content.principal)
-        console.log(content.member)
         content.team = {
             "userids": content.member.length ? content.member[1] : [],
             "justuserids": 1
         }
         delete(content.member)
+        if (content.ownerid && typeof (content.ownerid) == 'object') content.ownerid = content.ownerid.length == 2 ? content.ownerid[1][0] : ""
         _Http.basic({
             "id": 20221211112101,
             content

+ 15 - 1
packageA/work/add.scss

@@ -20,7 +20,21 @@
         margin-right: 30rpx;
         margin-top: 10rpx;
     }
-    .sub{
+
+    .sub {
         width: 180rpx;
     }
+}
+
+.info {
+    height: 48rpx;
+    text-align: center;
+    line-height: 48rpx;
+    color: #E7EEFF;
+    border-radius: 8rpx;
+    font-size: 24rpx;
+    font-family: PingFang SC-Bold, PingFang SC;
+    font-weight: bold;
+    background-color: #3874F6;
+    padding: 0 10rpx;
 }

+ 1 - 0
packageA/work/add.wxml

@@ -1,6 +1,7 @@
 <Yl_Headline title='基本信息' type='switch' switchLabel='仅显示必填信息' switch='{{showAll}}' bind:callBack='onChange' />
 <Yl_field id='Form' form='{{form}}' showAll='{{!showAll}}' bind:onConfirm='onConfirm' bind:interrupt="interrupt">
     <view slot='discountrate' style="margin-right: 36rpx;">%</view>
+    <view slot='synchronization' class="info" wx:if="{{synchronization}}" bindtap="startSynchronization">同步</view>
 </Yl_field>
 <view style="height: 100rpx;" />
 <view class="new-footer">

+ 60 - 0
packageA/work/synchronization.js

@@ -0,0 +1,60 @@
+const _Http = getApp().globalData.http;
+Page({
+    data: {
+        total: 0
+    },
+    onLoad(options) {
+        let content = {
+            nocache: true,
+            pageNumber: 1,
+            pageTotal: 1,
+            ...JSON.parse(options.data)
+        }
+        this.setData({
+            content
+        });
+        this.getList()
+    },
+    getList(init = false) {
+        if (init.detail != undefined) init = init.detail;
+        let content = this.data.content;
+        if (init) content.pageNumber = 1;
+        if (content.pageNumber > content.pageTotal) return;
+
+        this.selectComponent("#ListBox").setHeight(".total", this);
+        _Http.basic({
+            "id": 20231207130504,
+            content
+        }).then(res => {
+            this.selectComponent('#ListBox').RefreshToComplete();
+            console.log("跟进列表", res)
+            this.setData({
+                total: res.total
+            })
+            if (res.msg != '成功') return wx.showToast({
+                title: res.data,
+                icon: "none"
+            })
+            if (content.ownertable != 'sat_orderclue') res.data = res.data.map(v => {
+                v.contentList = v.content.split("\n").map(v => {
+                    let obj = v.split(":")
+                    return {
+                        label: obj[0],
+                        value: obj[1] || ""
+                    }
+                })
+                return v
+            })
+
+            this.setData({
+                'content.pageNumber': res.pageNumber + 1,
+                'content.pageTotal': res.pageTotal,
+                list: res.pageNumber == 1 ? res.data : this.data.list.concat(res.data)
+            })
+
+        })
+    },
+    onClick(e) {
+        _Http.selectSync(e.currentTarget.dataset.item, this.data.content.ownertable)
+    }
+})

+ 4 - 0
packageA/work/synchronization.json

@@ -0,0 +1,4 @@
+{
+    "usingComponents": {},
+    "navigationBarTitleText": "同步跟进内容"
+}

+ 92 - 0
packageA/work/synchronization.scss

@@ -0,0 +1,92 @@
+page {
+    height: 100vh;
+    overflow: hidden;
+}
+
+.total {
+    height: 64rpx;
+    line-height: 64rpx;
+    font-size: 24rpx;
+    font-family: PingFang SC-Regular, PingFang SC;
+    color: #666666;
+    background: #F4F5F7;
+    padding-left: 30rpx;
+}
+
+.item {
+    width: 100%;
+    padding-left: 30rpx;
+    box-sizing: border-box;
+    background-color: #fff;
+    margin-bottom: 20rpx;
+
+    .user {
+        display: flex;
+        align-items: center;
+        width: 100%;
+        height: 120rpx;
+        box-sizing: border-box;
+
+        .portrait {
+            width: 80rpx;
+            height: 80rpx;
+            background: #3874F6;
+            border-radius: 50%;
+            text-align: center;
+            line-height: 80rpx;
+            font-size: 28rpx;
+            font-family: PingFang SC-Regular, PingFang SC;
+            color: #FFFFFF;
+            flex-shrink: 0;
+        }
+
+        .exp {
+            width: 100%;
+            margin-left: 20rpx;
+
+            .line-1 {
+                height: 42rpx;
+                font-size: 30rpx;
+                font-family: PingFang SC-Regular, PingFang SC;
+                color: #333333;
+            }
+
+            .phone {
+                font-size: 24rpx;
+                font-family: PingFang SC-Regular, PingFang SC;
+                color: #999999;
+                margin-top: 4rpx;
+            }
+        }
+    }
+
+    .type {
+        font-size: 26rpx;
+        display: flex;
+        justify-content: space-between;
+        width: 100%;
+        color: #333333;
+
+        &-item {
+            width: 48%;
+            color: #000;
+        }
+    }
+
+    .content {
+        font-size: 26rpx;
+        color: #333333;
+        margin-top: 8rpx;
+    }
+
+
+    .time {
+        margin-top: 20rpx;
+        padding: 20rpx;
+        font-size: 24rpx;
+        color: #999;
+        box-sizing: border-box;
+        border-top: 1px solid #ddd;
+        margin-left: -30rpx;
+    }
+}

+ 39 - 0
packageA/work/synchronization.wxml

@@ -0,0 +1,39 @@
+<view class="total">共{{total}}个</view>
+<Yl_ListBox id='ListBox' bind:getlist='getList'>
+    <navigator url="#" class="item" wx:for="{{list}}" wx:key="sys_datafollowupid" data-item="{{item}}" bindtap="onClick">
+        <view class="user">
+            <view class="portrait">
+                {{item.createby[0]}}
+            </view>
+            <view class="exp">
+                <view class="line-1">
+                    {{item.createby}}
+                    <text class="phone">{{item.enterprisename}}</text>
+                </view>
+                <view class="phone">
+                    部门:{{item.depname||' --'}} <text style="margin-right: 50rpx;"></text>
+                    职位:{{item.position||' --'}}
+                </view>
+            </view>
+        </view>
+        <block wx:if="{{content.ownertable!='sat_orderclue'}}">
+            <view class="type">
+                <view class="type-item line-1">
+                    跟进类型:<text>{{item.type||' --'}}</text>
+                </view>
+                <view class="type-item line-1">
+                    跟进对象:<text style="color: #085CDF !important;">{{item.contacts||' --'}}</text>
+                </view>
+            </view>
+            <view class="content" wx:for="{{item.contentList}}" wx:key="i" wx:for-item="it" wx:for-index="i">{{ it.label}}:{{it.value||' --'}}</view>
+        </block>
+        <block wx:else>
+            <view class="content">跟进类型:{{item.followupmode||' --'}}</view>
+            <view class="content">跟进内容:{{item.content||' --'}}</view>
+        </block>
+        <view class="time">
+            {{item.createdate}}
+        </view>
+    </navigator>
+    <My_empty wx:if="{{!list.length}}" />
+</Yl_ListBox>

+ 14 - 0
project.private.config.json

@@ -20,6 +20,20 @@
                     "query": "id=4156",
                     "launchMode": "default",
                     "scene": null
+                },
+                {
+                    "name": "新建任务",
+                    "pathName": "packageA/work/add",
+                    "query": "",
+                    "launchMode": "default",
+                    "scene": null
+                },
+                {
+                    "name": "tbu",
+                    "pathName": "packageA/work/synchronization",
+                    "query": "data=%7B%22ownertable%22%3A%22sa_customers%22%2C%22ownerid%22%3A3389%7D",
+                    "launchMode": "default",
+                    "scene": null
                 }
             ]
         }