def zoho_list_item_to_tote_task(item): print item listID = item[0] listName = item[1] subItems = item[2] tote_task_item = nuclasses.task(listName, zohoID=listID) for each in subItems: listID = each[0] listName = each[1] nuclasses.task(listName, zohoID=listID, parentTask=tote_task_item) return tote_task_item
def addItem(self, widget, entry): #text = entry.get_text() entryText = self.quickListEntry.get_text() comboText = self.quickListCombo.get_active() #print widget, entry, "Text is: ", entry.get_text() if comboText == OPTION_ADD_TASK: nuclasses.task(entryText) elif comboText == OPTION_ADD_EVENT: nuclasses.event(entryText) else: nuclasses.log_error("A weird error occured... Neither a task nor an event was selected") self.treeview_both.set_model(self.__create_model_both(nuclasses.tasks, nuclasses.events)) self.treeview.set_model(self.__create_model_tasks(nuclasses.tasks))
def addTasksFromCalDict(itemlist): for t in itemlist: nuclasses.task(t["name"], description=t["description"], startTime=t["startTime"], uid=t["uid"])