add method to get old valid contact list

This commit is contained in:
2024-09-25 22:49:51 +02:00
parent e411c01d5d
commit 1a1788c9d7
@@ -40,7 +40,7 @@ def write_contact_with_ip_info_to_file(contact_list):
col = 0 col = 0
# Create a workbook and add a worksheet. # Create a workbook and add a worksheet.
workbook = xlsxwriter.Workbook('ip_info_{}.xlsx'.format(len(contact_list))) workbook = xlsxwriter.Workbook('ip_info_{}.xlsx'.format(len(contact_list)))
header_data = ['name', 'email', 'isp', 'ip_address', 'created_at'] header_data = ['name', 'email', 'isp', 'ip_address', 'created_at', "passport"]
worksheet = workbook.add_worksheet() worksheet = workbook.add_worksheet()
header_format = workbook.add_format({'bold': True}) header_format = workbook.add_format({'bold': True})
@@ -54,6 +54,7 @@ def write_contact_with_ip_info_to_file(contact_list):
worksheet.write(row, col + 2, info.isp) worksheet.write(row, col + 2, info.isp)
worksheet.write(row, col + 3, info.ip_address) worksheet.write(row, col + 3, info.ip_address)
worksheet.write(row, col + 4, info.created_at) worksheet.write(row, col + 4, info.created_at)
worksheet.write(row, col + 5, info.passport)
row += 1 row += 1
workbook.close() workbook.close()