Skip to content

model

Auto Added by WPeMatico

Append “Add New” button in Grid Listing, on a Form

A custom module has Foo and Bar Models. In the Foo element’s Form, there exists a grid listing of Bar items which belong to that Foo. This is an excerpt from the view/adminhtml/ui_component/bf_foo_form.xml file: <insertListing name=”bf_foo_form_bar_grid”> <settings> <externalProvider>bf_foo_form_bar_grid.bf_foo_grid_data_source</externalProvider> <loading>false</loading> <autoRender>true</autoRender>… Read More »Append “Add New” button in Grid Listing, on a Form

In Model Edit, display filtered grid of another Model

Consider two models, Foo and Bar. The Bar model has a non-nullable field foo_id which is associated with a Foo object. <?xml version=”1.0″ ?> <schema xmlns:xsi=”…” xsi:noNamespaceSchemaLocation=”…”> <table name=”dc_foos_foo” resource=”default” engine=”innodb”> <column xsi:type=”int” name=”foo_id” padding=”10″ unsigned=”true” nullable=”false” identity=”true”/> <constraint xsi:type=”primary”… Read More »In Model Edit, display filtered grid of another Model