law-common 1.2.20 → 1.2.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.
@@ -1,11 +1,22 @@
1
- import { IApiEntity, IProjectEntity, IProjectEntityDependent } from "../../entities";
1
+ import { IApiEntity, IDesignationApiEntity, IProjectCreateDtoExtra, IProjectEntity, IProjectEntityDependent } from "../../entities";
2
+ import { IClientApiEntity } from "./client.entity.response";
3
+ import { IRateApiEntity } from "./rate.entity.response";
2
4
  import { IUserApiEntity } from "./user.entity.api";
3
5
  export type IProjectApiEntity = IApiEntity<IProjectEntity>;
4
6
  export type IProjectApiEntityArray = IProjectApiEntity[];
5
- export type IProjectApiEntityDependent = IProjectApiEntity & IProjectEntityDependent;
7
+ export type IProjectApiEntityDependent = IProjectApiEntity & IProjectEntityDependent & IProjectCreateDtoExtra;
6
8
  export type IProjectEntityGet = {
7
9
  projects: IProjectApiEntityDependent[];
8
10
  users: {
9
11
  [key: string]: IUserApiEntity;
10
12
  };
13
+ clients: {
14
+ [key: string]: IClientApiEntity;
15
+ };
16
+ designations?: {
17
+ [key: string]: IDesignationApiEntity;
18
+ };
19
+ rates?: {
20
+ [key: string]: IRateApiEntity;
21
+ };
11
22
  };
@@ -27,7 +27,9 @@ export interface IProjectHourlyRate {
27
27
  rate: number;
28
28
  unit: TimeUnitEnum.HOUR;
29
29
  }
30
- export type IProjectHourlyRates = IProjectHourlyRate[];
30
+ export interface IProjectCreateDtoExtra {
31
+ projectBillingRate: IProjectHourlyRate[] | IProjectFixedMonthlyRate | IProjectAdhocRate;
32
+ }
31
33
  export interface IProjectFixedMonthlyRate {
32
34
  rate: number;
33
35
  unit: TimeUnitEnum.MONTH;
@@ -37,8 +39,7 @@ export interface IProjectAdhocRate {
37
39
  rate: number;
38
40
  maxEstimatedHours: number;
39
41
  }
40
- export interface IProjectEntityCreateDto extends Omit<IEntityCreateDto<IProjectEntity>, IProjectExclude>, IProjectEntityDependent {
41
- projectBillingRate?: IProjectHourlyRates | IProjectFixedMonthlyRate | IProjectAdhocRate;
42
+ export interface IProjectEntityCreateDto extends Omit<IEntityCreateDto<IProjectEntity>, IProjectExclude>, IProjectEntityDependent, IProjectCreateDtoExtra {
42
43
  }
43
44
  export interface IProjectEntityUpdateDto extends Omit<IEntityUpdateDto<IProjectEntity>, IProjectExclude>, Partial<IProjectEntityDependent> {
44
45
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "law-common",
3
- "version": "1.2.20",
3
+ "version": "1.2.21",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "files": [