Patch level : 10.0
Files correlati : ca0.exe Ricompilazione Demo : [ ] Commento : Corretta gestione alberi di ricerca su commesse e centri di costo. Ora l'albero non compare piu' in caso di archivi enormi e la finestra di ricerca e' molto piu' veloce. git-svn-id: svn://10.65.10.50/trunk@20558 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
c623b5162a
commit
50d081a204
@ -403,21 +403,25 @@ static void ca_append_select_clause(ostream& out, int level, int logic, bool upp
|
||||
else
|
||||
{
|
||||
const TMultilevel_code_info& mci = ca_multilevel_code_info(logic);
|
||||
const TFieldref& key = mci.fieldref(level);
|
||||
|
||||
str << "STR(";
|
||||
if (level > 1 && !upper_limit)
|
||||
str << "(NUM(LEN(" << key.name() << "))>" << key.from() << ')'; // SE LEN(CODCONTO)>=4
|
||||
if (level < mci.levels())
|
||||
const int last_level = mci.levels()-1;
|
||||
if (last_level > 0)
|
||||
{
|
||||
if (level > 1 && !upper_limit) str << "&&";
|
||||
str << "(NUM(LEN(" << key.name() << "))<=" << key.to() << ')'; // SE LEN(CODCONTO)<=7
|
||||
CHECKD(level>=0 && level <= last_level, "Bad analitic level ", level);
|
||||
const TFieldref& key = mci.fieldref(level);
|
||||
|
||||
str << "STR(";
|
||||
if (level > 0 && !upper_limit)
|
||||
str << "(NUM(LEN(" << key.name() << "))>" << key.from() << ')'; // SE LEN(CODCONTO)>=4
|
||||
if (level < last_level)
|
||||
{
|
||||
if (level > 0 && !upper_limit) str << "&&";
|
||||
str << "(NUM(LEN(" << key.name() << "))<=" << key.to() << ')'; // SE LEN(CODCONTO)<=7
|
||||
}
|
||||
str << ')';
|
||||
}
|
||||
str << ')';
|
||||
}
|
||||
|
||||
const TString & condition = ca_create_user_select_clause(logic);
|
||||
|
||||
if (condition.full())
|
||||
{
|
||||
if (str.full())
|
||||
@ -427,6 +431,7 @@ static void ca_append_select_clause(ostream& out, int level, int logic, bool upp
|
||||
}
|
||||
str << '(' << condition << ')';
|
||||
}
|
||||
|
||||
if (str.full())
|
||||
out << " SE " << str << '\n';
|
||||
}
|
||||
@ -822,6 +827,14 @@ int TSimple_anal_msk::compute_offset() const
|
||||
RCT rct; xvt_vobj_get_client_rect(TASK_WIN, &rct);
|
||||
if (rct.right > 720)
|
||||
delta = (rct.right - 720) / 2 / CHARX;
|
||||
|
||||
if (delta > 0)
|
||||
{
|
||||
TLocalisamfile lif(get_logicnum());
|
||||
if (lif.items() > 2048) // Niente alberi enormi ... per ora
|
||||
delta = 0;
|
||||
}
|
||||
|
||||
return delta;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user