|
158 | 158 | <elementTmpl>Magento_PageBuilder/form/element/input-no-maxlength</elementTmpl>
|
159 | 159 | </settings>
|
160 | 160 | </field>
|
161 |
| - <htmlContent name="conditions_form" sortOrder="5" template="Magento_PageBuilder/form/element/widget-conditions"> |
| 161 | + <htmlContent name="conditions_form" sortOrder="5" template="Magento_PageBuilder/form/element/widget-conditions" component="Magento_PageBuilder/js/form/element/html"> |
162 | 162 | <settings>
|
163 | 163 | <visible>false</visible>
|
164 | 164 | <additionalClasses>
|
|
197 | 197 | </select>
|
198 | 198 | </formElements>
|
199 | 199 | </field>
|
200 |
| - <field name="products_count" sortOrder="20" formElement="input"> |
| 200 | + <container name="product_count_group" component="Magento_Ui/js/form/components/group" sortOrder="20"> |
201 | 201 | <argument name="data" xsi:type="array">
|
202 | 202 | <item name="config" xsi:type="array">
|
203 |
| - <item name="default" xsi:type="number">5</item> |
| 203 | + <item name="breakLine" xsi:type="boolean">false</item> |
204 | 204 | </item>
|
205 | 205 | </argument>
|
206 |
| - <settings> |
207 |
| - <dataType>number</dataType> |
208 |
| - <label translate="true">Number of Products to Display</label> |
209 |
| - <additionalClasses> |
210 |
| - <class name="admin__field-small">true</class> |
211 |
| - </additionalClasses> |
212 |
| - <dataScope>products_count</dataScope> |
213 |
| - <validation> |
214 |
| - <rule name="required-entry" xsi:type="boolean">true</rule> |
215 |
| - <rule name="validate-number" xsi:type="boolean">true</rule> |
216 |
| - <rule name="less-than-equals-to" xsi:type="number">999</rule> |
217 |
| - <rule name="greater-than-equals-to" xsi:type="number">1</rule> |
218 |
| - </validation> |
219 |
| - </settings> |
220 |
| - </field> |
| 206 | + <field name="products_count" sortOrder="10" formElement="input"> |
| 207 | + <argument name="data" xsi:type="array"> |
| 208 | + <item name="config" xsi:type="array"> |
| 209 | + <item name="default" xsi:type="number">5</item> |
| 210 | + </item> |
| 211 | + </argument> |
| 212 | + <settings> |
| 213 | + <dataType>number</dataType> |
| 214 | + <label translate="true">Number of Products to Display</label> |
| 215 | + <additionalClasses> |
| 216 | + <class name="admin__field-small">true</class> |
| 217 | + </additionalClasses> |
| 218 | + <dataScope>products_count</dataScope> |
| 219 | + <validation> |
| 220 | + <rule name="required-entry" xsi:type="boolean">true</rule> |
| 221 | + <rule name="validate-number" xsi:type="boolean">true</rule> |
| 222 | + <rule name="less-than-equals-to" xsi:type="number">999</rule> |
| 223 | + <rule name="greater-than-equals-to" xsi:type="number">1</rule> |
| 224 | + </validation> |
| 225 | + </settings> |
| 226 | + </field> |
| 227 | + <field name="product_totals" sortOrder="20" formElement="input" component="Magento_PageBuilder/js/form/element/product-totals"> |
| 228 | + <argument name="data" xsi:type="array"> |
| 229 | + <item name="config" xsi:type="array"> |
| 230 | + <item name="default" xsi:type="string">of ${ $.totalProductCount }</item> |
| 231 | + </item> |
| 232 | + </argument> |
| 233 | + <settings> |
| 234 | + <elementTmpl>ui/form/element/text</elementTmpl> |
| 235 | + <dataType>text</dataType> |
| 236 | + <imports> |
| 237 | + <link name="conditionOption">ns = ${ $.ns }, index = condition_option:value</link> |
| 238 | + <link name="conditionValues.category_ids">ns = ${ $.ns }, index = category_ids:value</link> |
| 239 | + <link name="conditionValues.sku">ns = ${ $.ns }, index = sku:value</link> |
| 240 | + <link name="conditionValues.condition">ns = ${ $.ns }, index = conditions_form:value</link> |
| 241 | + </imports> |
| 242 | + </settings> |
| 243 | + </field> |
| 244 | + </container> |
221 | 245 | </fieldset>
|
222 | 246 | </form>
|
0 commit comments