turf-common 1.0.18-beta.2 → 1.0.18-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/enums/booking-fetch-filter.enum.d.ts +5 -0
- package/build/enums/booking-fetch-filter.enum.js +9 -0
- package/build/interface/api/booking-availablity-by-pitch.interface.d.ts +11 -0
- package/build/interface/api/cancellation-charges.interface.d.ts +11 -0
- package/build/interface/api/create-cancellation-policy.interface.d.ts +10 -1
- package/build/interface/api/create-recurring-slot-booking.interface.d.ts +24 -1
- package/build/interface/api/get-booking-by-organization-id.interface.d.ts +4 -0
- package/build/interface/api/get-price-entity.interface.d.ts +10 -0
- package/build/interface/api/get-price-query.interface.d.ts +3 -0
- package/build/interface/api/index.d.ts +2 -1
- package/build/interface/api/index.js +2 -1
- package/build/interface/api/one-slot-booking.interface.d.ts +21 -0
- package/build/interface/api/set-price.interface.d.ts +6 -0
- package/build/interface/api/update-configuration.interface.d.ts +1 -1
- package/build/interface/api/update-recurring-booking.interface.d.ts +16 -1
- package/build/interface/api/update-turf-transaction-output.d.ts +8 -8
- package/build/interface/dto/update-booking-by-code-dto.interface.d.ts +5 -7
- package/package.json +1 -1
- package/build/interface/api/delete-booking-by-codes.interface.d.ts +0 -7
- package/build/interface/api/update-booking-by-code-response.d.ts +0 -7
- package/build/interface/api/update-booking-by-code.interface.d.ts +0 -15
- package/build/interface/api/update-booking-by-code.interface.js +0 -2
- /package/build/interface/api/{delete-booking-by-codes.interface.js → get-price-entity.interface.js} +0 -0
- /package/build/interface/api/{update-booking-by-code-response.js → set-price.interface.js} +0 -0
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BookingFetchFilter = void 0;
|
|
4
|
+
var BookingFetchFilter;
|
|
5
|
+
(function (BookingFetchFilter) {
|
|
6
|
+
BookingFetchFilter["PENDING_PAYMENT"] = "pending_payment";
|
|
7
|
+
BookingFetchFilter["PENDING_REFUND"] = "pending_refund";
|
|
8
|
+
BookingFetchFilter["FULL_REFUND"] = "full_refund";
|
|
9
|
+
})(BookingFetchFilter || (exports.BookingFetchFilter = BookingFetchFilter = {}));
|
|
@@ -26,3 +26,14 @@ export interface IBookingByPitches {
|
|
|
26
26
|
to: string;
|
|
27
27
|
pitch: number[];
|
|
28
28
|
}
|
|
29
|
+
export interface IBookingAvailabilityByPitchRequest {
|
|
30
|
+
slot: IBookingAvailabilitySlotRequest[];
|
|
31
|
+
bookingCode?: string;
|
|
32
|
+
}
|
|
33
|
+
export interface IBookingAvailabilitySlotRequest {
|
|
34
|
+
fromDate: number;
|
|
35
|
+
toDate: number;
|
|
36
|
+
weekdays: number[];
|
|
37
|
+
from: string;
|
|
38
|
+
to: string;
|
|
39
|
+
}
|
|
@@ -4,3 +4,14 @@ export interface ICancellationCharges {
|
|
|
4
4
|
cancellationUnit: string;
|
|
5
5
|
};
|
|
6
6
|
}
|
|
7
|
+
export interface ICancellationChargesDtoRequest {
|
|
8
|
+
data?: {
|
|
9
|
+
[key: string]: string;
|
|
10
|
+
};
|
|
11
|
+
new_slot?: ICancellationChargesSlot;
|
|
12
|
+
}
|
|
13
|
+
export interface ICancellationChargesSlot {
|
|
14
|
+
date: number;
|
|
15
|
+
from: string;
|
|
16
|
+
to: string;
|
|
17
|
+
}
|
|
@@ -1,3 +1,12 @@
|
|
|
1
|
-
import { ICancellationPolicyEntity } from
|
|
1
|
+
import { ICancellationPolicyEntity } from "../../@type";
|
|
2
2
|
export interface ICreateCancellationPolicy extends Array<ICancellationPolicyEntity> {
|
|
3
3
|
}
|
|
4
|
+
export interface ICreateCancellationPolicyDtoRequest {
|
|
5
|
+
adhocRefund: boolean;
|
|
6
|
+
cancellationPolicy?: ICancellationPolicyDetailsRequest[];
|
|
7
|
+
}
|
|
8
|
+
export interface ICancellationPolicyDetailsRequest {
|
|
9
|
+
from: number;
|
|
10
|
+
to: number;
|
|
11
|
+
charges: string;
|
|
12
|
+
}
|
|
@@ -1,3 +1,26 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { PaymentMode, BookingDetailsStatus } from "../../@enum";
|
|
2
|
+
import { IBookingDetailsEntity } from "../../@type";
|
|
2
3
|
export interface ICreateRecurringSlotBooking extends IBookingDetailsEntity {
|
|
3
4
|
}
|
|
5
|
+
export interface ICreateRecurringSlotsBookingDetailsResponse {
|
|
6
|
+
customerName: string;
|
|
7
|
+
contact: number;
|
|
8
|
+
email?: string | null;
|
|
9
|
+
paymentMode: PaymentMode;
|
|
10
|
+
couponCode?: string;
|
|
11
|
+
totalCost: number;
|
|
12
|
+
discountedCost: number;
|
|
13
|
+
amountPaid: number;
|
|
14
|
+
pitchId: number;
|
|
15
|
+
status: BookingDetailsStatus;
|
|
16
|
+
sport: string;
|
|
17
|
+
remarks?: string | null;
|
|
18
|
+
slot: IRecurringSlot[];
|
|
19
|
+
}
|
|
20
|
+
export declare class IRecurringSlot {
|
|
21
|
+
fromDate: number;
|
|
22
|
+
toDate: number;
|
|
23
|
+
weekdays: number[];
|
|
24
|
+
from: string;
|
|
25
|
+
to: string;
|
|
26
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ITurf } from "../../@type";
|
|
2
2
|
import { IBookingDetailsWithBooking } from "../../types/bookingdetails-with-booking.type";
|
|
3
3
|
import { UserType } from "../../enums/valid-type.enum";
|
|
4
|
+
import { BookingFetchFilter } from "../../enums/booking-fetch-filter.enum";
|
|
4
5
|
export interface IGetBookingsByOrganizationId {
|
|
5
6
|
turfs: {
|
|
6
7
|
[turfId: number]: ITurf;
|
|
@@ -17,3 +18,6 @@ export interface IGetBookingsByOrganizationId {
|
|
|
17
18
|
};
|
|
18
19
|
};
|
|
19
20
|
}
|
|
21
|
+
export interface IGetBookingsByOrganizationIdRequest {
|
|
22
|
+
fetch: BookingFetchFilter[];
|
|
23
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ISetPriceRequest } from "./set-price.interface";
|
|
1
2
|
export interface IGetPriceQuery {
|
|
2
3
|
[turfId: string]: {
|
|
3
4
|
[code: string]: {
|
|
@@ -5,3 +6,5 @@ export interface IGetPriceQuery {
|
|
|
5
6
|
};
|
|
6
7
|
};
|
|
7
8
|
}
|
|
9
|
+
export interface IGetPriceQueryRequest extends ISetPriceRequest {
|
|
10
|
+
}
|
|
@@ -27,7 +27,7 @@ export * from "./get-cron-job-by-date-range-name-status.interface";
|
|
|
27
27
|
export * from "./get-current-subscription.interface";
|
|
28
28
|
export * from "./get-organization-by-orgid.interface";
|
|
29
29
|
export * from "./get-price-by-organization-response.interface";
|
|
30
|
-
export * from "./get-price-entity.
|
|
30
|
+
export * from "./get-price-entity.interface";
|
|
31
31
|
export * from "./get-price-query.interface";
|
|
32
32
|
export * from "./get-pricing-plan-by-date-response.interface";
|
|
33
33
|
export * from "./get-pricing-plan-by-id.interface";
|
|
@@ -63,3 +63,4 @@ export * from "./delete-booking-by-codes-response.interface";
|
|
|
63
63
|
export * from "./update-booking-by-code-response.interface";
|
|
64
64
|
export * from "./login-response.interface";
|
|
65
65
|
export * from "./create-turf.interface";
|
|
66
|
+
export * from "./set-price.interface";
|
|
@@ -43,7 +43,7 @@ __exportStar(require("./get-cron-job-by-date-range-name-status.interface"), expo
|
|
|
43
43
|
__exportStar(require("./get-current-subscription.interface"), exports);
|
|
44
44
|
__exportStar(require("./get-organization-by-orgid.interface"), exports);
|
|
45
45
|
__exportStar(require("./get-price-by-organization-response.interface"), exports);
|
|
46
|
-
__exportStar(require("./get-price-entity.
|
|
46
|
+
__exportStar(require("./get-price-entity.interface"), exports);
|
|
47
47
|
__exportStar(require("./get-price-query.interface"), exports);
|
|
48
48
|
__exportStar(require("./get-pricing-plan-by-date-response.interface"), exports);
|
|
49
49
|
__exportStar(require("./get-pricing-plan-by-id.interface"), exports);
|
|
@@ -81,3 +81,4 @@ __exportStar(require("./delete-booking-by-codes-response.interface"), exports);
|
|
|
81
81
|
__exportStar(require("./update-booking-by-code-response.interface"), exports);
|
|
82
82
|
__exportStar(require("./login-response.interface"), exports);
|
|
83
83
|
__exportStar(require("./create-turf.interface"), exports);
|
|
84
|
+
__exportStar(require("./set-price.interface"), exports);
|
|
@@ -1,3 +1,24 @@
|
|
|
1
|
+
import { PaymentMode, BookingDetailsStatus } from "../../@enum";
|
|
1
2
|
import { IBookingDetailsEntity } from "../../@type";
|
|
2
3
|
export interface IOneSlotBooking extends IBookingDetailsEntity {
|
|
3
4
|
}
|
|
5
|
+
export interface ICreateOneSlotBookingDetailsRequest {
|
|
6
|
+
customerName: string;
|
|
7
|
+
contact: number;
|
|
8
|
+
email?: string | null;
|
|
9
|
+
paymentMode: PaymentMode;
|
|
10
|
+
couponCode: string;
|
|
11
|
+
totalCost?: number;
|
|
12
|
+
discountedCost: number;
|
|
13
|
+
amountPaid: number;
|
|
14
|
+
pitchId: number;
|
|
15
|
+
status: BookingDetailsStatus;
|
|
16
|
+
sport: string;
|
|
17
|
+
remarks?: string | null;
|
|
18
|
+
slot: ICreateOneSlot[];
|
|
19
|
+
}
|
|
20
|
+
export interface ICreateOneSlot {
|
|
21
|
+
date: number;
|
|
22
|
+
from: string;
|
|
23
|
+
to: string;
|
|
24
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BookingDetailsStatus } from "../../@enum";
|
|
1
|
+
import { BookingDetailsStatus, PaymentMode } from "../../@enum";
|
|
2
2
|
import { IBookingDetailsEntity } from "../../@type";
|
|
3
3
|
import { IDeleteBookingByCodesDto } from "../dto/delete-booking-by-codes-dto.interface";
|
|
4
4
|
import { IUpdateBookingByCodesDto } from "../dto/update-booking-by-code-dto.interface";
|
|
@@ -35,3 +35,18 @@ export interface IUpdateRecurringBooking extends IBookingDetailsEntity {
|
|
|
35
35
|
delete_slot?: IDeleteBookingByCodesDto;
|
|
36
36
|
update_slot?: IUpdateBookingByCodesDto;
|
|
37
37
|
}
|
|
38
|
+
export interface IUpdateRecurringSlotBookingDetailsRequest {
|
|
39
|
+
customerName?: string;
|
|
40
|
+
contact?: number;
|
|
41
|
+
email?: string;
|
|
42
|
+
paymentMode?: PaymentMode;
|
|
43
|
+
couponCode?: string;
|
|
44
|
+
amountPaid?: number;
|
|
45
|
+
status?: BookingDetailsStatus;
|
|
46
|
+
advancePayment?: number;
|
|
47
|
+
refundedAmount?: number;
|
|
48
|
+
refundedMode?: PaymentMode;
|
|
49
|
+
delete_slot?: IDeleteBookingByCodesDto;
|
|
50
|
+
update_slot?: IUpdateBookingByCodesDto;
|
|
51
|
+
remarks?: string | null;
|
|
52
|
+
}
|
|
@@ -4,16 +4,16 @@ import { PitchSports } from "../../enums/pitch-sports.enum";
|
|
|
4
4
|
export interface UpdateTurfTransactionOutput extends ITurfEntity {
|
|
5
5
|
}
|
|
6
6
|
export interface UpdateTurfDetailsRequest {
|
|
7
|
-
turfName
|
|
8
|
-
pitches
|
|
9
|
-
address
|
|
7
|
+
turfName?: string;
|
|
8
|
+
pitches?: IUpdatePitches[];
|
|
9
|
+
address?: string;
|
|
10
10
|
}
|
|
11
11
|
export interface IUpdatePitches {
|
|
12
|
-
number
|
|
13
|
-
name
|
|
14
|
-
operations
|
|
15
|
-
status
|
|
16
|
-
sports
|
|
12
|
+
number?: number;
|
|
13
|
+
name?: string;
|
|
14
|
+
operations?: PitchOperations;
|
|
15
|
+
status?: string;
|
|
16
|
+
sports?: IUpdateSports[];
|
|
17
17
|
}
|
|
18
18
|
export interface IUpdateSports {
|
|
19
19
|
name: PitchSports;
|
|
@@ -5,11 +5,9 @@ export interface IUpdateBookingByCodesDto {
|
|
|
5
5
|
refund_amount: number;
|
|
6
6
|
refund_mode: PaymentMode;
|
|
7
7
|
pitchId: number;
|
|
8
|
-
slot:
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
];
|
|
8
|
+
slot: {
|
|
9
|
+
date: number;
|
|
10
|
+
from: string;
|
|
11
|
+
to: string;
|
|
12
|
+
}[];
|
|
15
13
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { PaymentMode } from "../../@enum";
|
|
2
|
-
import { IUpdateBookingByCodesDto } from "../dto/update-booking-by-code-dto.interface";
|
|
3
|
-
export interface IUpdateBookingByCodeResponse extends IUpdateBookingByCodesDto {
|
|
4
|
-
cancellation_amount: number;
|
|
5
|
-
refund_amount: number;
|
|
6
|
-
refund_mode: PaymentMode;
|
|
7
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { PaymentMode } from "../../@enum";
|
|
2
|
-
export interface IUpdateBookingByCodes {
|
|
3
|
-
bookingCode: string;
|
|
4
|
-
cancellation_amount: number;
|
|
5
|
-
refund_amount: number;
|
|
6
|
-
refund_mode: PaymentMode;
|
|
7
|
-
pitchId: number;
|
|
8
|
-
slot: [
|
|
9
|
-
{
|
|
10
|
-
date: number;
|
|
11
|
-
from: string;
|
|
12
|
-
to: string;
|
|
13
|
-
}
|
|
14
|
-
];
|
|
15
|
-
}
|
/package/build/interface/api/{delete-booking-by-codes.interface.js → get-price-entity.interface.js}
RENAMED
|
File without changes
|
|
File without changes
|