Skip to content
Malouf Docs

Brookside

Product Data in Strapi

Category

Each Category will have Subcategories, which in turn will have Products linked to them. All you need to worry about is adding/linking the subcategories to the category. When you click on a category or create a new one, there will be a data field called “subcategories” and the dropdown says “Add relation”. Just click on the subcategory that you want and it will be linked. (Please note, there won’t be actual web pages for the categories, these are more of labels if anything. They are used in the header navigation)

Subcategory

Each subcategory will have multiple products added/linked to them. It is the same process as adding a subcategory to a category. Just go to the “products” data field and the dropdown will say “Add relation”. Just select all of the products that you want to belong in that subcategory. The subcategories will have actual web pages for them. For example, the “Beds” subcategory page is accessible from “brooksidehomedesigns.com/beds” and that page will display all of the products in that subcategory.

Product

Data Field: sizes

This data field is used to add the measurments table and its data. The options/values for “sizes”, “width”, “height”, and “length” will need to be added inside of square brackets [] and be enclosed in quotation marks. Separate each one with a comma ,.

For the “width”, “height”, and “length” sections, each position that its in on the list, correlates to the same position for the “sizes” choices. What I mean by this, like in the example below, the “Sofa” size is the first of the list options for “sizes”, and in “length”, “88.5” is the first in the list of options for that. This means that the Sofa has a length of 88.5. So if you have 6 “sizes” options, you will need to also have 6 “width”, “height”, and “length” options. See the example below for help as well. You can even just copy and paste this as a template and just edit what you need to.

PLEASE NOTE: It is VERY important that the data be added the same exact way as the example shown below.

{
  "data": {
    "sizes": [
      "Sofa",
      "Loveseat"
    ],
    "width": [
      "37",
      "37"
    ],
    "height": [
      "35",
      "35"
    ],
    "length": [
      "88.5",
      "64"
    ]
  }
}

Data Field: colors

This data field is used to add the color options for the product. The options/values for “colors” will need to be added inside of square brackets [] and be enclosed in quotation marks. Separate each one with a comma ,.

You will need to use the Hex Color Codes for the colors that you want.

PLEASE NOTE: It is VERY important that the data be added the same exact way as the example shown below.

{
  "data": {
    "colors": [
      "#444957",
      "#282828",
      "#B1ABA8"
    ]
  }
}

Data Field: subcategory

All you need to do here is add the subcategory that it is in.

Data Fields: warranty, materials_text, and care_instructions

These three data fields are the ONLY ONES where you will need to use a <h3></h3> tag for the headers and for the paragraphs you will need to use the paragraph tag <p></p>. Please see the examples below for how to use them. If you want a clickable link, you will need to use the anchor tags <a href=''></a> with the email or url going inside the “href=”” quotes.

warranty Example:

<h3>Limited Warranty</h3>
<p>1-Year Limited Warranty</p>
<p>Limited warranty covers defects in material or workmanship with certain exceptions. Warranty coverage begins at date of purchase and applies to original purchaser only. At its discretion, the company will repair, replace or refund any product that proves to be defective in materials or workmanship.</p>
<h3>How to get Service</h3>
<p>Email <a href="mailto:[email protected]">[email protected]</a> to submit your warranty claim. Please keep your receipt so that we may process your warranty request.</p>

materials_text Example:

<p>Body: 82% Polyurethane Foam Pad, 18% Textile Fiber</p>
<p>Seat Cushions: 85% Polyurethane Foam Pad, 15% Polyester Fiber Batting</p>
<p>Pillow: 100% Polyester Fiber</p>