예제 #1
0
 def register_payeeid(self, payee_str):
     id = self.get_payeeid(payee_str)
     if id == None:
       payee = Payee.create(PAYEENAME=payee_str.strip(), CATEGID=-1, SUBCATEGID=-1)
       id = self.get_payeeid(payee_str)
     return id
예제 #2
0
 def get_payee_name(self, payee_id):
   payee = Payee.select().where(Payee.PAYEEID == payee_id).get()
   return payee.PAYEENAME
예제 #3
0
 def get_payeeid(self, payee_str):
     try:
       id = Payee.select().where(Payee.PAYEENAME == payee_str.strip()).get()
       return id.PAYEEID
     except peewee.DoesNotExist as e:
       return None