|
From: <sv...@de...> - 2005-06-23 15:27:33
|
Author: pcamacho
Date: 2005-06-23 11:27:35 -0400 (Thu, 23 Jun 2005)
New Revision: 1403
Modified:
humano2/trunk/web/portal/site/showView.aspx.cs
Log:
FIX:
* when using search mode, the second column for viewtools was called "fi=
ltros", causing a conflict with the name=20
"where". Now "where" is used in every case.
* replaced "currrentUser" by "currentUser".
Modified: humano2/trunk/web/portal/site/showView.aspx.cs
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- humano2/trunk/web/portal/site/showView.aspx.cs 2005-06-23 14:54:45 UT=
C (rev 1402)
+++ humano2/trunk/web/portal/site/showView.aspx.cs 2005-06-23 15:27:35 UT=
C (rev 1403)
@@ -126,22 +126,20 @@
viewTable =3D getViewForSearch(iniClass,idAttributes,idOperators,val=
uesToSearch);
}
=20
- //replaces dynamic session variables
- Type myType =3D typeof(SessionCredencial);
- string whereStr =3D viewTable.Rows[0]["where"].ToString();
-
- FieldInfo[] myFieldInfo =3D myType.GetFields();
- for(int i=3D0;i<myFieldInfo.Length;i++)
- {
- FieldInfo myPropInfo =3D (FieldInfo)myFieldInfo[i];
- string fieldName =3D myPropInfo.Name;=09
- whereStr =3D whereStr.Replace("[currrentUser." + fieldName + "]",myP=
ropInfo.GetValue(userCred).ToString());
- }
-=20
- =09
- =09
- viewTable.Rows[0]["where"] =3D whereStr;
-
+ //replaces dynamic session variables
+ Type myType =3D typeof(SessionCredencial);
+ =20
+ string whereStr =3D viewTable.Rows[0]["where"].ToString();
+ =20
+ FieldInfo[] myFieldInfo =3D myType.GetFields();
+ for(int i=3D0;i<myFieldInfo.Length;i++)
+ {
+ FieldInfo myPropInfo =3D (FieldInfo)myFieldInfo[i];
+ string fieldName =3D myPropInfo.Name;=09
+ whereStr =3D whereStr.Replace("[currentUser." + fieldNam=
e + "]",myPropInfo.GetValue(userCred).ToString());
+ }
+ viewTable.Rows[0]["where"] =3D whereStr;
+ =20
// If there are multiple "order" arguments, they should be s=
eperated by ",";
// The framework already puts a "," between multiple "order =
arguments.
Logger.Log("Before ExecViewFromDataTabe. iniClass=3D " + Con=
vert.ToString(iniClass),LogLevel.Trace);
@@ -230,10 +228,10 @@
=20
//Explicacion de los filtros...
char separator =3D ';';
- dr["filtros"] =3D getFilterForSearch(idAttributes,idOperators,valuesT=
oSearch,separator);
- Logger.Log("search: filtros =3D " + dr["filtros"],LogLevel.Trace);
+ =09
+ dr["where"] =3D getFilterForSearch(idAttributes,idOperators,=
valuesToSearch,separator);
+ Logger.Log("search: filtros =3D " + dr["where"],LogLevel.Trace);
=20
- =20
dtParam.Rows.Add(dr);
return dtParam;
}
@@ -303,7 +301,7 @@
DataColumn dc1;
dc1 =3D new DataColumn("columns",typeof(string));
dt1.Columns.Add(dc1);
- dc1 =3D new DataColumn("filtros",typeof(string));
+ dc1 =3D new DataColumn("where",typeof(string));
dt1.Columns.Add(dc1);
dc1 =3D new DataColumn("group",typeof(string));
dt1.Columns.Add(dc1);
|