Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-app-operator-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanbaoming
jiedao-app-operator-master
Commits
b96ea9d5
Commit
b96ea9d5
authored
Jul 09, 2022
by
Marcus
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
特价组件流程测试 approveId
parent
ddf16499
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
51 additions
and
27 deletions
+51
-27
offer.js
src/api/ecw/offer.js
+8
-0
index.js
src/router/index.js
+1
-1
specialDiscount.vue
src/views/ecw/offer/specialDiscount.vue
+42
-26
No files found.
src/api/ecw/offer.js
View file @
b96ea9d5
...
...
@@ -97,3 +97,11 @@ export function getOfferSpecial(offerProdId) {
})
}
// 特价详情
export
function
getOfferSpecialByApproveId
(
approveId
)
{
return
request
({
url
:
'
/ecw/offer/special/info?approveId=
'
+
approveId
,
method
:
'
get
'
})
}
src/router/index.js
View file @
b96ea9d5
...
...
@@ -275,7 +275,7 @@ export const constantRoutes = [
meta
:
{
title
:
'
特价申请
'
,
icon
:
''
,
activeMenu
:
'
/offer/index
'
}
},
{
path
:
'
discount/:
i
d(
\\
d+)
'
,
path
:
'
discount/:
offerProdI
d(
\\
d+)
'
,
component
:
(
resolve
)
=>
import
(
'
@/views/ecw/offer/specialDiscount
'
),
props
:
true
,
name
:
'
discount
'
,
...
...
src/views/ecw/offer/specialDiscount.vue
View file @
b96ea9d5
...
...
@@ -33,11 +33,12 @@
</
template
>
<
script
>
import
{
createOfferSpecial
,
getOffer
,
getOfferSpecial
}
from
"
@/api/ecw/offer
"
import
{
createOfferSpecial
,
getOffer
,
getOfferSpecial
,
getOfferSpecialByApproveId
}
from
"
@/api/ecw/offer
"
export
default
{
name
:
"
specialDiscount
"
,
props
:
{
offerProdId
:
String
,
id
:
Number
,
readonly
:
{
type
:
Boolean
,
...
...
@@ -45,19 +46,24 @@ export default {
}
},
created
()
{
// if(this.offerId){
// this.form.offerId = this.offerId
// }
// 临时
if
(
this
.
$route
.
query
.
offerId
){
this
.
form
.
offerId
=
this
.
$route
.
query
.
offerId
-
0
// this.getOffer()
}
this
.
form
.
offerProdId
=
this
.
id
// if(this.offerProdId){
// }else if(this.$route.query.offerProdId){
// this.form.offerProdId = this.$route.query.offerProdId - 0
// }
if
(
this
.
form
.
offerId
)
this
.
getOffer
()
this
.
getOfferSpecial
()
// 查看详情,列表进来的
if
(
this
.
offerProdId
){
this
.
form
.
offerProdId
=
this
.
offerProdId
-
0
this
.
getOfferSpecial
()
}
// 从流程查看详情
if
(
this
.
id
)
this
.
getOfferSpecialByApproveId
()
},
data
()
{
return
{
...
...
@@ -78,27 +84,37 @@ export default {
this
.
$message
.
success
(
r
.
msg
||
'
提交成功
'
)
})
},
getOffer
(){
getOffer
(
this
.
form
.
offerId
).
then
(
r
=>
{
const
line
=
r
.
data
.
offerProdRespVOList
.
find
(
e
=>
e
.
offerProdId
=
this
.
form
.
offerProdId
)
console
.
log
(
line
)
const
{
clearanceFreight
,
seaFreight
}
=
line
this
.
form
=
{
...
this
.
form
,
clearanceFreight
,
seaFreight
// getOffer(){
// getOffer(this.form.offerId).then(r => {
// const line = r.data.offerProdRespVOList.find(e => e.offerProdId = this.form.offerProdId)
// console.log(line)
// const {
// clearanceFreight,
// seaFreight
// } = line
// this.form = {
// ...this.form,
// clearanceFreight,
// seaFreight
// }
// })
// },
getOfferSpecial
(){
getOfferSpecial
(
this
.
form
.
offerProdId
).
then
(
r
=>
{
this
.
follow
=
r
.
data
if
(
!
this
.
form
.
offerId
)
{
this
.
form
.
offerId
=
r
.
data
.
offerId
}
})
},
getOfferSpecial
(){
getOfferSpecial
(
this
.
form
.
offerProdI
d
).
then
(
r
=>
{
getOfferSpecial
ByApproveId
(){
getOfferSpecial
ByApproveId
(
this
.
i
d
).
then
(
r
=>
{
this
.
follow
=
r
.
data
if
(
!
this
.
form
.
offerId
)
{
this
.
form
.
offerId
=
r
.
data
.
offerId
this
.
form
.
offerProdId
=
r
.
data
.
offerProdId
this
.
form
.
clearanceFreight
=
this
.
form
.
offerSpecialApplyVO
.
clearanceFreight
this
.
form
.
seaFreight
=
this
.
form
.
offerSpecialApplyVO
.
seaFreight
}
})
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment