Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

NOTE: Data Model is still in development stage and might change on upcoming days

GridProduct

interface GridProduct {
  ProductId: string;
  Tenant: string;
  Customers?: string[];
  // Main default details
  ProductShortDescription?: Array<{
    CountryId: string;
    IsoLanguageId: string;
    ProductShortDescription: string;
  }>;
  ProductInternalName?: Array<{
    CountryId: string;
    IsoLanguageId: string;
    ProductInternalName: string;
  }>;
  IntroductionDate?: string; // Start Date (optional) - main date added on RelatedProduct(Variant)
  PlannedAbandonmentDate?: string; // End Date (optional) - main date added on RelatedProduct(Variant)
  StorageInstructions?: Array<{
    CountryId: string;
    IsoLanguageId: string;
    StorageInstructions: string;
  }>;
  ShellLifeDays?: number;
  ConsumerStorageInstruction?: Array<{
    CountryId: string;
    IsoLanguageId: string;
    ConsumerStorageInstruction: string;
  }>;
  ProductShippingInstruction?: Array<{
    CountryId: string;
    IsoLanguageId: string;
    ProductShippingInstruction: string;
  }>;
  GlobalTradeItemNumber?: string;
  GtinName?: string;
  EuropeanArticleNumber?: string;
  UniversalProductCode?: string;

  // Array of translation
  ProductName: Array<{
    CountryId: string;
    IsoLanguageId: string;
    ProductName: string;
  }>;

  // Array of translation
  ProductDescription: Array<{
    CountryId: string;
    IsoLanguageId: string;
    ProductDescription: string;
  }>;

  // Variants
  Variants: Array<{
    Id: string; // Item variant Id
    ProductId: string; // Parent product Id

    // Item variant name (optional)
    ProductName?: Array<{
      CountryId: string;
      IsoLanguageId: string;
      ProductName: string;
    }>;

    PeriodStartDate: string;
    PeriodEndDate: string;

    // Added custom field for variants
    Color?: string;
    Style?: string;
    Size?: string;
  }>;

  Brand?: Array<{
    CountryId: string;
    IsoLanguageId: string;
    BrandName: string;
    BrandDescription?: string;
    BrandMark?: string;
    BrandTrademark?: string;
    BrandLogo?: string;
  }>;

  // Array of translation
  ProductStatus: Array<{
    ProductStatus: ProductStatusEnum; // Ex. Active OR Inactive
    CountryId: string;
    IsoLanguageId: string;
    StoreId?: string;
    PeriodStartDate?: string;
    PeriodEndDate?: string;
    ProductStatusNote?: string;
  }>;

  // Equivalent to productDetails in GPF used for filters and data display
  ProductFeature?: Array<{
    Id: string; // SKU or variant Id
    ProductFeatureType: string; // Key of productDetails in GPF
    CountryId: string;
    IsoLanguageId: string;
    ProductFeatureValue: string;
  }>;

  // Product Price based on type
  ProductPriceList: Array<{
    Id: string; // SKU or variant Id
    PriceListType: PriceListTypeEnum; // 'Standard' OR 'Promotional'
    StoreId?: string;
    CountryId: string;
    IsoLanguageId: string;
    IsoCurrencyCode: string;
    PricingUomId?: string;
    PeriodStartTimestamp: string;
    PeriodEndTimestamp: string;
    SuggestedRetailPrice?: number;
    ListPrice: number;
  }>;

  // Images and links
  CatalogPageLocationProduct: Array<{
    Id: string; // SKU or variant Id
    ProductId: string; // Parent Id
    Catalog?: string; // Ex. Client name?
    CatalogPage?: string; // Ex. Root URL of kmart
    CatalogPageLocation?: string; // Ex. Product URL appended to root URL of Kmart
    CatalogPageLocationProduct: string; // Entire URL value
  }>;

  // Product categories (Converted semi-colon separated into array)
  ProductType: Array<ProductTypeInterface>;

  // Product Tags
  ProductLabel?: Array<{
    CountryId: string;
    IsoLanguageId: string;
    ProductLabel: string; // Ex. [Online Exclusive]
  }>;

  // Product Promotion
  ProductPromotion?: {
    PromotionId: string; // Referenced from Promotions Index or external data
    PeriodStartTimestamp: string;
    PeriodEndTimestamp: string;
  };

  // Product Quantity
  ProductItemQuantity?: Array<{
    Id: string; // SKU or variant Id
    StoreId?: string;
    ProductItemQuantityStartDate: string;
    ProductItemQuantityEndDate: string;
    ProductItemQuantity: number;
  }>;

  ProductVendor?: Array<{
    VendorId: string;
    ProductVendor: string;
    PeriodStartDate: string;
    PeriodEndDate: string;
  }>;
}


Other interface and enums:

enum PriceListTypeEnum {
  Standard = 'Standard',
  Promotional = 'Promotional',
}

enum ProductStatusEnum {
  Active = 'Active',
  Inactive = 'Inactive',
  Discontinued = 'Discontinued',
  Dormant = 'Dormant',
  Frozen = 'Frozen',
  Replaced = 'Replaced',
  Obsolete = 'Obsolete',
  Abandoned = 'Abandoned',
  Blocked = 'Blocked',
}

interface ProductTypeInterface {
  Key: string; // Ex. Key1>Key2
  CountryId: string;
  IsoLanguageId: string;
  ProductType: string; // Ex. Furniture>Living Room
}


  • No labels