def getAllReservetaions(): if request.method == 'POST': return OrdersHandler().insertReservationJson(request.json) if request.method == 'GET': if request.args: return OrdersHandler().searchOrders(request.args) else: return OrdersHandler().getAllReservations() else: return jsonify(Error="Method not allowed"), 405
def getReservationByConsumerId(cid): if request.method == 'GET': return OrdersHandler().getReservationsByConsumerId(cid) else: return jsonify(Error="Method not allowed"), 405
def getReservationByType(type): if request.method == 'GET': return OrdersHandler().getReservationsByType(type) else: return jsonify(Error="Method not allowed"), 405
def getReservationsByKeyword(keyword): if request.method == 'GET': return OrdersHandler().getReservationsByKeyword(keyword) else: return jsonify(Error="Method not allowed"), 405
def getOrderById(oid): if request.method == 'GET': return OrdersHandler().getOrderById(oid) else: return jsonify(Error="Method not allowed"), 405