perf: 商品接口增加typeEnum
This commit is contained in:
parent
4ba7c7c4e7
commit
56d8195450
|
|
@ -56,11 +56,10 @@ public class TbPlaceController {
|
||||||
@ApiOperation("查询/product")
|
@ApiOperation("查询/product")
|
||||||
public ResponseEntity<Object> queryActivateTbProductInfo(@RequestParam(defaultValue = "0") Integer page,
|
public ResponseEntity<Object> queryActivateTbProductInfo(@RequestParam(defaultValue = "0") Integer page,
|
||||||
@RequestParam(defaultValue = "30") Integer size,
|
@RequestParam(defaultValue = "30") Integer size,
|
||||||
@RequestParam(required = false) String typeEnum,
|
|
||||||
@RequestParam(required = false) Integer categoryId,
|
@RequestParam(required = false) Integer categoryId,
|
||||||
@RequestParam Integer shopId,
|
@RequestParam Integer shopId,
|
||||||
@RequestParam(required = false) Integer productId) {
|
@RequestParam(required = false) Integer productId) {
|
||||||
return new ResponseEntity<>(tbProductService.activateProduct(page, size, categoryId, shopId, productId, typeEnum), HttpStatus.OK);
|
return new ResponseEntity<>(tbProductService.activateProduct(page, size, categoryId, shopId, productId), HttpStatus.OK);
|
||||||
}
|
}
|
||||||
|
|
||||||
public TbPlaceController(TbShopTableService tbShopTableService, TbProductService tbProductService, RabbitMsgUtils rabbitMsgUtils) {
|
public TbPlaceController(TbShopTableService tbShopTableService, TbProductService tbProductService, RabbitMsgUtils rabbitMsgUtils) {
|
||||||
|
|
|
||||||
|
|
@ -758,11 +758,11 @@ public class TbProductServiceImpl implements TbProductService {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Object activateProduct(Integer page, Integer size, Integer categoryId, Integer shopId, Integer productId, String typeEnum) {
|
public Object activateProduct(Integer page, Integer size, Integer categoryId, Integer shopId, Integer productId) {
|
||||||
com.baomidou.mybatisplus.extension.plugins.pagination.Page<TbProduct> page1 = new com.baomidou.mybatisplus.extension.plugins.pagination.Page<>(page, size);
|
com.baomidou.mybatisplus.extension.plugins.pagination.Page<TbProduct> page1 = new com.baomidou.mybatisplus.extension.plugins.pagination.Page<>(page, size);
|
||||||
QueryWrapper<TbProduct> queryWrapper = new QueryWrapper<>();
|
QueryWrapper<TbProduct> queryWrapper = new QueryWrapper<>();
|
||||||
queryWrapper.eq("is_del", 0)
|
queryWrapper.eq("is_del", 0)
|
||||||
.eq("type_enum", typeEnum)
|
.in("type_enum", "sku", "normal")
|
||||||
.eq("shop_id", shopId)
|
.eq("shop_id", shopId)
|
||||||
.eq("is_delete", 0)
|
.eq("is_delete", 0)
|
||||||
.eq("status", 1)
|
.eq("status", 1)
|
||||||
|
|
|
||||||
|
|
@ -106,5 +106,5 @@ public interface TbProductService {
|
||||||
*/
|
*/
|
||||||
void returnStockByPro(Integer productId, Integer productSkuId, Integer num);
|
void returnStockByPro(Integer productId, Integer productSkuId, Integer num);
|
||||||
|
|
||||||
Object activateProduct(Integer page, Integer size, Integer categoryId, Integer shopId, Integer productId, String typeEnum);
|
Object activateProduct(Integer page, Integer size, Integer categoryId, Integer shopId, Integer productId);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue