@experts_hub/shared 1.0.62 → 1.0.64

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
@@ -31,6 +31,7 @@ __export(index_exports, {
31
31
  AccountStatus: () => AccountStatus,
32
32
  AccountType: () => AccountType,
33
33
  BaseEntity: () => BaseEntity,
34
+ ClientCreateAccountDto: () => ClientCreateAccountDto,
34
35
  ClientProfileQuestionDto: () => ClientProfileQuestionDto,
35
36
  CompanyProfile: () => CompanyProfile,
36
37
  CreateQuestionDto: () => CreateQuestionDto,
@@ -229,18 +230,48 @@ __decorateClass([
229
230
  (0, import_class_validator8.IsNotEmpty)({ message: "Please enter answer." })
230
231
  ], FreelancerProfileQuestionDto.prototype, "answer", 2);
231
232
 
232
- // src/modules/onboarding/dto/client-profile-question.dto.ts
233
+ // src/modules/onboarding/dto/freelancer-work-showcase.dto.ts
233
234
  var import_class_validator9 = require("class-validator");
234
- var ClientProfileQuestionDto = class {
235
+ var FreelancerWorkShowcaseDto = class {
235
236
  };
236
237
  __decorateClass([
237
238
  (0, import_class_validator9.IsNotEmpty)({ message: "Please enter uuid." }),
238
239
  (0, import_class_validator9.IsUUID)()
239
- ], ClientProfileQuestionDto.prototype, "uuid", 2);
240
+ ], FreelancerWorkShowcaseDto.prototype, "uuid", 2);
240
241
  __decorateClass([
241
- (0, import_class_validator9.IsNotEmpty)({ message: "Please enter question slug." }),
242
+ (0, import_class_validator9.IsNotEmpty)({ message: "Please enter likedin profile url." }),
242
243
  (0, import_class_validator9.IsString)(),
243
- (0, import_class_validator9.IsIn)([
244
+ (0, import_class_validator9.IsUrl)({ require_protocol: true }, { message: "linkedinProfileLink must be a valid URL with protocol (e.g. https://)" })
245
+ ], FreelancerWorkShowcaseDto.prototype, "linkedinProfileLink", 2);
246
+ __decorateClass([
247
+ (0, import_class_validator9.IsOptional)(),
248
+ (0, import_class_validator9.IsUrl)({ require_protocol: true }, { message: "kaggleProfileLink must be a valid URL with protocol (e.g. https://)" })
249
+ ], FreelancerWorkShowcaseDto.prototype, "kaggleProfileLink", 2);
250
+ __decorateClass([
251
+ (0, import_class_validator9.IsOptional)(),
252
+ (0, import_class_validator9.IsUrl)({ require_protocol: true }, { message: "githubProfileLink must be a valid URL with protocol (e.g. https://)" })
253
+ ], FreelancerWorkShowcaseDto.prototype, "githubProfileLink", 2);
254
+ __decorateClass([
255
+ (0, import_class_validator9.IsOptional)(),
256
+ (0, import_class_validator9.IsUrl)({ require_protocol: true }, { message: "stackOverflowProfileLink must be a valid URL with protocol (e.g. https://)" })
257
+ ], FreelancerWorkShowcaseDto.prototype, "stackOverflowProfileLink", 2);
258
+ __decorateClass([
259
+ (0, import_class_validator9.IsOptional)(),
260
+ (0, import_class_validator9.IsUrl)({ require_protocol: true }, { message: "portfolioLink must be a valid URL with protocol (e.g. https://)" })
261
+ ], FreelancerWorkShowcaseDto.prototype, "portfolioLink", 2);
262
+
263
+ // src/modules/onboarding/dto/client-profile-question.dto.ts
264
+ var import_class_validator10 = require("class-validator");
265
+ var ClientProfileQuestionDto = class {
266
+ };
267
+ __decorateClass([
268
+ (0, import_class_validator10.IsNotEmpty)({ message: "Please enter uuid." }),
269
+ (0, import_class_validator10.IsUUID)()
270
+ ], ClientProfileQuestionDto.prototype, "uuid", 2);
271
+ __decorateClass([
272
+ (0, import_class_validator10.IsNotEmpty)({ message: "Please enter question slug." }),
273
+ (0, import_class_validator10.IsString)(),
274
+ (0, import_class_validator10.IsIn)([
244
275
  "skills",
245
276
  "requiredFreelancer",
246
277
  "kindOfHiring",
@@ -249,38 +280,37 @@ __decorateClass([
249
280
  ])
250
281
  ], ClientProfileQuestionDto.prototype, "question_slug", 2);
251
282
  __decorateClass([
252
- (0, import_class_validator9.IsNotEmpty)({ message: "Please enter answer." })
283
+ (0, import_class_validator10.IsNotEmpty)({ message: "Please enter answer." })
253
284
  ], ClientProfileQuestionDto.prototype, "answer", 2);
254
285
 
255
- // src/modules/onboarding/dto/freelancer-work-showcase.dto.ts
256
- var import_class_validator10 = require("class-validator");
257
- var FreelancerWorkShowcaseDto = class {
286
+ // src/modules/onboarding/dto/client-create-account.dto.ts
287
+ var import_class_validator11 = require("class-validator");
288
+ var ClientCreateAccountDto = class {
258
289
  };
259
290
  __decorateClass([
260
- (0, import_class_validator10.IsNotEmpty)({ message: "Please enter uuid." }),
261
- (0, import_class_validator10.IsUUID)()
262
- ], FreelancerWorkShowcaseDto.prototype, "uuid", 2);
291
+ (0, import_class_validator11.IsNotEmpty)({ message: "Please enter full name." }),
292
+ (0, import_class_validator11.IsString)({ message: "Please enter valid full name." })
293
+ ], ClientCreateAccountDto.prototype, "fullName", 2);
263
294
  __decorateClass([
264
- (0, import_class_validator10.IsNotEmpty)({ message: "Please enter likedin profile url." }),
265
- (0, import_class_validator10.IsString)(),
266
- (0, import_class_validator10.IsUrl)({ require_protocol: true }, { message: "linkedinProfileLink must be a valid URL with protocol (e.g. https://)" })
267
- ], FreelancerWorkShowcaseDto.prototype, "linkedinProfileLink", 2);
295
+ (0, import_class_validator11.IsNotEmpty)({ message: "Please enter email." }),
296
+ (0, import_class_validator11.IsEmail)()
297
+ ], ClientCreateAccountDto.prototype, "email", 2);
268
298
  __decorateClass([
269
- (0, import_class_validator10.IsOptional)(),
270
- (0, import_class_validator10.IsUrl)({ require_protocol: true }, { message: "kaggleProfileLink must be a valid URL with protocol (e.g. https://)" })
271
- ], FreelancerWorkShowcaseDto.prototype, "kaggleProfileLink", 2);
299
+ (0, import_class_validator11.IsNotEmpty)({ message: "Please enter company name." }),
300
+ (0, import_class_validator11.IsString)({ message: "Please enter valid company name." })
301
+ ], ClientCreateAccountDto.prototype, "companyName", 2);
272
302
  __decorateClass([
273
- (0, import_class_validator10.IsOptional)(),
274
- (0, import_class_validator10.IsUrl)({ require_protocol: true }, { message: "githubProfileLink must be a valid URL with protocol (e.g. https://)" })
275
- ], FreelancerWorkShowcaseDto.prototype, "githubProfileLink", 2);
276
- __decorateClass([
277
- (0, import_class_validator10.IsOptional)(),
278
- (0, import_class_validator10.IsUrl)({ require_protocol: true }, { message: "stackOverflowProfileLink must be a valid URL with protocol (e.g. https://)" })
279
- ], FreelancerWorkShowcaseDto.prototype, "stackOverflowProfileLink", 2);
303
+ (0, import_class_validator11.IsNotEmpty)({ message: "Please enter password." }),
304
+ (0, import_class_validator11.MinLength)(6),
305
+ (0, import_class_validator11.MaxLength)(32),
306
+ (0, import_class_validator11.Matches)(/^(?=.*[A-Za-z])(?=.*\d)(?=.*[@$!%*?&])/, {
307
+ message: "Password must include letters, numbers and symbols."
308
+ })
309
+ ], ClientCreateAccountDto.prototype, "password", 2);
280
310
  __decorateClass([
281
- (0, import_class_validator10.IsOptional)(),
282
- (0, import_class_validator10.IsUrl)({ require_protocol: true }, { message: "portfolioLink must be a valid URL with protocol (e.g. https://)" })
283
- ], FreelancerWorkShowcaseDto.prototype, "portfolioLink", 2);
311
+ (0, import_class_validator11.IsNotEmpty)({ message: "Please enter confirm password." }),
312
+ Match("password", { message: "Passwords do not match" })
313
+ ], ClientCreateAccountDto.prototype, "confirmPassword", 2);
284
314
 
