@silexpert/core 0.4.232 → 0.4.234

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.
Files changed (34) hide show
  1. package/es/api/resources/ThirdParty.d.ts +4 -1
  2. package/es/api/resources/ThirdParty.d.ts.map +1 -1
  3. package/es/api/resources/ThirdParty.js +9 -0
  4. package/es/api/resources/ThirdParty.js.map +1 -1
  5. package/es/api/resources/TimeRecorder.d.ts +2 -1
  6. package/es/api/resources/TimeRecorder.d.ts.map +1 -1
  7. package/es/api/resources/TimeRecorder.js +3 -0
  8. package/es/api/resources/TimeRecorder.js.map +1 -1
  9. package/es/types/Interface/api/calendarEvent/getAllCalendarEvent.d.ts +1 -0
  10. package/es/types/Interface/api/calendarEvent/getAllCalendarEvent.d.ts.map +1 -1
  11. package/es/types/Interface/api/calendarEvent/getAllCalendarEvent.js +4 -0
  12. package/es/types/Interface/api/calendarEvent/getAllCalendarEvent.js.map +1 -1
  13. package/es/types/Interface/api/calendarEvent/readAllCalendarEvent.d.ts +2 -1
  14. package/es/types/Interface/api/calendarEvent/readAllCalendarEvent.d.ts.map +1 -1
  15. package/es/types/Interface/api/calendarEvent/readAllCalendarEvent.js.map +1 -1
  16. package/es/types/Interface/api/timeRecorder/ReadAttendanceHours.d.ts +2 -1
  17. package/es/types/Interface/api/timeRecorder/ReadAttendanceHours.d.ts.map +1 -1
  18. package/es/types/Interface/api/timeRecorder/ReadAttendanceHours.js.map +1 -1
  19. package/es/types/Interface/enum/Date.d.ts +2 -2
  20. package/es/types/Interface/enum/Date.d.ts.map +1 -1
  21. package/es/types/Interface/enum/Date.js.map +1 -1
  22. package/js/api/resources/ThirdParty.js +12 -0
  23. package/js/api/resources/ThirdParty.js.map +1 -1
  24. package/js/api/resources/TimeRecorder.js +4 -0
  25. package/js/api/resources/TimeRecorder.js.map +1 -1
  26. package/js/types/Interface/api/calendarEvent/getAllCalendarEvent.js +4 -0
  27. package/js/types/Interface/api/calendarEvent/getAllCalendarEvent.js.map +1 -1
  28. package/package.json +1 -1
  29. package/ts/api/resources/ThirdParty.ts +13 -1
  30. package/ts/api/resources/TimeRecorder.ts +4 -1
  31. package/ts/types/Interface/api/calendarEvent/getAllCalendarEvent.ts +3 -0
  32. package/ts/types/Interface/api/calendarEvent/readAllCalendarEvent.ts +2 -1
  33. package/ts/types/Interface/api/timeRecorder/ReadAttendanceHours.ts +3 -1
  34. package/ts/types/Interface/enum/Date.ts +2 -2
@@ -1,7 +1,10 @@
1
1
  import { Resource } from '../Resource';
2
- import { QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty } from '../../types';
2
+ import { QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty, UpdateThirdPartyForm, CreateThirdPartyForm } from '../../types';
3
3
  export declare class ThirdParty extends Resource {
4
4
  getAll(): Promise<Array<IThirdParty>>;
5
5
  getPaginated(pagination: QueryPaginate, query?: QueryThirdParty): Promise<BasePaginate<IThirdParty>>;
6
+ update(idThirdParty: number, payload: UpdateThirdPartyForm): Promise<IThirdParty>;
7
+ create(payload: CreateThirdPartyForm): Promise<IThirdParty>;
8
+ delete(idThirdParty: number): Promise<true>;
6
9
  }
7
10
  //# sourceMappingURL=ThirdParty.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ThirdParty.d.ts","sourceRoot":"","sources":["../../../ts/api/resources/ThirdParty.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EACL,aAAa,EAAE,YAAY,EAAE,WAAW,EAAE,eAAe,EAC1D,MAAM,aAAa,CAAC;AAErB,qBAAa,UAAW,SAAQ,QAAQ;IACtC,MAAM,IAAI,OAAO,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;IAIrC,YAAY,CAAC,UAAU,EAAE,aAAa,EAAE,KAAK,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,YAAY,CAAC,WAAW,CAAC,CAAC;CAQrG"}
