店铺删除接口
This commit is contained in:
parent
aace226c90
commit
fb9246e5e0
|
|
@ -10,6 +10,7 @@ import com.czg.annotation.SaAdminCheckPermission;
|
|||
import com.czg.annotation.SaAdminCheckRole;
|
||||
import com.czg.resp.CzgResult;
|
||||
import com.mybatisflex.core.paginate.Page;
|
||||
import com.mybatisflex.core.query.QueryWrapper;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
|
@ -62,9 +63,21 @@ public class ShopInfoController {
|
|||
* 店铺编辑
|
||||
* 权限标识: shopInfo:edit
|
||||
*/
|
||||
@SaAdminCheckRole("管理员")
|
||||
@SaAdminCheckPermission("shopInfo:edit")
|
||||
@PutMapping
|
||||
public CzgResult<?> edit(@RequestBody @Validated ShopInfoEditDTO shopInfoEditDTO) {
|
||||
return CzgResult.success(shopInfoService.edit(shopInfoEditDTO));
|
||||
}
|
||||
|
||||
/**
|
||||
* 店铺删除
|
||||
* 权限标识: shopInfo:del
|
||||
*/
|
||||
@SaAdminCheckRole("管理员")
|
||||
@SaAdminCheckPermission("shopInfo:del")
|
||||
@DeleteMapping
|
||||
public CzgResult<?> delete(@RequestParam Integer shopId) {
|
||||
return CzgResult.success(shopInfoService.remove(new QueryWrapper().eq(ShopInfo::getId, shopId)));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue