<XMI.documentation>
<XMI.exporter>umbrello uml modeller http://uml.sf.net</XMI.exporter>
<XMI.exporterVersion>1.1.5</XMI.exporterVersion>
+ <XMI.exporterEncoding>UnicodeUTF8</XMI.exporterEncoding>
</XMI.documentation>
- <XMI.model xmi.name="Samurai" href="/home/luca/public_html/samurai/doc/uml/Samurai.xmi" />
+ <XMI.model xmi.name="Samurai" href="/home/martin/public_html/samurai/doc/uml/Samurai.xmi" />
<XMI.metamodel xmi.name="UML" href="UML.xml" xmi.version="1.3" />
</XMI.header>
<XMI.content>
- <docsettings viewid="336" documentation="" uniqueid="386" />
+ <docsettings viewid="336" documentation="" uniqueid="387" />
<umlobjects>
<UML:Class stereotype="" package="" xmi.id="207" abstract="0" documentation="Clase para el manejo de los usuarios." name="SAMURAI_Usuario" static="0" scope="200" >
<UML:Operation stereotype="" package="" xmi.id="216" type="void" abstract="0" documentation="Constructor.Recibe como parametro opcional el login del usuario. y busca en la base la informacion referida a el." name="SAMURAI_Usuario" static="0" scope="200" >
</UML:Operation>
<UML:Operation stereotype="" package="" xmi.id="381" type="bool" abstract="0" documentation="Verifica si tiene un permiso.
-Se puede pasar parámetros variables con un identificador de permiso o un array, por ejemplo: $perm->tiene(1, 4, array(2, 5, 67), 12); Si tiene algún permiso devuelve true.
-Si no se pasa ningún párametro ($perm->tiene()), devuelve true si tiene un permiso (al menos uno) en el sistema actual." name="tiene" static="0" scope="200" />
+Se puede pasar parámetros variables con un identificador de permiso o un array, por ejemplo: $perm->tiene(1, 4, array(2, 5, 67), 12); Si tiene algún permiso devuelve true.
+Si no se pasa ningún párametro ($perm->tiene()), devuelve true si tiene un permiso (al menos uno) en el sistema actual." name="tiene" static="0" scope="200" />
<UML:Operation stereotype="" package="" xmi.id="385" type="array" abstract="0" documentation="Obtiene una lista de permisos. Si se especifica un sistema, obtiene la lista de permisos para ese sistema." name="getPermisos" static="0" scope="200" >
<UML:Parameter stereotype="" package="" xmi.id="1" value="''" type="int" abstract="0" documentation="Sistema del cual obtener la lista de permisos." name="sistema" static="0" scope="200" />
</UML:Operation>
<UML:Association nameb="" stereotype="" visibilitya="200" visibilityb="200" assoctype="500" rolea="265" roleb="264" multia="" doca="" multib="" docb="" package="" xmi.id="-1" abstract="0" documentation="" name="" static="0" scope="200" changeabilitya="900" changeabilityb="900" namea="" />
</umlobjects>
<diagrams>
- <diagram snapgrid="1" showattsig="1" fillcolor="#ffffc0" zoom="100" showgrid="1" showopsig="1" usefillcolor="1" snapx="10" canvaswidth="911" snapy="10" showatts="1" xmi.id="206" documentation="" type="402" showops="1" showpackage="0" name="Clases y Relaciones" localid="30000" showstereotype="0" showscope="1" snapcsgrid="0" font="helvetica,8,-1,0,50,0,0,0,0,0" linecolor="#ff0000" canvasheight="648" >
+ <diagram snapgrid="1" showattsig="1" fillcolor="#ffffc0" zoom="100" showgrid="1" showopsig="1" usefillcolor="1" snapx="10" canvaswidth="911" snapy="10" showatts="1" xmi.id="206" documentation="" type="402" showops="1" showpackage="0" name="Clases y Relaciones" localid="30000" showstereotype="0" showscope="1" snapcsgrid="0" font="helvetica,8,-1,0,50,0,0,0,0,0" linecolor="#ff0000" canvasheight="644" >
<widgets>
- <UML:ClassWidget usesdiagramfillcolour="0" width="157" showattsigs="601" usesdiagramusefillcolour="0" x="750" linecolour="#ff0000" y="290" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="234" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="207" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="111" showattsigs="601" usesdiagramusefillcolour="0" x="640" linecolour="#ff0000" y="10" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="273" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="208" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="149" showattsigs="601" usesdiagramusefillcolour="0" x="200" linecolour="#ff0000" y="10" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="585" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="209" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="118" showattsigs="601" usesdiagramusefillcolour="0" x="480" linecolour="#ff0000" y="310" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="195" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="210" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="35" showattsigs="601" usesdiagramusefillcolour="0" x="490" linecolour="#ff0000" y="10" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#d5d5cf" height="25" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="264" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="79" showattsigs="601" usesdiagramusefillcolour="0" x="480" linecolour="#ff0000" y="120" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="32" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="265" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="157" showattsigs="601" usesdiagramusefillcolour="0" x="750" linecolour="#ff0000" y="290" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="252" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="207" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="110" showattsigs="601" usesdiagramusefillcolour="0" x="640" linecolour="#ff0000" y="10" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="294" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="208" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="149" showattsigs="601" usesdiagramusefillcolour="0" x="200" linecolour="#ff0000" y="10" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="630" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="209" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="118" showattsigs="601" usesdiagramusefillcolour="0" x="480" linecolour="#ff0000" y="310" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="210" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="210" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="35" showattsigs="601" usesdiagramusefillcolour="0" x="490" linecolour="#ff0000" y="10" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#d5d5cf" height="28" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="264" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="79" showattsigs="601" usesdiagramusefillcolour="0" x="480" linecolour="#ff0000" y="120" showopsigs="600" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="35" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="265" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
</widgets>
<messages/>
<associations>
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="712" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<linepath>
<startpoint startx="506" starty="120" />
- <endpoint endx="507" endy="35" />
+ <endpoint endx="507" endy="38" />
</linepath>
</UML:AssocWidget>
<UML:AssocWidget totalcounta="3" indexa="1" visibilityB="200" totalcountb="2" indexb="1" widgetbid="210" roleBdoc="" widgetaid="265" roleAdoc="" documentation="" type="501" changeabilityA="900" changeabilityB="900" visibilityA="200" >
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="711" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="712" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<linepath>
- <startpoint startx="506" starty="152" />
+ <startpoint startx="506" starty="155" />
<endpoint endx="539" endy="310" />
</linepath>
</UML:AssocWidget>
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="711" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="712" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<linepath>
- <startpoint startx="480" starty="136" />
- <endpoint endx="349" endy="302" />
+ <startpoint startx="480" starty="137" />
+ <endpoint endx="349" endy="325" />
</linepath>
</UML:AssocWidget>
<UML:AssocWidget totalcounta="3" indexa="2" visibilityB="200" totalcountb="2" indexb="1" widgetbid="208" roleBdoc="" widgetaid="265" roleAdoc="" documentation="" type="501" changeabilityA="900" changeabilityB="900" visibilityA="200" >
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="712" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<linepath>
<startpoint startx="532" starty="120" />
- <endpoint endx="640" endy="146" />
+ <endpoint endx="640" endy="157" />
</linepath>
</UML:AssocWidget>
<UML:AssocWidget totalcounta="3" indexa="2" visibilityB="200" totalcountb="2" indexb="1" widgetbid="207" roleBdoc="" widgetaid="265" roleAdoc="" documentation="" type="501" changeabilityA="900" changeabilityB="900" visibilityA="200" >
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="711" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="10" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="712" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<linepath>
- <startpoint startx="532" starty="152" />
- <endpoint endx="750" endy="407" />
+ <startpoint startx="532" starty="155" />
+ <endpoint endx="750" endy="416" />
</linepath>
</UML:AssocWidget>
</associations>
</diagram>
- <diagram snapgrid="1" showattsig="1" fillcolor="#ffffc0" zoom="100" showgrid="1" showopsig="1" usefillcolor="1" snapx="10" canvaswidth="902" snapy="10" showatts="1" xmi.id="336" documentation="" type="402" showops="1" showpackage="0" name="Clases" localid="30000" showstereotype="0" showscope="1" snapcsgrid="0" font="helvetica,8,-1,0,50,0,0,0,0,0" linecolor="#ff0000" canvasheight="1129" >
+ <diagram snapgrid="1" showattsig="1" fillcolor="#ffffc0" zoom="100" showgrid="1" showopsig="1" usefillcolor="1" snapx="10" canvaswidth="902" snapy="10" showatts="1" xmi.id="336" documentation="" type="402" showops="1" showpackage="0" name="Clases" localid="30000" showstereotype="0" showscope="1" snapcsgrid="0" font="helvetica,8,-1,0,50,0,0,0,0,0" linecolor="#ff0000" canvasheight="1174" >
<widgets>
- <UML:ClassWidget usesdiagramfillcolour="0" width="35" showattsigs="601" usesdiagramusefillcolour="0" x="470" linecolour="#ff0000" y="20" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#d5d5cf" height="25" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="264" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="430" showattsigs="601" usesdiagramusefillcolour="0" x="10" linecolour="#ff0000" y="240" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="273" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="208" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="361" showattsigs="601" usesdiagramusefillcolour="0" x="10" linecolour="#ff0000" y="10" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="195" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="210" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="88" showattsigs="601" usesdiagramusefillcolour="0" x="450" linecolour="#ff0000" y="80" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="32" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="265" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="431" showattsigs="601" usesdiagramusefillcolour="0" x="10" linecolour="#ff0000" y="540" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="585" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="209" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="448" showattsigs="601" usesdiagramusefillcolour="0" x="450" linecolour="#ff0000" y="130" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="234" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="207" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
- <UML:ClassWidget usesdiagramfillcolour="0" width="288" showattsigs="601" usesdiagramusefillcolour="0" x="450" linecolour="#ff0000" y="370" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="78" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="377" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="35" showattsigs="601" usesdiagramusefillcolour="0" x="470" linecolour="#ff0000" y="20" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#d5d5cf" height="28" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="264" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="429" showattsigs="601" usesdiagramusefillcolour="0" x="10" linecolour="#ff0000" y="240" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="294" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="208" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="360" showattsigs="601" usesdiagramusefillcolour="0" x="10" linecolour="#ff0000" y="10" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="210" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="210" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="88" showattsigs="601" usesdiagramusefillcolour="0" x="450" linecolour="#ff0000" y="80" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="35" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="265" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="431" showattsigs="601" usesdiagramusefillcolour="0" x="10" linecolour="#ff0000" y="540" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="630" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="209" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="448" showattsigs="601" usesdiagramusefillcolour="0" x="450" linecolour="#ff0000" y="230" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="252" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="207" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
+ <UML:ClassWidget usesdiagramfillcolour="0" width="288" showattsigs="601" usesdiagramusefillcolour="0" x="450" linecolour="#ff0000" y="130" showopsigs="601" instancename="" usesdiagramlinecolour="0" fillcolour="#ffffc0" height="84" usefillcolor="1" showattributes="1" isinstance="0" xmi.id="377" showoperations="1" showpackage="0" showscope="1" showstereotype="0" font="helvetica,8,-1,0,50,0,0,0,0,0" />
</widgets>
<messages/>
<associations>
<UML:FloatingTextWidget usesdiagramfillcolour="1" width="0" usesdiagramusefillcolour="1" x="0" linecolour="none" y="0" operation="" instancename="" posttext="" usesdiagramlinecolour="1" role="712" fillcolour="none" height="0" usefillcolor="1" seqnum="" pretext="" isinstance="0" xmi.id="-1" text="" font="helvetica,12,-1,5,50,0,0,0,0,0" />
<linepath>
<startpoint startx="494" starty="80" />
- <endpoint endx="487" endy="45" />
+ <endpoint endx="487" endy="48" />
</linepath>
</UML:AssocWidget>
</associations>
</diagram>
</diagrams>
<listview>
- <listitem open="1" type="800" id="-1" label="Vistas" >
- <listitem open="1" type="801" id="-1" label="Vista lógica" >
+ <listitem open="1" type="800" id="-1" label="Views" >
+ <listitem open="1" type="801" id="-1" label="Logical View" >
<listitem open="1" type="803" id="-1" label="Diagramas" >
<listitem open="1" type="807" id="336" label="Clases" />
<listitem open="1" type="807" id="206" label="Clases y Relaciones" />
</listitem>
</listitem>
</listitem>
- <listitem open="0" type="802" id="-1" label="Vista de caso de uso" />
+ <listitem open="0" type="802" id="-1" label="Use Case View" />
<listitem open="1" type="821" id="-1" label="Component View" />
<listitem open="0" type="823" id="-1" label="Diagrams" />
<listitem open="1" type="827" id="-1" label="Deployment View" />
require_once 'PEAR.php';
require_once 'Perfil.php';
+require_once 'MECON/Usuario.php';
// +X2C Class 207 :SAMURAI_Usuario
$this->_db = $db;
$this->setLogin($login);
if (!is_null($login)) {
+ $tmp =& new MECON_Usuario(null, $login);
+ $this->setNrodoc($tmp->getDni());
+ $this->setNombre($tmp->getNombre());
$this->_obtenerDatosDb();
}
}
//FORECHEO LO QUE ME DEVUELVA GET USUARIOS
$rta = array ();
foreach (SAMURAI_Usuario::getUsuarios($db, $id_sistema) as $Usuario) {
- $rta[$permiso->getLogin()] = $permiso->getNombre();
+ $rta[$Usuario->getLogin()] = $Usuario->getNombre();
}
return $rta;
}
function _obtenerDatosDb() // ~X2C
{
$sql = parse_ini_file(dirname(__FILE__) . '/Usuario/consultas.ini', true);
- $tmp = $sql['obtener_datos_usuario'].$sql['obtener_datos_usuario3'];
- $dbh = $this->_db->prepare($tmp);
- $res = $this->_db->execute($dbh,array($this->getLogin()));
-
- if ($re = $res->fetchRow(DB_FETCHMODE_ASSOC)) {
- if (isset($re['nrodoc'])) {
- $this->setNrodoc($re['nrodoc']);
- }
- else {
- $this->setNrodoc();
- }
- if (isset($re['nombre'])) {
- $this->setNombre($re['nombre']);
- }
- else {
- $this->setNombre();
- }
- }
+
$tmp = $sql['obtener_perfiles_usuario'];
$dbh = $this->_db->prepare($tmp);
$res = $this->_db->execute($dbh,array($this->getLogin(), $_SESSION['samurai']['id_sistema']));
$rta = array();
+
while ($re = $res->fetchRow(DB_FETCHMODE_ASSOC)) {
$tmp = new SAMURAI_Perfil($this->_db, $re['id_perfil']);
$rta[] = $tmp->getId();
*/
function verificarLogin() // ~X2C
{
- $sql = parse_ini_file(dirname(__FILE__) . '/Usuario/consultas.ini', true);
- $tmp = $sql['verificar_login'];
- $dbh = $this->_db->prepare($tmp);
- $res = $this->_db->execute($dbh,array($this->getLogin()));
- $re = $res->fetchRow(DB_FETCHMODE_ASSOC);
- if ($re['cuenta'] == 0) {
+ $usu = new MECON_Usuario();
+ $tmp = $usu->verificarLogin($this->getLogin());
+ if ($tmp) {
+ if (PEAR::isError($tmp)) {
+ return $tmp;
+ }
+ else {
+ return true;
+ }
+ }
+ else {
return new PEAR_Error('Usuario no reconocido.<br>Recuerde que éste debe haberse logueado previamente a Intranet');
}
- return 1;
}
// -X2C
function asociarPerfil(&$db, $login, $id_perfil, $id_sistema, $responsable) // ~X2C
{
$sql = parse_ini_file(dirname(__FILE__) . '/Usuario/consultas.ini', true);
-
- //Verifico que el usuario exista
- $tmp = $sql['verificar_login'];
- $dbh = $db->prepare($tmp);
- $res = $db->execute($dbh,array($login));
- $re = $res->fetchRow(DB_FETCHMODE_ASSOC);
- if ($re['cuenta'] == 0) {
- return new PEAR_Error('Usuario no reconocido.');
- }
+ $usu = new MECON_Usuario();
+ $tmp = $usu->verificarLogin($login());
+ if ($tmp) {
+ if (PEAR::isError($tmp)) {
+ return $tmp;
+ }
+ else {
+ return true;
+ }
+ }
+ else {
+ return new PEAR_Error('Usuario no reconocido.<br>Recuerde que éste debe haberse logueado previamente a Intranet');
+ }
+
//Asocio el perfil con el usuario en perfil_sist_usuario
$datos = array ('login' => $login,
'id_perfil' => $id_perfil,
// -X2C
} // -X2C Class :SAMURAI_Usuario
-?>
\ No newline at end of file
+?>