2022-01-16 05:56:31 +01:00
|
|
|
export class RequestedPage
|
|
|
|
{
|
|
|
|
public static REQUEST_TYPE_NONE: number = 0;
|
|
|
|
public static REQUEST_TYPE_ID: number = 1;
|
|
|
|
public static REQUEST_TYPE_NAME: number = 2;
|
|
|
|
|
|
|
|
private _requestType: number;
|
2022-01-19 08:22:30 +01:00
|
|
|
private _requestById: number;
|
2022-01-16 05:56:31 +01:00
|
|
|
private _requestedOfferId: number;
|
2022-01-19 08:22:30 +01:00
|
|
|
private _requestByName: string;
|
2022-01-16 05:56:31 +01:00
|
|
|
|
|
|
|
constructor()
|
|
|
|
{
|
|
|
|
this._requestType = RequestedPage.REQUEST_TYPE_NONE;
|
|
|
|
}
|
|
|
|
|
2022-01-19 08:22:30 +01:00
|
|
|
public resetRequest():void
|
2022-01-16 05:56:31 +01:00
|
|
|
{
|
2022-01-19 08:22:30 +01:00
|
|
|
this._requestType = RequestedPage.REQUEST_TYPE_NONE;
|
|
|
|
this._requestedOfferId = -1;
|
2022-01-16 05:56:31 +01:00
|
|
|
}
|
|
|
|
|
2022-01-19 08:22:30 +01:00
|
|
|
public get requestType(): number
|
2022-01-16 05:56:31 +01:00
|
|
|
{
|
2022-01-19 08:22:30 +01:00
|
|
|
return this._requestType;
|
2022-01-16 05:56:31 +01:00
|
|
|
}
|
|
|
|
|
2022-01-19 08:22:30 +01:00
|
|
|
public get requestById(): number
|
2022-01-16 05:56:31 +01:00
|
|
|
{
|
2022-01-19 08:22:30 +01:00
|
|
|
return this._requestById;
|
2022-01-16 05:56:31 +01:00
|
|
|
}
|
|
|
|
|
2022-01-19 08:22:30 +01:00
|
|
|
public set requestById(id: number)
|
2022-01-16 05:56:31 +01:00
|
|
|
{
|
2022-01-19 08:22:30 +01:00
|
|
|
this._requestType = RequestedPage.REQUEST_TYPE_ID;
|
|
|
|
this._requestById = id;
|
|
|
|
}
|
|
|
|
|
|
|
|
public get requestByName(): string
|
|
|
|
{
|
|
|
|
return this._requestByName;
|
2022-01-16 05:56:31 +01:00
|
|
|
}
|
|
|
|
|
2022-01-19 08:22:30 +01:00
|
|
|
public set requestByName(name: string)
|
2022-01-16 05:56:31 +01:00
|
|
|
{
|
2022-01-19 08:22:30 +01:00
|
|
|
this._requestType = RequestedPage.REQUEST_TYPE_NAME;
|
|
|
|
this._requestByName = name;
|
2022-01-16 05:56:31 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
public get requestedOfferId(): number
|
|
|
|
{
|
|
|
|
return this._requestedOfferId;
|
|
|
|
}
|
|
|
|
|
|
|
|
public set requestedOfferId(offerId: number)
|
|
|
|
{
|
|
|
|
this._requestedOfferId = offerId;
|
|
|
|
}
|
|
|
|
}
|