You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(146) |
Jun
(188) |
Jul
(11) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|---|
|
From: <sv...@de...> - 2005-05-27 19:07:12
|
Author: marijn
Date: 2005-05-27 15:07:09 -0400 (Fri, 27 May 2005)
New Revision: 1174
Modified:
humano2/trunk/config/config.xml.tmpl
Log:
* Undoing escaped changes that should not be in trunk.
Modified: humano2/trunk/config/config.xml.tmpl
=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/config/config.xml.tmpl 2005-05-27 18:57:27 UTC (rev 117=
3)
+++ humano2/trunk/config/config.xml.tmpl 2005-05-27 19:07:09 UTC (rev 117=
4)
@@ -9,9 +9,8 @@
<pass>h2_dbase!</pass> <!-- The password of the database -->
</database>
<locations>
- <base>C:\h2_install</base> <!-- The base directory from where the=
files are referenced. -->
- <dbdrivers>bin</dbdrivers> <!-- Where is the database driver d=
irecotory -->
- <session>sessions</session> <!-- Directory where are the sessio=
n xml files stored -->
+ <dbdrivers>C:\h2_install\bin</dbdrivers> <!-- Where is the datab=
ase driver direcotory -->
+ <session>C:\h2_sessions</session> <!-- Directory where ar=
e the session xml files stored -->
<webbase>http://localhost:8080</webbase> <!-- what's the base lo=
cation where the humano2 installation lives? -->=20
</locations>
<log>
|
|
From: <sv...@de...> - 2005-05-27 18:57:25
|
Author: marijn
Date: 2005-05-27 14:57:27 -0400 (Fri, 27 May 2005)
New Revision: 1173
Modified:
humano2/trunk/changelog.txt
humano2/trunk/config/config.xml.tmpl
Log:
Adding Id keywork to file.
Modified: humano2/trunk/changelog.txt
=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/changelog.txt 2005-05-27 18:53:37 UTC (rev 1172)
+++ humano2/trunk/changelog.txt 2005-05-27 18:57:27 UTC (rev 1173)
@@ -1,3 +1,5 @@
+$Id$
+
=3D=3D 5.0.beta3 - 2005-05-27 =3D=3D
=20
* Databases
Property changes on: humano2/trunk/changelog.txt
___________________________________________________________________
Name: svn:keywords
+ Id
Modified: humano2/trunk/config/config.xml.tmpl
=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/config/config.xml.tmpl 2005-05-27 18:53:37 UTC (rev 117=
2)
+++ humano2/trunk/config/config.xml.tmpl 2005-05-27 18:57:27 UTC (rev 117=
3)
@@ -9,8 +9,9 @@
<pass>h2_dbase!</pass> <!-- The password of the database -->
</database>
<locations>
- <dbdrivers>C:\h2_install\bin</dbdrivers> <!-- Where is the datab=
ase driver direcotory -->
- <session>C:\h2_sessions</session> <!-- Directory where ar=
e the session xml files stored -->
+ <base>C:\h2_install</base> <!-- The base directory from where the=
files are referenced. -->
+ <dbdrivers>bin</dbdrivers> <!-- Where is the database driver d=
irecotory -->
+ <session>sessions</session> <!-- Directory where are the sessio=
n xml files stored -->
<webbase>http://localhost:8080</webbase> <!-- what's the base lo=
cation where the humano2 installation lives? -->=20
</locations>
<log>
|
|
From: <sv...@de...> - 2005-05-27 18:53:39
|
Author: marijn
Date: 2005-05-27 14:53:37 -0400 (Fri, 27 May 2005)
New Revision: 1172
Modified:
humano2/trunk/changelog.txt
Log:
* Updating information.
Modified: humano2/trunk/changelog.txt
=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/changelog.txt 2005-05-27 18:01:51 UTC (rev 1171)
+++ humano2/trunk/changelog.txt 2005-05-27 18:53:37 UTC (rev 1172)
@@ -1,15 +1,14 @@
=3D=3D 5.0.beta3 - 2005-05-27 =3D=3D
=20
* Databases
- * Added Driver for MicrosoftSQL server (pending issue is paging
- with mssql #135)
+ * Added Driver for MicrosoftSQL server=20
+ * PENDING: issue with paging mssql: see #135
=20
* Metamodel=20
* Added new attribute types of attributes:
- Email
- Currency
- password
- - HTML
- RUT
- URL
=20
@@ -23,7 +22,7 @@
* Attributes of derived types show up correctly in a view #53
=20
* Builder
- * Folders interface maintain the consistent tree consistent.
+ * Folders interface maintain the consistent tree consistent. #134
* Cleanup of support file (js, css, images, etc) directories. #103
* Creating a class, deleting it and creating it again works #41 =20
* Creation of folders sometimes returns errors #56
|
|
From: <sv...@de...> - 2005-05-27 18:01:52
|
Author: marijn
Date: 2005-05-27 14:01:51 -0400 (Fri, 27 May 2005)
New Revision: 1171
Modified:
humano2/trunk/core/schema/pgsql/pgsql-4-extendedAttributes.sql
Log:
* Hidding attribute HTML since that is still not behaving well with view=
s.
Modified: humano2/trunk/core/schema/pgsql/pgsql-4-extendedAttributes.sql
=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/core/schema/pgsql/pgsql-4-extendedAttributes.sql 2005-0=
5-27 17:39:19 UTC (rev 1170)
+++ humano2/trunk/core/schema/pgsql/pgsql-4-extendedAttributes.sql 2005-0=
5-27 18:01:51 UTC (rev 1171)
@@ -79,7 +79,7 @@
INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (94,27,'email','email',8,'f','f');
INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (87,27,'currency','currency',9,'f','f'=
);
INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (500,27, 'password','password',8,'f','=
f');
-INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (502,27, 'HTML','HTML',13,'f','f');
+INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (502,27, 'HTML','HTML',13,'f','t');
INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (503,27, 'RUT','RUT',8,'f','f');
INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (504,27, 'URL','URL',8,'f','f');
INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (506,27, 'image','image',39,'f','t');
|
|
From: <sv...@de...> - 2005-05-27 17:39:23
|
Author: marijn
Date: 2005-05-27 13:39:19 -0400 (Fri, 27 May 2005)
New Revision: 1170
Modified:
humano2/trunk/changelog.txt
Log:
* More information about the changes in Beta3
Modified: humano2/trunk/changelog.txt
=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/changelog.txt 2005-05-27 17:34:05 UTC (rev 1169)
+++ humano2/trunk/changelog.txt 2005-05-27 17:39:19 UTC (rev 1170)
@@ -1,9 +1,5 @@
=3D=3D 5.0.beta3 - 2005-05-27 =3D=3D
=20
- * Portal
- * Searching: A field that is of type pertinence gets searched as the
- user would expect (by name, not instance id)
-
* Databases
* Added Driver for MicrosoftSQL server (pending issue is paging
with mssql #135)
@@ -17,6 +13,25 @@
- RUT
- URL
=20
+ * Portal
+ * Searching: A field that is of type pertinence gets searched as the
+ user would expect (by name, not instance id) #122
+ * Fix when in the "goto page" box has a non-numeric value #84
+ * Paging funcions with Views #66
+ * The attribute format always gets tested when saving
+ instance. #126
+ * Attributes of derived types show up correctly in a view #53
+ =20
+ * Builder
+ * Folders interface maintain the consistent tree consistent.
+ * Cleanup of support file (js, css, images, etc) directories. #103
+ * Creating a class, deleting it and creating it again works #41 =20
+ * Creation of folders sometimes returns errors #56
+ * When deleting a class the leftbar gets updated correctly. #132
+ * When creating a view without a name it now doesn't use the
+ settings. #133
+
+
=3D=3D 5.0.beta2 - 2005-05-19 =3D=3D
=20
* Portal
|
|
From: <sv...@de...> - 2005-05-27 17:34:07
|
Author: pcamacho
Date: 2005-05-27 13:34:05 -0400 (Fri, 27 May 2005)
New Revision: 1169
Modified:
humano2/trunk/components/webTools/Adapter.cs
humano2/trunk/web/builder/site/foldermanagement.aspx.cs
Log:
FIX: #134.
Modified: humano2/trunk/components/webTools/Adapter.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/components/webTools/Adapter.cs 2005-05-27 16:46:50 UTC =
(rev 1168)
+++ humano2/trunk/components/webTools/Adapter.cs 2005-05-27 17:34:05 UTC =
(rev 1169)
@@ -1880,6 +1880,103 @@
return dt1;
}
=20
-
+ ///<summary>
+ /// Returns the list of all descendants of a folder (all levels
+ ///</summary>
+ public int [] GetAllDescendantsOfFolder(int folderId)
+ {
+ int [] directChilds =3D complex.GetChildsOfFolder(folderId);
+ int sizeDirectChilds =3D directChilds.Length;
+ =20
+ if(sizeDirectChilds =3D=3D 0) //we're done
+ {
+ Logger.Log("GetAllDescendantsIoFolder: " + folderId + " =
has no child",LogLevel.Trace);
+ return directChilds; =20
+ }
+ else //Follow recursivity and build tab
+ {
+ Logger.Log("GetAllDescendantsIoFolder: " + folderId + " h=
as " + sizeDirectChilds + " childs.",LogLevel.Trace);
+ int [] aux =3D null;
+ for(int i=3D0;i<sizeDirectChilds;i++)
+ {
+ aux =3D ConcatInt32Array(GetAllDescendantsOfFolder(d=
irectChilds[i]),aux);
+ }
+ int [] res =3D ConcatInt32Array(aux,directChilds);
+ return res;
+ }
+ } =20
+ =20
+ private int [] ConcatInt32Array(int [] arr1, int [] arr2)
+ {
+ =20
+ int sizeArr1;
+ int sizeArr2;
+ =20
+ if(arr1!=3Dnull)
+ {
+ sizeArr1 =3D arr1.Length; =20
+ }
+ else
+ {
+ sizeArr1 =3D 0; =20
+ }
+ =20
+ if(arr2!=3Dnull)
+ {
+ sizeArr2 =3D arr2.Length; =20
+ }
+ else
+ {
+ sizeArr2 =3D 0; =20
+ }
+ =20
+ int size =3D sizeArr1 + sizeArr2;
+ Logger.Log("ConcatInt32Array. size=3D " + size, LogLevel.Tra=
ce);
+ int [] res =3D new int[size];
+ =20
+ //copy first array
+ if(arr1 !=3D null)
+ {
+ for(int i=3D0;i<arr1.Length;i++)
+ {
+ res[i] =3D arr1[i];
+ }
+ }
+ //copy second array
+ if(arr2 !=3D null)
+ {
+ for(int i=3D0;i<arr2.Length;i++)
+ {
+ res[i+sizeArr1] =3D arr2[i]; =20
+ }
+ }
+ =20
+ Logger.Log("Adapter Concat",LogLevel.Trace);
+ for(int i=3D0;i<size;i++)
+ {
+ Logger.Log("res[" + i + "]=3D " +res[i] + " ",LogLevel.T=
race);
+ }
+ =20
+ return res;
+ }
+ =20
+ public bool IsDescendantOfFolder(int folderId, int folderIsDesce=
ndantId)
+ {
+ int [] allDescendants =3D GetAllDescendantsOfFolder(folderId=
);
+ bool res =3D false;=20
+ =20
+ //Look for the folderIsDescendantId in the descendant list
+ int size =3D allDescendants.Length;
+ for(int i=3D0; i< size; i++)
+ {
+ if(folderIsDescendantId =3D=3D allDescendants[i])
+ {
+ res =3D true;
+ break;
+ }
+ }
+ =20
+ return res;
+ }
}
}
Modified: humano2/trunk/web/builder/site/foldermanagement.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/builder/site/foldermanagement.aspx.cs 2005-05-27 16=
:46:50 UTC (rev 1168)
+++ humano2/trunk/web/builder/site/foldermanagement.aspx.cs 2005-05-27 17=
:34:05 UTC (rev 1169)
@@ -244,6 +244,12 @@
}
}
=09
+ =20
+ ///<summary>
+ ///Get the list of all folders (id,name) from a specific domain
+ ///</summary>
+ ///<param name=3D"domainId">id of domain</param>
+ ///<returns>list of folders with id and name</returns>
private DataTable getListFolder(int domainId)
{
string filtro =3D String.Format("34|4|'{0}'|0|0",domainId);
@@ -496,56 +502,20 @@
return;
}
=20
- arrFolder =3D getListFolderChilds(domainId);
foreach(DataRow row in dtResult.Rows)
{
- strHtml +=3D getNextOptionFolder(row,arrFolder,folderId);
+ //Don't allow a folder to be a child of one of its desce=
ndants and himself
+ adapter dbAdapter =3D userCred.CoreAdapter;
+ if(!dbAdapter.IsDescendantOfFolder(folderId, Convert.ToInt32(row["id=
_entity"]))
+ && folderId !=3D Convert.ToInt32(row["id_entity"]) )=
=20
+ {
+ strHtml +=3D String.Format("<option value=3D\"{0}\" =
selected>{1}</option>",row["id_entity"],row["folderName"]);
+ }
}
Response.Write(strHtml);
}
=20
- private string getNextOptionFolder(DataRow row, ArrayList arrFolder, i=
nt folderId)
- {
- string strHtml =3D "";
- int flag =3D 0;
=09
- int id_entity =3D Convert.ToInt32(row["id_entity"]);
- =09
- if(folderId =3D=3D id_entity)
- {
- return strHtml;
- }
- if (arrFolder !=3D null)
- {
- for(int pos =3D 0;pos < arrFolder.Count;pos++)
- {
- if (((strct_folderNode)arrFolder[pos]).idParent =3D=3D folderId)
- {
- if(((strct_folderNode)arrFolder[pos]).idNode =3D=3D id_entity)
- {
- flag =3D 1;
- }
- }
- }
- }
- if(folderParentId !=3D null && folderParentId.Length > 0)
- {
- if(Convert.ToInt32(folderParentId) =3D=3D id_entity)
- {
- if(flag =3D=3D 0)
- {
- strHtml =3D String.Format("<option value=3D\"{0}\" selected>{1}</o=
ption>",row["id_entity"],row[1]);
- return strHtml;
- }
- }
- }
- if(flag =3D=3D 0)
- {
- strHtml +=3D String.Format("<option value=3D\"{0}\">{1}</option>",ro=
w["id_entity"],row[1]);
- }
- return strHtml;
- }
-
public void html_getFolderParentId()
{
Response.Write("0");
|
|
From: <sv...@de...> - 2005-05-27 16:46:50
|
Author: marijn
Date: 2005-05-27 12:46:50 -0400 (Fri, 27 May 2005)
New Revision: 1168
Modified:
humano2/trunk/web/portal/site/readXslt.aspx
Log:
* Fixing uncorrectly commented lines. These are needed for filtering per=
tinence.
Modified: humano2/trunk/web/portal/site/readXslt.aspx
=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/readXslt.aspx 2005-05-27 16:36:00 UTC (=
rev 1167)
+++ humano2/trunk/web/portal/site/readXslt.aspx 2005-05-27 16:46:50 UTC (=
rev 1168)
@@ -160,7 +160,7 @@
/* Remark: Javascript always store the nodes in the same ord=
er: the order of creation */
var isObligatoryArray =3D new Array; /* array that stores th=
e booleans isObligatory for each attribute */
var attNameArray =3D new Array; /* array that stores the nam=
e of each attribute */
- //var attNameDict =3D new Array; /* array (dictionary) that =
stores the name, sysname relation. */
+ var attNameDict =3D new Array; /* array (dictionary) that st=
ores the name, sysname relation. */
var allInputsToCheck =3D new InputsToCheck();
var i=3D0; /* Counters */
var j=3D0;
@@ -179,7 +179,7 @@
<script language=3D"Javascript">
isObligatoryArray[i++]=3D'fa=
lse';
attNameArray[j++] =3D '<xsl:=
value-of select=3D"string($attributeName)"/>';
- //attNameDict["<xsl:value-of=
select=3D"string($attributeName)"/>"] =3D '<xsl:value-of select=3D"strin=
g($attributeSysName)"/>';
+ attNameDict["<xsl:value-of s=
elect=3D"string($attributeName)"/>"] =3D '<xsl:value-of select=3D"string(=
$attributeSysName)"/>';
</script>
<!-- If the field is obligatory =
add a star and put the JS variable isObligatory to false -->
<xsl:variable name=3D"isObligato=
ry" select=3D"/page/classInstance/structure/attribute[id_entity=3D$idAttr=
ibute]/isObligatory"/> =20
|
|
From: <sv...@de...> - 2005-05-27 16:35:58
|
Author: marijn Date: 2005-05-27 12:36:00 -0400 (Fri, 27 May 2005) New Revision: 1167 Modified: humano2/trunk/changelog.txt Log: * Updating changelog pre-beta3 release. Modified: humano2/trunk/changelog.txt =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/changelog.txt 2005-05-27 16:27:25 UTC (rev 1166) +++ humano2/trunk/changelog.txt 2005-05-27 16:36:00 UTC (rev 1167) @@ -1,4 +1,22 @@ +=3D=3D 5.0.beta3 - 2005-05-27 =3D=3D =20 + * Portal + * Searching: A field that is of type pertinence gets searched as the + user would expect (by name, not instance id) + + * Databases + * Added Driver for MicrosoftSQL server (pending issue is paging + with mssql #135) + + * Metamodel=20 + * Added new attribute types of attributes: + - Email + - Currency + - password + - HTML + - RUT + - URL + =3D=3D 5.0.beta2 - 2005-05-19 =3D=3D =20 * Portal |
|
From: <sv...@de...> - 2005-05-27 16:27:31
|
Author: svera
Date: 2005-05-27 12:27:25 -0400 (Fri, 27 May 2005)
New Revision: 1166
Modified:
humano2/trunk/web/builder/site/xsl/createview.xsl
Log:
* Fix bug #133
Modified: humano2/trunk/web/builder/site/xsl/createview.xsl
=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/builder/site/xsl/createview.xsl 2005-05-27 16:23:01=
UTC (rev 1165)
+++ humano2/trunk/web/builder/site/xsl/createview.xsl 2005-05-27 16:27:25=
UTC (rev 1166)
@@ -231,7 +231,7 @@
=20
</style>
<body >
- <form id=3D"formulario" name=3D"formulario" method=3D"post">
+ <form id=3D"formulario" name=3D"formulario" method=3D"post" =
>
<table width=3D"100%" border=3D"0" cellspacing=3D"0" cellpad=
ding=3D"0" class=3D"conttablecenter2">
<tr>
<td valign=3D"center" class=3D"smallgraytextnolink" =
>
@@ -475,7 +475,7 @@
<xsl:value-of se=
lect=3D"/view/viewDatas/saveName" />
</xsl:attribute>
<xsl:attribute name=3D=
"onclick">
- Form.UpdateSubmi=
tAll(rightColumn,expandFormSort,expandFormFilter); //Don't forget to do t=
he same in Form.UpdateHeader
+ return Form.Upda=
teSubmitAll(rightColumn,expandFormSort,expandFormFilter); //Don't forget =
to do the same in Form.UpdateHeader
</xsl:attribute>
</input>
</div>
|
Author: marijn
Date: 2005-05-27 12:23:01 -0400 (Fri, 27 May 2005)
New Revision: 1165
Modified:
humano2/trunk/components/formulas/ProcessFormulas.cs
humano2/trunk/components/import/Import.cs
humano2/trunk/components/rules/Rules.cs
humano2/trunk/components/viewTools/ViewTools.cs
humano2/trunk/components/webTools/Adapter.cs
humano2/trunk/components/webTools/session.cs
humano2/trunk/components/webTools/xmltools.cs
humano2/trunk/core/db/absComplex.cs
humano2/trunk/core/db/absCrud.cs
humano2/trunk/core/db/mssql/mssqlComplex.cs
humano2/trunk/core/db/mssql/mssqlConnection.cs
humano2/trunk/core/db/mssql/mssqlCrud.cs
humano2/trunk/core/db/pgsql/pgsqlComplex.cs
humano2/trunk/core/db/pgsql/pgsqlConnection.cs
humano2/trunk/core/db/pgsql/pgsqlCrud.cs
humano2/trunk/core/tests/mdPertinenceTests.cs
humano2/trunk/web/builder/site/buildattribute.aspx.cs
humano2/trunk/web/builder/site/combobox_type_entity.aspx.cs
humano2/trunk/web/builder/site/createInstanceRule.aspx.cs
humano2/trunk/web/builder/site/createreport.aspx.cs
humano2/trunk/web/builder/site/foldermanagement.aspx.cs
humano2/trunk/web/builder/site/formmanagement.aspx.cs
humano2/trunk/web/builder/site/formulamain.aspx.cs
humano2/trunk/web/builder/site/functionclasses.aspx.cs
humano2/trunk/web/builder/site/test.aspx.cs
humano2/trunk/web/builder/site/viewmain.aspx.cs
humano2/trunk/web/portal/site/report.aspx.cs
humano2/trunk/web/portal/site/search.aspx.cs
humano2/trunk/web/portal/site/showView.aspx.cs
humano2/trunk/web/portal/site/viewpertinencelist.aspx.cs
humano2/trunk/web/portal/site/viewrelations.aspx.cs
Log:
MERGE from braches/cleanup 1160:HEAD to trunk/
* Fixing many compiler warnings.
Modified: humano2/trunk/components/formulas/ProcessFormulas.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/components/formulas/ProcessFormulas.cs 2005-05-27 15:50=
:51 UTC (rev 1164)
+++ humano2/trunk/components/formulas/ProcessFormulas.cs 2005-05-27 16:23=
:01 UTC (rev 1165)
@@ -192,7 +192,7 @@
/// construye el resultado de la formula</sumary>
public DataTable GetDataTableResultFx(DataTable dtsql, DataTable dt2)
{
- string element,type,typeElement,typeFunction,fx;
+ string element,type,typeFunction,fx; //typeElement,
string expression=3D"";
int indice=3D1;
=20
@@ -209,7 +209,7 @@
{
element =3D dr["element"].ToString();
type =3D dr["type"].ToString();
- typeElement =3D dr["typeElement"].ToString();
+ //typeElement =3D dr["typeElement"].ToString();
if(type =3D=3D "elemento" || type =3D=3D "funcion")
{
expression =3D expression + dt2.Columns[indice].ColumnName;
@@ -238,7 +238,7 @@
{
element =3D dr["element"].ToString();
type =3D dr["type"].ToString();
- typeElement =3D dr["typeElement"].ToString();
+ //typeElement =3D dr["typeElement"].ToString();
typeFunction =3D dr["typeFunction"].ToString();
fx =3D dr["fx"].ToString();
if(type =3D=3D "elemento" || (type =3D=3D "funcion" && typeFunctio=
n =3D=3D "sql"))
@@ -598,7 +598,7 @@
string msj1,msj2;
DataSet ds1;
int idAtrib=3D0;
- int idPert=3D0;
+ //int idPert=3D0;
string typeElement;
int idTypeElement;
=09
@@ -644,7 +644,7 @@
theparams =3D this.TranslateField(element);
=09
idAtrib =3D theparams[0];
- idPert =3D theparams[1];
+ //idPert =3D theparams[1];
=09
drDats["theElement"] =3D element;
=09
@@ -714,7 +714,7 @@
public DataTable GetSqlElements(DataTable dt, int domainId, int column=
Id)
{
DataTable dtSql;
- string typeElement;
+ //string typeElement;
string fx, sqlView;
string typeFunction=3D"",theElement=3D"";
//int idAtrib, idRel;
@@ -728,7 +728,7 @@
drSql["type"] =3D dr["type"];
drSql["typeElement"] =3D dr["typeElement"];
drSql["idTypeElement"] =3D dr["idTypeElement"];
- typeElement =3D dr["typeElement"].ToString();
+ //typeElement =3D dr["typeElement"].ToString();
=09
if(dr["type"].ToString() =3D=3D "elemento")
{
@@ -781,7 +781,6 @@
=09
currentTableId =3D complex.TableId(columnId);
=20
- DataTable dtForm =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow dr =3D dtParam.NewRow();
=20
@@ -943,7 +942,7 @@
{
string tableTemp;
string strSQL;
- string element,type,typeElement,value,infoExtra;
+ string type,typeElement; // element,infoExtra,value
string nameColumn,typeDB;
int i;
=09
@@ -961,11 +960,11 @@
=09
foreach(DataRow draux in dt.Rows)
{
- element =3D draux["element"].ToString();
+ //element =3D draux["element"].ToString();
type =3D draux["type"].ToString();
typeElement =3D draux["typeElement"].ToString();
- value =3D draux["sqlView"].ToString();
- infoExtra =3D draux["infoExtraView"].ToString();
+ //value =3D draux["sqlView"].ToString();
+ //infoExtra =3D draux["infoExtraView"].ToString();
=09
if(type=3D=3D"elemento" || type=3D=3D"funcion")
{
@@ -988,9 +987,9 @@
{
string tableTemp;
string strSQL,strSQL2,strSQL3,sql1;
- string element,type,typeElement,value,infoExtra;
+ string element,type,value,infoExtra; // typeElement
string nameColumn;
- string theColumn,theTable;
+ string theTable; // theColumn,
int i;
=09
tableTemp =3D "tbltempfx"+columnId;
@@ -1001,7 +1000,7 @@
=09
=09
theTable =3D complex.TableName(columnId);
- theColumn =3D complex.ColumnName(columnId);
+ //theColumn =3D complex.ColumnName(columnId);
=20
//Primero se verificara que el datatable que viene, no trae Errores.
if(dt.Select("type like 'Error'").Length > 0)
@@ -1019,7 +1018,7 @@
{
element =3D draux["element"].ToString();
type =3D draux["type"].ToString();
- typeElement =3D draux["typeElement"].ToString();
+ //typeElement =3D draux["typeElement"].ToString();
value =3D draux["sqlView"].ToString();
infoExtra =3D draux["infoExtraView"].ToString();
=09
@@ -1082,7 +1081,7 @@
{
string tableTemp;
string strSQL,strSQL2,strSQL3,sql1,sql2;
- string element,type,typeElement,value,infoExtra;
+ string element,type; // ,infoExtra,value,typeElement
string nameColumn;
string theColumn,theTable;
int i;
@@ -1106,9 +1105,9 @@
{
element =3D draux["element"].ToString();
type =3D draux["type"].ToString();
- typeElement =3D draux["typeElement"].ToString();
- value =3D draux["sqlView"].ToString();
- infoExtra =3D draux["infoExtraView"].ToString();
+ //typeElement =3D draux["typeElement"].ToString();
+ //value =3D draux["sqlView"].ToString();
+ //infoExtra =3D draux["infoExtraView"].ToString();
=09
if(type=3D=3D"elemento" || type=3D=3D"funcion")
{
Modified: humano2/trunk/components/import/Import.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/components/import/Import.cs 2005-05-27 15:50:51 UTC (re=
v 1164)
+++ humano2/trunk/components/import/Import.cs 2005-05-27 16:23:01 UTC (re=
v 1165)
@@ -74,11 +74,11 @@
/// <param name=3D"attsArr">2 dimensional array wich contains Column =
name/Column definition.</param>
internal void createTables(string[,] attsArr)
{
- Hashtable classes =3D new Hashtable();
+ //Hashtable classes =3D new Hashtable();
=20
dsAtts=3D crud.ReadStructure(classId);
=20
- string xmlStr =3D dsAtts.GetXml();
+ //string xmlStr =3D dsAtts.GetXml();
=09
string[] cols =3D new string[1];
cols[0] =3D "classId";
@@ -239,14 +239,14 @@
=20
/// <summary>Reads the text file to be imported and is feed into a Da=
taTable, that DataTable is then passed to complex to fill the temporary i=
mport table</summary>
/// <param name=3D"srcFile">text file to be read</param>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
+ /// <param name=3D"attsArr">2-D which contains the file/db column mat=
ching information</param>
internal void LoadData(string srcFile, string[,] attsArr)
{
srcFile =3D srcFile.ToUpper().Replace("-TMP","-PROC");
using (StreamReader sr =3D new StreamReader(srcFile))
{
- string rawCols =3D sr.ReadLine();
- string[] rawColsArr =3D SplitDelimitedLine(rawCols,delimitator, qua=
lifier);
+ sr.ReadLine(); // string rawCols
+ //string[] rawColsArr =3D SplitDelimitedLine(rawCols,delimitator, q=
ualifier);
string line;
string[] lineArr;
// Read and display lines from the file until the end of
@@ -277,7 +277,6 @@
}
catch
{
- int n=3D0;
//FIXME: store line which containts invalid data in seperate file=
to make available in final report.
//The idea is that there is a class called Import Results.
//Each instance of that class has A) the original file uploaded, =
B) log file, C) file which contains the rows which had errors
@@ -290,7 +289,7 @@
=20
=20
/// <summary>Resolves the pertinence of the data being imported. </su=
mmary>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
+ /// <param name=3D"attsArr">2-D which contains the file/db column mat=
ching information</param>
internal void resolvePertinance(string[,] attsArr)
{
for (int i=3D0;i<attsArr.Length/3;i++)
@@ -328,7 +327,7 @@
/// <summary>
/// Call complex to generate the SQL statement to execute which will =
create the new instances and populate the class tables
/// </summary>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
+ /// <param name=3D"attsArr">2-D which contains the file/db column mat=
ching information</param>
internal void FinalImport(string[,] attsArr)
{
complex.finalImport(attsArr, dsAtts, tableName, domainId, classId);
@@ -344,7 +343,6 @@
/// arr[0] =3D Hello; There
/// arr[1] =3D world
/// </summary>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
public string[] SplitDelimitedLine(string CurrentLine, char Delimite=
r, char Qualifier)
{
int i;
@@ -442,7 +440,7 @@
classId =3D Convert.ToInt32(objXMLDOM.DocumentElement.SelectSingleNo=
de("/config/classId").InnerText);
delimitator =3D Convert.ToChar(objXMLDOM.DocumentElement.SelectSingl=
eNode("/config/delimitator").InnerText);
qualifierStr =3D objXMLDOM.DocumentElement.SelectSingleNode("/config=
/qualifier").InnerText;
- string updateAtts =3D objXMLDOM.DocumentElement.SelectSingleNode("/c=
onfig/updateAtts").InnerText;
+ //string updateAtts =3D objXMLDOM.DocumentElement.SelectSingleNode("=
/config/updateAtts").InnerText;
dbAttsStr =3D objXMLDOM.DocumentElement.SelectSingleNode("/config/db=
Atts").InnerText.Split(',');
fileAttsStr =3D objXMLDOM.DocumentElement.SelectSingleNode("/config/=
fileAtts").InnerText.Split(',');
rawFileFields =3D objXMLDOM.DocumentElement.SelectSingleNode("/confi=
g/rawFileFields").InnerText;
@@ -461,8 +459,8 @@
fileCols =3D io.SplitDelimitedLine(rawFileFields, delimitator,qualifi=
er);
=20
string[,] attsArr =3D new string[fileAttsStr.Length,3];
- ///attsArr gets returned and used everywhere in the import process. I=
t contains the
- ///column matching between the file being uploaded and the files in t=
he databse.
+ //attsArr gets returned and used everywhere in the import process. It=
contains the
+ //column matching between the file being uploaded and the files in th=
e databse.
for (int i =3D 0; i < fileAttsStr.Length; i++)
{
attsArr[i,0] =3D fileAttsStr[i]; //contains the ID of the column in =
the file
Modified: humano2/trunk/components/rules/Rules.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/components/rules/Rules.cs 2005-05-27 15:50:51 UTC (rev =
1164)
+++ humano2/trunk/components/rules/Rules.cs 2005-05-27 16:23:01 UTC (rev =
1165)
@@ -34,7 +34,6 @@
/// <returns></returns>
public object Test()
{
- DataTable dt =3D new DataTable();
return "Hola";
}
#endregion
@@ -120,7 +119,6 @@
{
int classId=3D1100;
string strfiltros =3D "";
- DataTable dtRules =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow dr =3D dtParam.NewRow();
int attributeId=3D0;
@@ -238,12 +236,12 @@
string attributes,operators,elements;
string[] arrAttributes,arrOperators,arrElements;
int attrib;
- int operatorId,setToId,idRel;
+ int operatorId; //,setToId,idRel;
string elementRule,setTo;
string valueRule=3D"";
string filtro=3D"";
int tableId=3D0;
- int[] theparams;
+ //int[] theparams;
DataTable dtEntitys =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow drParam =3D dtParam.NewRow();
@@ -279,10 +277,10 @@
else
finfiltro =3D "|0|0";
=20
- theparams =3D this.TranslateField(setTo);
+ //theparams =3D this.TranslateField(setTo);
=09
- setToId =3D theparams[0];
- idRel =3D theparams[1];
+ //setToId =3D theparams[0];
+ //idRel =3D theparams[1];
=20
tableId =3D complex.TableId(attrib);
=20
@@ -342,13 +340,13 @@
string attributes,operators,elements;
string[] arrAttributes,arrOperators,arrElements;
int attrib;
- int operatorId,setToId,idRel;
+ int operatorId; //,setToId,idRel;
string elementRule,setTo;
string valueRule=3D"";
string filtro=3D"";
int tableId=3D0;
- int[] theparams;
- DataTable dtEntitys =3D new DataTable();
+ //int[] theparams;
+ //DataTable dtEntitys =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow drParam =3D dtParam.NewRow();
=20
@@ -383,10 +381,10 @@
else
finfiltro =3D "|0|0";
=20
- theparams =3D this.TranslateField(setTo);
+ //theparams =3D this.TranslateField(setTo);
=09
- setToId =3D theparams[0];
- idRel =3D theparams[1];
+ //setToId =3D theparams[0];
+ //idRel =3D theparams[1];
=20
tableId =3D complex.TableId(attrib);
=20
@@ -466,16 +464,16 @@
public DataTable CreateDtToUpdate(int domainId, DataRow dr, DataTable =
dtEntity)
{
//int attrib=3D0;
- int setToId,idRel;
- string operatorRule,elementRule,setTo;
+ int setToId; //,idRel;
+ string setTo; // ,operatorRule,elementRule=20
string columnNameElement;
string tableName;
string valueRule;
- int tableId=3D0;
+ //int tableId=3D0;
int[] theparams;
- DataTable dtEntitys =3D new DataTable();
- DataTable dtParam =3D this.makeDataTableInViewTools();
- DataRow drParam =3D dtParam.NewRow();
+ //DataTable dtEntitys =3D new DataTable();
+ //DataTable dtParam =3D this.makeDataTableInViewTools();
+ //DataRow drParam =3D dtParam.NewRow();
=20
//Seccion del crud y el complex
crud.Domain =3D domainId;
@@ -485,17 +483,17 @@
vt.Complex =3D complex;
=20
//attrib =3D Convert.ToInt32(dr["attributeIdRule"].ToString());
- operatorRule =3D dr["operatorRule"].ToString();
- elementRule =3D dr["elementRule"].ToString();
+ //operatorRule =3D dr["operatorRule"].ToString();
+ //elementRule =3D dr["elementRule"].ToString();
setTo =3D dr["setTo"].ToString();
valueRule =3D dr["valueRule"].ToString();
=20
theparams =3D this.TranslateField(setTo);
=09
setToId =3D theparams[0];
- idRel =3D theparams[1];
+ //idRel =3D theparams[1];
=20
- tableId =3D complex.TableId(setToId);
+ //tableId =3D complex.TableId(setToId);
tableName =3D complex.TableName(setToId);
columnNameElement =3D complex.ColumnName(setToId);
=20
@@ -557,8 +555,9 @@
public string GetColumnsRules(int classId)
{
string str=3D"";
- DataTable dt1 =3D new DataTable();
- DataTable dtParam =3D this.makeDataTableInViewTools();
+ return str;
+ //DataTable dt1 =3D new DataTable();
+ /* DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow dr =3D dtParam.NewRow();
=20
dr["columna"] =3D "0";
@@ -569,11 +568,11 @@
ViewTools.ViewTools vt =3D new ViewTools.ViewTools(5);
//absCrud crud =3D Factory.Crud();
//absComplex complex =3D Factory.Complex(crud);
- vt.Complex =3D complex;
+ vt.Complex =3D complex; */
=20
- dt1 =3D vt.GetSQLDataTable(dtParam);
+ //dt1 =3D vt.GetSQLDataTable(dtParam);
=20
- return str;
+
}
=20
///<sumary>funcion que recorre el DT y actualiza la columna en la DB</=
sumary>
Modified: humano2/trunk/components/viewTools/ViewTools.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/components/viewTools/ViewTools.cs 2005-05-27 15:50:51 U=
TC (rev 1164)
+++ humano2/trunk/components/viewTools/ViewTools.cs 2005-05-27 16:23:01 U=
TC (rev 1165)
@@ -337,14 +337,14 @@
//{
=20
int pos =3D var.IndexOf(";");
- string a =3D var.Substring(pos + 1,7);
+ //string a =3D var.Substring(pos + 1,7);
if(var.Substring(pos + 1,7).ToLower() =3D=3D "\ninsert")
{
=20
createTable =3D var.Substring(0,pos);
var =3D var.Substring(var.IndexOf(";") + 2,var.Length - var.IndexO=
f(";") - 2);
pos =3D var.IndexOf(";");
- a =3D var.Substring(pos + 1,7);
+ //a =3D var.Substring(pos + 1,7);
=20
if(var.Substring(pos + 1,7).ToLower() =3D=3D "\nselect")
{
@@ -495,7 +495,7 @@
relations =3D GetRelatedTableList((string[])cols.ToArray(typeof(strin=
g)));
if(relations.Length > 0)
{
- ViewRelation previousRelation =3D null;=09
+ //ViewRelation previousRelation =3D null;=09
string relationType =3D "";
ArrayList tableDictionary =3D new ArrayList();
int counter =3D 1;
@@ -519,7 +519,7 @@
Query.Append(" =3D " + relation.EndTableName + "." + relation.Forei=
gnKeyName);
// Query.Append(" relTbl"+counter+" ON tblA." + relation.PrimaryKeyN=
ame);
// Query.Append(" =3D relTbl"+counter+"." + relation.ForeignKeyName)=
;
- previousRelation =3D relation;
+ //previousRelation =3D relation;
=20
if(tableDictionary.IndexOf(relation.EndTableName) =3D=3D -1)
{
@@ -711,10 +711,10 @@
{
StringBuilder strFilters =3D new StringBuilder();
string[] parameters;
- string iniFunction, endFunction;
+ string iniFunction; //endFunction;
string iniArgument, endArgument, operation;
string[] aux;
- int colIndex, intFilter, intIniFunc, intEndFunc;
+ int colIndex, intFilter, intIniFunc; //intEndFunc;
string tableName, columnName, tableName2, columnName2;
=09
foreach(string filter in strParams)
@@ -723,7 +723,7 @@
iniFunction =3D parameters[0].ToString();
iniArgument =3D parameters[1].ToString();
operation =3D parameters[2].ToString();
- endFunction =3D parameters[3].ToString();
+ //endFunction =3D parameters[3].ToString();
endArgument =3D parameters[4].ToString();
=20
intIniFunc =3D Convert.ToInt32(iniFunction);
@@ -759,7 +759,7 @@
=20
intFilter =3D Convert.ToInt32(operation);
=20
- intEndFunc =3D Convert.ToInt32(endFunction);
+ //intEndFunc =3D Convert.ToInt32(endFunction);
aux =3D endArgument.Split("^".ToCharArray());
if(aux[0].IndexOf("'") =3D=3D -1)
{
@@ -1299,10 +1299,10 @@
int[] parentIndexes;
int previousRelation =3D 0;
StringBuilder Query =3D new StringBuilder();
- string iniTable, endTable, entTable =3D "";
+ string iniTable, endTable;
+=09
+ parentIndexes =3D GetParentIndexes(intIdClass);
=20
- parentIndexes =3D GetParentIndexes(intIdClass);
-
for(int i =3D 0; i<=3D parentIndexes.Length - 2;i++)
{
iniTable =3D Complex.TableName(parentIndexes[i]);
@@ -1310,12 +1310,8 @@
if(previousRelation =3D=3D 0)
{
Query.Append(iniTable + " inner join " + endTable);
-// Query.Append(iniTable + " tblA inner join " + endTable + " tbl"+i=
);
Query.Append(" on " + iniTable + ".id_entity");
Query.Append(" =3D " + endTable + ".id_entity ");
-// Query.Append(" on tblA.id_entity");
-// Query.Append(" =3D tbl"+i+".id_entity ");
-// if (endTable =3D=3D "\"entity\"") entTable =3D "tbl"+i;
previousRelation =3D 1;
}
else
@@ -1327,7 +1323,6 @@
}
}
Query.Append("and entity.\"delDate\" is null ");
-// Query.Append("and "+entTable+".\"delDate\" is null ");
return Query.ToString();
}
=20
@@ -1429,8 +1424,8 @@
=20
int regIndex =3D Convert.ToInt32(dr[0].ItemArray[0]);
string owner =3D dr[0].ItemArray[1].ToString();
- string to =3D dr[0].ItemArray[2].ToString();
- string ratio =3D dr[0].ItemArray[3].ToString();
+ //string to =3D dr[0].ItemArray[2].ToString();
+ //string ratio =3D dr[0].ItemArray[3].ToString();
=20
toColumnIndex =3D Convert.ToInt32(owner);
columnNameTo =3D Complex.ColumnName(toColumnIndex);
@@ -1453,8 +1448,8 @@
}
=20
owner =3D dr[0].ItemArray[1].ToString();
- to =3D dr[0].ItemArray[2].ToString();
- ratio =3D dr[0].ItemArray[3].ToString();
+ //to =3D dr[0].ItemArray[2].ToString();
+ //ratio =3D dr[0].ItemArray[3].ToString();
=20
fromColumnIndex =3D Convert.ToInt32(owner);
tableNameFrom =3D Complex.TableName(fromColumnIndex);
@@ -1468,9 +1463,9 @@
=20
rel =3D Enums.RelationType.ManyToOne;
=20
- // NewRelationInstance(tableNameFrom, columnNameFrom, ta=
bleNameTo, columnNameTo,
- // fromTableIndex, toTableIndex, fromColumnIndex, toCol=
umnIndex,
- // rel, ref Relations);=09
+ //NewRelationInstance(tableNameFrom, columnNameFrom, tableNameT=
o, columnNameTo,
+ //fromTableIndex, toTableIndex, fromColumnIndex, toColumnIndex,
+ //rl, ref Relations);=09
}
else
{
Modified: humano2/trunk/components/webTools/Adapter.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/components/webTools/Adapter.cs 2005-05-27 15:50:51 UTC =
(rev 1164)
+++ humano2/trunk/components/webTools/Adapter.cs 2005-05-27 16:23:01 UTC =
(rev 1165)
@@ -90,12 +90,11 @@
/// <summary>
/// Entrega un DataTable con las clases existentes de acuerdo al tipo
/// </summary>
- /// <param name=3D"type">tipo de la clase</param>
/// <returns>DataTable</returns>
- public DataTable GetClassesFromTypePertinence(int id_entity, int domai=
n)
+ public DataTable GetClassesFromTypePertinence(int idEntity, int domain=
Id)
{
DataTable res;
- res =3D complex.GetClassesFromTypePertinence(id_entity, domain);
+ res =3D complex.GetClassesFromTypePertinence(idEntity, domainId);
return res;
}
=20
@@ -149,13 +148,13 @@
///<summary>Get values from a view for pertinence filtering view.</sum=
mary>
///<param name=3D"viewId">The Id of the view that is doing the filteri=
ng</param>
///<param name=3D"idClassView">The class that the view is asociated wi=
th.</param>
- ///<param name=3D"viewColumn">The column of the filter value.</param>
- ///<param name=3D"viewWhere">The conditions under which the filter wor=
ks.</param>
+ ///<param name=3D"filterValue">The column of the filter value.</param>
+ ///<param name=3D"displayColumn">The conditions under which the filter=
works.</param>
///<returns>The filtering value to be replaced</returns>
public string GetPertinenceFilterValues(int viewId, out int idClassVie=
w, out string filterValue, out string displayColumn)
{
string viewValue;
- int viewColumn;
+ //int viewColumn;
=20
int iniClass =3D (int) ViewConsts.ViewClass;
=09
@@ -218,7 +217,7 @@
/// <summary>
/// Entrega un DataTable con los atributos de un atributo
/// </summary>
- /// <param name=3D"classId">id del atributo</param>
+ /// <param name=3D"attId">id del atributo</param>
/// <returns>DataTable</returns>
public DataTable GetAttributesFromAttribute(int attId)
{
@@ -280,7 +279,7 @@
Humano2.Components.ViewTools.ViewTools vt =3D new ViewTools.ViewTo=
ols();
vt.Complex =3D complex;
=09
- DataTable table =3D getViewToolsTable();
+ //DataTable table =3D getViewToolsTable();
=20
// Get the id_entity and the domainName of all the domains in the sys=
tem.
string columns =3D "1012,1013,1014,1015,1016,1017,1018";
@@ -319,11 +318,11 @@
///<param name=3D"iniClass">The class that the DataTable's View sho=
uld act on.</param>
///<param name=3D"order">The ViewTools formated string with the ord=
er.</param>
///<param name=3D"page">The page that should be shown.</param>
- ///<param name=3D"keyFlag">The key Flag to use (0: for group by,=
1: without group)</param>
- ///<param name=3D"pageCount">The Number of pages of this view.</par=
am>
+ ///<param name=3D"keyFlag">The key Flag to use (0: for group=
by,1: without group)</param>
+
///<returns>The datatable that is the result of executing the view.=
</returns>
public DataTable ExecViewFromDataTable(int iniClass, DataTable vtTa=
ble, int idEntity, string order,=20
- int page, int keyFlag)
+ int page, int keyFlag)
{
// We got the data.. Do the viewTools invocation with the data.
Humano2.Components.ViewTools.ViewTools vt =3D new Humano2.Components.=
ViewTools.ViewTools(iniClass);
@@ -659,7 +658,7 @@
{
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -705,7 +704,7 @@
{
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -848,7 +847,7 @@
///<param name=3D"userId">The Id of the user.</param>
///<param name=3D"email">The email of the user name. In Humano2 the em=
ail is the login name</param>
///<param name=3D"pass">The password of the user</param>
- ///<param name=3D"domains">List of Ids that the user is subscribed to<=
/param>
+ ///<param name=3D"domainIds">List of Ids that the user is subscribed t=
o</param>
public void UpdateUser(int userId, string email, string pass, ArrayLis=
t domainIds)=20
{
DataSet ds =3D prepareUserData(userId, email, pass, domainIds);
@@ -934,7 +933,7 @@
return ds; =09
}
=09
- #region Read's Structural and Data
+ #region Reads Structural and Data
=20
/// <summary>
/// Lee la estructura de una entity (Instancia)
@@ -1035,9 +1034,9 @@
=20
/// <summary>
/// To get the class name by its id
- /// <param name=3D"classId">The id of the class</name>
- /// <returns>The name of class</returns>
/// </summary>
+ /// <param name=3D"classId">The id of the class</param>
+ /// <returns>The name of class</returns>
public string GetClassNameById(int classId)
{
=20
@@ -1113,7 +1112,7 @@
=20
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D this.getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -1165,7 +1164,7 @@
{
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D this.getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -1275,13 +1274,14 @@
///<remarks>better to do this seperately so we can better control what=
get's changed.</remarks>
///<param name=3D"classId">The id of the class to update</param>
///<param name=3D"domainId">The domain of the user</param>
- ///<param name=3D"domainId">the data for the update</param>
+ ///<param name=3D"className">the data for the update</param>
public void UpdateClass(int classId, int domainId, string className)
{ =09
Logger.Log("UpdateClass: changing classId " + classId + " name is now=
: " + className, LogLevel.Trace);
complex.UpdateClass(classId, domainId, className);
}
=09
+ /// <summary>
/// Method create
/// </summary>
/// <param name=3D"id_entity">An int</param>
@@ -1397,9 +1397,9 @@
}
=20
/// <summary>Marks one attribute of a class as obligatory.</summary=
>
- /// <param name=3D"primaryId">The id of the attribute that is to be=
primary.</summary>
- /// <param name=3D"classId">The class of the attribute</summary>
- /// <param name=3D"domainId">The domain Id of the class.</summary>
+ /// <param name=3D"primaryId">The id of the attribute that is to be=
primary.</param>
+ /// <param name=3D"classId">The class of the attribute</param>
+ /// <param name=3D"domainId">The domain Id of the class.</param>
public void SetAttributeAsPrimary(int primaryId, int classId, int d=
omainId)
{
// Remove the isPrimary label from all attributes. =20
@@ -1495,8 +1495,7 @@
/// Cambia los attributos de un view.
/// </summary>
/// <param name=3D"idEntity">An int</param>
- /// <param name=3D"idClass">An int</param>
- /// <param name=3D"viewName">A string</param>
+ /// <param name=3D"classId">An int</param>
/// <param name=3D"idDomain">An int</param>
/// <param name=3D"mode">An int</param>
public void ChangeAttributesOfView(int idEntity, int classId, int idDo=
main, int mode)
@@ -1817,7 +1816,6 @@
=20
DataTable res =3D GetAttributesFromClass(classId);
int idAtt =3D 0;
- int i=3D0;
foreach(DataRow row in res.Rows)
{
if(complex.IsPrimary(Convert.ToInt32(row["id_entity"])))
Modified: humano2/trunk/components/webTools/session.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/components/webTools/session.cs 2005-05-27 15:50:51 UTC =
(rev 1164)
+++ humano2/trunk/components/webTools/session.cs 2005-05-27 16:23:01 UTC =
(rev 1165)
@@ -128,7 +128,6 @@
{
value.lastAccess =3D DateTime.Now;
string key;
- int i =3D 1;
=20
//Tomo el mutex para no repetir key's
mutexKey.WaitOne();
Modified: humano2/trunk/components/webTools/xmltools.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/components/webTools/xmltools.cs 2005-05-27 15:50:51 UTC=
(rev 1164)
+++ humano2/trunk/components/webTools/xmltools.cs 2005-05-27 16:23:01 UTC=
(rev 1165)
@@ -60,10 +60,10 @@
///Do an XSLT transform with an xml string and an System=
.Xml.Xsl.XslTransform object
///</summary>
///<param name=3D'strXML'>The string of the xml document=
</param>
- ///<param name=3D'strXSLURL'>The url of the xsl</param>
+ ///<param name=3D'xsl'>The url of the xsl</param>
///<param name=3D'Response'>The html response object to =
send exception if needed</param>
///<returns>The result of transformation</returns>
- private static string TransformXML(string strXML, System=
.Xml.Xsl.XslTransform xsl,System.Web.HttpResponse Response)
+ private static string TransformXML(string strXML, System=
.Xml.Xsl.XslTransform xsl, System.Web.HttpResponse Response)
{
=20
//Logger.Log("Result of transformation: " + strX=
ML, LogLevel.Trace);
@@ -77,7 +77,7 @@
catch (System.Exception e)
{
//Put in custom error handler here...
- string x =3D e.ToString();
+ //string x =3D e.ToString();
//Response.Write(x);
}
=20
Modified: humano2/trunk/core/db/absComplex.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/core/db/absComplex.cs 2005-05-27 15:50:51 UTC (rev 1164=
)
+++ humano2/trunk/core/db/absComplex.cs 2005-05-27 16:23:01 UTC (rev 1165=
)
@@ -194,10 +194,9 @@
abstract public DataTable GetViewData(int viewId);
=20
///<summary>Get the structure of a report.</summary>
- ///<param name=3D"viewId">The id of the report.</param>
+ ///<param name=3D"reportId">The id of the report.</param>
///<returns>a datatable with the information about the report.</return=
s>
abstract public DataTable GetReportData(int reportId);
- =09
=20
///<summary>gets all the formulas that are related to attribtes of =
a class</summary>
///<param name=3D"classId">The Id of fthe class</param>
@@ -330,38 +329,38 @@
abstract public void finalImport(string [,] attsArr, DataSet dsAtts, s=
tring tableName, int domainId, int classId);
=20
/// <summary>
- /// Get the string id of the pertinence attribute an attribute is rela=
ted to
- /// <param name=3D"attribute">The attribute for which we want th=
e pertinence attribute related to
+ /// Get the string id of the pertinence attribute an attribute is relat=
ed to
/// </summary>
- /// <return>The attribute of the pertinence attribute or "" if a=
ttributeId is not a pertinence attribute</returns>
+ /// <param name=3D"attributeId">The attribute for which we want =
the pertinence attribute related to</param>
+ /// <returns>The attribute of the pertinence attribute or "" if =
attributeId is not a pertinence attribute</returns>
abstract public string GetPertinenceForAttribute(string attribut=
eId);
=20
/// <summary>
- /// Converts a system attribute name into a user attribute name
+ /// Converts a system attribute name into a user attribute name
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>user attribute name</returns>
+ /// <returns>user attribute name</returns>
abstract public string ConvertSysAttNameToUserAttName(string sys=
AttName);
=20
/// <summary>
/// Converts a system attribute name into its id
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param>
- /// <return>id of attribute</returns>
+ /// <returns>id of attribute</returns>
abstract public int ConvertSysAttNameToIdAttName(string sysAttName);
=20
/// <summary>
/// Tells if an attribute is primary=20
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
abstract public bool IsPrimary(string sysAttName);
=20
/// <summary>
- /// Tells if an attribute is primary=20
+ /// Tells if an attribute is primary=20
/// </summary>
- /// <param name=3D"sysAttName">id of attribute </param>
- /// <return>true if attribute is primary</returns>
+ /// <param name=3D"attId">id of attribute </param>
+ /// <returns>true if attribute is primary</returns>
abstract public bool IsPrimary(int attId);
=20
abstract public bool IsSelfLookUp(string sysAttName);
@@ -370,22 +369,23 @@
/// Get the params (where, orderby etc...) of a view
/// </summary>
/// <param name=3D"id">id of view</param>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
abstract public string [] GetParamsView(int id);
=20
/// <summary>
- /// Get the params (where, orderby etc...) of a report
+ /// Get the params (where, orderby etc...) of a report
/// </summary>
/// <param name=3D"id">id of report</param>
- /// <return>params of the report</returns>
+ /// <returns>params of the report</returns>
abstract public string [] GetParamsReport(int id);
=20
=20
///<summary>
- /// Returns the name of the basic attribute (numeric, textline..=
.) father of an attribute passed in param
+ /// Returns the name of the basic attribute (numeric, textline..=
.) father of an attribute passed in param =20
+ ///</summary>
/// <param name=3D"classId">The classId of an attribute</param>
/// <returns>the sys name of basic attribute</returns>
- ///</summary>
+
abstract public string GetBasicAttributeSysName(int classId);
=20
=20
Modified: humano2/trunk/core/db/absCrud.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/core/db/absCrud.cs 2005-05-27 15:50:51 UTC (rev 1164)
+++ humano2/trunk/core/db/absCrud.cs 2005-05-27 16:23:01 UTC (rev 1165)
@@ -461,8 +461,9 @@
dr["parentId"]=3D navTableId;
dr["parentPertinence"]=3D pertAttId;
dt.Rows.Add(dr);
- int toColumn =3D Create((int) MetaModelConsts.EntitiesPertinence, dt)=
;
=20
+ Create((int) MetaModelConsts.EntitiesPertinence, dt);
+
// Update the pertinence, pointing the owner to the navTable.
updatePertinenceNM(pertAttId, navTableId, fromColumn);
}
Modified: humano2/trunk/core/db/mssql/mssqlComplex.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/core/db/mssql/mssqlComplex.cs 2005-05-27 15:50:51 UTC (=
rev 1164)
+++ humano2/trunk/core/db/mssql/mssqlComplex.cs 2005-05-27 16:23:01 UTC (=
rev 1165)
@@ -88,7 +88,7 @@
}
=20
///<summary>Get the structure of a report.</summary>
- ///<param name=3D"viewId">The id of the report.</param>
+ ///<param name=3D"reportId">The id of the report.</param>
///<returns>a datatable with the information about the report.</return=
s>
public override DataTable GetReportData(int reportId)=20
{
@@ -159,9 +159,10 @@
/// <summary>
/// Entrega un DataTable con las clases existentes de acuerdo al tipo
/// </summary>
- /// <param name=3D"type">tipo de la clase</param>
+ /// <param name=3D"idEntity">Id del pertience cual estamos buscando re=
laciones.</param>
+ /// <param name=3D"domainId">Id del dominio de los elementos</param>
/// <returns>DataTable</returns>
- public override DataTable GetClassesFromTypePertinence(int id_entity, =
int domain)
+ public override DataTable GetClassesFromTypePertinence(int idEntity, i=
nt domainId)
{
string query;
DataTable res;
@@ -170,14 +171,14 @@
c.id_entity,
c.name,
(select ""ratio"" from pertinence p, entity en
- where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + id_entity.ToString() + @" and
+ where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + idEntity + @" and
en.id_entity =3D p.id_entity and en.""delDate"" is null) as r=
atio
from class c, entity e
where
c.id_entity =3D e.id_entity and
c.""isHidden"" =3D '0' and
e.""delDate"" is null and
- e.""domainId"" in (" + domain.ToString() + @", 10) order by c.""c=
lassType"" DESC, c.name";
+ e.""domainId"" in (" + domainId + @", 10) order by c.""classType"=
" DESC, c.name";
=09
res =3D this.doSelect(query);
return res;
@@ -900,10 +901,10 @@
}
=20
/// <summary>
- /// Get the string id of the pertinence attribute an attribute is rela=
ted to
+ /// Get the string id of the pertinence attribute an attribute is relat=
ed to
/// </summary>
- /// <param name=3D"attribute">The attribute for which we want th=
e pertinence attribute related to</param>
- /// <return>The attribute of the pertinence attribute or "" if a=
ttributeId is not a pertinence attribute</returns>
+ /// <param name=3D"attributeId">The attribute for which we want =
the pertinence attribute related to</param>
+ /// <returns>The attribute of the pertinence attribute or "" if =
attributeId is not a pertinence attribute</returns>
override public string GetPertinenceForAttribute(string attribut=
eId)
{
string req =3D "select \"id_entity\" from attribute where \"=
classId\" in (select \"to\" from pertinence where id_entity =3D " + Conve=
rt.ToInt32(attributeId) + ")";
@@ -920,10 +921,10 @@
}
=20
/// <summary>
- /// Converts a system attribute name into a user attribute name
+ /// Converts a system attribute name into a user attribute name
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>user attribute name</returns>
+ /// <returns>user attribute name</returns>
override public string ConvertSysAttNameToUserAttName(string sys=
AttName)
{
string req =3D "select \"attName\" from attribute where \"sy=
sAttName\" =3D '" + sysAttName +"'";
@@ -944,7 +945,7 @@
/// Tells if an attribute is primary=20
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(string sysAttName)
{
string req =3D "select \"isPrimary\" from attribute where \"=
sysAttName\" =3D '" + sysAttName + "'";
@@ -968,8 +969,8 @@
/// <summary>
/// Tells if an attribute is primary=20
/// </summary>
- /// <param name=3D"sysAttName">id of attribute </param>
- /// <return>true if attribute is primary</returns>
+ /// <param name=3D"attId">id of attribute </param>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(int attId)
{
string req =3D "select \"isPrimary\" from attribute where \"=
id_entity\" =3D '" + attId + "'";
@@ -1016,7 +1017,7 @@
/// Get the params (where, orderby etc...) of a view
/// </summary>
/// <param name=3D"id">id of view</param>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
override public string [] GetParamsView(int id)
{
string idStr =3D Convert.ToString(id);
@@ -1043,7 +1044,7 @@
/// Get the params (where, orderby etc...) of a report
/// </summary>
/// <param name=3D"id">id of report</param>
- /// <return>params of the report</returns>
+ /// <returns>params of the report</returns>
override public string [] GetParamsReport(int id)
{
string idStr =3D Convert.ToString(id);
@@ -1087,7 +1088,7 @@
foreach(DataRow dRow in tmpTable.Rows)
{
int attribClass =3D Convert.ToInt32(dRow[classIdCol[0]]);
- string colname =3D dRow[classIdCol[0]].ToString();
+ //string colname =3D dRow[classIdCol[0]].ToString();
string classTable =3D getTableName(attribClass);
switch (classId)
{
Modified: humano2/trunk/core/db/mssql/mssqlConnection.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/core/db/mssql/mssqlConnection.cs 2005-05-27 15:50:51 UT=
C (rev 1164)
+++ humano2/trunk/core/db/mssql/mssqlConnection.cs 2005-05-27 16:23:01 UT=
C (rev 1165)
@@ -255,11 +255,11 @@
=09
tgtTable.TableName =3D fillTable;
tgtTable =3D srcTable.Copy( );
- SqlCommandBuilder SqlCB =3D new SqlCommandBuilder( da );
+ //SqlCommandBuilder SqlCB =3D new SqlCommandBuilder( da );
da.Fill( tgtTable );
tgtTable =3D srcTable.Copy( );
ds.Tables.Add( tgtTable );
- string strXml =3D ds.GetXml( );
+ //string strXml =3D ds.GetXml( );
da.Update( tgtTable );
Close();
}
Modified: humano2/trunk/core/db/mssql/mssqlCrud.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/core/db/mssql/mssqlCrud.cs 2005-05-27 15:50:51 UTC (rev=
1164)
+++ humano2/trunk/core/db/mssql/mssqlCrud.cs 2005-05-27 16:23:01 UTC (rev=
1165)
@@ -94,15 +94,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
@@ -344,15 +344,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
Modified: humano2/trunk/core/db/pgsql/pgsqlComplex.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/core/db/pgsql/pgsqlComplex.cs 2005-05-27 15:50:51 UTC (=
rev 1164)
+++ humano2/trunk/core/db/pgsql/pgsqlComplex.cs 2005-05-27 16:23:01 UTC (=
rev 1165)
@@ -88,8 +88,8 @@
return res; =09
}
=09
- ///<summary>Get the structure of a report.</summary>
- ///<param name=3D"viewId">The id of the report.</param>
+ ///<summary>Get the structure of a report.</summary>
+ ///<param name=3D"reportId">The id of the report.</param>
///<returns>a datatable with the information about the report.</return=
s>
public override DataTable GetReportData(int reportId)=20
{
@@ -164,9 +164,10 @@
/// <summary>
/// Entrega un DataTable con las clases existentes de acuerdo al tipo
/// </summary>
- /// <param name=3D"type">tipo de la clase</param>
+ /// <param name=3D"idEntity">Id del pertience cual estamos buscando re=
laciones.</param>
+ /// <param name=3D"domainId">Id del dominio de los elementos</param>
/// <returns>DataTable</returns>
- public override DataTable GetClassesFromTypePertinence(int id_entity, =
int domain)
+ public override DataTable GetClassesFromTypePertinence(int idEntity, i=
nt domainId)
{
string query;
DataTable res;
@@ -175,14 +176,14 @@
c.id_entity,
c.name,
(select ""ratio"" from pertinence p, entity en
- where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + id_entity.ToString() + @" and
+ where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + idEntity + @" and
en.id_entity =3D p.id_entity and en.""delDate"" is null) as r=
atio
from class c, entity e
where
c.id_entity =3D e.id_entity and
c.""isHidden"" =3D 'f' and
e.""delDate"" is null and
- e.""domainId"" in (" + domain.ToString() + @", 10) order by c.""c=
lassType"" DESC, c.name";
+ e.""domainId"" in (" + domainId + @", 10) order by c.""classType"=
" DESC, c.name";
=09
res =3D this.doSelect(query);
return res;
@@ -944,8 +945,8 @@
/// <summary>
/// Get the string id of the pertinence attribute an attribute is rela=
ted to
/// </summary>
- /// <param name=3D"attribute">The attribute for which we want th=
e pertinence attribute related to</param>
- /// <return>The attribute of the pertinence attribute or "" if a=
ttributeId is not a pertinence attribute</returns>
+ /// <param name=3D"attributeId">The attribute for which we want =
the pertinence attribute related to</param>
+ /// <returns>The attribute of the pertinence attribute or "" if =
attributeId is not a pertinence attribute</returns>
override public string GetPertinenceForAttribute(string attribut=
eId)
{
string req =3D "select \"id_entity\" from attribute where \"=
classId\" in (select \"to\" from pertinence where id_entity =3D " + Conve=
rt.ToInt32(attributeId) + ")";
@@ -962,10 +963,10 @@
}
=20
/// <summary>
- /// Converts a system attribute name into a user attribute name
+ /// Converts a system attribute name into a user attribute name
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>user attribute name</returns>
+ /// <returns>user attribute name</returns>
override public string ConvertSysAttNameToUserAttName(string sys=
AttName)
{
string req =3D "select \"attName\" from attribute where \"sy=
sAttName\" =3D '" + sysAttName +"'";
@@ -983,10 +984,10 @@
}
=20
/// <summary>
- /// Tells if an attribute is primary=20
+ /// Tells if an attribute is primary=20
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(string sysAttName)
{
string req =3D "select \"isPrimary\" from attribute where \"=
sysAttName\" =3D '" + sysAttName + "'";
@@ -1008,10 +1009,10 @@
}
=20
/// <summary>
- /// Tells if an attribute is primary=20
+ /// Tells if an attribute is primary=20
/// </summary>
- /// <param name=3D"sysAttName">id of attribute </param>
- /// <return>true if attribute is primary</returns>
+ /// <param name=3D"attId">id of attribute </param>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(int attId)
{
string req =3D "select \"isPrimary\" from attribute where \"=
id_entity\" =3D '" + attId + "'";
@@ -1052,14 +1053,13 @@
return IsSelfLookUp;
} =20
/// <summary>
- /// Get the params (where, orderby etc...) of a view
+ /// Get the params (where, orderby etc...) of a view
/// </summary>
- /// <param name=3D"id">id of view</param>
- /// <return>params of view in a array</returns>
- override public string [] GetParamsView(int id)
+ /// <param name=3D"viewId">id of view</param>
+ /// <returns>params of view in a array</returns>
+ override public string [] GetParamsView(int viewId)
{ =20
-
- string idStr =3D Convert.ToString(id);
+ string idStr =3D Convert.ToString(viewId);
string req =3D "select \"groupby\", \"columns\",\"where\",\"=
order\" from view where id_entity=3D" + idStr;
string [] res =3D new string[4];
=20
@@ -1081,13 +1081,13 @@
=20
=20
/// <summary>
- /// Get the params (where, orderby etc...) of a report
+ /// Get the params (where, orderby etc...) of a report
/// </summary>
- /// <param name=3D"id">id of report</param>
- /// <return>params of the report</returns>
- override public string [] GetParamsReport(int id)
+ /// <param name=3D"reportId">id of report</param>
+ /// <returns>params of the report</returns>
+ override public string [] GetParamsReport(int reportId)
{
- string idStr =3D Convert.ToString(id);
+ string idStr =3D Convert.ToString(reportId);
string req =3D "select \"columns\",\"where\",\"order\",\"gr=
oupby\",\"having\",\"idClassReport\" from report where id_entity=3D" + id=
Str;
string [] res =3D new string[6];
=20
@@ -1128,7 +1128,7 @@
foreach(DataRow dRow in tmpTable.Rows)
{
int attribClass =3D Convert.ToInt32(dRow[classIdCol[0]]);
- string colname =3D dRow[classIdCol[0]].ToString();
+ //string colname =3D dRow[classIdCol[0]].ToString();
string classTable =3D getTableName(attribClass);
switch (classId)
{
Modified: humano2/trunk/core/db/pgsql/pgsqlConnection.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/core/db/pgsql/pgsqlConnection.cs 2005-05-27 15:50:51 UT=
C (rev 1164)
+++ humano2/trunk/core/db/pgsql/pgsqlConnection.cs 2005-05-27 16:23:01 UT=
C (rev 1165)
@@ -129,14 +129,14 @@
override public object doScalar(string query)
{
// Cast-down a tipo mas potente.
- object tmpObj;
+ //object tmpObj;
Open();
NpgsqlConnection conn =3D ( (NpgsqlConnection) dbCon );
NpgsqlCommand dbCmd =3D conn.CreateCommand( );
dbCmd.CommandText =3D query;
=09
IDataReader dr;
- try
+ try
{
dr =3D dbCmd.ExecuteReader( );
Close();
@@ -151,7 +151,7 @@
=20
if( dr.Read( ) && !Convert.IsDBNull( dr[0] ) )
{
- tmpObj =3D dr[0];
+ //tmpObj =3D dr[0];
dr.Close();
dbCmd.Dispose();
return dr[0];
@@ -246,11 +246,11 @@
=09
tgtTable.TableName =3D fillTable;
tgtTable =3D srcTable.Copy( );
- NpgsqlCommandBuilder SqlCB =3D new NpgsqlCommandBuilder( da );
+ //NpgsqlCommandBuilder SqlCB =3D new NpgsqlCommandBuilder( da );
da.Fill( tgtTable );
tgtTable =3D srcTable.Copy( );
ds.Tables.Add( tgtTable );
- string strXml =3D ds.GetXml( );
+ //string strXml =3D ds.GetXml( );
da.Update( tgtTable );
Close();
}
Modified: humano2/trunk/core/db/pgsql/pgsqlCrud.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/core/db/pgsql/pgsqlCrud.cs 2005-05-27 15:50:51 UTC (rev=
1164)
+++ humano2/trunk/core/db/pgsql/pgsqlCrud.cs 2005-05-27 16:23:01 UTC (rev=
1165)
@@ -97,15 +97,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
@@ -344,15 +344,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
Modified: humano2/trunk/core/tests/mdPertinenceTests.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/core/tests/mdPertinenceTests.cs 2005-05-27 15:50:51 UTC=
(rev 1164)
+++ humano2/trunk/core/tests/mdPertinenceTests.cs 2005-05-27 16:23:01 UTC=
(rev 1165)
@@ -46,7 +46,7 @@
string[] pertNamesTable =3D {"attName", "classId", "to", "ratio"=
};
object[] pertValuesTable=3D {"Trabajo", persId , empresaId, "n:1"};
DataTable dt =3D utils.buildTable(pertNamesTable, pertValuesTable);
- int trabID =3D crud.Create((int) MetaModelConsts.EntitiesPertinence, =
dt);
+ crud.Create((int) MetaModelConsts.EntitiesPertinence, dt); // int tra=
bID
}
=20
[Test]
@@ -156,13 +156,13 @@
string[] accRelNamesTable =3D {"attName","classId", "to", "ratio"=
};
object[] accRelValuesTable=3D {"access" ,navId, accessId, "n:1"};
dt =3D utils.buildTable(accRelNamesTable, accRelValuesTable);
- int accRelAttId =3D crud.Create((int) MetaModelConsts.EntitiesPertine=
nce, dt);
+ crud.Create((int) MetaModelConsts.EntitiesPertinence, dt); // int acc=
RelAttId
=09
int[] pIds =3D createPersonas(persId);
=09
int[] aIds =3D creaAccessos(accessId);
=09
- int e1Id =3D createNAVEmpresa(empresaId, navId, pIds, aIds);
+ createNAVEmpresa(empresaId, navId, pIds, aIds); // int e1Id
=09
// Console.WriteLine("***** NAV TABLE *****\n\n");
// DbUtils.DumpData(crud.ReadStructure(navId));
@@ -289,7 +289,7 @@
string[] levelNamesTable =3D {"attName", "classId"};
object[] levelValuesTable=3D {"level" , accessId};
dt =3D utils.buildTable(levelNamesTable, levelValuesTable);
- int levelAttId =3D crud.Create((int) testConsts.entityIdTextLine, dt)=
;
+ crud.Create((int) testConsts.entityIdTextLine, dt); // int levelAttId
=09
return accessId;
}
Modified: humano2/trunk/web/builder/site/buildattribute.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/builder/site/buildattribute.aspx.cs 2005-05-27 15:5=
0:51 UTC (rev 1164)
+++ humano2/trunk/web/builder/site/buildattribute.aspx.cs 2005-05-27 16:2=
3:01 UTC (rev 1165)
@@ -488,7 +488,6 @@
}
=20
int viewClassId;
- string viewColumn;
string viewWhereComplete;
string displayColumn;
string variableName =3D userCred.CoreAdapter.GetPertinenceFilterValu=
es(filterViewId, out viewClassId, out viewWhereComplete, out displayColum=
n);
@@ -754,8 +753,7 @@
string viewStr =3D Convert.ToString( getDataFromSetByIdEntity(pertSe=
t, (int) PertinenceConsts.FilterView) );
if(viewStr !=3D "")=20
{
- int commaIndex =3D -1;
- if( (commaIndex =3D viewStr.IndexOf(',')) =3D=3D -1)
+ if( viewStr.IndexOf(',') =3D=3D -1)
{
tblViewId =3D Convert.ToInt32(viewStr);
}=20
@@ -776,7 +774,6 @@
}
=09
res.Append(@"<select name=3D""to"" class=3D""pbttn"" onchange=3D""relo=
adPermClass(this.options[this.selectedIndex].value)"">");
- string currRatio =3D "";
foreach(DataRow classRow in dt.Rows) {
int rowClassId =3D Convert.ToInt32(classRow[0]);
string rowClassName =3D Convert.ToString(classRow[1]);
Modified: humano2/trunk/web/builder/site/combobox_type_entity.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/builder/site/combobox_type_entity.aspx.cs 2005-05-2=
7 15:50:51 UTC (rev 1164)
+++ humano2/trunk/web/builder/site/combobox_type_entity.aspx.cs 2005-05-2=
7 16:23:01 UTC (rev 1165)
@@ -31,9 +31,9 @@
=20
private void Page_Load(object sender, System.EventArgs e)
{
- string strAction =3D "";
+ //string strAction =3D "";
//string type_entity =3D "";
- string strfiltros =3D "";
+ //string strfiltros =3D "";
=20
adapte...
[truncated message content] |
|
From: <sv...@de...> - 2005-05-27 15:50:51
|
Author: pcamacho
Date: 2005-05-27 11:50:51 -0400 (Fri, 27 May 2005)
New Revision: 1164
Modified:
humano2/trunk/core/db/absComplex.cs
humano2/trunk/core/db/mssql/mssqlComplex.cs
humano2/trunk/core/db/pgsql/pgsqlComplex.cs
humano2/trunk/web/portal/site/leftbar.aspx.cs
Log:
FIX: the [1155] was not a good fix. Because doing an update of a folder w=
e could have a child before its father in=20
the folders' list used to build the tree. This new fix resolves the probl=
em by creating the list by level of the=20
trees, so a child can never be before its father.
Modified: humano2/trunk/core/db/absComplex.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/core/db/absComplex.cs 2005-05-27 15:35:32 UTC (rev 1163=
)
+++ humano2/trunk/core/db/absComplex.cs 2005-05-27 15:50:51 UTC (rev 1164=
)
@@ -388,6 +388,14 @@
///</summary>
abstract public string GetBasicAttributeSysName(int classId);
=20
+ =20
+ ///<summary>
+ ///Get the childs' id of a given folder
+ ///<param name=3D"folderId">id of folder</param>
+ ///<returns>the list of id of the childs</returns>
+ ///</summary>
+ abstract public int [] GetChildsOfFolder(int folderId);
+ =20
#endregion
=20
public object doScalar(string query)
Modified: humano2/trunk/core/db/mssql/mssqlComplex.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/core/db/mssql/mssqlComplex.cs 2005-05-27 15:35:32 UTC (=
rev 1163)
+++ humano2/trunk/core/db/mssql/mssqlComplex.cs 2005-05-27 15:50:51 UTC (=
rev 1164)
@@ -1224,5 +1224,19 @@
return sysName;
}
=20
+ public override int [] GetChildsOfFolder(int folderId)
+ {
+ string req =3D "select \"id_entity\" from folder where \"fol=
derParent\" =3D " + folderId;
+ DataTable dt =3D doSelect(req);
+ int dtSize =3D dt.Rows.Count;
+ int [] res =3D new int [dtSize];
+ for(int i=3D0; i< dtSize; i++)
+ {
+ res[i] =3D Convert.ToInt32(dt.Rows[i]["id_entity"]);
+ }
+ =20
+ return res;
+ }
+ =20
}
}
Modified: humano2/trunk/core/db/pgsql/pgsqlComplex.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/core/db/pgsql/pgsqlComplex.cs 2005-05-27 15:35:32 UTC (=
rev 1163)
+++ humano2/trunk/core/db/pgsql/pgsqlComplex.cs 2005-05-27 15:50:51 UTC (=
rev 1164)
@@ -1241,5 +1241,19 @@
return res; =09
=20
}
+ =20
+ public override int [] GetChildsOfFolder(int folderId)
+ {
+ string req =3D "select \"id_entity\" from folder where \"fol=
derParent\" =3D " + folderId;
+ DataTable dt =3D doSelect(req);
+ int dtSize =3D dt.Rows.Count;
+ int [] res =3D new int [dtSize];
+ for(int i=3D0; i< dtSize; i++)
+ {
+ res[i] =3D Convert.ToInt32(dt.Rows[i]["id_entity"]);
+ }
+ =20
+ return res;
+ }
}
}
Modified: humano2/trunk/web/portal/site/leftbar.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/leftbar.aspx.cs 2005-05-27 15:35:32 UTC=
(rev 1163)
+++ humano2/trunk/web/portal/site/leftbar.aspx.cs 2005-05-27 15:50:51 UTC=
(rev 1164)
@@ -23,6 +23,8 @@
using System.IO;
using System.Text.RegularExpressions;
=20
+using Humano2.Core;
+using Humano2.Core.Db;
using Humano2.Components.WebTools;
=20
namespace Portal.site
@@ -33,8 +35,12 @@
public class leftbar : basePage
{
private string Mode;
+ private int domainId;=20
=09
- private void Page_Load(object sender, System.EventArgs e) { }
+ private void Page_Load(object sender, System.EventArgs e)
+ {
+ domainId =3D userCred.DomainIds[userCred.CurrentDomainIndex]=
;
+ }
=20
/// <summary>
/// Creates an xml with all needed data.=20
@@ -104,10 +110,8 @@
{
string Forms=3D"";
string filtro =3D String.Format("34|0|'{0}'|0|0",userCred.DomainIds[=
userCred.CurrentDomainIndex]);
- string folderOrder =3D "1401|0"; //We must order the folders because=
parents must appear before children=20
- // when the webfxjstree i=
s built in the leftbar
- =20
- DataTable DTFolder =3D dbAdapter.GenerateViewTools(1400,"0,1401,1403=
,1402",filtro,"","",folderOrder,0);
+ =09
+ DataTable DTFolder =3D getFoldersInTreeOrder();
=20
DataTable DTView =3D dbAdapter.GenerateViewTools(1011,"0,1017,1018",=
filtro,"","","",0);
=20
@@ -128,10 +132,14 @@
if (Dr[3].ToString() !=3D "" && Dr[3].ToString() !=3D "0")
{
xmlString +=3D " <parent>" + Dr[3] + "</parent>";
- }else{
+ }
+ else
+ {
xmlString +=3D " <parent></parent>";
}
- }else{
+ }
+ else
+ {
xmlString +=3D " <parent></parent>";
}
Forms =3D Convert.ToString(Dr[2]);
@@ -182,7 +190,84 @@
=20
return xmlString;
}
-
+ =20
+ ///<summary>
+ ///Get a datatable with all the folders in tree order. That mean=
s that a child of whatever folder always=20
+ ///appears after this folder.
+ ///<summary>
+ private DataTable getFoldersInTreeOrder()
+ {
+ DataTable resDt =3D updateLevelFolders(0); //Start from the =
root
+ return resDt;
+ }
+ =20
+ private DataTable updateLevelFolders(int folderId)
+ {
+ adapter dbAdapter =3D userCred.CoreAdapter;
+ absCrud crud =3D Factory.Crud();
+ absComplex complex =3D crud.GetCore().Complex;
+ int [] listOfChilds =3D complex.GetChildsOfFolder(folderId);
+ int listOfChildsSize =3D listOfChilds.Length;
+ =20
+ DataTable newDt;
+ =20
+ if(listOfChildsSize =3D=3D 0) //No childs. We're done =20
+ {
+ newDt =3D null;
+ }
+ else //Follow recursivity
+ {
+ //Build the filter for query
+ string filter;=20
+ string listOfChildsForFilter =3D "[(";
+ for(int i=3D0;i<listOfChildsSize;i++)
+ {
+ listOfChildsForFilter +=3D "'" + Convert.ToString(li=
stOfChilds[i]) + "'" + ",";
+ }
+ listOfChildsForFilter =3D listOfChildsForFilter.Substrin=
g(0,listOfChildsForFilter.Length-1); //Remove last ","
+ listOfChildsForFilter +=3D ")]";
+ filter =3D String.Format("34|0|'{0}'|1|0",userCred.Domai=
nIds[userCred.CurrentDomainIndex]) + ";"; //For the domain =20
+ filter +=3D "0|8|" + listOfChildsForFilter + "|0|0"; //T=
o reduce the query to the list of childs =20
+ Logger.Log("leftbar.aspx.cs: filter =3D " + filter, Log=
Level.Trace);
+ //The datatable with values of current level filtered wi=
th childs
+ DataTable currentDt =3D dbAdapter.GenerateViewTools(1400=
,"0,1401,1403,1402",filter,"","","",0);
+ =20
+ //Build the concatenation of all DataTables
+ DataTable auxDt =3D null; //empty table to start
+ for(int i=3D0;i<listOfChildsSize;i++)
+ {
+ auxDt =3D concatDataTables(updateLevelFolders(listO=
fChilds[i]), auxDt);=20
+ } =20
+ //Add the current DataTable before the childs' DataTable=
s
+ newDt =3D concatDataTables(currentDt,auxDt);
+ }
+ return newDt;
+ }
+ =20
+ private DataTable concatDataTables(DataTable dt1, DataTable dt2)
+ {
+ DataSet ds =3D new DataSet();
+ =20
+ if(dt1 !=3D null)
+ {
+ ds.Merge(dt1);=20
+ }
+ =20
+ if(dt2 !=3D null)
+ {
+ ds.Merge(dt2);
+ }
+ =20
+ if(dt1 =3D=3D null && dt2 =3D=3D null)
+ {
+ return null; =20
+ }
+ else
+ {
+ return ds.Tables[0];
+ }
+ }
+ =20
private string genExploreList(adapter dbAdapter)
{
string xmlString;
|
|
From: <sv...@de...> - 2005-05-27 15:35:46
|
Author: svera
Date: 2005-05-27 11:35:32 -0400 (Fri, 27 May 2005)
New Revision: 1163
Modified:
humano2/trunk/web/builder/site/dataoperationbar.aspx
Log:
* With this modification the left bar is refreshed when you delete a cla=
ss
Modified: humano2/trunk/web/builder/site/dataoperationbar.aspx
=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/builder/site/dataoperationbar.aspx 2005-05-27 15:06=
:54 UTC (rev 1162)
+++ humano2/trunk/web/builder/site/dataoperationbar.aspx 2005-05-27 15:35=
:32 UTC (rev 1163)
@@ -12,6 +12,9 @@
var mainFrame =3D parent.frames["maindata"];
if(confirm("Are you sure you want to delete this class?")) {
mainFrame.window.location.href =3D "dataclassdelete.aspx?classId=3D=
" + GetClassId();
+ var leftFrame =3D parent.frames["leftdata"];
+ leftFrame.location.reload();
+ =09
}
}
=20
|
|
From: <sv...@de...> - 2005-05-27 15:06:56
|
Author: svera
Date: 2005-05-27 11:06:54 -0400 (Fri, 27 May 2005)
New Revision: 1162
Modified:
humano2/trunk/web/builder/site/dataclasscreate.aspx.cs
Log:
* Fix trouble with IE, when you press ENTER the class wasn?\194?\180t cr=
eated and in Firefox was created ok, now in both browsers the class is cr=
eated.
Modified: humano2/trunk/web/builder/site/dataclasscreate.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/builder/site/dataclasscreate.aspx.cs 2005-05-27 05:=
01:38 UTC (rev 1161)
+++ humano2/trunk/web/builder/site/dataclasscreate.aspx.cs 2005-05-27 15:=
06:54 UTC (rev 1162)
@@ -34,7 +34,9 @@
{
protected System.Web.UI.WebControls.TextBox className;
protected System.Web.UI.WebControls.Button btnCreateClass;
+ protected System.Web.UI.HtmlControls.HtmlForm Form1;
protected System.Web.UI.HtmlControls.HtmlInputHidden refresh;
+ private int flag =3D 0;
=20
override protected void OnInit(EventArgs e)
{
@@ -46,11 +48,16 @@
{
this.btnCreateClass.Click +=3D new System.EventHandler(this.btnCreate=
Class_Click);
this.Load +=3D new System.EventHandler(this.Page_Load);
+
}
=09
private void Page_Load(object sender, System.EventArgs e)
{
if(IsPostBack) {
+ if (className.Text !=3D "")
+ {
+ btnCreateClass_Click(sender,e);
+ }
refresh.Value =3D "yes";
}
}
@@ -58,6 +65,11 @@
=09
private void btnCreateClass_Click(object sender, System.EventArgs e)
{
+ if (this.flag !=3D 0)
+ {
+ return;
+ }
+
Logger.Log("btnCreateClass_Click called", LogLevel.Trace);
string clsName =3D className.Text;
Logger.Log("btnCreateClass_Click: Trying to create class"+ clsName, L=
ogLevel.Trace);
@@ -71,6 +83,7 @@
int newClassId =3D dbAdapter.CreateClass(clsName, userCred);
=20
Logger.Log("btnCreateClass_Click Done id:"+newClassId, LogLevel.Trace=
);
+ this.flag =3D 1;
}
}
}
|
Author: marijn
Date: 2005-05-27 01:01:38 -0400 (Fri, 27 May 2005)
New Revision: 1161
Modified:
humano2/branches/cleanup/components/formulas/ProcessFormulas.cs
humano2/branches/cleanup/components/import/Import.cs
humano2/branches/cleanup/components/rules/Rules.cs
humano2/branches/cleanup/components/viewTools/ViewTools.cs
humano2/branches/cleanup/components/webTools/Adapter.cs
humano2/branches/cleanup/components/webTools/session.cs
humano2/branches/cleanup/components/webTools/xmltools.cs
humano2/branches/cleanup/core/db/absComplex.cs
humano2/branches/cleanup/core/db/absCrud.cs
humano2/branches/cleanup/core/db/mssql/mssqlComplex.cs
humano2/branches/cleanup/core/db/mssql/mssqlConnection.cs
humano2/branches/cleanup/core/db/mssql/mssqlCrud.cs
humano2/branches/cleanup/core/db/pgsql/pgsqlComplex.cs
humano2/branches/cleanup/core/db/pgsql/pgsqlConnection.cs
humano2/branches/cleanup/core/db/pgsql/pgsqlCrud.cs
humano2/branches/cleanup/core/tests/mdPertinenceTests.cs
humano2/branches/cleanup/web/builder/site/buildattribute.aspx.cs
humano2/branches/cleanup/web/builder/site/combobox_type_entity.aspx.cs
humano2/branches/cleanup/web/builder/site/createInstanceRule.aspx.cs
humano2/branches/cleanup/web/builder/site/createreport.aspx.cs
humano2/branches/cleanup/web/builder/site/foldermanagement.aspx.cs
humano2/branches/cleanup/web/builder/site/formmanagement.aspx.cs
humano2/branches/cleanup/web/builder/site/formulamain.aspx.cs
humano2/branches/cleanup/web/builder/site/functionclasses.aspx.cs
humano2/branches/cleanup/web/builder/site/test.aspx.cs
humano2/branches/cleanup/web/builder/site/viewmain.aspx.cs
humano2/branches/cleanup/web/portal/site/report.aspx.cs
humano2/branches/cleanup/web/portal/site/search.aspx.cs
humano2/branches/cleanup/web/portal/site/showView.aspx.cs
humano2/branches/cleanup/web/portal/site/viewpertinencelist.aspx.cs
humano2/branches/cleanup/web/portal/site/viewrelations.aspx.cs
Log:
* Cleaning up the code, so that it produces no unneeded warning messages=
.
Modified: humano2/branches/cleanup/components/formulas/ProcessFormulas.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/branches/cleanup/components/formulas/ProcessFormulas.cs 2005-=
05-27 04:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/components/formulas/ProcessFormulas.cs 2005-=
05-27 05:01:38 UTC (rev 1161)
@@ -192,7 +192,7 @@
/// construye el resultado de la formula</sumary>
public DataTable GetDataTableResultFx(DataTable dtsql, DataTable dt2)
{
- string element,type,typeElement,typeFunction,fx;
+ string element,type,typeFunction,fx; //typeElement,
string expression=3D"";
int indice=3D1;
=20
@@ -209,7 +209,7 @@
{
element =3D dr["element"].ToString();
type =3D dr["type"].ToString();
- typeElement =3D dr["typeElement"].ToString();
+ //typeElement =3D dr["typeElement"].ToString();
if(type =3D=3D "elemento" || type =3D=3D "funcion")
{
expression =3D expression + dt2.Columns[indice].ColumnName;
@@ -238,7 +238,7 @@
{
element =3D dr["element"].ToString();
type =3D dr["type"].ToString();
- typeElement =3D dr["typeElement"].ToString();
+ //typeElement =3D dr["typeElement"].ToString();
typeFunction =3D dr["typeFunction"].ToString();
fx =3D dr["fx"].ToString();
if(type =3D=3D "elemento" || (type =3D=3D "funcion" && typeFunctio=
n =3D=3D "sql"))
@@ -598,7 +598,7 @@
string msj1,msj2;
DataSet ds1;
int idAtrib=3D0;
- int idPert=3D0;
+ //int idPert=3D0;
string typeElement;
int idTypeElement;
=09
@@ -644,7 +644,7 @@
theparams =3D this.TranslateField(element);
=09
idAtrib =3D theparams[0];
- idPert =3D theparams[1];
+ //idPert =3D theparams[1];
=09
drDats["theElement"] =3D element;
=09
@@ -714,7 +714,7 @@
public DataTable GetSqlElements(DataTable dt, int domainId, int column=
Id)
{
DataTable dtSql;
- string typeElement;
+ //string typeElement;
string fx, sqlView;
string typeFunction=3D"",theElement=3D"";
//int idAtrib, idRel;
@@ -728,7 +728,7 @@
drSql["type"] =3D dr["type"];
drSql["typeElement"] =3D dr["typeElement"];
drSql["idTypeElement"] =3D dr["idTypeElement"];
- typeElement =3D dr["typeElement"].ToString();
+ //typeElement =3D dr["typeElement"].ToString();
=09
if(dr["type"].ToString() =3D=3D "elemento")
{
@@ -781,7 +781,6 @@
=09
currentTableId =3D complex.TableId(columnId);
=20
- DataTable dtForm =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow dr =3D dtParam.NewRow();
=20
@@ -943,7 +942,7 @@
{
string tableTemp;
string strSQL;
- string element,type,typeElement,value,infoExtra;
+ string type,typeElement; // element,infoExtra,value
string nameColumn,typeDB;
int i;
=09
@@ -961,11 +960,11 @@
=09
foreach(DataRow draux in dt.Rows)
{
- element =3D draux["element"].ToString();
+ //element =3D draux["element"].ToString();
type =3D draux["type"].ToString();
typeElement =3D draux["typeElement"].ToString();
- value =3D draux["sqlView"].ToString();
- infoExtra =3D draux["infoExtraView"].ToString();
+ //value =3D draux["sqlView"].ToString();
+ //infoExtra =3D draux["infoExtraView"].ToString();
=09
if(type=3D=3D"elemento" || type=3D=3D"funcion")
{
@@ -988,9 +987,9 @@
{
string tableTemp;
string strSQL,strSQL2,strSQL3,sql1;
- string element,type,typeElement,value,infoExtra;
+ string element,type,value,infoExtra; // typeElement
string nameColumn;
- string theColumn,theTable;
+ string theTable; // theColumn,
int i;
=09
tableTemp =3D "tbltempfx"+columnId;
@@ -1001,7 +1000,7 @@
=09
=09
theTable =3D complex.TableName(columnId);
- theColumn =3D complex.ColumnName(columnId);
+ //theColumn =3D complex.ColumnName(columnId);
=20
//Primero se verificara que el datatable que viene, no trae Errores.
if(dt.Select("type like 'Error'").Length > 0)
@@ -1019,7 +1018,7 @@
{
element =3D draux["element"].ToString();
type =3D draux["type"].ToString();
- typeElement =3D draux["typeElement"].ToString();
+ //typeElement =3D draux["typeElement"].ToString();
value =3D draux["sqlView"].ToString();
infoExtra =3D draux["infoExtraView"].ToString();
=09
@@ -1082,7 +1081,7 @@
{
string tableTemp;
string strSQL,strSQL2,strSQL3,sql1,sql2;
- string element,type,typeElement,value,infoExtra;
+ string element,type; // ,infoExtra,value,typeElement
string nameColumn;
string theColumn,theTable;
int i;
@@ -1106,9 +1105,9 @@
{
element =3D draux["element"].ToString();
type =3D draux["type"].ToString();
- typeElement =3D draux["typeElement"].ToString();
- value =3D draux["sqlView"].ToString();
- infoExtra =3D draux["infoExtraView"].ToString();
+ //typeElement =3D draux["typeElement"].ToString();
+ //value =3D draux["sqlView"].ToString();
+ //infoExtra =3D draux["infoExtraView"].ToString();
=09
if(type=3D=3D"elemento" || type=3D=3D"funcion")
{
Modified: humano2/branches/cleanup/components/import/Import.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/branches/cleanup/components/import/Import.cs 2005-05-27 04:29=
:17 UTC (rev 1160)
+++ humano2/branches/cleanup/components/import/Import.cs 2005-05-27 05:01=
:38 UTC (rev 1161)
@@ -74,11 +74,11 @@
/// <param name=3D"attsArr">2 dimensional array wich contains Column =
name/Column definition.</param>
internal void createTables(string[,] attsArr)
{
- Hashtable classes =3D new Hashtable();
+ //Hashtable classes =3D new Hashtable();
=20
dsAtts=3D crud.ReadStructure(classId);
=20
- string xmlStr =3D dsAtts.GetXml();
+ //string xmlStr =3D dsAtts.GetXml();
=09
string[] cols =3D new string[1];
cols[0] =3D "classId";
@@ -239,14 +239,14 @@
=20
/// <summary>Reads the text file to be imported and is feed into a Da=
taTable, that DataTable is then passed to complex to fill the temporary i=
mport table</summary>
/// <param name=3D"srcFile">text file to be read</param>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
+ /// <param name=3D"attsArr">2-D which contains the file/db column mat=
ching information</param>
internal void LoadData(string srcFile, string[,] attsArr)
{
srcFile =3D srcFile.ToUpper().Replace("-TMP","-PROC");
using (StreamReader sr =3D new StreamReader(srcFile))
{
- string rawCols =3D sr.ReadLine();
- string[] rawColsArr =3D SplitDelimitedLine(rawCols,delimitator, qua=
lifier);
+ sr.ReadLine(); // string rawCols
+ //string[] rawColsArr =3D SplitDelimitedLine(rawCols,delimitator, q=
ualifier);
string line;
string[] lineArr;
// Read and display lines from the file until the end of
@@ -277,7 +277,6 @@
}
catch
{
- int n=3D0;
//FIXME: store line which containts invalid data in seperate file=
to make available in final report.
//The idea is that there is a class called Import Results.
//Each instance of that class has A) the original file uploaded, =
B) log file, C) file which contains the rows which had errors
@@ -290,7 +289,7 @@
=20
=20
/// <summary>Resolves the pertinence of the data being imported. </su=
mmary>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
+ /// <param name=3D"attsArr">2-D which contains the file/db column mat=
ching information</param>
internal void resolvePertinance(string[,] attsArr)
{
for (int i=3D0;i<attsArr.Length/3;i++)
@@ -328,7 +327,7 @@
/// <summary>
/// Call complex to generate the SQL statement to execute which will =
create the new instances and populate the class tables
/// </summary>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
+ /// <param name=3D"attsArr">2-D which contains the file/db column mat=
ching information</param>
internal void FinalImport(string[,] attsArr)
{
complex.finalImport(attsArr, dsAtts, tableName, domainId, classId);
@@ -344,7 +343,6 @@
/// arr[0] =3D Hello; There
/// arr[1] =3D world
/// </summary>
- /// <param name=3D"srcFile">2-D which contains the file/db column mat=
ching information</param>
public string[] SplitDelimitedLine(string CurrentLine, char Delimite=
r, char Qualifier)
{
int i;
@@ -442,7 +440,7 @@
classId =3D Convert.ToInt32(objXMLDOM.DocumentElement.SelectSingleNo=
de("/config/classId").InnerText);
delimitator =3D Convert.ToChar(objXMLDOM.DocumentElement.SelectSingl=
eNode("/config/delimitator").InnerText);
qualifierStr =3D objXMLDOM.DocumentElement.SelectSingleNode("/config=
/qualifier").InnerText;
- string updateAtts =3D objXMLDOM.DocumentElement.SelectSingleNode("/c=
onfig/updateAtts").InnerText;
+ //string updateAtts =3D objXMLDOM.DocumentElement.SelectSingleNode("=
/config/updateAtts").InnerText;
dbAttsStr =3D objXMLDOM.DocumentElement.SelectSingleNode("/config/db=
Atts").InnerText.Split(',');
fileAttsStr =3D objXMLDOM.DocumentElement.SelectSingleNode("/config/=
fileAtts").InnerText.Split(',');
rawFileFields =3D objXMLDOM.DocumentElement.SelectSingleNode("/confi=
g/rawFileFields").InnerText;
@@ -461,8 +459,8 @@
fileCols =3D io.SplitDelimitedLine(rawFileFields, delimitator,qualifi=
er);
=20
string[,] attsArr =3D new string[fileAttsStr.Length,3];
- ///attsArr gets returned and used everywhere in the import process. I=
t contains the
- ///column matching between the file being uploaded and the files in t=
he databse.
+ //attsArr gets returned and used everywhere in the import process. It=
contains the
+ //column matching between the file being uploaded and the files in th=
e databse.
for (int i =3D 0; i < fileAttsStr.Length; i++)
{
attsArr[i,0] =3D fileAttsStr[i]; //contains the ID of the column in =
the file
Modified: humano2/branches/cleanup/components/rules/Rules.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/branches/cleanup/components/rules/Rules.cs 2005-05-27 04:29:1=
7 UTC (rev 1160)
+++ humano2/branches/cleanup/components/rules/Rules.cs 2005-05-27 05:01:3=
8 UTC (rev 1161)
@@ -34,7 +34,6 @@
/// <returns></returns>
public object Test()
{
- DataTable dt =3D new DataTable();
return "Hola";
}
#endregion
@@ -120,7 +119,6 @@
{
int classId=3D1100;
string strfiltros =3D "";
- DataTable dtRules =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow dr =3D dtParam.NewRow();
int attributeId=3D0;
@@ -238,12 +236,12 @@
string attributes,operators,elements;
string[] arrAttributes,arrOperators,arrElements;
int attrib;
- int operatorId,setToId,idRel;
+ int operatorId; //,setToId,idRel;
string elementRule,setTo;
string valueRule=3D"";
string filtro=3D"";
int tableId=3D0;
- int[] theparams;
+ //int[] theparams;
DataTable dtEntitys =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow drParam =3D dtParam.NewRow();
@@ -279,10 +277,10 @@
else
finfiltro =3D "|0|0";
=20
- theparams =3D this.TranslateField(setTo);
+ //theparams =3D this.TranslateField(setTo);
=09
- setToId =3D theparams[0];
- idRel =3D theparams[1];
+ //setToId =3D theparams[0];
+ //idRel =3D theparams[1];
=20
tableId =3D complex.TableId(attrib);
=20
@@ -342,13 +340,13 @@
string attributes,operators,elements;
string[] arrAttributes,arrOperators,arrElements;
int attrib;
- int operatorId,setToId,idRel;
+ int operatorId; //,setToId,idRel;
string elementRule,setTo;
string valueRule=3D"";
string filtro=3D"";
int tableId=3D0;
- int[] theparams;
- DataTable dtEntitys =3D new DataTable();
+ //int[] theparams;
+ //DataTable dtEntitys =3D new DataTable();
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow drParam =3D dtParam.NewRow();
=20
@@ -383,10 +381,10 @@
else
finfiltro =3D "|0|0";
=20
- theparams =3D this.TranslateField(setTo);
+ //theparams =3D this.TranslateField(setTo);
=09
- setToId =3D theparams[0];
- idRel =3D theparams[1];
+ //setToId =3D theparams[0];
+ //idRel =3D theparams[1];
=20
tableId =3D complex.TableId(attrib);
=20
@@ -466,16 +464,16 @@
public DataTable CreateDtToUpdate(int domainId, DataRow dr, DataTable =
dtEntity)
{
//int attrib=3D0;
- int setToId,idRel;
- string operatorRule,elementRule,setTo;
+ int setToId; //,idRel;
+ string setTo; // ,operatorRule,elementRule=20
string columnNameElement;
string tableName;
string valueRule;
- int tableId=3D0;
+ //int tableId=3D0;
int[] theparams;
- DataTable dtEntitys =3D new DataTable();
- DataTable dtParam =3D this.makeDataTableInViewTools();
- DataRow drParam =3D dtParam.NewRow();
+ //DataTable dtEntitys =3D new DataTable();
+ //DataTable dtParam =3D this.makeDataTableInViewTools();
+ //DataRow drParam =3D dtParam.NewRow();
=20
//Seccion del crud y el complex
crud.Domain =3D domainId;
@@ -485,17 +483,17 @@
vt.Complex =3D complex;
=20
//attrib =3D Convert.ToInt32(dr["attributeIdRule"].ToString());
- operatorRule =3D dr["operatorRule"].ToString();
- elementRule =3D dr["elementRule"].ToString();
+ //operatorRule =3D dr["operatorRule"].ToString();
+ //elementRule =3D dr["elementRule"].ToString();
setTo =3D dr["setTo"].ToString();
valueRule =3D dr["valueRule"].ToString();
=20
theparams =3D this.TranslateField(setTo);
=09
setToId =3D theparams[0];
- idRel =3D theparams[1];
+ //idRel =3D theparams[1];
=20
- tableId =3D complex.TableId(setToId);
+ //tableId =3D complex.TableId(setToId);
tableName =3D complex.TableName(setToId);
columnNameElement =3D complex.ColumnName(setToId);
=20
@@ -557,8 +555,9 @@
public string GetColumnsRules(int classId)
{
string str=3D"";
- DataTable dt1 =3D new DataTable();
- DataTable dtParam =3D this.makeDataTableInViewTools();
+ return str;
+ //DataTable dt1 =3D new DataTable();
+ /* DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow dr =3D dtParam.NewRow();
=20
dr["columna"] =3D "0";
@@ -569,11 +568,11 @@
ViewTools.ViewTools vt =3D new ViewTools.ViewTools(5);
//absCrud crud =3D Factory.Crud();
//absComplex complex =3D Factory.Complex(crud);
- vt.Complex =3D complex;
+ vt.Complex =3D complex; */
=20
- dt1 =3D vt.GetSQLDataTable(dtParam);
+ //dt1 =3D vt.GetSQLDataTable(dtParam);
=20
- return str;
+
}
=20
///<sumary>funcion que recorre el DT y actualiza la columna en la DB</=
sumary>
Modified: humano2/branches/cleanup/components/viewTools/ViewTools.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/branches/cleanup/components/viewTools/ViewTools.cs 2005-05-27=
04:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/components/viewTools/ViewTools.cs 2005-05-27=
05:01:38 UTC (rev 1161)
@@ -337,14 +337,14 @@
//{
=20
int pos =3D var.IndexOf(";");
- string a =3D var.Substring(pos + 1,7);
+ //string a =3D var.Substring(pos + 1,7);
if(var.Substring(pos + 1,7).ToLower() =3D=3D "\ninsert")
{
=20
createTable =3D var.Substring(0,pos);
var =3D var.Substring(var.IndexOf(";") + 2,var.Length - var.IndexO=
f(";") - 2);
pos =3D var.IndexOf(";");
- a =3D var.Substring(pos + 1,7);
+ //a =3D var.Substring(pos + 1,7);
=20
if(var.Substring(pos + 1,7).ToLower() =3D=3D "\nselect")
{
@@ -495,7 +495,7 @@
relations =3D GetRelatedTableList((string[])cols.ToArray(typeof(strin=
g)));
if(relations.Length > 0)
{
- ViewRelation previousRelation =3D null;=09
+ //ViewRelation previousRelation =3D null;=09
string relationType =3D "";
ArrayList tableDictionary =3D new ArrayList();
int counter =3D 1;
@@ -519,7 +519,7 @@
Query.Append(" =3D " + relation.EndTableName + "." + relation.Forei=
gnKeyName);
// Query.Append(" relTbl"+counter+" ON tblA." + relation.PrimaryKeyN=
ame);
// Query.Append(" =3D relTbl"+counter+"." + relation.ForeignKeyName)=
;
- previousRelation =3D relation;
+ //previousRelation =3D relation;
=20
if(tableDictionary.IndexOf(relation.EndTableName) =3D=3D -1)
{
@@ -711,10 +711,10 @@
{
StringBuilder strFilters =3D new StringBuilder();
string[] parameters;
- string iniFunction, endFunction;
+ string iniFunction; //endFunction;
string iniArgument, endArgument, operation;
string[] aux;
- int colIndex, intFilter, intIniFunc, intEndFunc;
+ int colIndex, intFilter, intIniFunc; //intEndFunc;
string tableName, columnName, tableName2, columnName2;
=09
foreach(string filter in strParams)
@@ -723,7 +723,7 @@
iniFunction =3D parameters[0].ToString();
iniArgument =3D parameters[1].ToString();
operation =3D parameters[2].ToString();
- endFunction =3D parameters[3].ToString();
+ //endFunction =3D parameters[3].ToString();
endArgument =3D parameters[4].ToString();
=20
intIniFunc =3D Convert.ToInt32(iniFunction);
@@ -759,7 +759,7 @@
=20
intFilter =3D Convert.ToInt32(operation);
=20
- intEndFunc =3D Convert.ToInt32(endFunction);
+ //intEndFunc =3D Convert.ToInt32(endFunction);
aux =3D endArgument.Split("^".ToCharArray());
if(aux[0].IndexOf("'") =3D=3D -1)
{
@@ -1299,10 +1299,10 @@
int[] parentIndexes;
int previousRelation =3D 0;
StringBuilder Query =3D new StringBuilder();
- string iniTable, endTable, entTable =3D "";
+ string iniTable, endTable;
+=09
+ parentIndexes =3D GetParentIndexes(intIdClass);
=20
- parentIndexes =3D GetParentIndexes(intIdClass);
-
for(int i =3D 0; i<=3D parentIndexes.Length - 2;i++)
{
iniTable =3D Complex.TableName(parentIndexes[i]);
@@ -1310,12 +1310,8 @@
if(previousRelation =3D=3D 0)
{
Query.Append(iniTable + " inner join " + endTable);
-// Query.Append(iniTable + " tblA inner join " + endTable + " tbl"+i=
);
Query.Append(" on " + iniTable + ".id_entity");
Query.Append(" =3D " + endTable + ".id_entity ");
-// Query.Append(" on tblA.id_entity");
-// Query.Append(" =3D tbl"+i+".id_entity ");
-// if (endTable =3D=3D "\"entity\"") entTable =3D "tbl"+i;
previousRelation =3D 1;
}
else
@@ -1327,7 +1323,6 @@
}
}
Query.Append("and entity.\"delDate\" is null ");
-// Query.Append("and "+entTable+".\"delDate\" is null ");
return Query.ToString();
}
=20
@@ -1429,8 +1424,8 @@
=20
int regIndex =3D Convert.ToInt32(dr[0].ItemArray[0]);
string owner =3D dr[0].ItemArray[1].ToString();
- string to =3D dr[0].ItemArray[2].ToString();
- string ratio =3D dr[0].ItemArray[3].ToString();
+ //string to =3D dr[0].ItemArray[2].ToString();
+ //string ratio =3D dr[0].ItemArray[3].ToString();
=20
toColumnIndex =3D Convert.ToInt32(owner);
columnNameTo =3D Complex.ColumnName(toColumnIndex);
@@ -1453,8 +1448,8 @@
}
=20
owner =3D dr[0].ItemArray[1].ToString();
- to =3D dr[0].ItemArray[2].ToString();
- ratio =3D dr[0].ItemArray[3].ToString();
+ //to =3D dr[0].ItemArray[2].ToString();
+ //ratio =3D dr[0].ItemArray[3].ToString();
=20
fromColumnIndex =3D Convert.ToInt32(owner);
tableNameFrom =3D Complex.TableName(fromColumnIndex);
@@ -1468,9 +1463,9 @@
=20
rel =3D Enums.RelationType.ManyToOne;
=20
- // NewRelationInstance(tableNameFrom, columnNameFrom, ta=
bleNameTo, columnNameTo,
- // fromTableIndex, toTableIndex, fromColumnIndex, toCol=
umnIndex,
- // rel, ref Relations);=09
+ //NewRelationInstance(tableNameFrom, columnNameFrom, tableNameT=
o, columnNameTo,
+ //fromTableIndex, toTableIndex, fromColumnIndex, toColumnIndex,
+ //rl, ref Relations);=09
}
else
{
Modified: humano2/branches/cleanup/components/webTools/Adapter.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/branches/cleanup/components/webTools/Adapter.cs 2005-05-27 04=
:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/components/webTools/Adapter.cs 2005-05-27 05=
:01:38 UTC (rev 1161)
@@ -90,12 +90,11 @@
/// <summary>
/// Entrega un DataTable con las clases existentes de acuerdo al tipo
/// </summary>
- /// <param name=3D"type">tipo de la clase</param>
/// <returns>DataTable</returns>
- public DataTable GetClassesFromTypePertinence(int id_entity, int domai=
n)
+ public DataTable GetClassesFromTypePertinence(int idEntity, int domain=
Id)
{
DataTable res;
- res =3D complex.GetClassesFromTypePertinence(id_entity, domain);
+ res =3D complex.GetClassesFromTypePertinence(idEntity, domainId);
return res;
}
=20
@@ -149,13 +148,13 @@
///<summary>Get values from a view for pertinence filtering view.</sum=
mary>
///<param name=3D"viewId">The Id of the view that is doing the filteri=
ng</param>
///<param name=3D"idClassView">The class that the view is asociated wi=
th.</param>
- ///<param name=3D"viewColumn">The column of the filter value.</param>
- ///<param name=3D"viewWhere">The conditions under which the filter wor=
ks.</param>
+ ///<param name=3D"filterValue">The column of the filter value.</param>
+ ///<param name=3D"displayColumn">The conditions under which the filter=
works.</param>
///<returns>The filtering value to be replaced</returns>
public string GetPertinenceFilterValues(int viewId, out int idClassVie=
w, out string filterValue, out string displayColumn)
{
string viewValue;
- int viewColumn;
+ //int viewColumn;
=20
int iniClass =3D (int) ViewConsts.ViewClass;
=09
@@ -218,7 +217,7 @@
/// <summary>
/// Entrega un DataTable con los atributos de un atributo
/// </summary>
- /// <param name=3D"classId">id del atributo</param>
+ /// <param name=3D"attId">id del atributo</param>
/// <returns>DataTable</returns>
public DataTable GetAttributesFromAttribute(int attId)
{
@@ -280,7 +279,7 @@
Humano2.Components.ViewTools.ViewTools vt =3D new ViewTools.ViewTo=
ols();
vt.Complex =3D complex;
=09
- DataTable table =3D getViewToolsTable();
+ //DataTable table =3D getViewToolsTable();
=20
// Get the id_entity and the domainName of all the domains in the sys=
tem.
string columns =3D "1012,1013,1014,1015,1016,1017,1018";
@@ -319,11 +318,11 @@
///<param name=3D"iniClass">The class that the DataTable's View sho=
uld act on.</param>
///<param name=3D"order">The ViewTools formated string with the ord=
er.</param>
///<param name=3D"page">The page that should be shown.</param>
- ///<param name=3D"keyFlag">The key Flag to use (0: for group by,=
1: without group)</param>
- ///<param name=3D"pageCount">The Number of pages of this view.</par=
am>
+ ///<param name=3D"keyFlag">The key Flag to use (0: for group=
by,1: without group)</param>
+
///<returns>The datatable that is the result of executing the view.=
</returns>
public DataTable ExecViewFromDataTable(int iniClass, DataTable vtTa=
ble, int idEntity, string order,=20
- int page, int keyFlag)
+ int page, int keyFlag)
{
// We got the data.. Do the viewTools invocation with the data.
Humano2.Components.ViewTools.ViewTools vt =3D new Humano2.Components.=
ViewTools.ViewTools(iniClass);
@@ -659,7 +658,7 @@
{
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -705,7 +704,7 @@
{
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -848,7 +847,7 @@
///<param name=3D"userId">The Id of the user.</param>
///<param name=3D"email">The email of the user name. In Humano2 the em=
ail is the login name</param>
///<param name=3D"pass">The password of the user</param>
- ///<param name=3D"domains">List of Ids that the user is subscribed to<=
/param>
+ ///<param name=3D"domainIds">List of Ids that the user is subscribed t=
o</param>
public void UpdateUser(int userId, string email, string pass, ArrayLis=
t domainIds)=20
{
DataSet ds =3D prepareUserData(userId, email, pass, domainIds);
@@ -934,7 +933,7 @@
return ds; =09
}
=09
- #region Read's Structural and Data
+ #region Reads Structural and Data
=20
/// <summary>
/// Lee la estructura de una entity (Instancia)
@@ -1035,9 +1034,9 @@
=20
/// <summary>
/// To get the class name by its id
- /// <param name=3D"classId">The id of the class</name>
- /// <returns>The name of class</returns>
/// </summary>
+ /// <param name=3D"classId">The id of the class</param>
+ /// <returns>The name of class</returns>
public string GetClassNameById(int classId)
{
=20
@@ -1113,7 +1112,7 @@
=20
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D this.getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -1165,7 +1164,7 @@
{
//Creo las estructuras para poder llamar a viewTools
DataTable table =3D this.getViewToolsTable();
- ArrayList row =3D new ArrayList();
+ //ArrayList row =3D new ArrayList();
=20
ViewTools.ViewTools vt =3D new ViewTools.ViewTools();
=20
@@ -1275,13 +1274,14 @@
///<remarks>better to do this seperately so we can better control what=
get's changed.</remarks>
///<param name=3D"classId">The id of the class to update</param>
///<param name=3D"domainId">The domain of the user</param>
- ///<param name=3D"domainId">the data for the update</param>
+ ///<param name=3D"className">the data for the update</param>
public void UpdateClass(int classId, int domainId, string className)
{ =09
Logger.Log("UpdateClass: changing classId " + classId + " name is now=
: " + className, LogLevel.Trace);
complex.UpdateClass(classId, domainId, className);
}
=09
+ /// <summary>
/// Method create
/// </summary>
/// <param name=3D"id_entity">An int</param>
@@ -1397,9 +1397,9 @@
}
=20
/// <summary>Marks one attribute of a class as obligatory.</summary=
>
- /// <param name=3D"primaryId">The id of the attribute that is to be=
primary.</summary>
- /// <param name=3D"classId">The class of the attribute</summary>
- /// <param name=3D"domainId">The domain Id of the class.</summary>
+ /// <param name=3D"primaryId">The id of the attribute that is to be=
primary.</param>
+ /// <param name=3D"classId">The class of the attribute</param>
+ /// <param name=3D"domainId">The domain Id of the class.</param>
public void SetAttributeAsPrimary(int primaryId, int classId, int d=
omainId)
{
// Remove the isPrimary label from all attributes. =20
@@ -1495,8 +1495,7 @@
/// Cambia los attributos de un view.
/// </summary>
/// <param name=3D"idEntity">An int</param>
- /// <param name=3D"idClass">An int</param>
- /// <param name=3D"viewName">A string</param>
+ /// <param name=3D"classId">An int</param>
/// <param name=3D"idDomain">An int</param>
/// <param name=3D"mode">An int</param>
public void ChangeAttributesOfView(int idEntity, int classId, int idDo=
main, int mode)
@@ -1817,7 +1816,6 @@
=20
DataTable res =3D GetAttributesFromClass(classId);
int idAtt =3D 0;
- int i=3D0;
foreach(DataRow row in res.Rows)
{
if(complex.IsPrimary(Convert.ToInt32(row["id_entity"])))
Modified: humano2/branches/cleanup/components/webTools/session.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/branches/cleanup/components/webTools/session.cs 2005-05-27 04=
:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/components/webTools/session.cs 2005-05-27 05=
:01:38 UTC (rev 1161)
@@ -128,7 +128,6 @@
{
value.lastAccess =3D DateTime.Now;
string key;
- int i =3D 1;
=20
//Tomo el mutex para no repetir key's
mutexKey.WaitOne();
Modified: humano2/branches/cleanup/components/webTools/xmltools.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/branches/cleanup/components/webTools/xmltools.cs 2005-05-27 0=
4:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/components/webTools/xmltools.cs 2005-05-27 0=
5:01:38 UTC (rev 1161)
@@ -60,10 +60,10 @@
///Do an XSLT transform with an xml string and an System=
.Xml.Xsl.XslTransform object
///</summary>
///<param name=3D'strXML'>The string of the xml document=
</param>
- ///<param name=3D'strXSLURL'>The url of the xsl</param>
+ ///<param name=3D'xsl'>The url of the xsl</param>
///<param name=3D'Response'>The html response object to =
send exception if needed</param>
///<returns>The result of transformation</returns>
- private static string TransformXML(string strXML, System=
.Xml.Xsl.XslTransform xsl,System.Web.HttpResponse Response)
+ private static string TransformXML(string strXML, System=
.Xml.Xsl.XslTransform xsl, System.Web.HttpResponse Response)
{
=20
//Logger.Log("Result of transformation: " + strX=
ML, LogLevel.Trace);
@@ -77,7 +77,7 @@
catch (System.Exception e)
{
//Put in custom error handler here...
- string x =3D e.ToString();
+ //string x =3D e.ToString();
//Response.Write(x);
}
=20
Modified: humano2/branches/cleanup/core/db/absComplex.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/branches/cleanup/core/db/absComplex.cs 2005-05-27 04:29:17 UT=
C (rev 1160)
+++ humano2/branches/cleanup/core/db/absComplex.cs 2005-05-27 05:01:38 UT=
C (rev 1161)
@@ -194,10 +194,9 @@
abstract public DataTable GetViewData(int viewId);
=20
///<summary>Get the structure of a report.</summary>
- ///<param name=3D"viewId">The id of the report.</param>
+ ///<param name=3D"reportId">The id of the report.</param>
///<returns>a datatable with the information about the report.</return=
s>
abstract public DataTable GetReportData(int reportId);
- =09
=20
///<summary>gets all the formulas that are related to attribtes of =
a class</summary>
///<param name=3D"classId">The Id of fthe class</param>
@@ -330,38 +329,38 @@
abstract public void finalImport(string [,] attsArr, DataSet dsAtts, s=
tring tableName, int domainId, int classId);
=20
/// <summary>
- /// Get the string id of the pertinence attribute an attribute is rela=
ted to
- /// <param name=3D"attribute">The attribute for which we want th=
e pertinence attribute related to
+ /// Get the string id of the pertinence attribute an attribute is relat=
ed to
/// </summary>
- /// <return>The attribute of the pertinence attribute or "" if a=
ttributeId is not a pertinence attribute</returns>
+ /// <param name=3D"attributeId">The attribute for which we want =
the pertinence attribute related to</param>
+ /// <returns>The attribute of the pertinence attribute or "" if =
attributeId is not a pertinence attribute</returns>
abstract public string GetPertinenceForAttribute(string attribut=
eId);
=20
/// <summary>
- /// Converts a system attribute name into a user attribute name
+ /// Converts a system attribute name into a user attribute name
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>user attribute name</returns>
+ /// <returns>user attribute name</returns>
abstract public string ConvertSysAttNameToUserAttName(string sys=
AttName);
=20
/// <summary>
/// Converts a system attribute name into its id
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param>
- /// <return>id of attribute</returns>
+ /// <returns>id of attribute</returns>
abstract public int ConvertSysAttNameToIdAttName(string sysAttName);
=20
/// <summary>
/// Tells if an attribute is primary=20
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
abstract public bool IsPrimary(string sysAttName);
=20
/// <summary>
- /// Tells if an attribute is primary=20
+ /// Tells if an attribute is primary=20
/// </summary>
- /// <param name=3D"sysAttName">id of attribute </param>
- /// <return>true if attribute is primary</returns>
+ /// <param name=3D"attId">id of attribute </param>
+ /// <returns>true if attribute is primary</returns>
abstract public bool IsPrimary(int attId);
=20
abstract public bool IsSelfLookUp(string sysAttName);
@@ -370,22 +369,23 @@
/// Get the params (where, orderby etc...) of a view
/// </summary>
/// <param name=3D"id">id of view</param>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
abstract public string [] GetParamsView(int id);
=20
/// <summary>
- /// Get the params (where, orderby etc...) of a report
+ /// Get the params (where, orderby etc...) of a report
/// </summary>
/// <param name=3D"id">id of report</param>
- /// <return>params of the report</returns>
+ /// <returns>params of the report</returns>
abstract public string [] GetParamsReport(int id);
=20
=20
///<summary>
- /// Returns the name of the basic attribute (numeric, textline..=
.) father of an attribute passed in param
+ /// Returns the name of the basic attribute (numeric, textline..=
.) father of an attribute passed in param =20
+ ///</summary>
/// <param name=3D"classId">The classId of an attribute</param>
/// <returns>the sys name of basic attribute</returns>
- ///</summary>
+
abstract public string GetBasicAttributeSysName(int classId);
=20
#endregion
Modified: humano2/branches/cleanup/core/db/absCrud.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/branches/cleanup/core/db/absCrud.cs 2005-05-27 04:29:17 UTC (=
rev 1160)
+++ humano2/branches/cleanup/core/db/absCrud.cs 2005-05-27 05:01:38 UTC (=
rev 1161)
@@ -461,8 +461,9 @@
dr["parentId"]=3D navTableId;
dr["parentPertinence"]=3D pertAttId;
dt.Rows.Add(dr);
- int toColumn =3D Create((int) MetaModelConsts.EntitiesPertinence, dt)=
;
=20
+ Create((int) MetaModelConsts.EntitiesPertinence, dt);
+
// Update the pertinence, pointing the owner to the navTable.
updatePertinenceNM(pertAttId, navTableId, fromColumn);
}
Modified: humano2/branches/cleanup/core/db/mssql/mssqlComplex.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/branches/cleanup/core/db/mssql/mssqlComplex.cs 2005-05-27 04:=
29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/core/db/mssql/mssqlComplex.cs 2005-05-27 05:=
01:38 UTC (rev 1161)
@@ -88,7 +88,7 @@
}
=20
///<summary>Get the structure of a report.</summary>
- ///<param name=3D"viewId">The id of the report.</param>
+ ///<param name=3D"reportId">The id of the report.</param>
///<returns>a datatable with the information about the report.</return=
s>
public override DataTable GetReportData(int reportId)=20
{
@@ -159,9 +159,10 @@
/// <summary>
/// Entrega un DataTable con las clases existentes de acuerdo al tipo
/// </summary>
- /// <param name=3D"type">tipo de la clase</param>
+ /// <param name=3D"idEntity">Id del pertience cual estamos buscando re=
laciones.</param>
+ /// <param name=3D"domainId">Id del dominio de los elementos</param>
/// <returns>DataTable</returns>
- public override DataTable GetClassesFromTypePertinence(int id_entity, =
int domain)
+ public override DataTable GetClassesFromTypePertinence(int idEntity, i=
nt domainId)
{
string query;
DataTable res;
@@ -170,14 +171,14 @@
c.id_entity,
c.name,
(select ""ratio"" from pertinence p, entity en
- where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + id_entity.ToString() + @" and
+ where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + idEntity + @" and
en.id_entity =3D p.id_entity and en.""delDate"" is null) as r=
atio
from class c, entity e
where
c.id_entity =3D e.id_entity and
c.""isHidden"" =3D '0' and
e.""delDate"" is null and
- e.""domainId"" in (" + domain.ToString() + @", 10) order by c.""c=
lassType"" DESC, c.name";
+ e.""domainId"" in (" + domainId + @", 10) order by c.""classType"=
" DESC, c.name";
=09
res =3D this.doSelect(query);
return res;
@@ -900,10 +901,10 @@
}
=20
/// <summary>
- /// Get the string id of the pertinence attribute an attribute is rela=
ted to
+ /// Get the string id of the pertinence attribute an attribute is relat=
ed to
/// </summary>
- /// <param name=3D"attribute">The attribute for which we want th=
e pertinence attribute related to</param>
- /// <return>The attribute of the pertinence attribute or "" if a=
ttributeId is not a pertinence attribute</returns>
+ /// <param name=3D"attributeId">The attribute for which we want =
the pertinence attribute related to</param>
+ /// <returns>The attribute of the pertinence attribute or "" if =
attributeId is not a pertinence attribute</returns>
override public string GetPertinenceForAttribute(string attribut=
eId)
{
string req =3D "select \"id_entity\" from attribute where \"=
classId\" in (select \"to\" from pertinence where id_entity =3D " + Conve=
rt.ToInt32(attributeId) + ")";
@@ -920,10 +921,10 @@
}
=20
/// <summary>
- /// Converts a system attribute name into a user attribute name
+ /// Converts a system attribute name into a user attribute name
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>user attribute name</returns>
+ /// <returns>user attribute name</returns>
override public string ConvertSysAttNameToUserAttName(string sys=
AttName)
{
string req =3D "select \"attName\" from attribute where \"sy=
sAttName\" =3D '" + sysAttName +"'";
@@ -944,7 +945,7 @@
/// Tells if an attribute is primary=20
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(string sysAttName)
{
string req =3D "select \"isPrimary\" from attribute where \"=
sysAttName\" =3D '" + sysAttName + "'";
@@ -968,8 +969,8 @@
/// <summary>
/// Tells if an attribute is primary=20
/// </summary>
- /// <param name=3D"sysAttName">id of attribute </param>
- /// <return>true if attribute is primary</returns>
+ /// <param name=3D"attId">id of attribute </param>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(int attId)
{
string req =3D "select \"isPrimary\" from attribute where \"=
id_entity\" =3D '" + attId + "'";
@@ -1016,7 +1017,7 @@
/// Get the params (where, orderby etc...) of a view
/// </summary>
/// <param name=3D"id">id of view</param>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
override public string [] GetParamsView(int id)
{
string idStr =3D Convert.ToString(id);
@@ -1043,7 +1044,7 @@
/// Get the params (where, orderby etc...) of a report
/// </summary>
/// <param name=3D"id">id of report</param>
- /// <return>params of the report</returns>
+ /// <returns>params of the report</returns>
override public string [] GetParamsReport(int id)
{
string idStr =3D Convert.ToString(id);
@@ -1087,7 +1088,7 @@
foreach(DataRow dRow in tmpTable.Rows)
{
int attribClass =3D Convert.ToInt32(dRow[classIdCol[0]]);
- string colname =3D dRow[classIdCol[0]].ToString();
+ //string colname =3D dRow[classIdCol[0]].ToString();
string classTable =3D getTableName(attribClass);
switch (classId)
{
Modified: humano2/branches/cleanup/core/db/mssql/mssqlConnection.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/branches/cleanup/core/db/mssql/mssqlConnection.cs 2005-05-27 =
04:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/core/db/mssql/mssqlConnection.cs 2005-05-27 =
05:01:38 UTC (rev 1161)
@@ -255,11 +255,11 @@
=09
tgtTable.TableName =3D fillTable;
tgtTable =3D srcTable.Copy( );
- SqlCommandBuilder SqlCB =3D new SqlCommandBuilder( da );
+ //SqlCommandBuilder SqlCB =3D new SqlCommandBuilder( da );
da.Fill( tgtTable );
tgtTable =3D srcTable.Copy( );
ds.Tables.Add( tgtTable );
- string strXml =3D ds.GetXml( );
+ //string strXml =3D ds.GetXml( );
da.Update( tgtTable );
Close();
}
Modified: humano2/branches/cleanup/core/db/mssql/mssqlCrud.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/branches/cleanup/core/db/mssql/mssqlCrud.cs 2005-05-27 04:29:=
17 UTC (rev 1160)
+++ humano2/branches/cleanup/core/db/mssql/mssqlCrud.cs 2005-05-27 05:01:=
38 UTC (rev 1161)
@@ -94,15 +94,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
@@ -344,15 +344,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
Modified: humano2/branches/cleanup/core/db/pgsql/pgsqlComplex.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/branches/cleanup/core/db/pgsql/pgsqlComplex.cs 2005-05-27 04:=
29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/core/db/pgsql/pgsqlComplex.cs 2005-05-27 05:=
01:38 UTC (rev 1161)
@@ -88,8 +88,8 @@
return res; =09
}
=09
- ///<summary>Get the structure of a report.</summary>
- ///<param name=3D"viewId">The id of the report.</param>
+ ///<summary>Get the structure of a report.</summary>
+ ///<param name=3D"reportId">The id of the report.</param>
///<returns>a datatable with the information about the report.</return=
s>
public override DataTable GetReportData(int reportId)=20
{
@@ -164,9 +164,10 @@
/// <summary>
/// Entrega un DataTable con las clases existentes de acuerdo al tipo
/// </summary>
- /// <param name=3D"type">tipo de la clase</param>
+ /// <param name=3D"idEntity">Id del pertience cual estamos buscando re=
laciones.</param>
+ /// <param name=3D"domainId">Id del dominio de los elementos</param>
/// <returns>DataTable</returns>
- public override DataTable GetClassesFromTypePertinence(int id_entity, =
int domain)
+ public override DataTable GetClassesFromTypePertinence(int idEntity, i=
nt domainId)
{
string query;
DataTable res;
@@ -175,14 +176,14 @@
c.id_entity,
c.name,
(select ""ratio"" from pertinence p, entity en
- where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + id_entity.ToString() + @" and
+ where p.""to"" =3D c.id_entity and p.id_ent=
ity =3D " + idEntity + @" and
en.id_entity =3D p.id_entity and en.""delDate"" is null) as r=
atio
from class c, entity e
where
c.id_entity =3D e.id_entity and
c.""isHidden"" =3D 'f' and
e.""delDate"" is null and
- e.""domainId"" in (" + domain.ToString() + @", 10) order by c.""c=
lassType"" DESC, c.name";
+ e.""domainId"" in (" + domainId + @", 10) order by c.""classType"=
" DESC, c.name";
=09
res =3D this.doSelect(query);
return res;
@@ -944,8 +945,8 @@
/// <summary>
/// Get the string id of the pertinence attribute an attribute is rela=
ted to
/// </summary>
- /// <param name=3D"attribute">The attribute for which we want th=
e pertinence attribute related to</param>
- /// <return>The attribute of the pertinence attribute or "" if a=
ttributeId is not a pertinence attribute</returns>
+ /// <param name=3D"attributeId">The attribute for which we want =
the pertinence attribute related to</param>
+ /// <returns>The attribute of the pertinence attribute or "" if =
attributeId is not a pertinence attribute</returns>
override public string GetPertinenceForAttribute(string attribut=
eId)
{
string req =3D "select \"id_entity\" from attribute where \"=
classId\" in (select \"to\" from pertinence where id_entity =3D " + Conve=
rt.ToInt32(attributeId) + ")";
@@ -962,10 +963,10 @@
}
=20
/// <summary>
- /// Converts a system attribute name into a user attribute name
+ /// Converts a system attribute name into a user attribute name
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>user attribute name</returns>
+ /// <returns>user attribute name</returns>
override public string ConvertSysAttNameToUserAttName(string sys=
AttName)
{
string req =3D "select \"attName\" from attribute where \"sy=
sAttName\" =3D '" + sysAttName +"'";
@@ -983,10 +984,10 @@
}
=20
/// <summary>
- /// Tells if an attribute is primary=20
+ /// Tells if an attribute is primary=20
/// </summary>
/// <param name=3D"sysAttName">system name for attribute </param=
>
- /// <return>true if attribute is primary</returns>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(string sysAttName)
{
string req =3D "select \"isPrimary\" from attribute where \"=
sysAttName\" =3D '" + sysAttName + "'";
@@ -1008,10 +1009,10 @@
}
=20
/// <summary>
- /// Tells if an attribute is primary=20
+ /// Tells if an attribute is primary=20
/// </summary>
- /// <param name=3D"sysAttName">id of attribute </param>
- /// <return>true if attribute is primary</returns>
+ /// <param name=3D"attId">id of attribute </param>
+ /// <returns>true if attribute is primary</returns>
override public bool IsPrimary(int attId)
{
string req =3D "select \"isPrimary\" from attribute where \"=
id_entity\" =3D '" + attId + "'";
@@ -1052,14 +1053,13 @@
return IsSelfLookUp;
} =20
/// <summary>
- /// Get the params (where, orderby etc...) of a view
+ /// Get the params (where, orderby etc...) of a view
/// </summary>
- /// <param name=3D"id">id of view</param>
- /// <return>params of view in a array</returns>
- override public string [] GetParamsView(int id)
+ /// <param name=3D"viewId">id of view</param>
+ /// <returns>params of view in a array</returns>
+ override public string [] GetParamsView(int viewId)
{ =20
-
- string idStr =3D Convert.ToString(id);
+ string idStr =3D Convert.ToString(viewId);
string req =3D "select \"groupby\", \"columns\",\"where\",\"=
order\" from view where id_entity=3D" + idStr;
string [] res =3D new string[4];
=20
@@ -1081,13 +1081,13 @@
=20
=20
/// <summary>
- /// Get the params (where, orderby etc...) of a report
+ /// Get the params (where, orderby etc...) of a report
/// </summary>
- /// <param name=3D"id">id of report</param>
- /// <return>params of the report</returns>
- override public string [] GetParamsReport(int id)
+ /// <param name=3D"reportId">id of report</param>
+ /// <returns>params of the report</returns>
+ override public string [] GetParamsReport(int reportId)
{
- string idStr =3D Convert.ToString(id);
+ string idStr =3D Convert.ToString(reportId);
string req =3D "select \"columns\",\"where\",\"order\",\"gr=
oupby\",\"having\",\"idClassReport\" from report where id_entity=3D" + id=
Str;
string [] res =3D new string[6];
=20
@@ -1128,7 +1128,7 @@
foreach(DataRow dRow in tmpTable.Rows)
{
int attribClass =3D Convert.ToInt32(dRow[classIdCol[0]]);
- string colname =3D dRow[classIdCol[0]].ToString();
+ //string colname =3D dRow[classIdCol[0]].ToString();
string classTable =3D getTableName(attribClass);
switch (classId)
{
Modified: humano2/branches/cleanup/core/db/pgsql/pgsqlConnection.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/branches/cleanup/core/db/pgsql/pgsqlConnection.cs 2005-05-27 =
04:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/core/db/pgsql/pgsqlConnection.cs 2005-05-27 =
05:01:38 UTC (rev 1161)
@@ -129,14 +129,14 @@
override public object doScalar(string query)
{
// Cast-down a tipo mas potente.
- object tmpObj;
+ //object tmpObj;
Open();
NpgsqlConnection conn =3D ( (NpgsqlConnection) dbCon );
NpgsqlCommand dbCmd =3D conn.CreateCommand( );
dbCmd.CommandText =3D query;
=09
IDataReader dr;
- try
+ try
{
dr =3D dbCmd.ExecuteReader( );
Close();
@@ -151,7 +151,7 @@
=20
if( dr.Read( ) && !Convert.IsDBNull( dr[0] ) )
{
- tmpObj =3D dr[0];
+ //tmpObj =3D dr[0];
dr.Close();
dbCmd.Dispose();
return dr[0];
@@ -246,11 +246,11 @@
=09
tgtTable.TableName =3D fillTable;
tgtTable =3D srcTable.Copy( );
- NpgsqlCommandBuilder SqlCB =3D new NpgsqlCommandBuilder( da );
+ //NpgsqlCommandBuilder SqlCB =3D new NpgsqlCommandBuilder( da );
da.Fill( tgtTable );
tgtTable =3D srcTable.Copy( );
ds.Tables.Add( tgtTable );
- string strXml =3D ds.GetXml( );
+ //string strXml =3D ds.GetXml( );
da.Update( tgtTable );
Close();
}
Modified: humano2/branches/cleanup/core/db/pgsql/pgsqlCrud.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/branches/cleanup/core/db/pgsql/pgsqlCrud.cs 2005-05-27 04:29:=
17 UTC (rev 1160)
+++ humano2/branches/cleanup/core/db/pgsql/pgsqlCrud.cs 2005-05-27 05:01:=
38 UTC (rev 1161)
@@ -97,15 +97,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
@@ -344,15 +344,15 @@
idList.AddRange( Inh );
=09
//Verifico cual es el id de la clase base.
- int idParent;
+ //int idParent;
if( Inh.Length =3D=3D 0 )
{
- idParent =3D idEntity;
+ //idParent =3D idEntity;
idList.AddRange( getInheritanceOfType( idEntity ) );
}
else
{
- idParent =3D Inh[0];
+ //idParent =3D Inh[0];
}
=09
=09
Modified: humano2/branches/cleanup/core/tests/mdPertinenceTests.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/branches/cleanup/core/tests/mdPertinenceTests.cs 2005-05-27 0=
4:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/core/tests/mdPertinenceTests.cs 2005-05-27 0=
5:01:38 UTC (rev 1161)
@@ -46,7 +46,7 @@
string[] pertNamesTable =3D {"attName", "classId", "to", "ratio"=
};
object[] pertValuesTable=3D {"Trabajo", persId , empresaId, "n:1"};
DataTable dt =3D utils.buildTable(pertNamesTable, pertValuesTable);
- int trabID =3D crud.Create((int) MetaModelConsts.EntitiesPertinence, =
dt);
+ crud.Create((int) MetaModelConsts.EntitiesPertinence, dt); // int tra=
bID
}
=20
[Test]
@@ -156,13 +156,13 @@
string[] accRelNamesTable =3D {"attName","classId", "to", "ratio"=
};
object[] accRelValuesTable=3D {"access" ,navId, accessId, "n:1"};
dt =3D utils.buildTable(accRelNamesTable, accRelValuesTable);
- int accRelAttId =3D crud.Create((int) MetaModelConsts.EntitiesPertine=
nce, dt);
+ crud.Create((int) MetaModelConsts.EntitiesPertinence, dt); // int acc=
RelAttId
=09
int[] pIds =3D createPersonas(persId);
=09
int[] aIds =3D creaAccessos(accessId);
=09
- int e1Id =3D createNAVEmpresa(empresaId, navId, pIds, aIds);
+ createNAVEmpresa(empresaId, navId, pIds, aIds); // int e1Id
=09
// Console.WriteLine("***** NAV TABLE *****\n\n");
// DbUtils.DumpData(crud.ReadStructure(navId));
@@ -289,7 +289,7 @@
string[] levelNamesTable =3D {"attName", "classId"};
object[] levelValuesTable=3D {"level" , accessId};
dt =3D utils.buildTable(levelNamesTable, levelValuesTable);
- int levelAttId =3D crud.Create((int) testConsts.entityIdTextLine, dt)=
;
+ crud.Create((int) testConsts.entityIdTextLine, dt); // int levelAttId
=09
return accessId;
}
Modified: humano2/branches/cleanup/web/builder/site/buildattribute.aspx.c=
s
=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/branches/cleanup/web/builder/site/buildattribute.aspx.cs 2005=
-05-27 04:29:17 UTC (rev 1160)
+++ humano2/branches/cleanup/web/builder/site/buildattribute.aspx.cs 2005=
-05-27 05:01:38 UTC (rev 1161)
@@ -488,7 +488,6 @@
}
=20
int viewClassId;
- string viewColumn;
string viewWhereComplete;
string displayColumn;
string variableName =3D userCred.CoreAdapter.GetPertinenceFilterValu=
es(filterViewId, out viewClassId, out viewWhereComplete, out displayColum=
n);
@@ -754,8 +753,7 @@
string viewStr =3D Convert.ToString( getDataFromSetByIdEntity(pertSe=
t, (int) PertinenceConsts.FilterView) );
if(viewStr !=3D "")=20
{
- int commaIndex =3D -1;
- if( (commaIndex =3D viewStr.IndexOf(',')) =3D=3D -1)
+ if( viewStr.IndexOf(',') =3D=3D -1)
{
tblViewId =3D Convert.ToInt32(viewStr);
}=20
@@ -776,7 +774,6 @@
}
=09
res.Append(@"<select name=3D""to"" class=3D""pbttn"" onchange=3D""relo=
adPermClass(this.options[this.selectedIndex].value)"">");
- string currRatio =3D "";
forea...
[truncated message content] |
|
From: <sv...@de...> - 2005-05-27 04:29:19
|
Author: marijn Date: 2005-05-27 00:29:17 -0400 (Fri, 27 May 2005) New Revision: 1160 Added: humano2/branches/cleanup/ Log: * Small branch to cleanup silly compiler warnings. Copied: humano2/branches/cleanup (from rev 1159, humano2/trunk) |
|
From: <sv...@de...> - 2005-05-26 23:59:30
|
Author: marcelo
Date: 2005-05-26 19:58:57 -0400 (Thu, 26 May 2005)
New Revision: 1159
Modified:
humano2/trunk/core/db/pgsql/pgsqlCrud.cs
Log:
* Fixed eternal loop when creating a class whose sysname already exists
Modified: humano2/trunk/core/db/pgsql/pgsqlCrud.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/core/db/pgsql/pgsqlCrud.cs 2005-05-26 22:58:04 UTC (rev=
1158)
+++ humano2/trunk/core/db/pgsql/pgsqlCrud.cs 2005-05-26 23:58:57 UTC (rev=
1159)
@@ -1477,6 +1477,7 @@
string sysName =3D baseSysName;
do
{
+ exists =3D false;
ArrayList arr =3D getInheritanceByName(sysName,"class");
if (arr.Count > 0 )
{
|
|
From: <sv...@de...> - 2005-05-26 22:58:25
|
Author: svera
Date: 2005-05-26 18:58:04 -0400 (Thu, 26 May 2005)
New Revision: 1158
Modified:
humano2/trunk/components/webTools/session.cs
humano2/trunk/web/builder/site/formmanagement.aspx.cs
Log:
* Fix problem for session expire in builder.
Modified: humano2/trunk/components/webTools/session.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/components/webTools/session.cs 2005-05-26 22:38:59 UTC =
(rev 1157)
+++ humano2/trunk/components/webTools/session.cs 2005-05-26 22:58:04 UTC =
(rev 1158)
@@ -89,6 +89,10 @@
private Mutex mutexKey;
=20
/// <summary>
+ /// Para indicar una nueva fecha y hora de conexion y que no expire la=
session
+ /// </summary>
+ public DateTime newAccess =3D DateTime.Now;
+ /// <summary>
/// Constructor.. aqui inicializamos el hash;
/// </summary>
private SessionManager(){
@@ -98,16 +102,10 @@
timerControler.Start();
}
=20
- public void setNewLastAcces()
+ public void setNewLastAccess()
{
- ArrayList valList;
- SessionCredencial sc =3D null;
- valList =3D new ArrayList (h.Values);
- for (int i =3D 0; i < valList.Count; i++)
- {
- sc =3D(SessionCredencial)valList[i];
- sc.lastAccess =3D DateTime.Now;
- }
+ SessionManager cs =3D SessionManager.currentSessionManager;
+ cs.newAccess =3D DateTime.Now;
}
=20
/// <summary>
@@ -349,7 +347,7 @@
{
while(true)
{
- Thread.Sleep(300000);
+ Thread.Sleep(SessionManager.Current.timeOfLive);
try
{
keyList =3D new ArrayList(h.Keys);
@@ -359,7 +357,11 @@
=20
for(int i=3D0;i<valList.Count;i++ )
{
- sC =3D (SessionCredencial)valList[i];
+ sC =3D (SessionCredencial)valList[i];
+ if (SessionManager.currentSessionManager.newAccess > sC.lastAcces=
s)
+ {
+ sC.lastAccess =3D SessionManager.currentSessionManager.newAccess=
;
+ }
if (sC.lastAccess < dieTime)
{
h.Remove(keyList[i]);
Modified: humano2/trunk/web/builder/site/formmanagement.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/builder/site/formmanagement.aspx.cs 2005-05-26 22:3=
8:59 UTC (rev 1157)
+++ humano2/trunk/web/builder/site/formmanagement.aspx.cs 2005-05-26 22:5=
8:04 UTC (rev 1158)
@@ -41,7 +41,7 @@
=09
private void Page_Load(object sender, System.EventArgs e)
{
-=09
+ SessionManager.Current.setNewLastAccess();
getRequestParam();
if (ClassId > 0 && action !=3D CNS_DELETE)
{
|
|
From: <sv...@de...> - 2005-05-26 22:39:01
|
Author: marijn
Date: 2005-05-26 18:38:59 -0400 (Thu, 26 May 2005)
New Revision: 1157
Modified:
humano2/trunk/components/webTools/Adapter.cs
humano2/trunk/core/config.cs
humano2/trunk/core/environment.cs
Log:
* Adding support for primitive database type detection.
* Adding a work around so that microsoftSQL server doesn't choke on view=
paging.
Modified: humano2/trunk/components/webTools/Adapter.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/components/webTools/Adapter.cs 2005-05-26 20:44:42 UTC =
(rev 1156)
+++ humano2/trunk/components/webTools/Adapter.cs 2005-05-26 22:38:59 UTC =
(rev 1157)
@@ -329,24 +329,24 @@
Humano2.Components.ViewTools.ViewTools vt =3D new Humano2.Components.=
ViewTools.ViewTools(iniClass);
vt.Complex =3D complex;
vt.KeyFlag=3DkeyFlag;
- Logger.Log("ExecViewFromDataTable: vtTable.Rows[0][\"order\"]=3D " + =
vtTable.Rows[0]["order"],LogLevel.Trace);
- Logger.Log("ExecViewFromDataTable: order=3D " + "*" + order =
+ "*",LogLevel.Trace);
if((order !=3D null) && (order !=3D""))
{=20
Logger.Log("ExecViewFromDataTable: " + "order!=3D \"\"",Lo=
gLevel.Trace);
vtTable.Rows[0]["order"] =3D order; // Set the order with which are=
recovered the values.
}
=09
- if(page !=3D 0)=20
- { =20
- Logger.Log("ExecViewFromDataTable: page: " + page , LogLevel.Trace)=
;
+ if(Config.Instance().DataBase !=3D DataBaseEnum.MicrosoftSQL)
+ { //FIXME: Microsoft SQL server no hace paging correctamente actualme=
nte.=20
+ if(page !=3D 0)=20
+ { =20
+ Logger.Log("ExecViewFromDataTable: page: " + page , LogLevel.Trace)=
;
=20
- vt.Page =3D 1; // Do Pageing
- vt.RowsView =3D 20; // Number of rows per page.
- //vt.RowsView =3D 2; // Number of rows per page.
- vt.PageView =3D page; // Set the current page
+ vt.Page =3D 1; // Do Pageing
+ vt.RowsView =3D 20; // Number of rows per page.
+ //vt.RowsView =3D 2;=20
+ vt.PageView =3D page; // Set the current page
+ }
}
- Logger.Log("ExecViewFromDataTable: vtTable.Rows[0][\"order\"=
]=3D " + vtTable.Rows[0]["order"],LogLevel.Trace);
DataTable viewInstancesData =3D new DataTable();
=20
// Ejecuta el ViewTools y traye todos los valores en un dataTable.
Modified: humano2/trunk/core/config.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/core/config.cs 2005-05-26 20:44:42 UTC (rev 1156)
+++ humano2/trunk/core/config.cs 2005-05-26 22:38:59 UTC (rev 1157)
@@ -144,12 +144,22 @@
}
=09
RunTimeEnum _runtime =3D RunTimeEnum.Unknown;
+ DataBaseEnum _database =3D DataBaseEnum.Unknown;
=09
/// <summary>
- /// Detect the runtime environment.
+ /// Detect the environment that we are running in.
/// </summary>
private void detectEnvironment()
{
+ detectRunTime();
+ detectDataBase();
+ }
+
+ /// <summary>
+ /// Detect the runtime that we are using.
+ /// </summary>
+ private void detectRunTime()
+ {
if( Type.GetType( "Mono.Runtime", false ) !=3D null )
{
// we're on Mono
@@ -159,11 +169,34 @@
}
}
=09
+ ///<summary>Detect what database type is being used.</summary>
+ private void detectDataBase()
+ {
+ string dataBaseDll =3D GetOption("database", "driver");
+ if( dataBaseDll =3D=3D "Humano2.Core.Db.Pgsql.dll")
+ {
+ _database =3D DataBaseEnum.PostgreSQL;
+ }
+ else if( dataBaseDll =3D=3D "Humano2.Core.Db.Mssql.dll" )
+ {
+ _database =3D DataBaseEnum.MicrosoftSQL;
+ }
+ }
+
+ ///<summary>Returns the run time that we are using.</summary>
public RunTimeEnum RunTime
{
get
{ return _runtime; }
}
+
+ ///<summary>Returns the database type that we are using.</summary>
+ public DataBaseEnum DataBase
+ {
+ get
+ { return _database; }
+ }
+
=09
}
=09
Modified: humano2/trunk/core/environment.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/core/environment.cs 2005-05-26 20:44:42 UTC (rev 1156)
+++ humano2/trunk/core/environment.cs 2005-05-26 22:38:59 UTC (rev 1157)
@@ -17,4 +17,11 @@
Mono,
IIS,
}
+
+ public enum DataBaseEnum : int{
+ Unknown,
+ PostgreSQL,
+ MicrosoftSQL,
+ }
+
}
|
|
From: <sv...@de...> - 2005-05-26 20:44:53
|
Author: svera
Date: 2005-05-26 16:44:42 -0400 (Thu, 26 May 2005)
New Revision: 1156
Modified:
humano2/trunk/components/webTools/session.cs
Log:
* New Method for use in Builder, fix problem with expire session
Modified: humano2/trunk/components/webTools/session.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/components/webTools/session.cs 2005-05-26 20:26:37 UTC =
(rev 1155)
+++ humano2/trunk/components/webTools/session.cs 2005-05-26 20:44:42 UTC =
(rev 1156)
@@ -97,6 +97,18 @@
Thread timerControler =3D new Thread(new ThreadStart(timeDeletion));
timerControler.Start();
}
+
+ public void setNewLastAcces()
+ {
+ ArrayList valList;
+ SessionCredencial sc =3D null;
+ valList =3D new ArrayList (h.Values);
+ for (int i =3D 0; i < valList.Count; i++)
+ {
+ sc =3D(SessionCredencial)valList[i];
+ sc.lastAccess =3D DateTime.Now;
+ }
+ }
=20
/// <summary>
/// Libera todos los recursos de la session manager
|
|
From: <sv...@de...> - 2005-05-26 20:26:41
|
Author: pcamacho
Date: 2005-05-26 16:26:37 -0400 (Thu, 26 May 2005)
New Revision: 1155
Modified:
humano2/trunk/web/portal/site/leftbar.aspx.cs
Log:
FIX: the leftbar was crashing when trying to show folders because sometim=
es the child of a folder was arriving (in=20
the xml generated by leftbar.aspx.cs) before the father, so the javascrip=
t generated by xsl was wrong. The solution=20
was only to sort the folder by they id_entity, as a father is always crea=
ted before a child.
Modified: humano2/trunk/web/portal/site/leftbar.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/leftbar.aspx.cs 2005-05-26 19:28:12 UTC=
(rev 1154)
+++ humano2/trunk/web/portal/site/leftbar.aspx.cs 2005-05-26 20:26:37 UTC=
(rev 1155)
@@ -104,8 +104,10 @@
{
string Forms=3D"";
string filtro =3D String.Format("34|0|'{0}'|0|0",userCred.DomainIds[=
userCred.CurrentDomainIndex]);
- =09
- DataTable DTFolder =3D dbAdapter.GenerateViewTools(1400,"0,1401,1403=
,1402",filtro,"","","",0);
+ string folderOrder =3D "1401|0"; //We must order the folders because=
parents must appear before children=20
+ // when the webfxjstree i=
s built in the leftbar
+ =20
+ DataTable DTFolder =3D dbAdapter.GenerateViewTools(1400,"0,1401,1403=
,1402",filtro,"","",folderOrder,0);
=20
DataTable DTView =3D dbAdapter.GenerateViewTools(1011,"0,1017,1018",=
filtro,"","","",0);
=20
|
|
From: <sv...@de...> - 2005-05-26 19:28:14
|
Author: pcamacho
Date: 2005-05-26 15:28:12 -0400 (Thu, 26 May 2005)
New Revision: 1154
Modified:
humano2/trunk/core/schema/pgsql/pgsql-4-extendedAttributes.sql
Log:
CHANGE: the attributes password, URL, RUT, HTML, email and currency work =
well. Tey have been put like "not hidden" in=20
the metamodel, so they can appear in the list of attributes for the modif=
ication of a class in the builder (Only=20
for postgres).=20
Modified: humano2/trunk/core/schema/pgsql/pgsql-4-extendedAttributes.sql
=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/core/schema/pgsql/pgsql-4-extendedAttributes.sql 2005-0=
5-26 17:01:14 UTC (rev 1153)
+++ humano2/trunk/core/schema/pgsql/pgsql-4-extendedAttributes.sql 2005-0=
5-26 19:28:12 UTC (rev 1154)
@@ -76,12 +76,12 @@
Alter table "image" add foreign key ("id_entity") references "attribute=
" ("id_entity") on update restrict on delete cascade;
=20
=20
-INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (94,27,'email','email',8,'f','t');
-INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (87,27,'currency','currency',9,'f','t'=
);
-INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (500,27, 'password','password',8,'f','=
t');
-INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (502,27, 'HTML','HTML',13,'f','t');
-INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (503,27, 'RUT','RUT',8,'f','t');
-INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (504,27, 'URL','URL',8,'f','t');
+INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (94,27,'email','email',8,'f','f');
+INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (87,27,'currency','currency',9,'f','f'=
);
+INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (500,27, 'password','password',8,'f','=
f');
+INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (502,27, 'HTML','HTML',13,'f','f');
+INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (503,27, 'RUT','RUT',8,'f','f');
+INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (504,27, 'URL','URL',8,'f','f');
INSERT INTO "class" ("id_entity","classType","sysName","name","parentId=
","isAbstract","isHidden") VALUES (506,27, 'image','image',39,'f','t');
=20
=20
|
|
From: <sv...@de...> - 2005-05-26 17:01:21
|
Author: pcamacho
Date: 2005-05-26 13:01:14 -0400 (Thu, 26 May 2005)
New Revision: 1153
Modified:
humano2/trunk/web/portal/site/js/commonfunctions.js
humano2/trunk/web/portal/site/showView.aspx.cs
humano2/trunk/web/portal/site/xsl/pertinence.xsl
Log:
FIX: the attribute pertinence had an ugly representation (file pertinence=
.xsl). Now it looks like before.
Modified: humano2/trunk/web/portal/site/js/commonfunctions.js
=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/js/commonfunctions.js 2005-05-26 16:30:=
59 UTC (rev 1152)
+++ humano2/trunk/web/portal/site/js/commonfunctions.js 2005-05-26 17:01:=
14 UTC (rev 1153)
@@ -78,26 +78,24 @@
childElem =3D div.childNodes[j];
=20
//Here we need to put every tag name which has to be filled =
by the user
- if((childElem.tagName =3D=3D 'INPUT' || childElem.tagName =3D=
=3D 'TEXTAREA')) //the child is an input or a textarea ie is not a text
+ if( (childElem.tagName =3D=3D 'INPUT') =20
+ || (childElem.tagName =3D=3D 'TEXTAREA')) //the child i=
s an input or a textarea or hidden (for pertinence) ie is not a text
{
- if(childElem.getAttribute("type") !=3D "hidden") //Don't=
take hidden input
+ divRefArray =3D fn_getElemntsByTagName("div","divListasL=
eft");
+ //alert("allInputsToCheck.Get(" + i + "):" + allInputsTo=
Check.Get(i));
+ allInputsToCheck.SetValue(i,childElem.value); //Get the =
choosen value
+ divOk =3D alertUserWhenEmptyField(isObligatoryArray[=
i],childElem,attNameArray[i]) //Obligatory field
+ && allInputsToCheck.Get(i).Check(); //Other che=
cks ()allInputsToCheck is a global variable defined in readXslt.aspx
+ //If an attribute is not well filled, then put its name =
color to red
+ // else put it to black (normal)
+ if(!divOk)
{
- divRefArray =3D fn_getElemntsByTagName("div","divLis=
tasLeft");
- //alert("allInputsToCheck.Get(" + i + "):" + allInpu=
tsToCheck.Get(i));
- allInputsToCheck.SetValue(i,childElem.value); //Get =
the choosen value
- divOk =3D alertUserWhenEmptyField(isObligatoryAr=
ray[i],childElem,attNameArray[i]) //Obligatory field
- && allInputsToCheck.Get(i).Check(); //Other=
checks ()allInputsToCheck is a global variable defined in readXslt.aspx
- //If an attribute is not well filled, then put its n=
ame color to red
- // else put it to black (normal)
- if(!divOk)
- {
- divRefArray[i].style.color=3D"red";
- }else
- {
- divRefArray[i].style.color=3D"black";
- }
- formOk =3D divOk && formOk; //Check if all the form =
is well filled
+ divRefArray[i].style.color=3D"red";
+ }else
+ {
+ divRefArray[i].style.color=3D"black";
}
+ formOk =3D divOk && formOk; //Check if all the form is w=
ell filled
}
} =20
} =20
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-05-26 16:30:59 UT=
C (rev 1152)
+++ humano2/trunk/web/portal/site/showView.aspx.cs 2005-05-26 17:01:14 UT=
C (rev 1153)
@@ -121,7 +121,7 @@
}
else
{
- viewTable =3D getStructForSearch(iniClass,idAttributes,idOperators,v=
aluesToSearch);
+ viewTable =3D getViewForSearch(iniClass,idAttributes,idOperators,val=
uesToSearch);
}
=20
// If there are multiple "order" arguments, they should be s=
eperated by ",";
@@ -200,7 +200,7 @@
return xmlString;
}
=20
- private DataTable getStructForSearch(int iniClass,string idAttributes,=
string idOperators,string valuesToSearch)
+ private DataTable getViewForSearch(int iniClass,string idAttributes,st=
ring idOperators,string valuesToSearch)
{
DataTable dtParam =3D this.makeDataTableInViewTools();
DataRow dr =3D dtParam.NewRow();
@@ -210,7 +210,7 @@
=20
//Explicacion de los filtros...
char separator =3D '$';
- dr["filtros"] =3D getFilters(idAttributes,idOperators,valuesToSearch,=
separator);
+ dr["filtros"] =3D getFilterForSearch(idAttributes,idOperators,valuesT=
oSearch,separator);
Logger.Log("search: filtros =3D " + dr["filtros"],LogLevel.Trace);
=20
=20
@@ -252,10 +252,10 @@
}
=20
=20
- private string getFilters(string idAttributes, string idOperators, str=
ing valuesToCompare, char separator)
+ private string getFilterForSearch(string idAttributes, string idOperat=
ors, string valuesToCompare, char separator)
{
string filter =3D"";
- Logger.Log("getFilters: Step1", LogLevel.Trace);
+ =09
string [] idAttributesArr =3D idAttributes.Split(new char [] {separat=
or});
string [] idOperatorsArr =3D idOperators.Split(new char [] {separator=
});
string [] valuesToCompareArr =3D valuesToCompare.Split(new char [] {s=
eparator});
@@ -270,7 +270,7 @@
{
filter +=3D idAttributesArr[i] + "|" + idOperatorsArr[i] + "|'" + v=
aluesToCompareArr[i] + "'|1|0;"; =20
}
- Logger.Log("getFilters: Step2", LogLevel.Trace);
+ =09
int lastIndex =3D idAttributesArr.Length-2; //The index idAttributes=
Arr.Length-1 is empty because of split
filter +=3D idAttributesArr[lastIndex] + "|" + idOperatorsArr[lastIn=
dex] + "|'" + valuesToCompareArr[lastIndex] + "'|0|0"; =20
}
Modified: humano2/trunk/web/portal/site/xsl/pertinence.xsl
=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/xsl/pertinence.xsl 2005-05-26 16:30:59 =
UTC (rev 1152)
+++ humano2/trunk/web/portal/site/xsl/pertinence.xsl 2005-05-26 17:01:14 =
UTC (rev 1153)
@@ -18,16 +18,22 @@
=09
<xsl:when test=3D"/page/flagaction=3D'Update'">
<xsl:if test=3D"string($isEditable)=3D'true'">
- <input type=3D"text" name=3D"{concat('txt_',=
$sysAttName)}" value=3D"{$refData}" onfocus=3D"hideIFrame('{concat('frame=
_',$idEntity)}')" readonly=3D"readonly"/>
- =20
- <xsl:if test=3D"not($filterView)">
- <img src=3D"img/arrowDown.gif" border=3D=
"0" onclick=3D"toggleIFrame('{concat('frame_',$idEntity)}','viewpertinenc=
elist.aspx?idClass=3D{$idClass}&idEntity=3D{$idEntity}&sysAttName=
=3D{$sysAttName}');"></img>
- </xsl:if>=20
- <xsl:if test=3D"$filterView">
- <img src=3D"img/arrowDown.gif" border=3D=
"0" onclick=3D"toggleIFrameWithFilter('{concat('frame_',$idEntity)}','vie=
wpertinencelist.aspx?idClass=3D{$idClass}&idEntity=3D{$idEntity}&=
sysAttName=3D{$sysAttName}', '{$filterView}');"></img>
- </xsl:if>=20
- <img src=3D"img/1x1.gif" border=3D"0" width=
=3D"22" heigth=3D"22"></img>
- =20
+ <table border=3D"0" cellSpacing=3D"0" cellPa=
dding=3D"0" >
+ <tr>
+ <td valign=3D"top">
+ <input type=3D"text" name=3D"{co=
ncat('txt_',$sysAttName)}" value=3D"{$refData}" onfocus=3D"hideIFrame('{c=
oncat('frame_',$idEntity)}')" readonly=3D"readonly"/>
+ </td>
+ <td valign=3D"center">
+ <xsl:if test=3D"not($filterView)=
">
+ <img src=3D"img/arrowDown.gi=
f" border=3D"0" onclick=3D"toggleIFrame('{concat('frame_',$idEntity)}','v=
iewpertinencelist.aspx?idClass=3D{$idClass}&idEntity=3D{$idEntity}&am=
p;sysAttName=3D{$sysAttName}');"></img>
+ </xsl:if>=20
+ <xsl:if test=3D"$filterView">
+ <img src=3D"img/arrowDown.gi=
f" border=3D"0" onclick=3D"toggleIFrameWithFilter('{concat('frame_',$idEn=
tity)}','viewpertinencelist.aspx?idClass=3D{$idClass}&idEntity=3D{$id=
Entity}&sysAttName=3D{$sysAttName}', '{$filterView}');"></img>
+ </xsl:if>=20
+ <img src=3D"img/1x1.gif" border=3D=
"0" width=3D"22" heigth=3D"22"></img>
+ </td>
+ </tr>
+ </table>=09
<!--<input type=3D"button" name=3D"aaa" value=3D"Ver" onclick=3D"=
toggleIFrame('{concat('frame_',$idEntity)}','viewpertinencelist.aspx?idCl=
ass=3D{$idClass}&idEntity=3D{$idEntity}&sysAttName=3D{$sysAttName=
}');" />-->
<input type=3D"hidden" name=3D"{$sysAttName}" value=3D"{$data}" r=
eadonly=3D"readonly"/>
<iframe id=3D"{concat('frame_',$idEntity)}" src=3D"" style=3D"vis=
ibility: hidden; position:absolute;" width=3D"190" height=3D"165" framebo=
rder=3D"0" scrolling=3D"no" align=3D"middle"></iframe>
@@ -40,17 +46,23 @@
<xsl:when test=3D"/page/flagaction=3D'Create'">
<xsl:if test=3D"string($isEditable)=3D'true'"> =20
=20
- <input type=3D"text" name=3D"{concat('txt_',$sys=
AttName)}" value=3D"{$refData}" onfocus=3D"hideIFrame('{concat('frame_',$=
idEntity)}')" readonly=3D"readonly"/>
- =20
- <xsl:if test=3D"not($filterView)">
- <img src=3D"img/arrowDown.gif" border=3D"0" =
onclick=3D"toggleIFrame('{concat('frame_',$idEntity)}','viewpertinencelis=
t.aspx?idClass=3D{$idClass}&idEntity=3D{$idEntity}&sysAttName=3D{=
$sysAttName}');"></img>
- </xsl:if>=20
- <xsl:if test=3D"$filterView">
- <img src=3D"img/arrowDown.gif" border=3D"0" =
onclick=3D"toggleIFrameWithFilter('{concat('frame_',$idEntity)}','viewper=
tinencelist.aspx?idClass=3D{$idClass}&idEntity=3D{$idEntity}&sysA=
ttName=3D{$sysAttName}', '{$filterView}');"></img>
- </xsl:if>=20
- <img src=3D"img/1x1.gif" border=3D"0" width=3D"=
22" heigth=3D"22"></img>
- =20
- <!--<input type=3D"button" name=3D"aaa" value=3D"Ver" onclick=3D"t=
oggleIFrame('{concat('frame_',$idEntity)}','viewpertinencelist.aspx?idCla=
ss=3D{$idClass}&idEntity=3D{$idEntity}&sysAttName=3D{$sysAttName}=
');"/>-->
+ <table border=3D"0" cellSpacing=3D"0" cellPaddin=
g=3D"0" >
+ <tr>
+ <td valign=3D"top">
+ <input type=3D"text" name=3D"{concat=
('txt_',$sysAttName)}" value=3D"{$refData}" onfocus=3D"hideIFrame('{conca=
t('frame_',$idEntity)}')" readonly=3D"readonly"/>
+ </td>
+ <td valign=3D"center">
+ <xsl:if test=3D"not($filterView)">
+ <img src=3D"img/arrowDown.gif" b=
order=3D"0" onclick=3D"toggleIFrame('{concat('frame_',$idEntity)}','viewp=
ertinencelist.aspx?idClass=3D{$idClass}&idEntity=3D{$idEntity}&sy=
sAttName=3D{$sysAttName}');"></img>
+ </xsl:if>=20
+ <xsl:if test=3D"$filterView">
+ <img src=3D"img/arrowDown.gif" b=
order=3D"0" onclick=3D"toggleIFrameWithFilter('{concat('frame_',$idEntity=
)}','viewpertinencelist.aspx?idClass=3D{$idClass}&idEntity=3D{$idEnti=
ty}&sysAttName=3D{$sysAttName}', '{$filterView}');"></img>
+ </xsl:if>=20
+ <img src=3D"img/1x1.gif" border=3D"0=
" width=3D"22" heigth=3D"22"></img>
+ </td>
+ </tr>
+ </table>=09
+ =20
<input type=3D"hidden" name=3D"{$sysAttName}" />
<iframe id=3D"{concat('frame_',$idEntity)}" src=3D"" style=3D"visi=
bility: hidden; position:absolute;" width=3D"190" height=3D"165" framebor=
der=3D"0" scrolling=3D"no" align=3D"middle" ></iframe>
</xsl:if>
|
|
From: <sv...@de...> - 2005-05-26 16:31:00
|
Author: pcamacho
Date: 2005-05-26 12:30:59 -0400 (Thu, 26 May 2005)
New Revision: 1152
Modified:
humano2/trunk/components/webTools/Adapter.cs
humano2/trunk/core/db/pgsql/pgsqlComplex.cs
humano2/trunk/web/portal/site/addOption.aspx.cs
humano2/trunk/web/portal/site/showView.aspx.cs
Log:
CHANGE: factorization: the GetPrimaryAttributeIdForClass has migrated to =
Adapter.
Modified: humano2/trunk/components/webTools/Adapter.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/components/webTools/Adapter.cs 2005-05-26 16:17:12 UTC =
(rev 1151)
+++ humano2/trunk/components/webTools/Adapter.cs 2005-05-26 16:30:59 UTC =
(rev 1152)
@@ -1754,20 +1754,9 @@
{
=09
if (id_entity =3D=3D "")
+ {
return "";
-// Humano2.Components.ViewTools.ViewTools vt =3D new ViewTools.ViewToo=
ls();
-// vt.Complex =3D complex;
-// DataTable table =3D getViewToolsTable();
-//
-// if(type_relation =3D=3D "")
-// type_relation =3D "f";
-//
-// // Get the id_entity and the domainName of all the domains in the s=
ystem.
-// string[] fila =3D {"70","71|4|'" + id_entity + "'|0|0","","","",""}=
;
-// table.Rows.Add(fila);
-// vt.IdClass =3D 81; // This is the pertinece table.
-// XmlDocument objXmlDocument=3Dnew XmlDocument();
-// objXmlDocument =3D vt.GetSQLXML(table);
+ }
DataTable dt =3D new DataTable();
dt =3D complex.getPertinenceByIdClass(Convert.ToInt32(id_entity));
=20
@@ -1784,11 +1773,9 @@
}
=20
//return objXmlDocument.InnerXml;
- return strxml ;
-
- =09
- =09
+ return strxml ;=09
}
+ =20
public int GetClassByID(int id_entity)
{
return complex.getClassIdofInstance(id_entity);
@@ -1818,8 +1805,29 @@
{
return id_attribute;
}
-
}
+ =20
+ ///<summary>Finds the id of the primary attribute of a class</su=
mmary>
+ ///<param name=3D"classId">the id of class</param>
+ ///<returns>The id of primary attribute</returns>
+ public int GetPrimaryAttributeIdForClass(int classId)
+ {
+ absCrud crud =3D Factory.Crud();
+ absComplex complex =3D crud.GetCore().Complex;
+ =20
+ DataTable res =3D GetAttributesFromClass(classId);
+ int idAtt =3D 0;
+ int i=3D0;
+ foreach(DataRow row in res.Rows)
+ {
+ if(complex.IsPrimary(Convert.ToInt32(row["id_entity"])))
+ {
+ idAtt =3D Convert.ToInt32(row["id_entity"]);
+ break; =20
+ }
+ }
+ return idAtt;
+ }
=20
public DataTable GenerateViewTools(int classId, string columns, string=
filters,=20
string groupby, string havings,=20
Modified: humano2/trunk/core/db/pgsql/pgsqlComplex.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/core/db/pgsql/pgsqlComplex.cs 2005-05-26 16:17:12 UTC (=
rev 1151)
+++ humano2/trunk/core/db/pgsql/pgsqlComplex.cs 2005-05-26 16:30:59 UTC (=
rev 1152)
@@ -1241,6 +1241,5 @@
return res; =09
=20
}
-
}
}
Modified: humano2/trunk/web/portal/site/addOption.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/addOption.aspx.cs 2005-05-26 16:17:12 U=
TC (rev 1151)
+++ humano2/trunk/web/portal/site/addOption.aspx.cs 2005-05-26 16:30:59 U=
TC (rev 1152)
@@ -49,7 +49,7 @@
int idClassRel =3D Convert.ToInt32(dr2["to"].ToString());
=09
//For each attribute of pertinence put the id with t=
ogo
- int relAttId =3D getPrimaryAttributeIdForClass(idCla=
ssRel);
+ int relAttId =3D dbAdapter.GetPrimaryAttributeIdForC=
lass(idClassRel);
strXml +=3D "parent.AddAtt('" + idAtt + "^" + relAtt=
Id;
}
=20
@@ -62,27 +62,6 @@
Response.Write(strXml);
}
=20
- private int getPrimaryAttributeIdForClass(int classId)
- {
- Logger.Log("getPrimaryAttributeIdForClass (before)",LogLevel=
.Trace);
- absCrud crud =3D Factory.Crud();
- absComplex complex =3D crud.GetCore().Complex;
- =20
- DataTable res =3D dbAdapter.GetAttributesFromClass(classId);
- int idAtt =3D 0;
- int i=3D0;
- foreach(DataRow row in res.Rows)
- {
- if(complex.IsPrimary(Convert.ToInt32(row["id_entity"])))
- {
- idAtt =3D Convert.ToInt32(row["id_entity"]);
- break; =20
- }
- }
- Logger.Log("getPrimaryAttributeIdForClass (after)",LogLevel.=
Trace);
- return idAtt;
- }
- =20
#region Web Form Designer generated code
override protected void OnInit(EventArgs e)
{
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-05-26 16:17:12 UT=
C (rev 1151)
+++ humano2/trunk/web/portal/site/showView.aspx.cs 2005-05-26 16:30:59 UT=
C (rev 1152)
@@ -240,7 +240,7 @@
DataRow dr2 =3D dtpert.Rows[0];
int idClassRel =3D Convert.ToInt32(dr2["to"].ToString());
//For each attribute of pertinence put the id with t=
ogo
- int relAttId =3D getPrimaryAttributeIdForClass(idCla=
ssRel);
+ int relAttId =3D userCred.CoreAdapter.GetPrimaryAttr=
ibuteIdForClass(idClassRel);
columnsList +=3D idAtt + "^" + relAttId;
}
columnsList +=3D ",";
@@ -252,27 +252,6 @@
}
=20
=20
- private int getPrimaryAttributeIdForClass(int classId)
- {
- Logger.Log("getPrimaryAttributeIdForClass (before)",LogLevel=
.Trace);
- absCrud crud =3D Factory.Crud();
- absComplex complex =3D crud.GetCore().Complex;
- =20
- DataTable res =3D userCred.CoreAdapter.GetAttributesFromClas=
s(classId);
- int idAtt =3D 0;
- int i=3D0;
- foreach(DataRow row in res.Rows)
- {
- if(complex.IsPrimary(Convert.ToInt32(row["id_entity"])))
- {
- idAtt =3D Convert.ToInt32(row["id_entity"]);
- break; =20
- }
- }
- Logger.Log("getPrimaryAttributeIdForClass (after)",LogLevel.=
Trace);
- return idAtt;
- }
- =20
private string getFilters(string idAttributes, string idOperators, str=
ing valuesToCompare, char separator)
{
string filter =3D"";
|
|
From: <sv...@de...> - 2005-05-26 16:17:16
|
Author: pcamacho
Date: 2005-05-26 12:17:12 -0400 (Thu, 26 May 2005)
New Revision: 1151
Modified:
humano2/trunk/components/webTools/Adapter.cs
humano2/trunk/core/db/absComplex.cs
humano2/trunk/core/db/mssql/mssqlComplex.cs
humano2/trunk/core/db/pgsql/pgsqlComplex.cs
humano2/trunk/core/db/pgsql/pgsqlCrud.cs
humano2/trunk/web/portal/site/addOption.aspx.cs
humano2/trunk/web/portal/site/showView.aspx.cs
humano2/trunk/web/portal/site/topbar.aspx
Log:
FIX: bug #122.
Modified: humano2/trunk/components/webTools/Adapter.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/components/webTools/Adapter.cs 2005-05-26 16:09:36 UTC =
(rev 1150)
+++ humano2/trunk/components/webTools/Adapter.cs 2005-05-26 16:17:12 UTC =
(rev 1151)
@@ -312,64 +312,7 @@
return resp;
=20
} =20
- /* =20
- //Variables para extraer las funciones de coliumnas de tipo "vista"
- string columnValue=3D"";
- =09
-
- DataSet myDataSet=3D new DataSet();
- // Now we read the view via it's viewId, to recover it's values.
- myDataSet =3D ReadDataWithName(viewId, "data");
- Logger.Log(DbUtils.DumpData(myDataSet),LogLevel.Trace);
- //FIXME: there has to be a way to not walk over all elements (three "=
for" loops!)
- //FIXME: Maybe the best way is to use "viewTools" to get the view ele=
ments.
- foreach(DataTable myTable in myDataSet.Tables)
- { // walk over the tables in the DataSet.
- foreach(DataRow myRow in myTable.Rows)
- { // walk over the rows in the tables.
- foreach (DataColumn myColumn in myTable.Columns)
- { // walk over the columns of each row.
- int columnName;
- try { columnName =3D Convert.ToInt32( myRow[myColumn] ); }
- catch(System.InvalidCastException ) { continue; }
- catch(System.FormatException) { continue; }
-
- Logger.Log("columnName: " + columnName,LogLevel.=
Trace);
- switch(columnName) // See if the entites are parts of the view tab=
le taht we need.
- {
- =20
- case (int) ViewConsts.Columns: // If the row contains "columns" pa=
rt of the "view"
- vtInstance["columns"] =3D myRow["data"].ToString();
- break;
- case (int) ViewConsts.Where: // If the row contains "where" part o=
f the "view"
- vtInstance["where"] =3D myRow["data"].ToString();
- break;
- case (int) ViewConsts.GroupBy: // If the row contains "groupby" pa=
rt of the "view".
- vtInstance["groupby"] =3D myRow["data"].ToString();
- break;
- case (int) ViewConsts.Having: // If the row contains "having" part=
of the "view"
- vtInstance["havings"] =3D myRow["data"].ToString();
- break;
- case (int) ViewConsts.Order: // If the row contains "order" part o=
f the "view"
- vtInstance["order"] =3D myRow["data"].ToString();
- break;
-
- case (int) ViewConsts.Class:
- =20
- string info =3D myRow["data"].ToString();
- Logger.Log("info: " + info,LogLevel.Trace);
- =20
- break;
- }
- }
- }
- }
- =09
- vtTable.Rows.Add(vtInstance);
-
- return vtTable;=20
- }
- */
+ =20
=20
///<summary>Execute a View from a DataTable.</summary>
///<param name=3D"vtTable">A datatable with the data relevant to th=
e View.</param>
Modified: humano2/trunk/core/db/absComplex.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/core/db/absComplex.cs 2005-05-26 16:09:36 UTC (rev 1150=
)
+++ humano2/trunk/core/db/absComplex.cs 2005-05-26 16:17:12 UTC (rev 1151=
)
@@ -357,6 +357,12 @@
/// <return>true if attribute is primary</returns>
abstract public bool IsPrimary(string sysAttName);
=20
+ /// <summary>
+ /// Tells if an attribute is primary=20
+ /// </summary>
+ /// <param name=3D"sysAttName">id of attribute </param>
+ /// <return>true if attribute is primary</returns>
+ abstract public bool IsPrimary(int attId);
=20
abstract public bool IsSelfLookUp(string sysAttName);
=20
Modified: humano2/trunk/core/db/mssql/mssqlComplex.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/core/db/mssql/mssqlComplex.cs 2005-05-26 16:09:36 UTC (=
rev 1150)
+++ humano2/trunk/core/db/mssql/mssqlComplex.cs 2005-05-26 16:17:12 UTC (=
rev 1151)
@@ -964,6 +964,33 @@
=20
return isPrimary;
}
+ =20
+ /// <summary>
+ /// Tells if an attribute is primary=20
+ /// </summary>
+ /// <param name=3D"sysAttName">id of attribute </param>
+ /// <return>true if attribute is primary</returns>
+ override public bool IsPrimary(int attId)
+ {
+ string req =3D "select \"isPrimary\" from attribute where \"=
id_entity\" =3D '" + attId + "'";
+ string res =3D "";
+ DataTable dt =3D doSelect(req);
+ try
+ {
+ res =3D Convert.ToString(dt.Rows[0]["isPrimary"]);
+ }
+ catch
+ {
+ //Logger.Log("IsPrimary: problem when executing query fo=
r isPrimary flag ",LogLevel.Trace);
+ }
+ =20
+ //Logger.Log("IsPrimary: res=3D " + res,LogLevel.Trace);
+ bool isPrimary =3D (res =3D=3D "1");
+ =20
+ return isPrimary;
+ }
+ =20
+ =20
=20
override public bool IsSelfLookUp(string sysAttName)
{
Modified: humano2/trunk/core/db/pgsql/pgsqlComplex.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/core/db/pgsql/pgsqlComplex.cs 2005-05-26 16:09:36 UTC (=
rev 1150)
+++ humano2/trunk/core/db/pgsql/pgsqlComplex.cs 2005-05-26 16:17:12 UTC (=
rev 1151)
@@ -409,7 +409,7 @@
while(parentId !=3D 5)
{
oldParentId =3D parentId;
- Logger.Log("GetBasicAttributeSysName: parentId=3D " + pa=
rentId, LogLevel.Trace);
+ //Logger.Log("GetBasicAttributeSysName: parentId=3D " + =
parentId, LogLevel.Trace);
string queryParent =3D "select \"parentId\" from class w=
here id_entity=3D" + parentId;
object resParent =3D conn.doScalar(queryParent);
if(resParent =3D=3D null)
@@ -444,7 +444,7 @@
foreach(string col in args)
{
var =3D col.Split(",".ToCharArray());
- Logger.Log("BuildTempTable: col[" + loop + "]=3D " + col=
,LogLevel.Trace);
+ //Logger.Log("BuildTempTable: col[" + loop + "]=3D " + c=
ol,LogLevel.Trace);
name =3D var[0];
name =3D name.Substring(name.IndexOf(".")+1);
if ((loop > 0) && (name =3D=3D "id_entity"))=20
@@ -452,16 +452,16 @@
name =3D name + loop.ToString();
}
//FIXME: This "AttributeTypeMapping" needs to change to support dyna=
mic derived types in view.
- Logger.Log("BuildTempTable: var[2].ToString()=3D " + var[2].ToString=
(),LogLevel.Trace);
+ //Logger.Log("BuildTempTable: var[2].ToString()=3D " + var[2].ToStri=
ng(),LogLevel.Trace);
type =3D core.Crud.AttributeTypeMapping(var[0].ToString(=
)); //var[0] is of the form "d109cVerifAttribs"."c10007Text1" for example
=
//The data we need is c10007Text1
if (type =3D=3D null)=20
{
- Logger.Log("BuildTempTable: type=3D=3Dnull",LogLevel=
.Trace);
+ //Logger.Log("BuildTempTable: type=3D=3Dnull",LogLev=
el.Trace);
type =3D var[2].ToString(); //FIXME ok but it is a b=
ig patch
}
table.Append(name + " " + type + ",");
- Logger.Log("BuildTempTable. name=3D " + name + ", type=3D=
" + type,LogLevel.Trace);
+ //Logger.Log("BuildTempTable. name=3D " + name + ", typ=
e=3D " + type,LogLevel.Trace);
loop++;
}
table.Append("\"row\" Serial);\n");
@@ -1006,6 +1006,32 @@
=20
return isPrimary;
}
+ =20
+ /// <summary>
+ /// Tells if an attribute is primary=20
+ /// </summary>
+ /// <param name=3D"sysAttName">id of attribute </param>
+ /// <return>true if attribute is primary</returns>
+ override public bool IsPrimary(int attId)
+ {
+ string req =3D "select \"isPrimary\" from attribute where \"=
id_entity\" =3D '" + attId + "'";
+ string res =3D "";
+ DataTable dt =3D doSelect(req);
+ try
+ {
+ res =3D Convert.ToString(dt.Rows[0]["isPrimary"]);
+ }
+ catch
+ {
+ //Logger.Log("IsPrimary: problem when executing query fo=
r isPrimary flag ",LogLevel.Trace);
+ }
+ =20
+ //Logger.Log("IsPrimary: res=3D " + res,LogLevel.Trace);
+ bool isPrimary =3D (res =3D=3D "True");
+ =20
+ return isPrimary;
+ }
+ =20
override public bool IsSelfLookUp(string sysAttName)
{
string req =3D "select \"isSelfLookup\" from attribute where \"sysAtt=
Name\" =3D '" + sysAttName + "'";
Modified: humano2/trunk/core/db/pgsql/pgsqlCrud.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/core/db/pgsql/pgsqlCrud.cs 2005-05-26 16:09:36 UTC (rev=
1150)
+++ humano2/trunk/core/db/pgsql/pgsqlCrud.cs 2005-05-26 16:17:12 UTC (rev=
1151)
@@ -1756,28 +1756,27 @@
=20
absCrud crud =3D Factory.Crud();
absComplex complex =3D crud.GetCore().Complex;
- Logger.Log("finSqlTypeForAttribute: name=3D " + name,LogLeve=
l.Trace);
+ //Logger.Log("finSqlTypeForAttribute: name=3D " + name,LogLe=
vel.Trace);
=20
string [] nameSplit =3D name.Split((".").ToCharArray());
string aux =3D nameSplit[1]; //The before last element of sp=
lit has got the good data (sysName of attribute)
aux =3D aux.Replace("\"",""); //Remove "
- Logger.Log("findSqlTypeForAttribute: aux =3D " + aux, LogLe=
vel.Trace);
+ //Logger.Log("findSqlTypeForAttribute: aux =3D " + aux, Log=
Level.Trace);
=20
int id_entity =3D complex.ConvertSysAttNameToIdAttName(aux);
=20
- =20
string res;
=20
if(id_entity =3D=3D -1)
{
- Logger.Log("findSqlTypeForAttribute: id_entity =3D=3D -1=
",LogLevel.Trace);
+ //Logger.Log("findSqlTypeForAttribute: id_entity =3D=3D =
-1",LogLevel.Trace);
res =3D null;
}
else
{ =20
int classIdOfAttribute =3D complex.getClassIdofInstance(=
id_entity);=20
string basicAttributeSysName =3D complex.GetBasicAttribu=
teSysName(classIdOfAttribute);
- Logger.Log("findSqlTypeForAttribute: basicAttributeSysNa=
me=3D " + basicAttributeSysName,LogLevel.Trace);
+ //Logger.Log("findSqlTypeForAttribute: basicAttributeSys=
Name=3D " + basicAttributeSysName,LogLevel.Trace);
res =3DattMap[basicAttributeSysName];
}
return res;
Modified: humano2/trunk/web/portal/site/addOption.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/addOption.aspx.cs 2005-05-26 16:09:36 U=
TC (rev 1150)
+++ humano2/trunk/web/portal/site/addOption.aspx.cs 2005-05-26 16:17:12 U=
TC (rev 1151)
@@ -8,8 +8,9 @@
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;
-using Humano2.Core;
-using Humano2.Core.Db;
+
+using Humano2.Core;
+using Humano2.Core.Db;
using Humano2.Components.WebTools;
=20
namespace Portal
@@ -20,27 +21,68 @@
public class addOption : System.Web.UI.Page
{
=09
+ private adapter dbAdapter;
+ =20
private void Page_Load(object sender, System.EventArgs e)
{
+ dbAdapter =3D new adapter();
+ =20
string strXml=3D"";=09
int classId=3DConvert.ToInt32(Request.QueryString["classId"]);
=20
-
- adapter dbAdapter =3D new adapter();
+ //adapter dbAdapter =3D new adapter();
DataTable attributeTable =3D dbAdapter.GetAttributesFromClass(classId=
);
=20
strXml =3D"<script>\r\n";
strXml +=3D"function AddattOption(){\r\n";
foreach(DataRow currAtt in attributeTable.Rows)=20
{
- strXml +=3D "parent.AddAtt('" + currAtt["id_entity"] + "','" + currA=
tt["attName"] + "');\r\n";
- }=09
+ int idAtt =3D Convert.ToInt32(currAtt["id_entity"]);
+ if(currAtt["attType"].ToString()!=3D"pertinence")
+ {
+ strXml +=3D "parent.AddAtt('" + idAtt;=20
+ }
+ else
+ {
+ DataTable dtpert =3D dbAdapter.GetClassesFromPertine=
nce(Convert.ToInt32(currAtt["id_entity"]));
+ DataRow dr2 =3D dtpert.Rows[0];
+ int idClassRel =3D Convert.ToInt32(dr2["to"].ToString());
+ =09
+ //For each attribute of pertinence put the id with t=
ogo
+ int relAttId =3D getPrimaryAttributeIdForClass(idCla=
ssRel);
+ strXml +=3D "parent.AddAtt('" + idAtt + "^" + relAtt=
Id;
+ }
+ =20
+ strXml +=3D "','" + currAtt["attName"] + "');\r\n"; //T=
he name of attribute=20
+ }
//AttAdd.Text=3DstrXml;
strXml +=3D"}\r\n";
strXml +=3D"</script>\r\n";
+ Logger.Log("addOption.aspx.cs. strXml=3D " + strXml,LogLevel=
.Trace);
Response.Write(strXml);
}
-
+ =20
+ private int getPrimaryAttributeIdForClass(int classId)
+ {
+ Logger.Log("getPrimaryAttributeIdForClass (before)",LogLevel=
.Trace);
+ absCrud crud =3D Factory.Crud();
+ absComplex complex =3D crud.GetCore().Complex;
+ =20
+ DataTable res =3D dbAdapter.GetAttributesFromClass(classId);
+ int idAtt =3D 0;
+ int i=3D0;
+ foreach(DataRow row in res.Rows)
+ {
+ if(complex.IsPrimary(Convert.ToInt32(row["id_entity"])))
+ {
+ idAtt =3D Convert.ToInt32(row["id_entity"]);
+ break; =20
+ }
+ }
+ Logger.Log("getPrimaryAttributeIdForClass (after)",LogLevel.=
Trace);
+ return idAtt;
+ }
+ =20
#region Web Form Designer generated code
override protected void OnInit(EventArgs e)
{
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-05-26 16:09:36 UT=
C (rev 1150)
+++ humano2/trunk/web/portal/site/showView.aspx.cs 2005-05-26 16:17:12 UT=
C (rev 1151)
@@ -101,13 +101,10 @@
if (isSearch =3D=3D 0)
{
idEntity =3D Convert.ToInt32(Request.QueryString["id_entity"]);
- Logger.Log("idEntity: " + idEntity,LogLevel.Trace);
}
- else
- {
- idEntity =3D iniClass;
- }
+ =09
=20
+ Logger.Log("idEntity: " + idEntity,LogLevel.Trace);
string orderArr =3D Convert.ToString(Request.QueryString["or=
der"]);
=20
int currPage =3D Convert.ToInt32(Request.QueryString["page"]=
);
@@ -117,11 +114,11 @@
}
=20
//Logger.Log("showView createXml: currPage" + currPage, LogL=
evel.Trace);
- if(isSearch =3D=3D 0)
- {
- Logger.Log("Before GetViewDataTableFromId: idEntity " +=
idEntity,LogLevel.Trace);
- viewTable =3D dbAdapter.GetViewDataTableFromId(idEntity, out iniClas=
s);
- }
+ =20
+ if(isSearch =3D=3D 0)
+ {
+ viewTable =3D dbAdapter.GetViewDataTableFromId(idEntity,=
out iniClass);
+ }
else
{
viewTable =3D getStructForSearch(iniClass,idAttributes,idOperators,v=
aluesToSearch);
@@ -130,7 +127,7 @@
// 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);
- Logger.Log("idEntity: " + idEntity,LogLevel.Trace);
+ =20
DataTable viewRes =3D dbAdapter.ExecViewFromDataTable(iniCla=
ss, viewTable, idEntity, orderArr, currPage, 1);
=20
int pageCount=3D dbAdapter.NumberOfPagesInPagedView;
@@ -212,7 +209,7 @@
//Logger.Log("search: list of attributes =3D " + dr["columna"],LogLev=
el.Trace);
=20
//Explicacion de los filtros...
- char separator =3D '^';
+ char separator =3D '$';
dr["filtros"] =3D getFilters(idAttributes,idOperators,valuesToSearch,=
separator);
Logger.Log("search: filtros =3D " + dr["filtros"],LogLevel.Trace);
=20
@@ -223,18 +220,59 @@
=20
private string getAttributeListForClass(int classId)
{
- string columnsList =3D "0,";
+ absCrud crud =3D Factory.Crud();
+ absComplex complex =3D crud.GetCore().Complex;
+ =20
+ string columnsList =3D "0,";
DataTable res =3D userCred.CoreAdapter.GetAttributesFromClass(classId=
);
=20
foreach(DataRow row in res.Rows)
{
- columnsList +=3D row["id_entity"] + ","; =20
+ int idAtt =3D Convert.ToInt32(row["id_entity"]);
+ =09
+ if(row["attType"].ToString()!=3D"pertinence")
+ {
+ columnsList +=3D idAtt; =20
+ }
+ else
+ {
+ DataTable dtpert =3D userCred.CoreAdapter.GetClasses=
FromPertinence(idAtt);
+ DataRow dr2 =3D dtpert.Rows[0];
+ int idClassRel =3D Convert.ToInt32(dr2["to"].ToString());
+ //For each attribute of pertinence put the id with t=
ogo
+ int relAttId =3D getPrimaryAttributeIdForClass(idCla=
ssRel);
+ columnsList +=3D idAtt + "^" + relAttId;
+ }
+ columnsList +=3D ",";
}
=20
columnsList =3D columnsList.Substring(0,columnsList.Length-1); //Remo=
ve last ","
=20
return columnsList;
}
+ =20
+ =20
+ private int getPrimaryAttributeIdForClass(int classId)
+ {
+ Logger.Log("getPrimaryAttributeIdForClass (before)",LogLevel=
.Trace);
+ absCrud crud =3D Factory.Crud();
+ absComplex complex =3D crud.GetCore().Complex;
+ =20
+ DataTable res =3D userCred.CoreAdapter.GetAttributesFromClas=
s(classId);
+ int idAtt =3D 0;
+ int i=3D0;
+ foreach(DataRow row in res.Rows)
+ {
+ if(complex.IsPrimary(Convert.ToInt32(row["id_entity"])))
+ {
+ idAtt =3D Convert.ToInt32(row["id_entity"]);
+ break; =20
+ }
+ }
+ Logger.Log("getPrimaryAttributeIdForClass (after)",LogLevel.=
Trace);
+ return idAtt;
+ }
+ =20
private string getFilters(string idAttributes, string idOperators, str=
ing valuesToCompare, char separator)
{
string filter =3D"";
Modified: humano2/trunk/web/portal/site/topbar.aspx
=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/topbar.aspx 2005-05-26 16:09:36 UTC (re=
v 1150)
+++ humano2/trunk/web/portal/site/topbar.aspx 2005-05-26 16:17:12 UTC (re=
v 1151)
@@ -1,89 +1,87 @@
<%@ Page language=3D"c#" Codebehind=3D"topbar.aspx.cs" AutoEventWireup=3D=
"false" Inherits=3D"Portal.site.topbar" %>
<html>
- <head>
- <title>topbar</title>
- <link href=3D"css/default.css" rel=3D"stylesheet" type=3D=
"text/css">
- <link href=3D"css/top.css" rel=3D"stylesheet" type=3D"te=
xt/css">
- <script language=3D"javascript">
- function salir()
- {
- top.document.location.href=3D"login.aspx=
";
- }
- =20
- function showType()
- {
- //var baseUrl =3D "instance.aspx?display=
=3DcreateXslt.aspx&action=3Dcreate&id_entity=3D";
- var baseUrl =3D "Data_structured.aspx?di=
splay=3DcreateXslt.aspx&action=3Dcreate&id_entity=3D";
- var dropdowner =3D document.Form1.create=
Type;
- var classId =3D dropdowner.options[dropd=
owner.selectedIndex].value;
- if(classId =3D=3D -1)=20
- {
- return;
- }
- var mainUrl =3D baseUrl + classId;
- parent.mainFrame.location =3D mainUrl;
- dropdowner.selectedIndex=3D0
- }
- =20
- function ChargeAtt(obj){
- var obj2 =3D document.Form1.ddl4
- for (var i =3D obj2.length - 1 ; i >=3D 0 ; i--)=20
- {
- obj2.options[i] =3D null;
- }
- if(obj.value!=3D'' && obj.value!=3D'0'){
- //document.frames['FrameTempLoad'].location.href=3D'Add_object_ba=
rra_left.aspx?TypeEntity=3D'+obj.value+'&&accion=3D1'
- document.getElementById('FrameTempLoad').src=3D'addOption.aspx?cl=
assId=3D'+obj.value
- } =20
- } =20
- =20
- function AddAtt(value,text){
- var obj =3D document.Form1.ddl4
- var nopcion =3D new Option(); =09
- nopcion.text =3D text;
- nopcion.value =3D value;
- obj[obj.length] =3D nopcion;
- } =20
-
-
- function EntitySearch()
- {
- if (document.Form1.strSearchedText.value=3D=3D'')
- {
- alert("Insert a text to search.");
- return false;
- }
-
- if (document.Form1.intEntityType.selectedIndex=3D=3D0)
- {
- alert("Select a class for search.");
- return false;
- } =09
- =09
- //window.parent.frames["mainFrame"].location.href=3D"search.aspx=
?iniClass=3D"+document.Form1.intEntityType[document.Form1.intEntityType.s=
electedIndex].value+"&idAttribute=3D"+document.Form1.ddl4[document.Form1.=
ddl4.selectedIndex].value+"&idOperator=3D7&textToSearch=3D"+document.Form=
1.strSearchedText.value
- window.parent.frames["mainFrame"].location.href=3D"Data_structur=
ed.aspx?iniClass=3D"+document.Form1.intEntityType[document.Form1.intEntit=
yType.selectedIndex].value+"&idAttribute=3D"+document.Form1.ddl4[document=
.Form1.ddl4.selectedIndex].value+"&idOperator=3D7&textToSearch=3D"+docume=
nt.Form1.strSearchedText.value
- =09
- }=09
- =09
- =20
- </script>
- <link href=3D"css/styles_home.css" rel=3D"stylesheet" ty=
pe=3D"text/css"/>
- </head>
- <body bgcolor=3D"#bfd2ea">
- <form method=3D"post" onsubmit=3D"return EntitySearch()"=
name=3D"Form1" id=3D"Form1">
- <div id=3D"createType">
- <!--Here we create the real content of t=
he page via xsl -->
- <% getContent("xsl/topbar.xsl"); %>
- <%=20
- //Response.Write (createXml());=20
- //Response.End();
- %>
- <br/>
- </div>
- <div id=3D"logout">
- <!-- Don't delete this button (asp call)=
-->
- </div>
- <iframe id=3D"FrameTempLoad" name=3D"FrameTempLo=
ad" frameborder=3D"0" width=3D"1" height=3D"1" ></iframe>
- </form>
- </body>
+ <head>
+ <title>topbar</title>
+ <link href=3D"css/default.css" rel=3D"stylesheet" type=3D"text/c=
ss">
+ <link href=3D"css/top.css" rel=3D"stylesheet" type=3D"text/css">
+ <script language=3D"javascript">
+ function salir()
+ {
+ top.document.location.href=3D"login.aspx";
+ }
+ =20
+ function showType()
+ {
+ //var baseUrl =3D "instance.aspx?display=3DcreateXslt.as=
px&action=3Dcreate&id_entity=3D";
+ var baseUrl =3D "Data_structured.aspx?display=3DcreateXs=
lt.aspx&action=3Dcreate&id_entity=3D";
+ var dropdowner =3D document.Form1.createType;
+ var classId =3D dropdowner.options[dropdowner.selectedIn=
dex].value;
+ if(classId =3D=3D -1)=20
+ {
+ return;
+ }
+ var mainUrl =3D baseUrl + classId;
+ parent.mainFrame.location =3D mainUrl;
+ dropdowner.selectedIndex=3D0
+ }
+ =20
+ function ChargeAtt(obj)
+ {
+ var obj2 =3D document.Form1.ddl4
+ for (var i =3D obj2.length - 1 ; i >=3D 0 ; i--)=20
+ {
+ obj2.options[i] =3D null;
+ }
+ if(obj.value!=3D'' && obj.value!=3D'0')
+ {
+ //document.frames['FrameTempLoad'].location.href=3D'=
Add_object_barra_left.aspx?TypeEntity=3D'+obj.value+'&&accion=3D1'
+ document.getElementById('FrameTempLoad').src=3D'addO=
ption.aspx?classId=3D'+obj.value
+ } =20
+ } =20
+ =20
+ function AddAtt(value,text)
+ {
+ var obj =3D document.Form1.ddl4
+ var nopcion =3D new Option(); =09
+ nopcion.text =3D text;
+ nopcion.value =3D value;
+ obj[obj.length] =3D nopcion;
+ } =20
+ =20
+ =20
+ function EntitySearch()
+ {
+ if (document.Form1.strSearchedText.value=3D=3D'')
+ {
+ alert("Insert a text to search.");
+ return false;
+ }
+ if (document.Form1.intEntityType.selectedIndex=3D=3D0)
+ {
+ alert("Select a class for search.");
+ return false;
+ } =09
+ //window.parent.frames["mainFrame"].location.href=3D"sea=
rch.aspx?iniClass=3D"+document.Form1.intEntityType[document.Form1.intEnti=
tyType.selectedIndex].value+"&idAttribute=3D"+document.Form1.ddl4[documen=
t.Form1.ddl4.selectedIndex].value+"&idOperator=3D7&textToSearch=3D"+docum=
ent.Form1.strSearchedText.value
+ window.parent.frames["mainFrame"].location.href=3D"Data_=
structured.aspx?iniClass=3D"+document.Form1.intEntityType[document.Form1.=
intEntityType.selectedIndex].value+"&idAttribute=3D"+document.Form1.ddl4[=
document.Form1.ddl4.selectedIndex].value+"&idOperator=3D7&textToSearch=3D=
"+document.Form1.strSearchedText.value =09
+ }=09
+ </script>
+ <link href=3D"css/styles_home.css" rel=3D"stylesheet" type=3D"te=
xt/css"/>
+ </head>
+ <body bgcolor=3D"#bfd2ea">
+ <form method=3D"post" onsubmit=3D"return EntitySearch()" name=3D"For=
m1" id=3D"Form1">
+ <div id=3D"createType">
+ <!--Here we create the real content of the page via xsl -->
+ <% getContent("xsl/topbar.xsl"); %>
+ <%=20
+ //Response.Write (createXml());=20
+ //Response.End();
+ %>
+ <br/>
+ </div>
+ <div id=3D"logout">
+ <!-- Don't delete this button (asp call) -->
+ </div>
+ <iframe id=3D"FrameTempLoad" name=3D"FrameTempLoad" frameborder=3D"0=
" width=3D"1" height=3D"1" ></iframe>
+ </form>
+ </body>
</html>
|
|
From: <sv...@de...> - 2005-05-26 16:09:47
|
Author: marijn Date: 2005-05-26 12:09:36 -0400 (Thu, 26 May 2005) New Revision: 1150 Modified: humano2/trunk/core/config.cs Log: * Marking trunk as Beta3 Modified: humano2/trunk/core/config.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/core/config.cs 2005-05-25 21:16:05 UTC (rev 1149) +++ humano2/trunk/core/config.cs 2005-05-26 16:09:36 UTC (rev 1150) @@ -26,7 +26,7 @@ // The Version of the Humano2 core code const int major =3D 5; const int minor =3D 0; - const string patch =3D "beta2"; + const string patch =3D "beta3"; =09 // Contains the instance, once instanced. private static Config instance =3D null; |