1
+ {"version":3,"file":"ThirdParty.d.ts","sourceRoot":"","sources":["../../../ts/api/resources/ThirdParty.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EACL,aAAa,EAAE,YAAY,EAAE,WAAW,EAAE,eAAe,EAAE,oBAAoB,EAAE,oBAAoB,EACtG,MAAM,aAAa,CAAC;AAErB,qBAAa,UAAW,SAAQ,QAAQ;IACtC,MAAM,IAAI,OAAO,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;IAIrC,YAAY,CAAC,UAAU,EAAE,aAAa,EAAE,KAAK,CAAC,EAAE,eAAe,GAAG,OAAO,CAAC,YAAY,CAAC,WAAW,CAAC,CAAC;IASpG,MAAM,CAAC,YAAY,EAAE,MAAM,EAAE,OAAO,EAAE,oBAAoB,GAAG,OAAO,CAAC,WAAW,CAAC;IAIjF,MAAM,CAAC,OAAO,EAAE,oBAAoB,GAAG,OAAO,CAAC,WAAW,CAAC;IAI3D,MAAM,CAAC,YAAY,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAG5C"}
@@ -8,5 +8,14 @@ export class ThirdParty extends Resource {
8
8
  params: Object.assign(Object.assign({}, pagination), query),
9
9
  });
10
10
  }
11
+ update(idThirdParty, payload) {
12
+ return this.axios.$put(`/third-parties/${idThirdParty}`, payload);
13
+ }
14
+ create(payload) {
15
+ return this.axios.$post('/third-parties', payload);
16
+ }
17
+ delete(idThirdParty) {
18
+ return this.axios.$delete(`/third-parties/${idThirdParty}`);
19
+ }
11
20
  }
12
21
  //# sourceMappingURL=ThirdParty.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ThirdParty.js","sourceRoot":"","sources":["../../../ts/api/resources/ThirdParty.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAKvC,MAAM,OAAO,UAAW,SAAQ,QAAQ;IACtC,MAAM;QACJ,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;IAC3C,CAAC;IAED,YAAY,CAAC,UAAyB,EAAE,KAAuB;QAC7D,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,gBAAgB,EAAE;YACvC,MAAM,kCACD,UAAU,GACV,KAAK,CACT;SACF,CAAC,CAAC;IACL,CAAC;CACF","sourcesContent":["import { Resource } from '../Resource';\nimport {\n QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty,\n} from '../../types';\n\nexport class ThirdParty extends Resource {\n getAll(): Promise<Array<IThirdParty>> {\n return this.axios.$get('/third-parties');\n }\n\n getPaginated(pagination: QueryPaginate, query?: QueryThirdParty): Promise<BasePaginate<IThirdParty>> {\n return this.axios.$get('/third-parties', {\n params: {\n ...pagination,\n ...query,\n },\n });\n }\n}"]}
