case 3815

This commit is contained in:
2020-10-16 19:27:07 +00:00
parent 79c5561a7a
commit 21dff8b1cf

View File

@@ -222,25 +222,36 @@ namespace AyaNova
{ {
if (!listMaxResults.ContainsKey(sCurrentListKey)) if (!listMaxResults.ContainsKey(sCurrentListKey))
{ {
//Case 316 - workaround so MIAD gets all rows by default //case 3815 row count defaults, also removed this miad shit below, they are no longer a customer
if (AyaBizUtils.REGTO == "Miad Systems Ltd") //this code was intended to copy whatever the row count was last in use by the user when they last exited
listMaxResults.Add(sCurrentListKey, 0); //when viewing a new grid this session, instead, I'm removing all that and just defaulting to 100 when there is no
else // previously saved count
{
//case 1553 ////Case 316 - workaround so MIAD gets all rows by default
User u = User.GetItem(User.CurrentThreadUserID); //if (AyaBizUtils.REGTO == "Miad Systems Ltd")
foreach (ValueListItem vi in cbTop.Items) // listMaxResults.Add(sCurrentListKey, 0);
{ //else
if ((int)vi.DataValue == u.MainGridLastRowCount) //{
{
cbTop.SelectedItem = vi; // //case 1553
break; // User u = User.GetItem(User.CurrentThreadUserID);
} //foreach (ValueListItem vi in cbTop.Items)
} //{
// if ((int)vi.DataValue == u.MainGridLastRowCount)
// {
// cbTop.SelectedItem = vi;
// break;
// }
//}
listMaxResults.Add(sCurrentListKey,cbTop.SelectedIndex); // listMaxResults.Add(sCurrentListKey,cbTop.SelectedIndex);
} //}
cbTop.SelectedIndex = 1;//100
listMaxResults.Add(sCurrentListKey, 1);
} }
return listMaxResults[sCurrentListKey]; return listMaxResults[sCurrentListKey];
@@ -265,8 +276,16 @@ namespace AyaNova
if (!listCache.ContainsKey(key)) if (!listCache.ContainsKey(key))
{ {
//case 3815 list timeout handler
listCache.Add(key,ListFactory.GetList(key, FilterXML, System.Convert.ToInt32(cbTop.Value))); try
{
listCache.Add(key, ListFactory.GetList(key, FilterXML, System.Convert.ToInt32(cbTop.Value)));
}
catch (Exception e) {
Exception exInner = Util.CrackException(e);
Util.debugLog(exInner.Message);
}
} }