def put_and_report(self, item, author): self.log_and_put(item) u_actv = generic.UserActivities(actv_kind="Outreach", item=item.key, relative_to=author.key, parent=author.key) self.log_and_put(u_actv)
def put_and_report(self, item, author, group, other_to_update = None): self.log_and_put(item) # Log user activity u_activity = generic.UserActivities(parent = author.key, item = item.key, relative_to = project.key, actv_kind = "Groups") self.log_and_put(u_activity) # Log group update g_update = GroupUpdates(parent = group.key, author = author.key, item = item.key) self.log_and_put(g_update) self.log_and_put(group) if other_to_update: self.log_and_put(other_to_update) return
def put_and_report(self, item, author, project, other_to_update=None): self.log_and_put(item) # Log user activity u_activity = generic.UserActivities(parent=author.key, item=item.key, relative_to=project.key, actv_kind="Projects") self.log_and_put(u_activity) # Log project update p_update = ProjectUpdates(parent=project.key, author=author.key, item=item.key) self.log_and_put(p_update) self.log_and_put(project) if other_to_update: self.log_and_put(other_to_update) return
def put_and_report(self, item, author, project, list_of_things_to_update=[]): self.log_and_put(item) # Log user activity u_activity = generic.UserActivities(parent=author.key, item=item.key, relative_to=project.key, actv_kind="Projects") self.log_and_put(u_activity) # Log project update p_update = ProjectUpdates(parent=project.key, author=author.key, item=item.key) self.log_and_put(p_update) for i in list_of_things_to_update: self.log_and_put(i) return