Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-life-h5-ailipay
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 b6035776
authored
Jan 15, 2022
by
李伟康
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
commit
1 parent
fc56682c
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
68 additions
and
13 deletions
src/components/SearchBox.vue
src/components/Tab.vue
src/router/routes.js
src/views/coupon/goodsVerification.vue
src/views/coupon/verificationDetail.vue
src/views/coupon/verificationList.vue
src/components/SearchBox.vue
View file @
b603577
...
@@ -21,7 +21,17 @@
...
@@ -21,7 +21,17 @@
<
script
type=
'text/ecmascript-6'
>
<
script
type=
'text/ecmascript-6'
>
export
default
{
export
default
{
name
:
'SearchBox'
,
name
:
'SearchBox'
,
props
:
[
'keyword'
],
props
:
{
keyword
:
String
,
index
:
{
type
:
Number
,
default
:
0
},
updata
:
{
type
:
Number
,
default
:
new
Date
().
getTime
()
}
},
data
()
{
data
()
{
return
{
return
{
value
:
0
,
value
:
0
,
...
@@ -33,6 +43,11 @@ export default {
...
@@ -33,6 +43,11 @@ export default {
]
]
}
}
},
},
watch
:
{
'updata'
(
n
)
{
this
.
value
=
this
.
index
}
},
mounted
()
{
mounted
()
{
},
},
methods
:
{
methods
:
{
...
...
src/components/Tab.vue
View file @
b603577
...
@@ -46,7 +46,6 @@ export default {
...
@@ -46,7 +46,6 @@ export default {
},
},
watch
:
{
watch
:
{
'index'
(
n
)
{
'index'
(
n
)
{
console
.
log
(
n
)
this
.
tabIndex
=
n
this
.
tabIndex
=
n
},
},
'updata'
(
n
)
{
'updata'
(
n
)
{
...
...
src/router/routes.js
View file @
b603577
...
@@ -9,19 +9,22 @@ const pages = [
...
@@ -9,19 +9,22 @@ const pages = [
{
{
name
:
'verificationList'
,
name
:
'verificationList'
,
meta
:
{
meta
:
{
title
:
'核销列表'
title
:
'核销列表'
,
keepAlive
:
true
}
}
},
},
{
{
name
:
'verificationDetail'
,
name
:
'verificationDetail'
,
meta
:
{
meta
:
{
title
:
'核销详情'
title
:
'核销详情'
,
keepAlive
:
true
}
}
},
},
{
{
name
:
'goodsVerification'
,
name
:
'goodsVerification'
,
meta
:
{
meta
:
{
title
:
'核销订单'
title
:
'核销订单'
,
keepAlive
:
true
}
}
}
}
]
]
...
...
src/views/coupon/goodsVerification.vue
View file @
b603577
...
@@ -137,6 +137,7 @@ export default {
...
@@ -137,6 +137,7 @@ export default {
submit
()
{
submit
()
{
let
{
verficationCode
}
=
this
.
getParams
()
let
{
verficationCode
}
=
this
.
getParams
()
this
.
showLoading
()
this
.
showLoading
()
this
.
$route
.
params
.
isGoods
=
true
shopmallApi
shopmallApi
.
verficationGoods
(
verficationCode
)
.
verficationGoods
(
verficationCode
)
.
then
(
res
=>
{
.
then
(
res
=>
{
...
...
src/views/coupon/verificationDetail.vue
View file @
b603577
...
@@ -83,7 +83,7 @@ const couponObj = [
...
@@ -83,7 +83,7 @@ const couponObj = [
},
},
{
{
label
:
'类型'
,
label
:
'类型'
,
format
(
item
)
{
format
(
item
)
{
return
window
.
$discountType
[
item
.
discountType
]
return
window
.
$discountType
[
item
.
discountType
]
}
}
},
},
...
@@ -93,7 +93,7 @@ const couponObj = [
...
@@ -93,7 +93,7 @@ const couponObj = [
},
},
{
{
label
:
'发放时间'
,
label
:
'发放时间'
,
format
(
item
)
{
format
(
item
)
{
return
new
Date
(
item
.
issueDate
).
format
(
'yyyy年MM月dd日'
)
return
new
Date
(
item
.
issueDate
).
format
(
'yyyy年MM月dd日'
)
}
}
}
}
...
@@ -109,7 +109,7 @@ const vipObj = [
...
@@ -109,7 +109,7 @@ const vipObj = [
},
},
{
{
label
:
'有效期'
,
label
:
'有效期'
,
format
(
item
)
{
format
(
item
)
{
let
{
effectiveType
}
=
item
let
{
effectiveType
}
=
item
let
str
=
''
let
str
=
''
if
(
effectiveType
==
1
)
str
=
`
${
item
.
effectiveDays
}
天`
if
(
effectiveType
==
1
)
str
=
`
${
item
.
effectiveDays
}
天`
...
@@ -122,7 +122,7 @@ const vipObj = [
...
@@ -122,7 +122,7 @@ const vipObj = [
export
default
{
export
default
{
name
:
''
,
name
:
''
,
mixins
:
[
discountTypeMixin
],
mixins
:
[
discountTypeMixin
],
data
()
{
data
()
{
return
{
return
{
detail
:
{},
detail
:
{},
customerObj
:
[
customerObj
:
[
...
@@ -136,7 +136,7 @@ export default {
...
@@ -136,7 +136,7 @@ export default {
},
},
{
{
label
:
'领取时间'
,
label
:
'领取时间'
,
format
(
item
)
{
format
(
item
)
{
return
new
Date
(
item
.
receiveTime
).
format
(
'yyyy年MM月dd日'
)
return
new
Date
(
item
.
receiveTime
).
format
(
'yyyy年MM月dd日'
)
}
}
}
}
...
@@ -146,7 +146,7 @@ export default {
...
@@ -146,7 +146,7 @@ export default {
flag
:
false
flag
:
false
}
}
},
},
mounted
()
{
mounted
()
{
let
{
verficationCode
}
=
this
.
getParams
()
let
{
verficationCode
}
=
this
.
getParams
()
this
.
showLoading
()
this
.
showLoading
()
couponApi
.
scan
({
verficationCode
}).
then
(
res
=>
{
couponApi
.
scan
({
verficationCode
}).
then
(
res
=>
{
...
@@ -158,7 +158,9 @@ export default {
...
@@ -158,7 +158,9 @@ export default {
})
})
},
},
methods
:
{
methods
:
{
submit
()
{
submit
()
{
let
{
detail
:
{
discountType
}
}
=
this
this
.
$route
.
params
.
discountType
=
discountType
let
{
verficationCode
}
=
this
let
{
verficationCode
}
=
this
this
.
showLoading
()
this
.
showLoading
()
couponApi
.
verificationCode
({
verficationCode
}).
then
(
res
=>
{
couponApi
.
verificationCode
({
verficationCode
}).
then
(
res
=>
{
...
...
src/views/coupon/verificationList.vue
View file @
b603577
...
@@ -4,6 +4,8 @@
...
@@ -4,6 +4,8 @@
@
change=
"changeType"
@
change=
"changeType"
@
search=
"search"
@
search=
"search"
:keyword=
"userName"
:keyword=
"userName"
:index=
"type"
:updata=
"updata"
></search-box>
></search-box>
<tab
<tab
:list=
"tab[type]"
:list=
"tab[type]"
...
@@ -228,11 +230,43 @@ export default {
...
@@ -228,11 +230,43 @@ export default {
]
]
}
}
},
},
mounted
()
{
beforeRouteEnter
(
to
,
from
,
next
)
{
console
.
log
(
'from'
,
from
)
let
{
params
:
{
discountType
,
isGoods
}
}
=
from
next
(
vm
=>
{
if
(
discountType
)
{
if
(
discountType
==
7
)
{
vm
.
changeType
(
3
)
vm
.
getUserCouponList
({
userStatus
:
1
,
type
:
3
})
}
else
{
vm
.
changeType
(
0
)
vm
.
getUserCouponList
({
userStatus
:
0
,
type
:
0
})
vm
.
getUserCouponList
({
userStatus
:
1
,
type
:
0
})
}
}
if
(
isGoods
)
{
vm
.
changeType
(
2
)
vm
.
getGoodsVerficationList
(
1
)
}
})
},
activated
()
{
this
.
getTabNum
()
this
.
getTabNum
()
window
.
$wx
=
wxConfig
window
.
$wx
=
wxConfig
window
.
$wx
.
init
([
'scanQRCode'
])
window
.
$wx
.
init
([
'scanQRCode'
])
},
},
mounted
()
{
},
methods
:
{
methods
:
{
getTabNum
()
{
getTabNum
()
{
this
.
showLoading
()
this
.
showLoading
()
...
@@ -401,6 +435,7 @@ export default {
...
@@ -401,6 +435,7 @@ export default {
}
}
},
},
scan
()
{
scan
()
{
// let resultStr = 't=2&c=3483845737948516352'
window
.
$wx
.
scanQRCode
(
1
).
then
(({
resultStr
})
=>
{
window
.
$wx
.
scanQRCode
(
1
).
then
(({
resultStr
})
=>
{
let
name
=
'verificationDetail'
let
name
=
'verificationDetail'
let
[
t
,
c
]
=
resultStr
.
split
(
'&'
)
let
[
t
,
c
]
=
resultStr
.
split
(
'&'
)
...
...
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