pim-import 3.4.6 → 4.2.0

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.
@@ -1969,16 +1969,17 @@ export const generateTechSpecPdf = async (topicProductId: string) => {
1969
1969
  );
1970
1970
  log(`pdpSiteUrl: ${pdpSiteUrl}`);
1971
1971
  const contents = {
1972
- header: {
1973
- right: "Technical Specifications",
1974
- },
1972
+ // header: {
1973
+ // right: "Technical Specifications",
1974
+ // },
1975
1975
  footer: {
1976
- left: pdpSiteUrl,
1977
- right:
1978
- "www.flos.com - " +
1979
- (topicCatalogIds.includes("OUTDOOR")
1980
- ? "flos.outdoor@flos.com"
1981
- : "info@flos.com"),
1976
+ topLeft: `<a style="text-decoration: none; color:#000" href="${pdpSiteUrl}">${pdpSiteUrl}</a>`,
1977
+ topRight: topicProductId,
1978
+ bottomLeft: ``,
1979
+ bottomRight: ``,
1980
+ mail: topicCatalogIds.includes("OUTDOOR")
1981
+ ? "flos.outdoor@flos.com"
1982
+ : "info@flos.com",
1982
1983
  },
1983
1984
  };
1984
1985
 
@@ -111,6 +111,7 @@ export interface GenericData {
111
111
  value_da: string;
112
112
  value_ru: string;
113
113
  othersData: OthersData;
114
+ assistant?: string;
114
115
  }
115
116
  export interface OthersData {}
116
117
  export interface LastModified {
@@ -29,7 +29,7 @@ export declare const reindexFamilies: (offset?: number, limit?: number, catalogC
29
29
  s3FilePath?: string | undefined;
30
30
  total?: number | undefined;
31
31
  }>;
32
- export declare const reindexFamily: (topicFamilyEntryId: string) => Promise<{
32
+ export declare const reindexFamily: (topicFamilyEntryId: string) => Promise<false | {
33
33
  objectID: string;
34
34
  names: CfLocalizedEntryField;
35
35
  code: string;
package/types/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export { init as initPim } from "./pim/config";
2
- export { init as initContentful, initBaseEntries, deletePages, deleteEntries, getEntryByID, getTopicPage, } from "./libs/contentful";
2
+ export { init as initContentful, initBaseEntries, deletePages, deleteEntries, getEntryByID, getTopicPage, getEntries, } from "./libs/contentful";
3
3
  export { init as initS3, upload as uploadS3, saveJsonToS3, getFileFromS3, savePDFToS3, } from "./libs/s3";
4
4
  export { importDictionaryFields, importDictionaryIcons, importDictionaryProductLine, importDictionaryProductSubLine, } from "./pim/methods/dictionary";
5
5
  export { importCategories } from "./pim/methods/catalogs";
@@ -1,4 +1,5 @@
1
- import type { Entry, CreateEntryProps } from "contentful-management/dist/typings/entities/entry";
1
+ import type { Entry, CreateEntryProps, EntryProps } from "contentful-management/dist/typings/entities/entry";
2
+ import type { QueryOptions } from "contentful-management/dist/typings/common-types";
2
3
  import { Environment, Locale, CreateAssetProps } from "contentful-management/types";
3
4
  import { ContentfulLocale, AvailableCatalogs, TopicDetailsResponse, AssetPropFields, OtherFilters, WrapperImageFields } from "../types";
4
5
  import { GenericData } from "../resources/ProductDetails";
@@ -57,3 +58,4 @@ export declare const createWrapperImgix: (id: string, data: WrapperImageFields)
57
58
  export declare const archiveEntry: (entry: Entry, isProduct?: boolean) => Promise<Entry>;
58
59
  export declare const getDesignerData: (designer: GenericData) => Promise<CreateEntryProps<import("contentful-management/types").KeyValueMap>>;
59
60
  export declare const addDesignerData: (data: any, designer: GenericData, manyReferences?: boolean) => Promise<any>;
61
+ export declare const getEntries: (opts: QueryOptions) => Promise<import("contentful-management/dist/typings/common-types").Collection<import("contentful-management/dist/typings/entities/entry").Entry, EntryProps<Record<string, any>>>>;
@@ -1,11 +1,17 @@
1
- /// <reference types="node" />
2
- interface Columns {
1
+ interface HeaderColumns {
3
2
  left?: string;
4
3
  right?: string;
5
4
  }
5
+ interface FooterColumns {
6
+ topLeft?: string;
7
+ topRight?: string;
8
+ bottomLeft?: string;
9
+ bottomRight?: string;
10
+ mail?: string;
11
+ }
6
12
  interface PDFHeaderAndFooter {
7
- header?: Columns;
8
- footer?: Columns;
13
+ header?: HeaderColumns;
14
+ footer?: FooterColumns;
9
15
  }
10
- export declare const generatePDFByUrl: (url: string, path?: string, contents?: PDFHeaderAndFooter | undefined) => Promise<Buffer | null>;
16
+ export declare const generatePDFByUrl: (url: string, path?: string, contents?: PDFHeaderAndFooter | undefined) => Promise<any>;
11
17
  export {};
@@ -110,6 +110,7 @@ export interface GenericData {
110
110
  value_da: string;
111
111
  value_ru: string;
112
112
  othersData: OthersData;
113
+ assistant?: string;
113
114
  }
114
115
  export interface OthersData {
115
116
  }