mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-09 01:24:07 +01:00
Better support for no_actions row flag so fetched rows with no_actions are not selected by 'select all'
This commit is contained in:
parent
a27e7e1ee9
commit
7805844b7c
@ -563,24 +563,28 @@ var et2_dataview_selectionManager = (function(){ "use strict"; return Class.exte
|
|||||||
{
|
{
|
||||||
queryRanges.push(et2_bounds(naStart, i - 1));
|
queryRanges.push(et2_bounds(naStart, i - 1));
|
||||||
naStart = false;
|
naStart = false;
|
||||||
|
range_break += RANGE_MAX;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Select the element, unless flagged for exclusion
|
// Select the element, unless flagged for exclusion
|
||||||
if(!this._indexMap[i].no_actions)
|
// Check for no_actions flag via data
|
||||||
|
var data = egw.dataGetUIDdata(this._indexMap[i].uid);
|
||||||
|
if(!data || data && data.data && !data.data.no_actions)
|
||||||
{
|
{
|
||||||
this.setSelected(this._indexMap[i].uid, true);
|
this.setSelected(this._indexMap[i].uid, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (naStart === false)
|
||||||
|
{
|
||||||
|
naStart = i;
|
||||||
|
range_break = naStart + RANGE_MAX;
|
||||||
|
}
|
||||||
else if(i >= range_break)
|
else if(i >= range_break)
|
||||||
{
|
{
|
||||||
queryRanges.push(et2_bounds(naStart ? naStart : s, i - 1));
|
queryRanges.push(et2_bounds(naStart ? naStart : s, i - 1));
|
||||||
naStart = i;
|
naStart = i;
|
||||||
range_break += RANGE_MAX;
|
range_break += RANGE_MAX;
|
||||||
}
|
}
|
||||||
else if (naStart === false)
|
|
||||||
{
|
|
||||||
naStart = i;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Add the last range to the "queryRanges"
|
// Add the last range to the "queryRanges"
|
||||||
@ -645,9 +649,14 @@ var et2_dataview_selectionManager = (function(){ "use strict"; return Class.exte
|
|||||||
that._queryRangeCallback.call(that._context, this,
|
that._queryRangeCallback.call(that._context, this,
|
||||||
function (_order) {
|
function (_order) {
|
||||||
for (var j = 0; j < _order.length; j++)
|
for (var j = 0; j < _order.length; j++)
|
||||||
|
{
|
||||||
|
// Check for no_actions flag via data since entry isn't there/available
|
||||||
|
var data = egw.dataGetUIDdata(_order[j]);
|
||||||
|
if(!data || data && data.data && !data.data.no_actions)
|
||||||
{
|
{
|
||||||
this.setSelected(_order[j], true);
|
this.setSelected(_order[j], true);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
progressbar.set_value(100*(++range_index/range_count));
|
progressbar.set_value(100*(++range_index/range_count));
|
||||||
resolve();
|
resolve();
|
||||||
}, that);
|
}, that);
|
||||||
|
Loading…
Reference in New Issue
Block a user