|
BonPrinter v1.2.0
Thermal Printer tool
|
Class Authentication: Part of the module to hold the data of the current authentication session. More...
Public Member Functions | |
| None | __init__ (self, "MainWindow" ui) |
| bool | check_user_login (self, EUser|list[EUser] user, Optional[EUser|str] user_to_check=None) |
| Check if user log in. | |
| bool | get_article_view_state (self) |
| Get status if articles view. | |
| str | get_user_name_from_position (self, int position) |
| Get user name from position. | |
| int|None | get_user_position (self, Optional[EUser|str] user=None) |
| Get user position. | |
| None | log_in (self) |
| Log in user. | |
| None | log_out (self) |
| Log out user. | |
| None | logout_callback (self) |
| Logout timer callback. | |
| None | refresh_timer (self) |
| Start auto logout. | |
| None | start_timer (self) |
| Start auto logout. | |
| None | stop_timer (self) |
| deactivate auto logout. | |
Public Attributes | |
| bool | b_login_state = False |
| e_view = EWindowView.MAIN | |
| logout_timer = create_timer(parent=self.ui, callback=self.logout_callback) | |
| str|None | s_login_user = None |
| str | s_pw = "" |
| ui = ui | |
Class Authentication: Part of the module to hold the data of the current authentication session.
| ui | : main window object |
Definition at line 30 of file authentication.py.
| None __init__ | ( | self, | |
| "MainWindow" | ui ) |
Definition at line 36 of file authentication.py.
| bool check_user_login | ( | self, | |
| EUser | list[EUser] | user, | ||
| Optional[EUser | str] | user_to_check = None ) |
Check if user log in.
| user | : check if this user is logged in or list |
| user_to_check | : check this user (not logged in user) |
Definition at line 73 of file authentication.py.
| bool get_article_view_state | ( | self | ) |
Get status if articles view.
Definition at line 155 of file authentication.py.
| str get_user_name_from_position | ( | self, | |
| int | position ) |
Get user name from position.
| position | : user position |
Definition at line 123 of file authentication.py.
| int | None get_user_position | ( | self, | |
| Optional[EUser | str] | user = None ) |
Get user position.
| user | : get position of this user |
Definition at line 99 of file authentication.py.
| None log_in | ( | self | ) |
Log in user.
Definition at line 135 of file authentication.py.
| None log_out | ( | self | ) |
Log out user.
Definition at line 144 of file authentication.py.
| None logout_callback | ( | self | ) |
Logout timer callback.
Definition at line 44 of file authentication.py.
| None refresh_timer | ( | self | ) |
Start auto logout.
Definition at line 66 of file authentication.py.
| None start_timer | ( | self | ) |
Start auto logout.
Definition at line 53 of file authentication.py.
| None stop_timer | ( | self | ) |
deactivate auto logout.
Definition at line 60 of file authentication.py.
| bool b_login_state = False |
Definition at line 39 of file authentication.py.
| e_view = EWindowView.MAIN |
Definition at line 40 of file authentication.py.
| logout_timer = create_timer(parent=self.ui, callback=self.logout_callback) |
Definition at line 42 of file authentication.py.
| str | None s_login_user = None |
Definition at line 38 of file authentication.py.
| str s_pw = "" |
Definition at line 41 of file authentication.py.
| ui = ui |
Definition at line 37 of file authentication.py.