mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-24 00:43:20 +01:00
Et2Email: If searchUrl is set to "", skip server search / suggestions
This commit is contained in:
parent
469c0cf742
commit
477af60705
@ -141,7 +141,18 @@ export class Et2Email extends Et2InputWidget(LitElement) implements SearchMixinI
|
|||||||
*/
|
*/
|
||||||
@property({type: Boolean, reflect: true}) open = false;
|
@property({type: Boolean, reflect: true}) open = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Custom search options, passed to the searchUrl along with the search text
|
||||||
|
*
|
||||||
|
* @type {{includeLists : boolean}}
|
||||||
|
*/
|
||||||
@property({type: Object}) searchOptions = {includeLists: true};
|
@property({type: Object}) searchOptions = {includeLists: true};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Server-side search for suggested email addresses.
|
||||||
|
* Set to "" to cancel searching.
|
||||||
|
* @type {string}
|
||||||
|
*/
|
||||||
@property({type: String}) searchUrl = "EGroupware\\Api\\Etemplate\\Widget\\Taglist::ajax_email";
|
@property({type: String}) searchUrl = "EGroupware\\Api\\Etemplate\\Widget\\Taglist::ajax_email";
|
||||||
|
|
||||||
@state() searching = false;
|
@state() searching = false;
|
||||||
@ -451,6 +462,12 @@ export class Et2Email extends Et2InputWidget(LitElement) implements SearchMixinI
|
|||||||
// Clear current option, it's probably going to go away
|
// Clear current option, it's probably going to go away
|
||||||
this.setCurrentOption(null);
|
this.setCurrentOption(null);
|
||||||
|
|
||||||
|
// If no searchUrl, no search
|
||||||
|
if(!this.searchUrl)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
this.searching = true;
|
this.searching = true;
|
||||||
this.requestUpdate("searching");
|
this.requestUpdate("searching");
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user