File was renamed from code_volumn_manager.py |
| | |
| | | # yesterday 昨天的量 |
| | | import json |
| | | |
| | | import global_util |
| | | import gpcode_manager |
| | | from utils import global_util, tool |
| | | from db import redis_manager |
| | | import tool |
| | | from log import logger_day_volumn |
| | | from logs.log import logger_day_volumn |
| | | |
| | | __redis_manager = redis_manager.RedisManager(0) |
| | | |
| | |
| | | # 设置历史量 |
| | | def set_histry_volumn(code, max60, yesterday, max60_day=''): |
| | | redis = __redis_manager.getRedis() |
| | | global_util.max60_volumn[code] = (max60,max60_day) |
| | | global_util.max60_volumn[code] = (max60, max60_day) |
| | | global_util.yesterday_volumn[code] = yesterday |
| | | redis.setex("volumn_max60-{}".format(code), tool.get_expire(), json.dumps((max60,max60_day))) |
| | | redis.setex("volumn_max60-{}".format(code), tool.get_expire(), json.dumps((max60, max60_day))) |
| | | redis.setex("volumn_yes-{}".format(code), tool.get_expire(), yesterday) |
| | | |
| | | |