Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
business-assistant
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 6a7b74fd
authored
Apr 11, 2023
by
chenwq
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
样式调整,联调
1 parent
32f68ea5
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
411 additions
and
99 deletions
api/outputApi/output.js
packageMine/pages/customerManagement/customerList/customerList.wxml
packageMine/pages/customerManagement/technicianList/constant/data.js
packageMine/pages/customerManagement/technicianList/technicianList.js
packageMine/pages/customerManagement/technicianList/technicianList.wxml
pages/tab/output/components/BusiCard/BusiCard.js
pages/tab/output/components/BusiCard/BusiCard.scss
pages/tab/output/components/BusiCard/BusiCard.wxml
pages/tab/output/components/BusiCard/constant/data.js
pages/tab/output/components/StaffSort/StaffSort.js
pages/tab/output/components/StaffSort/StaffSort.scss
pages/tab/output/components/StaffSort/StaffSort.wxml
pages/tab/output/components/staff/staff.js
pages/tab/output/components/staff/staff.json
pages/tab/output/components/staff/staff.scss
pages/tab/output/components/staff/staff.wxml
api/outputApi/output.js
View file @
6a7b74f
...
@@ -132,5 +132,15 @@ class outputApi {
...
@@ -132,5 +132,15 @@ class outputApi {
...
data
...
data
})
})
}
}
// 我的员工
/** 服务商查询园区店员工产值统计 */
getStaffList
(
data
)
{
data
.
routerMethod
=
'dj.api.smarcarlife.yquser.stat.byPartnerMerchant'
return
api
.
post
({
method
:
'scrm.api.boutiquecoupon.rop.boutique.router.withoutLogin'
,
...
data
})
}
}
}
export
default
outputApi
export
default
outputApi
packageMine/pages/customerManagement/customerList/customerList.wxml
View file @
6a7b74f
...
@@ -33,7 +33,7 @@
...
@@ -33,7 +33,7 @@
<!-- 技师 -->
<!-- 技师 -->
<view class="employee-list">
<view class="employee-list">
<view class="avatar-box">
<view class="avatar-box">
<glsx-image class="avatar-img" src="personal/
staff
_defalut_avatar.png" />
<glsx-image class="avatar-img" src="personal/
tech
_defalut_avatar.png" />
<view wx:if="{{item.technicianCount != '0'}}" class="num">{{item.technicianCount > maxNum ? (maxNum + '+') : item.technicianCount}}</view>
<view wx:if="{{item.technicianCount != '0'}}" class="num">{{item.technicianCount > maxNum ? (maxNum + '+') : item.technicianCount}}</view>
</view>
</view>
<view class="look-btn" data-target="{{item}}" catchtap="handleTechnician">技师</view>
<view class="look-btn" data-target="{{item}}" catchtap="handleTechnician">技师</view>
...
...
packageMine/pages/customerManagement/technicianList/constant/data.js
View file @
6a7b74f
...
@@ -7,7 +7,7 @@ const formItems = [{
...
@@ -7,7 +7,7 @@ const formItems = [{
props
:
'technicianName'
,
props
:
'technicianName'
,
type
:
'input'
,
type
:
'input'
,
placeholder
:
'请输入技师的名称'
,
placeholder
:
'请输入技师的名称'
,
maxlength
:
1
0
maxlength
:
1
5
}]
}]
export
default
{
export
default
{
...
...
packageMine/pages/customerManagement/technicianList/technicianList.js
View file @
6a7b74f
...
@@ -134,6 +134,7 @@ Page({
...
@@ -134,6 +134,7 @@ Page({
cancelText
:
'取消'
,
cancelText
:
'取消'
,
confirmColor
:
'#3666FE'
,
confirmColor
:
'#3666FE'
,
success
(
res
)
{
success
(
res
)
{
if
(
res
.
confirm
)
{
wx
.
$api
.
showLoading
(
'加载中...'
)
wx
.
$api
.
showLoading
(
'加载中...'
)
mineServiceApi
.
deleteTechnician
(
params
).
then
(
res
=>
{
mineServiceApi
.
deleteTechnician
(
params
).
then
(
res
=>
{
let
{
code
,
data
,
message
}
=
res
let
{
code
,
data
,
message
}
=
res
...
@@ -146,6 +147,7 @@ Page({
...
@@ -146,6 +147,7 @@ Page({
}
}
})
})
}
}
}
})
})
},
},
...
...
packageMine/pages/customerManagement/technicianList/technicianList.wxml
View file @
6a7b74f
...
@@ -13,12 +13,12 @@
...
@@ -13,12 +13,12 @@
<view class="item-box" wx:for="{{technicianList}}" wx:key="index">
<view class="item-box" wx:for="{{technicianList}}" wx:key="index">
<view class="top">
<view class="top">
<view class="message">
<view class="message">
<glsx-image src="personal/
staff
_defalut_avatar.png" class="avatar" />
<glsx-image src="personal/
tech
_defalut_avatar.png" class="avatar" />
<view class="message-text">
<view class="message-text">
<input wx:if="{{item.isEdit}}" type="text" placeholder="{{formItems[0].placeholder}}" maxlength="{{formItems[0].maxlength}}" class="input" value="{{formData.technicianName}}" focus="{{item.isEdit}}" placeholder-class="input-placeholder" data-attr="{{formItems[0].props}}" confirm-type="done" bindinput="handleInput" bindblur="handleConfirm" />
<input wx:if="{{item.isEdit}}" type="text" placeholder="{{formItems[0].placeholder}}" maxlength="{{formItems[0].maxlength}}" class="input" value="{{formData.technicianName}}" focus="{{item.isEdit}}" placeholder-class="input-placeholder" data-attr="{{formItems[0].props}}" confirm-type="done" bindinput="handleInput" bindblur="handleConfirm" />
<view wx:else class="merchant">{{item.technicianName}}</view>
<view wx:else class="merchant">{{item.technicianName}}</view>
</view>
</view>
<glsx-image wx:if="{{!item.isEdit}}" src="personal/icon-
departmen
t.png" class="icon-edit" bindtap="handleEdit" data-type="edit" data-target="{{item}}" data-idx="{{index}}" />
<glsx-image wx:if="{{!item.isEdit}}" src="personal/icon-
edi
t.png" class="icon-edit" bindtap="handleEdit" data-type="edit" data-target="{{item}}" data-idx="{{index}}" />
</view>
</view>
<view class="delete" bindtap="handleDelete" data-target="{{item}}">删除</view>
<view class="delete" bindtap="handleDelete" data-target="{{item}}">删除</view>
</view>
</view>
...
...
pages/tab/output/components/BusiCard/BusiCard.js
View file @
6a7b74f
// pages/tab/output/components/BusiCard/BusiCard.js
// pages/tab/output/components/BusiCard/BusiCard.js
import
constantData
from
'./constant/data'
Component
({
Component
({
/**
/**
* 组件的属性列表
* 组件的属性列表
...
@@ -11,6 +12,32 @@ Component({
...
@@ -11,6 +12,32 @@ Component({
sceneCode
:
{
sceneCode
:
{
type
:
String
,
type
:
String
,
value
:
'-1'
value
:
'-1'
},
fromPage
:
{
type
:
String
,
value
:
'client'
},
formData
:
{
type
:
Object
,
value
:
()
=>
{
}
}
},
lifetimes
:
{
attached
()
{
let
{
fromPage
,
clientFormObj
,
staffFormObj
}
=
this
.
data
let
_obj
=
{}
switch
(
fromPage
)
{
case
'staff'
:
_obj
=
JSON
.
parse
(
JSON
.
stringify
(
staffFormObj
))
break
default
:
_obj
=
JSON
.
parse
(
JSON
.
stringify
(
clientFormObj
))
break
}
this
.
setData
({
formObj
:
_obj
})
}
}
},
},
...
@@ -18,74 +45,10 @@ Component({
...
@@ -18,74 +45,10 @@ Component({
* 组件的初始数据
* 组件的初始数据
*/
*/
data
:
{
data
:
{
formObj
:
{
formObj
:
{},
'-1'
:
[{
timeTabObj
:
constantData
.
timeTabObj
,
label
:
'精品升级'
,
clientFormObj
:
constantData
.
clientFormObj
,
name
:
'boutiqueUpgrade'
,
staffFormObj
:
constantData
.
staffFormObj
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'售后众筹'
,
name
:
'afterSalesCrowdfunding'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'会员权益/升级'
,
name
:
'vdUpgrade'
,
prefix
:
'¥'
,
isNum
:
true
}],
'SC002'
:
[{
label
:
'营业额'
,
name
:
'totalSubOrderOrderMoney'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'到店贴膜量'
,
name
:
'toShopCount'
},
{
label
:
'升级订单'
,
name
:
'upgradeCount'
},
{
label
:
'战败订单'
,
name
:
'noUpgradeCount'
},
{
label
:
'升级客单价'
,
name
:
'calUpPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'升级转化率'
,
name
:
'calTransform'
,
suffix
:
'%'
}],
'SC001'
:
[{
label
:
'营业额'
,
name
:
'turnover'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'推荐客户量'
,
name
:
'customerNum'
},
{
label
:
'成交客户量'
,
name
:
'successNum'
},
{
label
:
'融合客单价'
,
name
:
'fuseCustomerPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'权益客单价'
,
name
:
'equityCustomerPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'转化率'
,
name
:
'conversionRate'
,
suffix
:
'%'
}]
}
},
},
/**
/**
...
...
pages/tab/output/components/BusiCard/BusiCard.scss
View file @
6a7b74f
...
@@ -4,29 +4,58 @@
...
@@ -4,29 +4,58 @@
box-shadow
:
0
2rpx
20rpx
0
#b4bacc
52
;
box-shadow
:
0
2rpx
20rpx
0
#b4bacc
52
;
border-radius
:
8rpx
;
border-radius
:
8rpx
;
margin-bottom
:
20rpx
;
margin-bottom
:
20rpx
;
padding
:
20rpx
;
padding
:
20rpx
0
;
.title-box
{
.title-box
{
display
:
flex
;
display
:
flex
;
align-items
:
center
;
align-items
:
center
;
padding
:
0
20rpx
;
.icon
{
.icon
{
width
:
40rpx
;
width
:
40rpx
;
height
:
40rpx
;
height
:
40rpx
;
margin-right
:
8rpx
;
margin-right
:
8rpx
;
padding-bottom
:
14rpx
;
padding-bottom
:
14rpx
;
border-radius
:
50%
;
}
}
.title
{
.title
{
display
:
flex
;
justify-content
:
space-between
;
width
:
calc
(
100%
-
40rpx
);
width
:
calc
(
100%
-
40rpx
);
border-bottom
:
2rpx
dotted
#E0E0E0
;
border-bottom
:
2rpx
dotted
#E0E0E0
;
padding-bottom
:
14rpx
;
padding-bottom
:
14rpx
;
}
}
.title-tap
{
height
:
36rpx
;
line-height
:
36rpx
;
background
:
#3e71fe
1f
;
border-radius
:
4rpx
;
font-size
:
20rpx
;
color
:
#3E71FE
;
padding
:
0
8rpx
;
}
}
.bf-blue
{
padding
:
0
;
}
.
bf-blue
:
:
before
{
display
:
inline-block
;
content
:
''
;
width
:
6rpx
;
height
:
28rpx
;
background
:
#3666FE
;
border-radius
:
0
4rpx
4rpx
0
;
margin
:
-12rpx
16rpx
0
0
;
}
}
.content
{
.content
{
display
:
flex
;
display
:
flex
;
flex-wrap
:
wrap
;
flex-wrap
:
wrap
;
padding
:
0
20rpx
;
}
}
.content-item
{
.content-item
{
...
...
pages/tab/output/components/BusiCard/BusiCard.wxml
View file @
6a7b74f
<!--pages/tab/output/components/BusiCard/BusiCard.wxml-->
<!--pages/tab/output/components/BusiCard/BusiCard.wxml-->
<wxs src="../index.wxs" module="filter" />
<wxs src="../index.wxs" module="filter" />
<view class="busi-card">
<view class="busi-card">
<view class="title-box">
<view class="title-box" wx:if="{{fromPage == 'staff'}}">
<glsx-image src="output/icon-head.png" class="icon" />
<image wx:if="{{formObj.userAvatar}}" src="{{formObj.userAvatar}}" class="icon" />
<glsx-image wx:else src="personal/staff_defalut_avatar.png" class="icon" />
<view class="title">
{{info.userName}}
<view class="title-tap">{{timeTabObj[formData.timeIdx || '0']}}</view>
</view>
</view>
<view class="title-box bf-blue" wx:else>
<view class="title">{{info.merchantName || info.merchantName4s || ''}}</view>
<view class="title">{{info.merchantName || info.merchantName4s || ''}}</view>
</view>
</view>
<view class="content">
<view class="content">
...
...
pages/tab/output/components/BusiCard/constant/data.js
0 → 100644
View file @
6a7b74f
const
timeTabObj
=
{
0
:
'今日指标'
,
1
:
'本月指标'
,
2
:
'累计指标'
}
// -1:全部;SC002:精品升级;SC001:会员权益/升级
const
clientFormObj
=
{
'-1'
:
[{
label
:
'精品升级'
,
name
:
'boutiqueUpgrade'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'售后众筹'
,
name
:
'afterSalesCrowdfunding'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'会员权益/升级'
,
name
:
'vdUpgrade'
,
prefix
:
'¥'
,
isNum
:
true
}],
'SC002'
:
[{
label
:
'营业额'
,
name
:
'totalSubOrderOrderMoney'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'到店贴膜量'
,
name
:
'toShopCount'
},
{
label
:
'升级订单'
,
name
:
'upgradeCount'
},
{
label
:
'战败订单'
,
name
:
'noUpgradeCount'
},
{
label
:
'升级客单价'
,
name
:
'calUpPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'升级转化率'
,
name
:
'calTransform'
,
suffix
:
'%'
}],
'SC001'
:
[{
label
:
'营业额'
,
name
:
'turnover'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'推荐客户量'
,
name
:
'customerNum'
},
{
label
:
'成交客户量'
,
name
:
'successNum'
},
{
label
:
'融合客单价'
,
name
:
'fuseCustomerPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'权益客单价'
,
name
:
'equityCustomerPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'转化率'
,
name
:
'conversionRate'
,
suffix
:
'%'
}]
}
// -1:全部;SC002:精品升级;SC001:会员权益/升级
const
staffFormObj
=
{
'-1'
:
[{
label
:
'全部'
,
name
:
'totalAmount'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'精品升级'
,
name
:
'totalBoutiqueAmount'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'会员权益/升级'
,
name
:
'totalVdAmount'
,
prefix
:
'¥'
,
isNum
:
true
}],
'SC002'
:
[{
label
:
'营业额'
,
name
:
'orderMoneyTotal'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'升级客单价'
,
name
:
'upgradeUnitPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'到店贴膜量'
,
name
:
'toShopTotal'
},
{
label
:
'升级订单'
,
name
:
'upgradeTotal'
},
{
label
:
'战败订单'
,
name
:
'notUpgradeTotal'
},
{
label
:
'升级转化率'
,
name
:
'upgradeRate'
,
suffix
:
'%'
}],
'SC001'
:
[{
label
:
'营业额'
,
name
:
'orderMoneyTotal'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'推荐客户量'
,
name
:
'recommendTotal'
},
{
label
:
'成交客户量'
,
name
:
'dealTotal'
},
{
label
:
'融合客单价'
,
name
:
'fusionUnitPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'权益客单价'
,
name
:
'vdUnitPrice'
,
prefix
:
'¥'
,
isNum
:
true
},
{
label
:
'转化率'
,
name
:
'convertRate'
,
suffix
:
'%'
}]
}
export
default
{
timeTabObj
,
clientFormObj
,
staffFormObj
}
\ No newline at end of file
\ No newline at end of file
pages/tab/output/components/StaffSort/StaffSort.js
View file @
6a7b74f
// pages/tab/output/components/StaffSort/StaffSort.js
// pages/tab/output/components/StaffSort/StaffSort.js
import
{
scenceList
}
from
'~/pages/tab/index/constant/data'
import
{
scenceList
}
from
'~/pages/tab/index/constant/data'
const
busiOptSceneCode
=
[
'-1'
,
'SC00
2'
,
'SC001
'
]
const
busiOptSceneCode
=
[
'-1'
,
'SC00
1'
,
'SC002
'
]
import
mineApi
from
'~/api/mineApi/index'
import
mineApi
from
'~/api/mineApi/index'
import
{
getNowMonth
}
from
'~/utils/format'
import
{
getNowMonth
}
from
'~/utils/format'
Component
({
Component
({
...
@@ -17,10 +17,10 @@ Component({
...
@@ -17,10 +17,10 @@ Component({
data
:
{
data
:
{
busiOptSceneCode
,
busiOptSceneCode
,
formData
:
{
formData
:
{
// 0:全部-1;
1:精品升级SC002;2
:会员权益/升级SC001
// 0:全部-1;
2:精品升级SC002;1
:会员权益/升级SC001
busiIdx
:
0
,
busiIdx
:
0
,
sceneCode
:
'-1'
,
sceneCode
:
'-1'
,
yqMerchantName
:
'
全部
服务中心'
,
yqMerchantName
:
'服务中心'
,
timeIdx
:
0
timeIdx
:
0
},
},
// 服务中心
// 服务中心
...
@@ -28,6 +28,7 @@ Component({
...
@@ -28,6 +28,7 @@ Component({
serviceList
:
[],
serviceList
:
[],
// 筛选项折叠
// 筛选项折叠
isFold
:
false
,
isFold
:
false
,
isInputClear
:
false
,
baseData
:
{
baseData
:
{
busiList
:
[],
busiList
:
[],
timeList
:
[{
timeList
:
[{
...
@@ -44,8 +45,10 @@ Component({
...
@@ -44,8 +45,10 @@ Component({
},
},
lifetimes
:
{
lifetimes
:
{
attach
ed
()
{
creat
ed
()
{
this
.
initTime
()
this
.
initTime
()
},
attached
()
{
this
.
dealBusiList
()
this
.
dealBusiList
()
this
.
getSeviceCenter
()
this
.
getSeviceCenter
()
}
}
...
@@ -55,6 +58,29 @@ Component({
...
@@ -55,6 +58,29 @@ Component({
* 组件的方法列表
* 组件的方法列表
*/
*/
methods
:
{
methods
:
{
dealSearchTime
()
{
let
{
dataObj
,
formData
,
baseData
:
{
timeList
}
}
=
this
.
data
var
params
=
dataObj
[
timeList
[
formData
.
timeIdx
||
0
]?.
name
||
'todayTime'
]
return
params
},
dealParams
()
{
let
{
formData
}
=
this
.
data
let
params
=
{
sceneType
:
formData
.
busiIdx
||
''
,
yqMerchantIds
:
formData
.
yqMerchantId
||
''
,
userName
:
formData
.
userName
||
''
,
...
this
.
dealSearchTime
()
}
return
params
},
// handleInputeClear(e) {
// this.setData({
// isInputClear: true,
// ['formData.userName']: ''
// })
// },
handleInput
(
e
)
{
handleInput
(
e
)
{
let
{
attr
}
=
e
.
currentTarget
.
dataset
let
{
attr
}
=
e
.
currentTarget
.
dataset
let
{
value
}
=
e
.
detail
let
{
value
}
=
e
.
detail
...
@@ -75,7 +101,16 @@ Component({
...
@@ -75,7 +101,16 @@ Component({
},
},
handleInputBlur
()
{
handleInputBlur
()
{
let
{
isInputClear
}
=
this
.
data
console
.
log
(
isInputClear
,
'eieieii'
)
if
(
isInputClear
)
{
this
.
setData
({
isInputClear
:
false
})
return
true
}
this
.
changeFold
()
this
.
changeFold
()
this
.
triggerEvent
(
'staffSearch'
)
},
},
// 获取服务中心数据
// 获取服务中心数据
...
@@ -96,9 +131,8 @@ Component({
...
@@ -96,9 +131,8 @@ Component({
})
})
},
},
// 获取员工列表
// 获取员工列表
getStaffList
(
e
)
{
handleServiceChange
(
e
)
{
wx
.
$api
.
hideLoading
()
wx
.
$api
.
hideLoading
()
console
.
log
(
e
,
'切换----'
)
let
{
formData
}
=
this
.
data
let
{
formData
}
=
this
.
data
this
.
setData
({
this
.
setData
({
formData
:
{
formData
:
{
...
@@ -107,6 +141,7 @@ Component({
...
@@ -107,6 +141,7 @@ Component({
yqMerchantName
:
e
.
detail
.
yqMerchantName
yqMerchantName
:
e
.
detail
.
yqMerchantName
}
}
})
})
this
.
triggerEvent
(
'staffSearch'
)
},
},
// 格式化时间
// 格式化时间
initTime
()
{
initTime
()
{
...
@@ -114,16 +149,16 @@ Component({
...
@@ -114,16 +149,16 @@ Component({
let
today
=
date
.
getDate
()
let
today
=
date
.
getDate
()
let
month
=
getNowMonth
()
let
month
=
getNowMonth
()
const
todayTime
=
{
const
todayTime
=
{
startTim
e
:
`
${
month
}
-
${
today
}
00:00:00`
,
dataBeginDat
e
:
`
${
month
}
-
${
today
}
00:00:00`
,
endTim
e
:
`
${
month
}
-
${
today
}
23:59:59`
dataEndDat
e
:
`
${
month
}
-
${
today
}
23:59:59`
}
}
const
monthTime
=
{
const
monthTime
=
{
startTim
e
:
`
${
month
}
-01 00:00:00`
,
dataBeginDat
e
:
`
${
month
}
-01 00:00:00`
,
endTim
e
:
`
${
month
}
-
${
today
}
23:59:59`
dataEndDat
e
:
`
${
month
}
-
${
today
}
23:59:59`
}
}
const
defaultTime
=
{
const
defaultTime
=
{
startTim
e
:
''
,
dataBeginDat
e
:
''
,
endTim
e
:
`
${
month
}
-
${
today
}
23:59:59`
dataEndDat
e
:
`
${
month
}
-
${
today
}
23:59:59`
}
}
this
.
setData
({
this
.
setData
({
dataObj
:
{
dataObj
:
{
...
@@ -142,7 +177,7 @@ Component({
...
@@ -142,7 +177,7 @@ Component({
this
.
setData
({
this
.
setData
({
[
'formData.timeIdx'
]:
res
.
tapIndex
[
'formData.timeIdx'
]:
res
.
tapIndex
})
})
// this.handleBusiSearch(
)
this
.
triggerEvent
(
'staffSearch'
)
}
}
})
})
},
},
...
@@ -166,17 +201,15 @@ Component({
...
@@ -166,17 +201,15 @@ Component({
},
},
handleClickTab
(
e
)
{
handleClickTab
(
e
)
{
let
{
baseData
:
{
busiList
}
}
=
this
.
data
let
{
baseData
:
{
busiList
}
}
=
this
.
data
console
.
log
(
'???'
)
// 筛选
// 筛选
wx
.
showActionSheet
({
wx
.
showActionSheet
({
itemList
:
busiList
.
map
(
item
=>
item
.
name
),
itemList
:
busiList
.
map
(
item
=>
item
.
name
),
success
:
res
=>
{
success
:
res
=>
{
// this.resetBusiSearch()
this
.
setData
({
this
.
setData
({
[
'formData.busiIdx'
]:
res
.
tapIndex
,
[
'formData.busiIdx'
]:
res
.
tapIndex
,
[
'formData.sceneCode'
]:
busiOptSceneCode
[
res
.
tapIndex
]
[
'formData.sceneCode'
]:
busiOptSceneCode
[
res
.
tapIndex
]
})
})
// this.handleBusiSearch(
)
this
.
triggerEvent
(
'staffSearch'
)
}
}
})
})
},
},
...
...
pages/tab/output/components/StaffSort/StaffSort.scss
View file @
6a7b74f
...
@@ -48,6 +48,9 @@
...
@@ -48,6 +48,9 @@
}
}
.input
{
.input
{
position
:
relative
;
display
:
flex
;
align-items
:
center
;
box-sizing
:
border-box
;
box-sizing
:
border-box
;
width
:
128rpx
;
width
:
128rpx
;
height
:
60rpx
;
height
:
60rpx
;
...
@@ -58,12 +61,18 @@
...
@@ -58,12 +61,18 @@
transition
:
width
0
.2s
ease-out
;
transition
:
width
0
.2s
ease-out
;
}
}
.icon-delete
{
position
:
absolute
;
top
:
6rpx
;
right
:
10rpx
;
}
.long-input
{
.long-input
{
width
:
calc
(
100vw
-
180rpx
);
width
:
calc
(
100vw
-
180rpx
);
}
}
.input-placeholder
{
.input-placeholder
{
font-size
:
2
8
rpx
;
font-size
:
2
4
rpx
;
color
:
#858A94
;
color
:
#858A94
;
}
}
}
}
\ No newline at end of file
\ No newline at end of file
pages/tab/output/components/StaffSort/StaffSort.wxml
View file @
6a7b74f
...
@@ -19,8 +19,10 @@
...
@@ -19,8 +19,10 @@
</view>
</view>
</view>
</view>
</scroll-view>
</scroll-view>
<view class="right-box">
<view class="right-box input {{ isFold ? 'long-input' : '' }}">
<input type="text" placeholder="{{isFold ? '请输入员工姓名搜索' : '姓名'}}" maxlength="10" class="input {{ isFold ? 'long-input' : '' }}" value="{{formData.userName}}" placeholder-class="input-placeholder" data-attr="userName" confirm-type="search" bindinput="handleInput" bindfocus="handleInputFocus" bindblur="handleInputBlur" />
<glsx-image src="output/searchIcon.png" class="icon" />
<input type="text" placeholder="{{isFold ? '请输入员工姓名搜索' : '姓名'}}" maxlength="30" value="{{formData.userName}}" placeholder-class="input-placeholder" data-attr="userName" confirm-type="search" bindinput="handleInput" bindfocus="handleInputFocus" bindblur="handleInputBlur" />
<!-- <glsx-image wx:if="{{isFold}}" src="output/icon-delete.png" class="icon icon-delete" data-attr="userName" bindcatch="handleInputeClear" /> -->
</view>
</view>
</view>
</view>
<select-service-popup wx:if="{{popupShow}}" bind:hidePopup="filterTypeFn" bind:getStaffList="getStaffList" selectInfo="{{formData}}" popShow="{{popupShow}}" serviceRange="{{serviceList}}" />
\ No newline at end of file
\ No newline at end of file
<select-service-popup wx:if="{{popupShow}}" bind:hidePopup="filterTypeFn" bind:getStaffList="handleServiceChange" selectInfo="{{formData}}" popShow="{{popupShow}}" serviceRange="{{serviceList}}" />
\ No newline at end of file
\ No newline at end of file
pages/tab/output/components/staff/staff.js
View file @
6a7b74f
// pages/tab/output/components/staff/staff.js
// pages/tab/output/components/staff/staff.js
import
{
IMG_URL
}
from
'~/utils/constantData'
import
{
IMG_URL
}
from
'~/utils/constantData'
import
outputApi
from
'~/api/outputApi/index'
Component
({
Component
({
/**
/**
* 组件的属性列表
* 组件的属性列表
...
@@ -10,11 +11,64 @@ Component({
...
@@ -10,11 +11,64 @@ Component({
* 组件的初始数据
* 组件的初始数据
*/
*/
data
:
{
data
:
{
IMG_URL
,
bgUrl
:
`
${
IMG_URL
}
/personal/empty_tran.png`
,
formData
:
{
// 0:全部-1;2:精品升级SC002;1:会员权益/升级SC001
busiIdx
:
0
,
sceneCode
:
'-1'
,
yqMerchantName
:
'服务中心'
,
timeIdx
:
0
},
},
lifetimes
:
{
attached
()
{
this
.
getStaff
()
}
},
},
/**
/**
* 组件的方法列表
* 组件的方法列表
*/
*/
methods
:
{}
methods
:
{
// tab-业务经营切换
handleSearch
(
e
)
{
this
.
getStaff
(
true
,
true
)
},
getStaff
(
isReset
=
false
)
{
let
staffSortModule
=
this
.
selectComponent
(
'#staffSort'
)
let
staffSearchData
=
staffSortModule
?
staffSortModule
.
dealParams
()
:
{}
this
.
setData
({
formData
:
JSON
.
parse
(
JSON
.
stringify
(
staffSortModule
.
data
.
formData
))
})
let
{
userInfo
}
=
wx
.
$storage
.
get
()
let
params
=
{
...
staffSearchData
,
partnerMerchantId
:
userInfo
.
subLoginUser
.
merchantId
// partnerMerchantId: 44209468
}
outputApi
.
getStaffList
(
params
).
then
(
res
=>
{
if
(
isReset
)
{
this
.
setData
({
busiScrollTop
:
0
})
}
this
.
setData
({
triggered
:
false
})
let
_list
=
[]
// 1-会员权益/升级;2-精品升级
let
attrToNum
=
{
''
:
'totalStat'
,
'1'
:
'vdStat'
,
'2'
:
'boutiqueStat'
}
_list
=
res
[
attrToNum
[
staffSearchData
.
sceneType
||
''
]]
||
[]
this
.
setData
({
staffList
:
_list
})
})
},
}
})
})
pages/tab/output/components/staff/staff.json
View file @
6a7b74f
{
{
"component"
:
true
,
"component"
:
true
,
"usingComponents"
:
{
"usingComponents"
:
{
"staff-sort"
:
"../StaffSort/StaffSort"
"staff-sort"
:
"../StaffSort/StaffSort"
,
"busi-card"
:
"../BusiCard/BusiCard"
}
}
}
}
\ No newline at end of file
\ No newline at end of file
pages/tab/output/components/staff/staff.scss
View file @
6a7b74f
...
@@ -4,3 +4,40 @@
...
@@ -4,3 +4,40 @@
background-color
:
#fff
;
background-color
:
#fff
;
height
:
100%
;
height
:
100%
;
}
}
.staff
{
box-sizing
:
border-box
;
height
:
calc
(
100%
-
92rpx
);
color
:
#323436
;
// padding-top: 16rpx;
// background-color: #F2F3F7;
background-color
:
#FFFFFF
;
.title
{
height
:
80rpx
;
line-height
:
80rpx
;
font-size
:
28rpx
;
color
:
#323436
;
}
.
title
:
:
before
{
display
:
inline-block
;
content
:
''
;
width
:
6rpx
;
height
:
28rpx
;
background
:
#3666FE
;
border-radius
:
0
4rpx
4rpx
0
;
margin-right
:
16rpx
;
}
}
.staff-content
{
margin
:
0
16rpx
;
}
.end-txt
{
font-size
:
24rpx
;
text-align
:
center
;
color
:
#CCCED1
;
padding-bottom
:
60rpx
;
}
\ No newline at end of file
\ No newline at end of file
pages/tab/output/components/staff/staff.wxml
View file @
6a7b74f
<!-- pages/tab/output/components/staff/staff.wxml -->
<!-- pages/tab/output/components/staff/staff.wxml -->
<view class="staffCon">
<view class="staffCon">
<staff-sort></staff-sort>
<staff-sort id="staffSort" bindstaffSearch="handleSearch"></staff-sort>
<scroll-view class="staff" id="scroller" scroll-y="{{true}}" refresher-enabled="{{true}}" refresher-triggered="{{triggered}}" bindrefresherrefresh="handleSearch" lower-threshold='50' scroll-top="{{busiScrollTop}}">
<view wx:for="{{staffList}}" wx:key="index" class="staff-content">
<view class="title">{{item.yqMerchantName || ''}}</view>
<view wx:for="{{item.list}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
<busi-card info="{{subItem}}" fromPage="staff" sceneCode="{{formData.sceneCode}}" formData="{{formData}}"></busi-card>
</view>
</view>
<view wx:if="{{!staffList.length}}" class="end-txt">
<nothing-tips tips="暂无数据~" bgColor="{{'#FFFFFF'}}" bg="{{bgUrl}}" />
</view>
<view wx:else class="end-txt">
<view wx:if="{{formData.sceneCode == 'SC002'}}">数据统计精品升级全品类产品</view>
<view wx:else>到底啦~</view>
</view>
</scroll-view>
</view>
</view>
\ No newline at end of file
\ No newline at end of file
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment