完善了小程序端用户创建订单接口
This commit is contained in:
parent
9d43600ac7
commit
33297d7db5
|
@ -48,7 +48,7 @@ public class FileController {
|
||||||
* @return 图片可访问地址
|
* @return 图片可访问地址
|
||||||
*/
|
*/
|
||||||
@PostMapping("/upload/server/not_login")
|
@PostMapping("/upload/server/not_login")
|
||||||
@Operation(summary = "未登录情况下的文件上传", description = "参数:文件对象(multipartFile), 业务类型(biz),权限:所有人,方法名:uploadServerFileNotLogin")
|
@Operation(summary = "未登录情况下的文件上传", description = "参数:(文档上是false,但biz是必传的),文件对象(multipartFile), 业务类型(biz),权限:所有人,方法名:uploadServerFileNotLogin")
|
||||||
private BaseResponse<String> uploadServerFileNotLogin(@RequestPart("file")MultipartFile multipartFile, UploadFileRequest uploadFileRequest) {
|
private BaseResponse<String> uploadServerFileNotLogin(@RequestPart("file")MultipartFile multipartFile, UploadFileRequest uploadFileRequest) {
|
||||||
//获取业务名称
|
//获取业务名称
|
||||||
String biz = uploadFileRequest.getBiz();
|
String biz = uploadFileRequest.getBiz();
|
||||||
|
@ -79,8 +79,8 @@ public class FileController {
|
||||||
|
|
||||||
|
|
||||||
@PostMapping("/upload/server")
|
@PostMapping("/upload/server")
|
||||||
@Operation(summary = "已登录情况下的文件上传", description = "参数:文件对象(multipartFile), 业务类型(biz),权限:所有人,方法名:uploadServerFile")
|
@Operation(summary = "已登录情况下的文件上传", description = "参数:(文档上是false,但biz是必传的),文件对象(multipartFile), 业务类型(biz),权限:所有人,方法名:uploadServerFile")
|
||||||
public BaseResponse<String> uploadServerFile(@RequestPart MultipartFile multipartFile, UploadFileRequest uploadFileRequest, HttpServletRequest request) {
|
public BaseResponse<String> uploadServerFile(@RequestPart("file")MultipartFile multipartFile, UploadFileRequest uploadFileRequest, HttpServletRequest request) {
|
||||||
//获取业务名称
|
//获取业务名称
|
||||||
String biz = uploadFileRequest.getBiz();
|
String biz = uploadFileRequest.getBiz();
|
||||||
FileUploadBizEnum fileUploadBizEnum = FileUploadBizEnum.getEnumByValue(biz);
|
FileUploadBizEnum fileUploadBizEnum = FileUploadBizEnum.getEnumByValue(biz);
|
||||||
|
|
|
@ -123,7 +123,7 @@ public class CouponController {
|
||||||
* @return 优惠券列表
|
* @return 优惠券列表
|
||||||
*/
|
*/
|
||||||
@PostMapping("/list/page")
|
@PostMapping("/list/page")
|
||||||
@Operation(summary = "Web端管理员分页查询优惠券", description = "参数:优惠券查询请求体, 排序字段 sortField: conditionAmount requirePoints totalNum residueNum limitNum,权限:管理员(admin, boss),方法名:listCouponVOByPage")
|
@Operation(summary = "Web端管理员分页查询优惠券", description = "参数:优惠券查询请求体, 排序字段 sortField: conditionAmount requirePoints totalNum residueNum limitNum id,权限:管理员(admin, boss),方法名:listCouponVOByPage")
|
||||||
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
||||||
public BaseResponse<Page<Coupon>> listCouponVOByPage(@RequestBody CouponQueryRequest couponQueryRequest) {
|
public BaseResponse<Page<Coupon>> listCouponVOByPage(@RequestBody CouponQueryRequest couponQueryRequest) {
|
||||||
if (couponQueryRequest == null) {
|
if (couponQueryRequest == null) {
|
||||||
|
|
|
@ -16,7 +16,6 @@ import com.cultural.heritage.model.dto.good.GoodAddRequest;
|
||||||
import com.cultural.heritage.model.dto.good.GoodQueryRequest;
|
import com.cultural.heritage.model.dto.good.GoodQueryRequest;
|
||||||
import com.cultural.heritage.model.dto.good.GoodUpdateRequest;
|
import com.cultural.heritage.model.dto.good.GoodUpdateRequest;
|
||||||
import com.cultural.heritage.model.entity.Good;
|
import com.cultural.heritage.model.entity.Good;
|
||||||
import com.cultural.heritage.service.good.CategoryService;
|
|
||||||
import com.cultural.heritage.service.good.GoodService;
|
import com.cultural.heritage.service.good.GoodService;
|
||||||
import io.swagger.v3.oas.annotations.Operation;
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
@ -44,8 +43,6 @@ public class GoodController {
|
||||||
private GoodService goodService;
|
private GoodService goodService;
|
||||||
|
|
||||||
|
|
||||||
@Resource
|
|
||||||
private CategoryService categoryService;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -114,7 +111,7 @@ public class GoodController {
|
||||||
* @return 商品信息列表
|
* @return 商品信息列表
|
||||||
*/
|
*/
|
||||||
@PostMapping("/list/page")
|
@PostMapping("/list/page")
|
||||||
@Operation(summary = "Web端管理员分页查询商品", description = "参数:商品查询请求体,排序字段 sortField: price inventory,权限:管理员(admin, boss),方法名:listGoodByPage")
|
@Operation(summary = "Web端管理员分页查询商品", description = "参数:商品查询请求体,排序字段 sortField: price inventory id,权限:管理员(admin, boss),方法名:listGoodByPage")
|
||||||
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
||||||
public BaseResponse<Page<Good>> listGoodByPage(@RequestBody GoodQueryRequest goodQueryRequest) {
|
public BaseResponse<Page<Good>> listGoodByPage(@RequestBody GoodQueryRequest goodQueryRequest) {
|
||||||
long current = goodQueryRequest.getCurrent();
|
long current = goodQueryRequest.getCurrent();
|
||||||
|
|
|
@ -83,7 +83,7 @@ public class UserController {
|
||||||
* @return 用户登录信息
|
* @return 用户登录信息
|
||||||
*/
|
*/
|
||||||
@GetMapping("/login/wx_open")
|
@GetMapping("/login/wx_open")
|
||||||
@Operation(summary = "微信小程序用户登录", description = "参数:code(用户登录凭证), 权限:所有人, 方法名:userLoginByWxOpen")
|
@Operation(summary = "(无法测)微信小程序用户登录", description = "参数:code(用户登录凭证), 权限:所有人, 方法名:userLoginByWxOpen")
|
||||||
public BaseResponse<UserVO> userLoginByWxOpen(@RequestParam("code") String code, HttpServletRequest request) {
|
public BaseResponse<UserVO> userLoginByWxOpen(@RequestParam("code") String code, HttpServletRequest request) {
|
||||||
WxMaJscode2SessionResult sessionInfo;
|
WxMaJscode2SessionResult sessionInfo;
|
||||||
try {
|
try {
|
||||||
|
@ -218,7 +218,7 @@ public class UserController {
|
||||||
* @return 用户信息
|
* @return 用户信息
|
||||||
*/
|
*/
|
||||||
@GetMapping("/get")
|
@GetMapping("/get")
|
||||||
@Operation(summary = "Web端管理员根据id获取用户信息", description = "参数:用户id, 权限:管理员(admin, boss), 方法名:getUserById")
|
@Operation(summary = "(未使用)Web端管理员根据id获取用户信息", description = "参数:用户id, 权限:管理员(admin, boss), 方法名:getUserById")
|
||||||
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
||||||
public BaseResponse<User> getUserById(long id) {
|
public BaseResponse<User> getUserById(long id) {
|
||||||
if (id <= 0) {
|
if (id <= 0) {
|
||||||
|
@ -234,7 +234,7 @@ public class UserController {
|
||||||
* 获取用户数量
|
* 获取用户数量
|
||||||
*/
|
*/
|
||||||
@GetMapping("/count")
|
@GetMapping("/count")
|
||||||
@Operation(summary = "Web端管理员获取用户数量", description = "参数:无, 权限:管理员(admin, boss), 方法名:getUserCount")
|
@Operation(summary = "(未使用)Web端管理员获取用户数量", description = "参数:无, 权限:管理员(admin, boss), 方法名:getUserCount")
|
||||||
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
||||||
public BaseResponse<Long> getUserCount() {
|
public BaseResponse<Long> getUserCount() {
|
||||||
QueryWrapper<User> queryWrapper = new QueryWrapper<>();
|
QueryWrapper<User> queryWrapper = new QueryWrapper<>();
|
||||||
|
@ -251,7 +251,7 @@ public class UserController {
|
||||||
* @return 用户信息列表
|
* @return 用户信息列表
|
||||||
*/
|
*/
|
||||||
@PostMapping("/list/page")
|
@PostMapping("/list/page")
|
||||||
@Operation(summary = "Web端管理员分页获取用户信息", description = "参数:用户查询请求体, 排序字段 sortField: points,权限:管理员(admin, boss), 方法名:listUserByPage")
|
@Operation(summary = "Web端管理员分页获取用户信息", description = "参数:用户查询请求体, 排序字段 sortField: points id,权限:管理员(admin, boss), 方法名:listUserByPage")
|
||||||
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
||||||
public BaseResponse<Page<User>> listUserByPage(@RequestBody UserQueryRequest userQueryRequest) {
|
public BaseResponse<Page<User>> listUserByPage(@RequestBody UserQueryRequest userQueryRequest) {
|
||||||
long current = userQueryRequest.getCurrent();
|
long current = userQueryRequest.getCurrent();
|
||||||
|
@ -270,7 +270,7 @@ public class UserController {
|
||||||
* @return 脱敏用户信息列表
|
* @return 脱敏用户信息列表
|
||||||
*/
|
*/
|
||||||
@PostMapping("/list/page/vo")
|
@PostMapping("/list/page/vo")
|
||||||
@Operation(summary = "Web端管理员分页获取脱敏用户信息", description = "参数:用户查询请求体, 排序字段 sortField: points, 权限:管理员(admin, boss), 方法名:listUserVOByPage")
|
@Operation(summary = "(未使用)Web端管理员分页获取脱敏用户信息", description = "参数:用户查询请求体, 排序字段 sortField: points id, 权限:管理员(admin, boss), 方法名:listUserVOByPage")
|
||||||
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
@AuthCheck(mustRole = UserConstant.ADMIN_ROLE)
|
||||||
public BaseResponse<Page<UserVO>> listUserVOByPage(@RequestBody UserQueryRequest userQueryRequest) {
|
public BaseResponse<Page<UserVO>> listUserVOByPage(@RequestBody UserQueryRequest userQueryRequest) {
|
||||||
if (userQueryRequest == null) {
|
if (userQueryRequest == null) {
|
||||||
|
|
|
@ -7,7 +7,7 @@ import java.io.Serial;
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
|
|
||||||
@Data
|
@Data
|
||||||
@Schema(description = "购物车记录添加请求体", requiredProperties = {"userId", "goodId", "quantity", "subtotal"})
|
@Schema(description = "购物车记录添加请求体", requiredProperties = {"userId", "goodId", "quantity", "subtotal", "isGoodType"})
|
||||||
public class CartRecordAddRequest implements Serializable {
|
public class CartRecordAddRequest implements Serializable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -8,7 +8,7 @@ import java.io.Serializable;
|
||||||
|
|
||||||
@Data
|
@Data
|
||||||
@Schema(description = "商品更新请求体", requiredProperties = {"id", "name", "type", "price", "goodImg", "intro",
|
@Schema(description = "商品更新请求体", requiredProperties = {"id", "name", "type", "price", "goodImg", "intro",
|
||||||
"introDetail, detailImg", "label", "inventory", "festivalOrder"})
|
"introDetail", "detailImg", "label", "inventory", "festivalOrder", "isShelves"})
|
||||||
public class GoodUpdateRequest implements Serializable {
|
public class GoodUpdateRequest implements Serializable {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue
Block a user