李雨欣 8.29 14:59 测试查询接口

master
liyuxin 2024-08-29 14:59:45 +08:00
parent 2c5d3e0907
commit 6e71b8533f
11 changed files with 44 additions and 121 deletions

View File

@ -58,11 +58,6 @@ public class Product extends BaseEntity {
*/ */
@Excel(name = "商品状态1: 在售, 0: 下架)") @Excel(name = "商品状态1: 在售, 0: 下架)")
private String status; private String status;
/**
*
*/
@Excel(name = "类型")
private String type;
/** /**
* *
*/ */
@ -75,16 +70,13 @@ public class Product extends BaseEntity {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date") @Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date")
private Date updateTime; private Date updateTime;
/**
*
*/
@Excel(name = "接口地址") private String createBy;
private String apiAddr; private String updateBy;
/** private String remark;
*
*/
@Excel(name = "请求方式")
private String apiMoth;

View File

@ -48,11 +48,6 @@ public class ProductListReq {
*/ */
@Schema(description = "商品状态:同数据字典",defaultValue = "Y",type = "String") @Schema(description = "商品状态:同数据字典",defaultValue = "Y",type = "String")
private String status; private String status;
/**
*
*/
@Schema(description = "类型",defaultValue = "",type = "String")
private String type;
/** /**
* *
*/ */
@ -65,16 +60,6 @@ public class ProductListReq {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date") @Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date")
private Date updateTime; private Date updateTime;
/**
*
*/
@Schema(description = "接口地址",defaultValue = "",type = "String")
private String apiAddr;
/**
*
*/
@Schema(description = "请求方式",defaultValue = "",type = "String")
private String apiMoth;

View File

@ -41,13 +41,8 @@ public class ProductSaveReq {
/** /**
* 1: , 0: * 1: , 0:
*/ */
@Schema(description = "商品状态:同数据字典",defaultValue = "Y",type = "String") @Schema(description = "商品状态",defaultValue = "y",type = "String")
private String status; private String status;
/**
*
*/
@Schema(description = "类型",defaultValue = "",type = "String")
private String type;
/** /**
* *
*/ */
@ -60,16 +55,7 @@ public class ProductSaveReq {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date") @Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date")
private Date updateTime; private Date updateTime;
/**
*
*/
@Schema(description = "接口地址",defaultValue = "",type = "String")
private String apiAddr;
/**
*
*/
@Schema(description = "请求方式",defaultValue = "",type = "String")
private String apiMoth;
private BigDecimal begin; private BigDecimal begin;

View File

@ -48,11 +48,6 @@ public class ProductUpdReq {
*/ */
@Schema(description = "商品状态:同数据字典",defaultValue = "Y",type = "String") @Schema(description = "商品状态:同数据字典",defaultValue = "Y",type = "String")
private String status; private String status;
/**
*
*/
@Schema(description = "类型",defaultValue = "",type = "String")
private String type;
/** /**
* *
*/ */
@ -65,16 +60,7 @@ public class ProductUpdReq {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date") @Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date")
private Date updateTime; private Date updateTime;
/**
*
*/
@Schema(description = "接口地址",defaultValue = "",type = "String")
private String apiAddr;
/**
*
*/
@Schema(description = "请求方式",defaultValue = "",type = "String")
private String apiMoth;

View File

@ -49,11 +49,6 @@ public class ProductListResp {
*/ */
@Schema(description = "商品状态:同数据字典",defaultValue = "Y",type = "String") @Schema(description = "商品状态:同数据字典",defaultValue = "Y",type = "String")
private String status; private String status;
/**
*
*/
@Schema(description = "类型",defaultValue = "",type = "String")
private String type;
/** /**
* *
*/ */
@ -66,16 +61,6 @@ public class ProductListResp {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date") @Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date")
private Date updateTime; private Date updateTime;
/**
*
*/
@Schema(description = "接口地址",defaultValue = "",type = "String")
private String apiAddr;
/**
*
*/
@Schema(description = "请求方式",defaultValue = "",type = "String")
private String apiMoth;
private BigDecimal begin; private BigDecimal begin;
private BigDecimal end; private BigDecimal end;

View File

@ -44,11 +44,6 @@ public class ProductSaveResp {
*/ */
@Schema(description = "同数据字典",defaultValue = "Y",type = "String") @Schema(description = "同数据字典",defaultValue = "Y",type = "String")
private String status; private String status;
/**
*
*/
@Schema(description = "类型",defaultValue = "",type = "String")
private String type;
/** /**
* *
*/ */
@ -61,16 +56,7 @@ public class ProductSaveResp {
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date") @Schema(description = "更新时间",defaultValue = "2024-5-15 10:00:52",type = "Date")
private Date updateTime; private Date updateTime;
/**
*
*/
@Schema(description = "接口地址",defaultValue = "",type = "String")
private String apiAddr;
/**
*
*/
@Schema(description = "请求方式",defaultValue = "",type = "String")
private String apiMoth;

View File

@ -56,18 +56,17 @@ public class OrdersController {
} }
/** // /**
* () // * 查询订信息(测试)
* @param // * @param 】
* @return // * @return
*/ // */
@RequestMapping(path = "/orderSelect",method = RequestMethod.GET) // @RequestMapping(path = "/orderSelect",method = RequestMethod.GET)
@Operation(summary = "查询所有",description = "查询所有") // @Operation(summary = "查询所有",description = "查询所有")
public Result<List<OrdersSelectResp>> findAll(){ // public Result<List<OrdersSelectResp>> findAll(){
return Result.success(orderService.findAll()); // return Result.success(orderService.findAll());
} // }
//你歇会儿 把
/** /**

View File

@ -16,6 +16,6 @@ public interface OrdersMapper extends BaseMapper<Orders> {
* *
* @return * @return
*/ */
List<OrdersSelectResp> findAll(); // List<OrdersSelectResp> findAll();
} }

View File

@ -59,10 +59,10 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersMapper, Orders> impleme
@Override // @Override
public List<OrdersSelectResp> findAll() { // public List<OrdersSelectResp> findAll() {
return orderMapper.findAll(); // return orderMapper.findAll();
} // }
@Override @Override
public List<OrdersSelectResp> findByorderList(OrdersSelectResp ordersSelectResp) { public List<OrdersSelectResp> findByorderList(OrdersSelectResp ordersSelectResp) {

View File

@ -15,7 +15,7 @@ public interface OrdersService extends IService<Orders> {
List<OrdersSelectResp> findByorderList(OrdersSelectResp ordersSelectResp); List<OrdersSelectResp> findByorderList(OrdersSelectResp ordersSelectResp);
List<OrdersSelectResp> findAll(); // List<OrdersSelectResp> findAll();
} }

View File

@ -15,6 +15,8 @@
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="note" column="note" /> <result property="note" column="note" />
</resultMap> </resultMap>
<select id="findByorderList" resultType="com.muyu.market.admain.response.OrdersSelectResp"> <select id="findByorderList" resultType="com.muyu.market.admain.response.OrdersSelectResp">
SELECT SELECT
orders.*, orders.*,
@ -28,19 +30,21 @@
LEFT JOIN sys_user ON orders.order_id = sys_user.user_id LEFT JOIN sys_user ON orders.order_id = sys_user.user_id
LEFT JOIN product ON orders.order_id = product.product_id LEFT JOIN product ON orders.order_id = product.product_id
</select> </select>
<select id="findAll" resultType="com.muyu.market.admain.response.OrdersSelectResp">
SELECT
orders.*, <!-- <select id="findAll" resultType="com.muyu.market.admain.response.OrdersSelectResp">-->
sys_user.user_name, <!-- SELECT-->
product.product_name, <!-- orders.*,-->
product.product_price, <!-- sys_user.user_name,-->
product.description, <!-- product.product_name,-->
product.`status` <!-- product.product_price,-->
FROM <!-- product.description,-->
orders <!-- product.`status`-->
LEFT JOIN sys_user ON orders.order_id = sys_user.user_id <!-- FROM-->
LEFT JOIN product ON orders.order_id = product.product_id <!-- orders-->
</select> <!-- LEFT JOIN sys_user ON orders.order_id = sys_user.user_id-->
<!-- LEFT JOIN product ON orders.order_id = product.product_id-->
<!-- </select>-->