新增顾客礼物图鉴接口
This commit is contained in:
@@ -3,18 +3,18 @@ package com.starry.admin.modules.weichat.controller;
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.starry.admin.common.aspect.ClerkUserLogin;
|
||||
import com.starry.admin.common.aspect.CustomUserLogin;
|
||||
import com.starry.admin.common.conf.ThreadLocalRequestDetail;
|
||||
import com.starry.admin.common.exception.CustomException;
|
||||
import com.starry.admin.modules.gift.service.IPlayGiftInfoService;
|
||||
import com.starry.admin.modules.weichat.entity.PlayGiftInfoDto;
|
||||
import com.starry.admin.modules.weichat.entity.gift.PlayClerkGiftReturnVo;
|
||||
import com.starry.admin.modules.weichat.entity.gift.PlayCustomGiftQueryVo;
|
||||
import com.starry.common.result.R;
|
||||
import com.starry.common.utils.ConvertUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
@@ -60,4 +60,18 @@ public class WxGiftController {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 顾客获取礼物图鉴信息
|
||||
*
|
||||
* @param vo 顾客获得礼物查询对象
|
||||
* @return 礼物列表
|
||||
*/
|
||||
@CustomUserLogin
|
||||
@PostMapping("/custom/listByAll")
|
||||
public R customListByAll(@Validated @RequestBody PlayCustomGiftQueryVo vo) {
|
||||
List<PlayClerkGiftReturnVo> list = giftInfoService.customListByAll(ThreadLocalRequestDetail.getCustomUserInfo().getId(), vo.getObtained(), vo.getHistory());
|
||||
return R.ok(list);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
package com.starry.admin.modules.weichat.controller;
|
||||
|
||||
import com.starry.admin.modules.shop.module.entity.PlayShopCarouselInfoEntity;
|
||||
import com.starry.admin.modules.shop.service.IPlayShopCarouselInfoService;
|
||||
import com.starry.admin.modules.weichat.entity.shop.ShopHomeCarouseInfoReturnVo;
|
||||
import com.starry.common.result.R;
|
||||
import com.starry.common.utils.ConvertUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 动态接口
|
||||
*
|
||||
* @author admin
|
||||
* @since 2024/5/20 下午11:19
|
||||
**/
|
||||
@Slf4j
|
||||
@RestController
|
||||
@RequestMapping("/wx/shop")
|
||||
public class WxShopController {
|
||||
|
||||
|
||||
@Resource
|
||||
private IPlayShopCarouselInfoService playShopCarouselInfoService;
|
||||
|
||||
|
||||
@GetMapping(value = "custom/getShopHomeCarouseInfo")
|
||||
public R getShopHomeCarouseInfo() {
|
||||
List<PlayShopCarouselInfoEntity> entities = playShopCarouselInfoService.selectHomeCarouselInfo();
|
||||
return R.ok(ConvertUtil.entityToVoList(entities, ShopHomeCarouseInfoReturnVo.class));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package com.starry.admin.modules.weichat.entity.gift;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 店员礼物查询对象
|
||||
*
|
||||
* @author admin
|
||||
* @since 2024/5/26 上午12:20
|
||||
**/
|
||||
@Data
|
||||
public class PlayCustomGiftQueryVo {
|
||||
|
||||
|
||||
/**
|
||||
* 是否已获得礼物(0:已获取,1:所有礼物)
|
||||
*/
|
||||
private String obtained;
|
||||
|
||||
|
||||
/**
|
||||
* 是否是历史礼物(0:不是,1:是)
|
||||
*/
|
||||
private String history;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
package com.starry.admin.modules.weichat.entity.shop;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author admin
|
||||
* @since 2024/6/5 下午4:40
|
||||
**/
|
||||
@Data
|
||||
public class ShopHomeCarouseInfoReturnVo {
|
||||
|
||||
/**
|
||||
* 图片URL
|
||||
*/
|
||||
private String carouselUrl;
|
||||
}
|
||||
Reference in New Issue
Block a user