From 14211892572ae46ebff00f200254240d6abf69c8 Mon Sep 17 00:00:00 2001 From: zcxlsm Date: Thu, 11 Sep 2025 21:40:54 +0800 Subject: [PATCH] =?UTF-8?q?feat(Property):=20=E5=B0=8F=E7=A8=8B=E5=BA=8F?= =?UTF-8?q?=E7=83=AD=E9=97=A8=E6=B4=BB=E5=8A=A8=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../xcx/XCustomerActivityController.java | 61 +++++++++++++++++++ .../mapper/CustomerActivityMapper.java | 4 +- .../impl/CustomerActivityServiceImpl.java | 4 +- .../ResidentPersonServiceImpl.java | 2 + 4 files changed, 67 insertions(+), 4 deletions(-) create mode 100644 ruoyi-modules/Property/src/main/java/org/dromara/property/controller/xcx/XCustomerActivityController.java diff --git a/ruoyi-modules/Property/src/main/java/org/dromara/property/controller/xcx/XCustomerActivityController.java b/ruoyi-modules/Property/src/main/java/org/dromara/property/controller/xcx/XCustomerActivityController.java new file mode 100644 index 00000000..40fd3565 --- /dev/null +++ b/ruoyi-modules/Property/src/main/java/org/dromara/property/controller/xcx/XCustomerActivityController.java @@ -0,0 +1,61 @@ +package org.dromara.property.controller.xcx; + +import cn.dev33.satoken.annotation.SaCheckPermission; +import jakarta.servlet.http.HttpServletResponse; +import jakarta.validation.constraints.NotEmpty; +import jakarta.validation.constraints.NotNull; +import lombok.RequiredArgsConstructor; +import org.dromara.common.core.domain.R; +import org.dromara.common.core.validate.AddGroup; +import org.dromara.common.core.validate.EditGroup; +import org.dromara.common.excel.utils.ExcelUtil; +import org.dromara.common.idempotent.annotation.RepeatSubmit; +import org.dromara.common.log.annotation.Log; +import org.dromara.common.log.enums.BusinessType; +import org.dromara.common.mybatis.core.page.PageQuery; +import org.dromara.common.mybatis.core.page.TableDataInfo; +import org.dromara.common.web.core.BaseController; +import org.dromara.property.domain.bo.CustomerActivityBo; +import org.dromara.property.domain.vo.CustomerActivityVo; +import org.dromara.property.service.ICustomerActivityService; +import org.springframework.validation.annotation.Validated; +import org.springframework.web.bind.annotation.*; + +import java.util.List; + +/** + * 客户服务-活动 + * 前端访问路由地址为:/property/activity + * + * @author lsm + * @since 2025-09-11 + */ +@Validated +@RequiredArgsConstructor +@RestController +@RequestMapping("/xcx/activity") +public class XCustomerActivityController extends BaseController { + + private final ICustomerActivityService customerActivityService; + + /** + * 查询客户服务-活动列表 + */ + @GetMapping("/list") + @SaCheckPermission("xcx:activity:list") + public TableDataInfo list(CustomerActivityBo bo, PageQuery pageQuery) { + return customerActivityService.queryPageList(bo, pageQuery); + } + + /** + * 获取客户服务-活动详细信息 + * + * @param id 主键 + */ + @SaCheckPermission("xcx:activity:query") + @GetMapping("/{id}") + public R getInfo(@NotNull(message = "主键不能为空") + @PathVariable("id") Long id) { + return R.ok(customerActivityService.queryById(id)); + } +} diff --git a/ruoyi-modules/Property/src/main/java/org/dromara/property/mapper/CustomerActivityMapper.java b/ruoyi-modules/Property/src/main/java/org/dromara/property/mapper/CustomerActivityMapper.java index d97e720b..493aea91 100644 --- a/ruoyi-modules/Property/src/main/java/org/dromara/property/mapper/CustomerActivityMapper.java +++ b/ruoyi-modules/Property/src/main/java/org/dromara/property/mapper/CustomerActivityMapper.java @@ -3,13 +3,15 @@ package org.dromara.property.mapper; import org.dromara.property.domain.CustomerActivity; import org.dromara.property.domain.vo.CustomerActivityVo; import org.dromara.common.mybatis.core.mapper.BaseMapperPlus; +import org.mapstruct.Mapper; /** * 客户服务-活动Mapper接口 * * @author yuyongle - * @date 2025-09-08 + * @since 2025-09-08 */ +@Mapper public interface CustomerActivityMapper extends BaseMapperPlus { } diff --git a/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/CustomerActivityServiceImpl.java b/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/CustomerActivityServiceImpl.java index ae554982..64a67a7a 100644 --- a/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/CustomerActivityServiceImpl.java +++ b/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/CustomerActivityServiceImpl.java @@ -1,8 +1,6 @@ package org.dromara.property.service.impl; import cn.hutool.core.collection.CollUtil; -import cn.hutool.core.util.ObjectUtil; -import cn.hutool.core.util.StrUtil; import org.apache.dubbo.config.annotation.DubboReference; import org.dromara.common.core.utils.MapstructUtils; import org.dromara.common.core.utils.StringUtils; @@ -32,7 +30,7 @@ import java.util.Collection; * 客户服务-活动Service业务层处理 * * @author yuyongle - * @date 2025-09-08 + * @since 2025-09-08 */ @Slf4j @RequiredArgsConstructor diff --git a/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/residentImpl/ResidentPersonServiceImpl.java b/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/residentImpl/ResidentPersonServiceImpl.java index 7b47f97b..97055207 100644 --- a/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/residentImpl/ResidentPersonServiceImpl.java +++ b/ruoyi-modules/Property/src/main/java/org/dromara/property/service/impl/residentImpl/ResidentPersonServiceImpl.java @@ -202,6 +202,8 @@ public class ResidentPersonServiceImpl implements IResidentPersonService { } } + // 密码修改走单独接口 + update.setPassword(null); boolean flag = baseMapper.updateById(update) > 0; Assert.isTrue(flag, "修改入驻员工失败!"); return flag;