- Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathview.py
More file actions
Latest commit
43 lines (38 loc) · 1.26 KB
/
Copy pathview.py
File metadata and controls
43 lines (38 loc) · 1.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Author : Yaakov Azat @ AzatAI
# Profile: https://azat.ai/profile/yaakovazat
importtime
importos
importdatetime
importsettings
importmodule
classHome():
products= []
current_user=settings.CURRENT_USER
def__init__(self):
brand='Welcome to AzatAI Python Shop'
print(brand.center(100,'*'))
defsuperadmin(self):
print('')
print(f"PLEASE CREATE A SUPER ADMIN:".center(100,' '))
deflist_user(self,role):
"""
dasda
:param role:
:return:
"""
user=module.User()
all_users_list=user.all_users
print("UserName UserPassword User-Date_created Admin Staff Client")
foreachinall_users_list:
user_each_list=each.split(',')
ifuser_each_list[role]:
print(user_each_list)
defwelcome(self):
ifsettings.CURRENT_USER_ROLE=='ADMIN':
print(f"Welcome Home {settings.CURRENT_USER_ROLE}{settings.CURRENT_USER}".rjust(100, " "))
print("".center(100,'*'))
print(f"SITE MANAGEMENT".center(100, ' '))
else:
print(f"Welcome GUEST".rjust(100,' '))
print("".center(100,'*'))
print(f"REGISTER/LOGIN TO CONTINUE".center(100, ' '))