当前位置: 首页>>代码示例>>PHP>>正文


PHP DataFilter::script方法代码示例

本文整理汇总了PHP中DataFilter::script方法的典型用法代码示例。如果您正苦于以下问题:PHP DataFilter::script方法的具体用法?PHP DataFilter::script怎么用?PHP DataFilter::script使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DataFilter的用法示例。


在下文中一共展示了DataFilter::script方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: filteredgrid

    function filteredgrid()
    {
        $this->rapyd->load("datafilter", "datagrid");
        $this->rapyd->uri->keep_persistence();
        $this->datasis->modulo_id(707, 1);
        $script = '
		$(function() {
			$(".inputnum").numeric(".");
		});
		';
        $filter = new DataFilter("Filtro de Personal", 'pers');
        $filter->script($script, "create");
        $filter->script($script, "modify");
        $filter->script->css_class = 'inputnum';
        $filter->cedula = new inputField("Cédula", "cedula");
        $filter->cedula->size = 10;
        $filter->cedula->css_class = 'inputnum';
        $filter->nombre = new inputField("Nombre", "nombre");
        $filter->nombre->size = 30;
        $filter->apellido = new inputField("Apellido", "apellido");
        $filter->apellido->size = 30;
        $filter->contrato = new dropdownField("Contrato", "contrato");
        $filter->contrato->style = "width:400px;";
        $filter->contrato->option("", "");
        $filter->contrato->options("SELECT codigo,CONCAT('',codigo,nombre)as nombre FROM noco ORDER BY codigo");
        $filter->divi = new dropdownField("División", "divi");
        $filter->divi->style = "width:250px;";
        $filter->divi->option("", "");
        $filter->divi->options("SELECT division,descrip FROM divi ORDER BY division");
        $filter->buttons("reset", "search");
        $filter->build();
        $uri = anchor('nomina/pers/dataedit/show/<#codigo#>', '<#codigo#>');
        $grid = new DataGrid("Lista de Personal");
        $grid->order_by("codigo", "asc");
        $grid->per_page = 20;
        $grid->column("C&oacute;digo", $uri);
        $grid->column("C&eacute;dula", "cedula");
        $grid->column("Nombre", "nombre");
        $grid->column("Apellidos", "apellido");
        $grid->add("nomina/pers/dataedit/create");
        $grid->build();
        $data['content'] = $filter->output . $grid->output;
        $data['title'] = "<h1>Personal</h1>";
        $data["head"] = script("jquery.pack.js") . script("plugins/jquery.numeric.pack.js") . script("plugins/jquery.floatnumber.js") . $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
开发者ID:codethics,项目名称:proteoerp,代码行数:46,代码来源:pers.php

示例2: filteredgrid

 function filteredgrid()
 {
     $this->rapyd->load("datafilter", "datagrid");
     $script = '';
     $filter = new DataFilter("Lista");
     $filter->db->from("suminr");
     $filter->db->join("sprv", "suminr.proveed=sprv.proveed", "LEFT");
     $filter->script($script);
     $filter->numero = new inputField("Numero", "numero");
     $filter->numero->size = 15;
     $filter->fecha = new dateonlyField("Fecha", "fecha");
     $filter->fecha->dbformat = "Y-m-d";
     $filter->fecha->size = 12;
     $modbus = array('tabla' => 'sprv', 'columnas' => array('proveed' => 'Codigo', 'nombre' => 'Nombre'), 'filtro' => array('proveed' => 'Codigo', 'nombre' => 'Nombre'), 'retornar' => array('proveed' => 'proveed'), 'titulo' => 'Buscar Beneficiario');
     $bproveed = $this->datasis->modbus($modbus);
     $filter->proveed = new inputField("Beneficiario", "proveed");
     $filter->proveed->append($bproveed);
     $filter->proveed->size = 7;
     $filter->observacion = new inputField("Observaci&oacute;n", "observacion");
     $filter->observacion->size = 40;
     $filter->buttons("reset", "search");
     $filter->build();
     $uri = anchor('suministros/suminr/dataedit/show/<#numero#>', '<str_pad><#numero#>|8|0|STR_PAD_LEFT</str_pad>');
     function sta($status)
     {
         switch ($status) {
             case "P":
                 return "Pendiente";
                 break;
             case "A":
                 return "Anulado";
                 break;
             case "C":
                 return "Recibida";
                 break;
         }
     }
     $grid = new DataGrid();
     $grid->order_by("numero", "desc");
     $grid->per_page = 20;
     $grid->use_function('substr', 'str_pad', 'sta');
     $grid->column_orderby("N&uacute;mero", $uri, "numero");
     $grid->column_orderby("Fecha", "<dbdate_to_human><#fecha#></dbdate_to_human>", "fecha", "align='center'");
     $grid->column_orderby("Beneficiario", "nombre", "proveed", "align='left'");
     $grid->column_orderby("Total", "total", "total", "align='rigth'");
     $grid->column_orderby("Observaci&oacute;n", "<wordwrap><#observacion#>|50|\n|true</wordwrap>", "observacion", "align='left'");
     $grid->column_orderby("Estado", "<sta><#status#></sta>", "status", "align='center'      ");
     $grid->add("suministros/suminr/dataedit/create");
     $grid->build();
     //echo $grid->db->last_query();
     //		$data['content'] = $filter->output.$grid->output;
     $data['filtro'] = $filter->output;
     $data['content'] = $grid->output;
     $data['script'] = script("jquery.js") . "\n";
     $data['title'] = "Notas de Recepci&oacute;n";
     $data["head"] = script("jquery.js") . $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
开发者ID:enderochoa,项目名称:tortuga,代码行数:58,代码来源:suminr.php

示例3: filteredgrid

    function filteredgrid()
    {
        //$this->datasis->modulo_id(24,1);
        $this->rapyd->load("datafilter", "datagrid");
        $link = site_url('presupuesto/requisicion/getadmin');
        $script = '
			$(function() {
				$(".inputnum").numeric(".");
			});
			';
        $filter = new DataFilter("");
        $filter->script($script);
        $filter->db->select(array("a.numero numero", "a.fecha fecha", "a.total total"));
        $filter->db->from("ingresos a");
        //$filter->db->join("uejecutora b" ,"a.uejecuta=b.codigo");
        $filter->numero = new inputField("N&uacute;mero", "numero");
        $filter->numero->size = 15;
        $filter->fecha = new dateonlyField("Fecha", "fecha");
        $filter->fecha->size = 12;
        $filter->buttons("reset", "search");
        $filter->build();
        $uri = anchor($this->url . 'dataedit/show/<#numero#>', '<str_pad><#numero#>|8|0|STR_PAD_LEFT</str_pad>');
        $grid = new DataGrid("");
        $grid->order_by("numero", "desc");
        $grid->per_page = 20;
        $grid->use_function('substr', 'str_pad');
        $grid->column_orderby("N&uacute;mero", $uri, "numero");
        $grid->column_orderby("Fecha", "<dbdate_to_human><#fecha#></dbdate_to_human>", "fecha", "align='center'");
        $grid->column_orderby("Total", "<nformat><#total#></nformat>", "total", "align='right' ");
        $grid->add($this->url . "dataedit/create");
        $grid->build();
        $data['filtro'] = $filter->output;
        $data['content'] = $grid->output;
        $data['title'] = $this->titp;
        $data['script'] = script("jquery.js") . "\n";
        $data["head"] = $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
开发者ID:enderochoa,项目名称:tortuga,代码行数:38,代码来源:ingresos.php

示例4: filteredgrid

    function filteredgrid()
    {
        //$this->datasis->modulo_id(224,1);
        $this->rapyd->load("datafilter", "datagrid");
        $link = site_url('presupuesto/requisicion/getadmin');
        $script = '
			$(function() {
				$(".inputnum").numeric(".");
			});
		
			function get_uadmin(){
				$.post("' . $link . '",{ uejecuta:$("#uejecuta").val() },function(data){$("#td_uadministra").html(data);})
			}
			';
        $filter = new DataFilter("");
        $filter->script($script);
        $filter->db->select(array("a.status", "a.numero numero", "a.fecha fecha", "a.uejecuta", "b.nombre uejecuta2", "c.nombre uadministra2", "a.ano", "tsoli", "tdisp"));
        $filter->db->from("cdisp a");
        $filter->db->join("itcdisp d", "a.numero=d.numero", "LEFT");
        $filter->db->join("uejecutora b", "a.uejecuta=b.codigo", "LEFT");
        $filter->db->join("uadministra c", "a.uadministra=b.codigo", "LEFT");
        $filter->db->groupby("a.numero");
        $filter->numero = new inputField("N&uacute;mero", "numero");
        $filter->numero->size = 15;
        $filter->fecha = new dateonlyField("Fecha", "fecha");
        $filter->fecha->size = 12;
        $filter->uejecuta = new dropdownField("U.Ejecutora", "uejecuta");
        $filter->uejecuta->option("", "Seccionar");
        $filter->uejecuta->options("SELECT codigo,nombre FROM uejecutora ORDER BY nombre");
        $filter->uejecuta->onchange = "get_uadmin();";
        $filter->status = new dropdownField("Estado", "status");
        $filter->status->option('', '');
        $filter->status->option('C', 'Pre-Comprometido');
        $filter->status->option('A', 'Anulado');
        $filter->status->option('F', 'Finalizado Pre-Compromiso');
        $filter->status->option('P', 'Pendiente');
        $filter->codigoadm = new dropdownField("Est. Administrativa", "codigoadm");
        $filter->codigoadm->option("", "Seccionar");
        $filter->codigoadm->options("SELECT b.codigo, CONCAT_WS(' ',b.codigo,b.denominacion) AS val FROM presupuesto AS a JOIN estruadm AS b ON a.codigoadm=b.codigo  GROUP BY b.codigo");
        $filter->codigoadm->db_name = 'd.codigoadm';
        $filter->fondo = new dropdownField("Fuente de Financiamiento", "fondo");
        $filter->fondo->option("", "");
        $filter->fondo->options("SELECT fondo,CONCAT_WS(' ',fondo,descrip)a FROM fondo");
        $filter->fondo->db_name = 'd.fondo';
        $filter->codigopres = new inputField("Partida", "codigopres");
        $filter->codigopres->db_name = "d.codigopres";
        //$filter->codigopres->clause ="likerigth";
        $filter->codigopres->size = 25;
        $filter->buttons("reset", "search");
        $filter->build();
        $uri = anchor($this->url . 'dataedit/show/<#numero#>', '<#numero#>');
        function status($status = '')
        {
            switch ($status) {
                case 'C':
                    $status = "Pre-Comprometido";
                    break;
                case 'A':
                    $status = "Anulado";
                    break;
                case 'F':
                    $status = "Finalizado";
                    break;
                case 'P':
                    $status = "Pendiente";
                    break;
            }
            return $status;
        }
        $grid = new DataGrid("");
        $grid->order_by("numero", "desc");
        $grid->per_page = 20;
        $grid->use_function('substr', 'str_pad', 'status');
        $grid->column_orderby("N&uacute;mero", $uri, "numero");
        $grid->column_orderby("Fecha", "<dbdate_to_human><#fecha#></dbdate_to_human>", "fecha", "align='center'");
        $grid->column_orderby("Unidad Ejecutora", "uejecuta2", "uejecuta2", "align='left' NOWRAP");
        $grid->column_orderby("Unidad Administrativa", "uadministra2", "uadministra2", "align='left' NOWRAP");
        $grid->column_orderby("Disponible", "<nformat><#tdisp#></nformat>", "tdisp", "align='right' NOWRAP");
        $grid->column_orderby("Solicitado", "<nformat><#tsoli#></nformat>", "tsoli", "align='right' NOWRAP");
        $grid->column_orderby("Estado", "<status><#status#></status>", "status", "align='left'");
        $grid->add($this->url . "dataedit/create");
        $grid->build();
        $data['filtro'] = $filter->output;
        $data['content'] = $grid->output;
        $data['title'] = $this->titp;
        $data['script'] = script("jquery.js") . "\n";
        $data["head"] = $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
开发者ID:enderochoa,项目名称:tortuga,代码行数:89,代码来源:cdisp.php

示例5: index

    function index()
    {
        $this->rapyd->load('datafilter', 'datagrid');
        $link = site_url('supervisor/sfacfiscal/arreglaserial');
        $linkd = site_url('supervisor/sfacfiscal/arreglaserialdev');
        $link2 = site_url('supervisor/sfacfiscal/arreglanfiscal');
        $link4 = site_url('supervisor/sfacfiscal/arreglanfiscaldev');
        $link3 = site_url('supervisor/sfacfiscal/traereferen');
        $jquery = '
		function riega(id){
			if(confirm("Esta seguro que regar el serial para las facturas?")){
				if(confirm("Desea cambiar solo los registros vacios?"))
					resp=0;
				else
					resp=1;
				$.post("' . $link . '",{ cajero:$("#cajero").val(),fecha:$("#fecha").val(), serial:id ,noresp:resp, nulos:$("#nulos").val(),usuario:$("#usuario").val()},
				function(data){
					alert(data);
				});
			}
		}

		function riegadev(id){
			if(confirm("Esta seguro que regar el serial por las devoluciones?")){
				if(confirm("Desea cambiar solo los registros vacios?"))
					resp=0;
				else
					resp=1;
				$.post("' . $linkd . '",{ cajero:$("#cajero").val(),fecha:$("#fecha").val(), serial:id ,noresp:resp, nulos:$("#nulos").val(),usuario:$("#usuario").val()},
				function(data){
					alert(data);
				});
			}
		}

		function nfiscal(id){
			if(confirm("Esta seguro que regar el numero fiscal?")){
				if(confirm("Desea cambiar solo los registros vacios?"))
					resp=0;
				else
					resp=1;
				$.post("' . $link2 . '",{ cajero:$("#cajero").val(),fecha:$("#fecha").val(), numero:id ,noresp:resp, nulos:$("#nulos").val(),usuario:$("#usuario").val()},
				function(data){
					alert(data);
				});
			}
		}

		function nfiscaldev(id){
			if(confirm("Esta seguro que regar el numero fiscal?")){
				if(confirm("Desea cambiar solo los registros vacios?"))
					resp=0;
				else
					resp=1;
				$.post("' . $link4 . '",{ cajero:$("#cajero").val(),fecha:$("#fecha").val(), numero:id ,noresp:resp, nulos:$("#nulos").val(),usuario:$("#usuario").val()},
				function(data){
					alert(data);
				});
			}
		}


		function buscaref(){
			referenc = prompt("Introduce una referencia");
			$.post("' . $link3 . '",{ referen: referenc },
			function(data){
				alert(data);
			});
		}';
        function exissinv($cen, $t, $tipo_doc)
        {
            if (!empty($cen)) {
                if ($t == 1) {
                    if ($tipo_doc == 'F') {
                        $rt = form_button('asignar', $cen, 'onclick="riega(\'' . $cen . '\');"');
                    } else {
                        $rt = form_button('asignar', $cen, 'onclick="riegadev(\'' . $cen . '\');"');
                    }
                } else {
                    if ($tipo_doc == 'F') {
                        $rt = form_button('asignar', $cen, 'onclick="nfiscal(\'' . $cen . '\');"');
                    } else {
                        $rt = form_button('asignar', $cen, 'onclick="nfiscaldev(\'' . $cen . '\');"');
                    }
                }
            } else {
                $rt = '--';
            }
            return $rt;
        }
        $atts = array('width' => '800', 'height' => '600', 'scrollbars' => 'yes', 'status' => 'yes', 'resizable' => 'yes', 'screenx' => '0', 'screeny' => '0');
        $filter = new DataFilter('', 'sfac');
        //$filter->db->where('tipo_doc','F');
        $filter->script($jquery);
        $filter->fecha = new dateonlyField('Desde', 'fecha');
        $filter->fecha->clause = 'where';
        $filter->fecha->db_name = 'fecha';
        $filter->fecha->insertValue = date('Y-m-d');
        $filter->fecha->operator = '=';
        $filter->fecha->rule = 'required|chfecha';
//.........这里部分代码省略.........
开发者ID:codethics,项目名称:proteoerp,代码行数:101,代码来源:sfacfiscal.php

示例6: filteredgrid

    function filteredgrid()
    {
        //$this->datasis->modulo_id(24,1);
        $this->rapyd->load("datafilter", "datagrid");
        $link = site_url('presupuesto/requisicion/getadmin');
        $script = '
			$(function() {
				$(".inputnum").numeric(".");
				$("#mostrar").attr("title","Haz Click aqui para Mostrar el Filtro, y poder Buscar Documentos de una manera mas r&aacute;pida y cencilla");
				$("input[name=\\"btn_add\\"]").attr("title","Haz Click aqui para Agregar un nuevo Documento");
				
				$("#mostrar,.button,.enlace,.tuxhelp").tooltip({ 
				    track: true, 
				    delay: 0,
				    showURL: false, 
				    opacity: 1,
				    fixPNG: true, 
				    showBody: " - ", 
				    extraClass: "pretty fancy", 
				    top: -15,
				    left: 5
				});
			});
		
			function get_uadmin(){
				$.post("' . $link . '",{ uejecuta:$("#uejecuta").val() },function(data){$("#td_uadministra").html(data);})
			}
			';
        $filter = new DataFilter("");
        $filter->script($script);
        $filter->db->select(array("a.numero numero", "a.fecha fecha", "a.uejecuta", "b.nombre uejecuta2", "c.nombre uadministra2"));
        $filter->db->from("anoprox a");
        $filter->db->join("uejecutora b", "a.uejecuta=b.codigo");
        $filter->db->join("uadministra c", "a.uadministra=b.codigo", "LEFT");
        if ($this->datasis->traevalor('ESPEJO') == "S" && !$this->datasis->essuper()) {
            $filter->db->where("usuario", $this->session->userdata('usuario'));
        }
        $filter->numero = new inputField("N&uacute;mero", "numero");
        $filter->numero->size = 15;
        $filter->fecha = new dateonlyField("Fecha", "fecha", "d/m/Y");
        $filter->fecha->size = 12;
        $filter->uejecuta = new dropdownField("U.Ejecutora", "uejecuta");
        $filter->uejecuta->option("", "Seccionar");
        $filter->uejecuta->options("SELECT codigo,nombre FROM uejecutora ORDER BY nombre");
        $filter->uejecuta->onchange = "get_uadmin();";
        $filter->buttons("reset", "search");
        $filter->build();
        $uri = anchor($this->url . 'dataedit/show/<#numero#>', '<str_pad><#numero#>|8|0|STR_PAD_LEFT</str_pad>', array("title" => "Haz Click para ver el Documento de Proyecci&oacute;n N&uacute;mero <#numero#>", "class" => "enlace"));
        $grid = new DataGrid("Haz Click en cualquier n&uacute;mero de Documento para verlo");
        $grid->order_by("numero", "desc");
        $grid->per_page = 20;
        $grid->use_function('substr', 'str_pad');
        $grid->column_orderby("N&uacute;mero", $uri, "numero");
        $grid->column_orderby("Fecha", "<dbdate_to_human><#fecha#></dbdate_to_human>", "fecha", "align='center'");
        $grid->column_orderby("Unidad Ejecutora", "uejecuta2", "uejecuta2", "align='left' NOWRAP");
        $grid->column_orderby("Unidad Administrativa", "uadministra2", "uadministra2", "align='left' NOWRAP");
        $grid->add($this->url . "dataedit/create");
        $grid->build();
        $data['filtro'] = $filter->output;
        $data['content'] = $grid->output;
        $data['title'] = $this->titp;
        $data["head"] = $this->rapyd->get_head() . script('jquery.js') . script('jquery-ui.js') . script("plugins/jquery.numeric.pack.js") . script("plugins/jquery.json.min.js") . script('plugins/jquery.tooltip.js') . script('plugins/jquery.autocomplete.js') . style('jquery.autocomplete.css') . style('jquery.tooltip.css') . style('tooltip.css') . style('vino/jquery-ui.css');
        $this->load->view('view_ventanas', $data);
    }
开发者ID:enderochoa,项目名称:tortuga,代码行数:64,代码来源:anoprox.php

示例7: filteredgrid

    function filteredgrid()
    {
        //$this->datasis->modulo_id(24,1);
        $this->rapyd->load("datafilter", "datagrid");
        $link = site_url('presupuesto/requisicion/getadmin');
        $script = '
			$(function() {
				$(".inputnum").numeric(".");
			
			function get_uadmin(){
				$.post("' . $link . '",{ uejecuta:$("#uejecuta").val() },function(data){$("#td_uadministra").html(data);})
			}
		';
        $filter = new DataFilter("");
        $filter->script($script);
        $filter->db->select(array("a.numero numero", "a.fecha fecha", "a.uejecuta", "b.nombre uejecuta2", "concepto", "total", "status"));
        $filter->db->from("reinte a");
        $filter->db->join("uejecutora b", "a.uejecuta=b.codigo", "LEFT");
        $filter->db->join("uadministra c", "a.uadministra=b.codigo", "LEFT");
        $filter->numero = new inputField("N&uacute;mero", "numero");
        $filter->numero->size = 15;
        $filter->fecha = new dateonlyField("Fecha", "fecha", "d/m/Y");
        $filter->fecha->size = 12;
        $filter->uejecuta = new dropdownField("U.Ejecutora", "uejecuta");
        $filter->uejecuta->option("", "Seccionar");
        $filter->uejecuta->options("SELECT codigo,nombre FROM uejecutora ORDER BY nombre");
        $filter->uejecuta->onchange = "get_uadmin();";
        $filter->buttons("reset", "search");
        $filter->build();
        $uri = anchor($this->url . 'dataedit/show/<#numero#>', '<#numero#>');
        function sta($sta)
        {
            switch ($sta) {
                case 'P':
                    return 'Pendiente';
                case 'E2':
                    return 'Pagado';
                case 'O2':
                    return 'O. Pago';
                case 'T2':
                    return 'Causado';
                case 'C2':
                    return 'Comprometido';
                case 'C1':
                    return 'Causado';
                case 'T1':
                    return 'O. Pago';
                case 'O1':
                    return 'Pagado';
                    //				case 'E1':return 'Comprometido';
            }
        }
        $grid = new DataGrid("Haz Click en cualquier n&uacute;mero de Documento para verlo");
        $grid->order_by("numero", "desc");
        $grid->per_page = 20;
        $grid->use_function('substr', 'str_pad', 'sta');
        $grid->column_orderby("N&uacute;mero", $uri, "numero");
        $grid->column_orderby("Fecha", "<dbdate_to_human><#fecha#></dbdate_to_human>", "fecha", "align='center'");
        $grid->column_orderby("Unidad Ejecutora", "uejecuta2", "uejecuta2", "align='left'  ");
        $grid->column_orderby("Concepto", "concepto", "concepto", "align='left'  ");
        $grid->column_orderby("Total", "total", "total", "align='right' ");
        $grid->column_orderby("Estado", "<sta><#status#></sta>", "status", "align='right' ");
        if ($this->datasis->puede(319)) {
            $grid->add($this->url . "dataedit/create");
        }
        $grid->build();
        $data['filtro'] = $filter->output;
        $data['content'] = $grid->output;
        $data['title'] = $this->titp;
        $data["head"] = $this->rapyd->get_head() . script('jquery.js') . script('jquery-ui.js') . script("plugins/jquery.numeric.pack.js") . script("plugins/jquery.json.min.js") . script('plugins/jquery.tooltip.js') . script('plugins/jquery.autocomplete.js') . style('jquery.autocomplete.css') . style('jquery.tooltip.css') . style('tooltip.css') . style('vino/jquery-ui.css');
        $this->load->view('view_ventanas', $data);
    }
开发者ID:enderochoa,项目名称:tortuga,代码行数:72,代码来源:reinte.php

示例8: filteredgrid

 function filteredgrid()
 {
     $this->load->helper('form');
     $this->rapyd->load('dataobject', "datafilter", "datagrid");
     $this->rapyd->uri->keep_persistence();
     $this->datasis->modulo_id(52, 1);
     $mNOCO = array('tabla' => 'noco', 'columnas' => array('codigo' => 'C&oacute;digo de Sucursal', 'nombre' => 'Nombre'), 'filtro' => array('codigo' => 'C&oacute;digo', 'nombre' => 'Nombre'), 'retornar' => array('codigo' => 'contrato'), 'titulo' => 'Buscar Contratos', 'where' => 'tipo <> "O"');
     $bNOCO = $this->datasis->modbus($mNOCO);
     $script = '
             $(function() {
                     
             });
             ';
     $filter = new DataFilter("", 'pers');
     $filter->db->select(array("noco.nombre noconombre", "pers.codigo", "pers.nacional", "pers.cedula", "pers.nombre", "pers.nombre2", "pers.apellido", "pers.apellido2", "pers.direc1", "pers.direc2", "pers.direc3", "pers.telefono", "pers.nacimi", "pers.sso", "pers.sexo", "pers.civil", "pers.depto", "pers.cargo", "pers.sueldo", "pers.ingreso", "pers.retiro", "pers.tipo", "pers.contrato", "pers.dialib", "pers.status", "pers.banco", "pers.cutipo", "pers.cuenta", "pers.vari1", "pers.vari2", "pers.vari3", "pers.vari4", "pers.vari5", "pers.vari6", "pers.vari7", "pers.vari8", "pers.uaumento", "pers.formato", "pers.dialab", "pers.xdialab", "pers.sucursal", "pers.divi", "pers.carnet", "pers.enlace", "pers.estampa", "pers.usuario", "pers.hora", "pers.transac", "pers.cuentab", "pers.profes", "pers.niveled", "pers.vence", "pers.horario", "pers.rif", "pers.codigoadm", "pers.fondo", "pers.codigopres", "pers.email", "pers.tipoe", "pers.observa", "pers.sueldo", "divi.descrip division"));
     $filter->db->join("noco", "pers.contrato=noco.codigo", "LEFT");
     $filter->db->join("divi", "divi.division=pers.divi", "LEFT");
     $filter->script($script, "create");
     $filter->script($script, "modify");
     $filter->codigo = new inputField("Codigo", "codigo");
     $filter->codigo->size = 30;
     $filter->codigo->db_name = 'pers.codigo';
     $filter->cedula = new inputField("C&eacute;dula", "cedula");
     $filter->cedula->size = 10;
     $filter->cedula->css_class = 'inputnum';
     $filter->cedula->db_name = 'pers.cedula';
     $filter->nombre = new inputField("Nombre", "nombre");
     $filter->nombre->size = 30;
     $filter->nombre->db_name = 'pers.nombre';
     $filter->apellido = new inputField("Apellido", "apellido");
     $filter->apellido->size = 30;
     $filter->apellido->db_name = 'pers.apellido';
     $filter->fondo = new inputField("Fondo", "fondo");
     $filter->fondo->db_name = 'pers.fondo';
     $filter->divi = new dropdownField("Divisi&oacute;n", "divi");
     $filter->divi->style = "width:250px;";
     $filter->divi->option("", "");
     $filter->divi->options("SELECT division,CONCAT_WS(' ',division,descrip)des FROM divi ORDER BY division");
     //$filter->divi->group = "Relaci&oacute;n Laboral";
     $filter->codigoadm = new inputField("Est. Administrativa", "codigoadm");
     $filter->codigoadm->db_name = 'pers.codigoadm';
     $filter->codigopres = new inputField("Codigo Partida", "codigopres");
     $filter->codigopres->db_name = 'pers.codigopres';
     $filter->contrato = new inputField("Contrato", "contrato");
     $filter->contrato->size = 4;
     $filter->contrato->maxlength = 5;
     $filter->contrato->append($bNOCO);
     $filter->contrato->clause = 'where';
     $filter->contrato->operator = '=';
     $filter->sueldo = new inputField("Sueldo", "sueldo");
     $filter->sueldo->db_name = 'pers.sueldo';
     $filter->status = new dropdownField("Estatus", "status");
     $filter->status->option("", "");
     $filter->status->options(array("A" => "Activo", "V" => "Vacaciones", "R" => "Retirado"));
     $filter->status->group = "Relaci&oacute;n Laboral";
     $filter->status->style = "width:100px;";
     //$filter->script->css_class='inputnum';
     $filter->buttons("reset", "search");
     $filter->build();
     $uri = anchor('nomina/pers/dataedit/show/<raencode><#codigo#></raencode>', '<#codigo#>');
     $grid = new DataGrid("");
     $grid->order_by("pers.codigo", "asc");
     $grid->per_page = 20;
     $grid->column_orderby("C&oacute;digo", $uri, "pers.codigo");
     $grid->column_orderby("C&eacute;dula", "cedula", "cedula");
     $grid->column_orderby("Nombre", "nombre", "nombre", "align='left'NOWRAP");
     $grid->column_orderby("Apellidos", "apellido", "apellido", "align='left'NOWRAP");
     $grid->column_orderby("Division", "division", "divi.descrip", "");
     $grid->column_orderby("Contrato", "noconombre", "noconombre", "");
     $grid->column_orderby("Sueldo", "sueldo", "sueldo", "");
     $grid->add("nomina/pers/dataedit/create");
     $grid->build();
     $sql = $grid->db->last_query();
     $cantidad = $grid->recordCount;
     $hidden = array('sql' => $sql, 'cantidad' => $cantidad);
     $form = form_open($this->url . "masivo", '', $hidden);
     $form .= form_submit('modificar', 'Modificar Masivo');
     //$data['content'] = $filter->output.$grid->output;
     $data['filtro'] = $filter->output;
     $data['content'] = $grid->output . $form;
     $data['script'] = script("jquery.js") . "\n";
     $data['title'] = "Personal";
     $data["head"] = script("jquery.pack.js") . script("plugins/jquery.numeric.pack.js") . script("plugins/jquery.floatnumber.js") . $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
开发者ID:enderochoa,项目名称:tortuga,代码行数:85,代码来源:pers.php

示例9: filteredgrid

    function filteredgrid()
    {
        $this->datasis->modulo_id(24, 1);
        $this->rapyd->load("datafilter", "datagrid");
        $link = site_url('presupuesto/requisicion/getadmin');
        $script = '
			$(function() {
				$(".inputnum").numeric(".");
			});
		
			function get_uadmin(){
				$.post("' . $link . '",{ uejecuta:$("#uejecuta").val() },function(data){$("#td_uadministra").html(data);})
			}
			';
        $filter = new DataFilter("");
        $filter->script($script);
        $filter->db->select("a.numero,a.numero numero,a.fecha fecha,a.uejecuta uejecuta,a.uadministra,a.responsable,a.objetivo,a.tcantidad,a.timporte,a.status,a.ocompra,b.nombre uejecuta2,c.nombre uadministra2");
        $filter->db->from("requi a");
        $filter->db->join("uejecutora b", "a.uejecuta=b.codigo");
        $filter->db->join("uadministra c", "a.uadministra=b.codigo", "LEFT");
        $filter->numero = new inputField("N&uacute;mero", "numero");
        $filter->numero->size = 15;
        $filter->fecha = new dateonlyField("Fecha", "fecha");
        $filter->fecha->size = 12;
        $filter->uejecuta = new dropdownField("U.Ejecutora", "uejecuta");
        $filter->uejecuta->option("", "Seccionar");
        $filter->uejecuta->options("SELECT codigo,nombre FROM uejecutora ORDER BY nombre");
        $filter->uejecuta->onchange = "get_uadmin();";
        $filter->uejecuta->rule = "required";
        $filter->ocompra = new inputField("O. Compra", "ocompra");
        $filter->ocompra->size = 15;
        //$filter->uadministra = new dropdownField("U.Administrativa", "uadministra");
        //$filter->uadministra->option("","Ninguna");
        $filter->buttons("reset", "search");
        $filter->build();
        $uri = anchor('presupuesto/requisicion/dataedit/show/<#numero#>', '<str_pad><#numero#>|8|0|STR_PAD_LEFT</str_pad>');
        //$uri2 = anchor('presupuesto/requisicion/asig_part/modify/<#id#>','<str_pad><#id#>|8|0|STR_PAD_LEFT</str_pad>');
        $grid = new DataGrid("");
        $grid->order_by("numero", "desc");
        $grid->per_page = 20;
        $grid->use_function('substr', 'str_pad');
        $grid->column_orderby("N&uacute;mero", $uri, "numero");
        $grid->column_orderby("Fecha", "<dbdate_to_human><#fecha#></dbdate_to_human>", "fecha", "align='center'");
        $grid->column_orderby("Unidad Ejecutora", "uejecuta2", "uejecuta2", "align='left' NOWRAP");
        $grid->column_orderby("Unidad Administrativa", "uadministra2", "uadministra2", "align='left' NOWRAP");
        $grid->column_orderby("O.Compra", '<str_pad><#ocompra#>|8|0|STR_PAD_LEFT</str_pad>', "ocompra");
        $grid->column_orderby("Estado", "status", "status");
        $grid->column_orderby("Responsable", "responsable", "responsable");
        $grid->column_orderby("Objetivo", "objetivo", "objetivo");
        //$grid->column("Asig. Partida"         ,$uri2);
        $grid->add("presupuesto/requisicion/dataedit/create");
        $grid->build();
        //$ingrid = '<script type="text/javascript">
        //$(document).ready(
        //	function() {
        //		$("#tablagrid").ingrid({
        //			url: "remote.html",
        //			height: 350
        //		});
        //	}
        //);
        //</script> ';
        //
        //$data['style']   = style("ingrid.css");
        $data['filtro'] = $filter->output;
        $data['content'] = $grid->output;
        $data['title'] = "Requisiciones";
        //"";
        $data['script'] = script("jquery.js") . "\n";
        //.script("jquery.ingrid.js")."\n".$ingrid;
        $data["head"] = $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
开发者ID:enderochoa,项目名称:tortuga,代码行数:73,代码来源:requisicion.php


注:本文中的DataFilter::script方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。