$row = array("monto_deudor" => 0); echo returnVectorJSON($row); } } else { $row = array("monto_deudor" => 0); echo returnVectorJSON($row); } exit; } if ($oData["behavior"] == "load") { $expVta = new ExpertoVentas(); $id_reparto = $oData["id_reparto"]; $id_cliente = $oData["id_cliente"]; $rdo = $expVta->getSaldoDeudor($id_reparto, $id_cliente); $saldo = $rdo; $expReparto = new ExpertoRepartos(); $reparto = $expReparto->getDataReparto($id_reparto); $expCte = new ExpertoClientes(); $cliente = $expCte->getById($id_cliente); } ?> <html> <head> <link rel="stylesheet" type="text/css" href="<?php echo $style_form; ?> styleForm.css"> <script language="javascript" src="<?php echo $jquery;
<?php include_once 'ExpertoRepartos.php'; $oData = $oRequestData = $_POST ? $_POST : $_GET; $exp = new ExpertoRepartos(); switch ($oData["behavior"]) { case "reloadListRepartos": $fecha_fin = $oData["fecha_fin"]; $fecha_inicio = $oData["fecha_inicio"]; $data = $exp->getAll($fecha_inicio, $fecha_fin); echo "<script> var data = \"{$data}\";\n parent.mygrid.clearAll();\n\t\t\t\t\t\t\tparent.mygrid.detachEvent(parent.idOnXLE);\n parent.mygrid.parse(data, 'xml');\n parent.mygrid.filterByAll();\n </script>"; exit; break; case 'save': if ($exp->save($oData)) { pushInfo("Cambios aplicados exitosamente"); echo true; } else { pushError("El registro no pudo ser creado"); echo false; } break; case "delete": $flag = false; if (isset($oData['id_reparto'])) { $ids = explode(",", $oData['id_reparto']); foreach ($ids as $id) { if (!$exp->delete($id)) { $flag = true; } }
<?php include_once '../../config.php'; require 'ExpertoRepartos.php'; $exp = new ExpertoRepartos(); $oData = $oRequestData = $_POST ? $_POST : $_GET; $desde = date("Y-m-d", strtotime("-1 week")); $hasta = null; $filterBy = ""; if ($oData["filtros"]) { $filters = explode("||", $oData["filtros"]); for ($i = 0; $i < count($filters); $i++) { $fieldAnValue = explode("=", $filters[$i]); $value[$i] = $fieldAnValue[1]; } $filterBy .= "mygrid.getFilterElement(1).value = '" . $value[1] . "';"; $filterBy .= "mygrid.getFilterElement(2).value = '" . $value[2] . "';"; $filterBy .= "mygrid.getFilterElement(3).value = '" . $value[3] . "';"; $filterBy .= "mygrid.getFilterElement(4).value = '" . $value[4] . "';"; $filterBy .= "mygrid.getFilterElement(9).value = '" . $value[9] . "';"; $filterBy .= "mygrid.filterByAll();"; $desde = $value[10]; $hasta = $value[11]; } $data = $exp->getAll($desde, $hasta); ?> <html> <head> <!-- FORMS --> <script language="javascript" src="<?php
function update_row($rowId) { $exp = new ExpertoRepartos(); $exp->updateItemDeCarga($_POST[$rowId . "_c2"], $rowId); return "update"; }
<?php require_once 'ExpertoRepartos.php'; require_once "../../_framework.php"; $oData = $oRequestData = $_POST ? $_POST : $_GET; $filtros = $oData["filtros"]; $exp = new ExpertoRepartos(); switch ($oData['behavior']) { case 'load': $oData = $exp->getById($oData['id_reparto']); break; } ?> <html> <head> <link rel="stylesheet" type="text/css" href="<?php echo $style_form; ?> styleForm.css"> <script language="javascript" src="<?php echo $lib_js; ?> mainFormba.js"></script> <script language="javascript" src="<?php echo $jquery; ?> jquery.js"></script> <script language="javascript" src="<?php echo $jquery;
<?php require_once '../../config.php'; require_once '../../_framework.php'; include_once 'ExpertoRepartos.php'; include_once '../impresion/ExpertoImpresion.php'; include_once '../ventas/ExpertoVentas.php'; $oData = $oRequestData = $_POST ? $_POST : $_GET; $exp = new ExpertoRepartos(); $id = $oData["id_reparto"]; switch ($oData['behavior']) { case 'load': $reparto = $exp->getDataReparto($id); break; case 'update': break; case 'delete': break; case 'imprimir': $expPrint = new ExpertoImpresion(); $text = ""; if ($oData['listado'] == 'true') { $text = $exp->getTextForPrintListadoDeCarga($id); $expPrint->imprimir(reemplazarCaracteresEspecialesPorAscii($text)); exit; } if ($oData['presupuestos'] == 'true') { $expVta = new ExpertoVentas(); $text = $expVta->getTextForPrintVentasDeRepartoPresupuesto($id); $expPrint->imprimir(reemplazarCaracteresEspecialesPorAscii($text)); exit;
require "../../_framework.php"; require 'ExpertoVentas.php'; include_once '../repartos/ExpertoRepartos.php'; $oData = $oRequestData = $_POST ? $_POST : $_GET; $filtros = $oData["filtros"]; $filtros2 = $oData["filtros2"]; switch ($oData['behavior']) { case 'load': $exp = new ExpertoVentas(); $cabecera = $exp->getCabeceraVenta($oData["id_venta"]); $rs_saldo_deudor = $exp->getDataSaldoDeudor($cabecera["id_reparto"], $cabecera["id_cliente"]); $row_saldo_deudor = getRow($rs_saldo_deudor); $detalle = $exp->getDetalleVenta($oData["id_venta"]); $OR_REPARTO = "OR id_reparto = " . $cabecera["id_reparto"]; if ($cabecera["id_reparto"] != 1) { $expRepartos = new ExpertoRepartos(); $dataRepartos = $expRepartos->getById($cabecera["id_reparto"]); if ($dataRepartos["id_reparto_estado"] == 2) { $disabled = "disabled"; } } break; case 'save': break; case 'new': $exp = new ExpertoVentas(); switch ($oData["id_tipo_venta"]) { case 1: $vta = $exp->getNroFacturaByTipo("nro_factura_a"); break; case 2:
function update_row($rowId) { $exp = new ExpertoRepartos(); $exp->updateNumeroFactura($_POST[$rowId . "_c2"], $rowId); return "update"; }
<?php require_once '../../config.php'; require_once '../../_framework.php'; include_once 'ExpertoRepartos.php'; include_once '../impresion/ExpertoImpresion.php'; $oData = $oRequestData = $_POST ? $_POST : $_GET; $exp = new ExpertoRepartos(); $id = $oData["id_reparto"]; switch ($oData['behavior']) { case 'load': break; case 'update': if ($id) { $exp->crearItemsDeCarga($id); } break; case 'delete': break; case 'imprimir': $text = $exp->getTextForPrintListadoDeCarga($id); $expPrint = new ExpertoImpresion(); $expPrint->imprimir(reemplazarCaracteresEspecialesPorAscii($text)); break; } $data = $exp->getListadoDeCarga($id); ?> <html> <head> <!-- FORMS --> <script language="javascript" src="<?php