diff --git a/business/auth2/auth2.go b/business/auth2/auth2.go index fdd440947..949f35afd 100644 --- a/business/auth2/auth2.go +++ b/business/auth2/auth2.go @@ -161,7 +161,6 @@ func getFixedTokenName(token string) *AuthInfo { func createAuthInfo(user IUser, authBindInfo *AuthBindEx) (authInfo *AuthInfo) { token, tokenType := createToken(user, authBindInfo) //user为空 tokenType=2 - globals.SugarLogger.Debug("token,tokenType,user============", token, tokenType, user) expireDuration := DefTokenDuration authInfo = &AuthInfo{ AuthBindInfo: authBindInfo, @@ -249,7 +248,6 @@ func LoginInternal(ctx *Context, authType, authID, authIDType, authSecret string } realAuthID = user.GetID() } - globals.SugarLogger.Debug("打印realAuthID检测是否为空==================", realAuthID) if authBindEx, err = handler.VerifySecret(realAuthID, authSecret); err == nil { globals.SugarLogger.Debugf("Login authBindEx", utils.Format4Output(authBindEx, false)) if authBindEx == nil { // mobile, email会返回nil(表示不会新建AuthBind实体) @@ -282,7 +280,6 @@ func LoginInternal(ctx *Context, authType, authID, authIDType, authSecret string } } authInfo = createAuthInfo(user, authBindEx) - globals.SugarLogger.Debug("authInfo==================", authInfo) if user != nil && user.GetID() != "" { userProvider.UpdateLastLogin(user.GetID(), authType, ctx.GetRealRemoteIP()) } @@ -378,14 +375,12 @@ func AddAuthBind(user IUser, newAuthInfo *AuthInfo) (err error) { } RemoveUserInfo(newAuthInfo.Token) if newAuthInfo.AuthBindInfo.Type == AuthTypeMobile { - globals.SugarLogger.Debug("进入AuthTypeMobile,输出newAuthInfo.AuthBindInfo.AuthID", newAuthInfo.AuthBindInfo.AuthID) err = userProvider.UpdateUserMobile(user.GetID(), newAuthInfo.AuthBindInfo.AuthID) } else if newAuthInfo.AuthBindInfo.Type == AuthTypeEmail { err = userProvider.UpdateUserEmail(user.GetID(), newAuthInfo.AuthBindInfo.AuthID) } else { if handler := authers[newAuthInfo.AuthBindInfo.Type]; handler != nil { newAuthInfo.AuthBindInfo.UserID = user.GetID() - globals.SugarLogger.Debug("进入AddAuthBind获取userID", newAuthInfo.AuthBindInfo.UserID) handler.UnbindAuth(user.GetID(), newAuthInfo.GetAuthType(), newAuthInfo.GetAuthTypeID(), user.GetName()) err = handler.AddAuthBind(newAuthInfo.AuthBindInfo, user.GetName()) } else { @@ -398,7 +393,6 @@ func AddAuthBind(user IUser, newAuthInfo *AuthInfo) (err error) { func AddAuthBindWithMobile(authInfo *AuthInfo, mobile string) (err error) { if handler := authers[authInfo.AuthBindInfo.Type]; handler != nil { user, err := dao.GetUserByID(dao.GetDB(), "mobile", mobile) - globals.SugarLogger.Debug("user===============", user) if err != nil { return errors.New("此接口有执行顺序,请先调用注册登录接口:【第一步:Login,第二不:TiktokDecrypt】") } diff --git a/business/jxstore/cms/store.go b/business/jxstore/cms/store.go index 1d65ed5b5..581ae4f3b 100644 --- a/business/jxstore/cms/store.go +++ b/business/jxstore/cms/store.go @@ -5664,13 +5664,11 @@ func FilterByB2B(locationList []*common.Store4User, token string) (retVal []*com if err != nil { return nil, "", err } - globals.SugarLogger.Debug("检测数据userAuth,user,total==============", userAuth, user, total) // 获取位置附近门店列表 storeIDs := make([]int, 0, len(locationList)) for _, v := range locationList { storeIDs = append(storeIDs, v.ID) } - globals.SugarLogger.Debug("检测数据locationList,storeIDs==============", locationList, storeIDs) // 判断门店是不是b2b门店,如果是,用户必须为系统管理员(门店老板和运营人员) store, err := dao.GetStoreList(dao.GetDB(), storeIDs, nil, nil, nil, nil, "") if err != nil { @@ -5710,7 +5708,7 @@ func FilterByB2B(locationList []*common.Store4User, token string) (retVal []*com //首页信息展示 //func GetHomePageByLocation(locationList []*common.Store4User, token string) (interface{}, string, error) { // var ( -// //ctx *jxcontext.Context +// //ctx *jxcontext.Context // ) // // 获取用户权限,如普通用户不展示b2b相关目录,门店老板或者管理则展示全部 // result, _, err := FilterByB2B(locationList, token) @@ -5719,8 +5717,9 @@ func FilterByB2B(locationList []*common.Store4User, token string) (retVal []*com // } // for _, v := range result { // //获取门店信息 -// //storeInfos, err := GetStores(ctx, ) +// store, err := GetStores(ctx, ) // //获取热销商品 +// // //获取满减策略 // } // diff --git a/controllers/cms_store.go b/controllers/cms_store.go index 688545da1..58e6d9abc 100644 --- a/controllers/cms_store.go +++ b/controllers/cms_store.go @@ -9,6 +9,7 @@ import ( "git.rosy.net.cn/jx-callback/business/jxutils" "git.rosy.net.cn/jx-callback/business/jxutils/netprinter" "git.rosy.net.cn/jx-callback/business/model" + "git.rosy.net.cn/jx-callback/globals" "git.rosy.net.cn/jx-callback/globals/api" "github.com/astaxie/beego/server/web" ) @@ -63,6 +64,7 @@ func (c *StoreController) GetStores() { if err != nil { return nil, "", err } + globals.SugarLogger.Debug("检测数据param", params) retVal, err = cms.GetStores(params.Ctx, params.Keyword, params.MapData, params.Offset, params.PageSize, timeList[0], timeList[1], params.OrderCountFrom, params.OrderCountTo) return retVal, "", err }) diff --git a/controllers/cms_store_sku.go b/controllers/cms_store_sku.go index 6fe6d6743..2e128570f 100644 --- a/controllers/cms_store_sku.go +++ b/controllers/cms_store_sku.go @@ -1,11 +1,9 @@ package controllers import ( + "git.rosy.net.cn/baseapi/platformapi/jdapi" "git.rosy.net.cn/jx-callback/business/auth2" "git.rosy.net.cn/jx-callback/business/model" - "git.rosy.net.cn/jx-callback/globals" - - "git.rosy.net.cn/baseapi/platformapi/jdapi" "errors" "git.rosy.net.cn/jx-callback/business/jxstore/cms" @@ -54,7 +52,6 @@ type StoreSkuController struct { func (c *StoreSkuController) GetStoreSkus() { c.callGetStoreSkus(func(params *tStoreSkuGetStoreSkusParams) (retVal interface{}, errCode string, err error) { var skuIDs []int - globals.SugarLogger.Debug("检测param=============", params) if err = jxutils.Strings2Objs(params.SkuIDs, &skuIDs); err == nil { retVal, err = cms.GetStoreSkus(params.Ctx, params.StoreID, skuIDs, params.IsFocus, params.Keyword, params.IsBySku, params.IsAct, params.MapData, params.Offset, params.PageSize) }