def toJSONDict(self):
        self.pk = self.get_pk()
        self.pok = self.get_pok()
        self.decryption_factors = self.get_decryption_factors()
        self.decryption_proofs = self.get_decryption_proofs()

        return DBObject.toJSONDict(self)
Example #2
0
 def toJSONDict(self):
   self.pk = self.get_pk()
   self.pok = self.get_pok()
   self.decryption_factors = self.get_decryption_factors()
   self.decryption_proofs = self.get_decryption_proofs()
     
   return DBObject.toJSONDict(self)
    def toJSONDict(self):
        self.pk = self.get_pk()
        self.questions = self.get_questions()

        # depending on whether the election supports open registration
        # we could have openreg in there all the time, but for backwards compatibility
        # with existing elections, let's not include it.
        if self.openreg_enabled:
            self.openreg = True
        else:
            ## FIXME: make this more efficient for large number of voters
            self.voters_hash = self.get_voters_hash()

        return DBObject.toJSONDict(self)
Example #4
0
 def toJSONDict(self):
   self.pk = self.get_pk()
   self.questions = self.get_questions()
   
   # depending on whether the election supports open registration
   # we could have openreg in there all the time, but for backwards compatibility
   # with existing elections, let's not include it.
   if self.openreg_enabled:
     self.openreg = True
   else:
     ## FIXME: make this more efficient for large number of voters
     self.voters_hash = self.get_voters_hash()
     
   return DBObject.toJSONDict(self)