项目明细调整

This commit is contained in:
chen-xin-zhi 2025-05-09 10:14:37 +08:00
parent 9652eea78b
commit 7c39a7634a
12 changed files with 38 additions and 67 deletions

View File

@ -1,7 +1,7 @@
package com.greenorange.promotion.controller.project; package com.greenorange.promotion.controller.project;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.greenorange.promotion.annotation.RequiresPermission; import com.greenorange.promotion.annotation.RequiresPermission;
import com.greenorange.promotion.annotation.SysLog; import com.greenorange.promotion.annotation.SysLog;
import com.greenorange.promotion.common.BaseResponse; import com.greenorange.promotion.common.BaseResponse;
@ -10,24 +10,21 @@ import com.greenorange.promotion.common.ResultUtils;
import com.greenorange.promotion.constant.UserConstant; import com.greenorange.promotion.constant.UserConstant;
import com.greenorange.promotion.exception.ThrowUtils; import com.greenorange.promotion.exception.ThrowUtils;
import com.greenorange.promotion.model.dto.CommonBatchRequest; import com.greenorange.promotion.model.dto.CommonBatchRequest;
import com.greenorange.promotion.model.dto.CommonRequest;
import com.greenorange.promotion.model.dto.project.ProjectAddRequest; import com.greenorange.promotion.model.dto.project.ProjectAddRequest;
import com.greenorange.promotion.model.dto.project.ProjectQueryRequest; import com.greenorange.promotion.model.dto.project.ProjectQueryRequest;
import com.greenorange.promotion.model.dto.project.ProjectUpdateRequest; import com.greenorange.promotion.model.dto.project.ProjectUpdateRequest;
import com.greenorange.promotion.model.entity.Project; import com.greenorange.promotion.model.entity.Project;
import com.greenorange.promotion.model.entity.ProjectNotification;
import com.greenorange.promotion.model.vo.project.ProjectVO; import com.greenorange.promotion.model.vo.project.ProjectVO;
import com.greenorange.promotion.model.vo.projectNotification.ProjectNotificationVO;
import com.greenorange.promotion.service.common.CommonService; import com.greenorange.promotion.service.common.CommonService;
import com.greenorange.promotion.service.project.ProjectService; import com.greenorange.promotion.service.project.ProjectService;
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;
import jakarta.annotation.Resource; import jakarta.annotation.Resource;
import jakarta.validation.Valid;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.greenorange.promotion.model.dto.CommonRequest;
import jakarta.validation.Valid;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;

View File

