@experts_hub/shared 1.0.188 → 1.0.190

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/dist/index.js CHANGED
@@ -2574,10 +2574,7 @@ __decorateClass([
2574
2574
  (0, import_typeorm28.OneToMany)(() => SenseloafLog, (senseloafLog) => senseloafLog.user)
2575
2575
  ], User.prototype, "senseloafLogs", 2);
2576
2576
  __decorateClass([
2577
- (0, import_typeorm28.OneToOne)(
2578
- () => FreelancerProfile,
2579
- (freelancerProfile) => freelancerProfile.user
2580
- )
2577
+ (0, import_typeorm28.OneToOne)(() => FreelancerProfile, (freelancerProfile) => freelancerProfile.user, { cascade: true })
2581
2578
  ], User.prototype, "freelancerProfile", 2);
2582
2579
  __decorateClass([
2583
2580
  (0, import_typeorm28.OneToOne)(() => CompanyProfile, (companyProfile) => companyProfile.user, {
@@ -2830,6 +2827,7 @@ var FreelancerExperienceDto = class {
2830
2827
  };
2831
2828
  __decorateClass([
2832
2829
  (0, import_class_validator39.ValidateNested)({ each: true }),
2830
+ (0, import_class_validator39.ArrayMinSize)(1, { message: "At least one experience is required." }),
2833
2831
  (0, import_class_transformer2.Type)(() => ExperienceDto)
2834
2832
  ], FreelancerExperienceDto.prototype, "experiences", 2);
2835
2833
 
@@ -2915,6 +2913,7 @@ var FreelancerEducationDto = class {
2915
2913
  };
2916
2914
  __decorateClass([
2917
2915
  (0, import_class_validator43.IsArray)(),
2916
+ (0, import_class_validator43.ArrayMinSize)(1, { message: "At least one education is required." }),
2918
2917
  (0, import_class_validator43.ValidateNested)({ each: true }),
2919
2918
  (0, import_class_transformer3.Type)(() => EducationDto)
2920
2919
  ], FreelancerEducationDto.prototype, "educations", 2);
@@ -2980,6 +2979,7 @@ var FreelancerProjectDto = class {
2980
2979
  };
2981
2980
  __decorateClass([
2982
2981
  (0, import_class_validator44.IsArray)(),
2982
+ (0, import_class_validator44.ArrayMinSize)(1, { message: "At least one project is required." }),
2983
2983
  (0, import_class_validator44.ValidateNested)({ each: true }),
2984
2984
  (0, import_class_transformer4.Type)(() => ProjectDto)
2985
2985
  ], FreelancerProjectDto.prototype, "projects", 2);
package/dist/index.mjs CHANGED
@@ -2650,10 +2650,7 @@ __decorateClass([
2650
2650
  OneToMany8(() => SenseloafLog, (senseloafLog) => senseloafLog.user)
2651
2651
  ], User.prototype, "senseloafLogs", 2);
2652
2652
  __decorateClass([
2653
- OneToOne(
2654
- () => FreelancerProfile,
2655
- (freelancerProfile) => freelancerProfile.user
2656
- )
2653
+ OneToOne(() => FreelancerProfile, (freelancerProfile) => freelancerProfile.user, { cascade: true })
2657
2654
  ], User.prototype, "freelancerProfile", 2);
2658
2655
  __decorateClass([
2659
2656
  OneToOne(() => CompanyProfile, (companyProfile) => companyProfile.user, {
@@ -2879,6 +2876,7 @@ var FREELANCER_EXPERIENCE_PATTERN = {
2879
2876
 
2880
2877
  // src/modules/user/freelancer-experience/dto/freelancer-experience.dto.ts
2881
2878
  import {
2879
+ ArrayMinSize,
2882
2880
  IsNotEmpty as IsNotEmpty32,
2883
2881
  IsOptional as IsOptional12,
2884
2882
  IsString as IsString20,
@@ -2912,6 +2910,7 @@ var FreelancerExperienceDto = class {
2912
2910
  };
2913
2911
  __decorateClass([
2914
2912
  ValidateNested({ each: true }),
2913
+ ArrayMinSize(1, { message: "At least one experience is required." }),
2915
2914
  Type2(() => ExperienceDto)
2916
2915
  ], FreelancerExperienceDto.prototype, "experiences", 2);
2917
2916
 
@@ -2974,7 +2973,7 @@ var FREELANCER_EDUCATION_PATTERN = {
2974
2973
  };
2975
2974
 
2976
2975
  // src/modules/user/freelancer-education/dto/freelancer-education.dto.ts
2977
- import { IsArray as IsArray6, ValidateNested as ValidateNested2, IsString as IsString23, IsNotEmpty as IsNotEmpty35, IsOptional as IsOptional15 } from "class-validator";
2976
+ import { IsArray as IsArray6, ValidateNested as ValidateNested2, IsString as IsString23, IsNotEmpty as IsNotEmpty35, IsOptional as IsOptional15, ArrayMinSize as ArrayMinSize2 } from "class-validator";
2978
2977
  import { Type as Type3 } from "class-transformer";
2979
2978
  var EducationDto = class {
2980
2979
  };
@@ -2997,6 +2996,7 @@ var FreelancerEducationDto = class {
2997
2996
  };
2998
2997
  __decorateClass([
2999
2998
  IsArray6(),
2999
+ ArrayMinSize2(1, { message: "At least one education is required." }),
3000
3000
  ValidateNested2({ each: true }),
3001
3001
  Type3(() => EducationDto)
3002
3002
  ], FreelancerEducationDto.prototype, "educations", 2);
@@ -3008,7 +3008,7 @@ var FREELANCER_PROJECT_PATTERN = {
3008
3008
  };
3009
3009
 
3010
3010
  // src/modules/user/freelancer-project/dto/freelancer-project.dto.ts
3011
- import { IsArray as IsArray7, ValidateNested as ValidateNested3, IsString as IsString24, IsNotEmpty as IsNotEmpty36, IsOptional as IsOptional16, IsDateString, MaxLength as MaxLength12 } from "class-validator";
3011
+ import { IsArray as IsArray7, ValidateNested as ValidateNested3, IsString as IsString24, IsNotEmpty as IsNotEmpty36, IsOptional as IsOptional16, IsDateString, MaxLength as MaxLength12, ArrayMinSize as ArrayMinSize3 } from "class-validator";
3012
3012
  import { Type as Type4 } from "class-transformer";
3013
3013
  var ProjectDto = class {
3014
3014
  };
@@ -3062,6 +3062,7 @@ var FreelancerProjectDto = class {
3062
3062
  };
3063
3063
  __decorateClass([
3064
3064
  IsArray7(),
3065
+ ArrayMinSize3(1, { message: "At least one project is required." }),
3065
3066
  ValidateNested3({ each: true }),
3066
3067
  Type4(() => ProjectDto)
3067
3068
  ], FreelancerProjectDto.prototype, "projects", 2);
@@ -23,3 +23,4 @@ export * from './freelancer-admin';
23
23
  export * from './client-admin';
24
24
  export * from './user/freelancer-declaration';
25
25
  export * from './cms';
26
+ export * from './client-admin';
@@ -0,0 +1,64 @@
1
+ export interface IFetchClientsResponse {
2
+ statusCode: number;
3
+ status: boolean;
4
+ message: string;
5
+ data: any;
6
+ }
7
+ export interface ICreateClientPayload {
8
+ firstName: string;
9
+ lastName: string;
10
+ email: string;
11
+ password: string;
12
+ confirmPassword: string;
13
+ companyName: string;
14
+ skills: string[];
15
+ requiredFreelancer: string;
16
+ kindOfHiring: string;
17
+ modeOfHire: string;
18
+ foundUsOn: string;
19
+ OTHER?: string;
20
+ foundUsOnDetail?: string;
21
+ }
22
+ export interface ICreateClientResponse {
23
+ statusCode: number;
24
+ status: boolean;
25
+ message: string;
26
+ }
27
+ export interface IUpdateClientPayload {
28
+ firstName?: string;
29
+ lastName?: string;
30
+ email?: string;
31
+ password?: string;
32
+ confirmPassword?: string;
33
+ companyName?: string;
34
+ skills?: string[];
35
+ requiredFreelancer?: string;
36
+ kindOfHiring?: string;
37
+ modeOfHire?: string;
38
+ foundUsOn?: string;
39
+ OTHER?: string;
40
+ foundUsOnDetail?: string;
41
+ }
42
+ export interface IUpdateClientResponse {
43
+ statusCode: number;
44
+ status: boolean;
45
+ message: string;
46
+ }
47
+ export interface IUpdateClientAccountStatusPayload {
48
+ accountSatus: string;
49
+ }
50
+ export interface IUpdateClientAccountStatusResponse {
51
+ statusCode: number;
52
+ status: boolean;
53
+ message: string;
54
+ }
55
+ export interface IDeleteClientResponse {
56
+ statusCode: number;
57
+ status: boolean;
58
+ message: string;
59
+ }
60
+ export interface IAttachPermissionsToClientResponse {
61
+ statusCode: number;
62
+ status: boolean;
63
+ message: string;
64
+ }
@@ -0,0 +1,24 @@
1
+ export declare enum HiringMode {
2
+ REMOTE = "REMOTE",
3
+ ONSITE = "ONSITE",
4
+ BOTH = "BOTH"
5
+ }
6
+ export declare enum HiringType {
7
+ PARTTIME = "PARTTIME",
8
+ FULLTIME = "FULLTIME",
9
+ BOTH = "BOTH"
10
+ }
11
+ export declare class CreateClientDto {
12
+ firstName: string;
13
+ lastName: string;
14
+ email: string;
15
+ confirmPassword: string;
16
+ companyName: string;
17
+ skills: string[];
18
+ requiredFreelancer: string;
19
+ kindOfHiring: string;
20
+ modeOfHire: string;
21
+ foundUsOn: string;
22
+ OTHER?: string;
23
+ foundUsOnDetail?: string;
24
+ }
@@ -0,0 +1,3 @@
1
+ export * from './create-client.dto';
2
+ export * from './update-client-status.dto';
3
+ export * from './update-client.dto';
@@ -0,0 +1,3 @@
1
+ export declare class UpdateClientAccountStatusDto {
2
+ accountStatus: string;
3
+ }
@@ -0,0 +1,11 @@
1
+ export declare class UpdateClientDto {
2
+ uniqueId: string;
3
+ userName: string;
4
+ firstName: string;
5
+ lastName: string;
6
+ email: string;
7
+ mobile: string;
8
+ password: string;
9
+ accountType: string;
10
+ accountStatus: string;
11
+ }
@@ -0,0 +1,3 @@
1
+ export * from './pattern/pattern';
2
+ export * from './dto';
3
+ export * from './client-admin.interface';
@@ -0,0 +1,7 @@
1
+ export declare const CLIENT_PATTERN: {
2
+ fetchClient: string;
3
+ findClientById: string;
4
+ createClient: string;
5
+ updateClient: string;
6
+ deleteClient: string;
7
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@experts_hub/shared",
3
- "version": "1.0.188",
3
+ "version": "1.0.190",
4
4
  "description": "Shared DTOs, interfaces, and utilities for experts hub applications",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/",