示例#1
0
 function wol()
 {
     if (!extension_loaded('sockets')) {
         show_error('La extension "sockets" no esta cargada, debe cargarla para poder usar estas opciones');
     }
     $this->load->library('rapyd');
     $this->rapyd->load('dataform');
     $form = new DataForm('supervisor/monitoreo/wol/process');
     $form->mac = new inputField('Dirección MAC', 'mac');
     $form->mac->append('Ejemplo: 00:01:02:03:04:05');
     $form->mac->rule = 'required|mac';
     $form->mac->maxlength = 17;
     $form->mac->size = 20;
     $form->submit('btnsubmit', 'Enviar');
     $form->build_form();
     if ($form->on_success()) {
         $mac = $form->mac->newValue;
         $rt = $this->_wol($mac);
         if (!$rt) {
             $form->error_string = $this->error;
             $form->build_form();
             $salida = $form->output . br();
         } else {
             $salida = $form->output . br() . 'Señal enviada satisfactoriamente';
         }
     } else {
         $salida = $form->output;
     }
     $this->rapyd->jquery[] = '$(".inputnum").numeric(".");';
     $data['content'] = $salida;
     $data['title'] = heading('Envio de señal de encendido por LAN');
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
示例#2
0
    public function testTimesAdded()
    {
        echo '<h3>Checking Times</h3>';
        $sql = 'SELECT `flighttime`
			  FROM ' . TABLE_PREFIX . 'pireps 
			  WHERE `accepted`=' . PIREP_ACCEPTED;
        $results = DB::get_results($sql);
        $this->added_time = 0;
        foreach ($results as $row) {
            $this->added_time = Util::AddTime($this->added_time, $row->flighttime);
        }
        heading('Time added, all PIREPS at once');
        $this->assertNotEqual(0, $this->added_time);
        heading('Time added, pilot by pilot');
        // Now calculate by PIREP
        $allpilots = PilotData::GetAllPilots();
        $total = 0;
        foreach ($allpilots as $pilot) {
            $p_hours = PilotData::getPilotHours($pilot->pilotid);
            $total = Util::AddTime($total, $p_hours);
        }
        $this->assertNotEqual(0, $total);
        heading('Comparing pilot to pilot vs all PIREPS');
        $this->assertEqual($total, $this->added_time);
        heading('Compare to STAT total hours');
        StatsData::UpdateTotalHours();
        $this->assertEqual($total, StatsData::TotalHours());
        echo '<br />';
    }
示例#3
0
 function predict($opponentCode)
 {
     $this->data['ResultsHeading'] = heading("Results", 2, 'class="text-center bg-danger"');
     //---- get PIT overall average and get PIT last 5 games average
     //Our Team
     $ourCode = "PIT";
     $steelersStandings = $this->teams->getFromCode($ourCode);
     $overallAvg = $steelersStandings->Pct1;
     //----end get PIT overall average and last 5 games
     $this->load->model('scores');
     $lastFive = $this->scores->getAvgLast5($ourCode);
     ///--------Predict our points
     $avgAgainstOpponent = $this->scores->getAvgLast5Opponent($ourCode, $opponentCode);
     if ($avgAgainstOpponent == 0) {
         $pointsUs = (0.7 * $overallAvg + 0.2 * $lastFive) / 0.9;
     } else {
         $pointsUs = 0.7 * $overallAvg + 0.2 * $lastFive + 0.1 * $avgAgainstOpponent;
     }
     $ourTeam = array('TeamName' => $ourCode, 'AveragePts' => $pointsUs);
     $this->data['OurTeamArray'] = $ourTeam;
     ///---------end Prediction for Our Team
     /////------------Predict Opponent points
     $opponentStandings = $this->teams->getFromCode($opponentCode);
     $overallOpponentAvg = $opponentStandings->Pct1;
     $lastFiveOpponent = $this->scores->getAvgLast5($opponentCode);
     //different when standings updated
     $avgAgainstUs = $this->scores->getAvgLast5Opponent($opponentCode, $ourCode);
     if ($avgAgainstUs == 0) {
         $pointsOpponent = (0.7 * $overallOpponentAvg + 0.2 * $lastFiveOpponent) / 0.9;
     } else {
         $pointsOpponent = 0.7 * $overallOpponentAvg + 0.2 * $lastFiveOpponent + 0.1 * $avgAgainstUs;
     }
     $opponent = array('TeamName' => $opponentCode, 'AveragePts' => $pointsOpponent);
     $this->data['OpponentArray'] = $opponent;
 }
示例#4
0
 function filteredgrid()
 {
     $this->pi18n->cargar('i18n', 'dataedit');
     $this->rapyd->load('datafilter', 'datagrid');
     $this->rapyd->uri->keep_persistence();
     $this->pi18n->msj('rifci', 'RIF o C.I.');
     $filter = new DataFilter('Filtro', 'i18n');
     $filter->modulo = new inputField('M&oacute;dulo', 'modulo');
     $filter->modulo->size = 20;
     $filter->buttons('reset', 'search');
     $filter->build();
     $uri = anchor('supervisor/i18n/dataedit/modify/<#id#>', '<#id#>');
     $grid = new DataGrid('Internacionalizaci&oacute;n');
     $grid->order_by('id', 'asc');
     $grid->per_page = 20;
     $grid->column_orderby('ID', $uri, 'id');
     $grid->column_orderby('Modulo', 'modulo', 'modulo');
     $grid->column_orderby('M&eacute;todo', 'metodo', 'metodo');
     $grid->column_orderby('Pa&iacute;s', 'pais', 'pais');
     $grid->column_orderby('Campo', 'campo', 'campo');
     $grid->add('supervisor/i18n/dataedit/create');
     $grid->build();
     $data['content'] = $filter->output . $grid->output;
     $data['content'] .= $this->pi18n->fallas();
     $data['title'] = heading('Internacionalizaci&oacute;n');
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
示例#5
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);
 }
