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 cef440e7
authored
Apr 13, 2023
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'dev_v4.18.2' into 'develop'
Dev v4.18.2 See merge request
!56
2 parents
ba9b21ff
0c832f88
Hide whitespace changes
Inline
Side-by-side
Showing
26 changed files
with
176 additions
and
118 deletions
api/api.js
components/Calendar/Calendar_Function.js
components/CalendarMonth/Calendar_Function.js
components/Confirm/Confirm.js
components/Goods/Goods.js
components/Goods/Goods.wxml
components/Merchant-Seles/Merchant-Seles.js
components/authSetting/authSetting.js
config.js
pages/accountItems/accountItems.js
pages/webView/webView.js
pages/wxLogin/wxLogin.js
tabOperating/pages/index/components/conquestCell/conquestCell.wxml
tabWorkOrder/pages/additionRecordOrder/additionRecordOrder.js
tabWorkOrder/pages/additionRecordOrder/additionRecordOrder.wxml
tabWorkOrder/pages/confirmOrder/confirmOrder.js
tabWorkOrder/pages/confirmOrder/confirmOrder.wxml
tabWorkOrder/pages/constructionOrderDetail/constructionOrderDetail.js
tabWorkOrder/pages/constructionOrderDetail/constructionOrderDetail.wxml
tabWorkOrder/pages/createOrder/createOrder.js
tabWorkOrder/pages/createOrder/createOrder.wxml
tabWorkOrder/pages/index/index.wxml
tabWorkOrder/pages/orderDetail/orderDetail.js
tabWorkOrder/pages/orderDetail/orderDetail.wxml
utils/util.js
utils/utils_wx.js
api/api.js
View file @
cef440e
...
...
@@ -134,7 +134,7 @@ module.exports = {
},
// 获取订单信息
getWorkList
(
data
)
{
params
=
data
||
{}
let
params
=
data
||
{}
params
.
sceneType
=
1
return
api
.
post
(
'dj.api.smartcarlife.order.search'
,
params
)
},
...
...
@@ -146,5 +146,10 @@ module.exports = {
// 获取园区店下的4s店
getSceneMerchantRefStoreList
(
data
)
{
return
api
.
post
(
'dj.api.scenemerchantref.query4SRefByYqShop'
,
data
)
},
// 获取园区店配置
getYqStoreConfig
(
data
)
{
return
api
.
get
(
'dj.api.smarcarlife.yqMerchantConfig.detail'
,
data
)
}
}
components/Calendar/Calendar_Function.js
View file @
cef440e
...
...
@@ -24,7 +24,7 @@ class Calendar {
// console.log(calenderHeight)
let
height
=
'80%'
if
(
typeof
calenderHeight
===
'number'
)
{
wx
.
$util
.
get
Phone
Info
(
res
=>
{
wx
.
$util
.
get
System
Info
(
res
=>
{
let
{
windowHeight
}
=
res
if
(
calenderHeight
>
windowHeight
)
calenderHeight
=
windowHeight
if
(
calenderHeight
<
windowHeight
*
0.5
)
calenderHeight
=
windowHeight
*
0.5
...
...
components/CalendarMonth/Calendar_Function.js
View file @
cef440e
...
...
@@ -23,7 +23,7 @@ class Calendar {
let
{
data
:
calenderHeight
}
=
_this
let
height
=
'80%'
if
(
typeof
calenderHeight
===
'number'
)
{
wx
.
$util
.
get
Phone
Info
(
res
=>
{
wx
.
$util
.
get
System
Info
(
res
=>
{
let
{
windowHeight
}
=
res
if
(
calenderHeight
>
windowHeight
)
calenderHeight
=
windowHeight
if
(
calenderHeight
<
windowHeight
*
0.5
)
calenderHeight
=
windowHeight
*
0.5
...
...
components/Confirm/Confirm.js
View file @
cef440e
...
...
@@ -539,7 +539,7 @@ Component({
}
},
attached
()
{
wx
.
$util
.
get
Phone
Info
(
info
=>
{
wx
.
$util
.
get
System
Info
(
info
=>
{
let
{
windowWidth
}
=
info
this
.
setData
({
x
:
windowWidth
,
...
...
components/Goods/Goods.js
View file @
cef440e
...
...
@@ -147,7 +147,7 @@ Component({
let
upgradeGoodsList
=
[]
i
.
upgradeGoodsList
.
map
(
c
=>
{
// console.log(c);
let
name
=
c
.
upgradeGoods
Name
||
c
.
goodsInfo
.
goodsName
let
name
=
c
.
upgradeGoods
Alias
||
c
.
upgradeGoodsName
||
c
.
goodsInfo
.
goodsName
if
(
name
.
indexOf
(
value
)
!=
-
1
)
{
upgradeGoodsList
.
push
(
c
)
}
...
...
components/Goods/Goods.wxml
View file @
cef440e
...
...
@@ -24,7 +24,7 @@
data-ind="{{ind}}"
data-item="{{i}}">
<view class="name text-hide {{i.active?'textWidth':''}}">
{{filter.replaceItemText(i.upgradeGoodsName) || filter.replaceItemText(i.goodsInfo.goodsName)}}
{{filter.replaceItemText(i.upgradeGoods
Alias) ||filter.replaceItemText(i.upgradeGoods
Name) || filter.replaceItemText(i.goodsInfo.goodsName)}}
</view>
<view class="last" wx:if="{{!i.active}}">
<!-- | -->
...
...
components/Merchant-Seles/Merchant-Seles.js
View file @
cef440e
...
...
@@ -13,7 +13,8 @@ Component({
type
:
Object
,
observer
:
function
(
n
)
{
// console.log('userInfo', n)
if
(
n
&&
this
.
data
.
type
!=
1
)
this
.
getMerchantList
()
// 先请求导流方接口
if
(
n
&&
this
.
data
.
type
==
2
)
this
.
getMerchantList
()
}
},
...
...
@@ -28,16 +29,16 @@ Component({
// 处理先要调用销售顾问接口再调用转化人员接口的问题
observers
:
{
'orderObj.sellerUserId'
:
function
(
id
)
{
// console.log(id)
// console.log('orderObj.sellerUserId', this.data.orderObj)
let
{
type
,
selesFirstRender
}
=
this
.
data
// console.log(type == 1 && selesFirstRender)
// selesFirstRender
if
(
type
==
1
&&
id
)
{
// sellerUserId 解决接口数据重复请求问题
let
{
type
,
sellerUserId
}
=
this
.
data
if
(
type
==
1
&&
id
&&
id
!=
sellerUserId
)
{
// console.log(id)
// console.log('orderObj.sellerUserId')
this
.
getMerchantList
()
//
this.setData({
// selesFirstRender: false
//
})
this
.
setData
({
sellerUserId
:
id
})
}
}
},
...
...
@@ -50,7 +51,7 @@ Component({
selesList
:
[],
orderObj
:
{},
isFirst
:
true
,
sel
esFirstRender
:
true
,
sel
lerUserId
:
''
,
orderSellerInfo
:
''
},
...
...
components/authSetting/authSetting.js
View file @
cef440e
...
...
@@ -61,7 +61,7 @@ Component({
const
path
=
`
${
baseUrl
}${
url
}
.html`
// private user
wx
.
navigateTo
({
url
:
`/pages/webView/webView?
path
=
${
encodeURIComponent
(
path
)}
`
url
:
`/pages/webView/webView?
url
=
${
encodeURIComponent
(
path
)}
`
})
// var globalData = appInstance.globalData.extConfig
...
...
config.js
View file @
cef440e
...
...
@@ -10,7 +10,7 @@
* 2测试
* 3生产环境
*/
let
index
=
2
let
index
=
1
const
accountInfo
=
wx
.
getAccountInfoSync
()
const
systemInfo
=
wx
.
getSystemInfoSync
()
...
...
pages/accountItems/accountItems.js
View file @
cef440e
...
...
@@ -136,6 +136,91 @@ Page({
loginUserInfoList
})
},
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') {
},
// 检测一下是否能微信端小程序登录
checkAgree
()
{
return
new
Promise
((
resolve
,
reject
)
=>
{
let
sysInfo
=
wx
.
getSystemInfoSync
()
// let { environment } = sysInfo
// 1企业微信 0微信
let
envName
=
sysInfo
.
environment
?
1
:
0
let
{
merchantId
:
yqMerchantId
}
=
wx
.
$util
.
getUserInfo
()
api
.
getYqStoreConfig
({
yqMerchantId
}).
then
(
res
=>
{
let
{
code
,
data
:
{
loginControlList
=
[]
}
}
=
res
if
(
code
==
'0'
)
{
// const loginControlList = []
// const loginControlList = [0, 1]
if
(
loginControlList
.
includes
(
envName
))
{
resolve
(
true
)
}
else
{
wx
.
hideLoading
()
wx
.
showModal
({
title
:
'温馨提示'
,
content
:
`请在
${
envName
==
0
?
'企业微信'
:
'微信'
}
中打开`
,
showCancel
:
false
,
confirmText
:
'知道了'
,
confirmColor
:
'#3582EE'
})
resolve
(
false
)
}
}
})
})
},
async
getYqMerchantSceneConfig
({
yqMerchantId
,
isSuper
})
{
let
checkAgree
=
await
this
.
checkAgree
()
if
(
!
checkAgree
)
return
false
// 超管默认开通所有场景
if
(
isSuper
)
{
// 0 会员权益/升级 1 精品升级
let
openSceneArr
=
constantData
.
sceneList
.
map
(
val
=>
{
return
val
?.
sceneType
})
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
openSceneArr
})
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
{
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
openSceneArr
})
// 只开通一个场景直接跳转页面
if
(
openSceneArr
.
length
===
1
)
{
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
selectedSceneType
:
openSceneArr
.
includes
(
1
)
?
1
:
0
})
wx
.
$router
.
reLaunch
(
openSceneArr
.
includes
(
1
)
?
'tabIndex.index'
:
'packageEquity.equityPage'
)
}
else
if
(
openSceneArr
.
length
>
1
)
{
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
}
}
}
else
{
wx
.
$util
.
showToast
(
message
)
}
})
},
choiceAccountLogin
()
{
let
{
loginUserInfoList
}
=
this
.
data
let
id
=
null
...
...
@@ -148,6 +233,7 @@ Page({
isSuper
=
e
.
isSuper
}
})
if
(
!
id
)
{
wx
.
$util
.
showToast
(
'请选择账号'
)
return
...
...
@@ -161,64 +247,16 @@ Page({
.
then
(
res
=>
{
let
{
data
,
message
}
=
res
if
(
data
)
{
app
.
globalData
.
YQorderSetting
=
null
//
app.globalData.YQorderSetting = null
app
.
globalData
.
yqdInfo
.
merchantRange
=
null
wx
.
$util
.
setUserInfo
(
data
.
loginUserInfoList
[
0
])
app
.
globalData
.
YQorderSetting
=
null
// console.log
(data.loginUserInfoList[0])
wx
.
$util
.
setUserInfo
(
data
.
loginUserInfoList
[
0
])
checkYqdSuper
(
app
,
data
.
loginUserInfoList
[
0
])
const
SCENE
=
wx
.
$SCENE
console
.
log
(
SCENE
,
'SCENE'
)
// debugger 兼容扫码优惠券进来和免登录逻辑冲突问题
if
(
SCENE
&&
SCENE
.
path
!=
'pages/accountItems/accountItems'
)
{
let
{
path
,
query
// : { scene }
}
=
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
}
else
{
// 超管默认开通所有场景
if
(
isSuper
)
{
// 0 会员权益/升级 1 精品升级
let
openSceneArr
=
constantData
.
sceneList
.
map
(
val
=>
{
return
val
?.
sceneType
})
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
openSceneArr
})
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
{
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
openSceneArr
})
// 只开通一个场景直接跳转页面
if
(
openSceneArr
.
length
===
1
)
{
wx
.
$util
.
setUserInfo
({
...
wx
.
$util
.
getUserInfo
(),
selectedSceneType
:
openSceneArr
.
includes
(
1
)
?
1
:
0
})
wx
.
$router
.
reLaunch
(
openSceneArr
.
includes
(
1
)
?
'tabIndex.index'
:
'packageEquity.equityPage'
)
}
else
if
(
openSceneArr
.
length
>
1
)
{
wx
.
$router
.
reLaunch
(
'pages.sceneIndex'
)
}
}
}
else
{
wx
.
$util
.
showToast
(
message
)
}
})
}
// console.log(data.loginUserInfoList[0])
getYQorderInfo
()
const
SCENE
=
wx
.
$SCENE
// 有场景信息就跳转对应页面 没有就登录场景
SCENE
&&
SCENE
.
path
!=
'pages/accountItems/accountItems'
?
this
.
sceneHandle
()
:
this
.
getYqMerchantSceneConfig
({
yqMerchantId
,
isSuper
})
}
else
{
wx
.
$util
.
showToast
(
message
)
}
...
...
pages/webView/webView.js
View file @
cef440e
...
...
@@ -24,7 +24,7 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
wx
.
$
api
.
showLoading
(
'加载中...'
)
wx
.
$
util
.
showLoading
(
'加载中...'
)
let
decodeUrl
=
decodeURIComponent
(
options
.
url
)
let
param
=
this
.
getParams
(
decodeUrl
)
if
(
param
.
urlParam
)
{
...
...
pages/wxLogin/wxLogin.js
View file @
cef440e
...
...
@@ -204,6 +204,7 @@ Page({
iv
})
.
then
(({
code
,
data
,
message
})
=>
{
console
.
log
(
data
)
wx
.
hideLoading
()
if
(
code
==
0
)
{
let
{
loginUserInfoList
,
sessionId
}
=
data
...
...
tabOperating/pages/index/components/conquestCell/conquestCell.wxml
View file @
cef440e
...
...
@@ -88,7 +88,9 @@
wx:for-item='subOrdersItem'
wx:for-index='subOrdersIndex'>
<view class="goodsItem">
<view class="name oneText">{{filter.replaceItemText(subOrdersItem.upgradeGoodsName)}}</view>
<view class="name oneText">
{{filter.replaceItemText(subOrdersItem.upgradeGoodsAlias||subOrdersItem.upgradeGoodsName)}}
</view>
<view class="price">¥{{filter.toDecimal2 (subOrdersItem.totalPrice)}}</view>
</view>
</block>
...
...
tabWorkOrder/pages/additionRecordOrder/additionRecordOrder.js
View file @
cef440e
...
...
@@ -674,7 +674,7 @@ Page({
// if (!e.shopMinPrice) e.shopMinPrice = e.upgradeShopPrice
if
(
!
e
.
shopMinPrice
)
e
.
shopMinPrice
=
e
.
upgradeShopMinPrice
e
.
goodsInfo
=
{
goodsName
:
e
.
upgradeGoodsName
goodsName
:
e
.
upgradeGoods
Alias
||
e
.
upgradeGoods
Name
}
e
.
count
=
e
.
number
e
.
id
=
e
.
upgradeGoodsId
...
...
@@ -768,7 +768,7 @@ Page({
accountDate
&&
(
accountDate
=
new
Date
(
accountDate
).
format
(
'yyyy-MM-dd'
))
this
.
setData
({
outTradeNo
,
totalFee
:
totalFee
*
100
,
totalFee
:
totalFee
*
100
,
accountDate
})
})
...
...
@@ -777,7 +777,7 @@ Page({
},
onRoute
(
options
)
{
let
{
outTradeNo
,
totalFee
,
accountDate
,
supplementId
}
=
options
console
.
log
(
options
);
console
.
log
(
options
)
// 如果是扫码进来的
if
(
supplementId
)
{
return
this
.
checkShowOrderInfo
(
options
)
...
...
tabWorkOrder/pages/additionRecordOrder/additionRecordOrder.wxml
View file @
cef440e
...
...
@@ -246,7 +246,7 @@
<image src="../../images/del.png" />
</view>
<view class="name text-hide">
{{filter.replaceItemText(item.upgradeGoodsName) || filter.replaceItemText(item.goodsInfo.goodsName)}}
{{filter.replaceItemText(item.upgradeGoods
Alias)||filter.replaceItemText(item.upgradeGoods
Name) || filter.replaceItemText(item.goodsInfo.goodsName)}}
</view>
<view class="price-box">
¥
...
...
tabWorkOrder/pages/confirmOrder/confirmOrder.js
View file @
cef440e
...
...
@@ -218,7 +218,7 @@ Page({
if
(
e
.
upgradeWarrantyPeriod
||
e
.
upgradeWarrantyPeriod
>
0
)
{
warrantyCardList
.
push
({
warrantyPeriod
:
e
.
upgradeWarrantyPeriod
,
goodsName
:
e
.
upgradeGoodsName
goodsName
:
e
.
upgradeGoods
Alias
||
e
.
upgradeGoods
Name
})
}
})
...
...
tabWorkOrder/pages/confirmOrder/confirmOrder.wxml
View file @
cef440e
...
...
@@ -33,7 +33,9 @@
<view class="goods">
<block wx:for="{{orderInfo.subOrderList}}" wx:key="index">
<view class="item">
<view class="name text-hide">{{filter.replaceItemText(item.upgradeGoodsName) || ''}}</view>
<view class="name text-hide">
{{filter.replaceItemText(item.upgradeGoodsAlias) ||filter.replaceItemText(item.upgradeGoodsName) || ''}}
</view>
<view class="type">x{{item.number}}</view>
<view class="price">¥{{item.price}}</view>
</view>
...
...
tabWorkOrder/pages/constructionOrderDetail/constructionOrderDetail.js
View file @
cef440e
...
...
@@ -164,7 +164,7 @@ Page({
if
(
e
.
upgradeWarrantyPeriod
||
e
.
upgradeWarrantyPeriod
>
0
)
{
warrantyCardList
.
push
({
warrantyPeriod
:
e
.
upgradeWarrantyPeriod
,
goodsName
:
e
.
upgradeGoodsName
,
goodsName
:
e
.
upgradeGoods
Alias
||
e
.
upgradeGoods
Name
,
cardCode
:
e
.
cardCode
})
}
...
...
tabWorkOrder/pages/constructionOrderDetail/constructionOrderDetail.wxml
View file @
cef440e
...
...
@@ -37,7 +37,9 @@
<view class="goods">
<block wx:for="{{orderInfo.subOrderList}}" wx:key="index">
<view class="item">
<view class="name text-hide">{{filter.replaceItemText(item.upgradeGoodsName) || ''}}</view>
<view class="name text-hide">
{{filter.replaceItemText(item.upgradeGoodsAlias) ||filter.replaceItemText(item.upgradeGoodsName) || ''}}
</view>
<view class="type">x{{item.number}}</view>
<view class="price">¥{{item.price}}</view>
</view>
...
...
@@ -173,7 +175,7 @@
</view>
</block> -->
<!-- wx:if="{{warrantyCardList.length || warrantyCardVisible}}" -->
<!-- 没有质保加屏蔽客服开启 就不显示 -->
<!-- 没有质保加屏蔽客服开启 就不显示 -->
<block wx:if="{{orderInfo.status != 10&&warrantyCardList.length || warrantyCardVisible}}">
<view class="box">
<view class="title">{{orderInfo.selectPayType==0? '客服' :'质保'}}</view>
...
...
tabWorkOrder/pages/createOrder/createOrder.js
View file @
cef440e
...
...
@@ -578,7 +578,7 @@ Page({
// if (!e.shopMinPrice) e.shopMinPrice = e.upgradeShopPrice
if
(
!
e
.
shopMinPrice
)
e
.
shopMinPrice
=
e
.
upgradeShopMinPrice
e
.
goodsInfo
=
{
goodsName
:
e
.
upgradeGoodsName
goodsName
:
e
.
upgradeGoods
Alias
||
e
.
upgradeGoods
Name
}
e
.
count
=
e
.
number
e
.
id
=
e
.
upgradeGoodsId
...
...
tabWorkOrder/pages/createOrder/createOrder.wxml
View file @
cef440e
...
...
@@ -253,7 +253,7 @@
<image src="../../images/del.png" />
</view>
<view class="name text-hide">
{{filter.replaceItemText(item.upgradeGoodsName) || filter.replaceItemText(item.goodsInfo.goodsName)}}
{{filter.replaceItemText(item.upgradeGoods
Alias) ||filter.replaceItemText(item.upgradeGoods
Name) || filter.replaceItemText(item.goodsInfo.goodsName)}}
</view>
<view class="price-box">
¥
...
...
tabWorkOrder/pages/index/index.wxml
View file @
cef440e
...
...
@@ -90,7 +90,9 @@
wx:for-item="i"
wx:for-index="sindex">
<view class="goods" wx:if="{{sindex < 2}}">
<view class="goods-name text-hide">{{filter.replaceItemText(i.upgradeGoodsName) || ''}}</view>
<view class="goods-name text-hide">
{{filter.replaceItemText(i.upgradeGoodsAlias) ||filter.replaceItemText(i.upgradeGoodsName) || ''}}
</view>
<view class="goods-price">
¥
<text>{{i.totalPrice || 0}}</text>
...
...
tabWorkOrder/pages/orderDetail/orderDetail.js
View file @
cef440e
...
...
@@ -15,7 +15,7 @@ Page({
customerService
:
''
,
defaultCustomerService
:
'https://img02.glsx.com.cn/weapp/resource/dj-car-boutique-work-wechat/kf.png'
,
failCustomerService
:
'../images/kfrefresh.png'
,
warrantyCardVisible
:
true
,
warrantyCardVisible
:
true
},
jumpUpdate
()
{
let
{
orderInfo
}
=
this
.
data
...
...
@@ -159,7 +159,7 @@ Page({
if
(
e
.
upgradeWarrantyPeriod
||
e
.
upgradeWarrantyPeriod
>
0
)
{
warrantyCardList
.
push
({
warrantyPeriod
:
e
.
upgradeWarrantyPeriod
,
goodsName
:
e
.
upgradeGoodsName
,
goodsName
:
e
.
upgradeGoods
Alias
||
e
.
upgradeGoods
Name
,
cardCode
:
e
.
cardCode
})
}
...
...
@@ -245,17 +245,17 @@ Page({
},
1000
*
index
)
})
},
getServiceBaseInfo
(
merchantId
){
api
.
getServiceBaseInfo
({
merchantId
})
.
then
((
result
)
=>
{
console
.
log
(
result
,
'result'
);
let
{
data
,
code
}
=
result
if
(
data
.
cardCodeFlag
&&
data
.
cardCodeFlag
==
1
)
{
this
.
setData
({
warrantyCardVisible
:
false
})
}
getServiceBaseInfo
(
merchantId
)
{
api
.
getServiceBaseInfo
({
merchantId
}).
then
(
result
=>
{
console
.
log
(
result
,
'result'
)
let
{
data
,
code
}
=
result
if
(
data
.
cardCodeFlag
&&
data
.
cardCodeFlag
==
1
)
{
this
.
setData
({
warrantyCardVisible
:
false
})
}
})
},
},
setQrBoxHeight
()
{
wx
.
$util
.
getViewInfo
(
'#qr-view'
,
({
height
})
=>
{
// console.log(height)
...
...
@@ -305,7 +305,7 @@ Page({
this
.
setData
({
customerService
:
''
})
// setTimeout(() => {
let
{
failCustomerService
,
defaultCustomerService
}
=
this
.
data
let
{
orderCode
,
customerPhone
:
phoneNumber
,
selectPayType
}
=
this
.
data
.
orderInfo
...
...
tabWorkOrder/pages/orderDetail/orderDetail.wxml
View file @
cef440e
...
...
@@ -27,7 +27,9 @@
<view class="goods">
<block wx:for="{{orderInfo.subOrderList}}" wx:key="index">
<view class="item">
<view class="name text-hide">{{filter.replaceItemText(item.upgradeGoodsName) || ''}}</view>
<view class="name text-hide">
{{filter.replaceItemText(item.upgradeGoodsAlias) ||filter.replaceItemText(item.upgradeGoodsName) || ''}}
</view>
<view class="type">x{{item.number}}</view>
<view class="price">¥{{item.price}}</view>
</view>
...
...
@@ -134,8 +136,8 @@
</block>
</view>
<!-- wx:if="{{warrantyCardList&&warrantyCardList.length}}" -->
<!-- 没有屏蔽质保卡 就显示 -->
<!-- wx:if="{{!warrantyCardVisible&&orderInfo.selectPayType==0}}" -->
<!-- 没有屏蔽质保卡 就显示 -->
<!-- wx:if="{{!warrantyCardVisible&&orderInfo.selectPayType==0}}" -->
<block wx:if="{{warrantyCardList.length || warrantyCardVisible}}">
<view class="box">
<view class="title">{{orderInfo.selectPayType==0? '客服' :'质保'}}</view>
...
...
utils/util.js
View file @
cef440e
...
...
@@ -105,7 +105,11 @@ const removeStorage = () => {
}
const
showNoAccess
=
()
=>
{
wx
.
showToast
(
'您的账号无法完成此操作'
)
// wx.showToast('您的账号无法完成此操作')
wx
.
showToast
({
title
:
'您的账号无法完成此操作'
,
icon
:
'error'
})
}
const
setStorageSync
=
(
key
,
data
)
=>
{
wx
.
setStorageSync
(
key
,
JSON
.
stringify
(
data
))
...
...
utils/utils_wx.js
View file @
cef440e
...
...
@@ -91,18 +91,6 @@ const wxShowToast = (name, params) => {
}
}
/**获取设备信息 */
const
getSystemInfo
=
callBack
=>
{
wx
.
getSystemInfo
({
success
(
res
)
{
callBack
(
res
)
},
fail
(
err
)
{
callBack
(
err
)
}
})
}
/**拨打电话 */
const
phoneCall
=
phoneNumber
=>
{
wx
.
makePhoneCall
({
...
...
@@ -220,8 +208,19 @@ const isFullSucreen = isComponents => {
})
return
val
}
/**获取手机信息 */
const
getPhoneInfo
=
callBack
=>
{
// /**获取手机信息 */
// const getPhoneInfo = callBack => {
// wx.getSystemInfo({
// success(res) {
// callBack(res)
// },
// fail(err) {
// callBack(err)
// }
// })
// }
/**获取设备信息 */
const
getSystemInfo
=
callBack
=>
{
wx
.
getSystemInfo
({
success
(
res
)
{
callBack
(
res
)
...
...
@@ -232,7 +231,7 @@ const getPhoneInfo = callBack => {
})
}
const
wxApi
=
{
getPhoneInfo
,
//
getPhoneInfo,
previewImage
,
getSystemInfo
,
showLoading
,
...
...
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