drafted ajax search call

This commit is contained in:
2019-06-01 16:15:08 +02:00
parent d21bd5ef4e
commit 7f65fd79a4
9 changed files with 278 additions and 17 deletions

View File

@@ -30,12 +30,19 @@ class MaterioSapiSearchForm extends FormBase {
'#weight' => '0',
'#attributes' => [
"placeholder" => $this->t('Search'),
"@keyup" => "keyup",
// "@keyup" => "keyup",
"@keyup.enter" => "submit",
"v-model" => "typed"
"v-model" => "keys",
// "v-on:select" => "typed",
],
'#autocomplete_route_name' => 'materio_sapi.search_autocomplete',
];
$form['searchautocomplete'] = [
'#type' => 'hidden',
'#attributes' => [
"v-model" => "autocomplete"
],
];
$form['submit'] = [
'#type' => 'submit',