This commit is contained in:
ls
2024-12-03 00:02:44 +08:00
parent 30aaee523c
commit 215444ac4d
4 changed files with 203 additions and 180 deletions

View File

@@ -76,7 +76,9 @@ def scrape():
print("total:" + str(json_data['RECORDS']))
for index, row in enumerate(json_data['ROWS']):
print("index:"+str(index))
part_number = row[0] # 部件编号
table_id= get_md5(''.join([row[0], row[1], row[2]]))
part_number =table_id # row[0] # 部件编号
file_links_str = row[4] # 文件链接
# 使用正则表达式分隔文件名
@@ -229,8 +231,7 @@ def scrape():
manufacturer=row[2]
experiment_date=row[3]
origin_data = ','.join(row)
data_db = [get_md5(''.join([device_name,device_function,manufacturer])), 'Crawler', datetime.now(), None, None, None,
data_db = [table_id, 'Crawler', datetime.now(), None, None, None,
device_type,
device_name, device_mode,
device_function,