cancel
Showing results for 
Search instead for 
Did you mean: 

Validate mass actions check box column

Validate mass actions check box column


Hi,

 

I am using Magento ver. 2.1.7 CE .

 

I added new button "Validate" in UI component layout inside "<argument>" tag as follows

 

<argument>
.....
.....

<item name="buttons" xsi:type="array">			
	<item name="print" xsi:type="array">
		<item name="name" xsi:type="string">print</item>
		<item name="label" xsi:type="string" translate="true">Validate</item>
		<item name="sortOrder" xsi:type="number">0</item>
		<item name="class" xsi:type="string">primary</item>
		<item name="url" xsi:type="string">*/*/save</item>
	</item>

	<item name="add" xsi:type="array">
		<item name="name" xsi:type="string">add</item>
		<item name="label" xsi:type="string" translate="true">Add New</item>
		<item name="class" xsi:type="string">primary</item>
		<item name="url" xsi:type="string">*/*/add</item>
	</item>
</item>
.....
.....
<columns>


I want to validate the checkbox for limit the selection not more than two items before submission.

If more than two selection, show popup message to user.

 

validate-massaction.png

 

Thanks.