repzo 1.0.17 → 1.0.18
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/changelog.md +22 -21
- package/lib/index.d.ts +597 -580
- package/lib/index.js +1370 -1336
- package/lib/types/index.d.ts +130 -0
- package/package.json +1 -1
- package/src/index.ts +1860 -1816
- package/src/types/index.ts +126 -0
package/lib/types/index.d.ts
CHANGED
|
@@ -3488,6 +3488,136 @@ export declare namespace Service {
|
|
|
3488
3488
|
}
|
|
3489
3489
|
export {};
|
|
3490
3490
|
}
|
|
3491
|
+
namespace Refund {
|
|
3492
|
+
export interface RefundSchema {
|
|
3493
|
+
_id: string;
|
|
3494
|
+
status: RefundStatus;
|
|
3495
|
+
remainder: number;
|
|
3496
|
+
amount: number;
|
|
3497
|
+
client_id: string;
|
|
3498
|
+
client_name: string;
|
|
3499
|
+
creator: AdminCreator | RepCreator;
|
|
3500
|
+
time?: number;
|
|
3501
|
+
serial_number: SerialNumber;
|
|
3502
|
+
route?: string;
|
|
3503
|
+
paytime: string;
|
|
3504
|
+
note?: string;
|
|
3505
|
+
currency: string;
|
|
3506
|
+
transaction_type: RefundType;
|
|
3507
|
+
check?: Check;
|
|
3508
|
+
LinkedTxn?: {
|
|
3509
|
+
Txn_serial_number: SerialNumber;
|
|
3510
|
+
Txn_invoice_total: number;
|
|
3511
|
+
TxnType: "return_invoice" | "payment" | "invoice";
|
|
3512
|
+
};
|
|
3513
|
+
company_namespace: string[];
|
|
3514
|
+
integration_meta?: {
|
|
3515
|
+
[key: string]: any;
|
|
3516
|
+
};
|
|
3517
|
+
sync_id: string;
|
|
3518
|
+
custom_status?: string;
|
|
3519
|
+
visit_id?: string;
|
|
3520
|
+
teams?: string[];
|
|
3521
|
+
paymentsData: {
|
|
3522
|
+
amount: number;
|
|
3523
|
+
paid: number;
|
|
3524
|
+
balance: number;
|
|
3525
|
+
payments: PaymentData[];
|
|
3526
|
+
};
|
|
3527
|
+
createdAt: string;
|
|
3528
|
+
updatedAt: string;
|
|
3529
|
+
__v: number;
|
|
3530
|
+
}
|
|
3531
|
+
interface CreateBody {
|
|
3532
|
+
amount: number;
|
|
3533
|
+
client_id: string;
|
|
3534
|
+
client_name: string;
|
|
3535
|
+
time?: number;
|
|
3536
|
+
serial_number?: SerialNumber;
|
|
3537
|
+
route?: string;
|
|
3538
|
+
paytime: string;
|
|
3539
|
+
note?: string;
|
|
3540
|
+
currency: string;
|
|
3541
|
+
transaction_type: RefundType;
|
|
3542
|
+
check?: Check;
|
|
3543
|
+
LinkedTxn?: {
|
|
3544
|
+
Txn_serial_number: SerialNumber;
|
|
3545
|
+
Txn_invoice_total: number;
|
|
3546
|
+
TxnType: "return_invoice" | "payment" | "invoice";
|
|
3547
|
+
};
|
|
3548
|
+
company_namespace?: string[];
|
|
3549
|
+
integration_meta?: {
|
|
3550
|
+
[key: string]: any;
|
|
3551
|
+
};
|
|
3552
|
+
sync_id: string;
|
|
3553
|
+
custom_status?: string;
|
|
3554
|
+
visit_id?: string;
|
|
3555
|
+
teams?: string[];
|
|
3556
|
+
}
|
|
3557
|
+
interface UpdateBody {
|
|
3558
|
+
integration_meta?: {
|
|
3559
|
+
[key: string]: any;
|
|
3560
|
+
};
|
|
3561
|
+
}
|
|
3562
|
+
type RefundSchemaWithPopulatedKeys = RefundSchema & {
|
|
3563
|
+
balance_to_refund: number;
|
|
3564
|
+
custom_status?: string | CustomStatus.CustomStatusSchema;
|
|
3565
|
+
check?: Check & {
|
|
3566
|
+
bank: Bank.BankSchema;
|
|
3567
|
+
};
|
|
3568
|
+
invoice?: {
|
|
3569
|
+
invoice_serial_number: string;
|
|
3570
|
+
invoice_date: string;
|
|
3571
|
+
invoice_due_date: string;
|
|
3572
|
+
original_amount: number;
|
|
3573
|
+
refund: number;
|
|
3574
|
+
};
|
|
3575
|
+
};
|
|
3576
|
+
type RefundType = "check" | "cash";
|
|
3577
|
+
type PopulatedKeys = "custom_status";
|
|
3578
|
+
type RefundStatus = "consumed" | "unconsumed" | "partially_consumed";
|
|
3579
|
+
export namespace Find {
|
|
3580
|
+
type Params = DefaultPaginationQueryParams & {
|
|
3581
|
+
_id?: string[] | string;
|
|
3582
|
+
"creator._id"?: string[] | string;
|
|
3583
|
+
client_id?: string[] | string;
|
|
3584
|
+
from_paytime?: number;
|
|
3585
|
+
to_paytime?: number;
|
|
3586
|
+
custom_status?: string[] | string;
|
|
3587
|
+
transaction_type?: RefundType | RefundType[];
|
|
3588
|
+
creator?: string[] | string;
|
|
3589
|
+
clients?: string[] | string;
|
|
3590
|
+
withPrintDetails?: boolean;
|
|
3591
|
+
[key: string]: any;
|
|
3592
|
+
populatedKeys?: PopulatedKeys[];
|
|
3593
|
+
};
|
|
3594
|
+
interface Result extends DefaultPaginationResult {
|
|
3595
|
+
data: RefundSchemaWithPopulatedKeys[];
|
|
3596
|
+
absolute_total: number;
|
|
3597
|
+
page_total: number;
|
|
3598
|
+
}
|
|
3599
|
+
}
|
|
3600
|
+
export namespace Get {
|
|
3601
|
+
type ID = string;
|
|
3602
|
+
interface Params {
|
|
3603
|
+
withPrintDetails?: boolean;
|
|
3604
|
+
populatedKeys?: PopulatedKeys[];
|
|
3605
|
+
}
|
|
3606
|
+
type Result = RefundSchemaWithPopulatedKeys & {
|
|
3607
|
+
custom_status: CustomStatus.CustomStatusSchema;
|
|
3608
|
+
};
|
|
3609
|
+
}
|
|
3610
|
+
export namespace Create {
|
|
3611
|
+
type Body = CreateBody;
|
|
3612
|
+
type Result = RefundSchema;
|
|
3613
|
+
}
|
|
3614
|
+
export namespace Update {
|
|
3615
|
+
type ID = string;
|
|
3616
|
+
type Body = UpdateBody;
|
|
3617
|
+
type Result = RefundSchema;
|
|
3618
|
+
}
|
|
3619
|
+
export {};
|
|
3620
|
+
}
|
|
3491
3621
|
namespace Cycle {
|
|
3492
3622
|
type CycleStatus = "pending" | "approved" | "processing" | "rejected";
|
|
3493
3623
|
export interface Schema {
|