[oform] Bug 59069
This commit is contained in:
parent
661825ace9
commit
2da83c27aa
|
@ -127,7 +127,7 @@ define([
|
||||||
|
|
||||||
onInputSearchChange: function (text) {
|
onInputSearchChange: function (text) {
|
||||||
var text = text[0];
|
var text = text[0];
|
||||||
if (this._state.searchText !== text) {
|
if ((text && this._state.searchText !== text) || (!text && this._state.newSearchText)) {
|
||||||
this._state.newSearchText = text;
|
this._state.newSearchText = text;
|
||||||
this._lastInputChange = (new Date());
|
this._lastInputChange = (new Date());
|
||||||
if (this._searchTimer === undefined) {
|
if (this._searchTimer === undefined) {
|
||||||
|
@ -136,7 +136,11 @@ define([
|
||||||
if ((new Date()) - me._lastInputChange < 400) return;
|
if ((new Date()) - me._lastInputChange < 400) return;
|
||||||
|
|
||||||
me._state.searchText = me._state.newSearchText;
|
me._state.searchText = me._state.newSearchText;
|
||||||
(me._state.newSearchText !== '') && me.onQuerySearch();
|
if (me._state.newSearchText !== '') {
|
||||||
|
me.onQuerySearch();
|
||||||
|
} else {
|
||||||
|
me.api.asc_endFindText();
|
||||||
|
}
|
||||||
clearInterval(me._searchTimer);
|
clearInterval(me._searchTimer);
|
||||||
me._searchTimer = undefined;
|
me._searchTimer = undefined;
|
||||||
}, 10);
|
}, 10);
|
||||||
|
|
Loading…
Reference in a new issue