Exemple #1
0
 def list_subscribers_for_super_admin(
         self, context) -> (list, MassEnergizeAPIError):
     subscribers, err = self.store.list_subscribers_for_super_admin(context)
     if err:
         return None, err
     return serialize_all(subscribers, full=True), None
Exemple #2
0
 def list_teams_for_super_admin(
         self, context: Context) -> (list, MassEnergizeAPIError):
     teams, err = self.store.list_teams_for_super_admin(context)
     if err:
         return None, err
     return serialize_all(teams), None
Exemple #3
0
 def list_tags_for_community_admin(
         self, community_id) -> Tuple[list, MassEnergizeAPIError]:
     tags, err = self.store.list_tags_for_community_admin(community_id)
     if err:
         return None, err
     return serialize_all(tags), None
Exemple #4
0
 def delete_community(self, args) -> (dict, MassEnergizeAPIError):
   community, err = self.store.delete_community(args)
   if err:
     return None, err
   return serialize_all(community), None
Exemple #5
0
 def list_teams(self, context: Context,
                args) -> (list, MassEnergizeAPIError):
     team, err = self.store.list_teams(context, args)
     if err:
         return None, err
     return serialize_all(team), None
Exemple #6
0
 def list_actions_todo(self, context: Context,
                       args) -> Tuple[list, MassEnergizeAPIError]:
     actions_todo, err = self.store.list_todo_actions(context, args)
     if err:
         return None, err
     return serialize_all(actions_todo), None
Exemple #7
0
 def list_users_for_super_admin(
         self, context) -> Tuple[list, MassEnergizeAPIError]:
     users, err = self.store.list_users_for_super_admin(context)
     if err:
         return None, err
     return serialize_all(users), None
Exemple #8
0
 def list_actions(self, context: Context, community_id, subdomain) -> (list, MassEnergizeAPIError):
   actions, err = self.store.list_actions(context, community_id, subdomain)
   if err:
     return None, err
   return serialize_all(actions), None
Exemple #9
0
 def list_events_for_super_admin(self,
                                 context) -> (list, MassEnergizeAPIError):
     events, err = self.store.list_events_for_super_admin(context)
     if err:
         return None, err
     return serialize_all(events), None
Exemple #10
0
 def list_tags(self, tag_id) -> (list, MassEnergizeAPIError):
     tags, err = self.store.list_tags(tag_id)
     if err:
         return None, err
     return serialize_all(tags), None
Exemple #11
0
 def list_tags_for_super_admin(self) -> (list, MassEnergizeAPIError):
     tags, err = self.store.list_tags_for_super_admin()
     if err:
         return None, err
     return serialize_all(tags), None
Exemple #12
0
 def list_vendors(self, context, args) -> Tuple[list, MassEnergizeAPIError]:
     vendors, err = self.store.list_vendors(context, args)
     if err:
         return None, err
     return serialize_all(vendors), None
Exemple #13
0
 def list_page_settings_for_super_admin(
         self) -> Tuple[list, MassEnergizeAPIError]:
     page_settings, err = self.store.list_page_settings_for_super_admin()
     if err:
         return None, err
     return serialize_all(page_settings), None
Exemple #14
0
 def list_teams_for_community_admin(
         self, context: Context, args) -> Tuple[list, MassEnergizeAPIError]:
     teams, err = self.store.list_teams_for_community_admin(context, args)
     if err:
         return None, err
     return serialize_all(teams), None
Exemple #15
0
 def list_team_admin_messages_for_community_admin(
         self, context: Context) -> (list, MassEnergizeAPIError):
     messages, err = self.store.list_team_admin_messages(context)
     if err:
         return None, err
     return serialize_all(messages), None
Exemple #16
0
 def navigation_menu_list(self, context: Context,
                          args) -> Tuple[dict, MassEnergizeAPIError]:
     main_menu_items, err = self.store.navigation_menu_list(context, args)
     if err:
         return None, err
     return serialize_all(main_menu_items), None
Exemple #17
0
 def list_users(self, community_id) -> Tuple[list, MassEnergizeAPIError]:
     user, err = self.store.list_users(community_id)
     if err:
         return None, err
     return serialize_all(user), None
Exemple #18
0
 def list_users_for_community_admin(self, context, community_id) -> (list, MassEnergizeAPIError):
   users, err = self.store.list_users_for_community_admin(context, community_id)
   if err:
     return None, err
   return serialize_all(users), None
Exemple #19
0
 def list_events_for_user(self, context: Context,
                          args) -> Tuple[list, MassEnergizeAPIError]:
     events, err = self.store.list_events_for_user(context, args)
     if err:
         return None, err
     return serialize_all(events), None
Exemple #20
0
 def list_actions_completed(self, context: Context, args) -> (list, MassEnergizeAPIError):
   actions_completed, err = self.store.list_completed_actions(context, args)
   if err:
     return None, err
   return serialize_all(actions_completed), None
Exemple #21
0
 def list_communities(self, context, args) -> (list, MassEnergizeAPIError):
   communities, err = self.store.list_communities(context, args)
   if err:
     return None, err
   return serialize_all(communities), None
Exemple #22
0
 def list_donate_page_settings_for_community_admin(self, community_id) -> (list, MassEnergizeAPIError):
   donate_page_settings, err = self.store.list_donate_page_settings_for_community_admin(community_id)
   if err:
     return None, err
   return serialize_all(donate_page_settings), None
Exemple #23
0
 def get_graphs(self, context) -> (list, MassEnergizeAPIError):
   communities, err = self.store.list_communities_for_super_admin(context)
   if err:
     return None, err
   return serialize_all(communities), None
Exemple #24
0
 def list_donate_page_settings_for_super_admin(self) -> (list, MassEnergizeAPIError):
   donate_page_settings, err = self.store.list_donate_page_settings_for_super_admin()
   if err:
     return None, err
   return serialize_all(donate_page_settings), None
Exemple #25
0
 def members(self, context, args) -> (dict, MassEnergizeAPIError):
     members, err = self.store.members(context, args)
     if err:
         return None, err
     return serialize_all(members), None
Exemple #26
0
 def get_rsvp_list(self, context,
                   args) -> Tuple[list, MassEnergizeAPIError]:
     rsvps, err = self.store.get_rsvp_list(context, args)
     if err:
         return None, err
     return serialize_all(rsvps), None
Exemple #27
0
 def list_goals(self, community_id, subdomain, team_id, user_id) -> Tuple[list, MassEnergizeAPIError]:
   goals, err = self.store.list_goals(community_id, subdomain, team_id, user_id)
   if err:
     return None, err
   return serialize_all(goals), None
Exemple #28
0
 def list_super_admin(self, context,
                      args) -> Tuple[dict, MassEnergizeAPIError]:
     admins, err = self.store.list_super_admin(context, args)
     if err:
         return None, err
     return serialize_all(admins), None