/**
  * Muestra una Ficha de Informacion del Socio
  *
  * @param string $domicilio_extendido
  * @param string $trTool
  * @param string $marco
  * @return string
  */
 function getFicha($domicilio_extendido = false, $marco = true, $trTool = "")
 {
     $eldom = "";
     $idpersona = $this->mCodigo;
     $ccache = $domicilio_extendido == true ? EACP_CLAVE . ".ficha.{$idpersona}.ext" : EACP_CLAVE . ".ficha.{$idpersona}";
     $this->mIDEnCache = $ccache;
     $xCache = new cCache();
     $exoFicha = null;
     if ($xCache->isReady() == true) {
         $exoFicha = $xCache->get($ccache);
     }
     if ($exoFicha == null) {
         $DSocio = $this->getDatosInArray();
         $DIngreso = $this->getDatosDeIngreso_InArray();
         $empresa = $this->getClaveDeEmpresa();
         $tingreso = $DIngreso["descripcion_tipoingreso"];
         $xLng = new cLang();
         $xT = new cTipos();
         $xT->setForceMayus();
         $xT->setToUTF8();
         $mdom = $this->getDomicilio(99);
         $elnombre = $this->getNombreCompleto();
         // $DSocio["apellidopaterno"] . " " . $DSocio["apellidomaterno"] . " " . $DSocio["nombrecompleto"];
         if ($domicilio_extendido == false) {
             $eldom = strlen(trim($mdom)) < 6 ? "" : "<tr><th class='izq'>" . $xLng->getT("TR.Domicilio") . "</th><td colspan='3'>" . htmlentities($xT->cChar($mdom)) . "</td></tr>";
         } else {
             if ($this->getODomicilio() != null) {
                 $eldom = "<tr><td colspan='4'>" . $this->getODomicilio()->getFicha($this->getTelefonoPrincipal()) . "</td></tr>";
             }
         }
         $rfc = $this->getRFC();
         $curp = $this->getCURP();
         $tool = $trTool;
         $wTable = "";
         $tdExtra = "";
         $tdCurp = "<th class='izq'>" . $xLng->getT("TR.CURP") . "</th><td>{$curp}</td>";
         if ($this->getEsPersonaFisica() == false) {
             $tdCurp = "";
             //OBTENER REPRESENTANTE LEGAL
             //22Octubre2013
             $xRels = $this->getORepresentanteLegal();
             if ($xRels != null) {
                 $tdCurp = "<th class='izq'>" . $xRels->getNombreRelacion() . "</th><td>" . $xRels->getCodigoDePersona() . "-" . $xRels->getNombreDelRelacionado() . "</td>";
             }
         }
         if ($this->mGrupoAsociado != DEFAULT_GRUPO) {
             $dG = new cGrupo($this->mGrupoAsociado);
             $grupo = $dG->getNombre();
             $tdExtra .= "<tr><th class='izq'>" . $xLng->getT("TR.Grupo Solidario") . "</th><td colspan='3'>{$grupo}</td></tr>";
         }
         if ($empresa != DEFAULT_EMPRESA) {
             $xEmp = new cEmpresas($empresa);
             $xEmp->init();
             $Nempresa = cleanString($xEmp->getNombre());
             $tdExtra .= "<tr><th class='izq'>" . $xLng->getT("TR.Empresa") . "</th><td colspan='3'>{$Nempresa}</td></tr>";
         }
         if (getEsModuloMostrado(USUARIO_TIPO_OFICIAL_AML) == true) {
             $xDPais = new cDomiciliosPaises($this->getPaisDeOrigen());
             $xDPais->init();
             $NPais = $xDPais->getNombre();
             $xRiesgo = new cAml_risk_levels();
             $xRiesgo->setData($xRiesgo->query()->initByID($this->getNivelDeRiesgo()));
             $tdExtra .= "<tr><th class='izq'>" . $xLng->getT("TR.Riesgo de Persona") . "</th><td>" . strtoupper($xRiesgo->nombre_del_nivel()->v()) . "</td>\n\t\t\t\t\t\t<th class='izq'>" . $xLng->getT("TR.pais") . "</th><td colspan='3'>{$NPais}</td></tr>";
         }
         $exoFicha = "\n\t\t\t<table {$wTable} >\n\t\t\t<tbody>\n\t\t\t\t<tr>\n\t\t\t\t\t<th class='izq'>" . $xLng->getT("TR.Codigo") . "</th>\n\t\t\t\t\t<th>" . $this->mCodigo . "</th>\n\t\t\t\t\t<th class='izq'>" . $xLng->getT("TR.Nombre_completo") . "</th>\n\t\t\t\t\t<td>{$elnombre}</td>\n\t\t\t\t</tr>\n\t\t\t\t{$eldom}\n\t\t\t\t<tr>\n\t\t\t\t\t<th class='izq'>" . $xLng->getT("TR.RFC") . "</th>\n\t\t\t\t\t<td>{$rfc}</td>\n\t\t\t\t\t{$tdCurp}\n\t\t\t\t</tr>\n\t\t\t\t{$tdExtra}\n\t\t\t</tbody>\n\t\t\t<tfoot>{$tool}</tfoot>\n\t\t\t</table>";
         if ($marco == true) {
             $exoFicha = "<fieldset><legend>|&nbsp;&nbsp;" . $xLng->getT("TR.Ficha de Informacion") . "&nbsp;&nbsp;|</legend>\n\t\t\t\t\t\t{$exoFicha}\n\t\t\t\t\t\t</fieldset>";
         }
         if ($xCache->isReady() == true) {
             $xCache->set($ccache, $exoFicha);
         }
     }
     return $exoFicha;
 }