提交修改
This commit is contained in:
parent
581d5c0909
commit
c0934ba746
@ -47,4 +47,8 @@ public interface VvBuyerDao extends BaseMapper<VvBuyerEntity> {
|
|||||||
@IF @GE Long minCreateTimestamp,
|
@IF @GE Long minCreateTimestamp,
|
||||||
@IF @LE Long maxCreateTimestamp,
|
@IF @LE Long maxCreateTimestamp,
|
||||||
@OrderBy @IF @Column(VvBuyerEntity.create_timestamp) String createTimestampSort);
|
@OrderBy @IF @Column(VvBuyerEntity.create_timestamp) String createTimestampSort);
|
||||||
|
|
||||||
|
|
||||||
|
@LIMIT
|
||||||
|
VvBuyerEntity selectVvBuyerIsTestById(Long id, Integer isTest);
|
||||||
}
|
}
|
||||||
@ -74,9 +74,11 @@ public interface VvProductDao extends BaseMapper<VvProductEntity> {
|
|||||||
@IF Integer appCategoryId1,
|
@IF Integer appCategoryId1,
|
||||||
@IF Integer appCategoryId2,
|
@IF Integer appCategoryId2,
|
||||||
@IF Integer appCategoryId3,
|
@IF Integer appCategoryId3,
|
||||||
|
@IF Integer isTest,
|
||||||
@IF @OrderBy(VvProductEntity.show_sale_price) String salePriceSort,
|
@IF @OrderBy(VvProductEntity.show_sale_price) String salePriceSort,
|
||||||
@IF @OrderBy(VvProductEntity.show_sale_count) String saleCountSort,
|
@IF @OrderBy(VvProductEntity.show_sale_count) String saleCountSort,
|
||||||
@IF @OrderBy(VvProductEntity.create_timestamp) String createTimestampSort);
|
@IF @OrderBy(VvProductEntity.create_timestamp) String createTimestampSort
|
||||||
|
);
|
||||||
|
|
||||||
List<VvProductEntity> selectVvProductByProductIds(@IN List<Long> id);
|
List<VvProductEntity> selectVvProductByProductIds(@IN List<Long> id);
|
||||||
|
|
||||||
|
|||||||
@ -10,7 +10,7 @@ import java.util.Date;import java.util.Date;
|
|||||||
/**
|
/**
|
||||||
*买家信息
|
*买家信息
|
||||||
* @author quyixiao
|
* @author quyixiao
|
||||||
* @since 2025-08-23
|
* @since 2025-10-14
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@Data
|
@Data
|
||||||
@ -30,6 +30,7 @@ private static final long serialVersionUID = 1L;
|
|||||||
public final static String buyer_phone = CLASS_NAME + "buyer_phone"; // 买家手机号
|
public final static String buyer_phone = CLASS_NAME + "buyer_phone"; // 买家手机号
|
||||||
public final static String create_timestamp = CLASS_NAME + "create_timestamp"; // 买家创建时间
|
public final static String create_timestamp = CLASS_NAME + "create_timestamp"; // 买家创建时间
|
||||||
public final static String modify_timestamp = CLASS_NAME + "modify_timestamp"; // 买家修改时间
|
public final static String modify_timestamp = CLASS_NAME + "modify_timestamp"; // 买家修改时间
|
||||||
|
public final static String is_test = CLASS_NAME + "is_test"; // 是否是测试账号
|
||||||
//
|
//
|
||||||
@TableId(value = "id", type = IdType.AUTO)
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
private Long id;
|
private Long id;
|
||||||
@ -49,6 +50,8 @@ private static final long serialVersionUID = 1L;
|
|||||||
private Long createTimestamp;
|
private Long createTimestamp;
|
||||||
//买家修改时间
|
//买家修改时间
|
||||||
private Long modifyTimestamp;
|
private Long modifyTimestamp;
|
||||||
|
//是否是测试账号
|
||||||
|
private Integer isTest;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @return
|
* @return
|
||||||
@ -184,6 +187,21 @@ private static final long serialVersionUID = 1L;
|
|||||||
this.modifyTimestamp = modifyTimestamp;
|
this.modifyTimestamp = modifyTimestamp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否是测试账号
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public Integer getIsTest() {
|
||||||
|
return isTest;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 是否是测试账号
|
||||||
|
* @param isTest
|
||||||
|
*/
|
||||||
|
public void setIsTest(Integer isTest) {
|
||||||
|
this.isTest = isTest;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "VvBuyerEntity{" +
|
return "VvBuyerEntity{" +
|
||||||
@ -196,6 +214,7 @@ private static final long serialVersionUID = 1L;
|
|||||||
",buyerPhone=" + buyerPhone +
|
",buyerPhone=" + buyerPhone +
|
||||||
",createTimestamp=" + createTimestamp +
|
",createTimestamp=" + createTimestamp +
|
||||||
",modifyTimestamp=" + modifyTimestamp +
|
",modifyTimestamp=" + modifyTimestamp +
|
||||||
|
",isTest=" + isTest +
|
||||||
"}";
|
"}";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -10,7 +10,7 @@ import java.util.Date;import java.util.Date;
|
|||||||
/**
|
/**
|
||||||
*商品表
|
*商品表
|
||||||
* @author quyixiao
|
* @author quyixiao
|
||||||
* @since 2025-08-26
|
* @since 2025-10-14
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@Data
|
@Data
|
||||||
@ -45,6 +45,7 @@ private static final long serialVersionUID = 1L;
|
|||||||
public final static String admin_category_id4 = CLASS_NAME + "admin_category_id4"; // admin4级类目
|
public final static String admin_category_id4 = CLASS_NAME + "admin_category_id4"; // admin4级类目
|
||||||
public final static String admin_category_id5 = CLASS_NAME + "admin_category_id5"; // admin5级类目
|
public final static String admin_category_id5 = CLASS_NAME + "admin_category_id5"; // admin5级类目
|
||||||
public final static String seller_id = CLASS_NAME + "seller_id"; // 商家id
|
public final static String seller_id = CLASS_NAME + "seller_id"; // 商家id
|
||||||
|
public final static String is_test = CLASS_NAME + "is_test"; // 是否是测试单
|
||||||
//
|
//
|
||||||
@TableId(value = "id", type = IdType.AUTO)
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
private Long id;
|
private Long id;
|
||||||
@ -94,6 +95,8 @@ private static final long serialVersionUID = 1L;
|
|||||||
private String adminCategoryId5;
|
private String adminCategoryId5;
|
||||||
//商家id
|
//商家id
|
||||||
private Long sellerId;
|
private Long sellerId;
|
||||||
|
//是否是测试单
|
||||||
|
private Integer isTest;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @return
|
* @return
|
||||||
@ -454,6 +457,21 @@ private static final long serialVersionUID = 1L;
|
|||||||
this.sellerId = sellerId;
|
this.sellerId = sellerId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 是否是测试单
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public Integer getIsTest() {
|
||||||
|
return isTest;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 是否是测试单
|
||||||
|
* @param isTest
|
||||||
|
*/
|
||||||
|
public void setIsTest(Integer isTest) {
|
||||||
|
this.isTest = isTest;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return "VvProductEntity{" +
|
return "VvProductEntity{" +
|
||||||
@ -481,6 +499,7 @@ private static final long serialVersionUID = 1L;
|
|||||||
",adminCategoryId4=" + adminCategoryId4 +
|
",adminCategoryId4=" + adminCategoryId4 +
|
||||||
",adminCategoryId5=" + adminCategoryId5 +
|
",adminCategoryId5=" + adminCategoryId5 +
|
||||||
",sellerId=" + sellerId +
|
",sellerId=" + sellerId +
|
||||||
|
",isTest=" + isTest +
|
||||||
"}";
|
"}";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -49,7 +49,7 @@ public class MysqlMain_update {
|
|||||||
List<TablesBean> list = new ArrayList<TablesBean>();
|
List<TablesBean> list = new ArrayList<TablesBean>();
|
||||||
|
|
||||||
|
|
||||||
String a = "vv_buyer_address";
|
String a = "vv_buyer";
|
||||||
for (String s : a.split(",")) {
|
for (String s : a.split(",")) {
|
||||||
list.add(new TablesBean(s));
|
list.add(new TablesBean(s));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -12,24 +12,20 @@ public class AppIndexPageRequest {
|
|||||||
|
|
||||||
private int pageSize = 10;
|
private int pageSize = 10;
|
||||||
|
|
||||||
|
|
||||||
/***
|
/***
|
||||||
* 商品名称
|
* 商品名称
|
||||||
*/
|
*/
|
||||||
private String productName;
|
private String productName;
|
||||||
|
|
||||||
|
|
||||||
//一级类目id
|
//一级类目id
|
||||||
private Integer categoryId1;
|
private Integer categoryId1;
|
||||||
//二级类目
|
//二级类目
|
||||||
private Integer categoryId2;
|
private Integer categoryId2;
|
||||||
//三级类目
|
//三级类目
|
||||||
private Integer categoryId3;
|
private Integer categoryId3;
|
||||||
//是否是首页
|
|
||||||
private Integer frontPage;
|
|
||||||
|
|
||||||
|
|
||||||
//销售价格
|
//销售价格,传ASC 或 DESC
|
||||||
private String salePriceSort;
|
private String salePriceSort;
|
||||||
|
|
||||||
// 按真实销量排序,传ASC 或 DESC
|
// 按真实销量排序,传ASC 或 DESC
|
||||||
@ -39,10 +35,27 @@ public class AppIndexPageRequest {
|
|||||||
*/
|
*/
|
||||||
private String createTimestampSort;
|
private String createTimestampSort;
|
||||||
|
|
||||||
|
|
||||||
|
/***
|
||||||
|
* 如果是内部用户,可传 1,如果不是内部用户,你就传0
|
||||||
|
*/
|
||||||
|
private Integer isTest = 0 ;
|
||||||
|
|
||||||
|
|
||||||
|
/***
|
||||||
|
* 买家id
|
||||||
|
*/
|
||||||
|
private Long buyerId;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//是否是首页
|
||||||
|
private Integer frontPage;
|
||||||
/***
|
/***
|
||||||
* 状态
|
* 状态
|
||||||
*/
|
*/
|
||||||
private String status ;
|
private String status ;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -10,6 +10,7 @@ import com.heyu.api.data.dto.vv.VvProductDTO;
|
|||||||
import com.heyu.api.data.dto.vv.VvProductPropertyDTO;
|
import com.heyu.api.data.dto.vv.VvProductPropertyDTO;
|
||||||
import com.heyu.api.data.dto.vv.VvSkuDTO;
|
import com.heyu.api.data.dto.vv.VvSkuDTO;
|
||||||
import com.heyu.api.data.entity.vv.*;
|
import com.heyu.api.data.entity.vv.*;
|
||||||
|
import com.heyu.api.data.utils.NumberUtil;
|
||||||
import com.heyu.api.data.utils.R;
|
import com.heyu.api.data.utils.R;
|
||||||
import com.heyu.api.utils.ISelect;
|
import com.heyu.api.utils.ISelect;
|
||||||
import com.heyu.api.utils.PPageUtils;
|
import com.heyu.api.utils.PPageUtils;
|
||||||
@ -52,13 +53,28 @@ public class AppIndexPageController {
|
|||||||
@Autowired
|
@Autowired
|
||||||
private VvProductPropertyValueDao vvProductPropertyValueDao;
|
private VvProductPropertyValueDao vvProductPropertyValueDao;
|
||||||
|
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private VvBuyerDao vvBuyerDao ;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/***
|
/***
|
||||||
* 列表
|
* 列表 /app/index/page/list
|
||||||
*/
|
*/
|
||||||
@RequestMapping("/page/list")
|
@RequestMapping("/page/list")
|
||||||
public R list(@RequestBody AppIndexPageRequest vvProductRequest) {
|
public R list(@RequestBody AppIndexPageRequest vvProductRequest) {
|
||||||
vvProductRequest.setFrontPage(1);
|
vvProductRequest.setFrontPage(1);
|
||||||
vvProductRequest.setStatus(ProductStatusEnums.online.getStatus());
|
vvProductRequest.setStatus(ProductStatusEnums.online.getStatus());
|
||||||
|
|
||||||
|
if(NumberUtil.equals(vvProductRequest.getIsTest() ,1)){
|
||||||
|
Long buyerId = vvProductRequest.getBuyerId();
|
||||||
|
VvBuyerEntity vvBuyerEntity = vvBuyerDao.selectVvBuyerIsTestById(buyerId, 1);
|
||||||
|
if(vvBuyerEntity == null){
|
||||||
|
return R.error("非内部用户");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
PPageUtils pageUtils = PPageUtils.startPage(vvProductRequest.getPageNum(), vvProductRequest.getPageSize())
|
PPageUtils pageUtils = PPageUtils.startPage(vvProductRequest.getPageNum(), vvProductRequest.getPageSize())
|
||||||
.doSelect(new ISelect() {
|
.doSelect(new ISelect() {
|
||||||
@Override
|
@Override
|
||||||
@ -70,6 +86,7 @@ public class AppIndexPageController {
|
|||||||
vvProductRequest.getCategoryId1(),
|
vvProductRequest.getCategoryId1(),
|
||||||
vvProductRequest.getCategoryId2(),
|
vvProductRequest.getCategoryId2(),
|
||||||
vvProductRequest.getCategoryId3(),
|
vvProductRequest.getCategoryId3(),
|
||||||
|
vvProductRequest.getIsTest(),
|
||||||
vvProductRequest.getSalePriceSort(),
|
vvProductRequest.getSalePriceSort(),
|
||||||
vvProductRequest.getSaleCountSort(),
|
vvProductRequest.getSaleCountSort(),
|
||||||
vvProductRequest.getCreateTimestampSort()
|
vvProductRequest.getCreateTimestampSort()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user