Skip to content

Commit

Permalink
Merge pull request #38 from EmicoEcommerce/feat-builder-template
Browse files Browse the repository at this point in the history
feat: builder-template
  • Loading branch information
ah-net authored Jan 16, 2025
2 parents 0759086 + 90f766d commit 8cb04c4
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 1 deletion.
5 changes: 5 additions & 0 deletions src/Model/FilterApplier/TweakwiseFilterApplier.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,11 @@ public function applyFilters(LandingPageInterface $page)
if ($sortTemplateId) {
$navigationRequest->setSortTemplateId($sortTemplateId);
}

$builderTemplateId = $page->getTweakwiseBuilderTemplate();
if ($builderTemplateId) {
$navigationRequest->setBuilderTemplateId($builderTemplateId);
}
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,30 @@
</settings>
</actionDelete>
</container>
</dynamicRows>
</dynamicRows>

<field formElement="select" name="tweakwise_builder_template" sortOrder="66">
<argument name="data" xsi:type="array">
<item name="config" xsi:type="array">
<item name="source" xsi:type="string">Page</item>
</item>
</argument>

<settings>
<dataType>text</dataType>
<label translate="true">Tweakwise builder template</label>
<dataScope>tweakwise_builder_template</dataScope>
<validation>
<rule name="required-entry" xsi:type="boolean">false</rule>
</validation>
</settings>
<formElements>
<select>
<settings>
<options class="Tweakwise\Magento2Tweakwise\Model\Config\Source\BuilderTemplate" />
</settings>
</select>
</formElements>
</field>
</fieldset>
</form>

0 comments on commit 8cb04c4

Please sign in to comment.