+ 全部
生效中
已过期
@@ -60,13 +61,12 @@
align="center"
label="优惠券名称">
-
- {{scope.row.couponType | getType}}
+ {{scope.row.effectType | getType}}
-->
+
+
+
+
+
+
- 修改
+ 修改
删除
@@ -154,7 +170,7 @@ import commentsListVue from '../book/commentsList.vue'
couponRange: '',
couponType:''
},
- currentState:'0', // "currentState":""//当前状态 0 发放中 1结束
+ currentState:'', // "currentState":""//当前状态 0 发放中 1结束
dataList: [],
rangList: global.rangList,
TypeList: global.TypeList,
@@ -197,9 +213,34 @@ import commentsListVue from '../book/commentsList.vue'
activated () {
this.getDataList()
},
- methods: {
-
-
+ methods: {
+ // 修改优惠券状态
+ changeStateHandle (id, state) {
+ console.log('进来了')
+ this.$http({
+ url: this.$http.adornUrl('/common/coupon/updateCouponState'),
+ method: 'post',
+ data: this.$http.adornData({
+ id: id,
+ currentState: state
+ })
+ }).then(({data}) => {
+ if (data && data.code === 0) {
+ this.$message({
+ message: '操作成功',
+ type:'success',
+ duration: 1500,
+ onClose: () => {
+ this.getDataList()
+ }
+ })
+ } else {
+ this.$message.error(data.msg)
+ }
+ }).catch((e) => {
+ this.$message.error(e.msg)
+ })
+ },
handleClick(){
console.log(this.currentState)
this.pageIndex = 1
@@ -251,10 +292,11 @@ import commentsListVue from '../book/commentsList.vue'
this.dataListSelections = val
},
// 新增 / 修改
- addOrUpdateHandle (id) {
- this.addOrUpdateVisible = true
- this.$nextTick(() => {
- this.$refs.addOrUpdate.init(id)
+ addOrUpdateHandle (id) {
+ this.addOrUpdateVisible = true
+ this.$nextTick(() => {
+ this.$refs.addOrUpdate.init(id)
+ // this.addOrUpdateVisible = true
})
},
// 删除
diff --git a/src/views/modules/coupon/userCouponList.vue b/src/views/modules/coupon/userCouponList.vue
index 28e6649..db8afe8 100644
--- a/src/views/modules/coupon/userCouponList.vue
+++ b/src/views/modules/coupon/userCouponList.vue
@@ -2,7 +2,7 @@
- {{scope.row.couponEntity.couponType | getType}}
+ {{scope.row.couponEntity.effectType | getType}}
@@ -306,11 +306,11 @@ export default {
dialogHandleClose(){
this.youVisible = false
this.youForm.ids = undefined
- this.youForm.remark = ''
+ // this.youForm.remark = ''
},
surYou() {
- if(this.youForm.ids.length == 0){
+ if(!this.youForm.ids){
this.$message({
message: '请选择优惠券',
type: 'warning',
diff --git a/src/views/modules/course/course-add-or-update.vue b/src/views/modules/course/course-add-or-update.vue
index a34ca86..ceed1ea 100644
--- a/src/views/modules/course/course-add-or-update.vue
+++ b/src/views/modules/course/course-add-or-update.vue
@@ -385,7 +385,8 @@ export default {
// console.log('editor ready!', quill)
},
init(row) {
- console.log("11111", row);
+ console.log("进来了吗?", row);
+ // if(!)
if (row && row.id) {
this.courseId = row.id
this.$http
diff --git a/src/views/modules/shop/proCouponList.vue b/src/views/modules/shop/proCouponList.vue
new file mode 100644
index 0000000..c52e09a
--- /dev/null
+++ b/src/views/modules/shop/proCouponList.vue
@@ -0,0 +1,412 @@
+
+
+
+
+
+
+
+
+ 绑定新优惠券
+
+
+
+
+
+
+
+
+ {{scope.row.couponEntity.couponName}}
+
+
+
+
+ {{scope.row.couponEntity.limitedCollar}}
+
+
+
+
+ {{scope.row.couponEntity.useLevel}}
+
+
+
+
+ {{scope.row.couponEntity.couponRange | getRange}}
+
+
+
+
+ {{scope.row.couponEntity.effectType | getType}}
+
+
+
+
+
+ 断开绑定
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 绑 定
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/modules/shop/shopproduct.vue b/src/views/modules/shop/shopproduct.vue
index f62f253..2345de3 100644
--- a/src/views/modules/shop/shopproduct.vue
+++ b/src/views/modules/shop/shopproduct.vue
@@ -142,7 +142,10 @@
@click.native="handleEditCurriculum(scope.row.productId)"
>新版修改 -->
-
+ 购买赠优惠券
图书与课程
-
+