rework icons, codechanges, bugfixes, typofixes
This commit is contained in:
@@ -56,4 +56,4 @@ if __name__ == "__main__":
|
||||
("SoSe 15", 1, 0),
|
||||
]
|
||||
|
||||
print(custom_sort(unsorted))
|
||||
# print(custom_sort(unsorted))
|
||||
|
||||
@@ -109,7 +109,7 @@ class Mailer(Ui_eMailPreview):
|
||||
self.buttonBox.accepted.connect(self.createAndSendMail)
|
||||
|
||||
def load_mail_templates(self):
|
||||
print("loading mail templates")
|
||||
# print("loading mail templates")
|
||||
mail_templates = os.listdir("mail_vorlagen")
|
||||
for template in mail_templates:
|
||||
self.comboBox.addItem(template)
|
||||
@@ -169,12 +169,12 @@ class Mailer(Ui_eMailPreview):
|
||||
# server.starttls()
|
||||
# server.auth(mechanism="PLAIN")
|
||||
if config["mail"]["use_user_name"] == 1:
|
||||
print(config["mail"]["user_name"])
|
||||
# print(config["mail"]["user_name"])
|
||||
server.login(config["mail"]["user_name"], password)
|
||||
else:
|
||||
server.login(sender_email, password)
|
||||
server.sendmail(sender_email, self.prof_mail, mail)
|
||||
print("Mail sent")
|
||||
# print("Mail sent")
|
||||
# end active process
|
||||
server.quit()
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ def tuple_to_dict(tlist: tuple, type: str) -> dict:
|
||||
ret = []
|
||||
for line in tlist:
|
||||
data = makeDict()
|
||||
if type == "Monographie":
|
||||
if type == "Monografien":
|
||||
data["type"] = type
|
||||
data["work_author"] = line[0]
|
||||
data["year"] = line[1]
|
||||
@@ -84,10 +84,10 @@ def tuple_to_dict(tlist: tuple, type: str) -> dict:
|
||||
|
||||
def elsa_word_to_csv(path):
|
||||
doc = Document(path)
|
||||
# print all lines in doc
|
||||
# # print all lines in doc
|
||||
doctype = [para.text for para in doc.paragraphs if para.text != ""][-1]
|
||||
tuples = {
|
||||
"Monographie": ("", "", "", "", "", "", "", "", ""),
|
||||
"Monografien": ("", "", "", "", "", "", "", "", ""),
|
||||
"Herausgeberwerke": ("", "", "", "", "", "", "", "", "", "", ""),
|
||||
"Zeitschriftenaufsätze": ("", "", "", "", "", "", "", "", "", ""),
|
||||
}
|
||||
@@ -113,10 +113,10 @@ def elsa_word_to_csv(path):
|
||||
data = [
|
||||
row for row in df.itertuples(index=False, name=None) if row != tuples[doctype]
|
||||
]
|
||||
print(data)
|
||||
# print(data)
|
||||
return tuple_to_dict(data, doctype), doctype
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
else_df = elsa_word_to_csv("c:/Users/aky547/Desktop/hrsgw_test.docx")
|
||||
print(else_df)
|
||||
else_df = elsa_word_to_csv("C:/Users/aky547/Desktop/Antrag ELSA Schweitzer.docx")
|
||||
# print(else_df)
|
||||
@@ -178,7 +178,7 @@ class ZoteroController:
|
||||
def __get_data(self, isbn):
|
||||
web = WebRequest()
|
||||
web.get_ppn(isbn)
|
||||
data = web.get_data()
|
||||
data = web.get_data_elsa()
|
||||
bib = BibTextTransformer("ARRAY")
|
||||
bib.get_data(data)
|
||||
book = bib.return_data()
|
||||
|
||||
Reference in New Issue
Block a user