Example #1
0
 def choicelist(self):
     #excludes the choice uuid
     choices = []
     if self._type == FLAG_CHOICE:
         choicelist = FlagChoice.by_flag_id(self.id)
         if choicelist is not None and len(choicelist) > 0:
             for flagchoice in choicelist:
                 choices.append(flagchoice.choice)
     return json.dumps(choices)
Example #2
0
 def choicelist(self):
     #excludes the choice uuid
     choices = []
     if self._type == FLAG_CHOICE:
         choicelist = FlagChoice.by_flag_id(self.id)
         if choicelist is not None and len(choicelist) > 0:
             for flagchoice in choicelist:
                 choices.append(flagchoice.choice)
     return json.dumps(choices)
Example #3
0
 def choices(self):
     #inlucdes the choice uuid - needed for editing choice
     choices = []
     if self._type == FLAG_CHOICE:
         choicelist = FlagChoice.by_flag_id(self.id)
         if choicelist is not None and len(choicelist) > 0:
             for flagchoice in choicelist:
                 choices.append(flagchoice.to_dict())
     return json.dumps(choices)
Example #4
0
 def choices(self):
     #inlucdes the choice uuid - needed for editing choice
     choices = []
     if self._type == FLAG_CHOICE:
         choicelist = FlagChoice.by_flag_id(self.id)
         if choicelist is not None and len(choicelist) > 0:
             for flagchoice in choicelist:
                 choices.append(flagchoice.to_dict())
     return json.dumps(choices)