/**
  * 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;
 }
 $mems = $xSoc->getEsPersonaFisica() == true ? $xB->getMembers_InArray(false, BASE_DOCTOS_PERSONAS_FISICAS) : $xB->getMembers_InArray(false, BASE_DOCTOS_PERSONAS_MORALES);
 $rsDocs = $ql->getDataRecord($xql->getListadoDePersonasDoctos($idsocio));
 $xTbl = new cHTabla();
 foreach ($rsDocs as $rows) {
     $iddocto = $rows["archivo_de_documento"];
     $fecha = $xF->getFechaByInt($rows["fecha_de_carga"]);
     $xTbl->initRow();
     $xTbl->addTD($rows["tipo"]);
     $xTbl->addTD($xF->getFechaCorta($fecha));
     $xTbl->addTD($xBtn->getBasic($rows["archivo_de_documento"], "var xPers = new PersGen();xPers.getDocumento({persona:{$idsocio}, docto: '" . $rows["archivo_de_documento"] . "'});", $oFrm->ic()->TIPO));
     $xTbl->addTD($rows["observaciones"]);
     $xTbl->endRow();
 }
 $xHTabs->addTab("TR.DOCUMENTOS", $xTbl->get());
 //tabs
 if (getEsModuloMostrado(USUARIO_TIPO_OFICIAL_AML) == true) {
     $xDiv3 = new cHDiv("tx1", "msgcumplimiento");
     $oFrm->addToolbar($xBtn->getBasic("TR.validar documentos", "jsaValidarDocumentacion()", "documentos", "idvalidadoc", false));
     $oFrm->addToolbar($xBtn->getBasic("TR.validar perfil_transaccional", "jsaValidarPerfilT()", "perfil", "validaperfil", false));
     $oFrm->addToolbar($xBtn->getBasic("TR.validar riesgo", "jsaValidarRiesgo()", "riesgo", "validariesgo", false));
     $oFrm->addToolbar($xBtn->getBasic("TR.Actualizar Nivel de Riesgo", "jsActualizarNivelDeRiesgo({$idsocio})", "riesgo", "actualizarriesgo", false));
     $oFrm->OButton("TR.ARBOL_DE_RELACIONES", "jsSigmaRelaciones()", $oFrm->ic()->EXPORTAR);
     $oFrm->OButton("TR.Consulta en LISTA_NEGRA", "var xAML = new AmlGen(); xAML.getConsultaListaNegra({$idsocio})", $oFrm->ic()->REGISTROS);
     $xHTabs->addTab("TR.cumplimiento", $xDiv3->get());
     //tab6
     $jsTabs .= ",\n selected: 6\n";
     $xT = new cTabla($xql->getListadoDePerfil($idsocio));
     $xT->addTool(SYS_DOS);
     $xHTabs->addTab("TR.perfil_transaccional", $xT->Show());
     //tab6
 }
 $xTabs->addTab("TR.OPERACIONES", $cEdit->Show());
 $NumOpers = $cEdit->getRowCount();
 $cBan = new cTabla($xSQL->getListadoDeOperacionesBancarias("", "", "", false, false, " AND `bancos_operaciones`.`recibo_relacionado` = {$idrecibo} "));
 //$cBan->setEventKey("idcontrol");
 $cBan->setKeyField("idcontrol");
 $cBan->addTool(SYS_UNO);
 $cBan->addTool(SYS_DOS);
 $cBan->setFootSum(array(7 => "monto"));
 $xTabs->addTab("TR.BANCOS", $cBan->Show());
 //Operaciones de Tesorería
 $cTes = new cTabla($xSQL->getListadoDeOperacionesDeTesoreria("", "", $idrecibo));
 $cTes->addTool(SYS_UNO);
 $cTes->addTool(SYS_DOS);
 $xTabs->addTab("TR.TESORERIA", $cTes->Show());
 //agregar contable
 if (getEsModuloMostrado(USUARIO_TIPO_CONTABLE) == true) {
     $xTbl = new cTabla("SELECT * FROM `contable_polizas_proforma` WHERE `numero_de_recibo`={$idrecibo}");
     $xTabs->addTab("TR.Pre Poliza", $xTbl->Show());
     //poliza relacionada
     $xTbl = new cTabla($xSQL->getListadoDePolizasContables(false, false, false, false, false, " AND (`recibo_relacionado`={$idrecibo}) "));
     $xTabs->addTab("TR.Poliza", $xTbl->Show());
     //factura XML
     //$xRec->getFactura(false, OUT_RXML);
     //$xDo	= new cDocumentos();
 }
 //
 $xFRM->addHTML($xTabs->get());
 $xFRM->addHTML("<input type='hidden' name='cNumeroRecibo' id='idNumeroRecibo' value='{$idrecibo}'>\n\t<input type='hidden' name='cFechaRecibo' id='idFechaRecibo' value='{$fechaRecibo}'>\n\t<input type='hidden' name='cTotalRecibo' id='idTotalRecibo' value='{$totalRecibo}'>\n\t<input type='hidden' name='cOperacion' id='idOperacion' value=''>\n\t");
 $xFRM->addFooterBar("<br/>");
 echo $xFRM->get();
 $recAct = $cEdit->getJSActions();