lst_profession = []
# loop through each item
for item in self.data["professionalhistory"]:
+ if item["leavedate"] == "":
+ leavedate_str = self.lang_strings[6]
+ else:
+ leavedate_str = item["leavedate"]
str_profession = tpl_profession.safe_substitute (
joindate = item["joindate"],
- leavedate= item["leavedate"],
+ leavedate = leavedate_str,
organization = item["organization"],
jobtitle = item["jobtitle"],
additionalinfo = item["additionalinfo"]
PyQt4.QtGui.QMessageBox.critical (self, lang.ERROR_UPDATE, lang.ERROR_REQ_MISSING)
return
# if currently employed in that position, leaving date is to be disabled
- # and set to "current"
+ # and set to empty
if self.currentemployment.isChecked ():
- leavedatestr = "current"
+ leavedatestr = ""
else:
# if the leaving date is < join date
if self.leavedate.date () < self.joindate.date ():
PyQt4.QtGui.QMessageBox.critical (self, lang.ERROR_ADD, lang.ERROR_REQ_MISSING)
return
# if currently employed in that position, leaving date is to be disabled
- # and set to "current"
+ # and set to ""
if self.currentemployment.isChecked ():
- leavedatestr = "current"
+ leavedatestr = ""
else:
# if the leaving date is < join date
if self.leavedate.date () < self.joindate.date ():
selitem = selitems[0]
self.designation.setText (selitem.text (0))
self.joindate.setDate (PyQt4.QtCore.QDate.fromString (selitem.text(1), "dd MMM, yyyy"))
- if selitem.text (2) == "current":
+ if selitem.text (2) == "":
self.leavedate.setEnabled (False)
self.currentemployment.setChecked (True)
else: