fix
This commit is contained in:
parent
2b4627a062
commit
36f2ebbc07
@ -24,7 +24,7 @@ def get_area_by_locationid(ldid):
|
||||
sql = f"select area from location where id={ldid}"
|
||||
data = mydb.query(sql)
|
||||
if data:
|
||||
return data[0][0]
|
||||
return data[0][0].replace("[", "").replace("]", "").replace('"', "")
|
||||
else:
|
||||
log.error(f"get area from location failed!,sql={sql}")
|
||||
return area
|
||||
@ -119,13 +119,13 @@ def send_cache_data():
|
||||
log.error("split data failed", exc_info=True)
|
||||
# 检查ID是否存在播放列表中,以及播放次数是否完毕
|
||||
if all:
|
||||
pdb.set_trace()
|
||||
# log.info(f"get data was {all}!\n")
|
||||
for line in all:
|
||||
if line:
|
||||
print(f"1={line}")
|
||||
locationid = json.loads(line.get('locationid'))
|
||||
for item in locationid:
|
||||
pdb.set_trace()
|
||||
area = get_area_by_locationid(item)
|
||||
for one in area.split(','):
|
||||
key = f"ad::{line.get('gameid', 0)}::{line.get('channelid', 0)}::{one}::{item}"
|
||||
|
Loading…
x
Reference in New Issue
Block a user