Commit 67daf6b0 by 蒋勇

d

parent 0c8181a8
...@@ -14,7 +14,7 @@ class AppCache extends CacheBase{ ...@@ -14,7 +14,7 @@ class AppCache extends CacheBase{
return "缓存本地应用对象"; return "缓存本地应用对象";
} }
prefix(){ prefix(){
return "g_applocal_" return "g_applocal_cm:"
} }
async buildCacheVal(cachekey,inputkey, val, ex, ...items) { async buildCacheVal(cachekey,inputkey, val, ex, ...items) {
const configValue=await this.appDao.findOne({appkey:inputkey}); const configValue=await this.appDao.findOne({appkey:inputkey});
......
...@@ -13,7 +13,7 @@ class ChannelCache extends CacheBase { ...@@ -13,7 +13,7 @@ class ChannelCache extends CacheBase {
return "缓存本地应用对象"; return "缓存本地应用对象";
} }
prefix() { prefix() {
return "g_channel_" return "g_channel_cm:"
} }
async buildCacheVal(cachekey, inputkey, val, ex, ...items) { async buildCacheVal(cachekey, inputkey, val, ex, ...items) {
const configValue = await this.channelDao.model.findOne( const configValue = await this.channelDao.model.findOne(
......
...@@ -12,7 +12,7 @@ class ClientBindBizUserCache extends CacheBase{ ...@@ -12,7 +12,7 @@ class ClientBindBizUserCache extends CacheBase{
return "缓存本地应用对象"; return "缓存本地应用对象";
} }
prefix(){ prefix(){
return "g_client2bizuser_" return "g_client2bizuser_cm:"
} }
async buildCacheVal(cachekey,inputkey, val, ex, ...items) { async buildCacheVal(cachekey,inputkey, val, ex, ...items) {
return JSON.stringify(val); return JSON.stringify(val);
......
...@@ -14,7 +14,7 @@ class CodeCache extends CacheBase{ ...@@ -14,7 +14,7 @@ class CodeCache extends CacheBase{
return "缓存code子系统用户登录信息对象"; return "缓存code子系统用户登录信息对象";
} }
prefix(){ prefix(){
return "g_code_userlocal_" return "g_code_userlocal_cm:"
} }
async buildCacheVal(cachekey,inputkey, val, ex, ...items) { async buildCacheVal(cachekey,inputkey, val, ex, ...items) {
if (val) { if (val) {
......
...@@ -14,7 +14,7 @@ class CompanyCache extends CacheBase{ ...@@ -14,7 +14,7 @@ class CompanyCache extends CacheBase{
return "缓存统一公司对象"; return "缓存统一公司对象";
} }
prefix(){ prefix(){
return "gc_companylocal_" return "gc_companylocal_cm:"
} }
async buildCacheVal(cachekey,inputkey, val, ex, ...items) { async buildCacheVal(cachekey,inputkey, val, ex, ...items) {
const configValue=await this.companyDao.findOne({companykey:inputkey}); const configValue=await this.companyDao.findOne({companykey:inputkey});
......
...@@ -13,7 +13,7 @@ class TxCache extends CacheBase { ...@@ -13,7 +13,7 @@ class TxCache extends CacheBase {
return "缓存缓存腾讯队列信息"; return "缓存缓存腾讯队列信息";
} }
prefix() { prefix() {
return "g_txInfo_" return "g_txInfo_cm:"
} }
async buildCacheVal(cachekey, inputkey, val, ex, ...items) { async buildCacheVal(cachekey, inputkey, val, ex, ...items) {
if (val) { if (val) {
......
...@@ -13,7 +13,7 @@ class UserCache extends CacheBase{ ...@@ -13,7 +13,7 @@ class UserCache extends CacheBase{
return "缓存本地应用对象"; return "缓存本地应用对象";
} }
prefix(){ prefix(){
return "g_userlocal_" return "g_userlocal_cm:"
} }
async buildCacheVal(cachekey,inputkey, val, ex, ...items) { async buildCacheVal(cachekey,inputkey, val, ex, ...items) {
const configValue = await this.userDao.model.findAll({ const configValue = await this.userDao.model.findAll({
......
...@@ -14,7 +14,7 @@ class VCodeCache extends CacheBase { ...@@ -14,7 +14,7 @@ class VCodeCache extends CacheBase {
return "缓存给手机发送的验证码60妙"; return "缓存给手机发送的验证码60妙";
} }
prefix() { prefix() {
return "g_vcode_" return "g_vcode_cm:"
} }
async buildCacheVal(cachekey, inputkey, val, ex, ...items) { async buildCacheVal(cachekey, inputkey, val, ex, ...items) {
//inputkey采用appkey_mobile的形式 //inputkey采用appkey_mobile的形式
......
...@@ -385,6 +385,7 @@ class UserService extends ServiceBase { ...@@ -385,6 +385,7 @@ class UserService extends ServiceBase {
*/ */
async getBizUserForBizChance(clientMobile, spName, productCatName,regionName) { async getBizUserForBizChance(clientMobile, spName, productCatName,regionName) {
var self = this var self = this
clientMobile=clientMobile+"_"+spName
//按照服务商名字查询到公司,按照公司查询出users,条件是可以接受派单任务,并且技能标签含有,产品类别名称 //按照服务商名字查询到公司,按照公司查询出users,条件是可以接受派单任务,并且技能标签含有,产品类别名称
return this.db.transaction(async function (t) { return this.db.transaction(async function (t) {
//先检查缓存是否存在bizuser //先检查缓存是否存在bizuser
...@@ -463,7 +464,7 @@ class UserService extends ServiceBase { ...@@ -463,7 +464,7 @@ class UserService extends ServiceBase {
* @param {*} regionName 区域 * @param {*} regionName 区域
*/ */
async getBizUserForDelivery(xclientMobile, spName, productCatName, skucode,regionName) { async getBizUserForDelivery(xclientMobile, spName, productCatName, skucode,regionName) {
let clientMobile='fordeliver'+xclientMobile let clientMobile='fordeliver'+xclientMobile+"_"+spName
var self = this var self = this
//按照服务商名字查询到公司,按照公司查询出users,条件是可以接受派单任务,并且技能标签含有,产品类别名称 //按照服务商名字查询到公司,按照公司查询出users,条件是可以接受派单任务,并且技能标签含有,产品类别名称
return this.db.transaction(async function (t) { return this.db.transaction(async function (t) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment