feat: 新增住建厅价格计算

This commit is contained in:
han0
2024-07-12 11:11:28 +08:00
parent 44c8e8c096
commit cb0eb54984
26 changed files with 140 additions and 81 deletions

View File

@@ -26,6 +26,7 @@ def run_spider(spider):
process.start()
return pathlib.Path(filename) # .absolute()
class CookieTools:
user_agent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36'

View File

@@ -70,7 +70,7 @@ class DataFujianSpider(scrapy.Spider):
'year': response.meta['year'],
'month': response.meta['month'],
'city': response.meta['city'],
'date': datetime.date.today().strftime('%Y-%m-%d')
'date': datetime.datetime(response.meta['year'], response.meta['month'], 1).strftime('%Y-%m-%d')
}

View File

@@ -64,7 +64,8 @@ class DataJiangxiSpider(scrapy.Spider):
'date': date,
}
# todo 江西造价站入库
# todo-2 江西造价站入库
if __name__ == '__main__':
import json