docta-package 1.2.58 → 1.2.59

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.
@@ -12,15 +12,15 @@ const location_1 = require("./location");
12
12
  // Base DTO for everyone
13
13
  class DoctorOutputDto {
14
14
  constructor(doctor) {
15
- var _a;
16
- this.id = doctor.id.toString();
15
+ var _a, _b, _c;
16
+ this.id = (_b = ((_a = doctor.id) !== null && _a !== void 0 ? _a : doctor._id)) === null || _b === void 0 ? void 0 : _b.toString();
17
17
  this.user = new user_1.UserOutputDto(doctor.user);
18
18
  this.name = doctor.name;
19
19
  this.specialty = new specialty_1.SpecialtyOutputDto(doctor.specialty);
20
20
  this.slug = doctor.slug;
21
21
  this.biography = doctor.biography || null;
22
22
  this.isActive = doctor.isActive;
23
- this.consultationFeePerHour = (_a = doctor.consultationFeePerHour) !== null && _a !== void 0 ? _a : null;
23
+ this.consultationFeePerHour = (_c = doctor.consultationFeePerHour) !== null && _c !== void 0 ? _c : null;
24
24
  this.isVerified = doctor.isVerified;
25
25
  this.isVisible = doctor.isVisible;
26
26
  this.photo = doctor.photo || null;
@@ -5,7 +5,8 @@ const user_1 = require("./user");
5
5
  // Base DTO for everyone
6
6
  class ExpertiseOutputDto {
7
7
  constructor(expertise) {
8
- this.id = expertise.id.toString();
8
+ var _a, _b;
9
+ this.id = (_b = ((_a = expertise.id) !== null && _a !== void 0 ? _a : expertise._id)) === null || _b === void 0 ? void 0 : _b.toString();
9
10
  this.en = {
10
11
  name: expertise.en.name,
11
12
  description: expertise.en.description || null,
@@ -5,7 +5,8 @@ const user_1 = require("./user");
5
5
  // Base DTO for everyone
6
6
  class PatientOutputDto {
7
7
  constructor(patient) {
8
- this.id = patient.id.toString();
8
+ var _a, _b;
9
+ this.id = (_b = ((_a = patient.id) !== null && _a !== void 0 ? _a : patient._id)) === null || _b === void 0 ? void 0 : _b.toString();
9
10
  this.user = new user_1.UserOutputDto(patient.user);
10
11
  this.dob = patient.dob || null;
11
12
  this.phoneNumber = patient.phoneNumber || null;
@@ -5,7 +5,8 @@ const user_1 = require("./user");
5
5
  // Base DTO for everyone
6
6
  class SpecialtyOutputDto {
7
7
  constructor(specialty) {
8
- this.id = specialty.id.toString();
8
+ var _a, _b;
9
+ this.id = (_b = ((_a = specialty.id) !== null && _a !== void 0 ? _a : specialty._id)) === null || _b === void 0 ? void 0 : _b.toString();
9
10
  this.en = {
10
11
  name: specialty.en.name,
11
12
  description: specialty.en.description || null,
@@ -4,7 +4,8 @@ exports.LoggedInUserOutputDto = exports.UserAdminOutputDto = exports.UserOutputD
4
4
  // Base DTO for everyone
5
5
  class UserOutputDto {
6
6
  constructor(user) {
7
- this.id = user.id.toString();
7
+ var _a, _b;
8
+ this.id = (_b = ((_a = user.id) !== null && _a !== void 0 ? _a : user._id)) === null || _b === void 0 ? void 0 : _b.toString();
8
9
  this.name = user.name;
9
10
  this.email = user.email;
10
11
  this.role = user.role;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "docta-package",
3
- "version": "1.2.58",
3
+ "version": "1.2.59",
4
4
  "description": "This package will contail all the required files to run the docta micro-service app",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",