拖动排序
This commit is contained in:
@@ -18,6 +18,7 @@ import java.util.List;
|
||||
|
||||
/**
|
||||
* 支付方式管理
|
||||
*
|
||||
* @author Administrator
|
||||
*/
|
||||
@RestController
|
||||
@@ -60,7 +61,19 @@ public class ShopPayTypeController {
|
||||
@PostMapping
|
||||
public CzgResult<Boolean> add(@RequestBody @Validated(InsertGroup.class) ShopPayTypeAddDTO shopPayTypeAddDTO) {
|
||||
ShopPayType shopPayType = BeanUtil.copyProperties(shopPayTypeAddDTO, ShopPayType.class);
|
||||
return CzgResult.success(shopPayTypeService.add(StpKit.USER.getShopId(),shopPayType));
|
||||
return CzgResult.success(shopPayTypeService.add(StpKit.USER.getShopId(), shopPayType));
|
||||
}
|
||||
|
||||
/**
|
||||
* 支付类型拖动排序
|
||||
*
|
||||
* @param shopId 店铺ID
|
||||
* @param id 拖动的支付类型ID
|
||||
* @param targetSort 目标位置排序号
|
||||
*/
|
||||
@PostMapping("/sort")
|
||||
public CzgResult<Void> sort(@RequestParam Long shopId, @RequestParam Integer id, @RequestParam Integer targetSort) {
|
||||
shopPayTypeService.updateSort(shopId, id, targetSort);
|
||||
return CzgResult.success();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user