修改商城权限,让登录用户可以看到数据

This commit is contained in:
邹宗楠
2022-03-28 19:06:01 +08:00
parent 147830ce3b
commit abe967dd8e
6 changed files with 15 additions and 2 deletions

View File

@@ -736,7 +736,8 @@ func getGetStoresSkusBaseSQL(db *dao.DaoDB, storeIDs, skuIDs []int, upcs []strin
func GetStoresSkus(ctx *jxcontext.Context, storeIDs, skuIDs []int, upcs []string, isFocus, isHighPrice bool, priceType int, keyword string, isBySku, isAct bool, params map[string]interface{}, offset, pageSize int) (skuNamesInfo *dao.StoreSkuNamesInfo, err error) {
//权限
if permission.IsRoled(ctx) { // 管理员不进入
if permission.IsRoled(ctx) || auth2.WeCartAppID != ctx.GetLoginInfo().GetIsWeCartApp() { // 管理员不进入,商城不进入
if storeIDsMap, err := permission.GetUserStoresResultMap(ctx.GetUserID()); err == nil {
var storeIDs2 []int
if len(storeIDs) > 0 {