@punks/backend-entity-manager 0.0.450 → 0.0.451

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.
@@ -76,7 +76,7 @@ export type ImportEntry<TSheetItem, TEntityId> = {
76
76
  export interface IEntitySerializer<TEntity, TEntityId, TEntitySearchParameters, TSheetItem, TPayload = unknown> {
77
77
  export(filters?: TEntitySearchParameters): Promise<TSheetItem[]>;
78
78
  import(items: TSheetItem[], payload?: TPayload): Promise<void>;
79
- serialize(items: TSheetItem[], format: EntitySerializationFormat): Promise<EntityExportFile>;
79
+ serialize(items: TSheetItem[], format: EntitySerializationFormat, payload?: TPayload): Promise<EntityExportFile>;
80
80
  parse<TPayload>(data: Buffer, format: EntitySerializationFormat, payload?: TPayload): Promise<ImportEntry<TSheetItem, TEntityId>[]>;
81
81
  createSample(format: EntitySerializationFormat): Promise<EntityExportFile>;
82
82
  }
package/dist/esm/index.js CHANGED
@@ -906,8 +906,10 @@ class EntitiesExportCommand {
906
906
  },
907
907
  };
908
908
  }
909
- async buildExportFile(data, format) {
910
- return await this.services.resolveSerializer().serialize(data, format);
909
+ async buildExportFile(data, format, payload) {
910
+ return await this.services
911
+ .resolveSerializer()
912
+ .serialize(data, format, payload);
911
913
  }
912
914
  async uploadExportFile(file) {
913
915
  await this.bucket.fileUpload({