mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 18:48:51 +02:00
N°1498 Fixed an issue on Advanced search external key autocomplete where homonyms weren't displayed
SVN:trunk[5876]
This commit is contained in:
@@ -609,9 +609,10 @@ $(function()
|
||||
if(Object.keys(oResponse).length > 0)
|
||||
{
|
||||
// Note: Response is indexed by labels from server so the JSON is always ordered on decoding.
|
||||
for(var sLabel in oResponse)
|
||||
for(var skey in oResponse)
|
||||
{
|
||||
var sValue = oResponse[sLabel];
|
||||
var sValue = oResponse[skey].value;
|
||||
var sLabel = oResponse[skey].label;
|
||||
// Note: We don't use the _isSelectedValue() method here as it only returns "applied" values; at this moment will could have a checked value that is not among selected (me.options.values) yet. The result would be an hidden item from the AC results.
|
||||
var bSelected = (this.element.find(this._getSelectedValuesWrapperSelector() + ' .sfc_opc_mc_item[data-value-code="' + sValue + '"]').length > 0);
|
||||
var bInitChecked = bSelected;
|
||||
@@ -636,9 +637,10 @@ $(function()
|
||||
if(Object.keys(oResponse).length > 0)
|
||||
{
|
||||
// Note: Response is indexed by labels from server so the JSON is always ordered on decoding.
|
||||
for(var sLabel in oResponse)
|
||||
for(var skey in oResponse)
|
||||
{
|
||||
var sValue = oResponse[sLabel];
|
||||
var sValue = oResponse[skey].value;
|
||||
var sLabel = oResponse[skey].label;
|
||||
// Note: We don't use the _isSelectedValue() method here as it only returns "applied" values; at this moment will could have a checked value that is not among selected (me.options.values) yet. The result would be an hidden item from the AC results.
|
||||
var bSelected = (this.element.find(this._getSelectedValuesWrapperSelector() + ' .sfc_opc_mc_item[data-value-code="' + sValue + '"]').length > 0);
|
||||
var bInitChecked = bSelected;
|
||||
|
||||
Reference in New Issue
Block a user