Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
regional-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 19c93041
authored
Apr 28, 2026
by
zhangxw
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
驻店管理 调店分配新增员工改造需求开发
1 parent
59525781
Hide whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
352 additions
and
214 deletions
app.json
packageWorkspace/pages/residentManage/api.js
packageWorkspace/pages/residentManage/components/accountAllocation/index.js
packageWorkspace/pages/residentManage/components/accountAllocation/index.wxml
packageWorkspace/pages/residentManage/components/addStaff/index.js
packageWorkspace/pages/residentManage/components/addStaff/index.wxml
packageWorkspace/pages/residentManage/components/businessType/index.js
packageWorkspace/pages/residentManage/components/businessType/index.sass
packageWorkspace/pages/residentManage/components/businessType/index.wxml
packageWorkspace/pages/residentManage/components/shopMerchant/index.js
packageWorkspace/pages/residentManage/components/shopMerchant/index.sass
packageWorkspace/pages/residentManage/components/shopMerchant/index.wxml
packageWorkspace/pages/residentManage/components/yqMerchant/index.sass
packageWorkspace/pages/residentManage/createStaff.js
packageWorkspace/pages/residentManage/createStaff.json
packageWorkspace/pages/residentManage/createStaff.sass
packageWorkspace/pages/residentManage/createStaff.wxml
packageWorkspace/pages/residentManage/residentManage.js
packageWorkspace/pages/residentManage/residentManage.json
packageWorkspace/pages/residentManage/residentManage.wxml
project.config.json
router/router.js
app.json
View file @
19c9304
...
@@ -59,10 +59,9 @@
...
@@ -59,10 +59,9 @@
"root"
:
"packageWorkspace"
,
"root"
:
"packageWorkspace"
,
"name"
:
"packageWorkspace"
,
"name"
:
"packageWorkspace"
,
"pages"
:
[
"pages"
:
[
"pages/serverCenter/view/serverCenter/serverCenter"
,
"pages/serverCenter/view/serverCenter/serverCenter"
,
"pages/serverCenter/view/companyNoticeDetail/companyNoticeDetail"
,
"pages/serverCenter/view/companyNoticeDetail/companyNoticeDetail"
,
"pages/refundOperationList/refundOperationList"
,
"pages/refundOperationList/refundOperationList"
,
"pages/refundDetailList/refundDetailList"
,
"pages/refundDetailList/refundDetailList"
,
"pages/refundApply/refundApply"
,
"pages/refundApply/refundApply"
,
"pages/receptionRecords/receptionRecords"
,
"pages/receptionRecords/receptionRecords"
,
...
@@ -79,17 +78,18 @@
...
@@ -79,17 +78,18 @@
"pages/carSeries/carSeries"
,
"pages/carSeries/carSeries"
,
"pages/performanceRating/rateList/retaList"
,
"pages/performanceRating/rateList/retaList"
,
"pages/validReferralCount/referralCountList/referralCountList"
,
"pages/validReferralCount/referralCountList/referralCountList"
,
"pages/attendanceStatis/attendanceList/attendanceList"
,
"pages/attendanceStatis/attendanceList/attendanceList"
,
"pages/appealFormManage/appealFormList/appealFormList"
,
"pages/appealFormManage/appealFormList/appealFormList"
,
"pages/orderApprovalManage/orderApprovalList/orderApprovalList"
,
"pages/orderApprovalManage/orderApprovalList/orderApprovalList"
,
"pages/orderApprovalManage/orderApprovalDetail/orderApprovalDetail"
,
"pages/orderApprovalManage/orderApprovalDetail/orderApprovalDetail"
,
"pages/performanceRating/ruleNote/ruleNote"
,
"pages/performanceRating/ruleNote/ruleNote"
,
"pages/performanceRating/rateEdit/rateEdit"
,
"pages/performanceRating/rateEdit/rateEdit"
,
"pages/performanceRating/rateDetail/rateDetail"
,
"pages/performanceRating/rateDetail/rateDetail"
,
"pages/performanceRating/batchOperation/batchOperation"
,
"pages/performanceRating/batchOperation/batchOperation"
,
"pages/validReferralCount/referraCountEdit/referraCountEdit"
,
"pages/validReferralCount/referraCountEdit/referraCountEdit"
,
"pages/attendanceStatis/attendanceDetail/attendanceDetail"
,
"pages/attendanceStatis/attendanceDetail/attendanceDetail"
,
"pages/appealFormManage/appealFormDetail/appealFormDetail"
"pages/appealFormManage/appealFormDetail/appealFormDetail"
,
"pages/residentManage/createStaff"
]
]
},
},
{
{
...
@@ -144,4 +144,4 @@
...
@@ -144,4 +144,4 @@
},
},
"lazyCodeLoading"
:
"requiredComponents"
,
"lazyCodeLoading"
:
"requiredComponents"
,
"resizable"
:
true
"resizable"
:
true
}
}
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/api.js
View file @
19c9304
...
@@ -8,12 +8,12 @@ module.exports = {
...
@@ -8,12 +8,12 @@ module.exports = {
},
},
/**驻店管理-获取园区店 */
/**驻店管理-获取园区店 */
getyqMerchantList
(
data
)
{
getyqMerchantList
(
data
)
{
return
api
.
post
(
'dj.api.s
martcarlife.scene.yqMerchant.pageList
'
,
data
)
return
api
.
post
(
'dj.api.s
cenemerchantref.findAllMerchantPage
'
,
data
)
},
},
/**小程序新增员工*/
/**小程序新增员工*/
createStaffAccount
(
data
)
{
createStaffAccount
(
data
)
{
let
params
=
data
||
{}
let
params
=
data
||
{}
return
api
.
post
(
'dj.api.smartcarlife.staffBaseInfo.account.
add
'
,
params
)
return
api
.
post
(
'dj.api.smartcarlife.staffBaseInfo.account.
merchant.assign
'
,
params
)
},
},
/** 员工日报配置列表查询 */
/** 员工日报配置列表查询 */
...
@@ -33,6 +33,10 @@ module.exports = {
...
@@ -33,6 +33,10 @@ module.exports = {
/**修改员工日报填报门店配置 */
/**修改员工日报填报门店配置 */
updateDailyReportConfig
(
data
)
{
updateDailyReportConfig
(
data
)
{
return
api
.
post
(
"dj.api.smartcarlife.staff.dailyReportConfig.update"
,
data
);
return
api
.
post
(
"dj.api.smartcarlife.staff.dailyReportConfig.update"
,
data
);
},
},
/** 根据人员获取业务场景数据 */
getBaseSceneCodeList
(
data
)
{
return
api
.
post
(
"dj.api.scenemerchantref.findAllSceneByMerchantId"
,
data
)
}
};
};
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/components/accountAllocation/index.js
View file @
19c9304
...
@@ -316,20 +316,12 @@ Component({
...
@@ -316,20 +316,12 @@ Component({
}
=
this
.
data
;
}
=
this
.
data
;
let
{
let
{
staffPhone
,
staffPhone
,
staffName
staffName
,
}
=
accountList
[
index
]
staffId
let
pageInstance
=
wx
.
$router
.
getPageInstance
()
}
=
accountList
[
index
]
wx
.
navigateTo
({
pageInstance
.
setData
({
url
:
`/packageWorkspace/pages/residentManage/createStaff?staffPhone=
${
staffPhone
}
&staffName=
${
staffName
}
&staffId=
${
staffId
}
`
activeIndex
:
0
})
},
()
=>
{
let
thisPage
=
pageInstance
.
selectComponent
(
`#componet-0`
)
thisPage
.
setData
({
'staffObj.staffName'
:
staffName
,
'staffObj.staffPhone'
:
staffPhone
})
})
},
},
// 触底刷新
// 触底刷新
mineReachBottom
()
{
mineReachBottom
()
{
...
@@ -362,11 +354,11 @@ Component({
...
@@ -362,11 +354,11 @@ Component({
})
})
},
},
},
},
lifetimes
:
{
//
lifetimes: {
attached
:
function
()
{
//
attached: function () {
this
.
getData
()
//
this.getData()
}
//
}
},
//
},
})
})
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/components/accountAllocation/index.wxml
View file @
19c9304
...
@@ -23,7 +23,7 @@
...
@@ -23,7 +23,7 @@
<block wx:if="{{ isFlag }}">
<block wx:if="{{ isFlag }}">
<scroll-view
<scroll-view
class="account-box"
class="account-box"
style="height: calc(100vh - var(--fontSize
6
40));"
style="height: calc(100vh - var(--fontSize
5
40));"
enhanced="{{ true }}"
enhanced="{{ true }}"
show-scrollbar="{{ false }}"
show-scrollbar="{{ false }}"
scroll-y
scroll-y
...
...
packageWorkspace/pages/residentManage/components/addStaff/index.js
View file @
19c9304
...
@@ -39,62 +39,70 @@ Component({
...
@@ -39,62 +39,70 @@ Component({
merchantName
:
''
,
//归属门店名称
merchantName
:
''
,
//归属门店名称
yqMerchantId
:
''
,
//园区店id
yqMerchantId
:
''
,
//园区店id
yqMerchantName
:
''
,
//园区店名称
yqMerchantName
:
''
,
//园区店名称
}
},
},
baseSceneList
:
[]
},
/**
/**
* 组件的方法列表
* 组件的方法列表
*/
*/
methods
:
{
methods
:
{
getBaseSceneList
()
{
let
{
staffObj
}
=
this
.
data
api
.
getBaseSceneCodeList
({
merchantId
:
staffObj
?.
merchantId
}).
then
(
res
=>
{
this
.
setData
({
baseSceneList
:
res
?.
data
||
[]})
})
},
showPopup
(
e
)
{
showPopup
(
e
)
{
let
{
let
{
showName
showName
}
=
e
.
currentTarget
.
dataset
,
{
}
=
e
.
currentTarget
.
dataset
,
{
staffObj
:
{
staffObj
:
{
staffSceneLabel
,
staffSceneLabel
,
merchantId
,
merchantId
,
},
},
yqMerchartList
yqMerchartList
}
=
this
.
data
;
}
=
this
.
data
;
if
(
showName
==
'shopMerchantBox'
&&
staffSceneLabel
==
''
)
{
if
(
showName
==
'isBusiness'
&&
merchantId
==
''
)
{
wx
.
$util
.
showToast
(
`请先选择所属业务`
);
return
}
if
(
showName
==
'yqMerchartBox'
&&
merchantId
==
''
)
{
wx
.
$util
.
showToast
(
`请先选择归属门店`
);
wx
.
$util
.
showToast
(
`请先选择归属门店`
);
return
return
}
}
if
(
showName
==
'yqMerchartBox'
&&
yqMerchartList
.
length
<=
1
)
{
if
(
showName
==
'yqMerchartBox'
&&
staffSceneLabel
==
''
)
{
wx
.
$util
.
showToast
(
`请先选择所属业务`
);
return
}
if
(
showName
==
'yqMerchartBox'
&&
yqMerchartList
.
length
<=
1
)
{
return
return
}
}
this
.
setData
({
this
.
setData
({
[
showName
]:
true
[
showName
]:
true
});
});
},
},
getyqMerchantList
()
{
// getyqMerchantList() {
let
{
// let {
staffSceneLabel
,
// staffSceneLabel,
merchantId
// merchantId
}
=
this
.
data
.
staffObj
// } = this.data.staffObj
let
params
=
{
// let params = {
sceneLabel
:
staffSceneLabel
,
// baseSceneCode: staffSceneLabel,
merchantId
// merchantId
}
// }
try
{
// try {
api
.
getyqMerchantList
(
params
).
then
(
res
=>
{
// api.getyqMerchantList(params).then(res => {
if
(
res
.
code
==
0
)
{
// if (res.code == 0) {
let
item
=
res
.
data
.
list
.
length
?
res
.
data
.
list
[
0
]
:
''
// let item = res.data.list.length ? res.data.list[0] : ''
this
.
setData
({
// console.log(item)
yqMerchartList
:
res
.
data
.
list
,
// this.setData({
'staffObj.yqMerchantId'
:
item
?
item
.
yqMerchantId
:
''
,
// yqMerchartList: res.data.list,
'staffObj.yqMerchantName'
:
item
?
item
.
yqMerchantName
:
''
// 'staffObj.yqMerchantId': item ? item.yqMerchantId : '',
})
// 'staffObj.yqMerchantName': item ? item.yqMerchantName : ''
}
// })
})
// }
}
catch
(
err
)
{
// })
// } catch (err) {
}
//
}
},
//
},
selectChoose
(
e
)
{
selectChoose
(
e
)
{
let
{
let
{
chooseList
,
chooseList
,
...
@@ -104,24 +112,36 @@ Component({
...
@@ -104,24 +112,36 @@ Component({
let
textArr
=
[],
let
textArr
=
[],
idArr
=
[];
idArr
=
[];
chooseList
.
forEach
(
item
=>
{
chooseList
.
forEach
(
item
=>
{
textArr
.
push
(
item
.
text
)
textArr
.
push
(
item
.
baseSceneCodeName
)
idArr
.
push
(
item
.
id
)
idArr
.
push
(
item
.
baseSceneCode
)
})
})
this
.
setData
({
this
.
setData
({
[
text
]:
textArr
.
join
(
','
),
[
text
]:
textArr
.
join
(
','
),
[
key
]:
idArr
.
join
(
','
),
[
key
]:
idArr
.
join
(
','
),
'staffObj.yqMerchantId'
:
''
,
'staffObj.yqMerchantId'
:
chooseList
&&
chooseList
[
0
]?.
serviceList
&&
chooseList
[
0
]?.
serviceList
[
0
]?.
merchantId
,
'staffObj.yqMerchantName'
:
''
,
'staffObj.yqMerchantName'
:
chooseList
&&
chooseList
[
0
]?.
serviceList
&&
chooseList
[
0
]?.
serviceList
[
0
]?.
merchantName
,
'staffObj.merchantId'
:
''
,
'staffObj.merchantName'
:
''
,
yqMerchartList
:
[]
})
})
},
},
selectChooseShop
(
e
)
{
let
{
shopMerchantId
,
shopMerchantName
}
=
e
.
detail
this
.
setData
({
'staffObj.merchantId'
:
shopMerchantId
,
'staffObj.merchantName'
:
shopMerchantName
,
'staffObj.staffSceneLabelText'
:
''
,
'staffObj.staffSceneLabel'
:
''
,
'staffObj.yqMerchantId'
:
''
,
'staffObj.yqMerchantName'
:
''
,
yqMerchartList
:
[],
shopMerchantBox
:
false
},
()
=>
{
this
.
getBaseSceneList
()
})
},
async
submit
(
i
)
{
async
submit
(
i
)
{
let
_this
=
this
;
let
_this
=
this
;
let
{
let
{
staffObj
staffObj
}
=
this
.
data
;
}
=
this
.
data
;
let
thisPage
=
wx
.
$router
.
getPageInstance
()
let
thisPage
=
wx
.
$router
.
getPageInstance
()
let
key
=
thisPage
.
checkRequired
(
staffObj
);
let
key
=
thisPage
.
checkRequired
(
staffObj
);
...
@@ -133,10 +153,11 @@ Component({
...
@@ -133,10 +153,11 @@ Component({
let
apiName
=
let
apiName
=
"createStaffAccount"
,
"createStaffAccount"
,
params
=
{
params
=
{
...
staffObj
...
staffObj
,
sceneList
:
staffObj
?.
staffSceneLabel
?.
split
(
','
)?.
map
(
val
=>
{
return
{
baseSceneCode
:
val
}
})
};
};
delete
params
.
staffSceneLabelText
delete
params
.
staffSceneLabelText
delete
params
.
staffSceneLabel
api
[
apiName
](
params
)
api
[
apiName
](
params
)
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
let
{
let
{
...
@@ -168,10 +189,7 @@ Component({
...
@@ -168,10 +189,7 @@ Component({
// staffObj: clearData
// staffObj: clearData
// }
// }
// )
// )
wx
.
$router
.
back
()
thisPage
.
setData
({
activeIndex
:
1
})
}
}
},
},
});
});
...
...
packageWorkspace/pages/residentManage/components/addStaff/index.wxml
View file @
19c9304
...
@@ -11,21 +11,21 @@
...
@@ -11,21 +11,21 @@
<view class="box">
<view class="box">
<gl-cell border valueAlign="right" label="员工姓名" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize290)" required>
<gl-cell border valueAlign="right" label="员工姓名" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize290)" required>
<input placeholder="请输入" value="{{staffObj.staffName}}" class="input" placeholder-class="placeholder-class" bindinput="input" data-name="staffObj.staffName" always-embed></input>
<input placeholder="请输入"
disabled style="color: #BBBBBB;"
value="{{staffObj.staffName}}" class="input" placeholder-class="placeholder-class" bindinput="input" data-name="staffObj.staffName" always-embed></input>
</gl-cell>
</gl-cell>
<gl-cell border valueAlign="right" label="手机号" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize140)" required>
<gl-cell border valueAlign="right" label="手机号" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize140)" required>
<input placeholder="请输入" class="input" value="{{staffObj.staffPhone}}" type="number" maxlength="11" placeholder-class="placeholder-class" bindinput="input" bindblur="phoneBlur" data-name="staffObj.staffPhone" always-embed></input>
<input placeholder="请输入" disabled class="input" style="color: #BBBBBB;" value="{{staffObj.staffPhone}}" type="number" maxlength="11" placeholder-class="placeholder-class" bindinput="input" bindblur="phoneBlur" data-name="staffObj.staffPhone" always-embed></input>
</gl-cell>
<gl-cell border valueAlign="right" required label="归属门店" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize180)" haveArrow bindclick="showPopup" data-show-name="shopMerchantBox" placeholder="点击选择">
<block wx:if="{{ staffObj.merchantId }}">
<view class="between">{{staffObj.merchantName}}{{staffObj.merchantId}}</view>
</block>
</gl-cell>
</gl-cell>
<gl-cell border valueAlign="right" label="所属业务" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize180)" required haveArrow bindclick="showPopup"data-show-name="isBusiness" placeholder="点击选择">
<gl-cell border valueAlign="right" label="所属业务" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize180)" required haveArrow bindclick="showPopup"data-show-name="isBusiness" placeholder="点击选择">
<block wx:if="{{ staffObj.staffSceneLabelText }}">
<block wx:if="{{ staffObj.staffSceneLabelText }}">
<view class="between">{{staffObj.staffSceneLabelText}}</view>
<view class="between">{{staffObj.staffSceneLabelText}}</view>
</block>
</block>
</gl-cell>
</gl-cell>
<gl-cell border valueAlign="right" required label="归属门店" cellHeight="{{cellHeight}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize180)" haveArrow bindclick="showPopup" data-show-name="shopMerchantBox" placeholder="点击选择">
<block wx:if="{{ staffObj.merchantId }}">
<view class="between">{{staffObj.merchantName}}{{staffObj.merchantId}}</view>
</block>
</gl-cell>
<gl-cell valueAlign="right" label="关联账号" required cellHeight="{{cellHeight}}" cellBoxStyle="{{cellBoxStyle}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize290)" haveArrow="{{yqMerchartList.length>1}}" bindclick="showPopup" data-show-name="yqMerchartBox" placeholder="点击选择" >
<gl-cell valueAlign="right" label="关联账号" required cellHeight="{{cellHeight}}" cellBoxStyle="{{cellBoxStyle}}" cellStyle="{{cellStyle}}" requiredAfter labelWidth="var(--fontSize290)" haveArrow="{{yqMerchartList.length>1}}" bindclick="showPopup" data-show-name="yqMerchartBox" placeholder="点击选择" >
<block wx:if="{{ staffObj.yqMerchantName }}">
<block wx:if="{{ staffObj.yqMerchantName }}">
<view class="between">{{staffObj.yqMerchantName}}{{staffObj.yqMerchantId}}</view>
<view class="between">{{staffObj.yqMerchantName}}{{staffObj.yqMerchantId}}</view>
...
@@ -36,6 +36,6 @@
...
@@ -36,6 +36,6 @@
<view class="btn" bind:tap="submit">确认开通</view>
<view class="btn" bind:tap="submit">确认开通</view>
<text class="hint">请核对员工姓名、手机号,开通账号后即可</text>
<text class="hint">请核对员工姓名、手机号,开通账号后即可</text>
<text class="hint">投入使用。登录密码默认为Aa+手机号</text>
<text class="hint">投入使用。登录密码默认为Aa+手机号</text>
<business-type show="{{isBusiness}}" scene-label="{{staffObj.staffSceneLabel}}" bindconfirm="selectChoose"></business-type>
<business-type show="{{isBusiness}}" scene-label="{{staffObj.staffSceneLabel}}" b
aseSceneList="{{baseSceneList}}" b
indconfirm="selectChoose"></business-type>
<shop-merchant show="{{shopMerchantBox}}" scene-label="{{staffObj.staffSceneLabel}}" bindconfirm="selectChoose" merchantId="{{staffObj.merchantId}}"></shop-merchant>
<shop-merchant show="{{shopMerchantBox}}" scene-label="{{staffObj.staffSceneLabel}}" bindconfirm="selectChoose
Shop
" merchantId="{{staffObj.merchantId}}"></shop-merchant>
<yq-merchant show="{{yqMerchartBox}}" merchantId="{{staffObj.yqMerchantId}}" yqMerchartList="{{yqMerchartList}}"></yq-merchant>
<yq-merchant show="{{yqMerchartBox}}" merchantId="{{staffObj.yqMerchantId}}" yqMerchartList="{{yqMerchartList}}"></yq-merchant>
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/components/businessType/index.js
View file @
19c9304
...
@@ -10,7 +10,8 @@ Component({
...
@@ -10,7 +10,8 @@ Component({
if
(
n
)
this
.
initData
();
if
(
n
)
this
.
initData
();
}
}
},
},
sceneLabel
:
String
,
sceneLabel
:
String
,
baseSceneList
:
Array
},
},
/**
/**
...
@@ -19,17 +20,7 @@ Component({
...
@@ -19,17 +20,7 @@ Component({
data
:
{
data
:
{
key
:
'staffObj.staffSceneLabel'
,
key
:
'staffObj.staffSceneLabel'
,
text
:
'staffObj.staffSceneLabelText'
,
text
:
'staffObj.staffSceneLabelText'
,
list
:
[{
list
:
[]
text
:
'轻改'
,
id
:
1
,
active
:
false
},
{
text
:
'会员权益/升级'
,
id
:
0
,
active
:
false
}
]
},
},
/**
/**
...
@@ -37,18 +28,18 @@ Component({
...
@@ -37,18 +28,18 @@ Component({
*/
*/
methods
:
{
methods
:
{
initData
(
ids
)
{
initData
(
ids
)
{
let
arr
=
this
.
data
.
sceneLabel
?
this
.
data
.
sceneLabel
.
split
(
','
):[],
let
arr
=
this
.
data
.
sceneLabel
?
this
.
data
.
sceneLabel
.
split
(
','
):[],
{
{
l
ist
baseSceneL
ist
}
=
this
.
data
;
}
=
this
.
data
;
l
ist
.
forEach
(
item
=>
{
baseSceneL
ist
.
forEach
(
item
=>
{
item
.
active
=
false
item
.
active
=
false
if
(
arr
.
includes
(
String
(
item
.
id
)))
{
if
(
arr
.
includes
(
String
(
item
.
baseSceneCode
)))
{
item
.
active
=
true
item
.
active
=
true
}
}
})
})
this
.
setData
({
this
.
setData
({
list
list
:
baseSceneList
})
})
},
},
choose
(
e
)
{
choose
(
e
)
{
...
@@ -56,9 +47,8 @@ Component({
...
@@ -56,9 +47,8 @@ Component({
list
list
}
=
this
.
data
,
{
}
=
this
.
data
,
{
index
index
}
=
e
.
currentTarget
.
dataset
;
}
=
e
.
currentTarget
.
dataset
;
let
thisPage
=
wx
.
$router
.
getPageInstance
();
list
.
forEach
(
item
=>
{
list
.
forEach
(
item
=>
{
item
.
active
=
false
item
.
active
=
false
})
})
list
[
index
].
active
=
true
list
[
index
].
active
=
true
...
@@ -77,19 +67,10 @@ Component({
...
@@ -77,19 +67,10 @@ Component({
return
item
return
item
}
}
})
})
let
thisPage
=
wx
.
$router
.
getPageInstance
();
if
(
!
chooseList
.
length
)
return
wx
.
$util
.
showToast
(
"请勾选业务"
);
if
(
!
chooseList
.
length
)
return
wx
.
$util
.
showToast
(
"请勾选业务"
);
this
.
setData
({
this
.
setData
({
show
:
false
,
show
:
false
,
});
});
thisPage
.
setData
({
isBusiness
:
false
,
});
// thisPage?.setGoodsTotal && thisPage.setGoodsTotal(chooseList);
// thisPage.setData({
// goodsList: chooseList,
// });
console
.
log
(
chooseList
)
this
.
triggerEvent
(
"confirm"
,{
chooseList
,
text
,
key
});
this
.
triggerEvent
(
"confirm"
,{
chooseList
,
text
,
key
});
},
},
cancel
()
{
cancel
()
{
...
...
packageWorkspace/pages/residentManage/components/businessType/index.sass
View file @
19c9304
/* tabWorkOrder/pages/residentManage/components/businessType/index.wxss */
/* tabWorkOrder/pages/residentManage/components/businessType/index.wxss */
.box
{
.box
{
height
:
200rpx
;
// height:200rpx;
height
:
100%
;
// width: calc(100% + var(--fontSize64));
// width: calc(100% + var(--fontSize64));
// margin-left: calc(-1 * var(--fontSize32));
// margin-left: calc(-1 * var(--fontSize32));
}
}
...
...
packageWorkspace/pages/residentManage/components/businessType/index.wxml
View file @
19c9304
<popup show="{{ show }}" title="选择所属业务" bindconfirm="confirm" bindcancel="cancel" height="40%">
<popup show="{{ show }}" title="选择所属业务" bindconfirm="confirm" bindcancel="cancel" height="40%">
<
view
class="box">
<
scroll-view scroll-y show-scrollbar="{{false}}" enhanced="true"
class="box">
<block wx:if="{{list.length}}">
<block wx:if="{{list.length}}">
<view class="item" wx:for="{{ list }}">
<view class="item" wx:for="{{ list }}">
<view class="item-hd" catchtap="choose" data-index="{{ index }}">
<view class="item-hd" catchtap="choose" data-index="{{ index }}">
...
@@ -11,10 +11,10 @@
...
@@ -11,10 +11,10 @@
<view class="arc" />
<view class="arc" />
</block>
</block>
</view>
</view>
<view class="name">{{item.
text
}}</view>
<view class="name">{{item.
baseSceneCodeName
}}</view>
</view>
</view>
</view>
</view>
</block>
</block>
<view class="safeAreaInset"></view>
<view class="safeAreaInset"></view>
</view>
</
scroll-
view>
</popup>
</popup>
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/components/shopMerchant/index.js
View file @
19c9304
...
@@ -87,8 +87,7 @@ Component({
...
@@ -87,8 +87,7 @@ Component({
let
params
=
{
let
params
=
{
merchantIdName
,
merchantIdName
,
pageNum
,
pageNum
,
pageSize
,
pageSize
sceneLabel
:
this
.
data
.
sceneLabel
}
}
api
.
getshopMerchantList
(
params
).
then
(
res
=>
{
api
.
getshopMerchantList
(
params
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
if
(
res
.
code
==
0
)
{
...
@@ -174,16 +173,17 @@ Component({
...
@@ -174,16 +173,17 @@ Component({
this
.
setData
({
this
.
setData
({
show
:
false
show
:
false
},
()
=>
{
},
()
=>
{
let
pageInstance
=
wx
.
$router
.
getPageInstance
()
this
.
triggerEvent
(
"confirm"
,{
shopMerchantId
,
shopMerchantName
})
let
thisPage
=
pageInstance
.
selectComponent
(
`#componet-0`
)
// let pageInstance = wx.$router.getPageInstance()
// let thisPage = pageInstance.selectComponent(`#componet-0`)
thisPage
.
setData
({
//
thisPage.setData({
shopMerchantBox
:
false
,
//
shopMerchantBox: false,
'staffObj.merchantId'
:
shopMerchantId
,
//
'staffObj.merchantId': shopMerchantId,
'staffObj.merchantName'
:
shopMerchantName
//
'staffObj.merchantName': shopMerchantName
},
()
=>
{
//
}, () => {
thisPage
.
getyqMerchantList
()
// //
thisPage.getyqMerchantList()
})
//
})
})
})
},
},
...
...
packageWorkspace/pages/residentManage/components/shopMerchant/index.sass
View file @
19c9304
...
@@ -62,7 +62,9 @@
...
@@ -62,7 +62,9 @@
}
}
.list-nothing,
.list-nothing,
.list-not
{
.list-not
{
text-align
:
center
;
text-align
:
center
;
font-size
:
28rpx
;
color
:
#979797
;
}
}
.search-input
{
.search-input
{
// border: 1rpx solid #979797;
// border: 1rpx solid #979797;
...
...
packageWorkspace/pages/residentManage/components/shopMerchant/index.wxml
View file @
19c9304
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
</block>
</block>
</view>
</view>
<block wx:if="{{isFlag}}">
<block wx:if="{{isFlag}}">
<scroll-view class="store-select-box" scroll-top="{{scrollTop}}" style="height: calc(100% - var(--fontSize
60
));" enhanced="{{true}}" show-scrollbar="{{false}}" scroll-y bindscrolltolower="mineReachBottom">
<scroll-view class="store-select-box" scroll-top="{{scrollTop}}" style="height: calc(100% - var(--fontSize
82
));" enhanced="{{true}}" show-scrollbar="{{false}}" scroll-y bindscrolltolower="mineReachBottom">
<view class="merchant-box" wx:if="{{shopMerchantList.length>0}}">
<view class="merchant-box" wx:if="{{shopMerchantList.length>0}}">
<block wx:for="{{shopMerchantList}}" wx:key="index">
<block wx:for="{{shopMerchantList}}" wx:key="index">
<view class="item {{storeIndex===index?'active':''}}" bindtap="choose" data-index="{{index}}">
<view class="item {{storeIndex===index?'active':''}}" bindtap="choose" data-index="{{index}}">
...
...
packageWorkspace/pages/residentManage/components/yqMerchant/index.sass
View file @
19c9304
...
@@ -6,7 +6,7 @@
...
@@ -6,7 +6,7 @@
font-size
:
var
(
--
fontSize32
)
;
font-size
:
var
(
--
fontSize32
)
;
}
}
.store-select-box
{
.store-select-box
{
height
:
calc
(
100%
-
var
(
--
fontSize
168
))
;
height
:
calc
(
100%
-
var
(
--
fontSize
82
))
;
}
}
.merchant-box
.item
{
.merchant-box
.item
{
...
...
packageWorkspace/pages/residentManage/createStaff.js
0 → 100644
View file @
19c9304
// packageWorkspace/pages/residentManage/createStaff.js
const
phoneRex
=
/^
[
1
]([
3-9
])[
0-9
]{9}
$/
;
Page
({
/**
* 页面的初始数据
*/
data
:
{
navStyle
:
'background-color: transparent'
,
navBarHeight
:
88
,
},
navbarReady
(
e
)
{
let
navBarHeight
=
e
.
detail
.
height
this
.
setData
({
navBarHeight
})
},
/**
* 生命周期函数--监听页面加载
*/
onLoad
(
options
)
{
let
comp
=
this
.
selectComponent
(
'#componet-0'
)
if
(
comp
)
{
comp
.
setData
({
'staffObj.staffName'
:
options
?.
staffName
,
'staffObj.staffPhone'
:
options
?.
staffPhone
,
'staffObj.staffId'
:
options
?.
staffId
})
}
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady
()
{
},
/**
* 生命周期函数--监听页面显示
*/
onShow
()
{
},
back
()
{
wx
.
$router
.
back
()
},
getBaseSceneList
()
{
getBaseSceneCodeList
},
checkRequired
(
obj
)
{
let
target
=
[
"staffName"
,
"staffPhone"
,
"staffSceneLabel"
,
"merchantId"
,
"yqMerchantId"
];
obj
=
{
...
obj
};
if
(
!
phoneRex
.
test
(
obj
.
staffPhone
))
{
this
.
showToast
(
"请输入正确的手机号"
);
return
true
;
}
try
{
target
.
map
((
key
)
=>
{
if
(
!
obj
[
key
])
{
throw
key
;
}
});
}
catch
(
error
)
{
return
error
;
}
return
false
;
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide
()
{
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload
()
{
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh
()
{
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom
()
{
},
/**
* 用户点击右上角分享
*/
onShareAppMessage
()
{
}
})
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/createStaff.json
0 → 100644
View file @
19c9304
{
"usingComponents"
:
{
"add-staff"
:
"./components/addStaff/index"
},
"navigationStyle"
:
"custom"
}
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/createStaff.sass
0 → 100644
View file @
19c9304
/* packageWorkspace/pages/residentManage/createStaff.wxss */
page
{
background
:
#F7F8FA
;
}
.bg
{
width
:
100%
;
height
:
var
(
--
fontSize400
)
;
background
:
linear-gradient
(
0deg
,
#e8f0fb
00
0%
,
#dde8fb
100%
)
;
position
:
fixed
;
left
:
0
;
top
:
0
;
z-index
:
-1
;
}
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/createStaff.wxml
0 → 100644
View file @
19c9304
<!--packageWorkspace/pages/residentManage/createStaff.wxml-->
<navigation-bar bindnavbarReady="navbarReady" class="navigation-bar-wrap" bindback="back" showBack="true" navStyle="{{navStyle}}">新增员工</navigation-bar>
<view class="bg"></view>
<view class="content" style="margin-top: {{navBarHeight}}px;">
<add-staff id="componet-0"></add-staff>
</view>
packageWorkspace/pages/residentManage/residentManage.js
View file @
19c9304
...
@@ -57,7 +57,8 @@ Page({
...
@@ -57,7 +57,8 @@ Page({
* 生命周期函数--监听页面显示
* 生命周期函数--监听页面显示
*/
*/
onShow
()
{
onShow
()
{
const
comp
=
this
.
selectComponent
(
"#componet-1"
);
comp
.
getData
&&
comp
.
getData
()
},
},
back
()
{
back
()
{
wx
.
$router
.
back
()
wx
.
$router
.
back
()
...
...
packageWorkspace/pages/residentManage/residentManage.json
View file @
19c9304
{
{
"navigationStyle"
:
"custom"
,
"navigationStyle"
:
"custom"
,
"usingComponents"
:
{
"usingComponents"
:
{
"add-staff"
:
"./components/addStaff/index"
,
"account-allocation"
:
"./components/accountAllocation/index"
"account-allocation"
:
"./components/accountAllocation/index"
}
}
}
}
\ No newline at end of file
\ No newline at end of file
packageWorkspace/pages/residentManage/residentManage.wxml
View file @
19c9304
...
@@ -2,9 +2,5 @@
...
@@ -2,9 +2,5 @@
<navigation-bar bindnavbarReady="navbarReady" class="navigation-bar-wrap" bindback="back" showBack="true" navStyle="{{navStyle}}">驻店管理</navigation-bar>
<navigation-bar bindnavbarReady="navbarReady" class="navigation-bar-wrap" bindback="back" showBack="true" navStyle="{{navStyle}}">驻店管理</navigation-bar>
<view class="bg"></view>
<view class="bg"></view>
<view class="content">
<view class="content">
<view class="tabs" >
<account-allocation id="componet-1"></account-allocation>
<view wx:for="{{list}}" wx:key="index" class="tab {{activeIndex==index?'active':''}}" data-index="{{index}}" bind:tap="changeHandle">{{item}}</view>
</view>
<add-staff id="componet-0" wx:if="{{activeIndex===0}}"></add-staff>
<account-allocation id="componet-1" wx:if="{{activeIndex===1}}"></account-allocation>
</view>
</view>
\ No newline at end of file
\ No newline at end of file
project.config.json
View file @
19c9304
{
{
"appid"
:
"wx6216a8e625e76b00"
,
"appid"
:
"wx6216a8e625e76b00"
,
"projectname"
:
"regional-assistant"
,
"projectname"
:
"regional-assistant"
,
"compileType"
:
"miniprogram"
,
"compileType"
:
"miniprogram"
,
"libVersion"
:
"3.14.3"
,
"libVersion"
:
"3.14.3"
,
"scripts"
:
{
"scripts"
:
{
"beforeUpload"
:
"node ./scripts/wx-upload-guard.js || exit 1"
"beforeUpload"
:
"node ./scripts/wx-upload-guard.js || exit 1"
},
},
"packOptions"
:
{
"packOptions"
:
{
"ignore"
:
[
"ignore"
:
[
{
{
"value"
:
".vscode"
,
"value"
:
".vscode"
,
"type"
:
"folder"
"type"
:
"folder"
}
}
],
],
"include"
:
[]
"include"
:
[]
},
},
"setting"
:
{
"setting"
:
{
"urlCheck"
:
false
,
"urlCheck"
:
false
,
"coverView"
:
true
,
"coverView"
:
true
,
"es6"
:
true
,
"es6"
:
true
,
"postcss"
:
true
,
"postcss"
:
true
,
"minified"
:
true
,
"minified"
:
true
,
"enhance"
:
true
,
"enhance"
:
true
,
"showShadowRootInWxmlPanel"
:
true
,
"showShadowRootInWxmlPanel"
:
true
,
"packNpmManually"
:
true
,
"packNpmManually"
:
true
,
"packNpmRelationList"
:
[
"packNpmRelationList"
:
[
{
{
"packageJsonPath"
:
"./package.json"
,
"packageJsonPath"
:
"./package.json"
,
"miniprogramNpmDistDir"
:
"./miniprogram_npm"
"miniprogramNpmDistDir"
:
"./miniprogram_npm"
}
}
],
],
"compileHotReLoad"
:
true
,
"compileHotReLoad"
:
true
,
"babelSetting"
:
{
"babelSetting"
:
{
"ignore"
:
[],
"ignore"
:
[],
"disablePlugins"
:
[],
"disablePlugins"
:
[],
"outputPath"
:
""
"outputPath"
:
""
},
},
"useCompilerPlugins"
:
[
"useCompilerPlugins"
:
[
"sass"
"sass"
],
],
"ignoreDevUnusedFiles"
:
false
,
"ignoreDevUnusedFiles"
:
false
,
"ignoreUploadUnusedFiles"
:
false
,
"ignoreUploadUnusedFiles"
:
false
,
"compileWorklet"
:
false
,
"compileWorklet"
:
false
,
"uglifyFileName"
:
false
,
"uglifyFileName"
:
false
,
"uploadWithSourceMap"
:
true
,
"uploadWithSourceMap"
:
true
,
"minifyWXSS"
:
true
,
"minifyWXSS"
:
true
,
"minifyWXML"
:
true
,
"minifyWXML"
:
true
,
"localPlugins"
:
false
,
"localPlugins"
:
false
,
"disableUseStrict"
:
false
,
"disableUseStrict"
:
false
,
"condition"
:
false
,
"condition"
:
false
,
"swc"
:
false
,
"swc"
:
false
,
"disableSWC"
:
true
"disableSWC"
:
true
},
},
"editorSetting"
:
{
"editorSetting"
:
{
"tabIndent"
:
"insertSpaces"
,
"tabIndent"
:
"insertSpaces"
,
"tabSize"
:
2
"tabSize"
:
2
},
},
"simulatorPluginLibVersion"
:
{}
"simulatorPluginLibVersion"
:
{}
}
}
\ No newline at end of file
\ No newline at end of file
router/router.js
View file @
19c9304
...
@@ -118,10 +118,10 @@ class Router {
...
@@ -118,10 +118,10 @@ class Router {
name
=
_name
.
split
(
"?"
)[
0
];
name
=
_name
.
split
(
"?"
)[
0
];
parent
=
_parent
;
parent
=
_parent
;
}
}
console
.
log
(
"this[_routerList]"
,
this
[
_routerList
]);
//
console.log("this[_routerList]", this[_routerList]);
const
routerMapItem
=
this
[
_routerList
].
find
((
item
)
=>
item
.
parent
===
parent
&&
item
.
name
===
name
);
const
routerMapItem
=
this
[
_routerList
].
find
((
item
)
=>
item
.
parent
===
parent
&&
item
.
name
===
name
);
// console.log(this[_routerList])
// console.log(this[_routerList])
console
.
log
(
routerMapItem
);
//
console.log(routerMapItem);
if
(
!
routerMapItem
)
{
if
(
!
routerMapItem
)
{
console
.
error
(
"找不到路由"
);
console
.
error
(
"找不到路由"
);
return
;
return
;
...
...
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