示例#6
0
 function filteredgrid()
 {
     $this->rapyd->uri->keep_persistence();
     $this->rapyd->load('datafilter', 'datagrid');
     $filter = new DataFilter('', 'gpt_pro');
     $filter->parr = new inputField('Par&aacute;metro', 'parr');
     $filter->parr->rule = 'trim|required';
     $filter->parr->clause = '';
     //$filter->submit = new submitField('Buscar', 'submitbtn');
     //$filter->submit->in='parr';
     $filter->buttons('reset', 'search');
     $filter->build();
     $uri = anchor($this->url . 'dataedit/show/<raencode><#id_pro#></raencode>', '<#nom_pro#>', 'target="framedetrepo" onclick="$(\'#cajafiltro\').hide();"');
     //$uri = anchor($this->url.'dataedit/show/<raencode><#id_pro#></raencode>','<#nom_pro#>');
     $grid = new DataGrid('Especialidades farmaceuticas');
     if (strlen($filter->parr->newValue) > 0) {
         $dbparr = $this->db->escape($filter->parr->newValue);
         $grid->db->where('MATCH(nom_pro,pres_pro,lab_pro,gen_pro,mono_pro) AGAINST (' . $dbparr . ')');
     }
     $grid->order_by('nom_pro');
     $grid->per_page = 15;
     $grid->column_orderby('Nombre', $uri, 'nom_pro', 'align="left"');
     $grid->column_orderby('Presentaci&oacute;n', 'pres_pro', 'pres_pro', 'align="left"');
     $grid->column_orderby('Laboratorio', 'lab_pro', 'lab_pro', 'align="left"');
     //$grid->column_orderby('Cod. Pro','cod_pro','cod_pro','align="left"');
     //$grid->column_orderby('Gen. Pro','gen_pro','gen_pro','align="left"');
     $grid->build();
     $data['filtro'] = $filter->output . $grid->output;
     $data['content'] = '<script type="text/javascript"> $(function(){ $("#cajafiltro").show(); }); </script>';
     //$data['content'].= $acti->output;
     $data['content'] .= '<IFRAME src="' . site_url('farmacia/gpt_pro/dummy') . '" width="100%" height="500" scrolling="auto" frameborder="0" name="framedetrepo">iframe no son soportados</IFRAME>';
     $data['head'] = $this->rapyd->get_head() . script('jquery.js') . script('jquery.highlight.js');
     $data['title'] = heading($this->titp);
     $this->load->view('view_ventanas', $data);
 }
示例#7
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);
 }
示例#8
0
文件: install.php 项目: nyfagel/klubb
 /**
  * database function.
  * 
  * @access public
  * @return void
  */
 public function database()
 {
     $this->output->enable_profiler(true);
     $this->load->database();
     $this->load->dbutil();
     $this->load->dbforge();
     $data['title'] = $this->system_model->get('app_name');
     $data['breadcrumbs'] = array(array('data' => anchor('/', $this->system_model->get('app_name')), 'mode' => 'unavailable'), array('data' => anchor('install', ucfirst(lang('install'))), 'mode' => 'unavailable'), array('data' => anchor('install/database', ucfirst(lang('install') . ' ' . lang('database'))), 'mode' => 'current'));
     $html = heading(ucfirst(lang('install')) . ' ' . lang('database'), 1);
     $current = $this->migration->current();
     if (is_null($current)) {
         $html .= div($this->migration->error_string(), 'alert-box error');
     } else {
         $html .= div('Klubb database version: ' . $current, 'alert-box success');
     }
     $tables = $this->db->list_tables();
     foreach ($tables as $table) {
         $fields = $this->db->list_fields($table);
         array_unshift($fields, strong('Fält:'));
         $fields = ul($fields, array('class' => 'inline-list'));
         $html .= div(heading('Tabell: ' . $table, 4) . $fields, 'radius panel');
     }
     $data['html'] = $html;
     $this->system_model->view('template', $data);
 }
