整体优化完善接口与数据权限检查
This commit is contained in:
@@ -1,30 +1,55 @@
|
||||
package core
|
||||
|
||||
const (
|
||||
ScopePermissionRead = string("permission:read")
|
||||
ScopePermissionWrite = string("permission:write")
|
||||
ScopePermission = string("permission") // 权限
|
||||
ScopePermissionRead = string("permission:read") // 读取权限列表
|
||||
ScopePermissionWrite = string("permission:write") // 写入权限
|
||||
|
||||
ScopeAdminRoleRead = string("admin_role:read")
|
||||
ScopeAdminRoleWrite = string("admin_role:write")
|
||||
ScopeAdminRole = string("admin_role") // 管理员角色
|
||||
ScopeAdminRoleRead = string("admin_role:read") // 读取管理员角色列表
|
||||
ScopeAdminRoleWrite = string("admin_role:write") // 写入管理员角色
|
||||
|
||||
ScopeAdminRead = string("admin:read")
|
||||
ScopeAdminWrite = string("admin:write")
|
||||
ScopeAdmin = string("admin") // 管理员
|
||||
ScopeAdminRead = string("admin:read") // 读取管理员列表
|
||||
ScopeAdminWrite = string("admin:write") // 写入管理员
|
||||
|
||||
ScopeProductRead = string("product:read")
|
||||
ScopeProductWrite = string("product:write")
|
||||
ScopeProduct = string("product") // 产品
|
||||
ScopeProductRead = string("product:read") // 读取产品列表
|
||||
ScopeProductWrite = string("product:write") // 写入产品
|
||||
|
||||
ScopeProductSkuRead = string("product_sku:read")
|
||||
ScopeProductSkuWrite = string("product_sku:write")
|
||||
ScopeProductSku = string("product_sku") // 产品套餐
|
||||
ScopeProductSkuRead = string("product_sku:read") // 读取产品套餐列表
|
||||
ScopeProductSkuWrite = string("product_sku:write") // 写入产品套餐
|
||||
|
||||
ScopeProductDiscountRead = string("product_discount:read")
|
||||
ScopeProductDiscountWrite = string("product_discount:write")
|
||||
ScopeDiscount = string("discount") // 折扣
|
||||
ScopeDiscountRead = string("discount:read") // 读取折扣列表
|
||||
ScopeDiscountWrite = string("discount:write") // 写入折扣
|
||||
|
||||
ScopeResourceRead = string("resource:read")
|
||||
ScopeResourceWrite = string("resource:write")
|
||||
ScopeResource = string("resource") // 用户套餐
|
||||
ScopeResourceRead = string("resource:read") // 读取用户套餐列表
|
||||
ScopeResourceWrite = string("resource:write") // 写入用户套餐
|
||||
|
||||
ScopeUserRead = string("user:read")
|
||||
ScopeUserWrite = string("user:write")
|
||||
ScopeUser = string("user") // 用户
|
||||
ScopeUserRead = string("user:read") // 读取用户列表
|
||||
ScopeUserWrite = string("user:write") // 写入用户
|
||||
|
||||
ScopeCouponRead = string("coupon:read")
|
||||
ScopeCouponWrite = string("coupon:write")
|
||||
ScopeCoupon = string("coupon") // 优惠券
|
||||
ScopeCouponRead = string("coupon:read") // 读取优惠券列表
|
||||
ScopeCouponWrite = string("coupon:write") // 写入优惠券
|
||||
|
||||
ScopeBatch = string("batch") // 批次
|
||||
ScopeBatchRead = string("batch:read") // 读取批次列表
|
||||
ScopeBatchWrite = string("batch:write") // 写入批次
|
||||
|
||||
ScopeChannel = string("channel") // IP
|
||||
ScopeChannelRead = string("channel:read") // 读取 IP 列表
|
||||
ScopeChannelWrite = string("channel:write") // 写入 IP
|
||||
|
||||
ScopeTrade = string("trade") // 交易
|
||||
ScopeTradeRead = string("trade:read") // 读取交易列表
|
||||
ScopeTradeWrite = string("trade:write") // 写入交易
|
||||
|
||||
ScopeBill = string("bill") // 账单
|
||||
ScopeBillRead = string("bill:read") // 读取账单列表
|
||||
ScopeBillWrite = string("bill:write") // 写入账单
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user