- 注释掉老user与auth相关的代码

This commit is contained in:
gazebo
2019-09-24 16:39:50 +08:00
parent 72c9889d10
commit 412b11396a
18 changed files with 1172 additions and 1442 deletions

View File

@@ -179,15 +179,15 @@ func getStoresSql(ctx *jxcontext.Context, keyword string, params map[string]inte
sqlWhereParams = append(sqlWhereParams, keywordLike, keywordLike, keywordLike, keywordLike, keywordLike, keywordLike, keywordLike, keywordLike, keywordLike, keywordLike, keywordLike)
if keywordInt64, err2 := strconv.ParseInt(keyword, 10, 64); err2 == nil {
if !globals.DisableWXAuth1 && jxutils.IsLegalMobileNumber(keywordInt64) {
sql += `
LEFT JOIN weixins wx1 ON t1.id = wx1.jxstoreid AND wx1.parentid = -1 AND wx1.tel = ?
LEFT JOIN weixins wx2 ON t1.id = wx2.jxstoreid AND wx2.parentid = -1
LEFT JOIN weixins wx3 ON wx3.parentid = wx2.id AND wx3.tel = ?
`
sqlParams = append(sqlParams, keywordInt64, keywordInt64)
sqlWhere += " OR wx1.id IS NOT NULL OR wx3.id IS NOT NULL"
}
// if !globals.DisableWXAuth1 && jxutils.IsLegalMobileNumber(keywordInt64) {
// sql += `
// LEFT JOIN weixins wx1 ON t1.id = wx1.jxstoreid AND wx1.parentid = -1 AND wx1.tel = ?
// LEFT JOIN weixins wx2 ON t1.id = wx2.jxstoreid AND wx2.parentid = -1
// LEFT JOIN weixins wx3 ON wx3.parentid = wx2.id AND wx3.tel = ?
// `
// sqlParams = append(sqlParams, keywordInt64, keywordInt64)
// sqlWhere += " OR wx1.id IS NOT NULL OR wx3.id IS NOT NULL"
// }
sqlWhere += " OR t1.id = ? OR t1.city_code = ? OR t1.district_code = ?"
sqlWhereParams = append(sqlWhereParams, keywordInt64, keywordInt64, keywordInt64)
if jxutils.GuessVendorIDFromVendorStoreID(keywordInt64) != model.VendorIDUnknown {