sigo-entities 0.0.219 → 0.0.221

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.d.mts CHANGED
@@ -1,5 +1,3 @@
1
- import { ObjectId } from 'mongodb';
2
-
3
1
  declare class DestinatarioDTO {
4
2
  Identificacion: string;
5
3
  Nombre: string;
@@ -1777,7 +1775,7 @@ declare class UnidadMedidaDTO {
1777
1775
  }
1778
1776
 
1779
1777
  declare class BaremosColombiaENTITY {
1780
- _id?: ObjectId | string;
1778
+ _id?: string;
1781
1779
  foreignKey: string;
1782
1780
  Obra: string;
1783
1781
  Contrato: string;
package/dist/index.d.ts CHANGED
@@ -1,5 +1,3 @@
1
- import { ObjectId } from 'mongodb';
2
-
3
1
  declare class DestinatarioDTO {
4
2
  Identificacion: string;
5
3
  Nombre: string;
@@ -1777,7 +1775,7 @@ declare class UnidadMedidaDTO {
1777
1775
  }
1778
1776
 
1779
1777
  declare class BaremosColombiaENTITY {
1780
- _id?: ObjectId | string;
1778
+ _id?: string;
1781
1779
  foreignKey: string;
1782
1780
  Obra: string;
1783
1781
  Contrato: string;
package/dist/index.js CHANGED
@@ -9546,7 +9546,11 @@ var BaremosColombiaENTITY = class {
9546
9546
  };
9547
9547
  __decorateClass([
9548
9548
  (0, import_class_transformer167.Expose)(),
9549
- (0, import_class_transformer167.Transform)(({ value }) => typeof value === "string" ? new import_mongodb.ObjectId(value) : value, { toClassOnly: true })
9549
+ (0, import_class_transformer167.Transform)(({ value }) => {
9550
+ if (value instanceof import_mongodb.ObjectId) return value;
9551
+ if (typeof value === "string") return new import_mongodb.ObjectId(value);
9552
+ return value;
9553
+ }, { toClassOnly: true })
9550
9554
  ], BaremosColombiaENTITY.prototype, "_id", 2);
9551
9555
  __decorateClass([
9552
9556
  (0, import_class_validator167.IsString)({ message: "debe ser un texto" }),
package/dist/index.mjs CHANGED
@@ -9293,7 +9293,11 @@ var BaremosColombiaENTITY = class {
9293
9293
  };
9294
9294
  __decorateClass([
9295
9295
  Expose166(),
9296
- Transform6(({ value }) => typeof value === "string" ? new ObjectId(value) : value, { toClassOnly: true })
9296
+ Transform6(({ value }) => {
9297
+ if (value instanceof ObjectId) return value;
9298
+ if (typeof value === "string") return new ObjectId(value);
9299
+ return value;
9300
+ }, { toClassOnly: true })
9297
9301
  ], BaremosColombiaENTITY.prototype, "_id", 2);
9298
9302
  __decorateClass([
9299
9303
  IsString141({ message: "debe ser un texto" }),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sigo-entities",
3
- "version": "0.0.219",
3
+ "version": "0.0.221",
4
4
  "description": "Desarrollo de modelos de datos SIGO",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",