ravcredit-lib 0.0.2 → 0.0.3
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/esm2022/lib/v1/objects/oAddress.mjs +2 -0
- package/esm2022/lib/v1/objects/oBusiness.mjs +2 -0
- package/esm2022/lib/v1/objects/oClient.mjs +2 -0
- package/esm2022/lib/v1/objects/oConekta.mjs +85 -0
- package/esm2022/lib/v1/objects/oContract.mjs +2 -0
- package/esm2022/lib/v1/objects/oContractAll.mjs +2 -0
- package/esm2022/lib/v1/objects/oCustomer.mjs +18 -0
- package/esm2022/lib/v1/objects/oDevice.mjs +2 -0
- package/esm2022/lib/v1/objects/oFinancial.mjs +2 -0
- package/esm2022/lib/v1/objects/oGlobal.mjs +86 -0
- package/esm2022/lib/v1/objects/oLogIn.mjs +17 -0
- package/esm2022/lib/v1/objects/oNewPayment.mjs +2 -0
- package/esm2022/lib/v1/objects/oNotification.mjs +17 -0
- package/esm2022/lib/v1/objects/oPassport.mjs +7 -0
- package/esm2022/lib/v1/objects/oUser.mjs +2 -0
- package/esm2022/lib/v1/util/UtilBusiness.mjs +181 -0
- package/esm2022/lib/v1/util/UtilClient.mjs +221 -0
- package/esm2022/lib/v1/util/UtilContract.mjs +339 -0
- package/esm2022/lib/v1/util/UtilDynamiCore.mjs +292 -0
- package/esm2022/public-api.mjs +16 -2
- package/fesm2022/ravcredit-lib.mjs +962 -1
- package/fesm2022/ravcredit-lib.mjs.map +1 -1
- package/lib/v1/objects/oAddress.d.ts +9 -0
- package/lib/v1/objects/oBusiness.d.ts +101 -0
- package/lib/{oClient.d.ts → v1/objects/oClient.d.ts} +0 -1
- package/lib/v1/objects/oConekta.d.ts +305 -0
- package/lib/v1/objects/oContract.d.ts +23 -0
- package/lib/v1/objects/oContractAll.d.ts +21 -0
- package/lib/v1/objects/oCustomer.d.ts +17 -0
- package/lib/v1/objects/oDevice.d.ts +5 -0
- package/lib/v1/objects/oFinancial.d.ts +30 -0
- package/lib/v1/objects/oGlobal.d.ts +149 -0
- package/lib/v1/objects/oLogIn.d.ts +30 -0
- package/lib/v1/objects/oNewPayment.d.ts +11 -0
- package/lib/v1/objects/oNotification.d.ts +25 -0
- package/lib/v1/objects/oPassport.d.ts +55 -0
- package/lib/v1/objects/oUser.d.ts +25 -0
- package/lib/v1/util/UtilBusiness.d.ts +54 -0
- package/lib/v1/util/UtilClient.d.ts +34 -0
- package/lib/v1/util/UtilContract.d.ts +71 -0
- package/lib/v1/util/UtilDynamiCore.d.ts +453 -0
- package/package.json +1 -1
- package/public-api.d.ts +15 -1
- package/esm2022/lib/oClient.mjs +0 -2
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { tyClientContract } from "./oGlobal";
|
|
2
|
+
import { oClient } from "./oClient";
|
|
3
|
+
import { oContract } from "./oContract";
|
|
4
|
+
import { IDCAccount } from '../util/UtilDynamiCore';
|
|
5
|
+
export interface iContractAll {
|
|
6
|
+
getAllLocal(): Promise<void>;
|
|
7
|
+
getAllServer(): Promise<void>;
|
|
8
|
+
getDynamicTransactionsManual(account: number): Promise<boolean>;
|
|
9
|
+
createNewReferenceDynamic(client: tyClientContract): Promise<boolean>;
|
|
10
|
+
createNewReferenceConekta(client: tyClientContract): Promise<void>;
|
|
11
|
+
createNewReferencePassport(client: tyClientContract): Promise<void>;
|
|
12
|
+
referenceCreated(response: boolean, provider: string): void;
|
|
13
|
+
getColumnName(column: string): string;
|
|
14
|
+
searchDynamicAccount(client: tyClientContract): Promise<IDCAccount | null>;
|
|
15
|
+
updateClient(client: Partial<oClient>): Promise<boolean>;
|
|
16
|
+
updateContract(id: string, contract: Partial<oContract>): Promise<boolean>;
|
|
17
|
+
deleteClient(client: oClient): Promise<boolean>;
|
|
18
|
+
deleteContract(contract: oContract): Promise<boolean>;
|
|
19
|
+
updateClientAppAccess(client: Partial<oClient>, id: string): Promise<boolean>;
|
|
20
|
+
calcTotal(contract: oContract): number;
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export interface oCustomer {
|
|
2
|
+
livemode: boolean;
|
|
3
|
+
name: string;
|
|
4
|
+
email: string;
|
|
5
|
+
phone: string;
|
|
6
|
+
id: string;
|
|
7
|
+
object: string;
|
|
8
|
+
created_at: number;
|
|
9
|
+
corporate: boolean;
|
|
10
|
+
custom_reference: string;
|
|
11
|
+
}
|
|
12
|
+
export interface oCustomerInfo {
|
|
13
|
+
customer_id: string;
|
|
14
|
+
name?: string;
|
|
15
|
+
email?: string;
|
|
16
|
+
phone?: string;
|
|
17
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { oBusinessDeadlines } from "./oBusiness";
|
|
2
|
+
export interface oFinancialProgress {
|
|
3
|
+
id: string;
|
|
4
|
+
amount: number;
|
|
5
|
+
date: number;
|
|
6
|
+
}
|
|
7
|
+
export interface oFinancial {
|
|
8
|
+
total: number;
|
|
9
|
+
initial: number;
|
|
10
|
+
deadlines: oBusinessDeadlines;
|
|
11
|
+
initDate?: number;
|
|
12
|
+
finalDate?: number;
|
|
13
|
+
weeklyPayment: number;
|
|
14
|
+
dayCut?: number;
|
|
15
|
+
finalPayment?: number;
|
|
16
|
+
progress?: oFinancialProgress[];
|
|
17
|
+
pendingOf: string[];
|
|
18
|
+
interest: number;
|
|
19
|
+
provider: string;
|
|
20
|
+
financed: number;
|
|
21
|
+
nextPayment: number;
|
|
22
|
+
amount_commission_opening?: number;
|
|
23
|
+
principal_disbursed?: number;
|
|
24
|
+
expected_disbursed?: number;
|
|
25
|
+
credit_type?: string;
|
|
26
|
+
interest_rate?: number;
|
|
27
|
+
commission_opening?: number;
|
|
28
|
+
interest_arrears?: number;
|
|
29
|
+
clabe?: string;
|
|
30
|
+
}
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
import { oUser } from "./oUser";
|
|
2
|
+
import { oBusinessInfo, oSchedule } from "./oBusiness";
|
|
3
|
+
import { oClient } from "./oClient";
|
|
4
|
+
import { oDevice } from "./oDevice";
|
|
5
|
+
import { oAddress } from "./oAddress";
|
|
6
|
+
import { oFinancial } from "./oFinancial";
|
|
7
|
+
import { MatSnackBarConfig } from "@angular/material/snack-bar";
|
|
8
|
+
import { oContract } from "./oContract";
|
|
9
|
+
import { oNotification } from "./oNotification";
|
|
10
|
+
export declare enum eRoles {
|
|
11
|
+
Administrator = "Administrator",
|
|
12
|
+
Seller = "Seller",
|
|
13
|
+
Consultant = "Consultant"
|
|
14
|
+
}
|
|
15
|
+
export declare enum eProcessStatus {
|
|
16
|
+
IDLE = "IDLE",
|
|
17
|
+
ERROR = "ERROR",
|
|
18
|
+
CANCELED = "CANCELED",
|
|
19
|
+
COMPLETE = "COMPLETE",
|
|
20
|
+
PROCESSING = "PROCESSING",
|
|
21
|
+
WAITING = "WAITING"
|
|
22
|
+
}
|
|
23
|
+
export declare enum eLoginStatus {
|
|
24
|
+
IDLE = "IDLE",
|
|
25
|
+
ERROR = "ERROR",
|
|
26
|
+
AUTHORIZED = "AUTHORIZED",
|
|
27
|
+
CHECKING = "CHECKING",
|
|
28
|
+
NOAUTHORIZED = "NOAUTHORIZED",
|
|
29
|
+
NOTFOUND = "NOTFOUND",
|
|
30
|
+
ERRORPASSWORD = "ERRORPASSWORD"
|
|
31
|
+
}
|
|
32
|
+
export declare enum eClientStatus {
|
|
33
|
+
ACTIVE = "active",
|
|
34
|
+
COMPLETED = "completed",
|
|
35
|
+
PAUSED = "paused",
|
|
36
|
+
CANCELED = "canceled",
|
|
37
|
+
LATE = "late"
|
|
38
|
+
}
|
|
39
|
+
export declare const cSingleOptionClientStatus: iOptionsSelect;
|
|
40
|
+
export declare const cOptionsClientStatus: iOptionsSelect[];
|
|
41
|
+
export interface iOptionsSelect {
|
|
42
|
+
viewValue: String;
|
|
43
|
+
value: String;
|
|
44
|
+
}
|
|
45
|
+
export interface iSelect {
|
|
46
|
+
viewValue: eRoles;
|
|
47
|
+
value: eRoles;
|
|
48
|
+
}
|
|
49
|
+
export declare const eRolesSelect: iSelect[];
|
|
50
|
+
export interface iConfigUUID {
|
|
51
|
+
client_uuid?: string;
|
|
52
|
+
contract_uuid: string;
|
|
53
|
+
}
|
|
54
|
+
export interface iPaymentDelay {
|
|
55
|
+
today: number;
|
|
56
|
+
nextPayment: number;
|
|
57
|
+
daysDelay: number;
|
|
58
|
+
late: boolean;
|
|
59
|
+
}
|
|
60
|
+
export declare const cPaymentDalay: iPaymentDelay;
|
|
61
|
+
export interface oResponse {
|
|
62
|
+
error?: string;
|
|
63
|
+
data: oUser | oUser[] | oBusinessInfo | oAddress | oSchedule | oFinancial | string | iPaymentDelay | oClient | oDevice | iConfigUUID | Response | oNotification;
|
|
64
|
+
}
|
|
65
|
+
export interface gResponse {
|
|
66
|
+
status?: boolean;
|
|
67
|
+
path: string;
|
|
68
|
+
statusCode: number;
|
|
69
|
+
error?: string;
|
|
70
|
+
epochTime: number;
|
|
71
|
+
data: any;
|
|
72
|
+
}
|
|
73
|
+
export interface gResponseFuncEmail {
|
|
74
|
+
success: boolean;
|
|
75
|
+
message: any;
|
|
76
|
+
}
|
|
77
|
+
export declare const snackBarConfigAction: MatSnackBarConfig;
|
|
78
|
+
export declare const snackBarConfigNoAction: MatSnackBarConfig;
|
|
79
|
+
export interface iInformativeDialog {
|
|
80
|
+
message: string;
|
|
81
|
+
title: string;
|
|
82
|
+
cancel: string;
|
|
83
|
+
continue: string;
|
|
84
|
+
}
|
|
85
|
+
export interface iSnackBarMessage {
|
|
86
|
+
message: string;
|
|
87
|
+
action: string;
|
|
88
|
+
config: MatSnackBarConfig;
|
|
89
|
+
}
|
|
90
|
+
export type tyClientContract = oClient & oContract;
|
|
91
|
+
export declare const cTyClientContract: {
|
|
92
|
+
id: string;
|
|
93
|
+
dynamicAccount?: number;
|
|
94
|
+
client: string;
|
|
95
|
+
address: oAddress;
|
|
96
|
+
device: oDevice;
|
|
97
|
+
financial: oFinancial;
|
|
98
|
+
createdAt?: number;
|
|
99
|
+
lastPayment?: number;
|
|
100
|
+
by: string;
|
|
101
|
+
active: boolean;
|
|
102
|
+
photo?: string;
|
|
103
|
+
name: string;
|
|
104
|
+
username: string;
|
|
105
|
+
password?: string;
|
|
106
|
+
email: string;
|
|
107
|
+
phone: string;
|
|
108
|
+
curp: string;
|
|
109
|
+
contract?: string;
|
|
110
|
+
lastLogin?: number;
|
|
111
|
+
contract_temporary?: string;
|
|
112
|
+
exists?: boolean;
|
|
113
|
+
conekta_id?: string;
|
|
114
|
+
dynamic_id?: number | string;
|
|
115
|
+
dynamic_account?: string | number;
|
|
116
|
+
dynamic_ref?: string;
|
|
117
|
+
passport_id?: string;
|
|
118
|
+
payments?: import("./oClient").oClientPayments[];
|
|
119
|
+
reference?: string;
|
|
120
|
+
references?: import("./oClient").oClientReferences[];
|
|
121
|
+
token?: string;
|
|
122
|
+
userReferences: import("./oClient").oUserReference[];
|
|
123
|
+
contractUrl?: string;
|
|
124
|
+
status: string;
|
|
125
|
+
};
|
|
126
|
+
export interface oContractMetrics {
|
|
127
|
+
total: number;
|
|
128
|
+
activated: number;
|
|
129
|
+
paused: number;
|
|
130
|
+
completed: number;
|
|
131
|
+
canceled: number;
|
|
132
|
+
late: number;
|
|
133
|
+
dynamicCount: number;
|
|
134
|
+
passportCount: number;
|
|
135
|
+
conektaCount: number;
|
|
136
|
+
rateTotal: number;
|
|
137
|
+
rateActive: number;
|
|
138
|
+
ratePaused: number;
|
|
139
|
+
rateComplete: number;
|
|
140
|
+
rateCanceled: number;
|
|
141
|
+
rateLate: number;
|
|
142
|
+
}
|
|
143
|
+
export interface HasUnsavedChanges {
|
|
144
|
+
hasUnsavedChanges(): boolean;
|
|
145
|
+
}
|
|
146
|
+
export interface oPaymentDates {
|
|
147
|
+
week: number;
|
|
148
|
+
date: number;
|
|
149
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { WritableSignal } from "@angular/core";
|
|
2
|
+
export declare enum eAuthActions {
|
|
3
|
+
delete = "delete",
|
|
4
|
+
auth = "auth"
|
|
5
|
+
}
|
|
6
|
+
export declare enum eAuthType {
|
|
7
|
+
auth = "auth",
|
|
8
|
+
login = "login",
|
|
9
|
+
idle = ""
|
|
10
|
+
}
|
|
11
|
+
export interface iAuthConfig {
|
|
12
|
+
title: string;
|
|
13
|
+
desc: string;
|
|
14
|
+
data: boolean;
|
|
15
|
+
}
|
|
16
|
+
export declare const cAuthConfig: iAuthConfig;
|
|
17
|
+
export interface ISignIn {
|
|
18
|
+
username: WritableSignal<string>;
|
|
19
|
+
password: WritableSignal<string>;
|
|
20
|
+
login(credentials: oAuth, destination: string): Promise<void>;
|
|
21
|
+
success(): void;
|
|
22
|
+
}
|
|
23
|
+
export interface oAuth {
|
|
24
|
+
username: string;
|
|
25
|
+
password: string;
|
|
26
|
+
}
|
|
27
|
+
export interface oAuthRes {
|
|
28
|
+
status: number;
|
|
29
|
+
data: {};
|
|
30
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { oContract } from "./oContract";
|
|
2
|
+
import { oClient } from "./oClient";
|
|
3
|
+
export interface iNewPayment {
|
|
4
|
+
getContract(): Promise<void>;
|
|
5
|
+
getContractApi(): Promise<oContract>;
|
|
6
|
+
getClient(contract: oContract): Promise<void>;
|
|
7
|
+
getClientApi(contract: oContract): Promise<oClient>;
|
|
8
|
+
getParams(): Promise<void>;
|
|
9
|
+
getAccount(): Promise<boolean>;
|
|
10
|
+
createPayment(): Promise<string>;
|
|
11
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export declare const cTopic = "RavCreditClients";
|
|
2
|
+
export declare enum eNotificationType {
|
|
3
|
+
GLOBAL = "global",
|
|
4
|
+
USER = "user",
|
|
5
|
+
PAYMENT = "payment"
|
|
6
|
+
}
|
|
7
|
+
export interface oNotificationResponses {
|
|
8
|
+
successCount: number;
|
|
9
|
+
failureCount: number;
|
|
10
|
+
}
|
|
11
|
+
export interface oNotification {
|
|
12
|
+
ids?: string[];
|
|
13
|
+
type?: string;
|
|
14
|
+
tokens?: string[];
|
|
15
|
+
topic?: string;
|
|
16
|
+
notification: {
|
|
17
|
+
title: string;
|
|
18
|
+
body: string;
|
|
19
|
+
};
|
|
20
|
+
data: any;
|
|
21
|
+
notification_id?: number;
|
|
22
|
+
recipient?: string;
|
|
23
|
+
responses?: oNotificationResponses;
|
|
24
|
+
}
|
|
25
|
+
export declare const cNotification: oNotification;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { oContract } from "./oContract";
|
|
2
|
+
export declare enum ePassportTypes {
|
|
3
|
+
CREATE = "create_references",
|
|
4
|
+
SEND = "send_references"
|
|
5
|
+
}
|
|
6
|
+
/** *********************************************************************************/
|
|
7
|
+
export interface iPassportAdditional {
|
|
8
|
+
client?: string;
|
|
9
|
+
clientID?: string;
|
|
10
|
+
credit?: string;
|
|
11
|
+
}
|
|
12
|
+
export interface iPassportReferenceData {
|
|
13
|
+
name: string;
|
|
14
|
+
email: string;
|
|
15
|
+
amount: number;
|
|
16
|
+
expirationDate: string;
|
|
17
|
+
additional: iPassportAdditional;
|
|
18
|
+
}
|
|
19
|
+
/** Passport request interface base */
|
|
20
|
+
export interface iPassportReference {
|
|
21
|
+
type: string;
|
|
22
|
+
data: iPassportReferenceData;
|
|
23
|
+
}
|
|
24
|
+
/** Global passport reference aPI */
|
|
25
|
+
export interface iGlobalPassport {
|
|
26
|
+
passport: iPassportReference;
|
|
27
|
+
contract: oContract;
|
|
28
|
+
date?: number;
|
|
29
|
+
}
|
|
30
|
+
/** ******************************** */
|
|
31
|
+
export interface iPassportResponseData {
|
|
32
|
+
name: string;
|
|
33
|
+
email: string;
|
|
34
|
+
amount: number;
|
|
35
|
+
expirationDate: string;
|
|
36
|
+
additional: iPassportAdditional;
|
|
37
|
+
}
|
|
38
|
+
export interface iPassportReferenceCenters {
|
|
39
|
+
name: string;
|
|
40
|
+
logo: string;
|
|
41
|
+
}
|
|
42
|
+
export interface iPassportReferenceRes {
|
|
43
|
+
reference: string;
|
|
44
|
+
centers: iPassportReferenceCenters[];
|
|
45
|
+
centerId: number;
|
|
46
|
+
barcode: string;
|
|
47
|
+
}
|
|
48
|
+
/** Passport response interface base */
|
|
49
|
+
export interface iPassportResponse {
|
|
50
|
+
type: string;
|
|
51
|
+
data: iPassportResponseData;
|
|
52
|
+
message: string;
|
|
53
|
+
references: iPassportReference[];
|
|
54
|
+
}
|
|
55
|
+
/** ******************************** */
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { eRoles } from "./oGlobal";
|
|
2
|
+
import { WritableSignal } from "@angular/core";
|
|
3
|
+
export interface iUser {
|
|
4
|
+
pUser: oUser;
|
|
5
|
+
getAllUsers(): void;
|
|
6
|
+
editUser(user: oUser): void;
|
|
7
|
+
deleteUser(user: oUser): void;
|
|
8
|
+
}
|
|
9
|
+
export interface oUser {
|
|
10
|
+
id: string;
|
|
11
|
+
username: string;
|
|
12
|
+
name: string;
|
|
13
|
+
password: string;
|
|
14
|
+
role: eRoles;
|
|
15
|
+
lastLogin?: number;
|
|
16
|
+
createdAt?: number;
|
|
17
|
+
access_token: string;
|
|
18
|
+
}
|
|
19
|
+
export interface iServiceUser {
|
|
20
|
+
users: WritableSignal<oUser[]>;
|
|
21
|
+
getAllUsersServer(): void;
|
|
22
|
+
createUser(o: oUser): void;
|
|
23
|
+
updateUser(o: oUser): void;
|
|
24
|
+
deleteUser(id: string): void;
|
|
25
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { UntypedFormArray, UntypedFormControl } from "@angular/forms";
|
|
2
|
+
import { oBusinessConfig, oBusinessDeadlines, oBusinessInfo, oSchedule, oTmpBusinessConfig } from "../objects/oBusiness";
|
|
3
|
+
import { oAddress } from '../objects/oAddress';
|
|
4
|
+
export declare const cAddress: oAddress;
|
|
5
|
+
export declare const cSchedule: oSchedule;
|
|
6
|
+
export declare const cEmptyDay: oSchedule;
|
|
7
|
+
export declare const week: string[];
|
|
8
|
+
export declare const cDefinedSchedule: oSchedule[];
|
|
9
|
+
export declare const cBusinessInfo: oBusinessInfo;
|
|
10
|
+
export declare const cBusinessDeadlines: oBusinessDeadlines;
|
|
11
|
+
export declare const cBusinessConfig: oBusinessConfig;
|
|
12
|
+
export declare class FactoryBusiness {
|
|
13
|
+
static FormBusinessInfo(info?: oBusinessInfo): {
|
|
14
|
+
name: UntypedFormControl;
|
|
15
|
+
email: UntypedFormControl;
|
|
16
|
+
desc: UntypedFormControl;
|
|
17
|
+
street: UntypedFormControl;
|
|
18
|
+
neighbor: UntypedFormControl;
|
|
19
|
+
cp: UntypedFormControl;
|
|
20
|
+
ext: UntypedFormControl;
|
|
21
|
+
int: UntypedFormControl;
|
|
22
|
+
city: UntypedFormControl;
|
|
23
|
+
state: UntypedFormControl;
|
|
24
|
+
phones: UntypedFormControl;
|
|
25
|
+
mondayOpen: UntypedFormControl;
|
|
26
|
+
mondayClose: UntypedFormControl;
|
|
27
|
+
tuesdayOpen: UntypedFormControl;
|
|
28
|
+
tuesdayClose: UntypedFormControl;
|
|
29
|
+
wednesdayOpen: UntypedFormControl;
|
|
30
|
+
wednesdayClose: UntypedFormControl;
|
|
31
|
+
thursdayOpen: UntypedFormControl;
|
|
32
|
+
thursdayClose: UntypedFormControl;
|
|
33
|
+
fridayOpen: UntypedFormControl;
|
|
34
|
+
fridayClose: UntypedFormControl;
|
|
35
|
+
saturdayOpen: UntypedFormControl;
|
|
36
|
+
saturdayClose: UntypedFormControl;
|
|
37
|
+
sundayOpen: UntypedFormControl;
|
|
38
|
+
sundayClose: UntypedFormControl;
|
|
39
|
+
};
|
|
40
|
+
static CreateBusinessInfoObj(data: oTmpBusinessConfig): oBusinessInfo;
|
|
41
|
+
static FormDeadlineConfig(data: oBusinessDeadlines): {
|
|
42
|
+
weeks: UntypedFormControl;
|
|
43
|
+
interest: UntypedFormControl;
|
|
44
|
+
};
|
|
45
|
+
static FormBusinessConfig(config?: oBusinessConfig): {
|
|
46
|
+
downloadsClient: UntypedFormControl;
|
|
47
|
+
passportPaymentReference: UntypedFormControl;
|
|
48
|
+
conektaPaymentReference: UntypedFormControl;
|
|
49
|
+
conektaPaymentLink: UntypedFormControl;
|
|
50
|
+
dynamicPaymentReference: UntypedFormControl;
|
|
51
|
+
deadlines: UntypedFormArray;
|
|
52
|
+
};
|
|
53
|
+
static testBusiness(message: string): string;
|
|
54
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { oClient, oUserReference } from '../objects/oClient';
|
|
2
|
+
import { iConektaRecurrent, iConektaSources } from '../objects/oConekta';
|
|
3
|
+
import { oContract } from '../objects/oContract';
|
|
4
|
+
import { tyClientContract } from '../objects/oGlobal';
|
|
5
|
+
import { IDCAccount, IDCClient } from './UtilDynamiCore';
|
|
6
|
+
import { oFinancial } from '../objects/oFinancial';
|
|
7
|
+
export declare const cClient: oClient;
|
|
8
|
+
export interface oClientConekta {
|
|
9
|
+
ravcredit: oClient;
|
|
10
|
+
conekta: iConektaRecurrent;
|
|
11
|
+
}
|
|
12
|
+
export declare const cUserReference: oUserReference;
|
|
13
|
+
export declare const cClientConekta: oClientConekta;
|
|
14
|
+
export interface iClientContract {
|
|
15
|
+
client: oClient;
|
|
16
|
+
contract: oContract;
|
|
17
|
+
}
|
|
18
|
+
export declare const cClientContract: iClientContract;
|
|
19
|
+
export declare class FactoryClient {
|
|
20
|
+
static CreateClientToConektaObj(data: oClient): any;
|
|
21
|
+
static CreateClientFromFormObj(data: any, client?: oClient): oClient;
|
|
22
|
+
static CreateClientConektaObj(data: oClient, finalDate: number): {
|
|
23
|
+
name: string;
|
|
24
|
+
email: string;
|
|
25
|
+
phone: string;
|
|
26
|
+
contract: string | undefined;
|
|
27
|
+
client_id: string;
|
|
28
|
+
payment_sources: iConektaSources[];
|
|
29
|
+
};
|
|
30
|
+
static MapperConektaClient(client: oClient, conekta: iConektaRecurrent): iClientContract;
|
|
31
|
+
static MapperTypeContCli_Client(_client: tyClientContract): oClient;
|
|
32
|
+
static MapperDynamicClient(dynamic: IDCClient, client: oClient, contract: oContract, clientDyn?: IDCClient, account?: IDCAccount): iClientContract;
|
|
33
|
+
static MapperFinancialContract(contract: oContract, account: IDCAccount): oFinancial;
|
|
34
|
+
}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { UntypedFormArray, UntypedFormControl } from "@angular/forms";
|
|
2
|
+
import { IDCAccount } from "./UtilDynamiCore";
|
|
3
|
+
import { oDevice } from '../objects/oDevice';
|
|
4
|
+
import { oFinancial } from '../objects/oFinancial';
|
|
5
|
+
import { oAddress } from '../objects/oAddress';
|
|
6
|
+
import { oContract } from '../objects/oContract';
|
|
7
|
+
import { oClient, oUserReference } from '../objects/oClient';
|
|
8
|
+
import { tyClientContract } from '../objects/oGlobal';
|
|
9
|
+
export declare enum eProvider {
|
|
10
|
+
none = "",
|
|
11
|
+
Conekta = "Conekta",
|
|
12
|
+
Passport = "Passport",
|
|
13
|
+
DynamiCore = "DynamiCore"
|
|
14
|
+
}
|
|
15
|
+
export declare const cDevice: oDevice;
|
|
16
|
+
export declare const cFinancial: oFinancial;
|
|
17
|
+
export declare const cAddress: oAddress;
|
|
18
|
+
export declare const cContract: oContract;
|
|
19
|
+
export declare class FactoryContract {
|
|
20
|
+
static FormClient(client?: oClient): {
|
|
21
|
+
name: UntypedFormControl;
|
|
22
|
+
email: UntypedFormControl;
|
|
23
|
+
phone: UntypedFormControl;
|
|
24
|
+
curp: UntypedFormControl;
|
|
25
|
+
userReferences: UntypedFormArray;
|
|
26
|
+
};
|
|
27
|
+
static CreateUserReferenceFormObj(user: oUserReference): {
|
|
28
|
+
name: UntypedFormControl;
|
|
29
|
+
phone: UntypedFormControl;
|
|
30
|
+
relationship: UntypedFormControl;
|
|
31
|
+
};
|
|
32
|
+
static FormAddress(address?: oAddress): {
|
|
33
|
+
street: UntypedFormControl;
|
|
34
|
+
neighbor: UntypedFormControl;
|
|
35
|
+
cp: UntypedFormControl;
|
|
36
|
+
ext: UntypedFormControl;
|
|
37
|
+
int: UntypedFormControl;
|
|
38
|
+
city: UntypedFormControl;
|
|
39
|
+
state: UntypedFormControl;
|
|
40
|
+
};
|
|
41
|
+
static FormDevice(device?: oDevice): {
|
|
42
|
+
model: UntypedFormControl;
|
|
43
|
+
IMEI: UntypedFormControl;
|
|
44
|
+
ID: UntypedFormControl;
|
|
45
|
+
};
|
|
46
|
+
static FormFinancial(financial?: oFinancial): {
|
|
47
|
+
total: UntypedFormControl;
|
|
48
|
+
initial: UntypedFormControl;
|
|
49
|
+
financed: UntypedFormControl;
|
|
50
|
+
weeklyPayment: UntypedFormControl;
|
|
51
|
+
deadlines: UntypedFormControl;
|
|
52
|
+
initDate: UntypedFormControl;
|
|
53
|
+
provider: UntypedFormControl;
|
|
54
|
+
credit_type: UntypedFormControl;
|
|
55
|
+
interest_rate: UntypedFormControl;
|
|
56
|
+
commission_opening: UntypedFormControl;
|
|
57
|
+
interest_arrears: UntypedFormControl;
|
|
58
|
+
amount_commission_opening: UntypedFormControl;
|
|
59
|
+
principal_disbursed: UntypedFormControl;
|
|
60
|
+
expected_disbursed: UntypedFormControl;
|
|
61
|
+
};
|
|
62
|
+
static CreateContractFromFormObj(data: any, finalPay: number): oContract;
|
|
63
|
+
static CreateContractToConektaObj(data: oContract, monthlyPay: number, finalPay: number): oContract;
|
|
64
|
+
static CreateAuthForm(username: string, curp: string): {
|
|
65
|
+
username: UntypedFormControl;
|
|
66
|
+
password: UntypedFormControl;
|
|
67
|
+
};
|
|
68
|
+
static createPassword(curp: string): string;
|
|
69
|
+
static MapperTypeContCli_Contract(_contract: tyClientContract): oContract;
|
|
70
|
+
static MapperSyncContractDynamic(base: oContract, account: IDCAccount): oContract;
|
|
71
|
+
}
|