예제 #1
0
 def book_info_th(self):
     if self.user_role == '管理员':
         db = DBHelp()
         count, res = db.query_all(table_name='borrow_info')
         self.method_name(db, res)
     else:
         db = DBHelp()
         count, res = db.query_super(table_name='borrow_info',
                                     column_name='borrow_user',
                                     condition=self.username)
         self.method_name(db, res)
예제 #2
0
 def book_info_th(self):
     db = DBHelp()
     count, res = db.query_all(table_name='book')
     self.query_book_info_done_signal.emit([count, res])