Commit e890b396 by zhangxw

分包修改

1 parent 7a112769
Showing 55 changed files with 185 additions and 77 deletions
...@@ -68,20 +68,6 @@ ...@@ -68,20 +68,6 @@
] ]
}, },
{ {
"root": "packagesList/mineDetail",
"name": "mineDetail",
"pages": [
"pages/messageBox",
"pages/customerManagement",
"pages/clue",
"pages/staffManage/staffList/staffList",
"pages/serviceManage/serviceList/serviceList",
"pages/staffManage/createStaff/createStaff",
"pages/staffManage/selectConnectionPage/selectConnectionPage",
"pages/successPage/successPage"
]
},
{
"root": "packagesList/apply", "root": "packagesList/apply",
"name": "apply", "name": "apply",
"pages": [ "pages": [
...@@ -94,13 +80,27 @@ ...@@ -94,13 +80,27 @@
"pages": [ "pages": [
"pages/apply" "pages/apply"
] ]
},
{
"root": "packageMine/pages",
"name": "packageMine",
"pages": [
"messageBox/messageBox",
"customerManagement/customerManagement",
"clue/clue",
"staffManage/staffList/staffList",
"serviceManage/serviceList/serviceList",
"staffManage/createStaff/createStaff",
"staffManage/selectConnectionPage/selectConnectionPage",
"successPage/successPage"
]
} }
], ],
"preloadRule": { "preloadRule": {
"pages/tab/mine/mine": { "pages/tab/mine/mine": {
"network": "all", "network": "all",
"packages": [ "packages": [
"mineDetail" "packageMine"
] ]
}, },
"pages/tab/index/index": { "pages/tab/index/index": {
......
...@@ -6,7 +6,20 @@ Component({ ...@@ -6,7 +6,20 @@ Component({
properties: { properties: {
show: Boolean, show: Boolean,
connectionList: Array, connectionList: Array,
tabBarStyle: String tabBarStyle: String,
selectedConnectionList: {
type: Array,
observer: function(n) {
let { connectionList } = this.data
if (n?.length) {
connectionList.map(val => {
if (n.findIndex(item => item.connectionCode == val.connectionCode) > -1) val.checked = true
return val
})
}
this.setData({connectionList})
}
}
}, },
/** /**
...@@ -26,7 +39,7 @@ Component({ ...@@ -26,7 +39,7 @@ Component({
// 不可操作选项 // 不可操作选项
if (item.disabled) return if (item.disabled) return
connectionList.forEach(v => { connectionList.forEach(v => {
if (v.serviceCode == item.serviceCode) v.checked = !v.checked if (v.connectionCode == item.connectionCode) v.checked = !v.checked
}) })
this.setData({ this.setData({
connectionList connectionList
......
...@@ -32,6 +32,9 @@ ...@@ -32,6 +32,9 @@
color: #666; color: #666;
box-sizing: border-box; box-sizing: border-box;
padding: 0 24rpx; padding: 0 24rpx;
display: flex;
align-items: center;
justify-content: center;
.text-center { .text-center {
font-size: 24rpx; font-size: 24rpx;
border-radius: 12rpx; border-radius: 12rpx;
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
<image src="/images/clear.png" class="search-clear" bindtap="clear" /> <image src="/images/clear.png" class="search-clear" bindtap="clear" />
</block> </block>
</view> </view>
<view class="search text-center" bindtap="showConfirm"> <view class="search" bindtap="showConfirm">
<view class="text-center">搜索</view> <view class="text-center">搜索</view>
</view> </view>
</view> </view>
......
...@@ -23,20 +23,20 @@ Component({ ...@@ -23,20 +23,20 @@ Component({
*/ */
methods: { methods: {
select(e) { select(e) {
let { index } = e.currentTarget.dataset let { item } = e.currentTarget.dataset
let { serviceList } = this.data let { serviceList } = this.data
serviceList.forEach((item, ind) => { serviceList.forEach((val, ind) => {
if (index == ind) { if (item.serviceCode == val.serviceCode) {
item.act = true val.act = true
} else { } else {
item.act = false val.act = false
} }
}) })
this.setData({ this.setData({
serviceList, serviceList,
selectInfo: serviceList[index] || {} selectInfo: item || {}
}) })
this.triggerEvent('hiddenSelectConfirm', serviceList[index]) this.triggerEvent('hiddenSelectConfirm', item)
}, },
input(e) { input(e) {
let { serviceList } = this.data let { serviceList } = this.data
......
...@@ -32,6 +32,9 @@ ...@@ -32,6 +32,9 @@
color: #666; color: #666;
box-sizing: border-box; box-sizing: border-box;
padding: 0 24rpx; padding: 0 24rpx;
display: flex;
align-items: center;
justify-content: center;
.text-center { .text-center {
font-size: 24rpx; font-size: 24rpx;
border-radius: 12rpx; border-radius: 12rpx;
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
<image src="/images/clear.png" class="search-clear" bindtap="clear" /> <image src="/images/clear.png" class="search-clear" bindtap="clear" />
</block> </block>
</view> </view>
<view class="search text-center" bindtap="showConfirm"> <view class="search" bindtap="showConfirm">
<view class="text-center">搜索</view> <view class="text-center">搜索</view>
</view> </view>
</view> </view>
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
<block wx:for="{{serviceList}}" wx:key="index"> <block wx:for="{{serviceList}}" wx:key="index">
<view <view
class="service-items text-hide {{item.act?'active':''}}" class="service-items text-hide {{item.act?'active':''}}"
data-index="{{index}}" data-item="{{item}}"
bindtap="select"> bindtap="select">
{{item.serviceName}} {{item.serviceName}}
</view> </view>
......
{ {
"component": true, "component": true,
"usingComponents": { "usingComponents": {
"msg-box": "../components/msgBox/msgBox", "msg-box": "../../components/msgBox/msgBox",
"tab": "../components/Tab/Tab" "tab": "../../components/Tab/Tab"
}, },
"navigationStyle": "custom" "navigationStyle": "custom"
} }
// packagesList/mineDetail/pages/staffManage/createStaff/createStaff.js // packagesList/mineDetail/pages/staffManage/createStaff/createStaff.js
import { behavior as computedBehavior } from "~/utils/lib/miniprogram-computed";
Page({ Page({
behaviors: [computedBehavior],
/** /**
* 页面的初始数据 * 页面的初始数据
...@@ -17,13 +19,15 @@ Page({ ...@@ -17,13 +19,15 @@ Page({
label: '员工姓名', label: '员工姓名',
props: 'staffName', props: 'staffName',
type: 'input', type: 'input',
placeholder: '请输入员工姓名' placeholder: '请输入员工姓名',
maxLength: 20
}, { }, {
label: '手机号码', label: '手机号码',
tips: '(登录凭证)', tips: '(登录凭证)',
props: 'mobile', props: 'staffMobile',
type: 'input', type: 'input',
placeholder: '请输入手机号码' placeholder: '请输入手机号码',
maxLength: 11
}, { }, {
label: '可见客户', label: '可见客户',
props: 'connectionIds', props: 'connectionIds',
...@@ -99,8 +103,25 @@ Page({ ...@@ -99,8 +103,25 @@ Page({
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}], }],
formData: {}, formData: {
showServiceConfirm: false connectionValue: '全部'
},
showServiceConfirm: false,
toastList: {
selectServiceInfo: '所属服务中心不能为空',
staffName: '员工姓名不能为空',
staffMobile: '手机号码不能为空'
}
},
watch: {
'formData.selectServiceInfo.serviceCode': function (e) {
// 将可见客户置为全部
this.setData({
'formData.connectionValue': '全部',
'formData.selectedConnectionList': []
})
}
}, },
/** /**
...@@ -111,8 +132,10 @@ Page({ ...@@ -111,8 +132,10 @@ Page({
onRoute(options) { onRoute(options) {
this.setData({ this.setData({
addOrEdit: options?.type addOrEdit: options?.info ? 'edit' : 'add',
formData: options?.info || {connectionValue: '全部'}
}) })
console.log(this.data.formData)
}, },
/** /**
...@@ -147,6 +170,7 @@ Page({ ...@@ -147,6 +170,7 @@ Page({
// 选择服务中心/客户 // 选择服务中心/客户
jump(e) { jump(e) {
let { formData } = this.data
let { type } = e.currentTarget.dataset let { type } = e.currentTarget.dataset
switch(type) { switch(type) {
// 选择服务中心 // 选择服务中心
...@@ -154,23 +178,59 @@ Page({ ...@@ -154,23 +178,59 @@ Page({
this.hiddenSelectConfirm() this.hiddenSelectConfirm()
break break
case 2: case 2:
wx.$router.go('packagesList.selectConnectionPage') if (!formData.selectServiceInfo) return wx.$api.showToast('请先选择所属服务中心')
wx.$router.go('packagesList.selectConnectionPage', this.data.formData)
} }
}, },
hiddenSelectConfirm(e) { hiddenSelectConfirm(e) {
let selectServiceInfo = e?.detail let selectServiceInfo = e?.detail
console.log(selectServiceInfo) this.setData({ showServiceConfirm: !this.data.showServiceConfirm })
if (!selectServiceInfo) return
this.setData({ this.setData({
showServiceConfirm: !this.data.showServiceConfirm,
'formData.selectServiceInfo': selectServiceInfo, 'formData.selectServiceInfo': selectServiceInfo,
'formData.serviceValue': selectServiceInfo?.serviceName 'formData.serviceValue': selectServiceInfo?.serviceName
}) })
}, },
input(e) {
const { value } = e.detail,
{ name } = e.currentTarget.dataset
this.setData({
[`formData.${name}`]: value
})
},
// 校验
checkRequired(obj) {
console.log(obj)
let target = ['selectServiceInfo', 'staffName', 'staffMobile']
try {
target.map(key => {
if (!obj[key]) {
throw key
}
})
} catch (error) {
return error
}
return false
},
// 提交 // 提交
handleConfirm() { handleConfirm() {
let { addOrEdit } = this.data let { addOrEdit, formData, toastList } = this.data
const phoneRex = /^[1]([3-9])[0-9]{9}$/
let key = this.checkRequired(formData)
if (key) {
wx.$api.showToast(toastList[key])
return
}
if (!phoneRex.test(formData?.staffMobile)) {
wx.$api.showToast('请输入正确的手机号')
return
}
console.log(formData)
let message = addOrEdit == 'add' ? '是否确定创建员工?' : '是否确定修改员工信息?' let message = addOrEdit == 'add' ? '是否确定创建员工?' : '是否确定修改员工信息?'
wx.showModal({ wx.showModal({
title: '提示', title: '提示',
......
...@@ -11,7 +11,10 @@ ...@@ -11,7 +11,10 @@
<input <input
type="text" type="text"
placeholder="{{item.placeholder}}" placeholder="{{item.placeholder}}"
class="input" class="input"
bindinput="input"
data-name="{{item.props}}"
maxlength="{{item.maxLength}}"
value="{{formData[item.props]}}" value="{{formData[item.props]}}"
placeholder-class="input-placeholder" /> placeholder-class="input-placeholder" />
</view> </view>
......
var formatMobile = function (item) {
return item.substring(0,3)+" " + item.substring(3,7) +" "+item.substring(7)
}
module.exports = {
formatMobile: formatMobile
}
\ No newline at end of file \ No newline at end of file
...@@ -7,7 +7,7 @@ Page({ ...@@ -7,7 +7,7 @@ Page({
data: { data: {
showConnectionConfirm: false, showConnectionConfirm: false,
connectionList: [{ connectionList: [{
serviceCode: 1, connectionCode: 1,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加1号服务中心', serviceName: '广东嘀加1号服务中心',
...@@ -15,104 +15,104 @@ Page({ ...@@ -15,104 +15,104 @@ Page({
checked: true, checked: true,
disabled: true disabled: true
}, { }, {
serviceCode: 2, connectionCode: 2,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加2号服务', serviceName: '广东嘀加2号服务',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 3, connectionCode: 3,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加3号服务', serviceName: '广东嘀加3号服务',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 4, connectionCode: 4,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加4号服务中心', serviceName: '广东嘀加4号服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 5, connectionCode: 5,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加5号服务中心', serviceName: '广东嘀加5号服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 6, connectionCode: 6,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 7, connectionCode: 7,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 8, connectionCode: 8,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 9, connectionCode: 9,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 10, connectionCode: 10,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 11, connectionCode: 11,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 12, connectionCode: 12,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 13, connectionCode: 13,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '123456', serviceName: '123456',
time: '2022.10.03', time: '2022.10.03',
disabled: true disabled: true
}, { }, {
serviceCode: 14, connectionCode: 14,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 15, connectionCode: 15,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 16, connectionCode: 16,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 17, connectionCode: 17,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心', serviceName: '广东嘀加八号快乐酷爱咖哩鸡服务中心咖哩鸡服务中心咖哩鸡服务中心',
time: '2022.10.03' time: '2022.10.03'
}, { }, {
serviceCode: 18, connectionCode: 18,
staffName: '马保国', staffName: '马保国',
staffMobile: '13645674567', staffMobile: '13645674567',
serviceName: '789', serviceName: '789',
...@@ -138,6 +138,23 @@ Page({ ...@@ -138,6 +138,23 @@ Page({
}, },
onRoute(options) {
let { selectType } = this.data
selectType.map(v => {
// 未指定可见客户
if (options?.selectedConnectionList.length == 0 && v.type == 0) {
v.active = true
} else if (options?.selectedConnectionList.length > 0 && v.type == 1) {
v.active = true
this.setData({
showConnectionList: true
})
}
return v
})
this.setData({selectType, selectedConnectionList: options?.selectedConnectionList || []})
},
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
*/ */
...@@ -160,13 +177,13 @@ Page({ ...@@ -160,13 +177,13 @@ Page({
}, },
changeType(e) { changeType(e) {
let { index } = e.currentTarget.dataset let { type } = e.currentTarget.dataset
let { selectType, showConnectionList } = this.data let { selectType, showConnectionList } = this.data
selectType.forEach((v, ind) => { selectType.forEach((v, ind) => {
if (index == ind && v.active) return showConnectionList = !showConnectionList if (type == v.type && v.active) return showConnectionList = !showConnectionList
if (index == ind && !v.active) { if (type == v.type && !v.active) {
v.active = true v.active = true
if (index == 1) showConnectionList = true if (type == 1) showConnectionList = true
else showConnectionList = false else showConnectionList = false
} }
else v.active = false else v.active = false
...@@ -207,7 +224,7 @@ Page({ ...@@ -207,7 +224,7 @@ Page({
let prevPage = currentPages[currentPages.length - 2] let prevPage = currentPages[currentPages.length - 2]
prevPage.setData({ prevPage.setData({
'formData.connectionValue': arr.find(v => v.active && v.type == 0) ? '全部' : `已选择${selectedConnectionList?.length}位客户`, 'formData.connectionValue': arr.find(v => v.active && v.type == 0) ? '全部' : `已选择${selectedConnectionList?.length}位客户`,
'formData.selectedIds': selectedConnectionList 'formData.selectedConnectionList': selectedConnectionList
}) })
this.back() this.back()
}, },
......
...@@ -4,14 +4,14 @@ ...@@ -4,14 +4,14 @@
</navigation-bar> </navigation-bar>
<view class="select-connection-page" style="padding-top:{{tabBarStyle}}px;"> <view class="select-connection-page" style="padding-top:{{tabBarStyle}}px;">
<view class="select-content"> <view class="select-content">
<view class="flex_class" wx:for="{{selectType}}" wx:key="index" bindtap="changeType" data-index="{{index}}"> <view class="flex_class" wx:for="{{selectType}}" wx:key="index" bindtap="changeType" data-type="{{item.type}}">
<view class="checked_class"> <view class="checked_class">
<view hidden="{{!item.active}}"> <view hidden="{{!item.active}}">
<glsx-image src="personal/checked.png" class="checked_class" /> <glsx-image src="personal/checked.png" class="checked_class" />
</view> </view>
</view> </view>
<view class="flex1"> <view class="flex1">
<view class="label {{index == 1?'lable_border':''}}">{{item.label}}<glsx-image wx:if="{{index == 1}}" src="personal/arrow_right.png" class="arrow_up {{showConnectionList ? 'arrow_down' : ''}}" /></view> <view class="label {{item.type == 1?'lable_border':''}}">{{item.label}}<glsx-image wx:if="{{item.type == 1}}" src="personal/arrow_right.png" class="arrow_up {{showConnectionList ? 'arrow_down' : ''}}" /></view>
<view class="tips" wx:if="{{item.tips}}">{{item.tips}}</view> <view class="tips" wx:if="{{item.tips}}">{{item.tips}}</view>
</view> </view>
</view> </view>
...@@ -27,4 +27,4 @@ ...@@ -27,4 +27,4 @@
<view class="btn-cancel" bindtap="handleConfirm" bindtap="back">取消</view> <view class="btn-cancel" bindtap="handleConfirm" bindtap="back">取消</view>
</view> </view>
</view> </view>
<select-connection-confirm show="{{showConnectionConfirm}}" bind:selectConfirm="selectConfirm" connectionList="{{connectionList}}" tabBarStyle="{{tabBarStyle}}"></select-connection-confirm> <select-connection-confirm show="{{showConnectionConfirm}}" selectedConnectionList="{{selectedConnectionList || []}}" bind:selectConfirm="selectConfirm" connectionList="{{connectionList}}" tabBarStyle="{{tabBarStyle}}"></select-connection-confirm>
...@@ -131,8 +131,9 @@ Page({ ...@@ -131,8 +131,9 @@ Page({
// } // }
// } // }
// }) // })
let type = e.currentTarget.dataset let dataset = e.currentTarget.dataset
wx.$router.go('packagesList.createStaff', type) console.log(dataset)
wx.$router.go('packagesList.createStaff', dataset)
}, },
/** /**
......
<!--packagesList/mineDetail/pages/staffManage/staffManage.wxml--> <!--packagesList/mineDetail/pages/staffManage/staffManage.wxml-->
<wxs src="../index.wxs" module="format" />
<view class="staff-list-page"> <view class="staff-list-page">
<view class="btn_box" bindtap="jump" data-type="add"> <view class="btn_box" bindtap="jump">
<glsx-image src="index/apply.png" class="icon" /> <glsx-image src="index/apply.png" class="icon" />
<text>创建新员工</text> <text>创建新员工</text>
</view> </view>
<view class="content-box" wx:if="{{!staffList.length}}"> <view class="content-box" wx:if="{{staffList.length}}">
<view class="title-box"> <view class="title-box">
<view class="title">员工数量:<text class="number">{{total}}</text></view> <view class="title">员工数量:<text class="number">{{total}}</text></view>
<view class="select-btn"> <view class="select-btn">
...@@ -23,14 +24,14 @@ ...@@ -23,14 +24,14 @@
style="height:calc(100vh - 148rpx - 110rpx);" style="height:calc(100vh - 148rpx - 110rpx);"
refresher-threshold="104" refresher-threshold="104"
refresher-triggered="{{triggered}}"> refresher-triggered="{{triggered}}">
<view class="item-box" wx:for="{{staffList}}" wx:key="index" bindtap="jump" data-type="edit"> <view class="item-box" wx:for="{{staffList}}" wx:key="index" bindtap="jump" data-info="{{item}}">
<view class="top"> <view class="top">
<view class="message"> <view class="message">
<glsx-image wx:if="{{!item.avatarUrl}}" src="personal/staff_defalut_avatar.png" class="avatar"/> <glsx-image wx:if="{{!item.avatarUrl}}" src="personal/staff_defalut_avatar.png" class="avatar"/>
<image wx:else src="{{item.avatarUrl}}" class="avatar"></image> <image wx:else src="{{item.avatarUrl}}" class="avatar"></image>
<view class="message-text"> <view class="message-text">
<view class="name">{{item.staffName}}</view> <view class="name">{{item.staffName}}</view>
<view class="mobile">{{item.staffMobile}}</view> <view class="mobile">{{format.formatMobile(item.staffMobile)}}</view>
</view> </view>
</view> </view>
<glsx-image src="personal/arrow_right.png" class="arrow_right" /> <glsx-image src="personal/arrow_right.png" class="arrow_right" />
......
...@@ -23,27 +23,27 @@ Page({ ...@@ -23,27 +23,27 @@ Page({
test: `/personal/icon2.png`, test: `/personal/icon2.png`,
boxItemList: [{ boxItemList: [{
name: '消息盒子', name: '消息盒子',
path: 'packagesList.messageBox', path: 'packageMine.messageBox',
hasRedPot: true, hasRedPot: true,
isRead: false isRead: false
}, { }, {
name: '看线索', name: '看线索',
path: 'packagesList.clue', path: 'packageMine.clue',
hasRedPot: true, hasRedPot: true,
isRead: false isRead: false
}, { }, {
name: '服务中心管理', name: '服务中心管理',
path: 'packagesList.serviceList', path: 'packageMine.serviceList',
hasRedPot: true, hasRedPot: true,
isRead: false isRead: false
}, { }, {
name: '员工管理', name: '员工管理',
path: 'packagesList.staffList', path: 'packageMine.staffList',
hasRedPot: true, hasRedPot: true,
isRead: false isRead: false
}, { }, {
name: '客户管理', name: '客户管理',
path: 'packagesList.customerManagement' path: 'packageMine.customerManagement'
}], }],
isShowService: false, isShowService: false,
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!