framework/src/main/java/cn/lili/modules/lmk/service/MemberCustomerTagService.java
@@ -40,4 +40,11 @@ * @return */ Result detail(); /** * 获得会员自定义标签通过id * @param id 会员id * @return */ Result detailById(String id); } framework/src/main/java/cn/lili/modules/lmk/service/impl/MemberCustomerTagServiceImpl.java
@@ -39,7 +39,7 @@ .eq(MemberCustomerTag::getDeleteFlag,false) .count(); if (count >= customerTagCount){ throw new ServiceException("已达到自定义标签最大数量"); return Result.error("已达到自定义标签最大数量"); } System.out.println(form); MemberCustomerTag entity = MemberCustomerTagForm.getEntity(form,null); @@ -82,4 +82,14 @@ return Result.ok().data(list); } @Override public Result detailById(String id) { List<MemberCustomerTag> list = new LambdaQueryChainWrapper<>(baseMapper) .eq(MemberCustomerTag::getMemberId,id) .eq(MemberCustomerTag::getDeleteFlag,false) .list(); return Result.ok().data(list); } } manager-api/src/main/java/cn/lili/controller/lmk/MemberCustomerTagController.java
@@ -8,6 +8,7 @@ import io.swagger.annotations.ApiOperation; import lombok.RequiredArgsConstructor; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @@ -35,4 +36,10 @@ return memberCustomerTagService.detail(); } @GetMapping("/detail/{id}") @ApiOperation(value = "通过id获取会员标签详情", notes = "通过id获取会员标签详情") public Result detailById(@PathVariable String id){ return memberCustomerTagService.detailById(id); } }