Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-boutique-work-wechat
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
1
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 51d8e590
authored
Sep 19, 2023
by
zhangxw
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
联调修改
1 parent
3ad4e24a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
34 changed files
with
379 additions
and
347 deletions
components/SideSelectPopup/SideSelectPopup.js
components/SideSelectPopup/SideSelectPopup.wxml
components/SideSelectPopup/SideSelectPopup.wxss
components/TabMine/TabMine.js
components/TabMine/TabMine.wxml
components/TabMine/TabMine.wxss
packageCrowdFunding/pages/TabBar/crowdFundingPage.js
packageCrowdFunding/pages/activityPage/activityPay/activityPay.wxml
packageCrowdFunding/pages/activityPage/components/activityInfoCom/activityInfoCom.wxml
packageEquity/pages/TabBar/equityPage.js
pages/accountItems/accountItems.js
pages/accountItems/accountItems.wxml
pages/changeScene/changeScene.js
pages/changeScene/changeScene.wxml
pages/loading/loading.js
pages/merchantList/merchantList.js
pages/merchantList/merchantList.wxml
pages/sceneIndex/sceneIndex.js
pages/sceneIndex/sceneIndex.wxml
pages/wxLogin/wxLogin.js
store/index.js
subvehicleConversion/api.js
subvehicleConversion/pages/TabBar/conversionPage.js
subvehicleConversion/pages/indexPage/index.js
subvehicleConversion/pages/indexPage/index.wxml
subvehicleConversion/pages/orderPage/supplementaryOrderList/supplementaryOrderList.wxss
tabDate/pages/index/index.js
tabIndex/pages/index/index.js
tabIndex/pages/index/index.sass
tabIndex/pages/index/index.wxml
tabMine/pages/index/index.js
tabMine/pages/index/index.wxml
tabMine/pages/index/index.wxss
utils/request/environment.js
components/SideSelectPopup/SideSelectPopup.js
View file @
51d8e59
// components/SideSelectPopup/SideSelectPopup.js
import
constantData
from
'../../pages/constant/data'
import
api
from
'~/api/api'
const
IMG_URL
=
'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat'
Component
({
...
...
@@ -17,6 +16,7 @@ Component({
let
{
storeList
,
subIndex
}
=
this
.
data
storeList
?.
map
((
val
,
index
)
=>
{
val
.
actived
=
false
val
.
index
=
index
if
(
userInfo
?.
sceneType
==
1
)
{
// 切换园区店
if
(
userInfo
?.
isSuper
&&
index
==
subIndex
)
val
.
actived
=
true
...
...
@@ -28,17 +28,11 @@ Component({
})
this
.
setData
({
userInfo
,
storeList
copyStoreList
:
storeList
,
searchValue
:
''
,
edit
:
false
,
showSearchInput
:
false
})
// let storagesceneType = userInfo.sceneType
// this.setData({storagesceneType})
// let { sceneList } = this.data
// let openSceneArr = userInfo?.openSceneArr || []
// // 获取开通业务场景
// let arr = sceneList.filter(v => openSceneArr.includes(v.sceneType))
// this.setData({
// sceneList: arr
// })
}
}
},
...
...
@@ -62,7 +56,12 @@ Component({
data
:
{
storagesceneType
:
''
,
IMG_URL
,
userInfo
:
{}
userInfo
:
{},
showSearchInput
:
false
,
inputFocus
:
false
,
searchValue
:
''
,
copyStoreList
:
[],
selectedMerchantId
:
''
},
/**
...
...
@@ -74,6 +73,80 @@ Component({
show
:
false
})
},
open
()
{
if
(
this
.
data
.
disabled
)
return
this
.
setData
({
edit
:
true
,
inputFocus
:
true
})
},
setValue
(
value
)
{
if
(
this
.
properties
.
filterEmoji
)
{
if
(
wx
.
$util
.
haveEmoji
(
value
))
value
=
wx
.
$util
.
replaceEmoji
(
value
)
}
this
.
setData
({
searchValue
:
value
})
},
input
(
e
)
{
let
{
value
}
=
e
.
detail
this
.
setValue
(
value
)
this
.
triggerEvent
(
'input'
,
{
value
})
},
inputConfifm
(
e
)
{
this
.
emit
(
e
)
},
emit
(
e
)
{
let
{
detail
:
{
value
},
type
}
=
e
this
.
setData
({
edit
:
false
})
this
.
setValue
(
value
)
this
.
searchEvent
()
},
clearInputText
()
{
this
.
setData
({
searchValue
:
''
,
edit
:
false
})
this
.
searchEvent
()
},
showSearch
()
{
this
.
setData
({
showSearchInput
:
!
this
.
data
.
showSearchInput
})
},
searchEvent
()
{
let
{
searchValue
,
selectedMerchantId
}
=
this
.
data
let
{
storeList
}
=
wx
.
$util
.
deepClone
(
this
.
data
)
if
(
!
searchValue
)
{
storeList
.
map
(
i
=>
{
i
.
active
=
false
if
(
i
.
merchantId
==
selectedMerchantId
)
i
.
active
=
true
return
i
})
this
.
setData
({
copyStoreList
:
storeList
})
}
else
{
let
arr
=
[]
storeList
.
map
(
i
=>
{
i
.
active
=
false
if
(
i
.
merchantId
==
selectedMerchantId
)
i
.
active
=
true
if
(
i
.
merchantName
.
indexOf
(
searchValue
)
!=
-
1
||
i
.
merchantId
==
searchValue
)
{
arr
.
push
(
i
)
}
})
this
.
setData
({
copyStoreList
:
arr
})
}
},
showTabBar
()
{
if
(
this
.
data
.
hasTabBar
)
wx
.
showTabBar
({
animation
:
true
})
},
...
...
@@ -82,12 +155,12 @@ Component({
},
selectStore
(
e
)
{
const
thisPage
=
wx
.
$router
.
getPageInstance
()
let
{
item
,
selectindex
}
=
e
.
currentTarget
.
dataset
let
{
item
}
=
e
.
currentTarget
.
dataset
let
{
userInfo
,
storeList
,
subIndex
}
=
this
.
data
// 精品升级场景
if
(
userInfo
?.
sceneType
==
1
)
{
// 超管切换园区店
if
(
userInfo
?.
isSuper
&&
select
index
==
subIndex
)
this
.
closeMenu
()
if
(
userInfo
?.
isSuper
&&
item
.
index
==
subIndex
)
this
.
closeMenu
()
else
if
(
!
userInfo
?.
isSuper
&&
item
?.
merchantId
==
userInfo
?.
shopMerchantId
)
return
this
.
closeMenu
()
}
else
{
// 其它场景
if
(
item
?.
merchantId
==
userInfo
?.
shopMerchantId
)
return
this
.
closeMenu
()
...
...
@@ -96,12 +169,13 @@ Component({
val
.
actived
=
false
if
(
userInfo
?.
sceneType
==
1
)
{
// 切换园区店
if
(
userInfo
?.
isSuper
&&
select
index
==
index
)
val
.
actived
=
true
if
(
userInfo
?.
isSuper
&&
item
.
index
==
index
)
val
.
actived
=
true
else
if
(
!
userInfo
?.
isSuper
&&
val
.
merchantId
==
userInfo
?.
shopMerchantId
)
val
.
actived
=
true
}
else
{
// 切换4s店
if
(
val
.
merchantId
==
userInfo
?.
shopMerchantId
)
val
.
actived
=
true
}
if
(
val
.
actived
)
this
.
setData
({
selectedMerchantId
:
val
.
merchantId
})
return
val
})
this
.
setData
({
...
...
@@ -110,7 +184,7 @@ Component({
// 精品升级场景 超管切换
if
(
userInfo
?.
isSuper
&&
userInfo
?.
sceneType
==
1
)
{
this
.
closeMenu
()
thisPage
.
changePicker
&&
thisPage
.
changePicker
(
storeList
[
selectindex
],
select
index
)
thisPage
.
changePicker
&&
thisPage
.
changePicker
(
storeList
[
item
.
index
],
item
.
index
)
return
}
// 切换4s店
...
...
components/SideSelectPopup/SideSelectPopup.wxml
View file @
51d8e59
<!--components/SideSelectPopup/SideSelectPopup.wxml-->
<van-popup custom-style="height: 100%;width:
70%
;" z-index="999999" custom-class="popclass" bind:click-overlay="closeMenu" position="left" bind:before-enter="hideTabBar" bind:after-leave="showTabBar" show="{{ show }}">
<van-popup custom-style="height: 100%;width:
560rpx
;" z-index="999999" custom-class="popclass" bind:click-overlay="closeMenu" position="left" bind:before-enter="hideTabBar" bind:after-leave="showTabBar" show="{{ show }}">
<view class="wrapper">
<view class="title">店面列表</view>
<view class="title_box">
<view class="title" wx:if="{{!showSearchInput}}">店面列表</view>
<view class="search_box">
<image wx:if="{{!showSearchInput}}" src="/images/search.png" bindtap="showSearch" mode=""/>
<view wx:else>
<view class="search-input">
<block wx:if="{{ !edit }}">
<view class="input {{ searchValue?'':'placeholder' }}" bindtap="open">
<block wx:if="{{ searchValue }}">{{searchValue}}</block>
<block wx:else>
<image src="/images/search.png" class="icon"></image>
{{'请输入门店名称/商户号搜索'}}
</block>
</view>
</block>
<block wx:else>
<view class="input_box">
<input
type="text"
class="input"
value="{{ searchValue }}"
focus="{{ inputFocus }}"
confirm-type="search"
bindinput="input"
bindblur="inputBlur"
bindconfirm="inputConfifm"
/>
<image src="/images/clear.png" bindtap="clearInputText" mode=""/>
</view>
</block>
</view>
</view>
</view>
</view>
<scroll-view scroll-y style="height: calc(100vh - 264rpx);" enhanced="{{true}}" show-scrollbar="{{false}}">
<block wx:for="{{
s
toreList}}" wx:key="index" wx:for-index="index">
<view catch:tap="selectStore" data-item="{{item}}"
data-selectindex="{{index}}"
class="element {{item.actived ? 'active' : ''}}">
<block wx:for="{{
copyS
toreList}}" wx:key="index" wx:for-index="index">
<view catch:tap="selectStore" data-item="{{item}}" class="element {{item.actived ? 'active' : ''}}">
<view><image src="{{IMG_URL}}/store_icon_nobg.png"></image></view>
<view class="text_box">
<view class="label">{{item.merchantName}}</view>
...
...
components/SideSelectPopup/SideSelectPopup.wxss
View file @
51d8e59
...
...
@@ -6,14 +6,60 @@
box-sizing: border-box;
padding: 88rpx 16rpx;
}
.wrapper .title{
height: 88rpx;
line-height: 88rpx;
.wrapper .title_box{
height: 60rpx;
line-height: 60rpx;
margin-bottom: 20rpx;
display: flex;
align-items: center;
justify-content: space-between;
}
.wrapper .title_box .title{
padding-left: 16rpx;
font-weight: 600;
font-size: 28rpx;
color: #FFFFFF80;
}
.wrapper .title_box .search_box{
display: flex;
align-items: center;
font-size: 28rpx;
}
.wrapper .title_box .search_box image{
width: 32rpx;
height: 32rpx;
}
.wrapper .title_box .search_box .search-input {
width: 528rpx;
height: 60rpx;
background: #FFFFFF;
border-radius: 38px;
padding: 0 16rpx;
box-sizing: border-box;
}
.wrapper .title_box .search_box .search-input .input{
display: flex;
align-items: center;
height: 100%;
}
.wrapper .title_box .search_box .search-input .input_box{
height: 100%;
display: flex;
align-items: center;
justify-content: space-between;
}
.wrapper .title_box .search_box .search-input .placeholder{
color: #C8C9CC;
}
.wrapper .element{
position: relative;
padding: 32rpx 0;
...
...
components/TabMine/TabMine.js
View file @
51d8e59
...
...
@@ -2,6 +2,7 @@
import
api
from
'../../tabMine/api'
const
app
=
getApp
()
import
constantData
from
'../../pages/constant/data'
const
IMG_URL
=
'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/mine/'
Component
({
/**
* 组件的属性列表
...
...
@@ -17,6 +18,7 @@ Component({
* 组件的初始数据
*/
data
:
{
IMG_URL
,
isYqdSuper
:
''
,
selectedSceneName
:
''
,
userInfo
:
{}
...
...
components/TabMine/TabMine.wxml
View file @
51d8e59
...
...
@@ -59,10 +59,12 @@
<view class="set_item item_3" bindtap="changeScene">
<view class="title">场景切换<image class="arrow_icon" src="/tabMine/images/arrow_icon.png" mode=""/></view>
<view class="set_tips">{{selectedSceneName}}</view>
<image class="icon_image" src="{{IMG_URL}}mine_icon_3.png" mode=""/>
</view>
<view class="set_item item_4" bindtap="goVersionPage">
<view class="title">更新日志<image class="arrow_icon" src="/tabMine/images/arrow_icon.png" mode=""/></view>
<view class="set_tips">最新{{versionData.version}}版</view>
<image class="icon_image" src="{{IMG_URL}}mine_icon_1.png" mode=""/>
</view>
</view>
<!-- <view class="version_box" bindtap="goVersionPage">
...
...
components/TabMine/TabMine.wxss
View file @
51d8e59
...
...
@@ -42,6 +42,10 @@
font-size: 40rpx;
color: #323436;
font-weight: 600;
max-width: 400rpx;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.change_btn{
width: 134rpx;
...
...
@@ -152,6 +156,15 @@
justify-content: center;
padding: 32rpx;
margin-bottom: 20rpx;
position: relative;
}
.set_box .set_item .icon_image{
width: 120rpx;
height: 120rpx;
position: absolute;
right: 0;
bottom: 0;
}
.set_box .set_item .title .arrow_icon{
...
...
packageCrowdFunding/pages/TabBar/crowdFundingPage.js
View file @
51d8e59
...
...
@@ -48,7 +48,8 @@ Page({
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
params
=
{
merchantId
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
merchantId
,
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
,
scene
:
3
}
get4SStoreList
(
params
).
then
(
result
=>
{
this
.
setData
({
...
...
packageCrowdFunding/pages/activityPage/activityPay/activityPay.wxml
View file @
51d8e59
<!-- packageCrowdFunding/pages/balanceNote/balanceNote.wxml -->
<wxs src="../balanceNote/index.wxs" module="filter" />
<wxs src="
../..
/index.wxs" module="filter2" />
<wxs src="
/packageCrowdFunding
/index.wxs" module="filter2" />
<glsx-privacy appletName="生意助手员工版" bind:agreeClick="agreeClick" bind:disagreeClick="disagreeClick"></glsx-privacy>
<view class="big-img page-box isFullSucreen">
<view class="titleBox">
...
...
packageCrowdFunding/pages/activityPage/components/activityInfoCom/activityInfoCom.wxml
View file @
51d8e59
<wxs src="
../..
/index.wxs" module="filter" />
<wxs src="
/packageCrowdFunding
/index.wxs" module="filter" />
<view class="orderInfoCom">
<view class="title">订单信息</view>
<view class="info">
...
...
packageEquity/pages/TabBar/equityPage.js
View file @
51d8e59
...
...
@@ -133,7 +133,8 @@ Page({
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
params
=
{
merchantId
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
merchantId
,
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
,
scene
:
0
}
get4SStoreList
(
params
).
then
(
result
=>
{
this
.
setData
({
...
...
pages/accountItems/accountItems.js
View file @
51d8e59
...
...
@@ -2,7 +2,7 @@
import
api
from
'~/api/api'
const
app
=
getApp
()
import
{
getYQorderInfo
,
get4SStoreList
}
from
'~/store/index'
import
constantData
from
'../constant/data
'
import
{
getShopSceneConfig
}
from
'~/store/index
'
Page
({
/**
* 页面的初始数据
...
...
@@ -25,13 +25,17 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
console
.
log
(
options
)
// let { noLogin } = options
let
id
=
decodeURIComponent
(
options
.
scene
).
split
(
'='
)[
1
]
// noLogin
// console.log(id)
id
?
this
.
qrCodeScene
(
id
)
:
this
.
getListSelectAccount
()
// this.getListSelectAccount()
},
getSceneArr
(
yqMerchantId
,
loginUserObj
)
{
// 超管开通全部场景
if
(
loginUserObj
?.
isSuper
)
return
// 获取4s店关联场景数据
getShopSceneConfig
({
yqMerchantId
}).
then
(
result
=>
{
if
(
!
result
?.
length
)
return
wx
.
$util
.
showToast
(
'暂无开通业务,请联系总部管理员'
)
this
.
get4SStoreList
(
loginUserObj
)
})
},
open
()
{
this
.
setData
({
...
...
@@ -43,7 +47,6 @@ Page({
if
(
this
.
properties
.
filterEmoji
)
{
if
(
wx
.
$util
.
haveEmoji
(
value
))
value
=
wx
.
$util
.
replaceEmoji
(
value
)
}
console
.
log
(
value
)
this
.
setData
({
searchValue
:
value
})
...
...
@@ -101,7 +104,6 @@ Page({
.
then
(
res
=>
{
// debugger
// res => {
console
.
log
(
res
)
let
{
code
,
data
}
=
res
let
op
=
{}
if
(
code
==
'0'
)
{
...
...
@@ -118,7 +120,6 @@ Page({
this
.
noLoginFn
()
}
)
console
.
log
(
op
)
}
}
// }
...
...
@@ -178,7 +179,6 @@ Page({
wx
.
$util
.
showLoading
(
'加载中...'
)
api
.
getListSelectAccount
().
then
(
res
=>
{
wx
.
hideLoading
()
// console.log(res)
let
{
code
,
data
,
message
}
=
res
if
(
code
==
0
)
{
let
{
loginUserInfoList
,
sessionId
}
=
data
...
...
@@ -196,7 +196,7 @@ Page({
})
},
chooseAccount
(
e
)
{
let
{
i
ndex
,
i
tem
}
=
e
.
currentTarget
.
dataset
let
{
item
}
=
e
.
currentTarget
.
dataset
let
{
loginUserInfoList
}
=
this
.
data
loginUserInfoList
.
map
(
i
=>
{
i
.
active
=
false
...
...
@@ -215,13 +215,9 @@ Page({
sceneHandle
()
{
const
SCENE
=
wx
.
$SCENE
let
{
path
,
query
}
=
SCENE
console
.
log
(
path
,
'path'
)
let
{
target
,
name
}
=
wx
.
$util
.
getSceneId
(
path
)
// console.log(query)
// console.log(target,name);
wx
.
$router
.
reLaunch
(
`
${
target
}
.
${
name
}
`
,
query
)
wx
.
$SCENE
=
null
// console.log(SCENE, 'SCENE')
// debugger 兼容扫码优惠券进来和免登录逻辑冲突问题
// if (SCENE && SCENE.path != 'pages/accountItems/accountItems') {
},
...
...
@@ -258,94 +254,48 @@ Page({
})
})
},
async
getYqMerchantSceneConfig
(
yqMerchantId
,
isSuper
,
result
,
loginInfo
)
{
// 先取消掉
// let checkAgree = await this.checkAgree()
// if (!checkAgree) return false
// 超管和督导默认开通所有场景
if
(
isSuper
)
{
// 0 会员权益/升级 1 精品升级
let
openSceneArr
=
constantData
.
sceneList
.
map
(
val
=>
{
return
val
?.
sceneType
})
let
{
merchantId
,
merchantName
}
=
result
[
0
]
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
openSceneArr
,
shopMerchantName
:
merchantName
,
shopMerchantId
:
merchantId
,
default4SStoreInfo
:
{
merchantId
:
merchantId
,
merchantName
:
merchantName
},
default4SStoreInfo_crowdFunding
:
{
merchantId
:
merchantId
,
merchantName
:
merchantName
},
default4SStoreInfo_newCarConversion
:
{
merchantId
:
merchantId
,
merchantName
:
merchantName
}
})
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
return
}
// 获取开通的业务场景
api
.
getYqMerchantSceneConfigAPI
({
yqMerchantId
:
yqMerchantId
}).
then
(
res
=>
{
let
{
data
,
message
,
code
}
=
res
if
(
code
==
0
)
{
let
openSceneArr
=
[]
data
?.
forEach
(
v
=>
{
if
(
v
.
sceneOpenFlag
===
0
)
openSceneArr
.
push
(
v
.
scene
)
})
if
(
!
openSceneArr
.
length
)
{
wx
.
$util
.
showToast
(
'暂无开通业务,请联系总部管理员'
)
}
else
{
if
(
loginInfo
?.
shopMerchantId
&&
!
((
loginInfo
?.
sceneType
??
''
)
===
''
))
{
// 记录上次登录选择的4s店和场景
let
{
shopMerchantId
,
shopMerchantName
,
sceneType
}
=
loginInfo
this
.
jumpPage
(
openSceneArr
,
{
merchantId
:
shopMerchantId
,
merchantName
:
shopMerchantName
,
sceneType
})
}
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
openSceneArr
})
if
(
result
?.
length
==
1
)
this
.
jumpPage
(
openSceneArr
,
result
[
0
])
else
wx
.
$router
.
reLaunch
(
'pages.merchantList'
)
}
// 获取园区店下4s店数据
get4SStoreList
(
loginUserObj
)
{
let
{
merchantId
,
isSuper
,
uuid
}
=
loginUserObj
get4SStoreList
({
merchantId
:
isSuper
?
undefined
:
merchantId
,
staffUUID
:
uuid
}).
then
(
result
=>
{
// 超管/仅一家4s店
let
obj
=
(
result
&&
result
[
0
])
||
{}
// 超管跳过选择4s店页面
if
(
isSuper
)
{
this
.
setShopMerchantObj
(
obj
)
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
return
}
// 仅一家4s店
if
(
result
?.
length
==
1
)
{
this
.
setShopMerchantObj
(
obj
)
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
}
else
{
wx
.
$
util
.
showToast
(
message
)
wx
.
$
router
.
reLaunch
(
'pages.merchantList'
)
}
})
},
// 仅一家4s店
jumpPage
(
openSceneArr
,
merchantSceneItem
)
{
// 存储4s店信息
let
{
merchantId
,
merchantName
,
sceneType
}
=
merchantSceneItem
setShopMerchantObj
(
data
)
{
let
{
merchantName
:
shopMerchantName
,
merchantId
:
shopMerchantId
}
=
data
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
shopMerchantName
:
m
erchantName
,
shopMerchantId
:
m
erchantId
,
sceneType
:
sceneType
||
''
,
shopMerchantName
:
shopM
erchantName
,
shopMerchantId
:
shopM
erchantId
,
sceneType
:
sceneType
,
default4SStoreInfo
:
{
merchantId
:
m
erchantId
,
merchantName
:
m
erchantName
merchantId
:
shopM
erchantId
,
merchantName
:
shopM
erchantName
},
default4SStoreInfo_crowdFunding
:
{
merchantId
:
m
erchantId
,
merchantName
:
m
erchantName
merchantId
:
shopM
erchantId
,
merchantName
:
shopM
erchantName
},
default4SStoreInfo_newCarConversion
:
{
merchantId
:
m
erchantId
,
merchantName
:
m
erchantName
merchantId
:
shopM
erchantId
,
merchantName
:
shopM
erchantName
}
})
// 记录到有选择场景直接进入对应场景
if
(
!
((
loginInfo
?.
sceneType
??
''
)
===
''
))
return
wx
.
$router
.
reLaunch
(
'pages.loading'
)
// 只开通一个场景直接跳转页面
if
(
openSceneArr
.
length
===
1
)
{
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
sceneType
:
openSceneArr
[
0
]
})
let
pageUrl
=
constantData
?.
pageUrl
wx
.
$router
.
reLaunch
(
pageUrl
[
openSceneArr
[
0
]])
}
else
if
(
openSceneArr
.
length
>
1
)
{
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
}
},
async
choiceAccountLogin
()
{
...
...
@@ -357,7 +307,6 @@ Page({
if
(
e
.
active
)
{
yqMerchantId
=
e
.
merchantId
id
=
e
.
uuid
// 超管 和 督导都认为开通所有场景
isSuper
=
e
.
isSuper
||
e
.
loginRole
==
3
}
})
...
...
@@ -369,15 +318,10 @@ Page({
// 清空4s店数据
app
.
globalData
.
storeListRange
=
[]
wx
.
$util
.
showLoading
()
this
.
get4SStoreList
(
yqMerchantId
,
id
,
isSuper
)
},
get4SStoreList
(
yqMerchantId
,
id
,
isSuper
)
{
get4SStoreList
({
merchantId
:
isSuper
?
undefined
:
yqMerchantId
,
staffUUID
:
id
}).
then
(
result
=>
{
this
.
selectAccountLogin
(
yqMerchantId
,
id
,
result
,
isSuper
)
})
this
.
selectAccountLogin
(
id
,
yqMerchantId
)
},
selectAccountLogin
(
yqMerchantId
,
id
,
result
,
isSuper
)
{
selectAccountLogin
(
id
,
yqMerchantId
)
{
api
.
selectAccountLogin
({
id
...
...
@@ -392,13 +336,16 @@ Page({
wx
.
$util
.
setUserInfo
(
data
.
loginUserInfoList
[
0
])
app
.
gobalCheckYqdSuper
(
data
.
loginUserInfoList
[
0
])
// checkYqdSuper(app, data.loginUserInfoList[0])
// console.log(data.loginUserInfoList[0])
getYQorderInfo
()
// 超管跳过选择4s店
if
(
data
.
loginUserInfoList
[
0
]
&&
data
.
loginUserInfoList
[
0
].
isSuper
)
{
this
.
get4SStoreList
(
data
.
loginUserInfoList
[
0
])
return
}
const
SCENE
=
wx
.
$SCENE
// debugger
// 有场景信息就跳转对应页面 没有就登录场景
SCENE
&&
SCENE
.
path
!=
'pages/accountItems/accountItems'
?
this
.
sceneHandle
()
:
this
.
get
YqMerchantSceneConfig
(
yqMerchantId
,
isSuper
,
result
,
data
.
loginUserInfoList
[
0
])
SCENE
&&
SCENE
.
path
!=
'pages/accountItems/accountItems'
?
this
.
sceneHandle
()
:
this
.
get
SceneArr
(
yqMerchantId
,
data
.
loginUserInfoList
[
0
])
}
else
{
wx
.
$util
.
showToast
(
message
)
}
...
...
pages/accountItems/accountItems.wxml
View file @
51d8e59
<!-- style="padding-bottom:{{isFullSucreen?'224rpx':'160rpx'}}" -->
<view class="layout">
<!-- <view class="title">请选择登录的账号</view> -->
<view class="search-box"
wx:if="{{copyLoginUserInfoList && copyLoginUserInfoList.length >= 10}}"
>
<view class="search-box">
<view class="search-input">
<block wx:if="{{!edit}}">
<view class="input {{searchValue?'':'placeholder'}}" bindtap="open">
...
...
pages/changeScene/changeScene.js
View file @
51d8e59
// pages/sceneIndex/sceneIndex.js
import
logOutAPI
from
'../../tabMine/api'
import
constantData
from
'../constant/data'
import
api
from
'~/api/api'
const
app
=
getApp
()
import
{
getShopSceneConfig
}
from
'~/store/index'
const
userInfo
=
wx
.
$util
.
getUserInfo
()
Page
({
/**
* 页面的初始数据
*/
data
:
{
timeState
:
''
,
sceneList
:
constantData
.
sceneList
,
isShow
:
false
,
userBoxHeight
:
0
openSceneArr
:
[]
},
// 选择场景
selectScene
(
e
)
{
let
{
scene
,
index
}
=
e
.
currentTarget
.
dataset
let
{
sceneList
}
=
this
.
data
const
userInfo
=
wx
.
$util
.
getUserInfo
()
let
{
sceneList
,
openSceneArr
}
=
this
.
data
if
(
!
openSceneArr
.
includes
(
scene
)
&&
!
userInfo
?.
isSuper
)
return
wx
.
$util
.
showToast
(
'暂未开通此场景'
)
sceneList
.
map
(
i
=>
(
i
.
actived
=
false
))
sceneList
[
index
].
actived
=
true
api
.
selectMerchantScene
({
...
...
@@ -46,59 +43,18 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad
(
options
)
{
let
{
sceneList
}
=
this
.
data
let
userInfo
=
wx
.
$util
.
getUserInfo
()
||
{}
let
openSceneArr
=
userInfo
?.
openSceneArr
||
[]
this
.
setData
({
timeState
:
wx
.
$util
.
getTimeState
()
})
wx
.
hideHomeButton
({
success
:
res
=>
{}
})
// 获取开通业务场景
let
arr
=
sceneList
.
filter
(
v
=>
openSceneArr
.
includes
(
v
.
sceneType
))
this
.
setData
({
isShow
:
Object
.
keys
(
userInfo
).
length
,
sceneList
:
arr
})
wx
.
$util
.
getViewInfo
(
'.user-box'
,
res
=>
{
this
.
setData
({
userBoxHeight
:
res
?.
height
})
},)
this
.
getSceneArr
()
},
// 切换账号
changeAccount
()
{
wx
.
$router
.
reLaunch
(
'pages.accountItems'
)
},
// 退出账号
logout
()
{
let
_this
=
this
wx
.
showModal
({
title
:
'温馨提示'
,
content
:
'是否退出当前账号?'
,
confirmColor
:
'#3582EE'
,
success
(
res
)
{
if
(
res
.
confirm
)
{
_this
.
setData
({
flag
:
true
})
_this
.
showLoading
()
logOutAPI
.
logout
().
then
(
_res_
=>
{
let
{
code
,
message
}
=
_res_
if
(
code
==
0
)
{
app
.
login
(
false
)
}
else
{
_this
.
setData
({
flag
:
false
})
_this
.
showToast
(
message
)
}
})
}
}
getSceneArr
()
{
// 超管默认开通全部场景
if
(
userInfo
?.
isSuper
)
return
// 获取4s店关联场景数据
getShopSceneConfig
({
yqMerchantId
:
userInfo
?.
subLoginUser
?.
merchantId
,
merchantId
:
userInfo
?.
shopMerchantId
}).
then
(
result
=>
{
this
.
setData
({
openSceneArr
:
result
.
map
(
val
=>
{
return
val
.
scene
})
||
[]})
})
},
...
...
@@ -113,15 +69,14 @@ Page({
onShow
()
{
let
{
sceneList
}
=
this
.
data
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
openSceneArr
=
userInfo
?.
openSceneArr
||
[]
openSceneArr
.
includes
(
userInfo
?.
sceneType
)
&&
sceneList
.
map
(
i
=>
{
i
.
actived
=
false
if
(
i
.
sceneType
==
userInfo
?.
sceneType
)
{
i
.
actived
=
true
}
return
i
})
sceneList
.
map
(
i
=>
{
i
.
actived
=
false
if
(
i
.
sceneType
==
userInfo
?.
sceneType
)
{
i
.
actived
=
true
}
return
i
})
console
.
log
(
sceneList
,
userInfo
)
this
.
setData
({
sceneList
})
},
...
...
pages/changeScene/changeScene.wxml
View file @
51d8e59
<!-- pages/sceneIndex/sceneIndex.wxml -->
<view class="layout"
wx:if="{{isShow}}"
>
<scroll-view class="scene-box" scroll-y style="height: calc(100vh - 140rpx - {{
userBoxHeight}}px - {{
isFullSucreen ? 34 : 0}}px - 60rpx);">
<view class="layout">
<scroll-view class="scene-box" scroll-y style="height: calc(100vh - 140rpx - {{isFullSucreen ? 34 : 0}}px - 60rpx);">
<block wx:for="{{sceneList}}" wx:key="index">
<view class="scene-item {{item.actived ? 'active' : ''}}" bindtap="selectScene" data-scene="{{item.sceneType}}" data-index="{{index}}">
<view class="left">
...
...
@@ -11,14 +11,10 @@
</view>
</view>
<view class="right">
<image wx:if='{{!item.actived}}' src="/images/arrow-right.png" />
<view class="selected-class" wx:else>当前场景</view>
<view class="selected-class" wx:if="{{item.actived}}">当前场景</view>
</view>
</view>
</block>
</scroll-view>
<!-- <view class="btn-box {{isFullSucreen?'isFullSucreen-btn':''}}">
<view class="logout text-center" bindtap="logout">退出账号</view>
</view> -->
</view>
pages/loading/loading.js
View file @
51d8e59
...
...
@@ -49,11 +49,11 @@ Page({
init
()
{
let
userInfo
=
wx
.
$util
.
getUserInfo
()
wx
.
nextTick
(()
=>
{
// 没有登录信息
或无开通场景
退出登录
if
(
!
userInfo
||
!
Object
.
keys
(
userInfo
).
length
||
!
userInfo
.
openSceneArr
?.
length
)
{
// 没有登录信息 退出登录
if
(
!
userInfo
||
!
Object
.
keys
(
userInfo
).
length
)
{
return
app
.
login
(
false
,
'请重新登录'
)
}
// 未选择4s店
// 未选择4s店
或未开通场景
if
((
userInfo
?.
shopMerchantId
??
''
)
===
''
)
return
wx
.
$router
.
reLaunch
(
'pages.accountItems'
)
// 未选择场景
if
((
userInfo
?.
sceneType
??
''
)
===
''
)
return
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
...
...
pages/merchantList/merchantList.js
View file @
51d8e59
// pages/accountItems/accountItems.js
import
api
from
'~/api/api'
import
{
get4SStoreList
}
from
'~/store/index'
import
constantData
from
'../constant/data'
const
IMG_URL
=
'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/'
import
{
getShopSceneConfig
}
from
'~/store/index'
Page
({
/**
* 页面的初始数据
...
...
@@ -14,7 +13,8 @@ Page({
loginUserInfoList
:
[],
shopMerchantId
:
''
,
shopMerchantName
:
''
,
IMG_URL
IMG_URL
,
openSceneArr
:
[]
},
/**
...
...
@@ -22,6 +22,7 @@ Page({
*/
onLoad
:
function
(
options
)
{
this
.
getMerchantList
()
this
.
getSceneArr
()
},
open
()
{
this
.
setData
({
...
...
@@ -29,6 +30,16 @@ Page({
inputFocus
:
true
})
},
getSceneArr
()
{
let
userInfo
=
wx
.
$util
.
getUserInfo
()
// 超管开通全部场景
if
(
userInfo
?.
isSuper
)
return
// 获取4s店关联场景数据
getShopSceneConfig
({
yqMerchantId
:
userInfo
?.
subLoginUser
?.
merchantId
,
merchantId
:
userInfo
?.
shopMerchantId
}).
then
(
result
=>
{
this
.
setData
({
openSceneArr
:
result
.
map
(
val
=>
{
return
val
.
scene
})
||
[]})
})
},
getMerchantList
(
e
)
{
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
params
=
{
...
...
@@ -46,9 +57,8 @@ Page({
.
catch
(
err
=>
{})
},
jumpPage
()
{
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
openSceneArr
=
userInfo
?.
openSceneArr
||
[]
let
{
shopMerchantName
,
shopMerchantId
}
=
this
.
data
let
{
shopMerchantName
,
shopMerchantId
,
openSceneArr
}
=
this
.
data
if
(
!
openSceneArr
?.
length
&&
!
wx
.
$util
.
getUserInfo
()?.
isSuper
)
return
wx
.
$util
.
showToast
(
'暂无开通业务,请联系总部管理员'
)
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
shopMerchantName
,
...
...
@@ -66,14 +76,7 @@ Page({
merchantName
:
shopMerchantName
}
})
// 只开通一个场景直接跳转页面
if
(
openSceneArr
.
length
===
1
)
{
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
sceneType
:
openSceneArr
[
0
]
})
let
pageUrl
=
constantData
?.
pageUrl
wx
.
$router
.
reLaunch
(
pageUrl
[
openSceneArr
[
0
]])
}
else
if
(
openSceneArr
.
length
>
1
)
{
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
}
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
},
setValue
(
value
)
{
if
(
this
.
properties
.
filterEmoji
)
{
...
...
@@ -129,7 +132,6 @@ Page({
chooseAccount
(
e
)
{
let
{
item
}
=
e
.
currentTarget
.
dataset
let
{
loginUserInfoList
}
=
this
.
data
let
userInfo
=
wx
.
$util
.
getUserInfo
()
loginUserInfoList
.
map
(
i
=>
{
i
.
active
=
false
if
(
i
.
merchantId
==
item
?.
merchantId
)
{
...
...
pages/merchantList/merchantList.wxml
View file @
51d8e59
<!-- style="padding-bottom:{{isFullSucreen?'224rpx':'160rpx'}}" -->
<view class="layout">
<view class="title">请选择4S店</view>
<view class="search-box" wx:if="{{copyLoginUserInfoList && copyLoginUserInfoList.length >= 10}}">
<view class="search-box">
<view class="search-input">
<block wx:if="{{!edit}}">
<view class="input {{searchValue?'':'placeholder'}}" bindtap="open">
...
...
pages/sceneIndex/sceneIndex.js
View file @
51d8e59
// pages/sceneIndex/sceneIndex.js
import
logOutAPI
from
'../../tabMine/api'
import
constantData
from
'../constant/data'
import
api
from
'~/api/api'
const
app
=
getApp
()
import
{
getShopSceneConfig
}
from
'~/store/index'
const
userInfo
=
wx
.
$util
.
getUserInfo
()
Page
({
/**
* 页面的初始数据
*/
data
:
{
timeState
:
''
,
sceneList
:
constantData
.
sceneList
,
isShow
:
false
,
userBoxHeight
:
0
openSceneArr
:
[]
},
// 选择场景
selectScene
(
e
)
{
let
{
scene
,
index
}
=
e
.
currentTarget
.
dataset
let
{
sceneList
}
=
this
.
data
const
userInfo
=
wx
.
$util
.
getUserInfo
()
let
{
sceneList
,
openSceneArr
}
=
this
.
data
if
(
!
openSceneArr
.
includes
(
scene
)
&&
!
userInfo
?.
isSuper
)
return
wx
.
$util
.
showToast
(
'暂未开通此场景'
)
sceneList
.
map
(
i
=>
(
i
.
actived
=
false
))
sceneList
[
index
].
actived
=
true
api
.
selectMerchantScene
({
...
...
@@ -46,59 +43,18 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad
(
options
)
{
let
{
sceneList
}
=
this
.
data
let
userInfo
=
wx
.
$util
.
getUserInfo
()
||
{}
let
openSceneArr
=
userInfo
?.
openSceneArr
||
[]
this
.
setData
({
timeState
:
wx
.
$util
.
getTimeState
()
})
wx
.
hideHomeButton
({
success
:
res
=>
{}
})
// 获取开通业务场景
let
arr
=
sceneList
.
filter
(
v
=>
openSceneArr
.
includes
(
v
.
sceneType
))
this
.
setData
({
isShow
:
Object
.
keys
(
userInfo
).
length
,
sceneList
:
arr
})
wx
.
$util
.
getViewInfo
(
'.user-box'
,
res
=>
{
this
.
setData
({
userBoxHeight
:
res
?.
height
})
},)
this
.
getSceneArr
()
},
// 切换账号
changeAccount
()
{
wx
.
$router
.
reLaunch
(
'pages.accountItems'
)
},
// 退出账号
logout
()
{
let
_this
=
this
wx
.
showModal
({
title
:
'温馨提示'
,
content
:
'是否退出当前账号?'
,
confirmColor
:
'#3582EE'
,
success
(
res
)
{
if
(
res
.
confirm
)
{
_this
.
setData
({
flag
:
true
})
_this
.
showLoading
()
logOutAPI
.
logout
().
then
(
_res_
=>
{
let
{
code
,
message
}
=
_res_
if
(
code
==
0
)
{
app
.
login
(
false
)
}
else
{
_this
.
setData
({
flag
:
false
})
_this
.
showToast
(
message
)
}
})
}
}
getSceneArr
()
{
// 超管默认开通全部场景
if
(
userInfo
?.
isSuper
)
return
// 获取4s店关联场景数据
getShopSceneConfig
({
yqMerchantId
:
userInfo
?.
subLoginUser
?.
merchantId
,
merchantId
:
userInfo
?.
isSuper
?
undefined
:
userInfo
?.
shopMerchantId
}).
then
(
result
=>
{
this
.
setData
({
openSceneArr
:
result
.
map
(
val
=>
{
return
val
.
scene
})
||
[]})
})
},
...
...
@@ -113,15 +69,13 @@ Page({
onShow
()
{
let
{
sceneList
}
=
this
.
data
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
openSceneArr
=
userInfo
?.
openSceneArr
||
[]
openSceneArr
.
includes
(
userInfo
?.
sceneType
)
&&
sceneList
.
map
(
i
=>
{
i
.
actived
=
false
if
(
i
.
sceneType
==
userInfo
?.
sceneType
)
{
i
.
actived
=
true
}
return
i
})
sceneList
.
map
(
i
=>
{
i
.
actived
=
false
if
(
i
.
sceneType
==
userInfo
?.
sceneType
)
{
i
.
actived
=
true
}
return
i
})
this
.
setData
({
sceneList
})
},
...
...
pages/sceneIndex/sceneIndex.wxml
View file @
51d8e59
<!-- pages/sceneIndex/sceneIndex.wxml -->
<view class="layout"
wx:if="{{isShow}}"
>
<scroll-view class="scene-box" scroll-y style="height: calc(100vh - 140rpx - {{
userBoxHeight}}px - {{
isFullSucreen ? 34 : 0}}px - 60rpx);">
<view class="layout">
<scroll-view class="scene-box" scroll-y style="height: calc(100vh - 140rpx - {{isFullSucreen ? 34 : 0}}px - 60rpx);">
<block wx:for="{{sceneList}}" wx:key="index">
<view class="scene-item {{item.actived ? 'active' : ''}}" bindtap="selectScene" data-scene="{{item.sceneType}}" data-index="{{index}}">
<view class="left">
...
...
@@ -10,15 +10,8 @@
<view class="desc">{{item.sceneDesc}}</view>
</view>
</view>
<!-- <view class="right">
<image wx:if='{{!item.actived}}' src="/images/arrow-right.png" />
<view class="selected-class" wx:else>当前场景</view>
</view> -->
</view>
</block>
</scroll-view>
<!-- <view class="btn-box {{isFullSucreen?'isFullSucreen-btn':''}}">
<view class="logout text-center" bindtap="logout">退出账号</view>
</view> -->
</view>
pages/wxLogin/wxLogin.js
View file @
51d8e59
This diff is collapsed.
Click to expand it.
store/index.js
View file @
51d8e59
...
...
@@ -255,43 +255,14 @@ export const setWebSocket = () => {
/** 获取园区店下的4S店 */
export
const
get4SStoreList
=
options
=>
{
console
.
log
(
options
,
'options'
)
return
new
Promise
((
resolve
,
reject
)
=>
{
const
app
=
getApp
()
wx
.
showLoading
()
if
(
app
.
globalData
.
storeListRange
?.
length
)
{
wx
.
hideLoading
()
return
resolve
(
app
.
globalData
.
storeListRange
)
}
api
.
getSceneMerchantRefStoreList
(
options
)
.
then
(
res
=>
{
wx
.
hideLoading
()
let
{
code
,
data
}
=
res
if
(
code
==
0
)
{
app
.
globalData
.
storeListRange
=
data
// let default4SStoreInfo = wx.$util.getUserInfo()?.default4SStoreInfo ? wx.$util.getUserInfo()?.default4SStoreInfo : data && data[0]
// let default4SStoreInfo_crowdFunding = wx.$util.getUserInfo()?.default4SStoreInfo_crowdFunding ? wx.$util.getUserInfo()?.default4SStoreInfo_crowdFunding : data && data[0]
// let default4SStoreInfo_newCarConversion = wx.$util.getUserInfo()?.default4SStoreInfo_newCarConversion ? wx.$util.getUserInfo()?.default4SStoreInfo_newCarConversion : data && data[0]
console
.
log
(
options
)
// if (options.scene == 0)
// wx.$util.setUserInfo({
// ...wx.$util.getUserInfo(),
// default4SStoreInfo: default4SStoreInfo
// })
// if (options.scene == 3 || options.scene == 2)
// if (options.isSubcehicle) {
// // 是否是次新车转化业务场景(商户关联关系与众筹一样)
// wx.$util.setUserInfo({
// ...wx.$util.getUserInfo(),
// default4SStoreInfo_newCarConversion: default4SStoreInfo_newCarConversion
// })
// } else
// wx.$util.setUserInfo({
// ...wx.$util.getUserInfo(),
// default4SStoreInfo_crowdFunding: default4SStoreInfo_crowdFunding
// })
resolve
(
app
.
globalData
.
storeListRange
)
resolve
(
data
||
[])
}
})
.
catch
(
error
=>
{
...
...
@@ -337,3 +308,13 @@ export const getPositionList = options => {
}
})
}
/** 获取4s店关联场景数据 */
export
const
getShopSceneConfig
=
options
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
api
.
getYqMerchantSceneConfigAPI
(
options
).
then
(
res
=>
{
let
{
data
}
=
res
resolve
(
data
||
[])
})
})
}
subvehicleConversion/api.js
View file @
51d8e59
...
...
@@ -72,5 +72,10 @@ module.exports = {
/** 修改订单备注 */
updateOrderRemark
(
data
)
{
return
api
.
post
(
'dj.api.smartcarlife.order.updateRemark'
,
data
)
},
/** 获取首页统计数据 */
getHomeStaticData
(
data
)
{
return
api
.
post
(
'dj.api.smartcarlife.expanded.gold.getMerchantCrowdfundingStatistics'
,
data
)
}
}
subvehicleConversion/pages/TabBar/conversionPage.js
View file @
51d8e59
...
...
@@ -51,7 +51,8 @@ Page({
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
params
=
{
merchantId
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
merchantId
,
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
,
scene
:
2
}
get4SStoreList
(
params
).
then
(
result
=>
{
this
.
setData
({
...
...
subvehicleConversion/pages/indexPage/index.js
View file @
51d8e59
...
...
@@ -30,21 +30,22 @@ Component({
],
staticDataList
:
[{
label
:
'今日营业额'
,
value
:
0
,
value
:
'todayAmount'
,
tipsLabel
:
'今日成交量'
,
tipsValue
:
0
tipsValue
:
'todayOrderCount'
},
{
label
:
'本月营业额'
,
value
:
0
,
value
:
'monthAmount'
,
tipsLabel
:
'本月成交量'
,
tipsValue
:
0
tipsValue
:
'monthOrderCount'
},
{
label
:
'累计营业额'
,
value
:
0
,
value
:
'totalAmount'
,
tipsLabel
:
'累计成交量'
,
tipsValue
:
0
tipsValue
:
'totalOrderCount'
}],
conversionList
:
{}
conversionList
:
{},
staticData
:
{}
},
lifetimes
:
{
attached
()
{
...
...
@@ -73,6 +74,14 @@ Component({
merchantId
:
wx
.
$util
.
getUserInfo
()?.
shopMerchantId
||
''
}
if
(
!
params
.
merchantId
)
return
api
.
getHomeStaticData
(
params
).
then
(
res
=>
{
let
{
code
,
data
}
=
res
if
(
code
==
0
)
{
this
.
setData
({
staticData
:
data
||
{}
})
}
})
api
.
summaryOfOutputValueList
(
params
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
if
(
res
.
data
?.
totalOutputValue
)
{
...
...
subvehicleConversion/pages/indexPage/index.wxml
View file @
51d8e59
...
...
@@ -2,10 +2,10 @@
<view class="top_box">
<view class="top_item" wx:for="{{staticDataList}}" wx:key="index">
<view class="label">{{item.label}}</view>
<view class="value"><text style="font-size: 28rpx;margin-right: 4rpx;">¥</text>{{
item.value
}}</view>
<view class="value"><text style="font-size: 28rpx;margin-right: 4rpx;">¥</text>{{
staticData[item.value] || 0
}}</view>
<view class="tips_box">
<text>{{item.tipsLabel}}</text>
<text class="num_text">{{
item.tipsValue
}}</text>
<text class="num_text">{{
staticData[item.tipsValue] || 0
}}</text>
</view>
</view>
</view>
...
...
@@ -16,7 +16,7 @@
<view class="overview-wrap">
<view class="overview-list" wx:for="{{productionValueList}}" wx:key="index">
<view class="overview-left">
<view class="overview-title"><image class="overview-img" src="{{IMG_URL}}staticIcon/{{item.i
con
}}.png"></image>{{item.title}}</view>
<view class="overview-title"><image class="overview-img" src="{{IMG_URL}}staticIcon/{{item.i
mgName
}}.png"></image>{{item.title}}</view>
<view class="overview-num">{{conversionList[item.valueName]}}</view>
</view>
</view>
...
...
subvehicleConversion/pages/orderPage/supplementaryOrderList/supplementaryOrderList.wxss
View file @
51d8e59
...
...
@@ -18,7 +18,7 @@
.search-box {
width: calc(100% - 64rpx);
margin:
53
rpx 32rpx 0;
margin:
32
rpx 32rpx 0;
display: flex;
background-color: #fff;
position: sticky;
...
...
tabDate/pages/index/index.js
View file @
51d8e59
...
...
@@ -389,7 +389,7 @@ Page({
}
})
console
.
log
(
data
.
list
,
'list'
)
const
userType
=
!
userInfo
?.
isSuper
&&
userInfo
.
merchantType
&&
userInfo
.
userType
==
1
const
userType
=
!
userInfo
?.
isSuper
&&
userInfo
?
.
merchantType
&&
userInfo
.
userType
==
1
list
=
data
.
list
.
map
(
item
=>
{
item
.
repeal
=
userType
&&
[
1
,
2
].
includes
(
item
.
inviteStatus
)
return
item
...
...
tabIndex/pages/index/index.js
View file @
51d8e59
...
...
@@ -133,7 +133,8 @@ Page({
let
userInfo
=
wx
.
$util
.
getUserInfo
()
let
params
=
{
merchantId
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
merchantId
,
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
staffUUID
:
userInfo
?.
isSuper
?
''
:
userInfo
?.
uuid
,
scene
:
1
}
get4SStoreList
(
params
).
then
(
result
=>
{
this
.
setData
({
...
...
@@ -193,7 +194,7 @@ Page({
let
{
item
,
type
}
=
e
.
currentTarget
.
dataset
let
{
userInfo
}
=
this
.
data
// 判断是不是门店员工
if
(
userInfo
.
merchantType
&&
!
userInfo
.
isSuper
&&
type
==
2
)
{
if
(
userInfo
?
.
merchantType
&&
!
userInfo
.
isSuper
&&
type
==
2
)
{
wx
.
$util
.
pointRecord
(
item
.
recordId
)
if
(
item
.
type
==
'scanCode'
)
{
wx
.
scanCode
({
...
...
tabIndex/pages/index/index.sass
View file @
51d8e59
...
...
@@ -22,7 +22,7 @@ page ::-webkit-scrollbar {
background
:
#FFFFFF
;
box-shadow
:
0
4rpx
20rpx
0
#000000
1a
;
border-radius
:
32rpx
32rpx
0
0
;
min-height
:
calc
(
100%
-
23
8
rpx
)
;
min-height
:
calc
(
100%
-
23
2
rpx
)
;
padding
:
30rpx
36rpx
;
}
}
...
...
tabIndex/pages/index/index.wxml
View file @
51d8e59
...
...
@@ -22,10 +22,10 @@
<view class="top_box">
<view class="top_item" wx:for="{{staticDataList}}" wx:key="index">
<view class="label">{{item.label}}</view>
<view class="value"><text style="font-size: 28rpx;margin-right: 4rpx;">¥</text>{{userStat[item.valueObj]['totalOrderMoney']}}</view>
<view class="value"><text style="font-size: 28rpx;margin-right: 4rpx;">¥</text>{{userStat[item.valueObj]['totalOrderMoney']
|| 0
}}</view>
<view class="tips_box">
<text>{{item.tipsLabel}}</text>
<text class="num_text">{{userStat[item.valueObj]['totalUpgrade']}}</text>
<text class="num_text">{{userStat[item.valueObj]['totalUpgrade']
|| 0
}}</text>
</view>
</view>
</view>
...
...
@@ -82,7 +82,7 @@
<div class="menu noStaff">
<block wx:for="{{ menu }}" wx:key="index">
<view class="item" bindtap="jump" data-item="{{ item }}" data-type="{{ userInfo.userType }}">
<image src="{{IMG_URL}}{{item.icon}}.png" />
<image src="{{IMG_URL}}
upgrade/
{{item.icon}}.png" />
<view class="label">{{item.name}}</view>
</view>
</block>
...
...
@@ -324,7 +324,7 @@
wx:if="{{ showOrderpop }}"
flag="{{ showOrderpop }}"
/>
<side-select-popup show="{{ shopSideSelectPopup }}" storeList="{{ userInfo.isSuper ? merchantRange : storeRange}}" subIndex="{{subIndex}}" hasTabBar="true" />
<side-select-popup show="{{ shopSideSelectPopup }}" storeList="{{ userInfo.isSuper ? merchantRange : storeRange}}"
bindconfirm="storeSearchEvent"
subIndex="{{subIndex}}" hasTabBar="true" />
<!-- <store-picker
subIndex="{{ subIndex }}"
pickList="{{ merchantRange }}"
...
...
tabMine/pages/index/index.js
View file @
51d8e59
...
...
@@ -2,11 +2,13 @@
import
api
from
'../../api.js'
const
app
=
getApp
()
import
constantData
from
'../../../pages/constant/data'
const
IMG_URL
=
'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/mine/'
Page
({
/**
* 页面的初始数据
*/
data
:
{
IMG_URL
,
navStyle
:
'background-color: rgba(0,0,0,0);box-shadow:none;'
,
workCount
:
0
,
workItem
:
[
...
...
@@ -263,6 +265,7 @@ Page({
},
// 切换场景
changeScene
()
{
wx
.
$router
.
reLaunch
(
'pages.changeScene'
)
},
...
...
tabMine/pages/index/index.wxml
View file @
51d8e59
...
...
@@ -52,18 +52,22 @@
<view class="title">工位设置<image class="arrow_icon" src="../../images/arrow_icon.png" mode=""/></view>
<view class="set_tips" wx:if="{{workCount>0}}"><text style="font-size: 32rpx;color: #333333; font-weight: 500;">{{workCount}}</text>个</view>
<view class="set_tips" wx:else>根据门店设置工位数</view>
<image class="icon_image" src="{{IMG_URL}}mine_icon_4.png" mode=""/>
</view>
<view class="set_item item_2" bindtap="showMerchantPop">
<view class="title">录单设置<image class="arrow_icon" src="../../images/arrow_icon.png" mode=""/></view>
<view class="set_tips">设置录单必填项</view>
<image class="icon_image" src="{{IMG_URL}}mine_icon_2.png" mode=""/>
</view>
<view class="set_item item_3" bindtap="changeScene">
<view class="title">场景切换<image class="arrow_icon" src="../../images/arrow_icon.png" mode=""/></view>
<view class="set_tips">{{selectedSceneName}}</view>
<image class="icon_image" src="{{IMG_URL}}mine_icon_3.png" mode=""/>
</view>
<view class="set_item item_4" bindtap="goVersionPage">
<view class="title">更新日志<image class="arrow_icon" src="../../images/arrow_icon.png" mode=""/></view>
<view class="set_tips">最新{{versionData.version}}版</view>
<image class="icon_image" src="{{IMG_URL}}mine_icon_1.png" mode=""/>
</view>
</view>
<!-- <view class="version_box" bindtap="goVersionPage">
...
...
tabMine/pages/index/index.wxss
View file @
51d8e59
...
...
@@ -152,6 +152,15 @@
justify-content: center;
padding: 32rpx;
margin-bottom: 20rpx;
position: relative;
}
.set_box .set_item .icon_image{
width: 120rpx;
height: 120rpx;
position: absolute;
right: 0;
bottom: 0;
}
.set_box .set_item .title .arrow_icon{
...
...
utils/request/environment.js
View file @
51d8e59
...
...
@@ -67,8 +67,8 @@ const domain_items = {
scrm
:
'https://scrm.dev.glsx.com.cn'
},
dev
:
{
//
dj: 'https://dj.dev.glsx.com.cn',
dj
:
'http://192.168.3.226:9711'
,
dj
:
'https://dj.dev.glsx.com.cn'
,
//
dj: 'http://192.168.3.226:9711',
scrm
:
'https://scrm.dev.glsx.com.cn'
},
uat
:
{
...
...
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