function jsaCargaDeCreditos($persona) { $xL = new cSQLListas(); $ql = new MQL(); $xs = new cHSelect(); $xs->setDivClass(""); $sql = $xL->getListadoDeCreditos($persona); $rs = $ql->getDataRecord($sql); $aOpts = array(); //setLog($sql); foreach ($rs as $row) { $aOpts[$row["credito"]] = $row["credito"] . "-" . $row["producto"] . "-" . $row["periocidad"] . "-" . $row["saldo"]; } $xs->addOptions($aOpts); return $xs->get("idcreditodescontado", "TR.CLAVE_de_credito"); }
$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 } if ($xSoc->getEsEmpresaConConvenio(true) == true) { $xT2 = new cHTabs("idcomoempresa"); $idempresa = $xSoc->getOEmpresa()->getClaveDeEmpresa(); $oFrm->addEmpresaComandos($idempresa); $xTCreds = new cTabla($xql->getListadoDeCreditos(false, false, false, false, " AND (`creditos_solicitud`.`persona_asociada` = {$idempresa}) ", false), 2); $xTPers = new cTabla($xql->getListadoDeSocios(" (`socios_general`.`dependencia` = {$idempresa}) ")); $xTAhorro = new cTabla($xql->getListadoDeIncidenciasAhorro($idempresa)); $xTPeriodo = new cTabla($xql->getListadoDePeriodoPorEmpresa($idempresa)); $xTPeriodo->setTdClassByType(); $xTPeriodo->setEventKey("var xG = new EmpGen(); xG.getOrdenDeCobranza"); $xTCreds->setTdClassByType(); $xTPers->setTdClassByType(); $xTAhorro->setTdClassByType(); $xModAhorro = "<input type=\"number\" id=\"id" . HP_REPLACE_ID . "\" onblur=\"jsModificarAhorro(this," . HP_REPLACE_ID . ")\" />"; $xTPers->addEspTool($xModAhorro); $xT2->addTab("TR.Trabajadores", $xTPers->Show()); $xTCreds->setFootSum(array(8 => "saldo")); $xT2->addTab("TR.Creditos por empresa", $xTCreds->Show()); //Ahorro por Empresa $xT2->addTab("TR.Ahorro por empresa", $xTAhorro->Show());
} $_SESSION["current_file"] = addslashes($theFile); //<===== FIN_H //===================================================================================================== $xInit = new cHPage("", HP_SERVICE); $txt = ""; $ql = new MQL(); $lis = new cSQLListas(); $xF = new cFecha(); $persona = parametro("persona", DEFAULT_SOCIO, MQL_INT); $credito = parametro("credito", DEFAULT_CREDITO, MQL_INT); $tipo = parametro("tipo", false, MQL_INT); $estado = parametro("estado", false, MQL_INT); $rs = array(); if (setNoMenorQueCero($persona) > DEFAULT_SOCIO) { //$xSoc = new cSocio($persona); $xSoc->init(); //$tipo = ( setNoMenorQueCero($tipo) > 0) ? $tipo : SYS_TODAS; $estado = setNoMenorQueCero($estado) > 0 ? $estado : SYS_TODAS; $SinSaldo = ($estado == CREDITO_ESTADO_AUTORIZADO or $estado == CREDITO_ESTADO_SOLICITADO) ? true : false; $sql = $lis->getListadoDeCreditos($persona, $SinSaldo, $estado); $datos = $ql->getDataRecord($sql); foreach ($datos as $row) { $describe = $xF->getFechaDDMM($row["otorgado"]) . " " . $row["producto"] . "*" . $row["periocidad"] . " " . $row["periodo"] . "*" . $row["saldo"]; $rs[$row["credito"]] = $describe; } //} } header('Content-type: application/json'); echo json_encode($rs); //setLog(json_encode($rs)); //setLog($sql);
$xL = new cSQLListas(); $xF = new cFecha(); $query = new MQL(); $estatus = parametro("estado", SYS_TODAS); $frecuencia = parametro("periocidad", SYS_TODAS); $producto = parametro("convenio", SYS_TODAS); $producto = parametro("producto", $producto); $empresa = parametro("empresa", SYS_TODAS); $out = parametro("out", SYS_DEFAULT); $FechaInicial = parametro("on", false); //$FechaInicial = parametro("fecha-0", $FechaInicial); $FechaInicial = ($FechaInicial == false) ? FECHA_INICIO_OPERACIONES_SISTEMA : $xF->getFechaISO($FechaInicial); $FechaFinal = parametro("off", false); // $FechaFinal = parametro("fecha-1", $FechaFinal); $FechaFinal = ($FechaFinal == false) ? fechasys() : $xF->getFechaISO($FechaFinal); $jsEvent = $out != OUT_EXCEL ? "initComponents()" : ""; $senders = getEmails($_REQUEST); $sql = $xL->getListadoDeCreditos(false, false, false, CREDITO_PRODUCTO_INDIVIDUAL, " AND (DATE_FORMAT(fecha_ministracion, '%d')=DATE_FORMAT('{$FechaFinal}', '%d')) "); $titulo = ""; $archivo = ""; $xRPT = new cReportes($xHP->getTitle()); $xRPT->setFile($archivo); $xRPT->setOut($out); $xRPT->setSQL($sql); //============ Reporte $xT = new cTabla($sql, 2); $xT->setTipoSalida($out); $body = $xRPT->getEncabezado($xHP->getTitle(), $FechaInicial, $FechaFinal); $xRPT->setBodyMail($body); //============ Agregar HTML //$xRPT->addContent( $xHP->init($jsEvent) ); $xRPT->addContent($body); //$xT->setEventKey("jsGoPanel");
function jsaGetCreditosPorMinistrar($fecha) { $xD = new cFecha(); $xL = new cSQLListas(); $fecha = $xD->getFechaISO($fecha); $sql = $xL->getListadoDeCreditos(false, true, CREDITO_ESTADO_AUTORIZADO, false, " AND (SELECT COUNT(*) FROM `creditos_rechazados` WHERE `numero_de_credito`= creditos_solicitud.`numero_solicitud`) = 0 "); $xT = new cTabla($sql, 2); $xT->setEventKey("jsGoPanel"); //$xT->setKeyField("creditos_solicitud"); return $xT->Show(); }
$persona = isset($_GET["socio"]) ? $_GET["socio"] : $persona; $f = isset($_GET["f"]) ? $_GET["f"] : false; $ctrl = isset($_GET["control"]) ? $_GET["control"] : "idsolicitud"; $a = isset($_GET["a"]) ? $_GET["a"] : ""; $tipos = isset($_GET["tipo"]) ? $_GET["tipo"] : SYS_TODAS; $tipos = $tipos == "todos" ? SYS_TODAS : $tipos; $OtherEvent = isset($_GET["ev"]) ? $_GET["ev"] : ""; //Otro Evento Desatado $tiny = isset($_GET["tinybox"]) ? true : false; $slimit = ""; if ($a == "") { $slimit = " LIMIT 0,20"; } echo $xHP->getHeader(); $lsql = new cSQLListas(); $sql = $lsql->getListadoDeCreditos($persona, true, $tipos, false, "", true); $xFRM = new cHForm("frmlistacreditos"); $xT = new cTabla($sql); $xT->setEventKey("setCredito"); $xFRM->addHTML($xT->Show($xHP->getTitle())); //$xFRM->addHTML("<code>$sql</code>"); $xFRM->addSubmit("TR.aceptar", "jsEnd()"); echo $xHP->setBodyinit(); echo $xFRM->get(); echo $xHP->setBodyEnd(); ?> <script> var msrc = null; function setCredito(id){ var mopts = {};
echo getRawHeader(); echo "<p class='bigtitle'>ESTADO DE CUENTA GENERAL DE PERSONAS</p><hr />"; $subf = $todo == true ? "" : " AND estatus_mvto=30"; // REPORTES DE SOCIOS $cSocio = new cSocio($idsocio); $cSocio->init(); echo $cSocio->getFicha(true); $cTae = new cTabla($xLi->getListadoDeActividadesEconomicas($idsocio)); $cTae->setTdClassByType(); echo $cTae->Show("TR.ACTIVIDAD_ECONOMICA"); // $cTpr = new cTabla($xLi->getListadoDeRelaciones($idsocio)); $cTpr->setTdClassByType(); echo $cTpr->Show(PERSONAS_TITULO_PARTES); // $sqlcred = $xLi->getListadoDeCreditos($idsocio, true); $cTcred = new cTabla($sqlcred); $cTcred->setTdClassByType(); echo $cTcred->Show("TR.Creditos"); // $cTcta = new cTabla($xLi->getListadoDeCuentasDeCapt($idsocio)); $cTcta->setTdClassByType(); echo $cTcta->Show("TR.CUENTAS DE CAPTACION"); // $sqlgar = $sqlb17_ext . " AND creditos_garantias.socio_garantia={$idsocio} "; $cTgar = new cTabla($sqlgar); echo $cTgar->Show("TR.GARANTIAS DE CREDITOS"); $cTbl = new cTabla($xLi->getListadoDeRecibosEmitidos($idsocio)); echo $cTbl->Show("TR.Recibos"); // MOVIMIENTOS $sqli = $sqlb18d . " AND socio_afectado={$idsocio} " . $subf;