add log support
This commit is contained in:
@@ -12,6 +12,9 @@ class ExcelHelper:
|
||||
|
||||
def write_phone(self, phone_number):
|
||||
new_df = pandas.Series([phone_number])
|
||||
f = open("phone_list.txt", "a")
|
||||
f.write("{},".format(phone_number))
|
||||
f.close()
|
||||
self._df = pandas.concat([self._df, new_df])
|
||||
self._df.to_excel("phone_list.xlsx")
|
||||
|
||||
@@ -37,3 +40,7 @@ class ExcelHelper:
|
||||
if __name__ == '__main__':
|
||||
helper = ExcelHelper()
|
||||
helper.write_phone("88649614591")
|
||||
helper.write_phone("88649614591")
|
||||
helper.write_phone("88649614591")
|
||||
helper.write_phone("8864961591")
|
||||
helper.write_phone("88649614591")
|
||||
|
||||
Reference in New Issue
Block a user