Example #1
0
 function dataedit()
 {
     $this->datasis->modulo_id($this->id_modulo, 1);
     $this->rapyd->load('dataedit');
     $edit = new DataEdit('Carga de Publicidad', 'publicidad');
     $edit->back_url = site_url('supervisor/publicidad/filteredgrid');
     $edit->archivo = new uploadField('Adjunto', 'archivo');
     $edit->archivo->upload_path = $this->upload_path;
     $edit->archivo->allowed_types = 'jpg|gif|swf|png';
     $edit->archivo->append('Puede adjuntar jpg,gif,png y swf');
     $edit->bgcolor = new colorpickerField('Color de Fondo', 'bgcolor');
     //$edit->bgcolor = new inputField("Color de Fondo", "bgcolor");
     $edit->bgcolor->maxlength = 7;
     $edit->bgcolor->size = 9;
     $edit->prob = new inputField('Probabilidad de aparicion', 'prob');
     $edit->prob->css_class = 'inputnum';
     $edit->prob->maxlength = 8;
     $edit->prob->size = 6;
     //$edit->prob->rule="";
     $edit->descrip = new textareaField('Descripción', 'descrip');
     $edit->descrip->rows = 5;
     $edit->buttons('modify', 'save', 'undo', 'back', 'delete');
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = '<h1>Registro de publicidad</h1>';
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #2
0
 function DataEdit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Agregar Menu", "tmenus");
     $edit->back_url = site_url("supervisor/tmenus/filteredgrid");
     $edit->modulo = new inputField("Modulo", "modulo");
     $edit->modulo->size = 12;
     $edit->modulo->maxlength = 10;
     $edit->secu = new inputField("Secuencia", "secu");
     $edit->secu->size = 6;
     $edit->secu->maxlength = 5;
     $edit->titulo = new inputField("Titulo", "titulo");
     $edit->titulo->size = 25;
     $edit->titulo->maxlength = 20;
     $edit->mensaje = new textareaField("Mensaje", "mensaje");
     $edit->mensaje->rows = 4;
     $edit->mensaje->cols = 90;
     $edit->ejecutar = new inputField("Ejecutar", "ejecutar");
     $edit->ejecutar->size = 80;
     $edit->ejecutar->maxlength = 80;
     $edit->buttons("modify", "save", "undo", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Menu de Datasis</h1>";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #3
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Inventario", "sinv");
     $edit->back_url = site_url("nomina/pers/filteredgrid");
     $edit->codigo = new inputField("Codigo", "codigo");
     $edit->grupo = new inputField("Grupo", "grupo");
     $edit->descrip = new inputField("Descripcion", "descrip");
     $edit->descrip2 = new inputField("Descripcion2", "descrip2");
     $edit->unidad = new inputField("Unidad", "unidad");
     $edit->ubica = new inputField("Ubicaci&oacute;n", "ubica");
     $edit->tipo = new inputField(".", "tipo");
     $edit->pvp_bs = new inputField("Pvp_bs", "pvp_bs");
     $edit->pvpprc = new inputField("Pvpprc", "pvpprc");
     $edit->contbs = new DateField("Contbs", "contbs");
     $edit->contprc = new inputField("Contprc", "contprc");
     $edit->mayobs = new DateField("Mayoobs", "mayobs");
     $edit->mayoprc = new inputField("Mayoprc", "mayoprc");
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = " Inventario ";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #4
0
 function dataedit($sta, $id)
 {
     $this->rapyd->load('dataedit', 'datagrid');
     $edit = new DataEdit('Ficha del cliente', 'scli');
     $edit->back_url = site_url($this->url . 'filteredgrid');
     $edit->cliente = new inputField('Cliente', 'cliente');
     $edit->cliente->rule = 'trim|required|existesprv';
     $edit->cliente->maxlength = 5;
     $edit->cliente->size = 7;
     $edit->cliente->mode = 'autohide';
     $edit->nombre = new inputField('Nombre', 'nombre');
     $edit->nombre->rule = 'trim';
     $edit->nombre->maxlength = 40;
     $edit->nombre->size = 40;
     $edit->nombre->mode = 'autohide';
     $edit->nombre->in = 'cliente';
     $edit->rifci = new inputField('RIF/CI', 'rifci');
     $edit->rifci->rule = 'trim';
     $edit->rifci->maxlength = 40;
     $edit->rifci->size = 40;
     $edit->rifci->mode = 'autohide';
     $edit->telefono = new inputField('Tel&eacute;fono', 'telefono');
     $edit->telefono->rule = 'trim';
     $edit->telefono->maxlength = 40;
     $edit->telefono->size = 40;
     $edit->telefono->mode = 'autohide';
     $edit->buttons('undo', 'back');
     $edit->build();
     $data['content'] = $edit->output;
     $crm = $edit->_dataobject->get('crm');
     if (empty($crm)) {
         $dbdata['usuario'] = $this->secu->usuario();
         $dbdata['status'] = 'A';
         $dbdata['fecha'] = date('Ymd');
         $dbdata['titulo'] = 'Callcenter';
         $dbdata['cliente'] = $edit->_dataobject->get('cliente');
         $dbdata['descripcion'] = '';
         $mSQL = $this->db->insert_string('crm_contenedor', $dbdata);
         $this->db->simple_query($mSQL);
         $crm = $this->db->insert_id();
         $mSQL = "UPDATE scli SET crm = {$crm} WHERE id={$id}";
         $this->db->simple_query($mSQL);
     }
     $this->crm_back = site_url("crm/callcenter/dataedit/{$sta}/{$id}");
     $adici = array($edit->_dataobject->pk['id']);
     $this->prefijo = 'crm_';
     $data['content'] .= Contenedor::_showAdjuntos($crm, 'crm/callcenter/adjuntos', $adici);
     $data['content'] .= Contenedor::_showEventos($crm, 'crm/callcenter/eventos', $adici);
     $data['content'] .= Contenedor::_showComentarios($crm, 'crm/callcenter/comentarios', $adici);
     $data['style'] = style('redmond/jquery-ui.css');
     $data['script'] = script('jquery.js');
     $data['script'] .= script('jquery-ui.js');
     $data['script'] .= script('plugins/jquery.floatnumber.js');
     $data['script'] .= script('plugins/jquery.numeric.pack.js');
     $data['script'] .= script('plugins/jquery.ui.autocomplete.autoSelectOne.js');
     $data['script'] .= phpscript('nformat.js');
     $data['head'] = $this->rapyd->get_head();
     $data['title'] = heading('Callcenter');
     $this->load->view('view_ventanas', $data);
 }
Example #5
0
 function dataedit()
 {
     $this->rapyd->load("dataobject", "dataedit");
     //              $link=site_url('finventario/bi_edificio/ultimo');
     //              $link2=site_url('finventario/bi_edificio/sugerir');
     $edit = new DataEdit("Muebles", "bi_bienes");
     $edit->back_url = site_url("bienes/bi_bienes/filteredgrid");
     $edit->pre_process('insert', '_valida');
     $edit->pre_process('update', '_valida');
     $edit->id = new inputField("Id", "id");
     $edit->id->mode = "autohide";
     $edit->id->when = array('show');
     $edit->nombre = new inputField("Nombre", "nombre");
     $edit->nombre->size = 30;
     $edit->nombre->maxlength = 30;
     $edit->descrip = new textareaField("Descripci&oacute;n", "descrip");
     $edit->descrip->rows = 4;
     $edit->descrip->cols = 50;
     $edit->modelo = new inputField("Modelo", "modelo");
     $edit->modelo->size = 20;
     $edit->modelo->maxlength = 30;
     $edit->color = new inputField("Color", "color");
     $edit->color->size = 20;
     $edit->color->maxlength = 30;
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "Muebles";
     $data["head"] = script("jquery.pack.js") . $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #6
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("ARTICULO", "sinv");
     $edit->back_url = site_url("inventario/cambiosinv/filteredgrid");
     $edit->post_process('update', '_post_update');
     $edit->codigo = new inputField("Codigo", "codigo");
     $edit->codigo->size = 25;
     $edit->codigo->mode = "autohide";
     $edit->descrip = new inputField("Descripcion", "descrip");
     $edit->descrip->size = 50;
     $edit->descrip->mode = "autohide";
     $edit->exmin = new inputField("Existencia Minima", "exmin");
     $edit->exmin->size = 20;
     $edit->exmax = new inputField("Existencia Maxima", "exmax");
     $edit->exmax->size = 20;
     $edit->existen = new inputField("Existencia", "existen");
     $edit->existen->size = 20;
     $edit->activo = new dropdownField("Activo", "activo");
     $edit->activo->option("", "");
     $edit->activo->option("S", "Si");
     $edit->activo->option("N", "No");
     $edit->activo->style = "width:50px";
     $edit->buttons("modify", "save", "undo", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = " Almacenes ";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #7
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Sucursal", "sucu");
     $edit->back_url = site_url("supervisor/sucu/filteredgrid");
     $edit->codigo = new inputField("C&oacute;digo", "codigo");
     $edit->codigo->rule = "required";
     $edit->codigo->mode = "autohide";
     $edit->codigo->size = 4;
     $edit->codigo->maxlength = 2;
     $edit->sucursal = new inputField("Sucursal", "sucursal");
     $edit->sucursal->rule = "strtoupper";
     $edit->sucursal->size = 60;
     $edit->sucursal->maxlength = 45;
     $edit->url = new inputField("URL", "url");
     $edit->url->size = 80;
     $edit->url->maxlength = 200;
     $edit->prefijo = new inputField("Prefijo", "prefijo");
     $edit->prefijo->size = 5;
     $edit->prefijo->maxlength = 3;
     $edit->proteo = new inputField("Proteo", "proteo");
     $edit->proteo->maxlength = 50;
     $edit->proteo->size = 70;
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Sucursal</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);
 }
Example #8
0
    function dataedit()
    {
        $this->rapyd->load('dataedit');
        $script = '
		$(function() {
			$(".inputnum").numeric(".");
		});';
        $edit = new DataEdit('Metas', 'metas');
        $edit->back_url = site_url('ventas/metas/filteredgrid');
        $edit->script($script, 'create');
        $edit->script($script, 'modify');
        $edit->fecha = new dateonlyField('Fecha', 'fecha', 'm/Y');
        $edit->fecha->insertValue = date('Y-m-d');
        $edit->fecha->dbformat = 'Ym';
        $edit->fecha->size = 7;
        $edit->fecha->append('mes/año');
        $edit->fecha->rule = 'required';
        $edit->codigo = new dropdownField('Producto', 'codigo');
        $edit->codigo->option('', 'Seleccionar');
        $edit->codigo->rule = 'required';
        $edit->codigo->options('SELECT TRIM(codigo),CONCAT_WS("-",TRIM(codigo),TRIM(descrip)) AS valor FROM sinv ORDER BY codigo');
        //$edit->codigo->style = 'width:150px';
        $edit->codigo->rule = 'required';
        $edit->cantidad = new inputField('Cantidad', 'cantidad');
        $edit->cantidad->size = 12;
        $edit->cantidad->maxlength = 12;
        $edit->cantidad->rule = 'numeric|required|positive';
        $edit->cantidad->css_class = 'inputnum';
        $edit->buttons('modify', 'save', 'undo', 'delete', 'back', 'add');
        $edit->build();
        $data['content'] = $edit->output;
        $data['title'] = heading('Metas');
        $data['head'] = script('jquery.js') . script('plugins/jquery.numeric.pack.js') . script('plugins/jquery.floatnumber.js') . $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
Example #9
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Zona", "zona");
     $edit->back_url = site_url("ventas/zonaf/filteredgrid");
     $edit->codigo = new inputField("codigo", "codigo");
     $edit->codigo->size = 5;
     $edit->codigo->rule = "required";
     $edit->codigo->maxlength = 5;
     $edit->pais = new dropdownField("Pa&iacute;s", "pais");
     $edit->pais->style = "width:150px";
     $edit->pais->option("", "Seleccionar");
     $edit->pais->options("SELECT codigo, nombre FROM pais ORDER BY codigo");
     $edit->pais->group = "Ubicaci&oacute;n";
     $edit->nombre = new inputField("Nombre", "nombre");
     $edit->nombre->size = 38;
     $edit->nombre->rule = "trim|required|strtoupper";
     $edit->nombre->maxlength = 30;
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Zona</h1>";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #10
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("", "prueba");
     $edit->id = new inputField("C&oacute;digo", "id");
     $edit->id->rule = "trim|required";
     $edit->id->size = 16;
     $edit->id->maxlength = 15;
     $edit->html = new editorField("Contenido", "html");
     $edit->html->rule = "required";
     $edit->html->rows = 20;
     //$edit->contenido->upload_path  = $this->upload_path;
     $edit->html->cols = 90;
     $edit->html->when = array("modify");
     //
     //$edit->html2 = new htmlField("Codice HTML", "html");
     //$edit->html2->cols = 70;
     //$edit->html2->rows = 10;
     $edit->iframe = new iframeField("related", "mpru/a", "500");
     $edit->iframe->when = array("show");
     //$edit->iframe->group = "Related Records";
     //$edit->container = new containerField("alert","html");
     //$edit->container->when = array("show");
     //
     //$edit->free = new freeField("Free Field","html","html");
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data["head"] = script("tabber.js") . script("prototype.js") . $this->rapyd->get_head() . script("scriptaculous.js") . script("effects.js");
     $data['title'] = '<h1>Catalogos de Inventarios</h1>';
     $this->load->view('view_ventanas', $data);
 }
Example #11
0
    function dataedit()
    {
        $this->datasis->modulo_id(101, 1);
        $this->rapyd->load("dataedit");
        $script = '
			$(".inputnum").numeric(".");
		';
        $edit = new DataEdit("Sector", "sectores");
        $edit->script($script, "create");
        $edit->back_url = site_url("presupuesto/sectores/filteredgrid");
        $edit->sect_pres = new inputField("C&oacute;digo", "sect_pres");
        $edit->sect_pres->size = 5;
        $edit->sect_pres->maxlength = 2;
        $edit->sect_pres->mode = "autohide";
        $edit->sect_pres->css_class = 'inputnum';
        $edit->nomb_sect = new inputField("Nombre", "nomb_sect");
        $edit->nomb_sect->size = 40;
        $edit->nomb_sect->maxlength = 80;
        $edit->nomb_sect->rule = 'required';
        $edit->buttons("modify", "save", "undo", "delete", "back");
        $edit->build();
        $data['content'] = $edit->output;
        $data['title'] = " Sectores ";
        $data["head"] = script("jquery.pack.js") . $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
Example #12
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Carga de Publicidad", "publicidad");
     $edit->back_url = site_url("supervisor/publicidad/filteredgrid");
     $edit->archivo = new uploadField("Archivo", "archivo");
     $edit->archivo->upload_path = $this->upload_path;
     $edit->archivo->allowed_types = "jpg|gif|swf|png";
     $edit->bgcolor = new inputField("Color de Fondo", "bgcolor");
     $edit->bgcolor->maxlength = 7;
     $edit->bgcolor->size = 9;
     //$edit->bgcolor->rule="";
     $edit->prob = new inputField("Probabilidad de aparicion", "prob");
     $edit->prob->css_class = 'inputnum';
     $edit->prob->maxlength = 8;
     $edit->prob->size = 6;
     //$edit->prob->rule="";
     $edit->descrip = new textareaField("Descripci&oacute;n", "descrip");
     $edit->descrip->rows = 5;
     $edit->buttons("modify", "save", "undo", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Registro de publicidad</h1>";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #13
0
 function dataedit()
 {
     $this->rapyd->load('dataedit');
     $edit = new DataEdit('Partidas', 'crm_partidas');
     $edit->back_url = site_url('crm/partidas/');
     $edit->codigo = new inputField('C&oacute;digo', 'codigo');
     $edit->codigo->rule = 'trim|required|max_length[15]';
     $edit->descripcion = new inputField('Descripci&oacute;n', 'descripcion');
     $edit->descripcion->rule = 'trim|required|max_length[100]';
     $edit->enlace = new inputField('Enlace Administrativo', 'enlace');
     $edit->enlace->rule = 'trim|required|max_length[6]';
     $edit->enlace->size = 7;
     $edit->medida = new inputField('Medida', 'medida');
     $edit->medida->rule = 'trim|required|max_length[5]';
     $edit->medida->size = 6;
     $edit->medida->max_size = 5;
     $edit->iva = new inputField('Iva', 'iva');
     $edit->iva->rule = 'trim|required|numeric';
     $edit->buttons('modify', 'save', 'undo', 'delete', 'back');
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = '<h1>Partidas de Contratos</h1>';
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #14
0
    function dataedit()
    {
        $this->datasis->modulo_id(102, 1);
        $this->rapyd->load("dataedit");
        $script = '
			$(".inputnum").numeric(".");
		';
        $edit = new DataEdit("Programas", "programas");
        $edit->script($script, "create");
        $edit->back_url = site_url("presupuesto/programas/filteredgrid");
        $edit->sect_pres = new dropdownField("Sector", "sect_pres");
        $edit->sect_pres->options("SELECT sect_pres, CONCAT_WS(' ',sect_pres,nomb_sect)AS nomb_sect FROM sectores ORDER BY sect_pres");
        $edit->sect_pres->style = 'width:300px;';
        $filter->id_prog = new inputField("Identificador", "id_prog");
        $filter->id_prog->size = 5;
        $edit->prog_pres = new inputField("C&oacute;digo Programa", "prog_pres");
        $edit->prog_pres->size = 5;
        $edit->prog_pres->maxlength = 2;
        $edit->prog_pres->mode = "autohide";
        $edit->prog_pres->css_class = 'inputnum';
        $edit->prog_pres->rule = 'required';
        $edit->nomb_prog = new inputField("Nombre Programa", "nomb_prog");
        $edit->nomb_prog->size = 40;
        $edit->nomb_prog->maxlength = 80;
        $edit->nomb_prog->rule = 'required';
        $edit->buttons("modify", "save", "undo", "delete", "back");
        $edit->build();
        $data['content'] = $edit->output;
        $data['title'] = " Programas ";
        $data["head"] = script("jquery.pack.js") . $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
Example #15
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("soporte", "soporte");
     $edit->back_url = site_url("supervisor/sopor/filteredgrid");
     //$edit->pre_process('delete','_pre_del');
     $edit->usuario = new inputField("Usuario", "usuario");
     $edit->usuario->mode = "autohide";
     //$edit->rif->rule = "required";
     //$edit->rif->maxlength=13;
     $edit->usuario->size = 14;
     $edit->estampa = new dateField("Estampa", "estampa", "d/m/Y");
     $edit->estampa->size = 10;
     $edit->estampa->mode = "autohide";
     $edit->titulo = new inputField("Titulo", "titulo");
     $edit->comentario = new textareaField("Comentario", "comentario");
     $edit->comentario->cols = 70;
     $edit->comentario->rows = 10;
     if ($this->uri->segment(4) === "1") {
         $edit->buttons("modify", "save", "undo", "back");
     } else {
         $edit->buttons("modify", "save", "undo", "delete", "back");
     }
     $edit->build();
     //echo $edit->_dataobject->db->last_query();;
     $data["edit"] = $edit->output;
     $data["modulo"] = "";
     $content["content"] = $this->load->view('rapyd/dataedit', $data, true);
     $content["rapyd_head"] = $this->rapyd->get_head();
     $content["code"] = "";
     $content["lista"] = "\r\n\t\t\t<h3>Editar o Agregar</h3>\r\n\t\t\t<div>La identificacion del Grupo debe ser unica, la clase puede ser Cliente, Interna u Otros, en la Descripcion colocar que se quiere agrupar y la cuenta contable para el enlace contable</div>\r\n\t\t\t<div class='line'></div>\r\n\t\t\t<a href='#' onclick='window.close()'>Cerrar</a>\r\n\t\t\t<div class='line'></div>\n<br><br><br>\n";
     $this->load->view('rapyd/tmpsolo', $content);
 }
Example #16
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Estructura Administrativa", "estruadm");
     $edit->pre_process('delete', '_pre_delete');
     $edit->back_url = "presupuesto/estruadm/index/filteredgrid";
     $edit->codigo = new inputField("C&oacute;digo", "codigo");
     $edit->codigo->rule = "trim|required|callback_chcodigo";
     $edit->codigo->mode = "autohide";
     $edit->codigo->size = 20;
     $edit->codigo->maxlength = 15;
     $edit->titulo = new inputField("Denominaci&oacute;n", "denominacion");
     $edit->titulo->rule = "required";
     $edit->titulo->size = 50;
     $edit->titulo->maxlength = 500;
     //$edit->descrip = new inputField("Tipo", "tipo");
     //$edit->descrip->size = 10;
     //$edit->descrip->maxlength = 1;
     $edit->uejecutora = new dropdownField("Unidad Ejecutora", "uejecutora");
     $edit->uejecutora->option("", "");
     $edit->uejecutora->size = 80;
     $edit->uejecutora->options("SELECT codigo, CONCAT(codigo,' ', nombre) nombre FROM uejecutora ORDER BY nombre");
     $edit->descripcion = new textAreaField("Descripcion", "descripcion");
     $edit->descripcion->cols = 80;
     $edit->descripcion->rows = 7;
     $edit->buttons("add", "modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data["head"] = $this->rapyd->get_head();
     $data['title'] = 'Estructura Administrativa';
     $this->load->view('view_ventanas', $data);
 }
Example #17
0
 function dataedit()
 {
     $this->rapyd->load('dataedit');
     $edit = new DataEdit("barras de Inventario", "sinv");
     $edit->back_url = site_url("inventario/ubica/filteredgrid/search/osp");
     $edit->ubica = new inputField("Ubica", "ubica");
     $edit->ubica->size = 15;
     $edit->codigo = new inputField("C&oacute;digo", "codigo");
     $edit->codigo->size = 15;
     $edit->codigo->rule = "required";
     $edit->codigo->mode = "autohide";
     $edit->codigo->mode = "readonly";
     $edit->descrip = new inputField("Descripci&oacute;n", "descrip");
     $edit->descrip->size = 40;
     $edit->descrip->mode = "autohide";
     $edit->descrip2 = new inputField("Descripci&oacute;n Corta", "descrip2");
     $edit->descrip2->size = 20;
     $edit->descrip2->mode = "autohide";
     $edit->precio1 = new inputField("Precio", "precio1");
     $edit->precio1->size = 15;
     $edit->precio1->mode = "autohide";
     $edit->buttons("modify", "save", "undo", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = " C&oacute;digo Barras de Inventario ";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #18
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Datos del Huesped", "hchk");
     $edit->back_url = site_url("hospitalidad/huesped/filteredgrid");
     $edit->post_process('insert', '_post_insert');
     $edit->post_process('update', '_post_update');
     $edit->post_process('delete', '_post_delete');
     $edit->cedula = new inputField("Cedula", "cedula");
     $edit->cedula->rule = "trim|strtoupper|required|callback_chrif|callback_chexiste";
     $edit->cedula->mode = "autohide";
     $edit->cedula->maxlength = 15;
     $edit->cedula->size = 17;
     $edit->nombres = new inputField("Nombres", "nombre");
     $edit->nombres->rule = "trim";
     $edit->nombres->size = 30;
     $edit->nombres->maxlength = 20;
     $edit->apellidos = new inputField("Apeliidos", "apellido");
     $edit->apellidos->rule = "trim";
     $edit->apellidos->size = 30;
     $edit->apellidos->maxlength = 20;
     $edit->dire1 = new inputField("Direcci&oacute;n", "dire1");
     $edit->dire1->rule = "trim";
     $edit->dire1->size = 50;
     $edit->dire1->maxlength = 40;
     $edit->telefono = new inputField("Tel&eacute;fono", "telefono");
     $edit->telefono->rule = "trim";
     $edit->telefono->size = 23;
     $edit->telefono->maxlength = 20;
     $edit->edad = new inputField("Edad", "edad");
     $edit->edad->rule = "trim";
     $edit->edad->size = 4;
     $edit->edad->maxlength = 2;
     $edit->visa = new dropdownField("Tipo de Visa", "visa");
     $edit->visa->option("", "");
     $edit->visa->options(array("T" => "Turista", "R" => "Residente", "O" => "Otros"));
     $edit->visa->style = "width:100px";
     $edit->civil = new dropdownField("Estado Civil", "civil");
     $edit->civil->option("", "");
     $edit->civil->options(array("S" => "SOLTERO(A)", "C" => "CASADO(A)", "D" => "DIVORCIADO(A)", "V" => "VIUDO(A)"));
     $edit->civil->style = "width:130px";
     $edit->profesion = new inputField("Profesi&oacute;n", "profesion");
     $edit->profesion->rule = "trim";
     $edit->profesion->size = 30;
     $edit->profesion->maxlength = 20;
     $edit->email = new inputField("Correo Electronico", "email");
     $edit->email->size = 40;
     $edit->email->maxlength = 40;
     $edit->email->rule = "valid_email|trim";
     $edit->nacional = new dropdownField("Nacionalidad", "nacional");
     $edit->nacional->option("", "");
     $edit->nacional->options("SELECT codigo, pais FROM nacion where pais>'' ORDER BY codigo ");
     $edit->nacional->style = "width:180px";
     $edit->buttons("modify", "save", "undo", "back", "delete");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Huespedes</h1>";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #19
0
 function dataedit()
 {
     function _vfecha($strdate)
     {
         if ($strdate == '') {
             return true;
         }
         if (ereg("([0-9]{2})/([0-9]{2})/([0-9]{4})", "{$strdate}", $arr)) {
             if (date("d/m/Y", strtotime("{$arr['2']}/{$arr['1']}/{$arr['3']}")) == $strdate) {
                 return true;
             }
         }
         return false;
     }
     $this->datasis->modulo_id(701001, 1);
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Calendario", "cale");
     $edit->back_url = site_url("nomina/calendario/filteredgrid");
     $edit->feria = new DateField("D&iacute;a Feriado", "feria", "d/m/Y");
     $edit->feria->rule = "required|callback_vfecha(";
     $edit->feria->mode = "autohide";
     $edit->motivo = new inputField("Motivo", "motivo");
     $edit->fijo = new inputField("Fijo", "fijo");
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Calendario</h1>";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #20
0
 function dataedit()
 {
     $this->rapyd->load('dataedit');
     $this->rapyd->uri->keep_persistence();
     $edit = new DataEdit('Cheque emitido', 'bmov');
     $status = $edit->_status;
     if ($status != 'show') {
         show_error('Error de par&aacute;metros');
     }
     $edit->back_url = site_url('finanzas/conforch/filteredgrid');
     $edit->fecha = new DateonlyField('Fecha', 'fecha', 'd/m/Y');
     $edit->fecha->insertValue = date('Y-m-d');
     $edit->benefi = new inputField('A nombre de', "benefi");
     $edit->benefi->group = 'Detalle del cheque';
     $edit->banco = new inputField("Del Banco", "banco");
     $edit->banco->group = 'Detalle del cheque';
     $edit->numcuent = new inputField("N&uacute;mero Cuenta", "numcuent");
     $edit->numcuent->in = 'banco';
     $edit->numcuent->group = 'Detalle del cheque';
     $edit->numero = new inputField("N&uacute;mero de cheque", "numero");
     $edit->numero->group = 'Detalle del cheque';
     $edit->monto = new inputField("Por un Monto de", "monto");
     $edit->monto->group = 'Detalle del cheque';
     $edit->nombre = new inputField('Proveedor', 'nombre');
     $edit->concepto = new inputField("Por Concepto", "concepto");
     $edit->anulado = new inputField("Anulado", "anulado");
     $edit->buttons('back');
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = heading('Consulta de Cheques');
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #21
0
    function dataedit()
    {
        //$this->datasis->modulo_id(101,1);
        $this->rapyd->load("dataedit");
        $link = site_url('presupuesto/ppla/autocompleteppla');
        $script = "\n\t\t\$(document).ready(function() {\n\t\t\t\$.post('{$link}',{ partida:'' },function(data){\n\t\t\t\tdatos=jQuery.parseJSON(data);\n\n\t\t\t\t\$('#codigopres').autocomplete({\n\t\t\t\t\tdelay: 0,\n\t\t\t\t\tminLength: 4,\n\t\t\t\t\tsource: datos,\n\t\t\t\t\tfocus: function( event, ui ) {\n\t\t\t\t\t\t\$( '#codigopres').val( ui.item.codigo );\n\t\t\t\t\t\t\$( '#denominacion').val( ui.item.denominacion );\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t},\n\t\t\t\t\tselect: function( event, ui ) {\n\t\t\t\t\t\t\$( '#codigopres').val( ui.item.codigo );\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t\t.data( 'autocomplete' )._renderItem = function( ul, item ) {\n\t\t\t\t\treturn \$( '<li></li>' )\n\t\t\t\t\t.data( 'item.autocomplete', item )\n\t\t\t\t\t.append( '<a>' +item.codigo+'-'+ item.denominacion + '</a>' )\n\t\t\t\t\t.appendTo( ul );\n\t\t\t\t};\n\t\t\t});\n\t\t});\n\t\t";
        $edit = new DataEdit("Presupuesto de Ingresos", "ingpresup");
        $edit->back_url = $this->url;
        $edit->post_process('update', '_post');
        $edit->post_process('insert', '_post');
        $edit->script($script, 'create');
        $edit->script($script, 'modify');
        $edit->codigopres = new inputField("C&oacute;digo Presupuesto", "codigopres");
        $edit->codigopres->db_name = "codigopres";
        $edit->codigopres->size = 20;
        $edit->codigopres->mode = "autohide";
        $edit->codigopres->rule = "required";
        $edit->denominacion = new textareaField("Denominacion", "denominacion");
        $edit->denominacion->rows = 2;
        $edit->denominacion->cols = 70;
        $edit->denominacion->rule = "required";
        $edit->tipo = new dropdownField("Tipo", "tipo");
        $edit->tipo->option('o', 'Ingreso Ordinario');
        $edit->tipo->option('e', 'Ingreso Extraordinario');
        $edit->tipo->option('r', 'Reversion de Pago');
        $edit->tipo->style = "50px";
        $edit->estimado = new inputField("Estimado", "estimado");
        $edit->estimado->size = 20;
        //$edit->estimado->mode = "autohide";
        //$edit->estimado->when = array("show","create");
        $edit->cuenta = new inputField("C&oacute;digo ", "cuenta");
        $edit->cuenta->db_name = "cuenta";
        $edit->cuenta->size = 20;
        //$edit->cuenta->mode = "autohide";
        //$edit->cuenta->rule ="required";
        $edit->abreviatura = new inputField("Abreviatura", "abreviatura");
        $edit->abreviatura->size = 15;
        $edit->abreviatura->maxlenght = 20;
        $edit->buttons("add", "modify", "save", "undo", "delete", "back");
        $edit->build();
        $style = '

		.ui-autocomplete {
		  max-height: 250px;
		  overflow-y: auto;
		  max-width: 600px;
		}
		 html.ui-autocomplete {
		  height: 250px;
		  width: 600px;
		}

		';
        $data['content'] = $edit->output;
        $data["style"] = $style;
        $data["head"] = script('jquery.js') . script('jquery-ui.js') . script('plugins/jquery.meiomask.js') . style('vino/jquery-ui.css') . $this->rapyd->get_head();
        $data['title'] = ' Presupuesto ';
        $this->load->view('view_ventanas', $data);
    }
Example #22
0
    function dataedit()
    {
        //$this->datasis->modulo_id(101,1);
        $this->rapyd->load("dataedit");
        $script = '
			$(".inputnum").numeric(".");
		';
        $qformato = $this->qformato = $this->datasis->formato_cpla();
        $mCPLA = array('tabla' => 'cpla', 'columnas' => array('codigo' => 'C&oacute;digo', 'denominacion' => 'Descripci&oacute;n'), 'filtro' => array('codigo' => 'C&oacute;digo', 'denominacion' => 'Denominacion'), 'retornar' => array('codigo' => '<#i#>'), 'titulo' => 'Buscar Cuenta', 'where' => "codigo LIKE \"{$qformato}\"", 'p_uri' => array(4 => '<#i#>'));
        $bcpla = $this->datasis->p_modbus($mCPLA, "cuenta");
        $bcplap = $this->datasis->p_modbus($mCPLA, "cuentap");
        $fbcpla = $this->datasis->p_modbus($mCPLA, "fcuenta");
        $fbcplap = $this->datasis->p_modbus($mCPLA, "fcuentap");
        $edit = new DataEdit($this->t**s, "fondo");
        $edit->script($script, "create");
        $edit->script($script, "modify");
        $edit->back_url = site_url("presupuesto/fondo/filteredgrid");
        $edit->fondo = new inputField("F. Financiamiento", "fondo");
        $edit->fondo->size = 20;
        $edit->fondo->maxlength = 20;
        $edit->descrip = new inputField("Descripci&oacute;n", "descrip");
        $edit->descrip->size = 60;
        $edit->descrip->maxlength = 100;
        $edit->cuenta = new inputField("Cuenta. Contable", "cuenta");
        $edit->cuenta->rule = 'callback_chcuentac|trim';
        $edit->cuenta->size = 12;
        $edit->cuenta->readonly = true;
        $edit->cuenta->append($bcpla);
        $edit->cuenta->group = 'Ordenes de Pago';
        $edit->cuentap = new inputField("Cuenta. Pasivo", "cuentap");
        $edit->cuentap->rule = 'callback_chcuentac|trim';
        $edit->cuentap->size = 20;
        $edit->cuentap->readonly = true;
        $edit->cuentap->append($bcplap);
        $edit->cuentap->group = 'Ordenes de Pago';
        $edit->fcuenta = new inputField("Cuenta. Contable", "fcuenta");
        $edit->fcuenta->rule = 'callback_chcuentac|trim';
        $edit->fcuenta->size = 20;
        //$edit->fcuenta->readonly=true;
        $edit->fcuenta->append($fbcpla);
        $edit->fcuenta->group = 'Fondo Anticipo';
        $edit->fcuentap = new inputField("Cuenta. Pasivo", "fcuentap");
        $edit->fcuentap->rule = 'callback_chcuentac|trim';
        $edit->fcuentap->size = 20;
        //$edit->fcuentap->readonly=true;
        $edit->fcuentap->append($fbcplap);
        $edit->fcuentap->group = 'Fondo Anticipo';
        $edit->partidaiva = new inputField("Partida Iva", "partidaiva");
        $edit->partidaiva->size = 25;
        $edit->partidaiva->maxlength = 25;
        $edit->buttons("modify", "save", "undo", "delete", "back");
        $edit->build();
        $data['content'] = $edit->output;
        $data['title'] = "{$this->t**s}";
        $data["head"] = script("jquery.pack.js") . $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
Example #23
0
    function dataedit()
    {
        $this->rapyd->load("dataedit");
        $modbus = array('tabla' => 'maes', 'columnas' => array('codigo' => 'C&oacute;digo', 'descrip' => 'Descripci&oacute;n', 'precio1' => 'Precio 1', 'precio2' => 'Precio 2', 'precio3' => 'Precio 3', 'precio4' => 'Precio 4', 'precio5' => 'Precio 5'), 'filtro' => array('codigo' => 'C&oacute;digo', 'descrip' => 'Descripci&oacute;n'), 'retornar' => array('codigo' => 'codigo'), 'titulo' => 'Buscar en inventario');
        $boton = $this->datasis->modbus($modbus);
        $script = '
		$(function() {
			$(".inputnum").numeric(".");
		});';
        $edit = new DataEdit("Inventario Express", "maesfisico");
        $edit->pre_process('insert', '_pre_insert');
        $edit->back_url = site_url("supermercado/efisico/filteredgrid");
        $edit->script($script, "create");
        $edit->script($script, "modify");
        $edit->id = new inputField("ID", "id");
        $edit->id->mode = "autohide";
        $edit->id->when = array('show');
        $edit->codigo = new inputField("C&oacute;digo", "codigo");
        $edit->codigo->size = 20;
        $edit->codigo->append($boton);
        $edit->codigo->mode = "autohide";
        $edit->codigo->maxlength = 15;
        $edit->codigo->rule = "trim|required";
        $edit->ubica = new dropdownField("Almacen", "ubica");
        $edit->ubica->option("", "Seleccionar");
        $edit->ubica->options("SELECT ubica,CONCAT(ubica,' ',ubides) descrip FROM caub WHERE gasto='N' ");
        $edit->ubica->rule = "trim|required";
        $edit->locali = new inputField("Localizaci&oacute;n", "locali");
        $edit->locali->size = 9;
        $edit->locali->maxlength = 5;
        $edit->locali->rule = "trim";
        $edit->cantidad = new inputField("Cantidad", "cantidad");
        $edit->cantidad->size = 15;
        $edit->cantidad->css_class = 'inputnum';
        $edit->cantidad->maxlength = 11;
        $edit->cantidad->rule = "numeric|callback_ccana";
        $edit->fraccion = new inputField("Fracci&oacute;n", "fraccion");
        $edit->fraccion->size = 15;
        $edit->fraccion->css_class = 'inputnum';
        $edit->fraccion->maxlength = 11;
        $edit->fraccion->rule = "numeric|callback_ccana";
        $edit->fecha = new DateonlyField("Fecha", "fecha", "d/m/Y");
        $edit->fecha->insertValue = date("Y-m-d");
        $edit->fecha->rule = "required";
        $edit->fecha->size = 12;
        //$edit->hora = new inputField("Hora","hora");
        //$edit->hora->size =8;
        //$edit->hora->rule='callback_chhora|trim';
        //$edit->hora->append('hh:mm:ss');
        //$edit->hora->rule="trim";
        $edit->buttons("modify", "save", "undo", "delete", "back");
        $edit->build();
        $data['content'] = $edit->output;
        $data['title'] = "<h1>Inventario Express</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);
    }
Example #24
0
 function dataedit()
 {
     $this->rapyd->load('dataedit');
     $edit = new DataEdit($this->t**s, 'IA');
     $edit->back_url = site_url($this->url . "filteredgrid");
     $edit->post_process('insert', '_post_insert');
     $edit->post_process('update', '_post_update');
     $edit->post_process('delete', '_post_delete');
     $edit->pre_process('insert', '_pre_insert');
     $edit->pre_process('update', '_pre_update');
     $edit->pre_process('delete', '_pre_delete');
     $edit->id = new inputField('Id', 'id');
     $edit->id->rule = 'max_length[10]';
     $edit->id->size = 12;
     $edit->id->maxlength = 10;
     $edit->nombre = new inputField('Nombre', 'nombre');
     $edit->nombre->rule = 'max_length[100]';
     $edit->nombre->size = 102;
     $edit->nombre->maxlength = 100;
     $edit->w = new inputField('W', 'w');
     $edit->w->rule = 'max_length[8]';
     $edit->w->size = 10;
     $edit->w->maxlength = 8;
     $edit->pos = new inputField('Pos', 'pos');
     $edit->pos->rule = 'max_length[10]';
     $edit->pos->size = 12;
     $edit->pos->maxlength = 10;
     $edit->buttons('modify', 'save', 'undo', 'delete', 'back');
     $edit->build();
     $data['content'] = $edit->output;
     $data['head'] = $this->rapyd->get_head();
     $data['title'] = $this->t**s;
     $this->load->view('view_ventanas', $data);
 }
Example #25
0
 function dataedit()
 {
     $this->rapyd->load('dataedit');
     $edit = new DataEdit($this->t**s, 'edifubica');
     $edit->back_url = site_url($this->url . 'filteredgrid');
     $edit->post_process('insert', '_post_insert');
     $edit->post_process('update', '_post_update');
     $edit->post_process('delete', '_post_delete');
     $edit->pre_process('insert', '_pre_insert');
     $edit->pre_process('update', '_pre_update');
     $edit->pre_process('delete', '_pre_delete');
     $edit->id_edif = new dropdownField('Edificaci&oacute;n', 'id_edif');
     $edit->id_edif->option('', 'Seleccionar');
     $edit->id_edif->options('SELECT id,TRIM(nombre) AS nombre FROM edif ORDER BY nombre');
     $edit->id_edif->rule = 'max_length[11]';
     $edit->descripcion = new inputField('Descripci&oacute;n', 'descripcion');
     $edit->descripcion->rule = 'max_length[50]';
     $edit->descripcion->size = 52;
     $edit->descripcion->maxlength = 50;
     $edit->buttons('modify', 'save', 'undo', 'delete', 'back', 'add');
     $edit->build();
     $data['content'] = $edit->output;
     $data['head'] = $this->rapyd->get_head();
     $data['title'] = heading($this->t**s);
     $this->load->view('view_ventanas', $data);
 }
Example #26
0
    function dataedit()
    {
        $this->datasis->modulo_id(83, 1);
        $this->rapyd->load("dataedit");
        $link2 = site_url($this->url . '/sugerir');
        $script = '
			$(".inputnum").numeric(".");
			
			function sugerir(){
				$.ajax({
						url: "' . $link2 . '",
						success: function(msg){
							if(msg){
								$("#codigo").val(msg);
							}
							else{
								alert("No es posible generar otra sugerencia. Coloque el c&oacute;digo manualmente");
							}
						}
					});
				}
		';
        $edit = new DataEdit($this->t**s, "uadministra");
        $edit->script($script, "create");
        $edit->back_url = site_url("presupuesto/uadministra/filteredgrid");
        $edit->codigoejec = new dropdownField("Unidad Ejecutora", "codigoejec");
        $edit->codigoejec->rule = 'required';
        $edit->codigoejec->options("SELECT codigo, CONCAT_WS(' ',codigo,nombre)as a FROM uejecutora ORDER BY nombre");
        $sugerir = '<a href="javascript:sugerir();" title="Sugerir un Codigo aleatorio">Sugerir C&oacute;digo </a>';
        $edit->codigo = new inputField("C&oacute;digo", "codigo");
        $edit->codigo->size = 5;
        $edit->codigo->maxlength = 4;
        $edit->codigo->mode = "autohide";
        $edit->codigo->css_class = 'inputnum';
        $edit->codigo->rule = 'required';
        $edit->codigo->append($sugerir);
        $edit->nombre = new inputField("Nombre", "nombre");
        $edit->nombre->size = 40;
        $edit->nombre->maxlength = 80;
        $edit->nombre->rule = 'required';
        $edit->director = new inputField("Director", "director");
        $edit->director->size = 60;
        $edit->director->maxlength = 100;
        $edit->funciones = new textareaField("Funciones", "funciones");
        $edit->funciones->rows = 8;
        $edit->funciones->cols = 60;
        $edit->buttons("modify", "save", "undo", "delete", "back");
        $edit->build();
        $data['content'] = $edit->output;
        $data['title'] = "{$this->t**s}";
        $data["head"] = script("jquery.js") . $this->rapyd->get_head();
        $this->load->view('view_ventanas', $data);
    }
Example #27
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Habitaci&oacute;n", "habi");
     $edit->back_url = site_url("hospitalidad/habita/filteredgrid");
     $edit->post_process('insert', '_post_insert');
     $edit->post_process('update', '_post_update');
     $edit->post_process('delete', '_post_delete');
     $edit->habit = new inputField("Habitacion", "habit");
     $edit->habit->rule = "trim|required|callback_chexiste";
     $edit->habit->mode = "autohide";
     $edit->habit->maxlength = 4;
     $edit->habit->size = 7;
     $edit->tipo = new dropdownField("Tipo", "tipo");
     $edit->tipo->option("", "");
     $edit->tipo->options("SELECT tipo,descrip FROM thab ORDER BY tipo");
     $edit->tipo->style = "width:150px";
     $edit->descrip = new inputField("Descripci&oacute;n", "descrip");
     $edit->descrip->rule = 'trim';
     $edit->descrip->maxlength = 40;
     $edit->descrip->size = 50;
     $edit->telefono = new inputField("Tel&eacute;fono Ext.", "telefono");
     $edit->telefono->rule = 'trim';
     $edit->telefono->size = 10;
     $edit->telefono->maxlength = 7;
     $edit->servicio = new inputField("Servicios", "servicio");
     $edit->servicio->rule = 'trim';
     $edit->servicio->size = 50;
     $edit->servicio->maxlength = 40;
     $edit->status = new dropdownField("Status", "status");
     $edit->status->option("", "");
     $edit->status->options(array("A" => "Activa", "B" => "Bloqueada", "M" => "Mantenimiento", "D" => "Da&ntilde;ana", "S" => "Salon", "C" => "Comodin"));
     $edit->status->style = "width:130px";
     $edit->estado = new dropdownField("Estado", "estado");
     $edit->estado->option("", "");
     $edit->estado->options(array("S" => "SUCIA", "L" => "LIMPIA", "A" => "ARREGLO"));
     $edit->estado->style = "width:130px";
     $edit->ocupada = new dropdownField("Ocupada", "ocupada");
     $edit->ocupada->option("", "");
     $edit->ocupada->options(array("S" => "SI", "N" => "NO"));
     $edit->ocupada->style = "width:60px";
     $edit->fecha = new dateonlyField("Fecha", "ultima");
     $edit->fecha->size = 12;
     $edit->quejas = new inputField("Quejas", "quejas");
     $edit->quejas->rule = "trim";
     $edit->quejas->size = 50;
     $edit->buttons("modify", "save", "undo", "back", "delete");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Habitaciones</h1>";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #28
0
 function dataedit()
 {
     $this->rapyd->load("dataedit");
     $edit = new DataEdit("Aplicaci&oacute;n de Anticipos", "apan");
     $edit->back_url = site_url("inventario/anticipos/filteredgrid");
     $edit->pre_process('insert', '_pre_insert');
     $edit->pre_process('update', '_pre_update');
     $edit->numero = new inputField("N&uacute;mero", "numero");
     $edit->numero->mode = "autohide";
     $edit->numero->maxlength = 8;
     $edit->numero->size = 12;
     $edit->numero->rule = "trim|required";
     $edit->fecha = new dateonlyField("Fecha", "fecha");
     $edit->fecha->size = 12;
     $edit->fecha->insertValue = date("Y-m-d", mktime(0, 0, 0, date("m"), date("d") - 30, date("Y")));
     $edit->fecha->rule = "trim|required";
     $edit->tipo = new inputField("Tipo", "tipo");
     $edit->tipo->maxlength = 1;
     $edit->tipo->size = 6;
     $edit->tipo->rule = "trim";
     $edit->clipro = new inputField("Clipro", "clipro");
     $edit->clipro->maxlength = 5;
     $edit->clipro->size = 6;
     $edit->clipro->rule = "trim";
     $edit->nombre = new inputField("Nombre", "nombre");
     $edit->nombre->maxlength = 30;
     $edit->nombre->size = 20;
     $edit->nombre->rule = "trim";
     $edit->monto = new inputField("Monto", "monto");
     $edit->monto->size = 12;
     $edit->monto->rule = "trim";
     $edit->reinte = new inputField("Reintegro", "reinte");
     $edit->reinte->maxlength = 5;
     $edit->reinte->size = 6;
     $edit->reinte->rule = "trim";
     $edit->observa1 = new inputField("Observaciones", "observa1");
     $edit->observa1->maxlength = 50;
     $edit->observa1->size = 50;
     $edit->observa1->rule = "trim";
     $edit->observa2 = new inputField("", "observa2");
     $edit->observa2->maxlength = 50;
     $edit->observa2->size = 50;
     $edit->observa2->rule = "trim";
     $edit->transac = new inputField("Transacci&oacute;n", "transac");
     $edit->hora = new inputField("Hora", "hora");
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = "<h1>Aplicaci&oacute;n de Anticipos</h1>";
     $data["head"] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Example #29
0
 function dataedit($status = '', $fondo = '', $codigoadm = '', $codigopres = '')
 {
     //$this->datasis->modulo_id(101,1);
     $this->rapyd->load("dataobject", "dataedit");
     $link = site_url('presupuesto/ppla/autocompleteppla');
     $script = "\r\n\t\t\$(document).ready(function() {\r\n\t\t\t\$('#codigopres#').setMask('9.99.99.99.99.99');\r\n\t\t\t\$.post('{$link}',{ partida:'' },function(data){\r\n\t\t\t\tdatos=jQuery.parseJSON(data);\r\n\t\t\t\t\r\n\t\t\t\t\$('#codigopres').autocomplete({\r\n\t\t\t\t\tdelay: 0,\r\n\t\t\t\t\tminLength: 4,\r\n\t\t\t\t\tsource: datos,\r\n\t\t\t\t\tfocus: function( event, ui ) {\r\n\t\t\t\t\t\t\$( '#codigopres').val( ui.item.codigo );\r\n\t\t\t\t\t\t\$( '#denominacion').val( ui.item.denominacion );\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t},\r\n\t\t\t\t\tselect: function( event, ui ) {\r\n\t\t\t\t\t\t\$( '#codigopres').val( ui.item.codigo );\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t}\r\n\t\t\t\t})\r\n\t\t\t\t.data( 'autocomplete' )._renderItem = function( ul, item ) {\r\n\t\t\t\t\treturn \$( '<li></li>' )\r\n\t\t\t\t\t.data( 'item.autocomplete', item )\r\n\t\t\t\t\t.append( '<a>' +item.codigo+'-'+ item.denominacion + '</a>' )\r\n\t\t\t\t\t.appendTo( ul );\r\n\t\t\t\t};\r\n\t\t\t});\r\n\t\t});\r\n\t\t";
     $do = new DataObject("presusol");
     if ($status == "create" && !empty($fondo) && !empty($codigoadm) && !empty($codigopres)) {
         $keys = array("tipo" => $fondo, "codigoadm" => $codigoadm, "codigopres" => $codigopres);
         $do->load($keys);
     }
     $edit = new DataEdit("Presupuesto", $do);
     $edit->back_url = "presupuesto/presusol";
     $edit->post_process('update', '_post');
     $edit->post_process('insert', '_post');
     $edit->script($script, 'create');
     $edit->script($script, 'modify');
     $edit->codigoadm = new dropdownField("Estructura Administrativa", "codigoadm");
     $edit->codigoadm->options("SELECT codigo,CONCAT_WS(' ',codigo,denominacion) FROM estruadm WHERE LENGTH(codigo)=(SELECT LENGTH(valor) from valores WHERE nombre='FORMATOESTRU')");
     $edit->codigoadm->mode = "autohide";
     $edit->codigoadm->rule = "required";
     $edit->tipo = new dropdownField("Fuente de Financiamiento", "tipo");
     $edit->tipo->options("SELECT fondo, fondo AS val FROM fondo");
     $edit->tipo->style = 'width:150px;';
     $edit->tipo->mode = "autohide";
     $edit->tipo->rule = "required";
     $edit->codigopres = new inputField("C&oacute;digo Presupuesto", "codigopres");
     $edit->codigopres->db_name = "codigopres";
     $edit->codigopres->size = 20;
     $edit->codigopres->mode = "autohide";
     $edit->codigopres->rule = "required";
     $edit->denominacion = new textareaField("Denominacion", "denominacion");
     $edit->denominacion->rows = 2;
     $edit->denominacion->cols = 70;
     $edit->denominacion->rule = "required";
     $edit->asignacion = new inputField("Asignado", "asignacion");
     $edit->asignacion->size = 20;
     //$edit->asignacion->mode = "autohide";
     //$edit->asignacion->when = array("show");
     $edit->solicitado = new inputField("Solicitado", "solicitado");
     $edit->solicitado->size = 20;
     //$edit->solicitado->mode = "autohide";
     //$edit->solicitado->when = array("show");
     $edit->buttons("modify", "save", "undo", "delete", "back");
     $edit->build();
     $style = "\r\n\t\t.ui-autocomplete {\r\n\t\t  max-height: 250px;\r\n\t\t  overflow-y: auto;\r\n\t\t  max-width: 600px;\r\n\t\t}\r\n\t\t html.ui-autocomplete {\r\n\t\t  height: 250px;\r\n\t\t  width: 600px;\r\n\t\t}\r\n\t\t";
     $data['content'] = $edit->output;
     $data["style"] = $style;
     $data["head"] = script('jquery.js') . script('jquery-ui.js') . script('plugins/jquery.meiomask.js') . style('vino/jquery-ui.css') . $this->rapyd->get_head();
     $data['title'] = ' Presupuesto ';
     $this->load->view('view_ventanas', $data);
 }
Example #30
0
 function dataedit()
 {
     $this->rapyd->load('dataedit', 'datagrid');
     $script = '$(function() {$(".inputnum").numeric(".");});';
     $edit = new DataEdit(" ", 'crm_tipos');
     $edit->back_url = site_url('crm/tipos/index');
     $edit->script($script, 'create');
     $edit->script($script, 'modify');
     $edit->post_process('insert', '_post_insert');
     $edit->post_process('update', '_post_update');
     $edit->post_process('delete', '_post_delete');
     $edit->usuario = new autoUpdateField('usuario', $this->session->userdata('usuario'), $this->session->userdata('usuario'));
     $edit->definicion = new dropdownField("Definici&oacute;n", "definicion");
     $edit->definicion->option("", "Seleccione");
     $edit->definicion->options("SELECT id,nombre  FROM crm_definiciones ORDER BY nombre");
     $edit->definicion->rule = 'required';
     $edit->descrip = new inputField('Descripci&oacute;n', 'descrip');
     $edit->descrip->size = 50;
     $edit->descrip->maxlength = 200;
     $edit->descrip->rule = 'trim|strtoupper|required';
     $edit->buttons('modify', 'save', 'undo', 'delete', 'back');
     $edit->build();
     $data['content'] = $edit->output;
     $data['title'] = '<h1>Tipos</h1>';
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }