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 2e627bbc
authored
Oct 20, 2022
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'develop' of 192.168.3.233:saas_plus/business-assistant into develop
2 parents
49bd912f
5531dbdd
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
82 additions
and
38 deletions
api/usersApi/UsersApi.js
components/SceneBox/SceneBox.wxss
login/index/components/Box/Box.js
packageOutput/pages/openBusiness/openBusiness.js
packageOutput/pages/openBusiness/openBusiness.wxml
packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.js
packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.scss
packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.wxml
packageOutput/pages/summary/summary.js
router/router.js
api/usersApi/UsersApi.js
View file @
2e627bb
...
...
@@ -143,6 +143,7 @@ class UsersApi {
/**获取微信用户信息 */
async
getWXUserInfo
()
{
let
wx_user_info
=
wx
.
$storage
.
get
(
'wx_user_info'
)
console
.
log
(
wx_user_info
)
if
(
!
wx_user_info
)
{
const
data
=
await
this
.
getUserProfile
()
wx
.
$storage
.
set
(
'wx_user_info'
,
data
)
...
...
components/SceneBox/SceneBox.wxss
View file @
2e627bb
...
...
@@ -60,8 +60,20 @@
background-image: linear-gradient(145deg, #F0F7FF 0%, #FFFFFF 73%);
border: 2rpx solid #3666FE;
box-shadow: 0 4rpx 8rpx 0 rgba(180, 186, 204, 0.32), 0 8rpx 20rpx 0 rgba(180, 186, 204, 0.40);
/* background: url('https://img02.glsx.com.cn/weapp/resource/saas/business-assistant/output/carselect.png') no-repeat;
background-size: 100% 100%; */
}
.active::after {
position: absolute;
left: 50%;
bottom: -7px;
display: block;
content: "";
width: 6px;
height: 6px;
border-bottom: 1px solid var(--btnColor);
border-right: 1px solid var(--btnColor);
transform: rotate(45deg) translateX(-50%);
background-color: #fff;
}
/* 选中 - end */
...
...
login/index/components/Box/Box.js
View file @
2e627bb
...
...
@@ -273,9 +273,6 @@ Component({
disabled
:
false
})
this
.
loginToken
=
data
USERAPI
.
getUserProfile
(
data
).
then
(
data
=>
{
wx
.
$storage
.
set
(
'wx_user_info'
,
data
)
})
}
else
this
.
reLogin
(
message
)
wx
.
hideLoading
()
}
catch
({
...
...
packageOutput/pages/openBusiness/openBusiness.js
View file @
2e627bb
...
...
@@ -37,7 +37,7 @@ Page({
var
proList
=
res
.
find
(
item
=>
item
.
sceneCode
==
sceneCode
)
console
.
log
(
proList
,
'??????'
)
this
.
setData
({
[
'sceneActivityObj.scene'
+
this
.
data
.
sceneActive
]:
proList
.
productList
.
filter
(
item
=>
!
item
.
openFlag
)
[
'sceneActivityObj.scene'
+
this
.
data
.
sceneActive
]:
proList
.
productList
.
filter
(
item
=>
item
.
openFlag
==
0
)
})
this
.
setCurActivity
()
})
...
...
packageOutput/pages/openBusiness/openBusiness.wxml
View file @
2e627bb
...
...
@@ -4,7 +4,7 @@
<view class="layout">
<view class="form m-b-32">
<text class="label">开通门店:</text>
<text>
嘀加鹏辉奥迪4S店
</text>
<text>
{{merchantInfo.merchantName}}
</text>
</view>
<view class="head m-b-32">开通门店产品/活动</view>
<!-- 场景活动 -->
...
...
@@ -15,7 +15,7 @@
<!-- 活动 -->
<view class="box">
<view class="box-title">产品/活动<text class="title-tip">(可多选)</text></view>
<view class="activity-box">
<view class="activity-box"
wx:if="{{sceneActive != 1}}"
>
<view class="activity-item text-hide {{ item.checked ? 'active' : '' }}" wx:for="{{activityList}}" wx:key="index" bindtap="handleActClick" data-idx="{{index}}">{{item.productName}}</view>
</view>
</view>
...
...
packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.js
View file @
2e627bb
...
...
@@ -67,7 +67,7 @@ Component({
lifetimes
:
{
attached
()
{
console
.
log
(
this
.
data
.
orderObj
,
'///////////'
)
this
.
dealStaffList
(
)
},
},
...
...
@@ -75,6 +75,25 @@ Component({
* 组件的方法列表
*/
methods
:
{
dealStaffList
()
{
var
list
=
this
.
data
.
orderObj
list
.
activityList
.
forEach
(
item
=>
{
item
.
showStaffList
=
item
.
staffList
.
length
>
10
?
item
.
staffList
.
slice
(
0
,
10
)
:
item
.
staffList
item
.
staffList
=
item
.
staffList
.
length
>
10
?
item
.
staffList
.
slice
(
10
)
:
[]
})
this
.
setData
({
orderObj
:
list
})
},
handleMore
(
e
)
{
var
{
idx
}
=
e
.
currentTarget
.
dataset
var
list
=
this
.
data
.
orderObj
var
item
=
list
.
activityList
[
idx
]
list
.
activityList
[
idx
].
showStaffList
=
list
.
activityList
[
idx
].
showStaffList
.
concat
(
item
.
staffList
.
length
>
10
?
item
.
staffList
.
slice
(
0
,
10
)
:
item
.
staffList
)
list
.
activityList
[
idx
].
staffList
=
item
.
staffList
.
length
>
10
?
item
.
staffList
.
slice
(
10
)
:
[]
this
.
setData
({
orderObj
:
list
})
}
}
})
packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.scss
View file @
2e627bb
...
...
@@ -129,6 +129,16 @@
width
:
calc
((
100%
-
116rpx
)
/
4
);
}
}
.btn-more
{
height
:
56rpx
;
line-height
:
56rpx
;
color
:
#5A6066
;
border
:
2rpx
solid
#EEEEEE
;
border-radius
:
28rpx
;
text-align
:
center
;
margin
:
0
20rpx
16rpx
;
}
}
}
...
...
packageOutput/pages/summary/components/outputCrowdfund/outputCrowdfund.wxml
View file @
2e627bb
...
...
@@ -34,8 +34,8 @@
<view class="tr">
<view class="th" style="width: {{subItem.width || ''}};" wx:for="{{tableHeadList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">{{subItem.label}}</view>
</view>
<view wx:if="{{item.staffList.length}}">
<block wx:for="{{item.staffList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
<view wx:if="{{item.s
howS
taffList.length}}">
<block wx:for="{{item.s
howS
taffList}}" wx:for-item="subItem" wx:for-index="idx" wx:key="idx">
<view class="tr">
<view class="td" style="width: {{i.width || ''}};" wx:for="{{tableHeadList}}" wx:for-item="i" wx:for-index="j" wx:key="j">
<text wx:if="{{i.prefix}}">{{i.prefix}}</text>
...
...
@@ -43,6 +43,7 @@
</view>
</view>
</block>
<view wx:if="{{item.staffList.length}}" class="btn-more" bindtap="handleMore" data-idx="{{index}}">查看更多</view>
</view>
<view class="tr" wx:else>
<view>暂无数据</view>
...
...
packageOutput/pages/summary/summary.js
View file @
2e627bb
...
...
@@ -118,7 +118,7 @@ Page({
outputApi
.
getSceneProStatus
(
params
).
then
(
res
=>
{
var
proList
=
res
.
find
(
item
=>
item
.
sceneCode
==
sceneCode
)
// 删----
proList
.
productList
[
1
].
productStatus
=
2
//
proList.productList[1].productStatus = 2
this
.
setData
({
[
'sceneActivityObj.scene'
+
this
.
data
.
sceneActive
]:
proList
.
productList
})
...
...
@@ -220,8 +220,8 @@ Page({
getActivityRevenue
()
{
var
params
=
this
.
dealSearchStatus
()
outputApi
.
getActivityRevenue
({
merchantId
:
this
.
data
.
merchantInfo
.
merchantId
,
...
params
}).
then
(
res
=>
{
console
.
log
(
res
)
console
.
log
(
this
.
data
.
sceneActivityObj
,
'++++++'
)
//
console.log(res)
//
console.log(this.data.sceneActivityObj, '++++++')
var
actList
=
this
.
data
.
sceneActivityObj
[
'scene'
+
this
.
data
.
sceneActive
]
actList
.
forEach
((
item
,
idx
)
=>
{
var
curItem
=
res
.
find
(
k
=>
k
.
goodsCategoryCode
==
item
.
productCode
)
...
...
@@ -229,8 +229,9 @@ Page({
console
.
log
(
curItem
)
curItem
.
totalNum
=
curItem
.
activityList
.
length
curItem
.
activityList
.
forEach
(
k
=>
{
// 时间
k
.
time
=
k
.
startTime
.
slice
(
5
).
replace
(
/-/g
,
'/'
)
+
'~'
+
k
.
endTime
.
slice
(
5
).
replace
(
/-/g
,
'/'
)
// 0-未开始;1-
开始
中;2-已结束
// 0-未开始;1-
活动
中;2-已结束
if
(
new
Date
(
k
.
startTime
)
>
new
Date
())
{
k
.
actStatus
=
0
k
.
interDays
=
parseInt
((
new
Date
().
getTime
(
k
.
startTime
)
-
new
Date
().
getTime
())
/
(
1000
*
60
*
60
*
24
))
+
1
...
...
@@ -244,21 +245,23 @@ Page({
}
k
.
suggestTxtList
=
[]
k
.
suggestList
=
[]
if
(
k
.
visitCount
<
200
)
{
if
((
k
.
actStatus
==
2
&&
k
.
interDays
<
8
)
||
k
.
actStatus
!=
2
)
{
k
.
suggestTxtList
.
push
(
'距离活动结束剩余'
+
k
.
toEndDays
+
'天'
)
if
(
k
.
actStatus
==
1
)
{
if
(
k
.
visitCount
<
200
)
{
if
((
k
.
actStatus
==
2
&&
k
.
interDays
<
8
)
||
k
.
actStatus
!=
2
)
{
k
.
suggestTxtList
.
push
(
'距离活动结束剩余'
+
k
.
toEndDays
+
'天'
)
}
k
.
suggestList
.
push
(
'触达车主的数量太少,建议与4S店关键人沟通下注册员工的转发执行情况'
)
}
k
.
suggestList
.
push
(
'触达车主的数量太少,建议与4S店关键人沟通下注册员工的转发执行情况'
)
}
if
(
k
.
shareRate
<
0.4
)
{
k
.
suggestTxtList
.
push
(
'分享员工占比低于40%'
)
k
.
suggestList
.
push
(
'建议与4S店关键人沟通下注册员工的转发执行情况'
)
}
if
(
k
.
conversionRate
<
0.05
)
{
k
.
suggestTxtList
.
push
(
'点击转化率低于5%'
)
k
.
suggest
List
.
push
(
'建议调整该产品的品类话术和营销内容'
)
if
(
k
.
shareRate
<
0.4
)
{
k
.
suggestTxtList
.
push
(
'分享员工占比低于40%'
)
k
.
suggestList
.
push
(
'建议与4S店关键人沟通下注册员工的转发执行情况'
)
}
if
(
k
.
conversionRate
<
0.05
)
{
k
.
suggestTxtList
.
push
(
'点击转化率低于5%'
)
k
.
suggestList
.
push
(
'建议调整该产品的品类话术和营销内容'
)
}
k
.
suggest
Txt
=
k
.
suggestTxtList
.
join
(
','
)
+
'。'
}
k
.
suggestTxt
=
k
.
suggestTxtList
.
join
(
','
)
+
'。'
})
actList
[
idx
].
outputData
=
curItem
}
...
...
@@ -275,14 +278,15 @@ Page({
*/
onLoad
(
options
)
{
this
.
setData
({
merchantInfo
:
{
pMerchantId
:
44209845
,
merchantId
:
44209390
,
merchantName
:
'????'
},
sceneCodeList
:
[
'SC001'
,
'SC002'
,
'SC003'
,
'SC004'
]
})
// 删----
// this.setData({
// merchantInfo: {
// pMerchantId: 44209845,
// merchantId: 44209390,
// merchantName: '????'
// },
// sceneCodeList: ['SC001', 'SC002', 'SC003', 'SC004']
// })
this
.
getSceneProStatus
(
this
.
data
.
sceneCodeList
[
this
.
data
.
sceneActive
-
1
])
wx
.
$router
.
getData
(
obj
=>
{
...
...
router/router.js
View file @
2e627bb
...
...
@@ -16,7 +16,7 @@ class Router {
wx
.
onAppRoute
(
async
e
=>
{
let
thisPage
=
this
.
getPageInstance
()
if
(
thisPage
)
{
await
USERAPI
.
getWXUserInfo
()
if
(
!
thisPage
.
route
.
includes
(
'login'
))
await
USERAPI
.
getWXUserInfo
()
thisPage
.
setData
({
IMG_URL
})
if
(
Object
.
keys
(
this
[
_query
]).
length
)
thisPage
.
options
=
this
[
_query
]
this
.
setNavigationBarTitleText
(
thisPage
)
...
...
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