|
@@ -73,7 +73,13 @@ class NotificationView(View):
|
|
pkey = '{uid}_{channel}_{event_type}_ptl'.format(uid=uid, event_type=event_type, channel=channel)
|
|
pkey = '{uid}_{channel}_{event_type}_ptl'.format(uid=uid, event_type=event_type, channel=channel)
|
|
# ykey = 'MUJ887NLR8K8GBM9111A_redis_qs'.format(uid=uid)
|
|
# ykey = 'MUJ887NLR8K8GBM9111A_redis_qs'.format(uid=uid)
|
|
ykey = '{uid}_redis_qs'.format(uid=uid)
|
|
ykey = '{uid}_redis_qs'.format(uid=uid)
|
|
- dkey = '{uid}_{channel}_{event_type}_flag'.format(uid=uid, event_type=event_type, channel=channel)
|
|
|
|
|
|
+ # dkey = '{uid}_{channel}_{event_type}_flag'.format(uid=uid, event_type=event_type, channel=channel)
|
|
|
|
+ is_sys_msg = self.is_sys_msg(int(event_type))
|
|
|
|
+ if is_sys_msg is True:
|
|
|
|
+ dkey = '{uid}_{channel}_{event_type}_flag'.format(uid=uid, event_type=event_type, channel=channel)
|
|
|
|
+ else:
|
|
|
|
+ dkey = '{uid}_{channel}_flag'.format(uid=uid, channel=channel)
|
|
|
|
+
|
|
# 判断redisObj.get_data(key=pkey):不为空
|
|
# 判断redisObj.get_data(key=pkey):不为空
|
|
redisObj = RedisObject(db=6)
|
|
redisObj = RedisObject(db=6)
|
|
have_ykey = redisObj.get_data(key=ykey) # uid_set 数据库缓存
|
|
have_ykey = redisObj.get_data(key=ykey) # uid_set 数据库缓存
|
|
@@ -124,7 +130,7 @@ class NotificationView(View):
|
|
res_data = {'code': 0, 'msg': 'no redi_list success!'}
|
|
res_data = {'code': 0, 'msg': 'no redi_list success!'}
|
|
return JsonResponse(status=200, data=res_data)
|
|
return JsonResponse(status=200, data=res_data)
|
|
|
|
|
|
- is_sys_msg = self.is_sys_msg(int(event_type))
|
|
|
|
|
|
+ # is_sys_msg = self.is_sys_msg(int(event_type))
|
|
nickname = redis_list[0]['uid_set__nickname']
|
|
nickname = redis_list[0]['uid_set__nickname']
|
|
detect_interval = redis_list[0]['uid_set__detect_interval']
|
|
detect_interval = redis_list[0]['uid_set__detect_interval']
|
|
detect_group = redis_list[0]['uid_set__detect_group']
|
|
detect_group = redis_list[0]['uid_set__detect_group']
|