Creating a Product Block
The third type of blocks in Headless CMS OneEntry is "For product block".
1. Creating a Block
To create a block of type "For product block", you need to enter the block name in the Name field, select "For product block" from the dropdown list in the Type field, and enter a unique
2. Editing a Block
To edit a block, you need to click the "Edit" button in the "Actions" column of the blocks table.
For blocks of type "For product block", there are four tabs available during editing:
- Basic data
- Attributes
- Categories
- Linked pages
Basic Data
The "Basic data" tab consists of the following forms:
- Name - change the block name
- Marker - change the Markerof the block
- Individual settings:
- Quantity - change the number of items in the block (only integer values are allowed)
- Sorting type of block items - you can sort either by date or by name
- Sorting order of block items - three options: ascending, descending, and no sorting
- Number of items per row - change the number of items in one row of the block (only integer values are allowed)
- Additional conditions - allows adding conditions for sorting blocks. To apply sorting, you need to activate the "Additional conditions" checkbox and select a sorting option (By name, price, and date). After that, enter the sorting values:
- for name - enter the product name. As soon as you start typing the product name, a list of products matching the entered value will appear, from which you can select the desired product.
- for price - two input fields: from the lower price and upper price
- for date - also two input fields, where you need to specify the time range
The order of selected blocks can be changed by dragging the blocks.
Attributes
The "Attributes" tab contains two dropdown lists for selecting Template and Attribute Set.
After selecting the attribute set, you need to fill in the values. In our case, this is the attribute number, which has the type Integer. We will specify 44 as the value.
Categories
The "Categories" tab contains a search bar
Linked Pages
The "Linked pages" tab contains a search bar
.