Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
gl_tape
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
3
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit a9f46d15
authored
Jul 02, 2024
by
前端
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'v1.0.7' of
http://192.168.3.233:8090/glsx/gl_tape
into v1.0.7
2 parents
5d047592
7ddaa012
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
144 additions
and
110 deletions
api/module/boutique.js
api/module/systemApi.js
assets/images/sprite.png
assets/spritesmith/logo.png
mixin/uploader.js
pages/equity/detail/components/History.vue
pages/equity/index.vue
utils/cache/constantData.js
api/module/boutique.js
View file @
a9f46d1
...
...
@@ -39,6 +39,14 @@ module.exports = {
...
data
,
});
},
// 历史订单列表
getQuotationList
(
data
)
{
return
http
.
post
({
method
:
"dj.api.smartcarlife.vehicle.damage.upgrade.quotation.page"
,
projectName
:
"boutique"
,
...
data
,
});
},
/**客户邀约记录 */
customerInviteRecordPage
(
data
)
{
return
http
.
post
({
...
...
api/module/systemApi.js
View file @
a9f46d1
...
...
@@ -70,9 +70,11 @@ const imgToBase64 = (list, urlKey) => {
})
})
};
const
updateMockData
=
(
data
,
key
)
=>
{
const
updateMockData
=
(
data
List
,
keyList
)
=>
{
const
mockData
=
uni
.
$storage
.
get
(
'mock_data'
)
mockData
[
key
]
=
data
keyList
.
map
(
key
=>
{
mockData
[
key
]
=
dataList
[
key
]
})
setTimeout
(()
=>
{
uni
.
$storage
.
set
(
"mock_data"
,
mockData
)
},
1
e3
)
...
...
assets/images/sprite.png
View file @
a9f46d1
876 KB
|
W:
|
H:
871 KB
|
W:
|
H:
2-up
Swipe
Onion skin
assets/spritesmith/logo.png
View file @
a9f46d1
10.9 KB
|
W:
|
H:
24.1 KB
|
W:
|
H:
2-up
Swipe
Onion skin
mixin/uploader.js
View file @
a9f46d1
...
...
@@ -228,18 +228,21 @@ export default {
uni
.
$isNetWork
()
.
then
(()
=>
{
if
(
this
.
snapshot
.
size
==
0
)
{
this
.
enQueue
();
this
.
pollingLater
(
interval
);
}
else
{
const
record
=
this
.
snapshot
.
dequeue
();
this
.
uploadRecord
(
record
);
}
this
.
upload
();
})
.
catch
(()
=>
{
this
.
pollingLater
(
interval
);
});
},
upload
()
{
if
(
this
.
snapshot
.
size
==
0
)
{
this
.
enQueue
();
this
.
pollingLater
(
interval
);
}
else
{
const
record
=
this
.
snapshot
.
dequeue
();
this
.
uploadRecord
(
record
);
}
},
stopPolling
()
{
this
.
snapshot
.
clear
();
this
.
snapshot
=
null
;
...
...
pages/equity/detail/components/History.vue
View file @
a9f46d1
<
template
>
<view
class=
"layout"
>
<view
class=
"title"
>
{{
title
}}
</view>
<template
v-if=
"historyList.length > 0"
>
<scroll-view
class=
"record-box"
scroll-y
@
scrolltolower=
"pageonReachBottom"
>
<template
v-if=
"list.length > 0"
>
<scroll-view
class=
"record-box"
scroll-y
@
scrolltolower=
"pageonReachBottom"
>
<view
class=
"card-list"
>
<view
class=
"card-item"
v-for=
"item in historyList"
:key=
"item.id"
>
<template>
<image
v-if=
"item.vdQuotationPaymentDoc && item.vdQuotationPaymentDoc.paymentDocUrl"
class=
"image-box"
:src=
"item.vdQuotationPaymentDoc.paymentDocUrl"
/>
<image
v-else
class=
"image-box"
src=
"https://img02.glsx.com.cn/weapp/resource/app-tape/media/common/pay.webp"
/>
<view
class=
"gradient-overlay"
></view>
</
template
>
<view
class=
"card-item"
v-for=
"item in list"
:key=
"item.id"
>
<template>
<image
v-if=
"item.vdQuotationPaymentDoc && item.vdQuotationPaymentDoc.paymentDocUrl"
class=
"image-box"
:src=
"item.vdQuotationPaymentDoc.paymentDocUrl"
/>
<image
v-else
class=
"image-box"
src=
"https://img02.glsx.com.cn/weapp/resource/app-tape/media/common/pay.webp"
/>
<view
class=
"gradient-overlay"
></view>
</
template
>
<view>
<view
class=
"name"
>
{{ nameHide(item.customerName) }}
</view>
<!-- <view class="name">{{ nameHide(item.customerName) }}</view> -->
<view
class=
"name"
>
{{ item.id }}
</view>
<view
class=
"goods-name"
>
{{ item.goodsName }}
</view>
<view
class=
"card-info"
>
<view
class=
"label"
>
车架号
</view>
...
...
@@ -35,38 +44,47 @@
</view>
<view
class=
"card-info"
>
<view
class=
"label"
>
实收金额
</view>
<view
class=
"price"
><view
class=
"flag"
>
¥
</view>
{{ accDiv(item.equityPrice) }}
</view>
<view
class=
"price"
>
<view
class=
"flag"
>
¥
</view>
{{ accDiv(item.equityPrice) }}
</view>
</view>
</view>
</view>
</view>
<view
class=
"end-text"
v-if=
"historyList.length > 0 && isEnd"
>
我是一个有底线的人
</view>
<view
class=
"end-text"
v-if=
"list.length > 0 && isEnd"
>
我是一个有底线的人
</view>
</scroll-view>
</template>
<
template
v-else
>
<view
class=
"no-data"
>
<glsx-image
class=
"no-data-img"
src=
"media/no-data.png"
mode=
"scaleToFill"
/>
<glsx-image
class=
"no-data-img"
src=
"media/no-data.png"
mode=
"scaleToFill"
/>
<view
class=
"no-data-text"
>
暂无数据
</view>
</view>
</
template
>
</view>
</template>
<
script
>
import
utils
from
'@/utils/utils'
;
import
Record
from
"@/mixin/record"
;
export
default
{
name
:
'History'
,
mixins
:
[
Record
],
props
:
{
title
:
String
,
madiaId
:
Number
,
show
:
Boolean
,
},
data
()
{
data
()
{
return
{
historyList
:
[],
isEnd
:
false
,
pageNum
:
1
,
shopMerchantId
:
''
,
goodsName
:
null
}
...
...
@@ -79,15 +97,15 @@ export default {
immediate
:
true
,
handler
(
newval
)
{
this
.
pageNum
=
1
this
.
historyList
=
[]
this
.
list
=
uni
.
getStorageSync
(
`
${
this
.
shopMerchantId
}
-historyList`
)
}
},
watchCarModel
:
{
immediate
:
true
,
handler
(
newval
)
{
handler
(
newval
)
{
console
.
log
(
newval
)
if
(
this
.
madiaId
==
4
)
{
this
.
historyL
ist
=
uni
.
$storage
.
get
(
"historyList"
)
// this.l
ist = uni.$storage.get("historyList")
let
index
=
{
'问界M5'
:
'M5'
,
'问界M7'
:
'M7'
,
...
...
@@ -114,43 +132,33 @@ export default {
init
()
{
const
{
shopMerchantId
}
=
uni
.
$storage
.
get
(
"userInfo"
);
this
.
shopMerchantId
=
shopMerchantId
this
.
getQuotationList
(
true
);
if
(
this
.
pageNum
==
1
)
this
.
getQuotationList
(
);
},
async
getQuotationList
(
isSwitch
=
false
,
next
=
false
)
{
const
{
goodsName
,
shopMerchantId
,
pageNum
}
=
this
if
(
next
)
++
this
.
pageNum
const
data
=
await
uni
.
$api
.
commonApi
.
getQuotationList
({
async
getQuotationList
()
{
const
{
goodsName
,
shopMerchantId
,
pageNum
,
pageSize
}
=
this
await
this
.
getList
(
'getQuotationList'
,
{
merchantIds
:
shopMerchantId
,
pageNum
,
pageSize
:
18
,
merchantId
:
shopMerchantId
,
pageSize
,
goodsName
,
orderStatus
:
3
,
goodsName
})
console
.
log
(
data
.
list
,
'====='
)
if
(
isSwitch
)
{
this
.
historyList
=
data
.
list
uni
.
$storage
.
set
(
"historyList"
,
data
.
list
)
this
.
isEnd
=
false
}
else
{
if
(
data
.
list
.
length
>
0
)
{
this
.
historyList
=
this
.
historyList
.
concat
(
data
.
list
)
this
.
isEnd
=
false
}
else
{
if
(
this
.
historyList
.
length
>
9
)
this
.
isEnd
=
true
}
}
if
(
pageNum
==
1
)
uni
.
setStorageSync
(
`
${
shopMerchantId
}
-historyList`
,
this
.
list
)
},
pageonReachBottom
()
{
console
.
log
(
'xiala '
)
this
.
getQuotationList
(
false
,
true
)
pageonReachBottom
()
{
let
{
pageNum
,
total
,
isEnd
,
pageSize
}
=
this
if
(
!
isEnd
)
isEnd
=
false
if
(
Math
.
ceil
(
total
/
pageSize
)
>
pageNum
)
{
this
.
pageNum
+=
1
this
.
getQuotationList
()
}
else
this
.
isEnd
=
true
},
// 脱敏
nameHide
(
name
)
{
nameHide
(
name
)
{
return
name
.
substring
(
0
,
1
)
+
'*'
;
},
accDiv
(
val
)
{
return
utils
.
accDiv
(
val
,
100
)
accDiv
(
val
)
{
return
utils
.
accDiv
(
val
||
0
,
100
)
},
}
}
...
...
@@ -178,19 +186,18 @@ export default {
z-index
:
2
;
}
.record-box
{
height
:
100%
;
padding-top
:
244
rpx
;
}
.card-list
{
display
:
grid
;
grid-template-columns
:
repeat
(
3
,
1
fr
);
gap
:
48
rpx
;
padding
:
0
64
rpx
48
rpx
;
.card-item
{
background-color
:
#
F7F9FF
;
background-color
:
#
f7f9ff
;
border-radius
:
32
rpx
;
height
:
372
rpx
;
box-sizing
:
border-box
;
...
...
@@ -202,14 +209,14 @@ export default {
.name
{
font-weight
:
500
;
font-size
:
32
rpx
;
color
:
#292
D
33
;
color
:
#292
d
33
;
}
.goods-name
{
margin-top
:
12
rpx
;
margin-bottom
:
16
rpx
;
font-weight
:
500
;
font-size
:
32
rpx
;
color
:
#2
C66F
7
;
color
:
#2
c66f
7
;
}
.card-info
{
display
:
flex
;
...
...
@@ -220,7 +227,7 @@ export default {
}
.label
{
font-size
:
24
rpx
;
color
:
#999
EA
8
;
color
:
#999
ea
8
;
width
:
136
rpx
;
}
.value
{
...
...
@@ -232,7 +239,7 @@ export default {
align-items
:
baseline
;
font-weight
:
500
;
font-size
:
32
rpx
;
color
:
#22
AC
38
;
color
:
#22
ac
38
;
.flag
{
font-size
:
24
rpx
;
}
...
...
@@ -248,18 +255,18 @@ export default {
z-index
:
-1
;
}
.gradient-overlay
{
z-index
:
-1
;
position
:
absolute
;
top
:
0
;
right
:
0
;
width
:
252
rpx
;
height
:
372
rpx
;
background
:
linear-gradient
(
to
left
,
rgba
(
247
,
249
,
255
,
0
)
0%
,
rgba
(
247
,
249
,
255
,
1
)
100%
);
}
z-index
:
-1
;
position
:
absolute
;
top
:
0
;
right
:
0
;
width
:
252
rpx
;
height
:
372
rpx
;
background
:
linear-gradient
(
to
left
,
rgba
(
247
,
249
,
255
,
0
)
0%
,
rgba
(
247
,
249
,
255
,
1
)
100%
);
}
}
}
}
...
...
pages/equity/index.vue
View file @
a9f46d1
...
...
@@ -9,7 +9,10 @@
@
backHome=
"backHome"
@
changeTab=
"changeTab"
>
<view
class=
"module-box"
slot=
"module"
>
<view
class=
"module-box"
slot=
"module"
>
<template
v-for=
"(i, index) in moduleList"
>
<view
:key=
"index"
...
...
@@ -44,10 +47,13 @@
/>
</
template
>
<
template
slot=
"content"
>
<novice-guide
@
nextStep=
"nextStep"
@
back=
"back"
/>
<novice-guide
@
nextStep=
"nextStep"
@
back=
"back"
/>
</
template
>
</home-frame>
<!--
<!--
<cover-view class="webview-container">
<web-view
@message="handlerMessage"
...
...
@@ -66,7 +72,7 @@ import HomeFrame from "@/components/HomeFrame/index.vue";
export
default
{
// mixins: [storge],
components
:
{
HomeFrame
,
detail
,
NoviceGuide
},
data
()
{
data
()
{
return
{
moduleList
:
[],
toolList
:
[],
...
...
@@ -77,7 +83,7 @@ export default {
recording
:
false
,
};
},
onBackPress
(
options
)
{
onBackPress
(
options
)
{
if
(
options
.
from
===
"backbutton"
)
{
// 物理返回按钮触发
// 阻止默认行为,即不执行页面返回
...
...
@@ -87,13 +93,13 @@ export default {
// 其他情况允许正常返回
return
false
;
},
onLoad
()
{
onLoad
()
{
const
mock_data
=
uni
.
$storage
.
get
(
"mock_data"
)
||
{};
this
.
moduleList
=
mock_data
.
moduleList
||
[];
this
.
toolList
=
mock_data
.
toolList
||
[];
this
.
get_Vehicle_Sales_Data
();
},
onShow
()
{
onShow
()
{
const
userInfo
=
uni
.
$storage
.
get
(
"userInfo"
);
if
(
!
userInfo
.
shopMerchantId
||
!
userInfo
.
shopMerchantName
)
{
uni
.
$storage
.
rm
(
"userInfo"
);
...
...
@@ -107,12 +113,12 @@ export default {
},
methods
:
{
...
mapMutations
(
"audio"
,
[
"setReceptionStatus"
]),
init
()
{
init
()
{
this
.
getSoure
();
this
.
findPayInfo
();
},
/**获取车型&销售数据 */
get_Vehicle_Sales_Data
()
{
get_Vehicle_Sales_Data
()
{
const
userInfo
=
uni
.
$storage
.
get
(
"userInfo"
),
storageCarBrandList
=
uni
.
$storage
.
get
(
"carBrandList"
),
storageEmployeeList
=
uni
.
$storage
.
get
(
"employeeList"
),
...
...
@@ -165,8 +171,8 @@ export default {
});
},
// 查询素材
async
getSoure
()
{
cons
t
{
moduleList
,
toolList
}
=
await
uni
.
$api
.
systemApi
.
getMockData
(
async
getSoure
()
{
le
t
{
moduleList
,
toolList
}
=
await
uni
.
$api
.
systemApi
.
getMockData
(
true
);
await
moduleList
.
map
(
async
(
e
)
=>
{
...
...
@@ -181,14 +187,21 @@ export default {
"url"
);
});
toolList
=
await
uni
.
$api
.
systemApi
.
imgToBase64
(
toolList
,
"shortTitleUrl"
);
this
.
moduleList
=
moduleList
;
this
.
toolList
=
toolList
;
uni
.
$api
.
systemApi
.
updateMockData
(
moduleList
,
"moduleList"
);
this
.
toolList
=
toolList
uni
.
$api
.
systemApi
.
updateMockData
({
moduleList
,
toolList
},
[
"moduleList"
,
'toolList'
]);
},
errorImg
(
index
)
{
errorImg
(
index
)
{
this
.
moduleList
[
index
].
showAlt
=
true
;
},
async
start
()
{
async
start
()
{
const
result
=
await
this
.
$permision
.
requestAndroidPermission
(
"android.permission.RECORD_AUDIO"
);
...
...
@@ -206,21 +219,21 @@ export default {
this
.
recording
=
true
;
},
toDetail
(
item
)
{
toDetail
(
item
)
{
this
.
chooseItem
=
item
;
this
.
$refs
.
home
.
previewRef
.
open
();
},
cancel
()
{
cancel
()
{
this
.
$refs
.
home
.
previewRef
.
close
();
},
preview
()
{
preview
()
{
let
{
id
}
=
this
.
chooseItem
;
this
.
type
=
"preview"
;
this
.
id
=
id
;
this
.
cancel
();
},
// 完成接待
done
(
e
)
{
done
(
e
)
{
this
.
$refs
.
home
.
finishRef
.
close
();
if
(
this
.
recording
)
this
.
$refs
.
home
.
stopAudio
();
this
.
recording
=
false
;
...
...
@@ -230,14 +243,14 @@ export default {
this
.
setReceptionStatus
(
e
);
},
1500
);
},
back
()
{
back
()
{
const
detailRef
=
this
.
$refs
.
detail
if
(
detailRef
.
showPayPage
)
return
detailRef
.
showPayPage
=
false
if
(
detailRef
.
showPayPage
)
return
detailRef
.
showPayPage
=
false
if
(
!
this
.
id
)
return
uni
.
navigateBack
();
if
(
this
.
type
!=
"preview"
)
return
this
.
$refs
.
home
.
finishRef
.
open
();
this
.
backHome
();
},
backHome
()
{
backHome
()
{
if
(
this
.
recording
)
this
.
$refs
.
home
.
stopAudio
(
true
);
this
.
$refs
.
home
.
finishRef
.
close
();
this
.
id
=
""
;
...
...
@@ -246,22 +259,22 @@ export default {
this
.
init
();
this
.
recording
=
false
;
},
nextStep
()
{
nextStep
()
{
let
{
id
}
=
this
.
moduleList
[
0
];
this
.
type
=
"preview"
;
this
.
id
=
id
;
},
clearHistory
()
{
clearHistory
()
{
this
.
$store
.
dispatch
(
"clearCustomerInfo"
);
this
.
$store
.
dispatch
(
"clearHistory"
);
this
.
$refs
.
home
.
setBooks
([]);
},
openStep
()
{
openStep
()
{
this
.
$refs
.
home
.
finishRef
.
close
();
this
.
$refs
.
detail
.
open
();
},
// 查询门店支付配置
async
findPayInfo
()
{
async
findPayInfo
()
{
const
{
shopMerchantId
}
=
uni
.
$storage
.
get
(
"userInfo"
);
const
data
=
await
uni
.
$api
.
commonApi
.
findPayInfo
({
merchantId
:
shopMerchantId
,
...
...
@@ -285,7 +298,7 @@ export default {
});
this
.
$store
.
dispatch
(
"setPaymentType"
,
paymentType
);
},
changeTab
(
index
)
{
changeTab
(
index
)
{
this
.
tabIndex
=
index
;
if
(
index
==
0
)
this
.
init
();
},
...
...
utils/cache/constantData.js
View file @
a9f46d1
...
...
@@ -19,6 +19,7 @@ export const STORAGE_OBJECTkEY = {
employeeList
:
"employeeList"
,
recordList
:
"recordList"
,
recordSuccessList
:
"recordSuccessList"
,
historyList
:
"historyList"
};
// export const IMG_VERSION = async () => {
...
...
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