Esempio n. 1
0
def __getRemoveVehicleTypeRequest(parkingIdentificationCode, id):
    vehiclerequest = VehicleTypeRequest(parkingIdentificationCode=parkingIdentificationCode, idFrequencyType=id)
    payload = Payload(vehiclerequest)
    request = Request(payload, buildMac(object2json(vehiclerequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 2
0
def getRequest(user, password):
    loginRequest = LoginRequest(user, password)
    payload = Payload(loginRequest)
    request = Request(payload, buildMac(object2json(loginRequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 3
0
def __getUpdateVehicleTypeRequest(parkingIdentificationCode, id, description):
    vehiclerequest = VehicleTypeRequest(parkingIdentificationCode, description, id)
    payload = Payload(vehiclerequest)
    request = Request(payload, buildMac(object2json(vehiclerequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 4
0
def __getUpdateParkingRatesRequest(parkingIdentificationCode, id, vehicleTypeId, frequencyTypeId, amount):
    parkingRatesRequest = ParkingRatesRequest(parkingIdentificationCode, id, vehicleTypeId, frequencyTypeId, amount)
    payload = Payload(parkingRatesRequest)
    request = Request(payload, buildMac(object2json(parkingRatesRequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 5
0
def __getSaveParkingRateRequest(parkingIdentificationCode, idVehicleSelected, idFrequencySelected, amount):
    parkingRateRequest = ParkingRatesRequest(parkingIdentificationCode, None, idVehicleSelected, idFrequencySelected, amount)
    payload = Payload(parkingRateRequest)
    request = Request(payload, buildMac(object2json(parkingRateRequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 6
0
def __getFindParkingRatesByIdRequest(parkingIdentificationCode, idParkingRate):
    parkingRatesRequest = ParkingRatesRequest(parkingIdentificationCode=parkingIdentificationCode, idParkingRate=idParkingRate)
    payload = Payload(parkingRatesRequest)
    request = Request(payload, buildMac(object2json(parkingRatesRequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 7
0
def __getUpdateFrequencyTypeRequest(parkingIdentificationCode, id, description, timeType, time, type, priority, combinablePreviousFrequency):
    frequencyRequest = FrequencyTypeRequest(parkingIdentificationCode, id, description, timeType, time, type, priority, combinablePreviousFrequency)
    payload = Payload(frequencyRequest)
    request = Request(payload, buildMac(object2json(frequencyRequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 8
0
def __getAllVehicleTypeRequest(parkingIdentificationCode):
    vehiclerequest = VehicleTypeRequest(parkingIdentificationCode)
    payload = Payload(vehiclerequest)
    request = Request(payload, buildMac(object2json(vehiclerequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 9
0
def __getFindFrequencyTypeByIdRequest(parkingIdentificationCode, idFrequencyType):
    frequencyRequest = FrequencyTypeRequest(parkingIdentificationCode=parkingIdentificationCode, idFrequencyType=idFrequencyType)
    payload = Payload(frequencyRequest)
    request = Request(payload, buildMac(object2json(frequencyRequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 10
0
def __getAllFrequencyTypeRequest(parkingIdentificationCode):
    frequencyrequest = FrequencyTypeRequest(parkingIdentificationCode)
    payload = Payload(frequencyrequest)
    request = Request(payload, buildMac(object2json(frequencyrequest)), 'HASH-PUBLIC-WEB')
    return request
Esempio n. 11
0
def createRequestToApplicationRest():
    payload = Payload('')
    request = Request(payload, buildMac(object2json('')), 'HASH-PUBLIC-WEB')
    return encrypt.encrypted(object2json(request))