@ -407,13 +407,6 @@ public class UserInfoController {
@PostMapping("/test")
@Timeout(5000) // 设置超时时间为 3000 毫秒3秒
public String testMethod() throws InterruptedException {
// 模拟长时间的任务超过 3 秒会抛出超时异常
Thread.sleep(10000); // 模拟 5 秒的耗时操作
return "任务完成";
}

View File

@ -27,13 +27,13 @@ public class Generator {
// 作者 // 作者
private static final String AUTHOR = "chenxinzhi"; private static final String AUTHOR = "chenxinzhi";
// 表注释 // 表注释
private static final String TABLE_COMMENT = "推广码"; private static final String TABLE_COMMENT = "用户项目";
// 实体类名 // 实体类名
private static final String ENTITY_NAME = "PromoCode"; private static final String ENTITY_NAME = "UserProject";
// 表名 // 表名
private static final String TABLE_NAME = "promo_code"; private static final String TABLE_NAME = "user_project";
// 实体类属性名 // 实体类属性名
private static final String ENTITY_NAME_LOWER = "promoCode"; private static final String ENTITY_NAME_LOWER = "userProject";
// 父包名 // 父包名
private static final String PARENT_PATH = "com.greenorange.promotion"; private static final String PARENT_PATH = "com.greenorange.promotion";

View File

@ -48,20 +48,6 @@ public class ProjectAddRequest implements Serializable {
@Schema(description = "项目图片URL", example = "http://xxx.png") @Schema(description = "项目图片URL", example = "http://xxx.png")
private String projectImage; private String projectImage;
/**
* 项目最高价格
*/
@DecimalMin(value = "0", message = "项目最低价格不能小于0")
@Schema(description = "项目最高价格", example = "30")
private BigDecimal maxProjectPrice;
/**
* 项目最低价格
*/
@DecimalMin(value = "0", message = "项目最低价格不能小于0")
@Schema(description = "项目最低价格", example = "10")
private BigDecimal minProjectPrice;
/** /**
* 项目简介 * 项目简介
*/ */

View File

@ -57,20 +57,6 @@ public class ProjectUpdateRequest implements Serializable {
@Schema(description = "项目图片URL", example = "http://xxx.png") @Schema(description = "项目图片URL", example = "http://xxx.png")
private String projectImage; private String projectImage;
/**
* 项目最高价格
*/
@DecimalMin(value = "0", message = "项目最低价格不能小于0")
@Schema(description = "项目最高价格", example = "30")
private BigDecimal maxProjectPrice;
/**
* 项目最低价格
*/
@DecimalMin(value = "0", message = "项目最低价格不能小于0")
@Schema(description = "项目最低价格", example = "10")
private BigDecimal minProjectPrice;
/** /**
* 项目简介 * 项目简介
*/ */

View File

@ -34,6 +34,12 @@ public class ProjectDetailAddRequest implements Serializable {
@Schema(description = "项目结算价", example = "") @Schema(description = "项目结算价", example = "")
private BigDecimal projectSettlementPrice; private BigDecimal projectSettlementPrice;
/**
* 项目最小结算价格
*/
@Schema(description = "项目最小结算价格", example = "${field.example}")
private BigDecimal projectMinSettlementPrice;
/** /**
* 最大抽佣比例 * 最大抽佣比例
*/ */

View File

@ -38,6 +38,12 @@ public class ProjectDetailQueryRequest extends PageRequest implements Serializab
@Schema(description = "项目结算价", example = "") @Schema(description = "项目结算价", example = "")
private BigDecimal projectSettlementPrice; private BigDecimal projectSettlementPrice;
/**
* 项目最小结算价格
*/
@Schema(description = "项目最小结算价格", example = "${field.example}")
private BigDecimal projectMinSettlementPrice;
/** /**
* 最大抽佣比例 * 最大抽佣比例
*/ */

View File

@ -42,6 +42,12 @@ public class ProjectDetailUpdateRequest implements Serializable {
@Schema(description = "项目结算价", example = "") @Schema(description = "项目结算价", example = "")
private BigDecimal projectSettlementPrice; private BigDecimal projectSettlementPrice;
/**
* 项目最小结算价格
*/
@Schema(description = "项目最小结算价格", example = "${field.example}")
private BigDecimal projectMinSettlementPrice;
/** /**
* 最大抽佣比例 * 最大抽佣比例
*/ */

View File

@ -32,16 +32,6 @@ public class Project implements Serializable {
*/ */
private String projectImage; private String projectImage;
/**
* 项目最高价格
*/
private BigDecimal maxProjectPrice;
/**
* 项目最低价格
*/
private BigDecimal minProjectPrice;
/** /**
* 项目简介 * 项目简介
*/ */

View File

@ -32,6 +32,11 @@ public class ProjectDetail implements Serializable {
*/ */
private BigDecimal projectSettlementPrice; private BigDecimal projectSettlementPrice;
/**
* 项目最小结算价格
*/
private BigDecimal projectMinSettlementPrice;
/** /**
* 最大抽佣比例 * 最大抽佣比例
*/ */

View File

@ -32,18 +32,6 @@ public class ProjectVO implements Serializable {
@Schema(description = "项目图片URL", example = "http://xxx.png") @Schema(description = "项目图片URL", example = "http://xxx.png")
private String projectImage; private String projectImage;
/**
* 项目最高价格
*/
@Schema(description = "项目最高价格", example = "30")
private BigDecimal maxProjectPrice;
/**
* 项目最低价格
*/
@Schema(description = "项目最低价格", example = "10")
private BigDecimal minProjectPrice;
/** /**
* 项目简介 * 项目简介
*/ */

View File

@ -32,6 +32,14 @@ public class ProjectDetailVO implements Serializable {
@Schema(description = "项目结算价", example = "${field.example}") @Schema(description = "项目结算价", example = "${field.example}")
private BigDecimal projectSettlementPrice; private BigDecimal projectSettlementPrice;
/**
* 项目最小结算价格
*/
@Schema(description = "项目最小结算价格", example = "${field.example}")
private BigDecimal projectMinSettlementPrice;
/** /**
* 最大抽佣比例 * 最大抽佣比例
*/ */