示例#9
0
 function index()
 {
     $this->rapyd->load('dataform');
     $filter = new dataForm('buscador/index/procesar');
     $filter->valor = new inputField('Valor', 'valor');
     $filter->valor->rule = 'required';
     $filter->valor->size = 20;
     $filter->submit('btnsubmit', 'Buscar');
     $filter->build_form();
     $sal = '';
     if ($filter->on_success()) {
         $this->load->library('table');
         $this->table->set_heading('Tabla', 'Campo', 'Coincidencias');
         $valor = $this->db->escape($filter->valor->newValue);
         $tables = $this->db->list_tables();
         foreach ($tables as $table) {
             $fields = $this->db->list_fields($table);
             foreach ($fields as $field) {
                 $mSQL = "SELECT COUNT(*) AS cana FROM `{$table}` WHERE `" . $field . "` = {$valor}";
                 $cana = $this->datasis->dameval($mSQL);
                 if ($cana > 0) {
                     $this->table->add_row($table, $field, $cana);
                 }
             }
         }
         $sal = $this->table->generate();
     }
     $data['content'] = $filter->output . $sal;
     $data['title'] = heading('Busca un valor en toda la base de datos');
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
示例#10
0
 function filteredgrid()
 {
     $this->rapyd->load('dataform', 'datagrid');
     $this->load->library('encrypt');
     $filter = new DataForm('ejecutasql/filteredgrid/process');
     $filter->sql = new textareaField('', 'sql');
     $filter->sql->cols = 90;
     $filter->sql->rows = 9;
     $filter->sql->rule = 'required';
     $filter->submit('btnsubmit', 'Ejecutar');
     $filter->build_form();
     $salida = '';
     if ($filter->on_success()) {
         $data = array();
         $mSQL = $filter->sql->value;
         $link = @mysql_connect($this->db->hostname, $this->db->username, $this->db->password) or die('Error de coneccion');
         mysql_select_db($this->db->database, $link) or die('Base de datos no seleccionable');
         $result = mysql_query($mSQL, $link);
         if (!$result) {
             $salida = mysql_errno($link) . ": " . mysql_error($link);
         } else {
             if (is_resource($result)) {
                 $num_rows = mysql_num_rows($result);
                 $afectados = 0;
             } elseif (is_bool($result)) {
                 $num_rows = 0;
                 $afectados = mysql_affected_rows();
             } else {
                 $num_rows = 0;
                 $afectados = 0;
             }
             if ($num_rows > 0) {
                 $colunas = mysql_num_fields($result);
                 while ($row = mysql_fetch_assoc($result)) {
                     $data[] = $row;
                 }
                 $grid = new DataGrid("Filas : {$num_rows}, Columnas : {$colunas} ,Afectados :{$afectados}", $data);
                 $grid->per_page = 100000;
                 foreach ($data[0] as $campos => $value) {
                     $grid->column($campos, $campos);
                 }
                 $grid->build();
                 $salida = $grid->output;
                 if (stristr($mSQL, 'SELECT')) {
                     $mSQL2 = $this->encrypt->encode($mSQL);
                     $salida .= "<form action='/../../proteoerp/xlsauto/repoauto2/'; method='post'>\n \t\t\t\t\t\t<input size='100' type='hidden' name='mSQL' value='{$mSQL2}'>\n \t\t\t\t\t\t<input type='submit' value='Descargar a Excel' name='boton'/>\n \t\t\t\t\t\t</form>";
                 }
             } elseif ($afectados > 0) {
                 $salida = "Filas afectadas {$afectados}";
             } else {
                 $salida = 'Esta consulta no genero resultados';
             }
         }
     }
     $data['content'] = $filter->output . $salida;
     $data['title'] = heading('Consulta SQL');
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
示例#11
0
function heading_nb_level2($l1tag, $l1url, $l2tag, $l2url)
{
    global $site, $siteuri;
    echo "<a href='{$siteuri}'>";
    heading($site . " &lt; " . $l1tag . " &lt; " . $l2tag);
    nb_top();
    nb_level2($l1tag, $l1url, $l2tag, $l2url);
}
示例#12
0
文件: docs.php 项目: gruner/doozer
function print_logr()
{
    global $env, $logr;
    if ($env == 'test') {
        heading('Log');
        print_r($logr);
    }
}
示例#13
0
 function index()
 {
     $this->rapyd->load('dataform', 'datatable', 'datagrid');
     $this->load->library('table');
     $base_process_uri = $this->rapyd->uri->implode_uri("base_uri", "gfid", "orderby");
     $filter = new DataForm($this->rapyd->uri->add_clause($base_process_uri, "search"));
     $filter->title('Elija una tabla');
     $filter->attributes = array('onsubmit' => 'is_loaded()');
     $filter->tabla = new dropdownField("Tabla", "tabla");
     $filter->tabla->option("pers", "Personal");
     $filter->tabla->option("nomina", "Nomina");
     $filter->tabla->option("sprv", "Proveedores");
     $filter->tabla->option("abonotros", "Abono Otros");
     $filter->tabla->clause = "";
     //$filter->obra = new dropdownField("Obra", "depto");
     //$filter->obra->db_name='depto';
     //$filter->obra->clause="where";
     //$filter->obra->option(" ","Todos");
     //$filter->obra->options("SELECT depto, descrip FROM dpto ORDER BY depto ");
     //$filter->obra->operator="=";
     //$filter->status = new dropdownField("Status","status");
     //$filter->status->option("","Todos");
     //$filter->status->option("A","Activos");
     //$filter->status->option("I","Inactivos");
     //$filter->status->style='width:100px';
     $filter->submit('btnsubmit', 'Descargar');
     $filter->build_form();
     if ($this->rapyd->uri->is_set("search")) {
         $table = $filter->tabla->newValue;
         $mSQL = "DESCRIBE {$table}";
         $query = $this->db->query($mSQL);
         if ($query->num_rows() > 0) {
             foreach ($query->result_array() as $row) {
                 $data[] = $row;
             }
         }
         function ractivo($field)
         {
             $data2 = array('name' => 'campos[]', 'id' => 'c' . $field, 'value' => $field, 'checked' => FALSE, 'style' => 'margin:5px');
             $retorna = form_checkbox($data2);
             return $retorna;
         }
         $grid = new DataGrid("Resultados", $data);
         $grid->use_function('ractivo', 'ucwords');
         $grid->column('Campos', '<ucwords><#Field#></ucwords>');
         $grid->column('Mostrar', "<ractivo><#Field#></ractivo>", 'align="center"');
         $grid->build();
         $tabla = $grid->output;
         $filter->build_form();
         $conten = $filter->output . form_open("nomina/rpers/crear/{$table}") . $tabla . form_submit('mysubmit', 'Generar') . form_close();
     } else {
         $conten = $filter->output;
     }
     $data['content'] = $conten;
     $data['title'] = heading('Reporte');
     $data["head"] = script("jquery.js") . $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
示例#14
0
 function index()
 {
     $data = array();
     $data['header'] = '';
     $data['content'] = $this->load->view('view_verificador', $data, true);
     $data['footer'] = '';
     $data['script'] = script('jquery-min.js');
     $data['script'] .= phpscript('nformat.js');
     $data['script'] .= script('jquery.bootgrid.min.js');
     $data['style'] = style('jquery.bootgrid.min.css');
     $data['panel'] = '';
     $data['title'] = heading('Verificador de precios');
     $this->load->view('view_ventanasjq', $data);
     /*
     		// Filter grid
     		$this->rapyd->load('datafilter','datagrid');
     		$filter = new DataFilter('Consulta de Precios', 'sinv');
     
     		$filter->Descripcion = new inputField('Descripcion','decrip');
     		$filter->clave->rule      ='max_length[50]';
     		$filter->clave->size      =7;
     		$filter->clave->maxlength =5;
     
     		$filter->marca = new inputField('Marca','marca');
     		$filter->marca->rule      ='max_length[30]';
     		$filter->marca->size      =32;
     		$filter->marca->maxlength =30;
     
     		$filter->buttons('reset', 'search');
     		$filter->build();
     
     		$uri = anchor($this->url.'dataedit/show/<raencode><#id#></raencode>','<#id#>');
     
     		$grid = new DataGrid('');
     		$grid->db->select('codigo', 'descrip','unidad','base1','precio1-base1 iva','precio1');
     		$grid->db->order_by('codigo');
     
     		$grid->db->order_by('codigo');
     		$grid->per_page = 40;
     
     		$grid->column_orderby('C&oacute;digo'   ,'codigo'  ,'codigo',  'align="left"');
     		$grid->column_orderby('Descripcion'     ,'nombre'  ,'descrip', 'align="left"');
     		$grid->column_orderby('Medida'          ,'unidad'  ,'unidad',  'align="left"');
     		$grid->column_orderby('Precio'          ,'base1'   ,'base1',   'align="right"');
     		$grid->column_orderby('I.V.A.'          ,'iva'     ,'iva',     'align="right"');
     		$grid->column_orderby('Precio de Venta' ,'precio1' ,'precio1', 'align="right"');
     
     		$grid->add($this->url.'dataedit/create');
     		$grid->build();
     
     		$data['filtro']  = $filter->output;
     		$data['content'] = $grid->output;
     		$data['head']    = $this->rapyd->get_head().script('jquery.min.js');
     		$data['title']   = heading($this->titp);
     		$this->load->view('view_ventanas', $data);
     */
 }
示例#15
0
 public function testFindSchedules()
 {
     heading('findSchedules');
     $data = SchedulesData::findSchedules(array());
     $this->assertNotEqual($data, false);
     heading('Find disabled schedules');
     $data = SchedulesData::findSchedules(array('s.enabled' => 0));
     $this->assertNotEqual($data, false);
 }
示例#16
0
 public function test_heading_object_attributes()
 {
     // Test array of attributes
     $this->assertEquals('<h2 class="bar" id="foo">foobar</h2>', heading('foobar', 2, array('class' => 'bar', 'id' => 'foo')));
     $test = new stdClass();
     $test->class = "bar";
     $test->id = "foo";
     $this->assertEquals('<h2 class="bar" id="foo">foobar</h2>', heading('foobar', 2, $test));
 }
示例#17
0
function motd()
{
    $motd = join('', file(MOTD_FILE));
    $stat = stat(MOTD_FILE);
    $mtime = $stat['mtime'];
    if ($mtime > time() - 60 * 60 * 24 * 7 and trim($motd)) {
        return heading(2, "Message of the Day") . "<blockquote>" . wiki_render(date('M d, Y @ H:i', $mtime) . "\n\n" . $motd) . "</blockquote>";
    }
}
示例#18
0
文件: home.php 项目: nyfagel/klubb
 /**
  * index function.
  * 
  * @access public
  * @return void
  */
 public function index()
 {
     $this->output->enable_profiler(false);
     $this->benchmark->mark('auth_start');
     if (!$this->auth->loggedin()) {
         redirect('user/login');
     }
     $uid = intval($this->auth->userid());
     $this->benchmark->mark('auth_end');
     $user = $this->user_model->get_user($uid);
     $greeting = '';
     if (isset($user['firstname'])) {
         $greeting = ' ' . $user['firstname'];
         $data['firstname'] = $user['firstname'];
     } else {
         $greeting = ' ' . $user['username'];
         $data['firstname'] = $user['firstname'];
     }
     $data['title'] = $this->system_model->get('app_name');
     $data['stylesheets'] = array('buttons_purple');
     $data['partial'] = 'home';
     $data['org_name'] = $this->system_model->get('org_name');
     $data['app_name'] = $this->system_model->get('app_name');
     $data['members'] = $this->member_model->count_members();
     $data['users'] = $this->user_model->count_users();
     $memberdata = heading(ucfirst(lang('members')), 5);
     $ofeachtype = array();
     $this->benchmark->mark('members_process_start');
     foreach ($this->member_model->get_types() as $type) {
         $count = $this->member_model->count_members_type($type['id']);
         array_push($ofeachtype, $count . ' ' . strtolower($type['plural']));
     }
     $data['membertypes'] = $ofeachtype;
     $memberdata .= p(ucfirst($data['org_name']) . ' har totalt ' . anchor('members', $data['members'] . ' ' . lang('members')) . ' varav:');
     $memberdata .= ul($data['membertypes'], array('class' => 'disc'));
     $memberdata .= button_group(array(button_anchor('members', ucfirst(lang('administer')) . ' ' . lang('members'), 'radius'), button_anchor('member/register', ucfirst(lang('register_member')), 'radius')), 'radius');
     $this->benchmark->mark('members_process_end');
     $userdata = heading(ucfirst(lang('users')), 5);
     $this->benchmark->mark('users_process_start');
     $userdata .= p(ucfirst($data['app_name']) . ' har totalt ' . anchor('admin/users', $data['users'] . ' ' . lang('users')) . '.');
     $active = $this->user_model->get_active();
     $ausers = array();
     foreach ($active as $aid) {
         $auser = $this->user_model->get_user($aid);
         array_push($ausers, $auser['firstname'] . ' ' . $auser['lastname']);
     }
     $data['loggedon'] = $ausers;
     $userdata .= heading(ucfirst(lang('currently_logged_on')) . ':', 6) . ul($ausers, array('class' => 'disc'));
     $userdata .= button_group(array(button_anchor('admin/users', ucfirst(lang('administer')) . ' ' . lang('users'), 'radius'), button_anchor('user/create', ucfirst(lang('create_user')), 'radius')), 'radius');
     $this->benchmark->mark('users_process_end');
     $content = heading(ucfirst(lang('welcome')) . $greeting . '!', 1);
     $content .= row(columns($memberdata, 6) . columns($userdata, 6));
     $html = $content;
     $data['html'] = $html;
     $this->system_model->view('template', $data);
 }
示例#19
0
 function index()
 {
     $this->rapyd->load('datatable', 'dataform');
     $form = new DataForm('supermercado/cargahisto/index/process');
     $form->title('Este modulo permite cargar manual las ventas sacadas de los historicos de las cajas');
     $form->fecha = new dateonlyField('Fecha', 'fecha', 'd/m/Y');
     $form->fecha->db_format = 'Ymd';
     $form->fecha->insertValue = date('Y-m-d');
     $form->fecha->size = 11;
     $form->fecha->autocomplete = false;
     $form->fecha->rule = 'required|chfecha';
     $form->hf = new uploadField('Facturas (<b>hf</b>YYYYMMCCCAAA.dbf)', 'hf');
     $form->hf->upload_path = 'tmp';
     $form->hf->upload_root = '/';
     $form->hf->rule = 'required';
     $form->hf->allowed_types = 'csv|dbf';
     $form->hi = new uploadField('Art&iacute;culos (<b>hi</b>YYYYMMCCCAAA.dbf)', 'hi');
     $form->hi->upload_path = 'tmp';
     $form->hi->upload_root = '/';
     $form->hi->rule = 'required';
     $form->hi->allowed_types = 'csv|dbf';
     $form->hs = new uploadField('Pagos (<b>hs</b>YYYYMMCCCAAA.dbf)', 'hs');
     $form->hs->upload_path = 'tmp';
     $form->hs->upload_root = '/';
     $form->hs->rule = 'required';
     $form->hs->allowed_types = 'csv|dbf';
     $form->submit('btnsubmit', 'Procesar');
     $form->build_form();
     if ($form->on_success()) {
         $fecha = $form->fecha->newValue;
         $encab = false;
         if (!empty($form->hf->upload_data['full_path'])) {
             if (substr($form->hf->upload_data['file_name'], 0, 2) == 'hf') {
                 $encab = true;
                 $this->_cargadbf($form->hf->upload_data['full_path'], $fecha);
                 unlink($form->hf->upload_data['full_path']);
             } else {
                 $form->error = 'Encabezado primero';
                 $form->build_form();
             }
         }
         if (!empty($form->hi->upload_data['full_path']) && $encab) {
             $this->_cargadbf($form->hi->upload_data['full_path'], $fecha);
             unlink($form->hi->upload_data['full_path']);
         }
         if (!empty($form->hs->upload_data['full_path']) && $encab) {
             $this->_cargadbf($form->hs->upload_data['full_path'], $fecha);
             unlink($form->hs->upload_data['full_path']);
         }
     }
     $data['content'] = $form->output;
     $data['title'] = heading('Cargar ventas de los hist&oacute;ricos de cajas');
     $data['script'] = script('jquery-1.2.6.js');
     $data['head'] = $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
示例#20
0
 function index()
 {
     $data = array();
     $data['header'] = '';
     $data['content'] = $this->load->view('view_lprecios', $data, true);
     $data['footer'] = '';
     $data['script'] = '';
     $data['panel'] = '';
     $data['title'] = heading('Consulta de precios');
     $this->load->view('view_ventanasjqm', $data);
 }
示例#21
0
 function index()
 {
     $data = array();
     $data['header'] = '';
     $data['content'] = $this->load->view('view_sfacmovil', $data, true);
     $data['footer'] = '';
     $data['script'] = '';
     $data['panel'] = '';
     $data['title'] = heading('Pre-factura');
     $this->load->view('view_ventanasjqm', $data);
 }
示例#22
0
 function index()
 {
     $this->rapyd->load('dataform');
     $this->rapyd->load('datagrid2');
     $this->load->library('encrypt');
     function dif($a, $b)
     {
         return number_format($a - $b, 2, ',', '.');
     }
     $form = new DataForm('supermercado/conciliacion/index/process');
     $form->fechad = new dateonlyField('Desde', 'fechad', 'd/m/Y');
     $form->fechad->insertValue = date('Y-m-d', mktime(0, 0, 0, date("m"), date("d") - 30, date("Y")));
     $form->fechad->rule = 'required';
     $form->fechah = new dateonlyField('Hasta', 'fechah', 'd/m/Y');
     $form->fechah->insertValue = date('Y-m-d');
     $form->fechah->rule = 'required';
     $form->submit('btnsubmit', 'Buscar');
     $form->build_form();
     $tabla = '';
     if ($form->on_success()) {
         $fechad = $form->fechad->newValue;
         $fechah = $form->fechah->newValue;
         //$mSQL="SELECT 'PV' ,caja,SUM(gtotal*IF(MID(numero,1,2)='NC',-1,1)) FROM viefac WHERE fecha BETWEEN '$fechad' AND '$fechah' GROUP BY caja UNION
         //SELECT 'PV' ,'MAYO',SUM(gtotal*IF(tipo='D',-1,1)) FROM fmay WHERE fecha BETWEEN '$fechad' AND '$fechah' UNION
         //SELECT 'CZ' ,caja,SUM(exento+base+iva+base1+iva1+base2+iva2-ncexento-ncbase-nciva-ncbase1-nciva1-ncbase2-nciva2) FROM fiscalz WHERE fecha BETWEEN '$fechad' AND '$fechah' GROUP BY caja";
         $mSQL = "SELECT a.fecha, a.caja, sum(a.gtotal*if(MID(a.numero,1,2)='NC',-1,1)) AS factura,\n\t\t\t(SELECT sum(exento+base+iva-ncexento-ncbase-nciva) venta FROM fiscalz c WHERE c.fecha=a.fecha AND c.caja=a.caja ) AS  cierrez,\n\t\t\t(SELECT sum(exento+base+iva-ncexento-ncbase-nciva) venta FROM fiscalz c WHERE c.fecha=a.fecha AND c.caja=a.caja )-\n\t\t\tsum(a.gtotal*if(MID(a.numero,1,2)='NC',-1,1)) AS dife\n\t\t\tFROM viefac a\n\t\t\tWHERE a.fecha BETWEEN '{$fechad}' AND '{$fechah}' GROUP BY a.fecha, a.caja ORDER BY a.caja,a.fecha";
         $grid = new DataGrid2('Res&uacute;men');
         $grid->db->_escape_char = '';
         $grid->db->_protect_identifiers = false;
         //$grid->per_page = 20;
         $grid->use_function('dif');
         $select = array('a.fecha', 'b.caja', '(SELECT sum(exento+base+iva+base1+iva1+base2+iva2-ncexento-ncbase-nciva-ncbase1-nciva1-ncbase2-nciva2) FROM fiscalz c WHERE c.fecha=a.fecha AND c.caja=b.caja) AS cierrez', '(SELECT sum(d.gtotal) FROM viefac AS d WHERE  d.fecha=a.fecha AND d.caja=b.caja) AS factura');
         $grid->db->select($select);
         $grid->db->from('tiempo AS a');
         $grid->db->join("caja AS b", "a.fecha BETWEEN '{$fechad}' AND '{$fechah}'");
         $grid->db->orderby("caja,fecha");
         $grid->db->having("cierrez IS NOT null OR factura IS NOT null");
         $grid->column("Fecha", "<dbdate_to_human><#fecha#></dbdate_to_human>", "align='center'");
         $grid->column("Caja", "caja", 'align=center');
         $grid->column("Factura", "<nformat><#factura#></nformat>", 'align=right');
         $grid->column("Cierre Z", "<nformat><#cierrez#></nformat>", 'align=right');
         $grid->column("Diferencia", "<dif><#factura#>|<#cierrez#></dif>", 'align=right');
         $grid->totalizar('factura', 'cierrez');
         $grid->build();
         //echo $grid->db->last_query();
         $tabla = $grid->output;
     }
     $reporte = anchor('reportes/ver/CONCILIACI', 'Imprimir');
     $data['content'] = $form->output . $reporte . $tabla;
     $data["head"] = script("jquery.pack.js") . script("plugins/jquery.numeric.pack.js") . script("plugins/jquery.floatnumber.js") . $this->rapyd->get_head();
     $data['title'] = heading('Concialiaciones de Cierre Z');
     $this->load->view('view_ventanas', $data);
 }
示例#23
0
 function filteredgrid()
 {
     $this->rapyd->load('datafilter', 'datagrid');
     $filter = new DataFilter($this->titp);
     $filter->db->from('caudi AS a');
     $filter->db->join('usuario AS b', 'a.uscaja = b.us_codigo');
     $filter->caja = new dropdownField('Caja', 'caja');
     $filter->caja->style = 'width:200px';
     $filter->caja->option('', 'Todos');
     $filter->caja->options("SELECT codbanc,CONCAT_WS('-',codbanc,banco) AS val FROM banc WHERE tbanco = 'CAJ' ORDER BY banco");
     $filter->uscaja = new dropdownField('Responsable', 'uscaja');
     $filter->uscaja->style = 'width:200px';
     $filter->uscaja->option('', 'Todos');
     $filter->uscaja->options("SELECT us_codigo,us_nombre FROM usuario ORDER BY us_nombre");
     $filter->status = new dropdownField('Estatus', 'status');
     $filter->status->style = 'width:200px';
     $filter->status->option('', 'Todos');
     $filter->status->option('P', 'Pendientes');
     $filter->status->option('A', 'Anulados');
     $filter->status->option('C', 'Cerrados');
     $filter->observa = new inputField('Observaci&oacute;n', 'observa');
     $filter->buttons('reset', 'search');
     $filter->build();
     $uri = anchor($this->url . '/auditoria/<raencode><#caja#></raencode>', '<str_pad><#id#>|10|0|0</str_pad>');
     function status($sto)
     {
         if ($sto == 'P') {
             return 'Pendiente';
         } elseif ($sto == 'A') {
             return 'Anulado';
         } else {
             return 'Cerrado';
         }
     }
     $grid = new DataGrid('');
     $grid->use_function('str_pad', 'status');
     $grid->order_by('id');
     $grid->per_page = 40;
     $grid->column_orderby('N&uacute;mero', $uri, 'id', 'align="left"');
     $grid->column_orderby('Caja', 'caja', 'caja', 'align="left"');
     $grid->column_orderby('Responsable', '<#uscaja#>-<#us_nombre#>', 'uscaja', 'align="left"');
     $grid->column_orderby('Estatus', '<status><#status#></status>', 'status', 'align="left"');
     $grid->column_orderby('Saldo', '<nformat><#saldo#></nformat>', 'saldo', 'align="right"');
     $grid->column_orderby('Monto', '<nformat><#monto#></nformat>', 'monto', 'align="right"');
     $grid->column_orderby('Diferencia', '<nformat><#diferencia#></nformat>', 'diferencia', 'align="right"');
     $grid->add($this->url . '/agregar');
     $grid->build();
     $data['filtro'] = $filter->output;
     $data['content'] = $grid->output;
     $data['head'] = $this->rapyd->get_head() . script('jquery.js');
     $data['title'] = heading($this->titp);
     $this->load->view('view_ventanas', $data);
 }
示例#24
0
 function filteredgrid($barras = '', $farmacia = '')
 {
     $this->rapyd->load('datafilter', 'datagrid');
     $modbus = array('tabla' => 'sinv', 'columnas' => array('codigo' => 'C&oacute;digo', 'barras' => 'Barras', 'descrip' => 'Descripci&oacute;n', 'precio1' => 'Precio 1', 'precio2' => 'Precio 2', 'precio3' => 'Precio 3', 'precio4' => 'Precio 4'), 'filtro' => array('codigo' => 'C&oacute;digo', 'barras' => 'Barras', 'descrip' => 'Descripci&oacute;n'), 'retornar' => array('barras' => 'barras'), 'titulo' => 'Buscar en inventario', 'dbgroup' => 'consolidado');
     $boton = $this->datasis->modbus($modbus);
     $barrase = $this->db->escape($barras);
     $sql = "\n\t\tSELECT fecha,fe,fa,descrip,venta,compras,saldo,semanal FROM (\n\t\tselect '' fe,farmacia fa,fecha,farmacia,descrip,venta,compras,saldo,(venta/4)  semanal\n\t\tfrom  vieventascompras \n\t\twhere barras={$barrase} AND farmacia is not null\n\t\tUNION ALL\n\t\tselect '','',fecha,farmacia,'TOTALES',SUM(venta),SUM(compras),SUM(saldo),(venta/4)  semanal \n\t\tfrom  vieventascompras \n\t\twhere barras={$barrase} AND farmacia is not null\n\t\tGROUP BY fecha with rollup\n\t\tUNION ALL\n\t\tselect CONCAT(MID(fecha,1,4),'-',MID(fecha,5,5)) fe,'',fecha,farmacia,'','','','','' \n\t\tfrom  vieventascompras \n\t\twhere barras={$barrase} AND farmacia is not null\n\t\tGROUP BY fecha \n\t\t)todo\n\t\tORDER BY fecha is null,fecha ,fe='',descrip='TOTALES',farmacia\n\t\t";
     $atts = array('width' => '800', 'height' => '600', 'scrollbars' => 'yes', 'status' => 'yes', 'resizable' => 'yes', 'screenx' => '0', 'screeny' => '0');
     $descrip = $this->datasis->dameval("SELECT descrip FROM sinv WHERE barras={$barrase} LIMIT 10 ");
     $uri = anchor_popup($this->url . "kardex/{$barras}/<#fa#>/<#fecha#>", '<#fa#>', $atts);
     $sql = $this->db->query($sql);
     $sql = $sql->result_array();
     function negrita($descrip, $fecha = NULL)
     {
         if ($descrip == 'TOTALES' && !(strlen($fecha) > 0)) {
             return "<span style='font-size:1.5em'><strong>TOTAL GENERAL</strong></span>";
         } elseif ($descrip == 'TOTALES') {
             return "<span style='font-size:1.2em'><strong>TOTALES</strong></span>";
         } else {
             return $descrip;
         }
     }
     function negrita2($descrip, $monto)
     {
         if ($descrip == 'TOTALES') {
             return "<span style='font-size:1.2em'><strong>" . nformat($monto) . "</strong></span>";
         } elseif (strlen($monto) > 0) {
             return nformat($monto);
         } else {
             return '';
         }
     }
     $grid = new DataGrid(anchor($this->url . 'viewinventario', 'Ir al Inventario por sucursales'), $sql);
     $grid->db->_escape_char = '';
     $grid->db->_protect_identifiers = false;
     $grid->use_function('negrita', 'negrita2');
     //$grid->column_orderby('Barras'            ,$uri                                           ,'align="left"'  );
     $grid->column('A&ntilde;o/Mes', "fe", 'align="center"');
     $grid->column('Farmacia', $uri, 'align="left"');
     $grid->column('Descripci&oacute;n', "<negrita><#descrip#>|<#fecha#></negrita>", 'align="left"');
     $grid->column('Mensual', "<negrita2><#descrip#>|<#venta#></negrita2>", 'align="right"');
     $grid->column('Semanal', "<negrita2><#descrip#>|<#semanal#></negrita2>", 'align="right"');
     $grid->column('Compras', "<negrita2><#descrip#>|<#compras#></negrita2>", 'align="right"');
     $grid->column('Saldo', "<negrita2><#descrip#>|<#saldo#></negrita2>", 'align="right"');
     $grid->build();
     //echo $grid->db->last_query();
     //$data['filtro']  = $filter->output;
     $data['content'] = $grid->output;
     $data['head'] = $this->rapyd->get_head() . script('jquery.js');
     $data['title'] = heading($descrip);
     $this->load->view('view_ventanas', $data);
 }
示例#25
0
 function anuales()
 {
     $this->rapyd->load('datagrid2');
     $this->rapyd->load('dataform');
     $this->load->helper('openflash');
     if ($this->uri->segment(4)) {
         $anio = $this->uri->segment(4);
     } elseif (isset($_POST['anio'])) {
         $anio = $_POST['anio'];
     }
     if (empty($anio)) {
         $anio = date("Y");
     }
     $fechai = $anio . '0101';
     $fechaf = $anio . '1231';
     $filter = new DataForm('compras/proveedores/anuales');
     $filter->title('Filtro de compras Anuales');
     $filter->anio = new inputField('A&ntilde;o', 'anio');
     $filter->anio->size = 4;
     $filter->anio->insertValue = $anio;
     $filter->anio->rule = 'max_length[4]';
     $filter->button('btnsubmit', 'Buscar', form2uri(site_url('compras/proveedores/anuales'), array('anio')), $position = "BL");
     $filter->build_form();
     $grid = new DataGrid2();
     $select = array('proveed', 'fecha', 'nombre', "SUM(montonet*IF(tipo_doc!='FC',-1,1)) AS grantotal", 'MONTH(fecha) AS mes', "SUM(inicial*IF( tipo_doc!='FC',-1,1)) AS contado", "SUM(credito*IF( tipo_doc!='FC',-1,1)) AS credito", "SUM(montotot*IF(tipo_doc!='FC',-1,1)) AS subtotal", "SUM(montoiva*IF(tipo_doc!='FC',-1,1)) AS impuesto", 'COUNT(*) AS numfac');
     $grid->db->select($select);
     $grid->db->from('scst');
     $grid->db->where('tipo_doc <>', 'NE');
     $grid->db->where('fecha >= ', $fechai);
     $grid->db->where('fecha <= ', $fechaf);
     $grid->db->where('actuali >= fecha');
     $grid->db->groupby('proveed');
     $grid->db->orderby('grantotal DESC');
     $grid->per_page = 15;
     //$grid->db->limit(15,0);
     $grid->column('Proveedor', 'nombre', 'align=\'left\'');
     $grid->column('Sub-Total', '<nformat><#subtotal#>|2</nformat>', 'align=\'right\'');
     $grid->column('Impuesto', '<nformat><#impuesto#>|2</nformat>', 'align=\'right\'');
     $grid->column('Total', '<nformat><#grantotal#>|2</nformat>', 'align=\'right\'');
     $grid->column('Contado', '<nformat><#contado#>|2</nformat>', 'align=\'right\'');
     $grid->column('Credito', '<nformat><#credito#>|2</nformat>', 'align=\'right\'');
     $grid->column('Cant. Fact', 'numfac', 'align=\'right\'');
     $grid->totalizar('impuesto', 'grantotal', 'contado', 'credito', 'subtotal');
     $grid->build();
     $grafico = open_flash_chart_object(700, 450, site_url("compras/proveedores/ganuales/{$anio}/"));
     $data['content'] = $grafico;
     $data['content'] .= $filter->output . $grid->output;
     $data['head'] = $this->rapyd->get_head();
     $data['title'] = heading('Compras Anuales');
     $this->load->view('view_ventanas', $data);
 }
示例#26
0
 public function index()
 {
     $data["title"] = heading("List of Product", 3);
     $data["products"] = $this->Products_model->showAllProducts();
     $this->load->view("view_products", $data);
     //var_dump($data->result_array());
     //$data2->ProductsName;
     //$x ='<ol>';
     //foreach ($data->result() as $row){
     //	$x .='<li>' .$row->ProductName. '</li>';
     //}
     //$x .= '</ol>';
     //echo $x;
 }
示例#27
0
文件: forget.php 项目: ummoy/invoice
 public function check_email()
 {
     if ($this->input->post('recovery_submit')) {
         $email = $this->input->post('reset_email');
         //echo $email;
         $this->load->model('forget_password_model');
         $info = $this->forget_password_model->exist_email($email);
         if (count($info) != 0) {
             //echo "here";
             $this->load->helper('html');
             $this->load->library('email');
             $this->load->library('session');
             $newdata = array('email' => $email);
             $this->session->set_userdata($newdata);
             //$this->session->set_userdata($email);
             //$config['protocol'] = 'mail';$this->email->initialize($config);
             $tmp_password = $this->forget_password_model->update_tmp_password($email);
             //echo $tmp_password;
             $config = array('protocol' => 'smtp', 'smtp_host' => 'ssl://orange.whitelabelwebserver.com', 'smtp_port' => 465, 'smtp_user' => '*****@*****.**', 'smtp_pass' => 'Q^F{ke_&xk(}', 'mailtype' => 'html', 'charset' => 'iso-8859-1');
             $this->load->library('email', $config);
             $this->email->set_newline("\r\n");
             $this->email->from('*****@*****.**', 'admin');
             $this->email->to($email);
             $base = $this->config->base_url();
             $message = heading('Your Email:');
             $message .= $email;
             $message .= br(2);
             $message .= heading('Password Recovery Link:');
             $message .= "<a href='" . $base . "index.php/forget/getlink/" . $tmp_password . "'>Click Here</a>";
             $message .= br(2);
             $message .= "Thank You";
             //$message="<a href='fsdkfjdsfjsdfjdsf'>sdfsdfsdf</a>";
             $this->email->subject('Password Recovery');
             $this->email->message($message);
             $this->email->set_mailtype("html");
             $this->email->send();
             // echo "<script>alert('Please check your email to update your password');</script>";
             echo $this->email->print_debugger();
             //redirect('welcome','refresh');
             // echo "<script>
             // alert('Please check your email to update your password');
             // window.location.href='welcome';
             // </script>";
         } else {
             //echo "";
             echo "<script>\n\t\t\t\talert('Email not registered yet!!!');\n\t\t\t\twindow.location.href='welcome';\n\t\t\t\t</script>";
         }
     }
 }
示例#28
0
 /**
  * Index Page for this controller.
  *
  * Maps to the following URL
  * 		http://example.com/index.php/welcome
  *	- or -
  * 		http://example.com/index.php/welcome/index
  *	- or -
  * Since this controller is set as the default controller in
  * config/routes.php, it's displayed at http://example.com/
  *
  * So any other public methods not prefixed with an underscore will
  * map to /index.php/welcome/<method_name>
  * @see http://codeigniter.com/user_guide/general/urls.html
  */
 public function index()
 {
     /*//$this->load->view('welcome_message');
     		echo "<h3>List Categories</h3>";
     		$data = $this->Categories_model->getAlldata();
     		//var_dump($data);
     		$vdata = "<ol>";
     		foreach ($data as $row)
     		{
     			$vdata .="<li>".$row->CategoryName."</li>";
     		}
     		$vdata .="</ol>";
     		echo $vdata;*/
     $data['judul'] = heading("List Categories", 3);
     $data['categories'] = $this->Categories_model->getAlldata();
     $this->load->view('view_categories', $data);
 }
示例#29
0
 function displayDivision()
 {
     $this->data['thetable'] = "";
     $orderBy = $this->session->userdata('orderbyteam');
     $conferences = $this->teams->getGroups('Conference');
     $this->data['thetable'] .= heading("Divisions", 2, 'class=""');
     foreach ($conferences as $conference) {
         $this->data['thetable'] .= heading($conference->Conference, 3, 'class="ConferenceHeading shadow"');
         $divisions = $this->teams->getGroups('Division');
         foreach ($divisions as $division) {
             if ($division->Conference == $conference->Conference) {
                 $this->data['thetable'] .= heading($division->Division, 4, 'class="divisionHeading shadow"');
                 $this->data['thetable'] .= $this->createTable($this->teams->some('Division', $division->Division, $orderBy));
             }
         }
     }
 }
示例#30
-3
文件: about.php 项目: nyfagel/klubb
 /**
  * index function.
  * 
  * @access public
  * @return void
  */
 public function index()
 {
     $this->output->enable_profiler(false);
     if (!$this->auth->loggedin()) {
         redirect('user/login');
     }
     $data['title'] = $this->system_model->get('app_name');
     $html = row(columns(heading(ucfirst(lang('about')) . ' ' . $this->system_model->get('app_name'), 1), 12));
     $uptime_array = explode(" ", exec("cat /proc/uptime"));
     $seconds = round($uptime_array[0], 0);
     $minutes = $seconds / 60;
     $hours = $minutes / 60;
     $days = floor($hours / 24);
     $hours = sprintf('%02d', floor($hours - $days * 24));
     $minutes = sprintf('%02d', floor($minutes - $days * 24 * 60 - $hours * 60));
     if ($days == 0) {
         $uptime = $hours . ":" . $minutes;
     } elseif ($days == 1) {
         $uptime = $days . " " . lang('day') . ", " . $hours . ":" . $minutes;
     } else {
         $uptime = $days . " " . lang('days') . ", " . $hours . ":" . $minutes;
     }
     $infolist = ul(array(heading('Applikation', 5) . ul(array(strong('Klubb-' . lang('version') . ': ') . KLUBB_VERSION, strong('CodeIgniter-' . lang('version') . ': ') . CI_VERSION, strong(ucfirst(lang('database')) . ': ') . $this->db->platform() . ', ' . lang('version') . ': ' . $this->db->version(), strong(ucfirst(lang('environment') . ': ')) . lang(ENVIRONMENT))), heading('Server', 5) . ul(array(strong('Namn: ') . php_uname('n'), strong('System: ') . php_uname('s') . ' ' . php_uname('r') . ' ' . php_uname('v') . ' ' . php_uname('m'), strong('Upptid: ') . $uptime, strong('PHP-version: ') . phpversion(), strong('PHP-moduler: ') . implode(', ', get_loaded_extensions())))), array('class' => 'no-bullet'));
     $html .= row(columns($infolist));
     $data['breadcrumbs'] = array(array('data' => anchor('/', $this->system_model->get('app_name')), 'mode' => 'unavailable'), array('data' => anchor('about', ucfirst(lang('about') . ' ' . $data['title'])), 'mode' => 'current'));
     $data['html'] = $html;
     $this->system_model->view('template', $data);
 }