0

I'm wondering how form inputs are interpreted in magento2 admin grids.

For example, add an input (manually via navigator console) in cart price rule creation form. The input value will not be sent with other parameters.

It's the same when adding an input with "htmlContent" element in ui_component form.

How to make my input sent with htmlContent ?

Edit :

This code in custom admin grid ui_component xml file :

<?xml version="1.0" encoding="UTF-8"?>
<form xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Ui:etc/ui_configuration.xsd">
---
 <fieldset name="custom" sortOrder="20">
 <settings>
 <collapsible>false</collapsible>
 <label translate="true">Custom</label>
 </settings>
 <container name="custom_container" sortOrder="10">
 <htmlContent name="html_content">
 <block class="Magento\Framework\View\Element\Template" template="Vendor_Module::input.phtml" />
 </htmlContent>
 </container>
 </fieldset>
</form>

input.phtml :

<input type="text" name="test_input" value="test_input" />

Input is not sent with the other <field> attributes of the ui_component form.

Muhammad Anas
1,4673 gold badges13 silver badges33 bronze badges
asked May 21, 2019 at 15:33
3
  • Write more that you have tried Commented May 21, 2019 at 15:39
  • Just edited the post Commented May 21, 2019 at 15:59
  • I found response here. magento.stackexchange.com/questions/154201/… Commented May 22, 2019 at 8:04

0

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.