ravcredit-lib 0.0.19 → 0.0.21
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/fesm2022/ravcredit-lib.mjs +2127 -0
- package/fesm2022/ravcredit-lib.mjs.map +1 -0
- package/index.d.ts +1734 -0
- package/package.json +25 -14
- package/ng-package.json +0 -7
- package/src/index.d.ts +0 -45
- package/src/lib/ravcredit-lib.component.spec.ts +0 -23
- package/src/lib/ravcredit-lib.component.ts +0 -16
- package/src/lib/ravcredit-lib.service.spec.ts +0 -16
- package/src/lib/ravcredit-lib.service.ts +0 -9
- package/src/lib/v1/const/constants.ts +0 -35
- package/src/lib/v1/idb/idb.service.spec.ts +0 -16
- package/src/lib/v1/idb/indexed-db.service.ts +0 -396
- package/src/lib/v1/objects/oAddress.ts +0 -19
- package/src/lib/v1/objects/oBusiness.ts +0 -112
- package/src/lib/v1/objects/oClient.ts +0 -46
- package/src/lib/v1/objects/oConekta.ts +0 -408
- package/src/lib/v1/objects/oContract.ts +0 -31
- package/src/lib/v1/objects/oContractAll.ts +0 -38
- package/src/lib/v1/objects/oCustomer.ts +0 -36
- package/src/lib/v1/objects/oDevice.ts +0 -5
- package/src/lib/v1/objects/oFinancial.ts +0 -32
- package/src/lib/v1/objects/oGlobal.ts +0 -192
- package/src/lib/v1/objects/oLogIn.ts +0 -43
- package/src/lib/v1/objects/oNewPayment.ts +0 -18
- package/src/lib/v1/objects/oNotification.ts +0 -34
- package/src/lib/v1/objects/oPassport.ts +0 -65
- package/src/lib/v1/objects/oUser.ts +0 -35
- package/src/lib/v1/objects/oVerification.ts +0 -100
- package/src/lib/v1/util/UtilBusiness.ts +0 -186
- package/src/lib/v1/util/UtilClient.ts +0 -295
- package/src/lib/v1/util/UtilConekta.ts +0 -97
- package/src/lib/v1/util/UtilContract.ts +0 -432
- package/src/lib/v1/util/UtilDashboard.ts +0 -19
- package/src/lib/v1/util/UtilDynamiCore.ts +0 -752
- package/src/lib/v1/util/UtilNotification.ts +0 -46
- package/src/lib/v1/util/UtilPassport.ts +0 -32
- package/src/lib/v1/util/UtilPayment.ts +0 -22
- package/src/lib/v1/util/UtilTime.ts +0 -179
- package/src/lib/v1/util/UtilsHttp.ts +0 -25
- package/src/lib/v2/const/constants.ts +0 -37
- package/src/lib/v2/messaging/messaging.ts +0 -10
- package/src/lib/v2/objects/oAsset.ts +0 -48
- package/src/lib/v2/objects/oAws.ts +0 -8
- package/src/lib/v2/objects/oCatalog.ts +0 -6
- package/src/lib/v2/objects/oClient.ts +0 -37
- package/src/lib/v2/objects/oCompany.ts +0 -10
- package/src/lib/v2/objects/oContract.ts +0 -10
- package/src/lib/v2/objects/oMediaDto.ts +0 -10
- package/src/lib/v2/objects/oScoreDto.ts +0 -40
- package/src/public-api.ts +0 -45
- package/tsconfig.lib.json +0 -15
- package/tsconfig.lib.prod.json +0 -11
- package/tsconfig.spec.json +0 -15
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import {cNotification, oNotification} from '../objects/oNotification';
|
|
2
|
-
import {UntypedFormControl, Validators} from '@angular/forms';
|
|
3
|
-
|
|
4
|
-
export const ROUTE_NOTIFICATIONS = "notifications"
|
|
5
|
-
export const ROUTE_GLOBAL_REFERENCE2 = "/contract-reference"
|
|
6
|
-
|
|
7
|
-
const prodFunction = "https://us-central1-ravcredit-2b079.cloudfunctions.net/CustomerNotification"
|
|
8
|
-
const prodFunction2 = "https://customernotification-2imgfxveka-uc.a.run.app"
|
|
9
|
-
const localTest = "http://127.0.0.1:5001/ravcredit-2b079/us-central1/CustomerNotification"
|
|
10
|
-
export const ravCreditFunctions = prodFunction
|
|
11
|
-
|
|
12
|
-
export class FactoryNotification {
|
|
13
|
-
|
|
14
|
-
public static FormNotification(notification?: oNotification) {
|
|
15
|
-
let data = cNotification
|
|
16
|
-
|
|
17
|
-
if (notification) data = notification
|
|
18
|
-
|
|
19
|
-
return {
|
|
20
|
-
title: new UntypedFormControl(data.notification.title, [Validators.required, Validators.min(1)]),
|
|
21
|
-
body: new UntypedFormControl(data.notification.body, [Validators.required, Validators.min(1)]),
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
public static CreateGlobalNotificationObj(data: oNotification) {
|
|
26
|
-
const o: any = {}
|
|
27
|
-
|
|
28
|
-
if (data.notification) {
|
|
29
|
-
const not: any = {}
|
|
30
|
-
if (data.notification.body) not["body"] = data.notification.body
|
|
31
|
-
if (data.notification.title) not["title"] = data.notification.title
|
|
32
|
-
|
|
33
|
-
if (data.ids) not["ids"] = data.ids
|
|
34
|
-
|
|
35
|
-
if (data.tokens) not["tokens"] = data.tokens
|
|
36
|
-
|
|
37
|
-
if (data.type) not["type"] = data.type
|
|
38
|
-
|
|
39
|
-
if (data.data) if (data.data.route) not["route"] = data.data.route
|
|
40
|
-
|
|
41
|
-
o["data"] = not
|
|
42
|
-
}
|
|
43
|
-
return o
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import {oContract} from '../objects/oContract';
|
|
2
|
-
import {oClient} from '../objects/oClient';
|
|
3
|
-
import {ePassportTypes, iGlobalPassport} from '../objects/oPassport';
|
|
4
|
-
|
|
5
|
-
export class FactoryPassport {
|
|
6
|
-
public static CreatePassportReference(
|
|
7
|
-
client: oClient,
|
|
8
|
-
contract: oContract,
|
|
9
|
-
dateTime?: number
|
|
10
|
-
): iGlobalPassport {
|
|
11
|
-
const o = {
|
|
12
|
-
passport: {
|
|
13
|
-
type: ePassportTypes.CREATE,
|
|
14
|
-
data: {
|
|
15
|
-
name: client.name,
|
|
16
|
-
email: client.email,
|
|
17
|
-
amount: contract.financial.weeklyPayment,
|
|
18
|
-
expirationDate: "",
|
|
19
|
-
additional: {
|
|
20
|
-
client: client.name,
|
|
21
|
-
clientID: client.id,
|
|
22
|
-
credit: client.status
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
},
|
|
26
|
-
contract: contract,
|
|
27
|
-
date: dateTime
|
|
28
|
-
}
|
|
29
|
-
if (dateTime != undefined) o.date = dateTime
|
|
30
|
-
return o
|
|
31
|
-
}
|
|
32
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import {oConektaRes} from '../objects/oConekta';
|
|
2
|
-
import {IDCTxnRow} from './UtilDynamiCore';
|
|
3
|
-
import {eProvider} from './UtilContract';
|
|
4
|
-
|
|
5
|
-
export interface oPaymentGlobal {
|
|
6
|
-
conektaPayment?: oConektaRes,
|
|
7
|
-
dynamicPayment?: IDCTxnRow[],
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export class FactoryPayment {
|
|
11
|
-
public static CreatePayment(data: oConektaRes | IDCTxnRow[], provider: eProvider): oPaymentGlobal {
|
|
12
|
-
const o: oPaymentGlobal = {}
|
|
13
|
-
|
|
14
|
-
if (provider == eProvider.DynamiCore)
|
|
15
|
-
o.dynamicPayment = data as IDCTxnRow[];
|
|
16
|
-
|
|
17
|
-
if (provider == eProvider.Conekta)
|
|
18
|
-
o.conektaPayment = data as oConektaRes
|
|
19
|
-
|
|
20
|
-
return o
|
|
21
|
-
}
|
|
22
|
-
}
|
|
@@ -1,179 +0,0 @@
|
|
|
1
|
-
import {add, format, getDate} from "date-fns";
|
|
2
|
-
import {es} from 'date-fns/locale/es';
|
|
3
|
-
import {eProvider} from './UtilContract';
|
|
4
|
-
import {inject, Injector, runInInjectionContext} from '@angular/core';
|
|
5
|
-
import {IDCTxnRow} from './UtilDynamiCore';
|
|
6
|
-
import {oPaymentDates} from '../objects/oGlobal';
|
|
7
|
-
import {oConektaOrder} from '../objects/oConekta';
|
|
8
|
-
import {dateCompleteFormat, dateFormat, expiredPayment, timeFormat} from '../const/constants';
|
|
9
|
-
import {IndexedDbService} from '../idb/indexed-db.service';
|
|
10
|
-
|
|
11
|
-
export class UtilTime {
|
|
12
|
-
private localeFns = es
|
|
13
|
-
|
|
14
|
-
public static IsExpired(time: number): boolean {
|
|
15
|
-
const dateInit = new Date(time)
|
|
16
|
-
const dayInit = dateInit.getDate()
|
|
17
|
-
const monthInit = dateInit.getMonth() + 1
|
|
18
|
-
|
|
19
|
-
const dateActual = new Date()
|
|
20
|
-
const dayActual = dateActual.getDate()
|
|
21
|
-
const monthActual = dateActual.getMonth() + 1
|
|
22
|
-
|
|
23
|
-
if (monthActual > monthInit) return true
|
|
24
|
-
|
|
25
|
-
return dayActual > dayInit;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
public static getDates(initial: number, weeks: number): oPaymentDates[] {
|
|
29
|
-
const dates: oPaymentDates[] = []
|
|
30
|
-
let prev = initial
|
|
31
|
-
for (let i = 0; i < weeks; i++) {
|
|
32
|
-
const date = add(prev, {weeks: 1})
|
|
33
|
-
dates.push(
|
|
34
|
-
{
|
|
35
|
-
week: i + 1,
|
|
36
|
-
date: date.getTime()
|
|
37
|
-
}
|
|
38
|
-
)
|
|
39
|
-
prev = date.getTime()
|
|
40
|
-
}
|
|
41
|
-
return dates
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
public static getPreviousWeek() {
|
|
45
|
-
const today = new Date().getTime()
|
|
46
|
-
const week = ((3600 * 24) * 7) * 1000
|
|
47
|
-
return today - week
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
public static getDayNum(date: Date | number): number {
|
|
51
|
-
return getDate(date)
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
public static getDayName(date: Date | number): string {
|
|
55
|
-
return format(date, "EEEE", {locale: es})
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
public static getMonthName(date: Date | number): string {
|
|
59
|
-
return format(date, "MMMM", {locale: es}).toUpperCase();
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
public static getYear(date: Date | number): string {
|
|
63
|
-
return format(date, "yyyy")
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
public static GetNextPayment(time: number, provider: string) {
|
|
67
|
-
let week = 0
|
|
68
|
-
if (provider == eProvider.Conekta) {
|
|
69
|
-
week = (((3600 * 24) * 7))
|
|
70
|
-
} else if (provider == eProvider.DynamiCore) {
|
|
71
|
-
week = (((3600 * 24) * 7) * 1000)
|
|
72
|
-
}
|
|
73
|
-
return this.getLocalTimeFromLong(time + week, provider)
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
public static getLocalTimeFromLong(time: number, provider: string) {
|
|
77
|
-
if (time <= 0) return ""
|
|
78
|
-
let factor = this.GetFactor(provider)
|
|
79
|
-
let dateTime = time * factor
|
|
80
|
-
let parsedDate = format(new Date(dateTime), dateFormat, {
|
|
81
|
-
locale: es
|
|
82
|
-
})
|
|
83
|
-
return parsedDate
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
public static DelayPaymentLast(
|
|
87
|
-
lastPayment: number, provider: string, injector: Injector
|
|
88
|
-
): boolean {
|
|
89
|
-
let factor = this.GetFactor(provider)
|
|
90
|
-
let now = new Date().getTime()
|
|
91
|
-
let last = 0
|
|
92
|
-
|
|
93
|
-
if (provider == eProvider.Conekta)
|
|
94
|
-
last = ((((3600 * 24) * 7)) + lastPayment) * factor
|
|
95
|
-
else if (provider == eProvider.DynamiCore)
|
|
96
|
-
last = ((((3600 * 24) * 7) * 1000) + lastPayment) * factor
|
|
97
|
-
|
|
98
|
-
runInInjectionContext(injector, () => {
|
|
99
|
-
const idb = inject(IndexedDbService)
|
|
100
|
-
// const observable = inject(ObservablesService)
|
|
101
|
-
idb.setLocalStorage(expiredPayment, String(now > last))
|
|
102
|
-
// observable.isLate.next(now > last)
|
|
103
|
-
})
|
|
104
|
-
return now > last
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
public static GetFactor(provider: string) {
|
|
108
|
-
let factor = 1
|
|
109
|
-
if (provider == eProvider.Conekta)
|
|
110
|
-
factor = 1000
|
|
111
|
-
return factor
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
public static GetEpochFromFormatedDate(date: string): number {
|
|
115
|
-
if (date == "") return 0
|
|
116
|
-
|
|
117
|
-
const _date = new Date(date)
|
|
118
|
-
if (isNaN(_date.getTime())) return 0
|
|
119
|
-
return _date.getTime()
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
public static GetTimeFromString(date: string) {
|
|
123
|
-
return format(new Date(date), timeFormat, {
|
|
124
|
-
locale: es
|
|
125
|
-
})
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
public static GetDateFromString(date: string) {
|
|
129
|
-
return format(new Date(date), dateCompleteFormat, {
|
|
130
|
-
locale: es
|
|
131
|
-
})
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
// Quick sort
|
|
135
|
-
public static SortingByTime(payments: IDCTxnRow[]): IDCTxnRow[] {
|
|
136
|
-
if (payments.length <= 1) return payments
|
|
137
|
-
|
|
138
|
-
const pivot = payments[payments.length - 1]
|
|
139
|
-
const pivotDate = new Date(pivot.created).getTime()
|
|
140
|
-
const left: IDCTxnRow[] = []
|
|
141
|
-
const right: IDCTxnRow[] = []
|
|
142
|
-
|
|
143
|
-
for (let i = 0; i < payments.length - 1; i++) {
|
|
144
|
-
const actualDate = new Date(payments[i].created).getTime()
|
|
145
|
-
if (actualDate > pivotDate) left.push(payments[i])
|
|
146
|
-
else right.push(payments[i])
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
return [...this.SortingByTime(left), pivot, ...this.SortingByTime(right)]
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
public static SortingByTimeConekta(payments: oConektaOrder []): oConektaOrder[] {
|
|
153
|
-
if (payments.length <= 1) return payments;
|
|
154
|
-
|
|
155
|
-
const pivot = payments[payments.length - 1]
|
|
156
|
-
let pivotDate = 0;
|
|
157
|
-
if (pivot.charges.data == undefined) return payments
|
|
158
|
-
|
|
159
|
-
if (pivot.charges.data[0].paid_at != undefined) {
|
|
160
|
-
pivotDate = pivot.charges.data[0].paid_at
|
|
161
|
-
} else {
|
|
162
|
-
pivot.charges.data[0].created_at
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
if (pivotDate <= 0) return payments;
|
|
166
|
-
|
|
167
|
-
const left: oConektaOrder[] = []
|
|
168
|
-
const right: oConektaOrder [] = []
|
|
169
|
-
|
|
170
|
-
for (let i = 0; i < payments.length - 1; i++) {
|
|
171
|
-
const actual = payments[i].charges.data[0].paid_at;
|
|
172
|
-
if (actual <= 0) continue
|
|
173
|
-
if (actual > pivotDate) left.push(payments[i])
|
|
174
|
-
else right.push(payments[i])
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
return [...this.SortingByTimeConekta(left), pivot, ...this.SortingByTimeConekta(right)]
|
|
178
|
-
}
|
|
179
|
-
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
export class UtilsHttp {
|
|
2
|
-
|
|
3
|
-
public static CreateHeadersRavcreditApi(token: string) {
|
|
4
|
-
return {
|
|
5
|
-
'Content-Type': 'application/json',
|
|
6
|
-
'Accept': 'application/json',
|
|
7
|
-
'Access-Control-Allow-Headers': 'Content-Type',
|
|
8
|
-
'Authorization': `Bearer ${token}`
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
public static CreateSimpleHeadersApi() {
|
|
13
|
-
return {
|
|
14
|
-
'Content-Type': 'application/json',
|
|
15
|
-
'Accept': 'application/json',
|
|
16
|
-
'Access-Control-Allow-Headers': 'Content-Type',
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
public static CreateAwsHeadersApi() {
|
|
21
|
-
return {
|
|
22
|
-
'Content-Type': 'application/json'
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
export const keyUserID: string = "rc_uid"
|
|
2
|
-
export const dbVersion: number = 1
|
|
3
|
-
export const dbName: string = "RavCreditDB"
|
|
4
|
-
export const keyPathId: string = "id"
|
|
5
|
-
|
|
6
|
-
export const dbAuthStore: string = "authStore"
|
|
7
|
-
export const dbUsersStore: string = "usersStore"
|
|
8
|
-
export const dbContractsStore: string = "contractsStore"
|
|
9
|
-
export const dbClientsStore: string = "clientsStore"
|
|
10
|
-
export const dbBusinessInfo: string = "businessInfo"
|
|
11
|
-
export const dbBusinessConfig: string = "businessConfig"
|
|
12
|
-
export const dbConektaClientsStore: string = "conektaClientsStore"
|
|
13
|
-
export const dbConektaReferencesStore: string = "conektaReferencesStore"
|
|
14
|
-
export const dbPassportReferencesStore: string = "passportReferencesStore"
|
|
15
|
-
export const dbDynamicReferencesStore: string = "dynamicReferencesStore"
|
|
16
|
-
export const dbDynamicAccountStore: string = "dynamicAccountStore"
|
|
17
|
-
export const dbNotificationsStore: string = "notificationsStore"
|
|
18
|
-
export const dbPaymentsStore: string = "paymentsStore"
|
|
19
|
-
|
|
20
|
-
export const dbIndexAuth: string = "iAuth"
|
|
21
|
-
export const dbIndexUsers: string = "iUsers"
|
|
22
|
-
export const dbIndexContracts: string = "iContracts"
|
|
23
|
-
export const dbIndexClients: string = "iClients"
|
|
24
|
-
export const dbIndexBusiness: string = "iBusiness"
|
|
25
|
-
export const dbIndexConektaClients: string = "iConecktaClients"
|
|
26
|
-
export const dbIndexConektaClientsRef: string = "iConecktaClientsRef"
|
|
27
|
-
export const dbIndexPassportClientsRef: string = "iPassportClientsRef"
|
|
28
|
-
export const dbIndexNotification: string = "iNotification"
|
|
29
|
-
export const dbIndexPayments: string = "iNotification"
|
|
30
|
-
|
|
31
|
-
export const dateFormat = "EEEE, dd MMM yyyy"
|
|
32
|
-
export const dateCompleteFormat = "EEEE, dd MMM yyyy hh:mm aaaa"
|
|
33
|
-
export const timeFormat = "hh:mm aaaa"
|
|
34
|
-
|
|
35
|
-
export const expiredPayment = "expiredPayment"
|
|
36
|
-
|
|
37
|
-
export const messagingTopic = "AdminTopic"
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import {oCatalog} from './oCatalog';
|
|
2
|
-
import {oScoreNoHit, oScoreReference} from './oScoreDto';
|
|
3
|
-
|
|
4
|
-
export interface oAssetCategory {
|
|
5
|
-
name: string
|
|
6
|
-
id: string
|
|
7
|
-
createAt: number
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export interface oAssetBrand{
|
|
11
|
-
name: string
|
|
12
|
-
id: string
|
|
13
|
-
description: string
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export interface oAssetOffer {
|
|
17
|
-
name: string
|
|
18
|
-
id: string
|
|
19
|
-
createAt: number
|
|
20
|
-
description: string
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export enum eAssetPeriod {
|
|
24
|
-
MONTH = "MONTH",
|
|
25
|
-
WEEK = "WEEK",
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export interface oPaymentOption {
|
|
29
|
-
deadline: number,
|
|
30
|
-
score: oScoreNoHit
|
|
31
|
-
period: eAssetPeriod,
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
export interface oAsset {
|
|
35
|
-
name: string
|
|
36
|
-
id: string
|
|
37
|
-
createAt: number
|
|
38
|
-
category: oAssetCategory
|
|
39
|
-
brand: oAssetBrand
|
|
40
|
-
price: number
|
|
41
|
-
model: string
|
|
42
|
-
imageUrl: string []
|
|
43
|
-
paymentOption: oPaymentOption[]
|
|
44
|
-
catalog: oCatalog
|
|
45
|
-
offers: oAssetOffer[]
|
|
46
|
-
score: oScoreReference
|
|
47
|
-
IMEI: string
|
|
48
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import {oClient} from '../../v1/objects/oClient';
|
|
2
|
-
import {eVerificationStep} from '../../v1/objects/oVerification';
|
|
3
|
-
import { eIdentityTypes } from "../../v1/util/UtilClient";
|
|
4
|
-
import { oMediaIdentity } from "./oMediaDto";
|
|
5
|
-
import {oScore, oScoreNoHit} from './oScoreDto';
|
|
6
|
-
|
|
7
|
-
export interface oClientPayments {
|
|
8
|
-
date: number;
|
|
9
|
-
dayPayment: number;
|
|
10
|
-
amount: number;
|
|
11
|
-
id: string;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
export interface oUserReference {
|
|
15
|
-
name: string,
|
|
16
|
-
phone: string,
|
|
17
|
-
relationship: string
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export interface oClientReferences {
|
|
21
|
-
date?: number;
|
|
22
|
-
amount?: number;
|
|
23
|
-
id: string;
|
|
24
|
-
url?: string;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export interface oClientV2 extends oClient {
|
|
28
|
-
score: oScore,
|
|
29
|
-
seller_id?: string
|
|
30
|
-
scoreNoHit?: oScoreNoHit,
|
|
31
|
-
study_degree?: string,
|
|
32
|
-
mediaSelfie?: oMediaIdentity,
|
|
33
|
-
mediaAddress?: oMediaIdentity,
|
|
34
|
-
mediaWithDevice?: oMediaIdentity,
|
|
35
|
-
mediaSelfieBack?: oMediaIdentity,
|
|
36
|
-
identityVerification?: eVerificationStep
|
|
37
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import {oContract} from '../../v1/objects/oContract';
|
|
2
|
-
import {oCompany} from './oCompany';
|
|
3
|
-
import {oAsset} from './oAsset';
|
|
4
|
-
import {eContractStatus} from '../../v1/util/UtilContract';
|
|
5
|
-
|
|
6
|
-
export interface oContractV2 extends oContract {
|
|
7
|
-
company: oCompany
|
|
8
|
-
status: eContractStatus
|
|
9
|
-
asset: oAsset // new entity to represent a user device
|
|
10
|
-
}
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export interface oScoreAddress {
|
|
4
|
-
CP: string,
|
|
5
|
-
ciudad: string,
|
|
6
|
-
estado: string,
|
|
7
|
-
domicilio: string,
|
|
8
|
-
coloniaPoblacion: string,
|
|
9
|
-
delegacionMunicipio: string
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export interface oScoreHit {
|
|
13
|
-
valor: string
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
export interface oScoreNoHit {
|
|
17
|
-
date: string,
|
|
18
|
-
score: string,
|
|
19
|
-
message: string,
|
|
20
|
-
evaluation: string
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export interface oScoreGeneral {
|
|
24
|
-
nombres: string,
|
|
25
|
-
apellidoMaterno: string,
|
|
26
|
-
apellidoPaterno: string,
|
|
27
|
-
fechaNacimiento: string
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export interface oScore {
|
|
31
|
-
domicilio: oScoreAddress,
|
|
32
|
-
scoreNoHit: oScoreHit,
|
|
33
|
-
folioConsulta: string,
|
|
34
|
-
datosGenerales: oScoreGeneral
|
|
35
|
-
}
|
|
36
|
-
//TODO: Add pending data, those params will comes from "Circulo de credito" API
|
|
37
|
-
export interface oScoreReference {
|
|
38
|
-
name: string,
|
|
39
|
-
score: number
|
|
40
|
-
}
|
package/src/public-api.ts
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Public API Surface of ravcredit-lib
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
export * from './lib/ravcredit-lib.service';
|
|
6
|
-
export * from './lib/ravcredit-lib.component';
|
|
7
|
-
export * from './lib/v1/objects/oAddress';
|
|
8
|
-
export * from './lib/v1/objects/oBusiness';
|
|
9
|
-
export * from './lib/v1/objects/oClient';
|
|
10
|
-
export * from './lib/v1/objects/oConekta';
|
|
11
|
-
export * from './lib/v1/objects/oContract';
|
|
12
|
-
export * from './lib/v1/objects/oContractAll';
|
|
13
|
-
export * from './lib/v1/objects/oCustomer';
|
|
14
|
-
export * from './lib/v1/objects/oDevice';
|
|
15
|
-
export * from './lib/v1/objects/oFinancial';
|
|
16
|
-
export * from './lib/v1/objects/oGlobal';
|
|
17
|
-
export * from './lib/v1/objects/oLogIn';
|
|
18
|
-
export * from './lib/v1/objects/oNewPayment';
|
|
19
|
-
export * from './lib/v1/objects/oNotification';
|
|
20
|
-
export * from './lib/v1/objects/oPassport';
|
|
21
|
-
export * from './lib/v1/objects/oUser';
|
|
22
|
-
export * from './lib/v1/objects/oVerification';
|
|
23
|
-
|
|
24
|
-
export * from './lib/v1/util/UtilClient';
|
|
25
|
-
export * from './lib/v1/util/UtilsHttp'
|
|
26
|
-
export * from './lib/v1/util/UtilBusiness';
|
|
27
|
-
export * from './lib/v1/util/UtilDynamiCore';
|
|
28
|
-
export * from './lib/v1/util/UtilContract';
|
|
29
|
-
export * from './lib/v1/util/UtilConekta';
|
|
30
|
-
export * from './lib/v1/util/UtilNotification';
|
|
31
|
-
export * from './lib/v1/util/UtilTime';
|
|
32
|
-
export * from './lib/v1/util/UtilDashboard';
|
|
33
|
-
export * from './lib/v1/util/UtilPassport';
|
|
34
|
-
export * from './lib/v1/util/UtilPayment';
|
|
35
|
-
|
|
36
|
-
export * from './lib/v1/idb/indexed-db.service';
|
|
37
|
-
export * from './lib/v1/const/constants';
|
|
38
|
-
|
|
39
|
-
export * from './lib/v2/objects/oAws';
|
|
40
|
-
export * from './lib/v2/objects/oCatalog';
|
|
41
|
-
export * from './lib/v2/objects/oContract';
|
|
42
|
-
export * from './lib/v2/objects/oAsset';
|
|
43
|
-
export * from './lib/v2/objects/oCompany';
|
|
44
|
-
export * from './lib/v2/objects/oScoreDto';
|
|
45
|
-
export * from './lib/v2/objects/oMediaDto';
|
package/tsconfig.lib.json
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/* To learn more about Typescript configuration file: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html. */
|
|
2
|
-
/* To learn more about Angular compiler options: https://angular.dev/reference/configs/angular-compiler-options. */
|
|
3
|
-
{
|
|
4
|
-
"extends": "../../tsconfig.json",
|
|
5
|
-
"compilerOptions": {
|
|
6
|
-
"outDir": "../../out-tsc/lib",
|
|
7
|
-
"declaration": true,
|
|
8
|
-
"declarationMap": true,
|
|
9
|
-
"inlineSources": true,
|
|
10
|
-
"types": []
|
|
11
|
-
},
|
|
12
|
-
"exclude": [
|
|
13
|
-
"**/*.spec.ts"
|
|
14
|
-
]
|
|
15
|
-
}
|
package/tsconfig.lib.prod.json
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/* To learn more about Typescript configuration file: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html. */
|
|
2
|
-
/* To learn more about Angular compiler options: https://angular.dev/reference/configs/angular-compiler-options. */
|
|
3
|
-
{
|
|
4
|
-
"extends": "./tsconfig.lib.json",
|
|
5
|
-
"compilerOptions": {
|
|
6
|
-
"declarationMap": false
|
|
7
|
-
},
|
|
8
|
-
"angularCompilerOptions": {
|
|
9
|
-
"compilationMode": "partial"
|
|
10
|
-
}
|
|
11
|
-
}
|
package/tsconfig.spec.json
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/* To learn more about Typescript configuration file: https://www.typescriptlang.org/docs/handbook/tsconfig-json.html. */
|
|
2
|
-
/* To learn more about Angular compiler options: https://angular.dev/reference/configs/angular-compiler-options. */
|
|
3
|
-
{
|
|
4
|
-
"extends": "../../tsconfig.json",
|
|
5
|
-
"compilerOptions": {
|
|
6
|
-
"outDir": "../../out-tsc/spec",
|
|
7
|
-
"types": [
|
|
8
|
-
"jasmine"
|
|
9
|
-
]
|
|
10
|
-
},
|
|
11
|
-
"include": [
|
|
12
|
-
"**/*.spec.ts",
|
|
13
|
-
"**/*.d.ts"
|
|
14
|
-
]
|
|
15
|
-
}
|