1
+ {"version":3,"file":"ThirdParty.js","sourceRoot":"","sources":["../../../ts/api/resources/ThirdParty.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAKvC,MAAM,OAAO,UAAW,SAAQ,QAAQ;IACtC,MAAM;QACJ,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;IAC3C,CAAC;IAED,YAAY,CAAC,UAAyB,EAAE,KAAuB;QAC7D,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,gBAAgB,EAAE;YACvC,MAAM,kCACD,UAAU,GACV,KAAK,CACT;SACF,CAAC,CAAC;IACL,CAAC;IAED,MAAM,CAAC,YAAoB,EAAE,OAA6B;QACxD,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,kBAAkB,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IACpE,CAAC;IAED,MAAM,CAAC,OAA6B;QAClC,OAAO,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC;IACrD,CAAC;IAED,MAAM,CAAC,YAAoB;QACzB,OAAO,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,kBAAkB,YAAY,EAAE,CAAC,CAAC;IAC9D,CAAC;CACF","sourcesContent":["import { Resource } from '../Resource';\nimport {\n QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty, UpdateThirdPartyForm, CreateThirdPartyForm,\n} from '../../types';\n\nexport class ThirdParty extends Resource {\n getAll(): Promise<Array<IThirdParty>> {\n return this.axios.$get('/third-parties');\n }\n\n getPaginated(pagination: QueryPaginate, query?: QueryThirdParty): Promise<BasePaginate<IThirdParty>> {\n return this.axios.$get('/third-parties', {\n params: {\n ...pagination,\n ...query,\n },\n });\n }\n\n update(idThirdParty: number, payload: UpdateThirdPartyForm): Promise<IThirdParty> {\n return this.axios.$put(`/third-parties/${idThirdParty}`, payload);\n }\n\n create(payload: CreateThirdPartyForm): Promise<IThirdParty> {\n return this.axios.$post('/third-parties', payload);\n }\n\n delete(idThirdParty: number): Promise<true> {\n return this.axios.$delete(`/third-parties/${idThirdParty}`);\n }\n}"]}
@@ -1,6 +1,7 @@
1
1
  import { Resource } from '../Resource';
2
- import { ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected } from '../../types';
2
+ import { ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected, ITimeRecorder } from '../../types';
3
3
  export declare class TimeRecorder extends Resource {
4
+ create(payload: ITimeRecorder): Promise<TimeRecorder>;
4
5
  getAllPresenceHoursByUser(idUser: number, params: QueryAttendance): Promise<ReadAttendanceHours>;
5
6
  getAllUsersNotYetConnected(date?: string): Promise<ReadUsersNotConnected[]>;
6
7
  getPaginatedDelays(params: QueryPaginatedDelays): Promise<BasePaginate<ReadPaginatedDelays>>;
@@ -1 +1 @@
1
- {"version":3,"file":"TimeRecorder.d.ts","sourceRoot":"","sources":["../../../ts/api/resources/TimeRecorder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EACL,mBAAmB,EAAE,eAAe,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,YAAY,EAAE,qBAAqB,EACrH,MAAM,aAAa,CAAC;AAErB,qBAAa,YAAa,SAAQ,QAAQ;IACxC,yBAAyB,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,eAAe,GAAG,OAAO,CAAC,mBAAmB,CAAC;IAIhG,0BAA0B,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,qBAAqB,EAAE,CAAC;IAG3E,kBAAkB,CAAC,MAAM,EAAE,oBAAoB,GAAG,OAAO,CAAC,YAAY,CAAC,mBAAmB,CAAC,CAAC;CAI7F"}
1
+ {"version":3,"file":"TimeRecorder.d.ts","sourceRoot":"","sources":["../../../ts/api/resources/TimeRecorder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EACL,mBAAmB,EAAE,eAAe,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,YAAY,EAAE,qBAAqB,EAAE,aAAa,EACpI,MAAM,aAAa,CAAC;AAErB,qBAAa,YAAa,SAAQ,QAAQ;IACxC,MAAM,CAAC,OAAO,EAAE,aAAa,GAAG,OAAO,CAAC,YAAY,CAAC;IAGrD,yBAAyB,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,eAAe,GAAG,OAAO,CAAC,mBAAmB,CAAC;IAIhG,0BAA0B,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,qBAAqB,EAAE,CAAC;IAG3E,kBAAkB,CAAC,MAAM,EAAE,oBAAoB,GAAG,OAAO,CAAC,YAAY,CAAC,mBAAmB,CAAC,CAAC;CAI7F"}
@@ -1,5 +1,8 @@
1
1
  import { Resource } from '../Resource';
2
2
  export class TimeRecorder extends Resource {
3
+ create(payload) {
4
+ return this.axios.$post('/time-recorders', payload);
5
+ }
3
6
  getAllPresenceHoursByUser(idUser, params) {
4
7
  return this.axios.$get(`/users/${idUser}/attendances`, { params });
5
8
  }
@@ -1 +1 @@
1
- {"version":3,"file":"TimeRecorder.js","sourceRoot":"","sources":["../../../ts/api/resources/TimeRecorder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAKvC,MAAM,OAAO,YAAa,SAAQ,QAAQ;IACxC,yBAAyB,CAAC,MAAc,EAAE,MAAuB;QAC/D,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,UAAU,MAAM,cAAc,EACnD,EAAE,MAAM,EAAE,CAAC,CAAC;IAChB,CAAC;IACD,0BAA0B,CAAC,IAAa;QACtC,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,sBAAsB,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;IACnE,CAAC;IACD,kBAAkB,CAAC,MAA4B;QAC7C,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,kBAAkB,EACvC,EAAE,MAAM,EAAE,CAAC,CAAC;IAChB,CAAC;CACF","sourcesContent":["import { Resource } from '../Resource';\nimport {\n ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected,\n} from '../../types';\n\nexport class TimeRecorder extends Resource {\n getAllPresenceHoursByUser(idUser: number, params: QueryAttendance): Promise<ReadAttendanceHours> {\n return this.axios.$get(`/users/${idUser}/attendances`,\n { params });\n }\n getAllUsersNotYetConnected(date?: string): Promise<ReadUsersNotConnected[]> {\n return this.axios.$get('/users/not-connected', { params: date });\n }\n getPaginatedDelays(params: QueryPaginatedDelays): Promise<BasePaginate<ReadPaginatedDelays>> {\n return this.axios.$get('paginated-delays',\n { params });\n }\n}"]}
1
+ {"version":3,"file":"TimeRecorder.js","sourceRoot":"","sources":["../../../ts/api/resources/TimeRecorder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAKvC,MAAM,OAAO,YAAa,SAAQ,QAAQ;IACxC,MAAM,CAAC,OAAsB;QAC3B,OAAO,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,iBAAiB,EAAE,OAAO,CAAC,CAAC;IACtD,CAAC;IACD,yBAAyB,CAAC,MAAc,EAAE,MAAuB;QAC/D,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,UAAU,MAAM,cAAc,EACnD,EAAE,MAAM,EAAE,CAAC,CAAC;IAChB,CAAC;IACD,0BAA0B,CAAC,IAAa;QACtC,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,sBAAsB,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;IACnE,CAAC;IACD,kBAAkB,CAAC,MAA4B;QAC7C,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,kBAAkB,EACvC,EAAE,MAAM,EAAE,CAAC,CAAC;IAChB,CAAC;CACF","sourcesContent":["import { Resource } from '../Resource';\nimport {\n ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected, ITimeRecorder,\n} from '../../types';\n\nexport class TimeRecorder extends Resource {\n create(payload: ITimeRecorder): Promise<TimeRecorder> {\n return this.axios.$post('/time-recorders', payload);\n }\n getAllPresenceHoursByUser(idUser: number, params: QueryAttendance): Promise<ReadAttendanceHours> {\n return this.axios.$get(`/users/${idUser}/attendances`,\n { params });\n }\n getAllUsersNotYetConnected(date?: string): Promise<ReadUsersNotConnected[]> {\n return this.axios.$get('/users/not-connected', { params: date });\n }\n getPaginatedDelays(params: QueryPaginatedDelays): Promise<BasePaginate<ReadPaginatedDelays>> {\n return this.axios.$get('paginated-delays',\n { params });\n }\n}"]}
@@ -1,5 +1,6 @@
1
1
  export declare class GetAllCalendarEvent {
2
2
  idUser: number;
3
+ areEventsEditable?: boolean;
3
4
  startDate: Date;
4
5
  endDate: Date;
5
6
  isValidated?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"getAllCalendarEvent.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/getAllCalendarEvent.ts"],"names":[],"mappings":"AAEA,qBAAa,mBAAmB;IAE9B,MAAM,EAAE,MAAM,CAAC;IAGf,SAAS,EAAE,IAAI,CAAC;IAGhB,OAAO,EAAE,IAAI,CAAC;IAGd,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB"}
1
+ {"version":3,"file":"getAllCalendarEvent.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/getAllCalendarEvent.ts"],"names":[],"mappings":"AAEA,qBAAa,mBAAmB;IAE9B,MAAM,EAAE,MAAM,CAAC;IAGf,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAG5B,SAAS,EAAE,IAAI,CAAC;IAGhB,OAAO,EAAE,IAAI,CAAC;IAGd,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB"}
@@ -14,6 +14,10 @@ __decorate([
14
14
  ApiProperty(),
15
15
  __metadata("design:type", Number)
16
16
  ], GetAllCalendarEvent.prototype, "idUser", void 0);
17
+ __decorate([
18
+ ApiPropertyOptional({ default: false }),
19
+ __metadata("design:type", Boolean)
20
+ ], GetAllCalendarEvent.prototype, "areEventsEditable", void 0);
17
21
  __decorate([
18
22
  ApiProperty(),
19
23
  __metadata("design:type", Date)
@@ -1 +1 @@
1
- {"version":3,"file":"getAllCalendarEvent.js","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/getAllCalendarEvent.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAEhF,MAAM,OAAO,mBAAmB;CAY/B;AAVC;IADC,WAAW,EAAE;;mDACC;AAGf;IADC,WAAW,EAAE;8BACH,IAAI;sDAAC;AAGhB;IADC,WAAW,EAAE;8BACL,IAAI;oDAAC;AAGd;IADC,mBAAmB,EAAE;;wDACA","sourcesContent":["import { ApiProperty, ApiPropertyOptional } from '../../../../utils/decorators';\n\nexport class GetAllCalendarEvent {\n @ApiProperty()\n idUser: number;\n\n @ApiProperty()\n startDate: Date;\n\n @ApiProperty()\n endDate: Date;\n\n @ApiPropertyOptional()\n isValidated?: boolean;\n}\n"]}
1
+ {"version":3,"file":"getAllCalendarEvent.js","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/getAllCalendarEvent.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAEhF,MAAM,OAAO,mBAAmB;CAe/B;AAbC;IADC,WAAW,EAAE;;mDACC;AAGf;IADC,mBAAmB,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;;8DACZ;AAG5B;IADC,WAAW,EAAE;8BACH,IAAI;sDAAC;AAGhB;IADC,WAAW,EAAE;8BACL,IAAI;oDAAC;AAGd;IADC,mBAAmB,EAAE;;wDACA","sourcesContent":["import { ApiProperty, ApiPropertyOptional } from '../../../../utils/decorators';\n\nexport class GetAllCalendarEvent {\n @ApiProperty()\n idUser: number;\n\n @ApiPropertyOptional({ default: false })\n areEventsEditable?: boolean;\n\n @ApiProperty()\n startDate: Date;\n\n @ApiProperty()\n endDate: Date;\n\n @ApiPropertyOptional()\n isValidated?: boolean;\n}\n"]}
@@ -2,10 +2,11 @@ export interface ReadAllCalendarEvent {
2
2
  id: number;
3
3
  title: string;
4
4
  start: string;
5
- end: string;
5
+ end: string | null;
6
6
  content: string;
7
7
  idTimeCounterType?: number;
8
8
  validatedAt?: Date;
9
+ class?: string;
9
10
  deletable?: boolean;
10
11
  resizable?: boolean;
11
12
  draggable?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"readAllCalendarEvent.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/readAllCalendarEvent.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,oBAAoB;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,WAAW,CAAC,EAAE,IAAI,CAAC;IACnB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB"}
1
+ {"version":3,"file":"readAllCalendarEvent.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/readAllCalendarEvent.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,oBAAoB;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,WAAW,CAAC,EAAE,IAAI,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB"}
@@ -1 +1 @@
1
- {"version":3,"file":"readAllCalendarEvent.js","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/readAllCalendarEvent.ts"],"names":[],"mappings":"","sourcesContent":["export interface ReadAllCalendarEvent {\n id: number,\n title: string,\n start: string,\n end: string,\n content: string,\n idTimeCounterType?: number\n validatedAt?: Date,\n deletable?: boolean,\n resizable?: boolean,\n draggable?: boolean,\n}"]}
1
+ {"version":3,"file":"readAllCalendarEvent.js","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/readAllCalendarEvent.ts"],"names":[],"mappings":"","sourcesContent":["export interface ReadAllCalendarEvent {\n id: number,\n title: string,\n start: string,\n end: string | null,\n content: string,\n idTimeCounterType?: number\n validatedAt?: Date,\n class?: string;\n deletable?: boolean,\n resizable?: boolean,\n draggable?: boolean,\n}"]}
@@ -1,5 +1,6 @@
1
+ import { ITimeRecorder } from '../../models/ITimeRecorder';
1
2
  export interface ReadAttendanceHours {
2
3
  idUser: number;
3
- datas: any[];
4
+ datas: ITimeRecorder[];
4
5
  }
5
6
  //# sourceMappingURL=ReadAttendanceHours.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ReadAttendanceHours.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/timeRecorder/ReadAttendanceHours.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,GAAG,EAAE,CAAC;CACd"}
1
+ {"version":3,"file":"ReadAttendanceHours.d.ts","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/timeRecorder/ReadAttendanceHours.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAE3D,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,aAAa,EAAE,CAAC;CACxB"}
@@ -1 +1 @@
1
- {"version":3,"file":"ReadAttendanceHours.js","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/timeRecorder/ReadAttendanceHours.ts"],"names":[],"mappings":"","sourcesContent":["export interface ReadAttendanceHours {\n idUser: number;\n datas: any[];\n}"]}
1
+ {"version":3,"file":"ReadAttendanceHours.js","sourceRoot":"","sources":["../../../../../ts/types/Interface/api/timeRecorder/ReadAttendanceHours.ts"],"names":[],"mappings":"","sourcesContent":["import { ITimeRecorder } from '../../models/ITimeRecorder';\n\nexport interface ReadAttendanceHours {\n idUser: number;\n datas: ITimeRecorder[];\n}"]}
@@ -1,6 +1,6 @@
1
1
  export interface DateRange {
2
- start: string;
3
- end: string;
2
+ start: Date;
3
+ end: Date;
4
4
  from?: number;
5
5
  to?: number;
6
6
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Date.d.ts","sourceRoot":"","sources":["../../../../ts/types/Interface/enum/Date.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;CACb"}
1
+ {"version":3,"file":"Date.d.ts","sourceRoot":"","sources":["../../../../ts/types/Interface/enum/Date.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,IAAI,CAAC;IACZ,GAAG,EAAE,IAAI,CAAC;IACV,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;CACb"}
@@ -1 +1 @@
1
- {"version":3,"file":"Date.js","sourceRoot":"","sources":["../../../../ts/types/Interface/enum/Date.ts"],"names":[],"mappings":"","sourcesContent":["export interface DateRange {\n start: string;\n end: string;\n from?: number;\n to?: number;\n}"]}
1
+ {"version":3,"file":"Date.js","sourceRoot":"","sources":["../../../../ts/types/Interface/enum/Date.ts"],"names":[],"mappings":"","sourcesContent":["export interface DateRange {\n start: Date;\n end: Date;\n from?: number;\n to?: number;\n}"]}
@@ -18,6 +18,18 @@ class ThirdParty extends _Resource.Resource {
18
18
  });
19
19
  }
20
20
 
21
+ update(idThirdParty, payload) {
22
+ return this.axios.$put(`/third-parties/${idThirdParty}`, payload);
23
+ }
24
+
25
+ create(payload) {
26
+ return this.axios.$post('/third-parties', payload);
27
+ }
28
+
29
+ delete(idThirdParty) {
30
+ return this.axios.$delete(`/third-parties/${idThirdParty}`);
31
+ }
32
+
21
33
  }
22
34
 
23
35
  exports.ThirdParty = ThirdParty;
@@ -1 +1 @@
1
- {"version":3,"file":"ThirdParty.js","mappings":";;;;;;;AAAA;;AAKM,MAAOA,UAAP,SAA0BC,kBAA1B,CAAkC;EACtCC,MAAM;IACJ,OAAO,KAAKC,KAAL,CAAWC,IAAX,CAAgB,gBAAhB,CAAP;EACD;;EAEDC,YAAY,CAACC,UAAD,EAA4BC,KAA5B,EAAmD;IAC7D,OAAO,KAAKJ,KAAL,CAAWC,IAAX,CAAgB,gBAAhB,EAAkC;MACvCI,MAAM,kCACDF,UADC,GAEDC,KAFC;IADiC,CAAlC,CAAP;EAMD;;AAZqC;;QAA3BP,U,GAAAA,U","names":["ThirdParty","Resource","getAll","axios","$get","getPaginated","pagination","query","params"],"sourceRoot":"","sources":["../../../ts/api/resources/ThirdParty.ts"],"sourcesContent":["import { Resource } from '../Resource';\nimport {\n QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty,\n} from '../../types';\n\nexport class ThirdParty extends Resource {\n getAll(): Promise<Array<IThirdParty>> {\n return this.axios.$get('/third-parties');\n }\n\n getPaginated(pagination: QueryPaginate, query?: QueryThirdParty): Promise<BasePaginate<IThirdParty>> {\n return this.axios.$get('/third-parties', {\n params: {\n ...pagination,\n ...query,\n },\n });\n }\n}"]}
1
+ {"version":3,"file":"ThirdParty.js","mappings":";;;;;;;AAAA;;AAKM,MAAOA,UAAP,SAA0BC,kBAA1B,CAAkC;EACtCC,MAAM;IACJ,OAAO,KAAKC,KAAL,CAAWC,IAAX,CAAgB,gBAAhB,CAAP;EACD;;EAEDC,YAAY,CAACC,UAAD,EAA4BC,KAA5B,EAAmD;IAC7D,OAAO,KAAKJ,KAAL,CAAWC,IAAX,CAAgB,gBAAhB,EAAkC;MACvCI,MAAM,kCACDF,UADC,GAEDC,KAFC;IADiC,CAAlC,CAAP;EAMD;;EAEDE,MAAM,CAACC,YAAD,EAAuBC,OAAvB,EAAoD;IACxD,OAAO,KAAKR,KAAL,CAAWS,IAAX,CAAgB,kBAAkBF,YAAY,EAA9C,EAAkDC,OAAlD,CAAP;EACD;;EAEDE,MAAM,CAACF,OAAD,EAA8B;IAClC,OAAO,KAAKR,KAAL,CAAWW,KAAX,CAAiB,gBAAjB,EAAmCH,OAAnC,CAAP;EACD;;EAEDI,MAAM,CAACL,YAAD,EAAqB;IACzB,OAAO,KAAKP,KAAL,CAAWa,OAAX,CAAmB,kBAAkBN,YAAY,EAAjD,CAAP;EACD;;AAxBqC;;QAA3BV,U,GAAAA,U","names":["ThirdParty","Resource","getAll","axios","$get","getPaginated","pagination","query","params","update","idThirdParty","payload","$put","create","$post","delete","$delete"],"sourceRoot":"","sources":["../../../ts/api/resources/ThirdParty.ts"],"sourcesContent":["import { Resource } from '../Resource';\nimport {\n QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty, UpdateThirdPartyForm, CreateThirdPartyForm,\n} from '../../types';\n\nexport class ThirdParty extends Resource {\n getAll(): Promise<Array<IThirdParty>> {\n return this.axios.$get('/third-parties');\n }\n\n getPaginated(pagination: QueryPaginate, query?: QueryThirdParty): Promise<BasePaginate<IThirdParty>> {\n return this.axios.$get('/third-parties', {\n params: {\n ...pagination,\n ...query,\n },\n });\n }\n\n update(idThirdParty: number, payload: UpdateThirdPartyForm): Promise<IThirdParty> {\n return this.axios.$put(`/third-parties/${idThirdParty}`, payload);\n }\n\n create(payload: CreateThirdPartyForm): Promise<IThirdParty> {\n return this.axios.$post('/third-parties', payload);\n }\n\n delete(idThirdParty: number): Promise<true> {\n return this.axios.$delete(`/third-parties/${idThirdParty}`);\n }\n}"]}
@@ -8,6 +8,10 @@ exports.TimeRecorder = undefined;
8
8
  var _Resource = require("../Resource");
9
9
 
10
10
  class TimeRecorder extends _Resource.Resource {
11
+ create(payload) {
12
+ return this.axios.$post('/time-recorders', payload);
13
+ }
14
+
11
15
  getAllPresenceHoursByUser(idUser, params) {
12
16
  return this.axios.$get(`/users/${idUser}/attendances`, {
13
17
  params
@@ -1 +1 @@
1
- {"version":3,"file":"TimeRecorder.js","mappings":";;;;;;;AAAA;;AAKM,MAAOA,YAAP,SAA4BC,kBAA5B,CAAoC;EACxCC,yBAAyB,CAACC,MAAD,EAAiBC,MAAjB,EAAwC;IAC/D,OAAO,KAAKC,KAAL,CAAWC,IAAX,CAAgB,UAAUH,MAAM,cAAhC,EACL;MAAEC;IAAF,CADK,CAAP;EAED;;EACDG,0BAA0B,CAACC,IAAD,EAAc;IACtC,OAAO,KAAKH,KAAL,CAAWC,IAAX,CAAgB,sBAAhB,EAAwC;MAAEF,MAAM,EAAEI;IAAV,CAAxC,CAAP;EACD;;EACDC,kBAAkB,CAACL,MAAD,EAA6B;IAC7C,OAAO,KAAKC,KAAL,CAAWC,IAAX,CAAgB,kBAAhB,EACL;MAAEF;IAAF,CADK,CAAP;EAED;;AAXuC;;QAA7BJ,Y,GAAAA,Y","names":["TimeRecorder","Resource","getAllPresenceHoursByUser","idUser","params","axios","$get","getAllUsersNotYetConnected","date","getPaginatedDelays"],"sourceRoot":"","sources":["../../../ts/api/resources/TimeRecorder.ts"],"sourcesContent":["import { Resource } from '../Resource';\nimport {\n ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected,\n} from '../../types';\n\nexport class TimeRecorder extends Resource {\n getAllPresenceHoursByUser(idUser: number, params: QueryAttendance): Promise<ReadAttendanceHours> {\n return this.axios.$get(`/users/${idUser}/attendances`,\n { params });\n }\n getAllUsersNotYetConnected(date?: string): Promise<ReadUsersNotConnected[]> {\n return this.axios.$get('/users/not-connected', { params: date });\n }\n getPaginatedDelays(params: QueryPaginatedDelays): Promise<BasePaginate<ReadPaginatedDelays>> {\n return this.axios.$get('paginated-delays',\n { params });\n }\n}"]}
1
+ {"version":3,"file":"TimeRecorder.js","mappings":";;;;;;;AAAA;;AAKM,MAAOA,YAAP,SAA4BC,kBAA5B,CAAoC;EACxCC,MAAM,CAACC,OAAD,EAAuB;IAC3B,OAAO,KAAKC,KAAL,CAAWC,KAAX,CAAiB,iBAAjB,EAAoCF,OAApC,CAAP;EACD;;EACDG,yBAAyB,CAACC,MAAD,EAAiBC,MAAjB,EAAwC;IAC/D,OAAO,KAAKJ,KAAL,CAAWK,IAAX,CAAgB,UAAUF,MAAM,cAAhC,EACL;MAAEC;IAAF,CADK,CAAP;EAED;;EACDE,0BAA0B,CAACC,IAAD,EAAc;IACtC,OAAO,KAAKP,KAAL,CAAWK,IAAX,CAAgB,sBAAhB,EAAwC;MAAED,MAAM,EAAEG;IAAV,CAAxC,CAAP;EACD;;EACDC,kBAAkB,CAACJ,MAAD,EAA6B;IAC7C,OAAO,KAAKJ,KAAL,CAAWK,IAAX,CAAgB,kBAAhB,EACL;MAAED;IAAF,CADK,CAAP;EAED;;AAduC;;QAA7BR,Y,GAAAA,Y","names":["TimeRecorder","Resource","create","payload","axios","$post","getAllPresenceHoursByUser","idUser","params","$get","getAllUsersNotYetConnected","date","getPaginatedDelays"],"sourceRoot":"","sources":["../../../ts/api/resources/TimeRecorder.ts"],"sourcesContent":["import { Resource } from '../Resource';\nimport {\n ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected, ITimeRecorder,\n} from '../../types';\n\nexport class TimeRecorder extends Resource {\n create(payload: ITimeRecorder): Promise<TimeRecorder> {\n return this.axios.$post('/time-recorders', payload);\n }\n getAllPresenceHoursByUser(idUser: number, params: QueryAttendance): Promise<ReadAttendanceHours> {\n return this.axios.$get(`/users/${idUser}/attendances`,\n { params });\n }\n getAllUsersNotYetConnected(date?: string): Promise<ReadUsersNotConnected[]> {\n return this.axios.$get('/users/not-connected', { params: date });\n }\n getPaginatedDelays(params: QueryPaginatedDelays): Promise<BasePaginate<ReadPaginatedDelays>> {\n return this.axios.$get('paginated-delays',\n { params });\n }\n}"]}
@@ -25,6 +25,10 @@ exports.GetAllCalendarEvent = GetAllCalendarEvent;
25
25
 
26
26
  __decorate([(0, _decorators.ApiProperty)(), __metadata("design:type", Number)], GetAllCalendarEvent.prototype, "idUser", void 0);
27
27
 
28
+ __decorate([(0, _decorators.ApiPropertyOptional)({
29
+ default: false
30
+ }), __metadata("design:type", Boolean)], GetAllCalendarEvent.prototype, "areEventsEditable", void 0);
31
+
28
32
  __decorate([(0, _decorators.ApiProperty)(), __metadata("design:type", Date)], GetAllCalendarEvent.prototype, "startDate", void 0);
29
33
 
30
34
  __decorate([(0, _decorators.ApiProperty)(), __metadata("design:type", Date)], GetAllCalendarEvent.prototype, "endDate", void 0);
@@ -1 +1 @@
1
- {"version":3,"file":"getAllCalendarEvent.js","mappings":";;;;;;;AAAA;;;;;;;;;;;;;;AAEM,MAAOA,mBAAP,CAA0B;;QAAnBA,mB,GAAAA,mB;;AAEXC,YADC,8BACD;;AAGAA,YADC,8BACD,4BAAWC,KAAX;;AAGAD,YADC,8BACD,4BAASC,KAAT;;AAGAD,YADC,sCACD","names":["GetAllCalendarEvent","__decorate","Date"],"sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/getAllCalendarEvent.ts"],"sourcesContent":["import { ApiProperty, ApiPropertyOptional } from '../../../../utils/decorators';\n\nexport class GetAllCalendarEvent {\n @ApiProperty()\n idUser: number;\n\n @ApiProperty()\n startDate: Date;\n\n @ApiProperty()\n endDate: Date;\n\n @ApiPropertyOptional()\n isValidated?: boolean;\n}\n"]}
1
+ {"version":3,"file":"getAllCalendarEvent.js","mappings":";;;;;;;AAAA;;;;;;;;;;;;;;AAEM,MAAOA,mBAAP,CAA0B;;QAAnBA,mB,GAAAA,mB;;AAEXC,YADC,8BACD;;AAGAA,YADC,qCAAoB;EAAEC,OAAO,EAAE;AAAX,CAApB,CACD;;AAGAD,YADC,8BACD,4BAAWE,KAAX;;AAGAF,YADC,8BACD,4BAASE,KAAT;;AAGAF,YADC,sCACD","names":["GetAllCalendarEvent","__decorate","default","Date"],"sourceRoot":"","sources":["../../../../../ts/types/Interface/api/calendarEvent/getAllCalendarEvent.ts"],"sourcesContent":["import { ApiProperty, ApiPropertyOptional } from '../../../../utils/decorators';\n\nexport class GetAllCalendarEvent {\n @ApiProperty()\n idUser: number;\n\n @ApiPropertyOptional({ default: false })\n areEventsEditable?: boolean;\n\n @ApiProperty()\n startDate: Date;\n\n @ApiProperty()\n endDate: Date;\n\n @ApiPropertyOptional()\n isValidated?: boolean;\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@silexpert/core",
3
- "version": "0.4.232",
3
+ "version": "0.4.234",
4
4
  "description": "Silex Core perform HTTP Request and object binding. Silex core helps developers to retrieve and return formatted object",
5
5
  "homepage": "https://gitlab.compta-clementine.fr/dev/silex-api",
6
6
  "main": "js/index.js",
@@ -1,6 +1,6 @@
1
1
  import { Resource } from '../Resource';
2
2
  import {
3
- QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty,
3
+ QueryPaginate, BasePaginate, IThirdParty, QueryThirdParty, UpdateThirdPartyForm, CreateThirdPartyForm,
4
4
  } from '../../types';
5
5
 
6
6
  export class ThirdParty extends Resource {
@@ -16,4 +16,16 @@ export class ThirdParty extends Resource {
16
16
  },
17
17
  });
18
18
  }
19
+
20
+ update(idThirdParty: number, payload: UpdateThirdPartyForm): Promise<IThirdParty> {
21
+ return this.axios.$put(`/third-parties/${idThirdParty}`, payload);
22
+ }
23
+
24
+ create(payload: CreateThirdPartyForm): Promise<IThirdParty> {
25
+ return this.axios.$post('/third-parties', payload);
26
+ }
27
+
28
+ delete(idThirdParty: number): Promise<true> {
29
+ return this.axios.$delete(`/third-parties/${idThirdParty}`);
30
+ }
19
31
  }
@@ -1,9 +1,12 @@
1
1
  import { Resource } from '../Resource';
2
2
  import {
3
- ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected,
3
+ ReadAttendanceHours, QueryAttendance, QueryPaginatedDelays, ReadPaginatedDelays, BasePaginate, ReadUsersNotConnected, ITimeRecorder,
4
4
  } from '../../types';
5
5
 
6
6
  export class TimeRecorder extends Resource {
7
+ create(payload: ITimeRecorder): Promise<TimeRecorder> {
8
+ return this.axios.$post('/time-recorders', payload);
9
+ }
7
10
  getAllPresenceHoursByUser(idUser: number, params: QueryAttendance): Promise<ReadAttendanceHours> {
8
11
  return this.axios.$get(`/users/${idUser}/attendances`,
9
12
  { params });
@@ -4,6 +4,9 @@ export class GetAllCalendarEvent {
4
4
  @ApiProperty()
5
5
  idUser: number;
6
6
 
7
+ @ApiPropertyOptional({ default: false })
8
+ areEventsEditable?: boolean;
9
+
7
10
  @ApiProperty()
8
11
  startDate: Date;
9
12
 
@@ -2,10 +2,11 @@ export interface ReadAllCalendarEvent {
2
2
  id: number,
3
3
  title: string,
4
4
  start: string,
5
- end: string,
5
+ end: string | null,
6
6
  content: string,
7
7
  idTimeCounterType?: number
8
8
  validatedAt?: Date,
9
+ class?: string;
9
10
  deletable?: boolean,
10
11
  resizable?: boolean,
11
12
  draggable?: boolean,
@@ -1,4 +1,6 @@
1
+ import { ITimeRecorder } from '../../models/ITimeRecorder';
2
+
1
3
  export interface ReadAttendanceHours {
2
4
  idUser: number;
3
- datas: any[];
5
+ datas: ITimeRecorder[];
4
6
  }
@@ -1,6 +1,6 @@
1
1
  export interface DateRange {
2
- start: string;
3
- end: string;
2
+ start: Date;
3
+ end: Date;
4
4
  from?: number;
5
5
  to?: number;
6
6
  }