285
315
  // src/modules/resume-parser/pattern/pattern.ts
286
316
  var RESUME_PARSER_PATTERN = {
@@ -300,75 +330,75 @@ var SUBADMIN_PATTERN = {
300
330
  };
301
331
 
302
332
  // src/modules/user/subadmin/dto/create-subadmin.dto.ts
303
- var import_class_validator11 = require("class-validator");
333
+ var import_class_validator12 = require("class-validator");
304
334
  var CreateSubAdminDto = class {
305
335
  };
306
336
  __decorateClass([
307
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter unique id." })
337
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter unique id." })
308
338
  ], CreateSubAdminDto.prototype, "uniqueId", 2);
309
339
  __decorateClass([
310
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter username." })
340
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter username." })
311
341
  ], CreateSubAdminDto.prototype, "userName", 2);
312
342
  __decorateClass([
313
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter first name." })
343
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter first name." })
314
344
  ], CreateSubAdminDto.prototype, "firstName", 2);
315
345
  __decorateClass([
316
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter last name." })
346
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter last name." })
317
347
  ], CreateSubAdminDto.prototype, "lastName", 2);
318
348
  __decorateClass([
319
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter email." })
349
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter email." })
320
350
  ], CreateSubAdminDto.prototype, "email", 2);
321
351
  __decorateClass([
322
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter mobile number." })
352
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter mobile number." })
323
353
  ], CreateSubAdminDto.prototype, "mobile", 2);
324
354
  __decorateClass([
325
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter the password." })
355
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter the password." })
326
356
  ], CreateSubAdminDto.prototype, "password", 2);
327
357
  __decorateClass([
328
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter account type." })
358
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter account type." })
329
359
  ], CreateSubAdminDto.prototype, "accountType", 2);
330
360
  __decorateClass([
331
- (0, import_class_validator11.IsNotEmpty)({ message: "Please enter account status." })
361
+ (0, import_class_validator12.IsNotEmpty)({ message: "Please enter account status." })
332
362
  ], CreateSubAdminDto.prototype, "accountStatus", 2);
333
363
 
334
364
  // src/modules/user/subadmin/dto/update-subadmin-status.dto.ts
335
- var import_class_validator12 = require("class-validator");
365
+ var import_class_validator13 = require("class-validator");
336
366
  var UpdateSubAdminAccountStatusDto = class {
337
367
  };
338
368
  __decorateClass([
339
- (0, import_class_validator12.IsString)()
369
+ (0, import_class_validator13.IsString)()
340
370
  ], UpdateSubAdminAccountStatusDto.prototype, "accountStatus", 2);
341
371
 
342
372
  // src/modules/user/subadmin/dto/update-subadmin.dto.ts
343
- var import_class_validator13 = require("class-validator");
373
+ var import_class_validator14 = require("class-validator");
344
374
  var UpdateSubAdminDto = class {
345
375
  };
346
376
  __decorateClass([
347
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter unique id." })
377
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter unique id." })
348
378
  ], UpdateSubAdminDto.prototype, "uniqueId", 2);
349
379
  __decorateClass([
350
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter username." })
380
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter username." })
351
381
  ], UpdateSubAdminDto.prototype, "userName", 2);
352
382
  __decorateClass([
353
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter first name." })
383
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter first name." })
354
384
  ], UpdateSubAdminDto.prototype, "firstName", 2);
355
385
  __decorateClass([
356
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter last name." })
386
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter last name." })
357
387
  ], UpdateSubAdminDto.prototype, "lastName", 2);
358
388
  __decorateClass([
359
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter email." })
389
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter email." })
360
390
  ], UpdateSubAdminDto.prototype, "email", 2);
361
391
  __decorateClass([
362
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter mobile number." })
392
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter mobile number." })
363
393
  ], UpdateSubAdminDto.prototype, "mobile", 2);
364
394
  __decorateClass([
365
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter the password." })
395
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter the password." })
366
396
  ], UpdateSubAdminDto.prototype, "password", 2);
367
397
  __decorateClass([
368
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter account type." })
398
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter account type." })
369
399
  ], UpdateSubAdminDto.prototype, "accountType", 2);
370
400
  __decorateClass([
371
- (0, import_class_validator13.IsNotEmpty)({ message: "Please enter account status." })
401
+ (0, import_class_validator14.IsNotEmpty)({ message: "Please enter account status." })
372
402
  ], UpdateSubAdminDto.prototype, "accountStatus", 2);
373
403
 
374
404
  // src/modules/question/pattern/pattern.ts
@@ -377,24 +407,24 @@ var QUESTION_PATTERN = {
377
407
  };
378
408
 
379
409
  // src/modules/question/dto/create-question.dto.ts
380
- var import_class_validator14 = require("class-validator");
410
+ var import_class_validator15 = require("class-validator");
381
411
  var CreateQuestionDto = class {
382
412
  };
383
413
  __decorateClass([
384
- (0, import_class_validator14.IsNotEmpty)({ message: "Please enter unique id." })
414
+ (0, import_class_validator15.IsNotEmpty)({ message: "Please enter unique id." })
385
415
  ], CreateQuestionDto.prototype, "questionId", 2);
386
416
  __decorateClass([
387
- (0, import_class_validator14.IsNotEmpty)({ message: "Please enter question." })
417
+ (0, import_class_validator15.IsNotEmpty)({ message: "Please enter question." })
388
418
  ], CreateQuestionDto.prototype, "question", 2);
389
419
  __decorateClass([
390
- (0, import_class_validator14.IsNotEmpty)({ message: "Please enter for whom the question is." })
420
+ (0, import_class_validator15.IsNotEmpty)({ message: "Please enter for whom the question is." })
391
421
  ], CreateQuestionDto.prototype, "questionFor", 2);
392
422
  __decorateClass([
393
- (0, import_class_validator14.IsNotEmpty)({ message: "Please enter options." })
423
+ (0, import_class_validator15.IsNotEmpty)({ message: "Please enter options." })
394
424
  ], CreateQuestionDto.prototype, "options", 2);
395
425
  __decorateClass([
396
- (0, import_class_validator14.IsOptional)(),
397
- (0, import_class_validator14.IsBoolean)({ message: "Whether the question status active" })
426
+ (0, import_class_validator15.IsOptional)(),
427
+ (0, import_class_validator15.IsBoolean)({ message: "Whether the question status active" })
398
428
  ], CreateQuestionDto.prototype, "isActive", 2);
399
429
 
400
430
  // src/adapters/tcp/user.tcp.adapter.ts
@@ -579,7 +609,7 @@ __decorateClass([
579
609
  ], BaseEntity.prototype, "deletedAt", 2);
580
610
 
581
611
  // src/entities/user.entity.ts
582
- var import_typeorm6 = require("typeorm");
612
+ var import_typeorm7 = require("typeorm");
583
613
 
584
614
  // src/entities/refresh-token.entity.ts
585
615
  var import_typeorm2 = require("typeorm");
@@ -787,6 +817,75 @@ FreelancerProfile = __decorateClass([
787
817
  (0, import_typeorm5.Entity)("freelancer_profiles")
788
818
  ], FreelancerProfile);
789
819
 
820
+ // src/entities/company-profile.entity.ts
821
+ var import_typeorm6 = require("typeorm");
822
+ var KindOfHire = /* @__PURE__ */ ((KindOfHire2) => {
823
+ KindOfHire2["FULLTIME"] = "FULLTIME";
824
+ KindOfHire2["SHORTTIME"] = "SHORTTIME";
825
+ KindOfHire2["BOTH"] = "BOTH";
826
+ return KindOfHire2;
827
+ })(KindOfHire || {});
828
+ var ModeOfHire = /* @__PURE__ */ ((ModeOfHire2) => {
829
+ ModeOfHire2["ONSITE"] = "ONSITE";
830
+ ModeOfHire2["REMOTE"] = "REMOTE";
831
+ ModeOfHire2["BOTH"] = "BOTH";
832
+ return ModeOfHire2;
833
+ })(ModeOfHire || {});
834
+ var FromUsOn = /* @__PURE__ */ ((FromUsOn2) => {
835
+ FromUsOn2["LINKEDIN"] = "LINKEDIN";
836
+ FromUsOn2["GOOGLE"] = "GOOGLE";
837
+ FromUsOn2["REFERRAL"] = "REFERRAL";
838
+ FromUsOn2["OTHER"] = "OTHER";
839
+ return FromUsOn2;
840
+ })(FromUsOn || {});
841
+ var CompanyProfile = class extends BaseEntity {
842
+ };
843
+ // individual index to find company profile by user
844
+ __decorateClass([
845
+ (0, import_typeorm6.Column)({ name: "user_id", type: "integer", nullable: true }),
846
+ (0, import_typeorm6.Index)()
847
+ ], CompanyProfile.prototype, "userId", 2);
848
+ __decorateClass([
849
+ (0, import_typeorm6.ManyToOne)(() => User, (user) => user.otps),
850
+ (0, import_typeorm6.JoinColumn)({ name: "user_id" })
851
+ ], CompanyProfile.prototype, "user", 2);
852
+ __decorateClass([
853
+ (0, import_typeorm6.Column)({ name: "company_name", type: "varchar", nullable: true })
854
+ ], CompanyProfile.prototype, "companyName", 2);
855
+ __decorateClass([
856
+ (0, import_typeorm6.Column)({ name: "skills", type: "text", nullable: true })
857
+ ], CompanyProfile.prototype, "skills", 2);
858
+ __decorateClass([
859
+ (0, import_typeorm6.Column)({ name: "required_freelancer", type: "varchar", nullable: true })
860
+ ], CompanyProfile.prototype, "requiredFreelancer", 2);
861
+ __decorateClass([
862
+ (0, import_typeorm6.Column)({
863
+ name: "kind_of_hiring",
864
+ type: "enum",
865
+ enum: KindOfHire,
866
+ nullable: true
867
+ })
868
+ ], CompanyProfile.prototype, "kindOfHiring", 2);
869
+ __decorateClass([
870
+ (0, import_typeorm6.Column)({
871
+ name: "mode_of_hire",
872
+ type: "enum",
873
+ enum: ModeOfHire,
874
+ nullable: true
875
+ })
876
+ ], CompanyProfile.prototype, "modeOfHire", 2);
877
+ __decorateClass([
878
+ (0, import_typeorm6.Column)({
879
+ name: "found_us_on",
880
+ type: "enum",
881
+ enum: FromUsOn,
882
+ nullable: true
883
+ })
884
+ ], CompanyProfile.prototype, "foundUsOn", 2);
885
+ CompanyProfile = __decorateClass([
886
+ (0, import_typeorm6.Entity)("company_profiles")
887
+ ], CompanyProfile);
888
+
790
889
  // src/entities/user.entity.ts
791
890
  var AccountType = /* @__PURE__ */ ((AccountType2) => {
792
891
  AccountType2["ADMIN"] = "ADMIN";
@@ -805,40 +904,40 @@ var AccountStatus = /* @__PURE__ */ ((AccountStatus2) => {
805
904
  var User = class extends BaseEntity {
806
905
  };
807
906
  __decorateClass([
808
- (0, import_typeorm6.Column)({ name: "unique_id", type: "varchar", unique: true })
907
+ (0, import_typeorm7.Column)({ name: "unique_id", type: "varchar", unique: true })
809
908
  ], User.prototype, "uniqueId", 2);
810
909
  __decorateClass([
811
- (0, import_typeorm6.Column)({ name: "username", type: "varchar", unique: true, nullable: true })
910
+ (0, import_typeorm7.Column)({ name: "username", type: "varchar", unique: true, nullable: true })
812
911
  ], User.prototype, "username", 2);
813
912
  __decorateClass([
814
- (0, import_typeorm6.Column)({ name: "first_name", type: "varchar", length: 100, nullable: true })
913
+ (0, import_typeorm7.Column)({ name: "first_name", type: "varchar", length: 100, nullable: true })
815
914
  ], User.prototype, "firstName", 2);
816
915
  __decorateClass([
817
- (0, import_typeorm6.Column)({ name: "last_name", type: "varchar", length: 100, nullable: true })
916
+ (0, import_typeorm7.Column)({ name: "last_name", type: "varchar", length: 100, nullable: true })
818
917
  ], User.prototype, "lastName", 2);
819
918
  __decorateClass([
820
- (0, import_typeorm6.Column)({ name: "date_of_birth", type: "date", nullable: true })
919
+ (0, import_typeorm7.Column)({ name: "date_of_birth", type: "date", nullable: true })
821
920
  ], User.prototype, "dateOfBirth", 2);
822
921
  __decorateClass([
823
- (0, import_typeorm6.Column)({ name: "gender", type: "varchar", length: 10, nullable: true })
922
+ (0, import_typeorm7.Column)({ name: "gender", type: "varchar", length: 10, nullable: true })
824
923
  ], User.prototype, "gender", 2);
825
924
  __decorateClass([
826
- (0, import_typeorm6.Column)({ name: "profile_picture_url", type: "text", nullable: true })
925
+ (0, import_typeorm7.Column)({ name: "profile_picture_url", type: "text", nullable: true })
827
926
  ], User.prototype, "profilePictureUrl", 2);
828
927
  __decorateClass([
829
- (0, import_typeorm6.Column)({ name: "email", type: "varchar", unique: true })
928
+ (0, import_typeorm7.Column)({ name: "email", type: "varchar", unique: true })
830
929
  ], User.prototype, "email", 2);
831
930
  __decorateClass([
832
- (0, import_typeorm6.Column)({ name: "mobile_code", type: "varchar", nullable: true })
931
+ (0, import_typeorm7.Column)({ name: "mobile_code", type: "varchar", nullable: true })
833
932
  ], User.prototype, "mobileCode", 2);
834
933
  __decorateClass([
835
- (0, import_typeorm6.Column)({ name: "mobile", type: "varchar", unique: true, nullable: true })
934
+ (0, import_typeorm7.Column)({ name: "mobile", type: "varchar", unique: true, nullable: true })
836
935
  ], User.prototype, "mobile", 2);
837
936
  __decorateClass([
838
- (0, import_typeorm6.Column)({ name: "password", type: "varchar" })
937
+ (0, import_typeorm7.Column)({ name: "password", type: "varchar" })
839
938
  ], User.prototype, "password", 2);
840
939
  __decorateClass([
841
- (0, import_typeorm6.Column)({
940
+ (0, import_typeorm7.Column)({
842
941
  name: "account_type",
843
942
  type: "enum",
844
943
  enum: AccountType,
@@ -846,7 +945,7 @@ __decorateClass([
846
945
  })
847
946
  ], User.prototype, "accountType", 2);
848
947
  __decorateClass([
849
- (0, import_typeorm6.Column)({
948
+ (0, import_typeorm7.Column)({
850
949
  name: "account_status",
851
950
  type: "enum",
852
951
  enum: AccountStatus,
@@ -854,42 +953,48 @@ __decorateClass([
854
953
  })
855
954
  ], User.prototype, "accountStatus", 2);
856
955
  __decorateClass([
857
- (0, import_typeorm6.Column)({ name: "is_email_verified", type: "boolean", default: false })
956
+ (0, import_typeorm7.Column)({ name: "is_email_verified", type: "boolean", default: false })
858
957
  ], User.prototype, "isEmailVerified", 2);
859
958
  __decorateClass([
860
- (0, import_typeorm6.Column)({ name: "is_mobile_verified", type: "boolean", default: false })
959
+ (0, import_typeorm7.Column)({ name: "is_mobile_verified", type: "boolean", default: false })
861
960
  ], User.prototype, "isMobileVerified", 2);
862
961
  __decorateClass([
863
- (0, import_typeorm6.Column)({
962
+ (0, import_typeorm7.Column)({
864
963
  name: "last_login_at",
865
964
  type: "timestamp with time zone",
866
965
  nullable: true
867
966
  })
868
967
  ], User.prototype, "lastLoginAt", 2);
869
968
  __decorateClass([
870
- (0, import_typeorm6.Column)({ name: "last_login_ip", type: "varchar", nullable: true })
969
+ (0, import_typeorm7.Column)({ name: "last_login_ip", type: "varchar", nullable: true })
871
970
  ], User.prototype, "lastLoginIp", 2);
872
971
  __decorateClass([
873
- (0, import_typeorm6.OneToMany)(() => RefreshToken, (token) => token.user)
972
+ (0, import_typeorm7.OneToMany)(() => RefreshToken, (token) => token.user)
874
973
  ], User.prototype, "refreshTokens", 2);
875
974
  __decorateClass([
876
- (0, import_typeorm6.OneToMany)(() => Otp, (otp) => otp.user)
975
+ (0, import_typeorm7.OneToMany)(() => Otp, (otp) => otp.user)
877
976
  ], User.prototype, "otps", 2);
878
977
  __decorateClass([
879
- (0, import_typeorm6.OneToMany)(() => ResumeParserLog, (resumeParser) => resumeParser.user)
978
+ (0, import_typeorm7.OneToMany)(() => ResumeParserLog, (resumeParser) => resumeParser.user)
880
979
  ], User.prototype, "resumeParserLogs", 2);
881
980
  __decorateClass([
882
- (0, import_typeorm6.OneToOne)(
981
+ (0, import_typeorm7.OneToOne)(
883
982
  () => FreelancerProfile,
884
983
  (freelancerProfile) => freelancerProfile.user
885
984
  )
886
985
  ], User.prototype, "freelancerProfile", 2);
986
+ __decorateClass([
987
+ (0, import_typeorm7.OneToOne)(
988
+ () => CompanyProfile,
989
+ (companyProfile) => companyProfile.user
990
+ )
991
+ ], User.prototype, "companyProfile", 2);
887
992
  User = __decorateClass([
888
- (0, import_typeorm6.Entity)("users")
993
+ (0, import_typeorm7.Entity)("users")
889
994
  ], User);
890
995
 
891
996
  // src/entities/question.entity.ts
892
- var import_typeorm7 = require("typeorm");
997
+ var import_typeorm8 = require("typeorm");
893
998
  var QuestionFor = /* @__PURE__ */ ((QuestionFor2) => {
894
999
  QuestionFor2["CLIENT"] = "CLIENT";
895
1000
  QuestionFor2["FREELANCER"] = "FREELANCER";
@@ -898,16 +1003,16 @@ var QuestionFor = /* @__PURE__ */ ((QuestionFor2) => {
898
1003
  var Question = class extends BaseEntity {
899
1004
  };
900
1005
  __decorateClass([
901
- (0, import_typeorm7.Column)({ name: "question", type: "varchar" })
1006
+ (0, import_typeorm8.Column)({ name: "question", type: "varchar" })
902
1007
  ], Question.prototype, "question", 2);
903
1008
  __decorateClass([
904
- (0, import_typeorm7.Column)({ name: "hint", type: "varchar", nullable: true })
1009
+ (0, import_typeorm8.Column)({ name: "hint", type: "varchar", nullable: true })
905
1010
  ], Question.prototype, "hint", 2);
906
1011
  __decorateClass([
907
- (0, import_typeorm7.Column)({ name: "slug", type: "varchar", nullable: true, unique: true })
1012
+ (0, import_typeorm8.Column)({ name: "slug", type: "varchar", nullable: true, unique: true })
908
1013
  ], Question.prototype, "slug", 2);
909
1014
  __decorateClass([
910
- (0, import_typeorm7.Column)({
1015
+ (0, import_typeorm8.Column)({
911
1016
  name: "question_for",
912
1017
  type: "enum",
913
1018
  enum: QuestionFor,
@@ -915,92 +1020,24 @@ __decorateClass([
915
1020
  })
916
1021
  ], Question.prototype, "questionFor", 2);
917
1022
  __decorateClass([
918
- (0, import_typeorm7.Column)({ name: "type", type: "varchar", nullable: true })
1023
+ (0, import_typeorm8.Column)({ name: "type", type: "varchar", nullable: true })
919
1024
  ], Question.prototype, "type", 2);
920
1025
  __decorateClass([
921
- (0, import_typeorm7.Column)({ name: "options", type: "jsonb", nullable: true })
1026
+ (0, import_typeorm8.Column)({ name: "options", type: "jsonb", nullable: true })
922
1027
  ], Question.prototype, "options", 2);
923
1028
  __decorateClass([
924
- (0, import_typeorm7.Column)({ name: "is_active", type: "boolean", default: false })
1029
+ (0, import_typeorm8.Column)({ name: "is_active", type: "boolean", default: false })
925
1030
  ], Question.prototype, "isActive", 2);
926
1031
  Question = __decorateClass([
927
- (0, import_typeorm7.Entity)("questions")
1032
+ (0, import_typeorm8.Entity)("questions")
928
1033
  ], Question);
929
-
930
- // src/entities/company-profile.entity.ts
931
- var import_typeorm8 = require("typeorm");
932
- var KindOfHire = /* @__PURE__ */ ((KindOfHire2) => {
933
- KindOfHire2["FULLTIME"] = "FULLTIME";
934
- KindOfHire2["SHORTTIME"] = "SHORTTIME";
935
- KindOfHire2["BOTH"] = "BOTH";
936
- return KindOfHire2;
937
- })(KindOfHire || {});
938
- var ModeOfHire = /* @__PURE__ */ ((ModeOfHire2) => {
939
- ModeOfHire2["ONSITE"] = "ONSITE";
940
- ModeOfHire2["REMOTE"] = "REMOTE";
941
- ModeOfHire2["BOTH"] = "BOTH";
942
- return ModeOfHire2;
943
- })(ModeOfHire || {});
944
- var FromUsOn = /* @__PURE__ */ ((FromUsOn2) => {
945
- FromUsOn2["LINKEDIN"] = "LINKEDIN";
946
- FromUsOn2["GOOGLE"] = "GOOGLE";
947
- FromUsOn2["REFERRAL"] = "REFERRAL";
948
- FromUsOn2["OTHER"] = "OTHER";
949
- return FromUsOn2;
950
- })(FromUsOn || {});
951
- var CompanyProfile = class extends BaseEntity {
952
- };
953
- // individual index to find company profile by user
954
- __decorateClass([
955
- (0, import_typeorm8.Column)({ name: "user_id", type: "integer", nullable: true }),
956
- (0, import_typeorm8.Index)()
957
- ], CompanyProfile.prototype, "userId", 2);
958
- __decorateClass([
959
- (0, import_typeorm8.ManyToOne)(() => User, (user) => user.otps),
960
- (0, import_typeorm8.JoinColumn)({ name: "user_id" })
961
- ], CompanyProfile.prototype, "user", 2);
962
- __decorateClass([
963
- (0, import_typeorm8.Column)({ name: "company_name", type: "varchar", nullable: true })
964
- ], CompanyProfile.prototype, "companyName", 2);
965
- __decorateClass([
966
- (0, import_typeorm8.Column)({ name: "skills", type: "text", nullable: true })
967
- ], CompanyProfile.prototype, "skills", 2);
968
- __decorateClass([
969
- (0, import_typeorm8.Column)({ name: "required_freelancer", type: "varchar", nullable: true })
970
- ], CompanyProfile.prototype, "requiredFreelancer", 2);
971
- __decorateClass([
972
- (0, import_typeorm8.Column)({
973
- name: "kind_of_hiring",
974
- type: "enum",
975
- enum: KindOfHire,
976
- nullable: true
977
- })
978
- ], CompanyProfile.prototype, "kindOfHiring", 2);
979
- __decorateClass([
980
- (0, import_typeorm8.Column)({
981
- name: "mode_of_hire",
982
- type: "enum",
983
- enum: ModeOfHire,
984
- nullable: true
985
- })
986
- ], CompanyProfile.prototype, "modeOfHire", 2);
987
- __decorateClass([
988
- (0, import_typeorm8.Column)({
989
- name: "found_us_on",
990
- type: "enum",
991
- enum: FromUsOn,
992
- nullable: true
993
- })
994
- ], CompanyProfile.prototype, "foundUsOn", 2);
995
- CompanyProfile = __decorateClass([
996
- (0, import_typeorm8.Entity)("company_profiles")
997
- ], CompanyProfile);
998
1034
  // Annotate the CommonJS export names for ESM import in node:
999
1035
  0 && (module.exports = {
1000
1036
  AUTHENTICATION_PATTERN,
1001
1037
  AccountStatus,
1002
1038
  AccountType,
1003
1039
  BaseEntity,
1040
+ ClientCreateAccountDto,
1004
1041
  ClientProfileQuestionDto,
1005
1042
  CompanyProfile,
1006
1043
  CreateQuestionDto,