@silexpert/core 1.0.90 → 1.0.91
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/es/api/resources/AccountingFiles.d.ts +2 -1
- package/es/api/resources/AccountingFiles.d.ts.map +1 -1
- package/es/api/resources/AccountingFiles.js +3 -0
- package/es/api/resources/AccountingFiles.js.map +1 -1
- package/es/api/resources/CommercialDocument.d.ts +7 -3
- package/es/api/resources/CommercialDocument.d.ts.map +1 -1
- package/es/api/resources/CommercialDocument.js +11 -4
- package/es/api/resources/CommercialDocument.js.map +1 -1
- package/es/api/resources/Employee.d.ts +2 -1
- package/es/api/resources/Employee.d.ts.map +1 -1
- package/es/api/resources/Employee.js +8 -4
- package/es/api/resources/Employee.js.map +1 -1
- package/es/api/resources/PaymentExpectationCustomer.d.ts +2 -1
- package/es/api/resources/PaymentExpectationCustomer.d.ts.map +1 -1
- package/es/api/resources/PaymentExpectationCustomer.js +2 -4
- package/es/api/resources/PaymentExpectationCustomer.js.map +1 -1
- package/es/api/resources/Product.d.ts +2 -1
- package/es/api/resources/Product.d.ts.map +1 -1
- package/es/api/resources/Product.js +2 -4
- package/es/api/resources/Product.js.map +1 -1
- package/es/api/resources/SheetMonthSchedule.d.ts +2 -1
- package/es/api/resources/SheetMonthSchedule.d.ts.map +1 -1
- package/es/api/resources/SheetMonthSchedule.js +2 -2
- package/es/api/resources/SheetMonthSchedule.js.map +1 -1
- package/es/api/resources/ThirdParty.d.ts +2 -1
- package/es/api/resources/ThirdParty.d.ts.map +1 -1
- package/es/api/resources/ThirdParty.js +2 -4
- package/es/api/resources/ThirdParty.js.map +1 -1
- package/es/types/Interface/api/accountingTransaction/QueryTransaction.d.ts +3 -0
- package/es/types/Interface/api/accountingTransaction/QueryTransaction.d.ts.map +1 -1
- package/es/types/Interface/api/accountingTransaction/QueryTransaction.js +7 -0
- package/es/types/Interface/api/accountingTransaction/QueryTransaction.js.map +1 -1
- package/es/types/Interface/api/commercialManagement/Create.d.ts +5 -0
- package/es/types/Interface/api/commercialManagement/Create.d.ts.map +1 -1
- package/es/types/Interface/api/commercialManagement/Create.js +17 -0
- package/es/types/Interface/api/commercialManagement/Create.js.map +1 -1
- package/js/api/resources/AccountingFiles.js +6 -0
- package/js/api/resources/AccountingFiles.js.map +1 -1
- package/js/api/resources/CommercialDocument.js +9 -3
- package/js/api/resources/CommercialDocument.js.map +1 -1
- package/js/api/resources/Employee.js +5 -3
- package/js/api/resources/Employee.js.map +1 -1
- package/js/api/resources/PaymentExpectationCustomer.js +5 -3
- package/js/api/resources/PaymentExpectationCustomer.js.map +1 -1
- package/js/api/resources/Product.js +5 -3
- package/js/api/resources/Product.js.map +1 -1
- package/js/api/resources/SheetMonthSchedule.js +5 -3
- package/js/api/resources/SheetMonthSchedule.js.map +1 -1
- package/js/api/resources/ThirdParty.js +5 -3
- package/js/api/resources/ThirdParty.js.map +1 -1
- package/js/types/Interface/api/accountingTransaction/QueryTransaction.js +9 -1
- package/js/types/Interface/api/accountingTransaction/QueryTransaction.js.map +1 -1
- package/js/types/Interface/api/commercialManagement/Create.js +11 -1
- package/js/types/Interface/api/commercialManagement/Create.js.map +1 -1
- package/package.json +1 -1
- package/ts/api/resources/AccountingFiles.ts +7 -1
- package/ts/api/resources/CommercialDocument.ts +63 -17
- package/ts/api/resources/Employee.ts +42 -10
- package/ts/api/resources/PaymentExpectationCustomer.ts +61 -18
- package/ts/api/resources/Product.ts +14 -3
- package/ts/api/resources/SheetMonthSchedule.ts +36 -9
- package/ts/api/resources/ThirdParty.ts +18 -4
- package/ts/types/Interface/api/accountingTransaction/QueryTransaction.ts +6 -0
- package/ts/types/Interface/api/commercialManagement/Create.ts +14 -0
|
@@ -1,8 +1,10 @@
|
|
|
1
|
+
import { CancelToken } from 'axios';
|
|
1
2
|
import { Resource } from '../Resource';
|
|
2
3
|
import {
|
|
3
4
|
BasePaginate,
|
|
4
5
|
CreateInvoiceDocument,
|
|
5
6
|
CreatePreSaleDocument,
|
|
7
|
+
CreateRegenerateDocument,
|
|
6
8
|
EstimateInvoiceType,
|
|
7
9
|
IEstimateInvoice,
|
|
8
10
|
QueryCountByStatus,
|
|
@@ -20,7 +22,7 @@ export class CommercialDocument extends Resource {
|
|
|
20
22
|
return this.axios.$get(`/commercial-management/documents/${id}`);
|
|
21
23
|
}
|
|
22
24
|
|
|
23
|
-
update(id: number, payload: UpdateCommercialDocument): Promise<IEstimateInvoice> {
|
|
25
|
+
update(id: number, payload: UpdateCommercialDocument): Promise<{ data: IEstimateInvoice }> {
|
|
24
26
|
return this.axios.patch(`/commercial-management/documents/${id}`, payload);
|
|
25
27
|
}
|
|
26
28
|
|
|
@@ -29,42 +31,86 @@ export class CommercialDocument extends Resource {
|
|
|
29
31
|
}
|
|
30
32
|
|
|
31
33
|
getNextReference(params: QueryNextReference): Promise<string> {
|
|
32
|
-
return this.axios.$get('/commercial-management/documents/references', {
|
|
34
|
+
return this.axios.$get('/commercial-management/documents/references', {
|
|
35
|
+
params,
|
|
36
|
+
});
|
|
33
37
|
}
|
|
34
38
|
|
|
35
|
-
getPaginated(
|
|
36
|
-
|
|
39
|
+
getPaginated(
|
|
40
|
+
params: QueryDocumentPaginated & QueryPaginate,
|
|
41
|
+
cancelToken?: CancelToken,
|
|
42
|
+
): Promise<BasePaginate<ReadEstimateInvoice>> {
|
|
43
|
+
return this.axios.$get('/commercial-management/documents', {
|
|
44
|
+
...(cancelToken ? { cancelToken } : {}),
|
|
45
|
+
params,
|
|
46
|
+
});
|
|
37
47
|
}
|
|
38
48
|
|
|
39
|
-
createEstimate(
|
|
40
|
-
|
|
49
|
+
createEstimate(
|
|
50
|
+
payload: Omit<CreatePreSaleDocument, 'idEstimateInvoiceType'>,
|
|
51
|
+
): Promise<IEstimateInvoice> {
|
|
52
|
+
return this.axios.$post('/commercial-management/estimates', {
|
|
53
|
+
...payload,
|
|
54
|
+
idEstimateInvoiceType: EstimateInvoiceType.DEVIS,
|
|
55
|
+
});
|
|
41
56
|
}
|
|
42
57
|
|
|
43
|
-
createOrder(
|
|
44
|
-
|
|
58
|
+
createOrder(
|
|
59
|
+
payload: Omit<CreatePreSaleDocument, 'idEstimateInvoiceType'>,
|
|
60
|
+
): Promise<IEstimateInvoice> {
|
|
61
|
+
return this.axios.$post('/commercial-management/orders', {
|
|
62
|
+
...payload,
|
|
63
|
+
idEstimateInvoiceType: EstimateInvoiceType.BON,
|
|
64
|
+
});
|
|
45
65
|
}
|
|
46
66
|
|
|
47
|
-
updateEstimate(
|
|
67
|
+
updateEstimate(
|
|
68
|
+
id: number,
|
|
69
|
+
payload: CreatePreSaleDocument,
|
|
70
|
+
): Promise<IEstimateInvoice> {
|
|
48
71
|
return this.axios.$put(`/commercial-management/estimates/${id}`, payload);
|
|
49
72
|
}
|
|
50
73
|
|
|
51
|
-
updateOrder(
|
|
74
|
+
updateOrder(
|
|
75
|
+
id: number,
|
|
76
|
+
payload: CreatePreSaleDocument,
|
|
77
|
+
): Promise<IEstimateInvoice> {
|
|
52
78
|
return this.axios.$put(`/commercial-management/orders/${id}`, payload);
|
|
53
79
|
}
|
|
54
80
|
|
|
55
|
-
preview(
|
|
56
|
-
|
|
81
|
+
preview(
|
|
82
|
+
idEstimateInvoiceType: EstimateInvoiceType,
|
|
83
|
+
payload: CreatePreSaleDocument | CreateInvoiceDocument,
|
|
84
|
+
): Promise<ReadPreview> {
|
|
85
|
+
return this.axios.$post('/commercial-management/preview', {
|
|
86
|
+
...payload,
|
|
87
|
+
idEstimateInvoiceType,
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
regenerate(id: number, payload: CreateRegenerateDocument): Promise<IEstimateInvoice> {
|
|
92
|
+
return this.axios.$post(`/commercial-management/documents/${id}/regenerate`, payload);
|
|
57
93
|
}
|
|
58
94
|
|
|
59
95
|
getFormValues(id: number): Promise<CreatePreSaleDocument> {
|
|
60
96
|
return this.axios.$get(`/commercial-management/documents/${id}/inputs`);
|
|
61
97
|
}
|
|
62
98
|
|
|
63
|
-
getDefaultFormValues(
|
|
64
|
-
|
|
99
|
+
getDefaultFormValues(
|
|
100
|
+
idEstimateInvoiceType: EstimateInvoiceType,
|
|
101
|
+
): Promise<CreatePreSaleDocument> {
|
|
102
|
+
return this.axios.$get('/commercial-management/documents/inputs', {
|
|
103
|
+
params: { idEstimateInvoiceType },
|
|
104
|
+
});
|
|
65
105
|
}
|
|
66
106
|
|
|
67
|
-
getStatistics(
|
|
68
|
-
|
|
107
|
+
getStatistics(
|
|
108
|
+
idSociety: number,
|
|
109
|
+
params: QueryCountByStatus,
|
|
110
|
+
): Promise<ReadCountDocumentByStatus> {
|
|
111
|
+
return this.axios.$get(
|
|
112
|
+
`/commercial-management/societies/${idSociety}/statistics`,
|
|
113
|
+
{ params },
|
|
114
|
+
);
|
|
69
115
|
}
|
|
70
|
-
}
|
|
116
|
+
}
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
+
import { CancelToken } from 'axios';
|
|
1
2
|
import { forEach } from 'lodash';
|
|
2
3
|
import {
|
|
3
|
-
BasePaginate,
|
|
4
|
+
BasePaginate,
|
|
5
|
+
IEmployee,
|
|
6
|
+
IWorkingSchedule,
|
|
7
|
+
CreateEmployee,
|
|
8
|
+
QueryEmployeeSearch,
|
|
9
|
+
UpdateEmployee,
|
|
10
|
+
UpdateOrCreateWorkingSchedule,
|
|
4
11
|
} from '../../types';
|
|
5
12
|
import { Resource } from '../Resource';
|
|
6
13
|
|
|
@@ -16,7 +23,9 @@ export class Employee extends Resource {
|
|
|
16
23
|
}
|
|
17
24
|
}
|
|
18
25
|
});
|
|
19
|
-
return this.axios.$post('/employees', formData, {
|
|
26
|
+
return this.axios.$post('/employees', formData, {
|
|
27
|
+
headers: { 'Content-Type': 'multipart/form-data' },
|
|
28
|
+
});
|
|
20
29
|
}
|
|
21
30
|
|
|
22
31
|
public getAll(idSociety: number): Promise<IEmployee[]> {
|
|
@@ -27,7 +36,10 @@ export class Employee extends Resource {
|
|
|
27
36
|
return this.axios.$get(`/employees/${id}`);
|
|
28
37
|
}
|
|
29
38
|
|
|
30
|
-
public update(
|
|
39
|
+
public update(
|
|
40
|
+
id: number,
|
|
41
|
+
payload: Partial<UpdateEmployee>,
|
|
42
|
+
): Promise<IEmployee> {
|
|
31
43
|
const formData = new FormData();
|
|
32
44
|
forEach(payload, (value, key) => {
|
|
33
45
|
if (value) {
|
|
@@ -38,22 +50,42 @@ export class Employee extends Resource {
|
|
|
38
50
|
}
|
|
39
51
|
}
|
|
40
52
|
});
|
|
41
|
-
return this.axios.$put(`/employees/${id}`, formData, {
|
|
53
|
+
return this.axios.$put(`/employees/${id}`, formData, {
|
|
54
|
+
headers: { 'Content-Type': 'multipart/form-data' },
|
|
55
|
+
});
|
|
42
56
|
}
|
|
43
57
|
|
|
44
58
|
public delete(id: number): Promise<true> {
|
|
45
59
|
return this.axios.$delete(`/employees/${id}`);
|
|
46
60
|
}
|
|
47
61
|
|
|
48
|
-
public getPaginate(
|
|
49
|
-
|
|
62
|
+
public getPaginate(
|
|
63
|
+
idSociety: number,
|
|
64
|
+
params?: QueryEmployeeSearch,
|
|
65
|
+
cancelToken?: CancelToken,
|
|
66
|
+
): Promise<BasePaginate<Employee>> {
|
|
67
|
+
return this.axios.$get(`/societies/${idSociety}/employees`, {
|
|
68
|
+
...(cancelToken ? { cancelToken } : {}),
|
|
69
|
+
params: { ...params, isPaginate: true },
|
|
70
|
+
});
|
|
50
71
|
}
|
|
51
72
|
|
|
52
|
-
public updateOrCreateWorkingSchedule(
|
|
53
|
-
|
|
73
|
+
public updateOrCreateWorkingSchedule(
|
|
74
|
+
idEmployee: number,
|
|
75
|
+
payload?: UpdateOrCreateWorkingSchedule,
|
|
76
|
+
): Promise<IWorkingSchedule> {
|
|
77
|
+
return this.axios.$post(
|
|
78
|
+
`employees/${idEmployee}/working-schedules`,
|
|
79
|
+
payload,
|
|
80
|
+
);
|
|
54
81
|
}
|
|
55
82
|
|
|
56
|
-
public deleteWorkingSchedule(
|
|
57
|
-
|
|
83
|
+
public deleteWorkingSchedule(
|
|
84
|
+
idEmployee: number,
|
|
85
|
+
idWorkingSchedule: number,
|
|
86
|
+
): Promise<true> {
|
|
87
|
+
return this.axios.$delete(
|
|
88
|
+
`employees/${idEmployee}/working-schedules/${idWorkingSchedule}`,
|
|
89
|
+
);
|
|
58
90
|
}
|
|
59
91
|
}
|
|
@@ -1,35 +1,78 @@
|
|
|
1
|
+
import { CancelToken } from 'axios';
|
|
1
2
|
import { Resource } from '../Resource';
|
|
2
3
|
import {
|
|
3
|
-
QueryGetPaymentExpectationCustomer,
|
|
4
|
+
QueryGetPaymentExpectationCustomer,
|
|
5
|
+
IPaymentExpectationCustomer,
|
|
6
|
+
QueryPayPaymentExpectationCustomer,
|
|
7
|
+
QueryConfirmPaymentExpectationCustomer,
|
|
8
|
+
QueryGetSocietyPaymentsExpectationsCustomers,
|
|
9
|
+
QueryDeleteSocietyPaymentExpectationCustomer,
|
|
10
|
+
BasePaginate,
|
|
11
|
+
UpdateRefundSocietyPaymentExpectationCustomer,
|
|
12
|
+
CreateSocietyPaymentExpectationCustomer,
|
|
13
|
+
ReadPaymentExpectationCustomerStat,
|
|
14
|
+
QueryGetSocietyPaymentsExpectationsCustomersStats,
|
|
4
15
|
} from '../../types';
|
|
5
16
|
|
|
6
17
|
export class PaymentExpectationCustomer extends Resource {
|
|
7
|
-
get(
|
|
18
|
+
get(
|
|
19
|
+
params: QueryGetPaymentExpectationCustomer,
|
|
20
|
+
): Promise<IPaymentExpectationCustomer> {
|
|
8
21
|
return this.axios.$get('/paymentExpectationCustomer', { params });
|
|
9
22
|
}
|
|
10
|
-
getBySociety(
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
23
|
+
getBySociety(
|
|
24
|
+
params: QueryGetSocietyPaymentsExpectationsCustomers,
|
|
25
|
+
cancelToken?: CancelToken,
|
|
26
|
+
): Promise<BasePaginate<IPaymentExpectationCustomer>> {
|
|
27
|
+
return this.axios.$get(
|
|
28
|
+
`/society/${params.idSociety}/paymentsExpectationsCustomers`,
|
|
29
|
+
{
|
|
30
|
+
...(cancelToken ? { cancelToken } : {}),
|
|
31
|
+
params,
|
|
32
|
+
},
|
|
33
|
+
);
|
|
14
34
|
}
|
|
15
|
-
stats(
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
35
|
+
stats(
|
|
36
|
+
params: QueryGetSocietyPaymentsExpectationsCustomersStats,
|
|
37
|
+
): Promise<ReadPaymentExpectationCustomerStat> {
|
|
38
|
+
return this.axios.$get(
|
|
39
|
+
`/society/${params.idSociety}/paymentsExpectationsCustomers/stats`,
|
|
40
|
+
{
|
|
41
|
+
params,
|
|
42
|
+
},
|
|
43
|
+
);
|
|
19
44
|
}
|
|
20
|
-
pay(
|
|
45
|
+
pay(
|
|
46
|
+
params: QueryPayPaymentExpectationCustomer,
|
|
47
|
+
): Promise<IPaymentExpectationCustomer> {
|
|
21
48
|
return this.axios.$post('/paymentExpectationCustomer/pay', params);
|
|
22
49
|
}
|
|
23
|
-
confirm(
|
|
50
|
+
confirm(
|
|
51
|
+
params: QueryConfirmPaymentExpectationCustomer,
|
|
52
|
+
): Promise<IPaymentExpectationCustomer> {
|
|
24
53
|
return this.axios.$post('/paymentExpectationCustomer/confirm', params);
|
|
25
54
|
}
|
|
26
|
-
delete(
|
|
27
|
-
|
|
55
|
+
delete(
|
|
56
|
+
params: QueryDeleteSocietyPaymentExpectationCustomer,
|
|
57
|
+
): Promise<IPaymentExpectationCustomer> {
|
|
58
|
+
return this.axios.$delete(
|
|
59
|
+
`/society/${params.idSociety}/paymentsExpectationsCustomers/${params.id}`,
|
|
60
|
+
);
|
|
28
61
|
}
|
|
29
|
-
refund(
|
|
30
|
-
|
|
62
|
+
refund(
|
|
63
|
+
params: UpdateRefundSocietyPaymentExpectationCustomer,
|
|
64
|
+
): Promise<IPaymentExpectationCustomer> {
|
|
65
|
+
return this.axios.$put(
|
|
66
|
+
`/society/${params.idSociety}/paymentsExpectationsCustomers/${params.id}/refund`,
|
|
67
|
+
params,
|
|
68
|
+
);
|
|
31
69
|
}
|
|
32
|
-
create(
|
|
33
|
-
|
|
70
|
+
create(
|
|
71
|
+
params: CreateSocietyPaymentExpectationCustomer,
|
|
72
|
+
): Promise<IPaymentExpectationCustomer> {
|
|
73
|
+
return this.axios.$post(
|
|
74
|
+
`/society/${params.idSociety}/paymentExpectationCustomer`,
|
|
75
|
+
params,
|
|
76
|
+
);
|
|
34
77
|
}
|
|
35
78
|
}
|
|
@@ -1,6 +1,12 @@
|
|
|
1
|
+
import { CancelToken } from 'axios';
|
|
1
2
|
import { Resource } from '../Resource';
|
|
2
3
|
import {
|
|
3
|
-
IProduct,
|
|
4
|
+
IProduct,
|
|
5
|
+
QueryPaginate,
|
|
6
|
+
QueryProduct,
|
|
7
|
+
BasePaginate,
|
|
8
|
+
CreateProduct,
|
|
9
|
+
UpdateProduct,
|
|
4
10
|
} from '../../types';
|
|
5
11
|
|
|
6
12
|
export class Product extends Resource {
|
|
@@ -8,8 +14,13 @@ export class Product extends Resource {
|
|
|
8
14
|
return this.axios.$get('/commercial-management/products');
|
|
9
15
|
}
|
|
10
16
|
|
|
11
|
-
getPaginated(
|
|
17
|
+
getPaginated(
|
|
18
|
+
pagination: QueryPaginate,
|
|
19
|
+
query?: QueryProduct,
|
|
20
|
+
cancelToken?: CancelToken,
|
|
21
|
+
): Promise<BasePaginate<IProduct>> {
|
|
12
22
|
return this.axios.$get('/commercial-management/products', {
|
|
23
|
+
...(cancelToken ? { cancelToken } : {}),
|
|
13
24
|
params: {
|
|
14
25
|
...pagination,
|
|
15
26
|
...query,
|
|
@@ -40,4 +51,4 @@ export class Product extends Resource {
|
|
|
40
51
|
responseType: 'arraybuffer',
|
|
41
52
|
});
|
|
42
53
|
}
|
|
43
|
-
}
|
|
54
|
+
}
|
|
@@ -1,10 +1,17 @@
|
|
|
1
|
+
import { CancelToken } from 'axios';
|
|
1
2
|
import {
|
|
2
|
-
BasePaginate,
|
|
3
|
+
BasePaginate,
|
|
4
|
+
ISheetMonthSchedule,
|
|
5
|
+
ISheetMonthScheduleDetail,
|
|
6
|
+
QuerySheetMonthSchedule,
|
|
3
7
|
} from '../../types';
|
|
4
8
|
import { Resource } from '../Resource';
|
|
5
9
|
|
|
6
10
|
export class SheetMonthSchedule extends Resource {
|
|
7
|
-
public create(
|
|
11
|
+
public create(
|
|
12
|
+
idEmployee: number,
|
|
13
|
+
payload: Omit<ISheetMonthSchedule, 'idEmployee' | 'employee'>,
|
|
14
|
+
): Promise<ISheetMonthSchedule> {
|
|
8
15
|
return this.axios.$post(`/sheet-month-schedules/${idEmployee}`, payload);
|
|
9
16
|
}
|
|
10
17
|
|
|
@@ -16,7 +23,10 @@ export class SheetMonthSchedule extends Resource {
|
|
|
16
23
|
return this.axios.$get(`/sheet-month-schedules/${id}`);
|
|
17
24
|
}
|
|
18
25
|
|
|
19
|
-
public update(
|
|
26
|
+
public update(
|
|
27
|
+
id: number,
|
|
28
|
+
payload: Partial<ISheetMonthSchedule>,
|
|
29
|
+
): Promise<ISheetMonthSchedule> {
|
|
20
30
|
return this.axios.$put(`/sheet-month-schedules/${id}`, payload);
|
|
21
31
|
}
|
|
22
32
|
|
|
@@ -24,15 +34,32 @@ export class SheetMonthSchedule extends Resource {
|
|
|
24
34
|
return this.axios.$delete(`/sheet-month-schedules/${id}`);
|
|
25
35
|
}
|
|
26
36
|
|
|
27
|
-
public getPaginate(
|
|
28
|
-
|
|
37
|
+
public getPaginate(
|
|
38
|
+
params: QuerySheetMonthSchedule,
|
|
39
|
+
cancelToken?: CancelToken,
|
|
40
|
+
): Promise<BasePaginate<SheetMonthSchedule>> {
|
|
41
|
+
return this.axios.$get('/sheet-month-schedules', {
|
|
42
|
+
...(cancelToken ? { cancelToken } : {}),
|
|
43
|
+
params,
|
|
44
|
+
});
|
|
29
45
|
}
|
|
30
46
|
|
|
31
|
-
public updateOrCreateSheetMonthScheduleDetail(
|
|
32
|
-
|
|
47
|
+
public updateOrCreateSheetMonthScheduleDetail(
|
|
48
|
+
idSheetMonthSchedule: number,
|
|
49
|
+
payload: Partial<Omit<ISheetMonthScheduleDetail, 'idSheetMonthSchedule'>>,
|
|
50
|
+
): Promise<ISheetMonthScheduleDetail> {
|
|
51
|
+
return this.axios.$post(
|
|
52
|
+
`/sheet-month-schedules/${idSheetMonthSchedule}/details`,
|
|
53
|
+
payload,
|
|
54
|
+
);
|
|
33
55
|
}
|
|
34
56
|
|
|
35
|
-
public deleteSheetMonthScheduleDetail(
|
|
36
|
-
|
|
57
|
+
public deleteSheetMonthScheduleDetail(
|
|
58
|
+
idSheetMonthSchedule: number,
|
|
59
|
+
idSheetMonthScheduleDetails: number,
|
|
60
|
+
): Promise<true> {
|
|
61
|
+
return this.axios.$delete(
|
|
62
|
+
`/sheet-month-schedules/${idSheetMonthSchedule}/details/${idSheetMonthScheduleDetails}`,
|
|
63
|
+
);
|
|
37
64
|
}
|
|
38
65
|
}
|
|
@@ -1,6 +1,12 @@
|
|
|
1
|
+
import { CancelToken } from 'axios';
|
|
1
2
|
import { Resource } from '../Resource';
|
|
2
3
|
import {
|
|
3
|
-
QueryPaginate,
|
|
4
|
+
QueryPaginate,
|
|
5
|
+
BasePaginate,
|
|
6
|
+
IThirdParty,
|
|
7
|
+
QueryThirdParty,
|
|
8
|
+
UpdateThirdPartyForm,
|
|
9
|
+
CreateThirdPartyForm,
|
|
4
10
|
} from '../../types';
|
|
5
11
|
|
|
6
12
|
export class ThirdParty extends Resource {
|
|
@@ -8,8 +14,13 @@ export class ThirdParty extends Resource {
|
|
|
8
14
|
return this.axios.$get('/third-parties');
|
|
9
15
|
}
|
|
10
16
|
|
|
11
|
-
getPaginated(
|
|
17
|
+
getPaginated(
|
|
18
|
+
pagination: QueryPaginate,
|
|
19
|
+
query?: QueryThirdParty,
|
|
20
|
+
cancelToken?: CancelToken,
|
|
21
|
+
): Promise<BasePaginate<IThirdParty>> {
|
|
12
22
|
return this.axios.$get('/third-parties/paginate', {
|
|
23
|
+
...(cancelToken ? { cancelToken } : {}),
|
|
13
24
|
params: {
|
|
14
25
|
...pagination,
|
|
15
26
|
...query,
|
|
@@ -17,7 +28,10 @@ export class ThirdParty extends Resource {
|
|
|
17
28
|
});
|
|
18
29
|
}
|
|
19
30
|
|
|
20
|
-
update(
|
|
31
|
+
update(
|
|
32
|
+
idThirdParty: number,
|
|
33
|
+
payload: UpdateThirdPartyForm,
|
|
34
|
+
): Promise<IThirdParty> {
|
|
21
35
|
return this.axios.$put(`/third-parties/${idThirdParty}`, payload);
|
|
22
36
|
}
|
|
23
37
|
|
|
@@ -28,4 +42,4 @@ export class ThirdParty extends Resource {
|
|
|
28
42
|
delete(idThirdParty: number): Promise<true> {
|
|
29
43
|
return this.axios.$delete(`/third-parties/${idThirdParty}`);
|
|
30
44
|
}
|
|
31
|
-
}
|
|
45
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Type } from 'class-transformer';
|
|
1
2
|
import { ApiProperty, ApiPropertyOptional } from '../../../../utils';
|
|
2
3
|
import { TypeCustomerProviderOperation } from '../../../Enum/TypeCustomerProviderOperation';
|
|
3
4
|
|
|
@@ -58,3 +59,8 @@ export class QueryGetAllTransactions {
|
|
|
58
59
|
@ApiPropertyOptional()
|
|
59
60
|
dateValue?: string;
|
|
60
61
|
}
|
|
62
|
+
|
|
63
|
+
export class _QueryTransaction extends QueryTransaction {
|
|
64
|
+
@Type(() => Number)
|
|
65
|
+
idTypeAccountingFile: number;
|
|
66
|
+
}
|
|
@@ -435,4 +435,18 @@ export class CreateRecurrence {
|
|
|
435
435
|
@ToBoolean()
|
|
436
436
|
@IsBoolean()
|
|
437
437
|
isActive: boolean;
|
|
438
|
+
}
|
|
439
|
+
|
|
440
|
+
export class CreateRegenerateDocument {
|
|
441
|
+
@ApiProperty()
|
|
442
|
+
@IsString()
|
|
443
|
+
label: string;
|
|
444
|
+
|
|
445
|
+
@ApiProperty()
|
|
446
|
+
@IsString()
|
|
447
|
+
reference: string;
|
|
448
|
+
|
|
449
|
+
@ApiProperty()
|
|
450
|
+
@IsString()
|
|
451
|
+
title: string;
|
|
438
452
|
}
|