Commit 83dc4db9 authored by 谢祁峰's avatar 谢祁峰

fix

parent 5ed0796d
...@@ -613,19 +613,19 @@ class CollectData(object): ...@@ -613,19 +613,19 @@ class CollectData(object):
(str(data['SYS']['action']), str(device_id), (str(data['SYS']['action']), str(device_id),
str(tag_query_results_multi))) str(tag_query_results_multi)))
# 首页搜索精准匹配标签关键字进linucb # 首页搜索精准匹配标签关键字进linucb
elif 'SYS' in data and 'APP' in data and 'action' in data['SYS'] and data['SYS'][ elif 'SYS' in data and 'APP' in data and 'action' in data['SYS'] and "api/v1/cards/topic" in data['SYS'][
'action'] == "api/v1/cards/topic": 'action'] :
tag_name = raw_val_dict["APP"].get("query", "") tag_name = raw_val_dict["APP"].get("query", "")
tag_id = raw_val_dict["APP"].get("action") tag_id = raw_val_dict["APP"].get("action")
tag_list = list(Tag.objects.using(settings.SLAVE1_DB_NAME).filter( tag_list = list(Tag.objects.using(settings.SLAVE1_DB_NAME).filter(
tag=tag_name).values_list("id")) tag=tag_name).values_list("id"))
tag_list.append(tag_id) tag_list.append(tag_id)
logging.info("action=cards_topic,tagid_list:%s" % tag_list) logging.info("action=home_page_search,tagid_list:%s" % tag_list)
device_id = raw_val_dict["device"]["device_id"] device_id = raw_val_dict["device"]["device_id"]
user_id = raw_val_dict["user_id"] if "user_id" in raw_val_dict else None user_id = raw_val_dict["user_id"] if "user_id" in raw_val_dict else None
self.transfer_update_recommend_tag_list(device_id, user_feature, user_id, tag_list, self.transfer_update_recommend_tag_list(device_id, user_feature, user_id, tag_list,
5) 5)
logging.info("update lintag success") logging.info("action=home_page_search,update lintag success")
# (客户端创建回答,后台创建回答或修改回答关联标签关键字进linucb # (客户端创建回答,后台创建回答或修改回答关联标签关键字进linucb
elif 'SYS' in data and 'APP' in data and 'action' in data['SYS'] and \ elif 'SYS' in data and 'APP' in data and 'action' in data['SYS'] and \
(data['SYS']['action'] in ("venus/community/topic/create", "venus/sun/topic/edit")): (data['SYS']['action'] in ("venus/community/topic/create", "venus/sun/topic/edit")):
......
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