Beispiel #1
0
 def stage_id(self):
     try:
         return (key for key, value in BILL_STAGES.items()
                 if value == self.stage).next()
     except StopIteration:
         return BILL_STAGES['UNKNOWN']
Beispiel #2
0
 def stage_id(self):
     try:
         return (key for key, value in BILL_STAGES.items() if value == self.stage).next()
     except StopIteration:
         return BILL_STAGES['UNKNOWN']