Commit 635bd810 by v_vjyjiang

d

parent 83314965
...@@ -6,19 +6,20 @@ class ChannelCache extends CacheBase { ...@@ -6,19 +6,20 @@ class ChannelCache extends CacheBase {
super(); super();
this.channelDao = system.getObject("db.common.channelDao"); this.channelDao = system.getObject("db.common.channelDao");
} }
isdebug() { isdebug () {
return settings.env == "dev"; return true;
} }
desc() { desc () {
return "缓存本地应用对象"; return "缓存本地应用对象";
} }
prefix() { prefix () {
return "g_channel_cm:" 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(
{where: { routehost: inputkey}, {
include:[{model:this.db.models.pathtomethod,as:"pts"}] where: { routehost: inputkey },
include: [{ model: this.db.models.pathtomethod, as: "pts" }]
}); });
if (configValue) { if (configValue) {
return JSON.stringify(configValue); return JSON.stringify(configValue);
......
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