20
votes
Accepted
Admin Product View Page Error on Sort Magento 2.3
SKU should be empty or string. In your case, it is null or not a string.
Run follwoing query will resolve your issue if it is null sku related error:
UPDATE catalog_product_entity SET sku='' WHERE ...
5
votes
How can I merge columns in UI grid in Magento 2
You need to renderer field in UI grid.
Add <Vendor>\<Module>\Ui\Component\Listing\Column\Firstname class in field like this
<column name="firstname" class="Vendor\Module\Ui\Component\...
3
votes
Accepted
How to use addFieldToFilter on ui grid
Please add filter in collection.php with
protected function _initSelect()
{
parent::_initSelect();
$this>addFieldToFilter("parent_id", array("neq" => 0));
return $this;
}
and extend ...
3
votes
Magento 2: Uicomponent grid filter with multiple values as url params
If you have a requirement as load an admin grid with pre-defined multiple filter values like below:
<argument name="data" xsi:type="array">
<item name="config&...
3
votes
Accepted
UiComponent export button issue, error: getRowData() must be an instance of Magento\Framework\Api\Search\DocumentInterface (Solved by myself)
I have resolved the issue by adding below code
$this->_init(
'Magento\Framework\View\Element\UiComponent\DataProvider\Document', 'Package\Module\Model\ResourceModel\Test'
);
to ...
3
votes
Accepted
Magento2 UI grid same column problem
Open mageplaza_helloworld_post_listing.xml at
view/adminhtml/ui_component/mageplaza_helloworld_post_listing.xml
Now replace <item name="update_url" xsi:type="url" path="mui/index/render"/>
...
3
votes
Magento 2 add custom filter to grid for date
Use Magento_Ui/js/grid/columns/date component for date filter in UI grid
<column name="updated_at">
<argument name="data" xsi:type="array">
<item name="js_config" xsi:type="...
2
votes
Accepted
Need pass dynamic url param value in massAction url of ui-component grid
In my dataProvider class Package\Module\Ui\Component\RsvpDataProvider
in below segment:
<argument name="class" xsi:type="string">Package\Module\Ui\Component\RsvpDataProvider</argument>
...
2
votes
Magento2: How to use Custom Collection Data in UI Component Grid
Your UI component has no datasource component like the one indicated here https://devdocs.magento.com/guides/v2.3/ui_comp_guide/concepts/ui_comp_data_source.html#declaring-the-xml
Try adding ...
2
votes
How to pass value from controller to /resourceModel/Collection.php class
As you mentioned you have UI grids, means in the second grid you must have a Dataprovider, you can check there if there is a, id available in the post then you can filter(by using addFieldToFilter() ) ...
2
votes
Accepted
Magento 2: Admin ui grid inline edit not working
Your <item name="enabled"> value is false. First of all, set true value as like below :
vendor_module_test_listing.xml :
<item name="editorConfig" xsi:type="array&...
2
votes
How to use addFieldToFilter on ui grid
To add value to grid in ui component.
Sample here.
First you should see in view/adminhtml/ui_component/xxxx_listing.xml
<dataSource name="xxxx_grid_data_source">
<argument name="...
2
votes
Accepted
Magento 2.3 - Add product name column in custom ui grid with product name filter
In case you are using custom filter you can create custom filter strategy in your DataProvider:
Declare it in the di.xml:
<type name="Vendor\Module\Ui\DataProvider\YourCustomDataProvider">
...
2
votes
Magento 2: How to display Customer Name instead of Customer Id in UI Component Form Field?
Create a file
Vendor\ModuleName\Model\DataProvider.php
use \Vendor\ModuleName\Model\ResourceModel\ModuleName\CollectionFactory;
/**
* Class DataProvider
*/
class DataProvider extends \Magento\Ui\...
2
votes
Accepted
Values for checkboxes not coming through on save for admin form ui grid
You need to do some changes and corrections.
Edit view/adminhtml/ui_component/xigen_announce_group_form.xml file and put some extra code under announce_group_edit_tab_message as per below.
<...
2
votes
Accepted
Magento2: How to add product images to custom ui-component admin grid
You can add _initSelect() method in your Collection.php file in your custom module
protected function _initSelect()
{
parent::_initSelect();
$this->getSelect()->joinLeft(
['cp' => $...
2
votes
Accepted
Magento 2 : Custom column filter with serialize data in UI grid
I also face same issue and solved by this below code :
app/code/Vendor/Module/Model/ResourceModel/Page/Grid/Collection.php
protected function _renderFiltersBefore() {
$filters = $this->...
1
vote
Accepted
Display custom column in Invoice grid using join
Here it is working fine.Don't know why was not working with adding my custom argument class Vendor\Module\Model\ResourceModel\Order\Grid\Collection
adminhtml/di.xml
<type name="Magento\...
1
vote
Magento 2.3 dynamically add columns to ui grid component
if you look at the function \Magento\Catalog\Ui\Component\Listing\Columns::prepare in the core, this does create dynamically the columns for the catalog listing.
Also, in the file vendor/magento/...
1
vote
Values for checkboxes not coming through on save for admin form ui grid
in your block template, you may create a hidden field (see /vendor/magento/module-catalog/view/adminhtml/templates/catalog/category/edit/assign_products.phtml for an example of what I mean)
then, very ...
1
vote
Magento 2 UI Grid - How to add tabs in columns control?
Just add <columnsControls name="columns_controls"/> under <listingToolbar> tag of your grid uicomponent xml file. If you do not have added <listingToolbar> tag then simply add the ...
1
vote
Accepted
UI listing Understanding
A good way to keep configuration data out of the javascript is to declare a provider in the base component’s XML so it will be able to find that data provider component. Under the node, add a node ...
1
vote
Accepted
Magento 2 : How to get selected record from ui form fieldset listing grid in controller?
For that, create phtml file in adminhtml for add selected product ids in hidden field and pass into js.
Follow this below steps :
1) Create this phtml file in your adminhtml templates
/app/code/...
1
vote
Magento 2 Debug Ui Grid
In this case problems usually in dataProvider.
But it will be easier if you provide your entity_lisiting_grid.xml
listing should like this :
<listing xmlns:xsi="http://www.w3.org/2001/...
1
vote
How to use addFieldToFilter on ui grid
in your listing.xml file above the line
<item name="update_url" xsi:type="url" path="mui/index/render"/>
add the id you are passing in the url like in my case
<...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
ui-grid × 47magento2 × 42
uicomponent × 24
magento-2.1 × 7
magento2.3 × 5
filter × 5
grid × 4
ui-form × 4
admin × 3
magento2.2 × 3
magento2.3.2 × 2
massaction × 2
data-provider × 2
php × 1
product-attribute × 1
adminhtml × 1
collection × 1
custom × 1
rest-api × 1
magento2.3.1 × 1
php-7 × 1
magento-2.1.3 × 1
date × 1
pagination × 1
admin-controller × 1