@punks/backend-entity-manager 0.0.405 → 0.0.407

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.
@@ -1,3 +1,4 @@
1
+ /// <reference types="node" />
1
2
  import { DataExportFile, DataExportInput } from "./types";
2
3
  import { EntityManagerRegistry } from "../../ioc/registry";
3
4
  export declare class DataExportService {
@@ -5,10 +6,15 @@ export declare class DataExportService {
5
6
  constructor(registry: EntityManagerRegistry);
6
7
  exportData<TSheetItem>(data: TSheetItem[], input: DataExportInput<TSheetItem>): Promise<{
7
8
  downloadUrl: import("../../../../abstractions/files").FileProviderDownloadUrl;
8
- file: DataExportFile;
9
+ file: {
10
+ fileName: string;
11
+ content: Buffer;
12
+ contentType: string;
13
+ };
9
14
  }>;
10
- extractData<TSheetItem>(data: TSheetItem[], input: DataExportInput<TSheetItem>): Promise<DataExportFile>;
15
+ extractData<TSheetItem>(data: TSheetItem[], input: Omit<DataExportInput<TSheetItem>, "fileName">): Promise<DataExportFile>;
11
16
  private uploadExportFile;
17
+ private buildExportFileName;
12
18
  private buildExportFilePath;
13
19
  private get defaultFileProvider();
14
20
  private get defaultBucketProvider();
@@ -1,6 +1,7 @@
1
1
  /// <reference types="node" />
2
2
  export type DataExportInput<TSheetItem> = {
3
- name: string;
3
+ dataName: string;
4
+ fileName: string;
4
5
  columns: DataSerializerColumnDefinition<TSheetItem>[];
5
6
  format: DataSerializationFormat;
6
7
  };
package/dist/index.d.ts CHANGED
@@ -2328,7 +2328,8 @@ declare class EmailService {
2328
2328
  }
2329
2329
 
2330
2330
  type DataExportInput<TSheetItem> = {
2331
- name: string;
2331
+ dataName: string;
2332
+ fileName: string;
2332
2333
  columns: DataSerializerColumnDefinition<TSheetItem>[];
2333
2334
  format: DataSerializationFormat;
2334
2335
  };
@@ -2355,10 +2356,15 @@ declare class DataExportService {
2355
2356
  constructor(registry: EntityManagerRegistry);
2356
2357
  exportData<TSheetItem>(data: TSheetItem[], input: DataExportInput<TSheetItem>): Promise<{
2357
2358
  downloadUrl: FileProviderDownloadUrl;
2358
- file: DataExportFile;
2359
+ file: {
2360
+ fileName: string;
2361
+ content: Buffer;
2362
+ contentType: string;
2363
+ };
2359
2364
  }>;
2360
- extractData<TSheetItem>(data: TSheetItem[], input: DataExportInput<TSheetItem>): Promise<DataExportFile>;
2365
+ extractData<TSheetItem>(data: TSheetItem[], input: Omit<DataExportInput<TSheetItem>, "fileName">): Promise<DataExportFile>;
2361
2366
  private uploadExportFile;
2367
+ private buildExportFileName;
2362
2368
  private buildExportFilePath;
2363
2369
  private get defaultFileProvider();
2364
2370
  private get defaultBucketProvider();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@punks/backend-entity-manager",
3
- "version": "0.0.405",
3
+ "version": "0.0.407",
4
4
  "description": "",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",