<?php
namespace Modules\Partners\Customers\CreditCards; class View_Utils_FormFilters extends \App\Mvc\View_Utils_FormAbstract { public function getForm() { $fieldsValues = $this->values['listingParams']->getFilters(); $form = \Engine\Form\Filters::create(); $form->setColumns(2); $name = \App\Form\Input\Autocomplete_Customer::create($this->lang['index']['filters']['customer'], 'filters[customer]', $fieldsValues['customer']); $form->addElement($name); $company = \App\Form\Input\Select_CreditCardVendors::create($this->lang['index']['filters']['company'], 'filters[company]', $fieldsValues['company']); $company->showDefaultOption(); $form->addElement($company); $form->setJSCallback('MVC.listing.installedHandlers["listing"].reloadAndResetListing'); $form->loadMissingDefaultValues($this->values['listingParams']->getDefaultFilters()); return $form; } }