-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathems_dinput.py
28 lines (23 loc) · 859 Bytes
/
ems_dinput.py
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
from kivy.lang import Builder
from kivy.app import App
from kivy.uix.screenmanager import Screen
from kivy.core.window import Window
from kivy.utils import rgba
from kivy.uix.popup import Popup
from kivy.uix.label import Label
from kivy.uix.button import Button
from colors import Colors
from FirebaseRealtimeDB import get_patient_info
kv = Builder.load_file('ems_dinput.kv')
class EMSDinput(Screen):
def check_dl_num(self, license):
b = Button(text="Error verifying license")
is_valid = get_patient_info(license)
if is_valid is None:
popup = Popup(title='Test popup', content=b, size=(200, 400))
b.bind(on_press=popup.dismiss)
popup.open()
return False
App.get_running_app().save_dlid(license)
print(App.get_running_app().get_dlid())
return True