diff --git a/yudao-admin-vue3/src/api/mall/promotion/memberbenefit/index.ts b/yudao-admin-vue3/src/api/mall/promotion/memberbenefit/index.ts
index 9a76773..bb3be5e 100644
--- a/yudao-admin-vue3/src/api/mall/promotion/memberbenefit/index.ts
+++ b/yudao-admin-vue3/src/api/mall/promotion/memberbenefit/index.ts
@@ -1,44 +1,48 @@
-import request from '@/config/axios'
-
-// 付费会员权益 VO
-export interface PaidMemberBenefitVO {
- id: number // 编号
- name: string // 名称
- iconUrl: string // 图标地址
- intro: string // 描述
- status: boolean // 状态:(默认)0隐藏 1显示
- sort: number // 排序
-}
-
-// 付费会员权益 API
-export const PaidMemberBenefitApi = {
- // 查询付费会员权益分页
- getPaidMemberBenefitPage: async (params: any) => {
- return await request.get({ url: `/paidmemberbenefit/paid-member-benefit/page`, params })
- },
-
- // 查询付费会员权益详情
- getPaidMemberBenefit: async (id: number) => {
- return await request.get({ url: `/paidmemberbenefit/paid-member-benefit/get?id=` + id })
- },
-
- // 新增付费会员权益
- createPaidMemberBenefit: async (data: PaidMemberBenefitVO) => {
- return await request.post({ url: `/paidmemberbenefit/paid-member-benefit/create`, data })
- },
-
- // 修改付费会员权益
- updatePaidMemberBenefit: async (data: PaidMemberBenefitVO) => {
- return await request.put({ url: `/paidmemberbenefit/paid-member-benefit/update`, data })
- },
-
- // 删除付费会员权益
- deletePaidMemberBenefit: async (id: number) => {
- return await request.delete({ url: `/paidmemberbenefit/paid-member-benefit/delete?id=` + id })
- },
-
- // 导出付费会员权益 Excel
- exportPaidMemberBenefit: async (params) => {
- return await request.download({ url: `/paidmemberbenefit/paid-member-benefit/export-excel`, params })
- },
-}
\ No newline at end of file
+import request from '@/config/axios'
+
+// 付费会员权益 VO
+export interface PaidMemberBenefitVO {
+ id: number // 编号
+ name: string // 名称
+ iconUrl: string // 图标地址
+ intro: string // 描述
+ status: boolean // 状态:(默认)0隐藏 1显示
+ sort: number // 排序
+}
+
+// 付费会员权益 API
+export const PaidMemberBenefitApi = {
+ // 查询付费会员权益分页
+ getPaidMemberBenefitPage: async (params: any) => {
+ return await request.get({ url: `/paidmemberbenefit/paid-member-benefit/page`, params })
+ },
+
+ // 查询付费会员权益详情
+ getPaidMemberBenefit: async (id: number) => {
+ return await request.get({ url: `/paidmemberbenefit/paid-member-benefit/get?id=` + id })
+ },
+
+ // 新增付费会员权益
+ createPaidMemberBenefit: async (data: PaidMemberBenefitVO) => {
+ return await request.post({ url: `/paidmemberbenefit/paid-member-benefit/create`, data })
+ },
+
+ // 修改付费会员权益
+ updatePaidMemberBenefit: async (data: PaidMemberBenefitVO) => {
+ return await request.put({ url: `/paidmemberbenefit/paid-member-benefit/update`, data })
+ },
+ // 修改会员权益状态
+ updatePaidMemberBenefitStatus: async (data: any) => {
+ return await request.put({ url: `/paidmemberbenefit/paid-member-benefit/updateStatus`, data})
+ },
+
+ // 删除付费会员权益
+ deletePaidMemberBenefit: async (id: number) => {
+ return await request.delete({ url: `/paidmemberbenefit/paid-member-benefit/delete?id=` + id })
+ },
+
+ // 导出付费会员权益 Excel
+ exportPaidMemberBenefit: async (params) => {
+ return await request.download({ url: `/paidmemberbenefit/paid-member-benefit/export-excel`, params })
+ },
+}
diff --git a/yudao-admin-vue3/src/utils/dict.ts b/yudao-admin-vue3/src/utils/dict.ts
index ca4e4ac..6004227 100644
--- a/yudao-admin-vue3/src/utils/dict.ts
+++ b/yudao-admin-vue3/src/utils/dict.ts
@@ -227,6 +227,7 @@ export enum DICT_TYPE {
PROMOTION_BARGAIN_RECORD_STATUS = 'promotion_bargain_record_status', // 砍价记录的状态
PROMOTION_COMBINATION_RECORD_STATUS = 'promotion_combination_record_status', // 拼团记录的状态
PROMOTION_BANNER_POSITION = 'promotion_banner_position', // banner 定位
+ MEMBER_BENEFIT_STATUS = 'member_benefit_status', // 会员权益状态
// ========== CRM - 客户管理模块 ==========
CRM_AUDIT_STATUS = 'crm_audit_status', // CRM 审批状态
diff --git a/yudao-admin-vue3/src/views/mall/promotion/memberbenefit/PaidMemberBenefitForm.vue b/yudao-admin-vue3/src/views/mall/promotion/memberbenefit/PaidMemberBenefitForm.vue
index a0f4087..83dd186 100644
--- a/yudao-admin-vue3/src/views/mall/promotion/memberbenefit/PaidMemberBenefitForm.vue
+++ b/yudao-admin-vue3/src/views/mall/promotion/memberbenefit/PaidMemberBenefitForm.vue
@@ -17,9 +17,14 @@
-
- 请选择字典生成
-
+
+
+
@@ -33,7 +38,7 @@
\ No newline at end of file
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/PaidMemberBenefitController.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/PaidMemberBenefitController.java
index b8b05d1..935b17b 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/PaidMemberBenefitController.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/PaidMemberBenefitController.java
@@ -3,6 +3,7 @@ package cn.iocoder.yudao.module.member.controller.admin.memberbenefit;
import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitPageReqVO;
import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitRespVO;
import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitSaveReqVO;
+import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitStatusReqVO;
import cn.iocoder.yudao.module.member.dal.dataobject.memberbenefit.PaidMemberBenefitDO;
import cn.iocoder.yudao.module.member.service.memberbenefit.PaidMemberBenefitService;
import org.springframework.web.bind.annotation.*;
@@ -54,6 +55,13 @@ public class PaidMemberBenefitController {
paidMemberBenefitService.updatePaidMemberBenefit(updateReqVO);
return success(true);
}
+ @PutMapping("/updateStatus")
+ @Operation(summary = "更新付费会员权益")
+ @PreAuthorize("@ss.hasPermission('paidmemberbenefit:paid-member-benefit:update')")
+ public CommonResult updatePaidMemberBenefitStatus(@RequestBody PaidMemberBenefitStatusReqVO req) {
+ paidMemberBenefitService.updatePaidMemberBenefitStatus(req);
+ return success(true);
+ }
@DeleteMapping("/delete")
@Operation(summary = "删除付费会员权益")
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitPageReqVO.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitPageReqVO.java
index 29b8ac6..77a673b 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitPageReqVO.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitPageReqVO.java
@@ -25,7 +25,7 @@ public class PaidMemberBenefitPageReqVO extends PageParam {
private String intro;
@Schema(description = "状态:(默认)0隐藏 1显示", example = "1")
- private Boolean status;
+ private Integer status;
@Schema(description = "排序")
private Integer sort;
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitRespVO.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitRespVO.java
index 256efdd..77162a2 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitRespVO.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitRespVO.java
@@ -31,7 +31,7 @@ public class PaidMemberBenefitRespVO {
@Schema(description = "状态:(默认)0隐藏 1显示", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
@ExcelProperty("状态:(默认)0隐藏 1显示")
- private Boolean status;
+ private Integer status;
@Schema(description = "排序", requiredMode = Schema.RequiredMode.REQUIRED)
@ExcelProperty("排序")
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitSaveReqVO.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitSaveReqVO.java
index c89dc41..c8d49af 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitSaveReqVO.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitSaveReqVO.java
@@ -25,7 +25,7 @@ public class PaidMemberBenefitSaveReqVO {
@Schema(description = "状态:(默认)0隐藏 1显示", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
@NotNull(message = "状态:(默认)0隐藏 1显示不能为空")
- private Boolean status;
+ private Integer status;
@Schema(description = "排序", requiredMode = Schema.RequiredMode.REQUIRED)
@NotNull(message = "排序不能为空")
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitStatusReqVO.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitStatusReqVO.java
new file mode 100644
index 0000000..8250593
--- /dev/null
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/controller/admin/memberbenefit/vo/PaidMemberBenefitStatusReqVO.java
@@ -0,0 +1,19 @@
+package cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo;
+
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+
+import javax.validation.constraints.NotEmpty;
+import javax.validation.constraints.NotNull;
+
+
+@Schema(description = "管理后台 - 付费会员权益新增/修改 Request VO")
+@Data
+public class PaidMemberBenefitStatusReqVO {
+ @Schema(description = " 编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "29131")
+ private Long id;
+
+ @Schema(description = "状态:(默认)0隐藏 1显示", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
+ @NotNull(message = "状态:(默认)0隐藏 1显示不能为空")
+ private Integer status;
+}
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/dal/dataobject/memberbenefit/PaidMemberBenefitDO.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/dal/dataobject/memberbenefit/PaidMemberBenefitDO.java
index e7e497b..a303d70 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/dal/dataobject/memberbenefit/PaidMemberBenefitDO.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/dal/dataobject/memberbenefit/PaidMemberBenefitDO.java
@@ -42,7 +42,7 @@ public class PaidMemberBenefitDO extends BaseDO {
/**
* 状态:(默认)0隐藏 1显示
*/
- private Boolean status;
+ private Integer status;
/**
* 排序
*/
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitService.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitService.java
index f3b56a1..2efa755 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitService.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitService.java
@@ -6,6 +6,7 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.common.pojo.PageParam;
import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitPageReqVO;
import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitSaveReqVO;
+import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitStatusReqVO;
import cn.iocoder.yudao.module.member.dal.dataobject.memberbenefit.PaidMemberBenefitDO;
/**
@@ -53,4 +54,9 @@ public interface PaidMemberBenefitService {
*/
PageResult getPaidMemberBenefitPage(PaidMemberBenefitPageReqVO pageReqVO);
+ /**
+ * 更新付费会员状态
+ * @return void
+ */
+ void updatePaidMemberBenefitStatus(PaidMemberBenefitStatusReqVO req);
}
\ No newline at end of file
diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitServiceImpl.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitServiceImpl.java
index 16b4e37..bf16cc2 100644
--- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitServiceImpl.java
+++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/memberbenefit/PaidMemberBenefitServiceImpl.java
@@ -1,7 +1,9 @@
package cn.iocoder.yudao.module.member.service.memberbenefit;
+import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitPageReqVO;
import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitSaveReqVO;
+import cn.iocoder.yudao.module.member.controller.admin.memberbenefit.vo.PaidMemberBenefitStatusReqVO;
import cn.iocoder.yudao.module.member.dal.dataobject.memberbenefit.PaidMemberBenefitDO;
import cn.iocoder.yudao.module.member.dal.mysql.memberbenefit.PaidMemberBenefitMapper;
import org.springframework.stereotype.Service;
@@ -72,4 +74,12 @@ public class PaidMemberBenefitServiceImpl implements PaidMemberBenefitService {
return paidMemberBenefitMapper.selectPage(pageReqVO);
}
+ @Override
+ public void updatePaidMemberBenefitStatus(PaidMemberBenefitStatusReqVO req) {
+ // 校验存在
+ validatePaidMemberBenefitExists(req.getId());
+ // 更新状态
+ paidMemberBenefitMapper.updateById(new PaidMemberBenefitDO().setId(req.getId()).setStatus(req.getStatus()));
+ }
+
}
\ No newline at end of file
diff --git a/yudao-module-subscribe/yudao-module-subscribe-biz/src/main/java/cn/iocoder/yudao/module/srbscribe/service/reservation/LitemallReservationServiceImpl.java b/yudao-module-subscribe/yudao-module-subscribe-biz/src/main/java/cn/iocoder/yudao/module/srbscribe/service/reservation/LitemallReservationServiceImpl.java
index 7d4958f..0e7e09d 100644
--- a/yudao-module-subscribe/yudao-module-subscribe-biz/src/main/java/cn/iocoder/yudao/module/srbscribe/service/reservation/LitemallReservationServiceImpl.java
+++ b/yudao-module-subscribe/yudao-module-subscribe-biz/src/main/java/cn/iocoder/yudao/module/srbscribe/service/reservation/LitemallReservationServiceImpl.java
@@ -2,7 +2,6 @@ package cn.iocoder.yudao.module.srbscribe.service.reservation;
import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.module.member.dal.dataobject.user.MemberUserDO;
-import cn.iocoder.yudao.module.member.dal.mysql.user.MemberUserMapper;
import cn.iocoder.yudao.module.srbscribe.controller.admin.reservation.vo.LitemallReservationPageReqVO;
import cn.iocoder.yudao.module.srbscribe.controller.admin.reservation.vo.LitemallReservationSaveReqVO;
import cn.iocoder.yudao.module.srbscribe.controller.admin.technician.vo.ServiceTimeVO;
@@ -18,7 +17,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import org.springframework.validation.annotation.Validated;
-
+import cn.iocoder.yudao.module.member.dal.mysql.user.MemberUserMapper;
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;