init
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
/** @var \Esun\CustomerCoupon\Block\Adminhtml\Form\CustomerSelect $block */
|
||||
/** @var \Magento\Framework\Escaper $escaper */
|
||||
?>
|
||||
<div class="esun-customer-coupon-select">
|
||||
<div data-role="esun-customer-coupon-scope" data-bind="scope: 'esunCustomerCouponSelect'">
|
||||
<input type="hidden" name="customer_ids" data-bind="value: value"/>
|
||||
<!-- ko template: getTemplate() --><!-- /ko -->
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/x-magento-init">
|
||||
{
|
||||
".esun-customer-coupon-select": {
|
||||
"Magento_Ui/js/core/app": {
|
||||
"components": {
|
||||
"esunCustomerCouponSelect": {
|
||||
"component": "Esun_CustomerCoupon/js/form/element/customer-select",
|
||||
"dataScope": "customer_ids",
|
||||
"template": "ui/grid/filters/elements/ui-select",
|
||||
"disableLabel": true,
|
||||
"multiple": true,
|
||||
"showCheckbox": true,
|
||||
"showPath": false,
|
||||
"chipsEnabled": true,
|
||||
"filterOptions": true,
|
||||
"searchOptions": true,
|
||||
"searchUrl": "<?= $escaper->escapeJs($escaper->escapeUrl($block->getSearchUrl())) ?>",
|
||||
"filterPlaceholder": "<?= $escaper->escapeJs(__('Search by name, email, or customer ID')) ?>",
|
||||
"selectedPlaceholders": {
|
||||
"defaultPlaceholder": "<?= $escaper->escapeJs(__('Search and select customers')) ?>",
|
||||
"lotPlaceholders": "<?= $escaper->escapeJs(__('customers selected')) ?>"
|
||||
},
|
||||
"pageLimit": 20,
|
||||
"options": []
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user