Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cloud-platform-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
youjj
cloud-platform-ui
Commits
5a08a58c
Commit
5a08a58c
authored
Aug 09, 2019
by
denghr
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加海报背景,优惠券列表加一个删除
parent
bc52c083
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
120 additions
and
4 deletions
+120
-4
cunponManagements.js
src/api/cunponManagements.js
+11
-0
conponList.vue
src/views/cunponManagements/conponList.vue
+33
-1
oneTourModal.vue
src/views/tourManage/modal/oneTourModal.vue
+39
-2
oneType.vue
src/views/vehicleType/modal/oneType.vue
+37
-1
No files found.
src/api/cunponManagements.js
View file @
5a08a58c
...
@@ -79,4 +79,15 @@ export function giveObj(obj) {
...
@@ -79,4 +79,15 @@ export function giveObj(obj) {
method
:
'POST'
,
method
:
'POST'
,
data
:
obj
data
:
obj
});
});
}
/**
* 优惠券列表删除
* @param query
*/
export
function
delObjOne
(
id
)
{
return
fetch
({
url
:
'/api/activity/admin/user_coupon/'
+
id
,
method
:
'delete'
})
}
}
\ No newline at end of file
src/views/cunponManagements/conponList.vue
View file @
5a08a58c
...
@@ -76,6 +76,11 @@
...
@@ -76,6 +76,11 @@
<span
v-if=
"scope.row.isUse==0"
>
未使用
</span>
<span
v-if=
"scope.row.isUse==0"
>
未使用
</span>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
<el-table-column
align=
"center"
label=
"操作"
width=
"150"
fixed=
"right"
>
<
template
scope=
"scope"
>
<el-button
class=
"el-button el-button--text el-button--small"
style=
"color:red;"
size=
"small"
@
click=
"deleteHandler(scope.row)"
>
删除
</el-button>
</
template
>
</el-table-column>
</el-table>
</el-table>
<div
v-show=
"!listLoading"
class=
"pagination-container"
>
<div
v-show=
"!listLoading"
class=
"pagination-container"
>
<el-pagination
@
size-change=
"handleSizeChange"
@
current-change=
"handleCurrentChange"
<el-pagination
@
size-change=
"handleSizeChange"
@
current-change=
"handleCurrentChange"
...
@@ -139,7 +144,8 @@
...
@@ -139,7 +144,8 @@
import
{
import
{
getTitle
,
getTitle
,
getCouponList
,
getCouponList
,
giveObj
giveObj
,
delObjOne
}
from
'api/cunponManagements'
;
}
from
'api/cunponManagements'
;
import
Element1
from
"../admin/menu/components/element"
;
import
Element1
from
"../admin/menu/components/element"
;
import
ElRow
from
"element-ui/packages/row/src/row"
;
import
ElRow
from
"element-ui/packages/row/src/row"
;
...
@@ -294,6 +300,32 @@
...
@@ -294,6 +300,32 @@
}
}
});
});
},
},
deleteHandler
(
row
){
this
.
$confirm
(
'确定删除吗?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(()
=>
{
delObjOne
(
row
.
id
).
then
(
response
=>
{
if
(
response
.
status
==
200
)
{
this
.
$notify
({
title
:
'成功'
,
message
:
'删除成功'
,
type
:
'success'
,
duration
:
2000
});
this
.
getList
();
}
else
{
this
.
$notify
({
title
:
'失败'
,
message
:
response
.
message
,
type
:
'error'
,
duration
:
2000
});
}
});
})
},
giveCunpon
(){
giveCunpon
(){
this
.
giveDialogVisible
=
true
;
this
.
giveDialogVisible
=
true
;
}
}
...
...
src/views/tourManage/modal/oneTourModal.vue
View file @
5a08a58c
...
@@ -148,6 +148,21 @@
...
@@ -148,6 +148,21 @@
<i
v-else-if=
"!imgFlag"
class=
"el-icon-plus avatar-uploader-icon"
style=
"lineHeight:100px;width:300px;height: 100px;border: 1px dashed #ccc;"
></i>
<i
v-else-if=
"!imgFlag"
class=
"el-icon-plus avatar-uploader-icon"
style=
"lineHeight:100px;width:300px;height: 100px;border: 1px dashed #ccc;"
></i>
</el-upload>
</el-upload>
</el-form-item>
</el-form-item>
<el-form-item
label=
"海报背景"
:style=
"
{display:'block'}">
<el-upload
class=
"upload-demo"
:headers=
"getHeaderWithToken"
:action=
"BASE_API+'/api/universal/file/app/unauth/admin/upload'"
:show-file-list=
"false"
:on-success=
"handlePosterSuccess"
:on-progress=
"uploadPosterProcess"
list-type=
"picture"
>
<div
slot=
"tip"
class=
"el-upload__tip"
>
<span
style=
"color: red;"
>
建议尺寸:320*228px
</span></div>
<el-progress
v-show=
"imgPosterFlag == true"
type=
"circle"
:percentage=
"percent_poster"
style=
"margin-top: 20px"
></el-progress>
<img
v-if=
"$utils.isString(form.posterBackground) && !$utils.isEmpty(form.posterBackground)&& !imgPosterFlag"
:src=
"form.posterBackground"
style=
"width:300px;max-height:300px;"
>
<i
v-else-if=
"!imgPosterFlag"
class=
"el-icon-plus avatar-uploader-icon"
style=
"lineHeight:100px;width:300px;height: 100px;border: 1px dashed #ccc;"
></i>
</el-upload>
</el-form-item>
<el-form-item
label=
"轮播图"
:style=
"
{display:'block'}">
<el-form-item
label=
"轮播图"
:style=
"
{display:'block'}">
<el-upload
<el-upload
class=
"upload-demo"
class=
"upload-demo"
...
@@ -258,6 +273,8 @@ import ElRow from "element-ui/packages/row/src/row";
...
@@ -258,6 +273,8 @@ import ElRow from "element-ui/packages/row/src/row";
},
},
data
()
{
data
()
{
return
{
return
{
imgPosterFlag
:
false
,
percent_poster
:
0
,
BASE_API
:
process
.
env
.
BASE_API
,
BASE_API
:
process
.
env
.
BASE_API
,
config
:
{
config
:
{
initialFrameWidth
:
null
,
initialFrameWidth
:
null
,
...
@@ -296,6 +313,7 @@ import ElRow from "element-ui/packages/row/src/row";
...
@@ -296,6 +313,7 @@ import ElRow from "element-ui/packages/row/src/row";
isMember
:
"0"
,
//是否是会员商品
isMember
:
"0"
,
//是否是会员商品
tagDTOS
:
[],
//旅行标签
tagDTOS
:
[],
//旅行标签
bannerDTOS
:[],
//banner轮播
bannerDTOS
:[],
//banner轮播
posterBackground
:
''
,
//海报背景
},
},
showDestinationVisible
:
false
,
//编辑目的地
showDestinationVisible
:
false
,
//编辑目的地
showPathWayVisible
:
false
,
//编辑途径地
showPathWayVisible
:
false
,
//编辑途径地
...
@@ -523,7 +541,8 @@ import ElRow from "element-ui/packages/row/src/row";
...
@@ -523,7 +541,8 @@ import ElRow from "element-ui/packages/row/src/row";
bannerDTOS
:
this
.
form
.
bannerDTOS
,
//banner轮播图
bannerDTOS
:
this
.
form
.
bannerDTOS
,
//banner轮播图
siteDTOS
:
siteDTOS
,
//出发地type=0,途径地type=1,目的地type=2
siteDTOS
:
siteDTOS
,
//出发地type=0,途径地type=1,目的地type=2
priceDTOS
:
this
.
form
.
tourDepartTimeVo
,
//活动日期
priceDTOS
:
this
.
form
.
tourDepartTimeVo
,
//活动日期
tagDTOS
:
tagDTOS
//旅游标签
tagDTOS
:
tagDTOS
,
//旅游标签
posterBackground
:
this
.
form
.
posterBackground
,
//海报背景
};
};
console
.
log
(
params
);
console
.
log
(
params
);
goodsEdit
(
params
).
then
(
response
=>
{
goodsEdit
(
params
).
then
(
response
=>
{
...
@@ -643,7 +662,8 @@ import ElRow from "element-ui/packages/row/src/row";
...
@@ -643,7 +662,8 @@ import ElRow from "element-ui/packages/row/src/row";
bannerDTOS
:
this
.
form
.
bannerDTOS
,
//banner轮播图
bannerDTOS
:
this
.
form
.
bannerDTOS
,
//banner轮播图
siteDTOS
:
siteDTOS
,
//出发地type=0,途径地type=1,目的地type=2
siteDTOS
:
siteDTOS
,
//出发地type=0,途径地type=1,目的地type=2
priceDTOS
:
this
.
form
.
tourDepartTimeVo
,
//活动日期
priceDTOS
:
this
.
form
.
tourDepartTimeVo
,
//活动日期
tagDTOS
:
tagDTOS
//旅游标签
tagDTOS
:
tagDTOS
,
//旅游标签
posterBackground
:
this
.
form
.
posterBackground
,
//海报背景
};
};
console
.
log
(
params
);
console
.
log
(
params
);
console
.
log
(
this
.
form
);
console
.
log
(
this
.
form
);
...
@@ -931,6 +951,22 @@ import ElRow from "element-ui/packages/row/src/row";
...
@@ -931,6 +951,22 @@ import ElRow from "element-ui/packages/row/src/row";
this
.
imgFlag
=
false
;
this
.
imgFlag
=
false
;
this
.
form
.
cover
=
res
.
data
;
this
.
form
.
cover
=
res
.
data
;
},
},
/**
* 海报背景上传
* **/
handlePosterSuccess
(
res
,
file
){
this
.
percent_poster
=
0
;
this
.
imgPosterFlag
=
false
;
this
.
form
.
posterBackground
=
res
.
data
;
},
/**
* 海报背景图上传进度
* */
uploadPosterProcess
(
event
,
file
,
fileList
)
{
this
.
imgPosterFlag
=
true
;
console
.
log
(
event
.
percent
);
this
.
percent_poster
=
Math
.
floor
(
event
.
percent
);
},
/**
/**
* banner上传
* banner上传
* */
* */
...
@@ -973,6 +1009,7 @@ import ElRow from "element-ui/packages/row/src/row";
...
@@ -973,6 +1009,7 @@ import ElRow from "element-ui/packages/row/src/row";
tagDTOS
:
[],
//旅行标签
tagDTOS
:
[],
//旅行标签
bannerDTOS
:[],
//banner轮播
bannerDTOS
:[],
//banner轮播
tourDepartTimeVo
:[],
//活动时间
tourDepartTimeVo
:[],
//活动时间
posterBackground
:
''
,
//海报背景
},
},
this
.
showDestinationVisible
=
false
,
//编辑目的地
this
.
showDestinationVisible
=
false
,
//编辑目的地
this
.
showPathWayVisible
=
false
,
//编辑途径地
this
.
showPathWayVisible
=
false
,
//编辑途径地
...
...
src/views/vehicleType/modal/oneType.vue
View file @
5a08a58c
...
@@ -149,6 +149,21 @@
...
@@ -149,6 +149,21 @@
<i
v-else-if=
"!imgFlag"
class=
"el-icon-plus avatar-uploader-icon"
style=
"lineHeight:100px;width:300px;height: 100px;border: 1px dashed #ccc;"
></i>
<i
v-else-if=
"!imgFlag"
class=
"el-icon-plus avatar-uploader-icon"
style=
"lineHeight:100px;width:300px;height: 100px;border: 1px dashed #ccc;"
></i>
</el-upload>
</el-upload>
</el-form-item>
</el-form-item>
<el-form-item
label=
"海报背景"
:style=
"
{display:'block'}">
<el-upload
class=
"upload-demo"
:headers=
"getHeaderWithToken"
:action=
"BASE_API+'/api/universal/file/app/unauth/admin/upload'"
:show-file-list=
"false"
:on-success=
"handlePosterSuccess"
:on-progress=
"uploadPosterProcess"
list-type=
"picture"
>
<div
slot=
"tip"
class=
"el-upload__tip"
>
<span
style=
"color: red;"
>
建议尺寸:320*228px
</span></div>
<el-progress
v-show=
"imgPosterFlag == true"
type=
"circle"
:percentage=
"percent_poster"
style=
"margin-top: 20px"
></el-progress>
<img
v-if=
"$utils.isString(form.posterBackground) && !$utils.isEmpty(form.posterBackground)&& !imgPosterFlag"
:src=
"form.posterBackground"
style=
"width:300px;max-height:300px;"
>
<i
v-else-if=
"!imgPosterFlag"
class=
"el-icon-plus avatar-uploader-icon"
style=
"lineHeight:100px;width:300px;height: 100px;border: 1px dashed #ccc;"
></i>
</el-upload>
</el-form-item>
<el-form-item
label=
"轮播图"
:style=
"
{display:'block'}">
<el-form-item
label=
"轮播图"
:style=
"
{display:'block'}">
<el-upload
<el-upload
class=
"upload-demo"
class=
"upload-demo"
...
@@ -256,6 +271,8 @@ import UE from '../../modal/Ueditor';//百度ue富文本
...
@@ -256,6 +271,8 @@ import UE from '../../modal/Ueditor';//百度ue富文本
},
},
data
()
{
data
()
{
return
{
return
{
imgPosterFlag
:
false
,
percent_poster
:
0
,
BASE_API
:
process
.
env
.
BASE_API
,
BASE_API
:
process
.
env
.
BASE_API
,
percent
:
0
,
//上传进度
percent
:
0
,
//上传进度
imgFlag
:
false
,
imgFlag
:
false
,
...
@@ -429,13 +446,29 @@ import UE from '../../modal/Ueditor';//百度ue富文本
...
@@ -429,13 +446,29 @@ import UE from '../../modal/Ueditor';//百度ue富文本
console
.
log
(
event
.
percent
);
console
.
log
(
event
.
percent
);
this
.
percent
=
Math
.
floor
(
event
.
percent
);
this
.
percent
=
Math
.
floor
(
event
.
percent
);
},
},
/**
* 海报背景图上传进度
* */
uploadPosterProcess
(
event
,
file
,
fileList
)
{
this
.
imgPosterFlag
=
true
;
console
.
log
(
event
.
percent
);
this
.
percent_poster
=
Math
.
floor
(
event
.
percent
);
},
/**
/**
* 封面图上传
* 封面图上传
* **/
* **/
handleAvatarSuccess
(
res
,
file
){
handleAvatarSuccess
(
res
,
file
){
this
.
percent
=
0
;
this
.
percent
=
0
;
this
.
imgFlag
=
false
;
this
.
imgFlag
=
false
;
this
.
form
.
cover_pic
=
res
.
data
;
this
.
form
.
coverPic
=
res
.
data
;
},
/**
* 海报背景上传
* **/
handlePosterSuccess
(
res
,
file
){
this
.
percent_poster
=
0
;
this
.
imgPosterFlag
=
false
;
this
.
form
.
posterBackground
=
res
.
data
;
},
},
/**
/**
* 创建
* 创建
...
@@ -451,6 +484,7 @@ import UE from '../../modal/Ueditor';//百度ue富文本
...
@@ -451,6 +484,7 @@ import UE from '../../modal/Ueditor';//百度ue富文本
modelParam
:
JSON
.
stringify
(
this
.
form
.
modelParam
),
//房车参数
modelParam
:
JSON
.
stringify
(
this
.
form
.
modelParam
),
//房车参数
picture
:
this
.
form
.
picture
,
//轮播图
picture
:
this
.
form
.
picture
,
//轮播图
coverPic
:
this
.
form
.
coverPic
,
//封面图
coverPic
:
this
.
form
.
coverPic
,
//封面图
posterBackground
:
this
.
form
.
posterBackground
,
//海报背景
price
:
this
.
form
.
price
,
//租车价格
price
:
this
.
form
.
price
,
//租车价格
deposit
:
this
.
form
.
deposit
,
//总押金
deposit
:
this
.
form
.
deposit
,
//总押金
vioDeposit
:
this
.
form
.
vioDeposit
,
vioDeposit
:
this
.
form
.
vioDeposit
,
...
@@ -498,6 +532,7 @@ import UE from '../../modal/Ueditor';//百度ue富文本
...
@@ -498,6 +532,7 @@ import UE from '../../modal/Ueditor';//百度ue富文本
picture
:
this
.
form
.
picture
,
//轮播图
picture
:
this
.
form
.
picture
,
//轮播图
price
:
this
.
form
.
price
,
//租车价格
price
:
this
.
form
.
price
,
//租车价格
coverPic
:
this
.
form
.
coverPic
,
//封面图
coverPic
:
this
.
form
.
coverPic
,
//封面图
posterBackground
:
this
.
form
.
posterBackground
,
//海报背景
deposit
:
this
.
form
.
deposit
,
//总押金
deposit
:
this
.
form
.
deposit
,
//总押金
vioDeposit
:
this
.
form
.
vioDeposit
,
vioDeposit
:
this
.
form
.
vioDeposit
,
hotSign
:
this
.
form
.
hotSign
,
//热门车型
hotSign
:
this
.
form
.
hotSign
,
//热门车型
...
@@ -835,6 +870,7 @@ import UE from '../../modal/Ueditor';//百度ue富文本
...
@@ -835,6 +870,7 @@ import UE from '../../modal/Ueditor';//百度ue富文本
rentDiscountStatus
:
"0"
,
//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值
rentDiscountStatus
:
"0"
,
//租车优惠状态 0--没有优惠;1--会员折扣;2--固定值
rentDiscountPrice
:
""
,
//租车优惠价格 固定优化价格
rentDiscountPrice
:
""
,
//租车优惠价格 固定优化价格
buyPrice
:
0
,
//购买价格
buyPrice
:
0
,
//购买价格
posterBackground
:
''
,
//海报背景
}
}
}
}
}
}
...
...
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