-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathservice.py
25 lines (17 loc) · 827 Bytes
/
service.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
from models import request
class service:
def __init__(self):
self.request = request()
def getList(self, location, movie, theater, screen, seat):
if location != "":
result = self.request.getMovieByLocation(location)
return result
elif movie != "":
result = self.request.getTheatreByMovies(movie)
return result
def createUser(self, username, password):
self.request.createUser(username, password)
def validateUser(self, username, password):
return self.request.validateUser(username, password)
def bookTicket(self, location, movie, theater, screen, seat, showtime, logged_in_user):
return self.request.bookTicket(location, movie, theater, screen, seat, showtime, logged_in_user)