Commit c4c0d8d1 by 岳巧源

add dict

parent cc3820fd
Showing with 9 additions and 1 deletions
...@@ -6,6 +6,7 @@ import time ...@@ -6,6 +6,7 @@ import time
import pymysql import pymysql
from common import request_to_jd_vc from common import request_to_jd_vc
import redis
# TODO 通知基石平台告警 ??? 是不是按照原来的方式?? 用is_mapping 字段来进行标识??? # TODO 通知基石平台告警 ??? 是不是按照原来的方式?? 用is_mapping 字段来进行标识???
...@@ -213,12 +214,19 @@ def update_ext_attr_by_class_ids(conf: dict): ...@@ -213,12 +214,19 @@ def update_ext_attr_by_class_ids(conf: dict):
def insert_ext_attr_to_redis(class_id, attr_id): def insert_ext_attr_to_redis(class_attr_map: dict):
""" """
拓展属性存到 redis中 拓展属性存到 redis中
key : jd_ext_attr key : jd_ext_attr
field: 分类id field: 分类id
value: 拓展属性id数组。 value: 拓展属性id数组。
for example: jd_ext_attr 33811 [235914, 562124]
class_attr_map 结构:
{
33811: [235914, 562124],
33471: [1001074361, 236705]
}
""" """
......
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 sign in to comment