Beispiel #1
2
 function carga()
 {
     $salida = '';
     //ini_set('upload_max_filesize','2000M');
     $salida .= form_open_multipart($this->url . 'guarda');
     $salida .= form_upload("archivo", "archivo");
     $salida .= form_submit('subir', 'Subir Archivos');
     $salida .= form_close();
     $data['content'] = $salida;
     $data['title'] = 'subedbfr Archivos .dbf Archivos dbf.';
     $this->load->view('view_ventanas_sola', $data);
 }
        public function getLoginForm()
        {
			$this->CI->lang->load('basic', 'english');
            $this->CI->load->helper('form');

			$form = '<div id="LoginForm">';
			$form.= '<p>'.$this->CI->lang->line('login_text').'</p>';
			$form.= form_open(site_url('login'), array(
				'id' => 'Login'
			));
			$form.= form_fieldset();
			$form.= form_label('username');
			$form.= form_input(array(
				'maxlength' => 20,
				'name' => 'username'
			));
			$form.= form_label('password');
			$form.= form_input(array(
				'maxlength' => 20,
				'name' => 'password',
				'type' => 'password'
			));
			$form.= form_submit('login_submit', $this->CI->lang->line('login_button'));
			$form.= form_fieldset_close();
			$form.= form_close();
			$form.= '</div>';

			return $form;
        }
Beispiel #3
0
 function revenueForm()
 {
     $revenueForm = array();
     $this->load->model('revenue_model');
     $economic = $this->expenditure_model->exp_economic();
     $donor = $this->agreement_model->getDonor();
     $source = $this->expenditure_model->getsource_Ndese();
     $budget = $this->agreement_model->getBudget();
     //REVENUE MASTER-------------------------------------------------------------------------------------
     $revenueForm['VOUCHER_NUM'] = array(form_label('भौचर नम्बर :', 'VOUCHER_NUM'), form_input(array('name' => 'VOUCHER_NUM', 'class' => 'number')));
     $revenueForm['VOUCHER_EDATE'] = array(form_label('भौचर मिति :', 'VOUCHER_EDATE'), form_input(array('name' => 'VOUCHER_EDATE', 'class' => 'number', 'id' => 'rvoucherEdate')));
     $revenueForm['VOUCHER_NDATE'] = array(form_input(array('name' => 'VOUCHER_NDATE', 'class' => 'number', 'id' => 'rvoucherNdate')));
     $revenueForm['ACC_CODE'] = array(form_label('बुद्गेत सिर्सक ', 'ACC_CODE'), form_input(array('name' => 'ACC_CODE', 'id' => 'typeauto', 'class' => 'number')), form_input(array('name' => 'ACC_CODE', 'id' => 'autocomplete', 'width' => '500px')));
     //form_dropdown('ACC_CODE', $budget, '', 'class="dropdown"'));
     $revenueForm['CREATED_BY'] = array(form_label(' प्रतिपादन BY:', 'CREATED_BY'), form_input(array('name' => 'CREATED_BY')));
     $revenueForm['CREATED_DATE'] = array(form_label('प्रतिपादन मिति :', 'CREATED_DATE'), form_input(array('name' => 'CREATED_DATE')));
     $revenueForm['AGREEMENET_ID'] = array(form_label(' agreement id :', 'AGREEMENET_ID'), form_input(array('name' => 'AGREEMENET_ID')));
     //  REVENUE DETAIL--------------------------------------------------------------------------------------
     // $revenueForm['INFO_ID'] = array(form_label('राजस्व कोड :', 'INFO_ID'), form_input(array('name' => 'INFO_ID[]', 'class' => 'number')));
     $revenueForm['AMOUNT_EDESC'] = array(form_label('मूल्य EDESC :', 'AMOUNT_EDESC'), form_input(array('name' => 'AMOUNT_EDESC[]', 'class' => 'number')));
     $revenueForm['AMOUNT_NDESC'] = array(form_input(array('name' => 'AMOUNT_NDESC[]', 'class' => 'number')));
     $revenueForm['BANK_VOUCHER_NUM'] = array(form_label('बैंक भौचर नम्बर :', 'BANK_VOUCHER_NUM'), form_input(array('name' => 'BANK_VOUCHER_NUM[]', 'class' => 'number')));
     $revenueForm['BANK_VOUCHER_DATE'] = array(form_label('बैंक भौचर मिति :', 'BANK_VOUCHER_DATE'), form_input(array('name' => 'BANK_VOUCHER_DATE[]', 'class' => 'number')));
     $revenueForm['BANK_CODE'] = array(form_label('बैंक कोड :', 'BANK_CODE'), form_input(array('name' => 'BANK_CODE[]')));
     // $revenueForm['REVENUE_DETAIL'] = array(form_label('revenu detail :', 'REVENUE_DETAIL'), form_input(array('name' => 'REVENUE_DETAIL', 'class' => 'REVENUE_DETAIL')));
     // REVENUE DETAIL DROPDOWNS----------------------------------------------------------------------
     $revenueForm['AMOUNT'] = array(form_label('मुल्य :', 'AMOUNT'), form_input(array('name' => 'AMOUNT[]', 'class' => 'AMOUNT')));
     $revenueForm['ECONOMIC_CODE5'] = array(form_dropdown('ECONOMIC_CODE5[]', $economic, '', ' class="dropdown"', 'id="reve_economic"'));
     $revenueForm['AMOUNT_TYPE'] = array(form_dropdown('AMOUNT_TYPE[]', array('d' => 'डेबिट ', 'c' => 'क्रेडिट ')));
     $revenueForm['SOURCE_TYPE_CODE'] = array(form_dropdown('SOURCE_TYPE_CODE[]', $source, '', 'class="source"'));
     $revenueForm['DONOR_CODE'] = array(form_dropdown('DONOR_CODE[]', $donor, '', 'class="donor"'));
     $revenueForm['TRANSIT'] = array(form_dropdown('TRANSIT', array('कोलेनिका ', 'बा . ख '), '', 'class="transit"'));
     $revenueForm['SUBMIT'] = array(form_submit('SUBMIT', 'Submit'));
     return $revenueForm;
 }
Beispiel #4
0
 public function get_newsletter_form()
 {
     /* BENCHMARK */
     $this->benchmark->mark('func_get_newsletter_form_start');
     $this->load->helper('data');
     $newsletter_html = '';
     // only make a newsletter form if users who are not site admins are signed in
     /*if ('super_admin'==$this->user['user_type'] or
           'admin_user'==$this->user['user_type'] or
           'supplier_user'==$this->user['user_type'])
       {
           $newsletter_html.='';
       }
       else
       {*/
     $attr = array('name' => 'newsletter_form', 'id' => 'newsletter_form', 'class' => 'form');
     $hidden = array('url' => uri_string());
     // reload url
     $newsletter_html .= form_open('newsletter/signup', $attr, $hidden);
     // email field
     $attr = array('name' => 'newsletter_email', 'id' => 'newsletter_email', 'class' => 'form_field', 'placeholder' => 'enter your email ...', 'value' => get_value(null, 'newsletter_email'));
     $newsletter_html .= form_input($attr, '');
     $newsletter_html .= form_input(array('name' => 'phone_number', 'class' => 'phone_number', 'style' => 'position:absolute;top:-10000px;'));
     // submit button
     $attr = array('name' => 'submit', 'id' => 'newsletter_submit', 'class' => 'checkout submit');
     $newsletter_html .= form_submit($attr, 'sign up');
     $newsletter_html .= form_close();
     /*}*/
     /* BENCHMARK */
     $this->benchmark->mark('func_get_newsletter_form_end');
     return $newsletter_html;
 }
Beispiel #5
0
function page_admin_images($act = "", $id = "")
{
    requires_admin();
    use_template("admin");
    if ($act == "add") {
        if (form_file_uploaded("file")) {
            $fname = $_FILES["file"]['name'];
            db_query("INSERT INTO images (link) VALUES ('')");
            $id = db_last_id();
            $fname = $id . "." . fileext($fname);
            form_file_uploaded_move("file", "img/" . $fname);
            db_query("UPDATE images SET link='img/{$fname}' WHERE id=%d", $id);
            redir("admin/images");
        }
        form_start("", "post", " enctype='multipart/form-data' ");
        form_file("Файл", "file");
        form_submit("Загрузить", "submit");
        form_end();
        $o = form();
        return $o;
    }
    if ($act == "del") {
        $im = db_object_get("images", $id);
        @unlink("../{$im->link}");
    }
    $o = table_edit("images", "admin/images", $act, $id, "", "", "", "image_func");
    return $o;
}
Beispiel #6
0
 function generateConfirm($edit)
 {
     $dataInvalid = $this->isDataInvalid($edit);
     if ($this->formbuilder) {
         $this->formbuilder->bulk_set_answers($_POST[$this->event->formkey()]);
         $dataInvalid .= $this->formbuilder->answers_invalid();
     }
     if ($dataInvalid) {
         error_exit($dataInvalid . '<br>Please use your back button to return to the form, fix these errors, and try again.');
     }
     $output = para('Please confirm that this data is correct and click the submit button to proceed to the payment information page.');
     $output .= form_hidden('edit[step]', 'submit');
     $fields = array('Registration Status' => 'payment', 'Notes' => 'notes');
     $rows = array();
     foreach ($fields as $display => $column) {
         array_push($rows, array($display, form_hidden("edit[{$column}]", $edit[$column]) . check_form($edit[$column])));
     }
     $output .= form_group('Registration details', "<div class='pairtable'>" . table(null, $rows) . '</div>');
     if ($this->formbuilder) {
         $form = $this->formbuilder->render_viewable();
         $form .= $this->formbuilder->render_hidden();
         $output .= form_group('Registration answers', $form);
     }
     $output .= para(form_submit('submit'));
     return form($output);
 }
Beispiel #7
0
 public function import($success = "")
 {
     $data['judul_besar'] = 'PHPExcel';
     $data['judul_kecil'] = 'Import';
     $data['output'] = "<h4>Sebelum mengupload, pastikan file anda berformat <strong>.xls/.xlsx</strong></h4>";
     $data['output'] .= form_open_multipart('php_excel/do_upload');
     $form = array('name' => 'userfile', 'style' => 'position:absolute;z-index:2;top:0;left:0;filter: alpha(opacity=0);-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=0);opacity:0;background-color:transparent;color:transparent;', 'onchange' => "\$('#upload-file-info').html(\$(this).val());");
     $data['output'] .= "<div style='position:relative;'>";
     $data['output'] .= "<a class='btn btn-primary' href='javascript:;'>";
     $data['output'] .= "Browse… " . form_upload($form);
     $data['output'] .= "</a>";
     $data['output'] .= "&nbsp;";
     $data['output'] .= "<span class='label label-info' id='upload-file-info'></span>";
     $data['output'] .= "</div>";
     $data['output'] .= "<br>";
     $data['output'] .= form_submit('name', 'Go !', 'class = "btn btn-default"');
     $data['output'] .= form_close();
     if ($success) {
         $data['pesan'] = '<div class="alert alert-success alert-dismissible">';
         $data['pesan'] .= '<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>';
         $data['pesan'] .= '<h4><i class="icon fa fa-check"></i> Alert!</h4>';
         $data['pesan'] .= 'Success alert preview. This alert is dismissable.';
         $data['pesan'] .= '</div>';
     }
     $this->load->view('welcome_message', $data, FALSE);
 }
Beispiel #8
0
function comments($comments, $object_id, $object, $usernames, $format, $return = 'agilan/index')
{
    $string = "";
    $string .= "<ol class='comments'>";
    if (isset($comments[$object_id]) && count($comments[$object_id]) > 0) {
        foreach ($comments[$object_id] as $kk => $ll) {
            $CID = $ll->user_id;
            $CU = $usernames[$ll->user_id];
            $stamp = mysql_to_unix($ll->created);
            $string .= "<li><b>" . $CU . ":</b> <small>" . $ll->comment . "<br/>" . mdate($format, $stamp) . "</small></li>";
        }
    } else {
        $string .= nbs();
    }
    $string .= "<li class='last'>";
    $string .= form_open('comments/index');
    $input = array('name' => 'comment', 'id' => 'comment', 'size' => 35);
    $string .= form_input($input);
    $string .= form_hidden('object', $object);
    $string .= form_hidden('object_id', $object_id);
    $string .= form_hidden('return_url', $return);
    $string .= form_submit('add comment', 'comment');
    $string .= form_close();
    $string .= "</li>";
    $string .= "</ol>";
    echo $string;
}
Beispiel #9
0
 public function editar()
 {
     if (!($this->dados['infos'] = $this->curso_model->listar($this->id))) {
         redirect('../cursos/listar');
     }
     $dadosCurso = $this->dados['infos'][0];
     $form = form_open('#', array('class' => 'niceform'));
     $form .= '<table class="cadForm">';
     $form .= '<tr>';
     $form .= '<td>';
     $form .= form_label('Nome:', '', array('for' => 'email'));
     $form .= form_input('curso_nome', $dadosCurso['curso_nome'], array('size' => 30));
     $form .= form_hidden('curso_id', $dadosCurso['curso_id']);
     $form .= form_hidden('lixeira', $dadosCurso['lixeira']);
     $form .= '</td>';
     $form .= '<td>';
     $form .= form_label('Quantidade de aulas:', '', array('for' => 'email'));
     $form .= form_input('curso_qtd_aulas', $dadosCurso['curso_qtd_aulas'], array('size' => 20));
     $form .= '</td>';
     $form .= '</tr>';
     $form .= '<tr>';
     $form .= '<td></td>';
     $form .= '<td>';
     $form .= form_submit('cadastrar', 'Enviar', 'id="submit"');
     $form .= '</td>';
     $form .= '</tr>';
     $form .= '</table>';
     $form .= form_close();
     $form .= '<span class="obs">Todos os campos são obrigatórios.</span>';
     $this->dados['form'] = $form;
     $this->load->view('editar', $this->dados);
 }
Beispiel #10
0
function list_node_image_terms()
{
    global $term_dir;
    $files = file_scan_directory($term_dir, '.*_(full|summ).*');
    if (!count($files)) {
        print 'No node_images for terms; update script does not support node images.';
        return;
    }
    $header = array(t('Term'), t('Image'), t('Migrate'), t('Delete'));
    foreach ($files as $image) {
        $image->tid = migrate_term_image_get_tid($image->name);
        list($image->width, $image->height) = getimagesize($image->filename);
        if ($image->height > 100) {
            $image->height = $image->height / 2;
            $image->width = $image->width / 2;
        }
        $img = "<img src='{$image->filename} ' width='{$image->width}' height='{$image->height}' />";
        $term = taxonomy_get_term($image->tid);
        $t_i_image = db_fetch_object(db_query('SELECT path FROM {term_image} WHERE tid = %d', $image->tid));
        if ($t_i_image) {
            $term->has_image = true;
        }
        unset($t_i_image);
        $item = $term->name . '($image->name)';
        $migrate = form_checkbox(NULL, "migrate][" . $image->name, 1, $term->has_image ? 0 : 1);
        $delete = form_checkbox(NULL, "delete][" . $image->name, 1, $term->has_image ? 1 : 0);
        $rows[] = array('data' => $item, $img, $migrate, $delete);
    }
    $table = theme('table', $header, $rows);
    $table .= '<em>Checked rows do not have an existing taxonomy_image entry</em><br/>';
    $form = form($table . form_submit('Migrate'));
    print $form;
}
Beispiel #11
0
 public function index($type = null)
 {
     switch ($type) {
         case null:
             $this->load->library('form_validation');
             $this->form_validation->set_rules('verify', 'Verification Code', 'required|xss_clean|max_length[111]');
             if ($this->form_validation->run() !== false) {
                 redirect('verify/code/' . $this->input->post('verify'));
             }
             $this->load->view('header');
             echo form_open('verify');
             echo form_label('Verify:', 'verify');
             echo form_input('verify', '', 'id="verify_input"');
             echo form_submit('submit', 'Verify');
             echo form_close();
             $this->load->view('footer');
             break;
         case 'newAccount':
             echo "<h1>Verify New Account</h1>";
             echo anchor('verify/send/newAccount', 'Send Confirmation Email', 'title="Send Confirmation Email"');
             break;
         case 'connectAccounts':
             echo "<h1>Connect Accounts</h1><h2>An account with that email already exists.</h2>";
             echo anchor('verify/send/connectAccounts', 'Connect Accounts', 'title="Connect Accounts"');
             break;
     }
 }
Beispiel #12
0
 function centinelas()
 {
     $this->load->helper('directory');
     $this->load->library('table');
     $tmpl = array('row_start' => '<tr valign="top">');
     $this->table->set_template($tmpl);
     $map = directory_map('./system/logs/');
     $lista = array();
     foreach ($map as $file) {
         if ($file != 'index.html') {
             $lista[] = anchor("supervisor/mantenimiento/borracentinela/{$file}", 'X') . " <a href='javascript:void(0)' onclick=\"carga('{$file}')\" >{$file}</a>";
         }
     }
     $copy = "<br><a href='javascript:void(0)' class='mininegro'  onclick=\"copiar()\" >Copiar texto</a>";
     $tadata = array('name' => 'sql', 'id' => 'log', 'rows' => '20', 'cols' => '60');
     $form = form_open('ejecutasql/filteredgrid/process') . form_textarea($tadata) . '<br>' . form_submit('mysubmit', 'Ejecutar como SQL') . form_close();
     $this->table->add_row(ul($lista), '<b id="fnom">Seleccione un archivo de centinela</b><br>' . $form);
     $link = site_url('supervisor/mantenimiento/vercentinela');
     $data['script'] = "<script>\n\t\t  function carga(arch){\n\t\t    link='{$link}'+'/'+arch;\n\t\t    //alert(link);\n\t\t    \$('#fnom').text(arch);\n\t\t    \$('#log').load(link);\n\t\t  };\n\t\t  function copiar(){\n\t\t    \$('#log').copy();\n\t\t  };\n\t\t</script>";
     $data['content'] = $this->table->generate();
     $data['title'] = "<h1>Centinelas</h1>";
     //script('plugins/jquery.clipboard.pack.js')
     $data["head"] = script("jquery.pack.js") . script('plugins/jquery.copy.min.js') . $this->rapyd->get_head() . style('marcos.css') . style('estilos.css');
     $this->load->view('view_ventanas', $data);
 }
Beispiel #13
0
 function get_settings_form($message = null)
 {
     $function = $this->type . '_settings';
     $form = $function($message);
     $form .= form_hidden('op', 'save');
     $form .= form_submit("Save configuration");
     return form($form);
 }
function UserAngelType_add_view($angeltype, $users_source, $user_id)
{
    $users = array();
    foreach ($users_source as $user_source) {
        $users[$user_source['UID']] = User_Nick_render($user_source);
    }
    return page_with_title(_("Add user to angeltype"), array(msg(), buttons(array(button(page_link_to('angeltypes') . '&action=view&angeltype_id=' . $angeltype['id'], _("back"), 'back'))), form(array(form_info(_("Angeltype"), $angeltype['name']), form_select('user_id', _("User"), $users, $user_id), form_submit('submit', _("Add"))))));
}
function ShiftType_edit_view($name, $angeltype_id, $angeltypes, $description, $shifttype_id)
{
    $angeltypes_select = ['' => _('All')];
    foreach ($angeltypes as $angeltype) {
        $angeltypes_select[$angeltype['id']] = $angeltype['name'];
    }
    return page_with_title($shifttype_id ? _('Edit shifttype') : _('Create shifttype'), [msg(), buttons([button(page_link_to('shifttypes'), shifttypes_title(), 'back')]), form([form_text('name', _('Name'), $name), form_select('angeltype_id', _('Angeltype'), $angeltypes_select, $angeltype_id), form_textarea('description', _('Description'), $description), form_info('', _('Please use markdown for the description.')), form_submit('submit', _('Save'))])]);
}
Beispiel #16
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);
 }
Beispiel #17
0
function listSearchesGUI()
{
    global $months;
    h3("Vis artikler fra gitt måned");
    form_start_post();
    select_open("month");
    for ($i = 1; $i < 10; $i++) {
        option_open("0" . $i);
        echo $months[$i];
        option_close();
    }
    for ($i = 10; $i < 13; $i++) {
        option_open($i);
        echo $months[$i];
        option_close();
    }
    select_close();
    form_hidden("m_c", "monthSearchResultGUI");
    form_select_number("year", 2004, date("Y"), date("Y"));
    form_submit("submit", "Søk");
    form_end();
    br();
    br();
    h3("Fritekstsøk");
    $author_usernames = array();
    $author_names = array();
    $author_usernames[] = "0";
    $author_names[] = "(ikke begrens)";
    $author_usernames = array_merge($author_usernames, getAllAuthorsUsernames());
    $author_names = array_merge($author_names, getAllAuthorsNames());
    form_start_post();
    form_textfield("text", "");
    br();
    echo "Sjekk mot hele ord ";
    form_checkbox("nopartialmatch", "1", "1");
    br();
    echo "Søk i kommentarer ";
    form_checkbox("searchcomments", "1", "0");
    form_hidden("m_c", "textSearchResultGUI");
    br();
    echo "Begrens til én forfatter ";
    form_dropdown("author", $author_usernames, $author_names, 0);
    br();
    form_submit("submit", "Fritekstsøk");
    form_end();
    br();
    br();
    h3("Vis alle kommentarer av gitt bruker");
    $author_usernames = getAllUsersUsernames();
    $author_names = getAllUsersNames();
    form_start_post();
    echo "Velg forfatter ";
    form_dropdown("author", $author_usernames, $author_names, 0);
    form_submit("submit", "Vis kommentarer");
    form_hidden("m_c", "listCommentsSearchResultGUI");
    form_end();
}
Beispiel #18
0
 public function classform()
 {
     $this->load->helper('form');
     echo form_open('http://127.0.0.1/cake/index.php/items/createclass');
     $data = array('name' => 'class_name');
     echo form_input($data);
     echo form_submit('submit', '提交');
     echo form_close();
 }
/**
 * Display form for adding/editing a shift entry.
 * @param string $angel
 * @param string $date
 * @param string $location
 * @param string $title
 * @param string $type
 * @param string $comment
 * 
 * @return string
 */
function ShiftEntry_edit_view($angel, $date, $location, $title, $type, $comment, $freeloaded, $freeload_comment, $user_admin_shifts = false)
{
    if ($user_admin_shifts) {
        $freeload_form = array(form_checkbox('freeloaded', _("Freeloaded"), $freeloaded), form_textarea('freeload_comment', _("Freeload comment (Only for shift coordination):"), $freeload_comment));
    } else {
        $freeload_form = array();
    }
    return page_with_title(_("Edit shift entry"), array(form(array(form_info(_("Angel:"), $angel), form_info(_("Date, Duration:"), $date), form_info(_("Location:"), $location), form_info(_("Title:"), $title), form_info(_("Type:"), $type), form_textarea('comment', _("Comment (for your eyes only):"), $comment), join("", $freeload_form), form_submit('submit', _("Save"))))));
}
Beispiel #20
0
 function index()
 {
     $this->rapyd->load("dataform", "datatable", 'datagrid');
     $this->load->library('table');
     //$mSQL=$this->db->query("SHOW tables");
     //$row = $mSQL->result_array();
     //$tables =$row;
     //$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 = new DataForm('nomina/rpers/process');
     $filter->title('Filtro del Reporte');
     //$filter->attributes=array('onsubmit'=>'is_loaded()');
     $filter->tabla = new dropdownField("Tabla", "tabla");
     $filter->tabla->option("pers", "Personal");
     $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';
     //if($this->rapyd->uri->is_set("search")){
     $mSQL = 'DESCRIBE pers';
     $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');
     $grid->column("Campos", 'Field');
     $grid->column("Mostrar", "<ractivo><#Field#></ractivo>", 'align="center"');
     $grid->build();
     $tabla = $grid->output;
     //$filter->button("btnsubmit", "Consultar",'', $position="BL");
     //$filter->button("btnsubmit", "Traer Tikets", form2uri(site_url("/supervisor/tiket/traertiket"),array('cliente')), $position="BL");//
     //$filter->button("btnsubmit", "Traer Tikets", form2uri(site_url("/supervisor/tiket/traertiket"), $position="BL");//
     $filter->build_form();
     $obra = 'hola';
     $data['content'] = $filter->output . form_open("nomina/rpers/crear/{$obra}") . $tabla . form_submit('mysubmit', 'Generar') . form_close();
     $data['title'] = " Reporte ";
     $data["head"] = script("jquery.js") . $this->rapyd->get_head();
     $this->load->view('view_ventanas', $data);
 }
Beispiel #21
0
 function index()
 {
     $this->load->helper('form');
     $data['titulo1'] = "<h1>Aumento de precio</h1>\n";
     $data['cuerpo'] = form_open('farmacia/aumento/procesa');
     $data['cuerpo'] .= form_input('aumenta') . '%';
     $data['cuerpo'] .= form_submit('pasa', 'Aceptar');
     $data['cuerpo'] .= form_close();
     $this->load->view('view_rapido', $data);
 }
Beispiel #22
0
 public function output($submit)
 {
     foreach ($this->inputs as $i->{$input}) {
         $this->output .= form_label($this->labels[$i]);
         $this->output .= form_input($input);
     }
     $this->output .= form_submit($submit);
     $this->output .= form_close();
     return $this->output;
 }
Beispiel #23
0
 function confirm(&$edit)
 {
     $output = "<p>Games for " . strftime("%A %B %d %Y", $edit['olddate']) . " will be moved to " . strftime("%A %B %d %Y", $edit['newdate']) . "</p>";
     $output .= form_hidden('edit[step]', 'perform');
     $output .= form_hidden('edit[type]', $edit['type']);
     $output .= form_hidden('edit[olddate]', $edit['olddate']);
     $output .= form_hidden('edit[newdate]', $edit['newdate']);
     $output .= form_submit('Confirm', 'submit');
     return form($output);
 }
Beispiel #24
0
 public function Ingresa()
 {
     $attributes = array('class' => 'form', 'id' => 'formdata', "method" => "post");
     echo form_open("/gets/index.php/frontface/home/validar", $attributes);
     $data = array('name' => 'usuario', 'id' => 'usuario', 'type' => 'text');
     echo form_input($data);
     $data = array('name' => 'clave', 'id' => 'clave', 'type' => 'password');
     echo form_input($data);
     echo form_submit("enviar", "Enviar");
     echo form_close();
 }
    public function settings_form($settings)
    {
        return form_open('', array('class' => 'dashForm')) . '<p>' . form_label(lang('wgt_cp_analytics_chart_title')) . form_input('title', $settings->title) . '</p>

			<p>' . form_label(lang('wgt_cp_analytics_chart_days')) . form_radio('days', '30', $settings->days == '30' ? TRUE : FALSE) . NBS . '30 days' . NBS . NBS . form_radio('days', '14', $settings->days == '14' ? TRUE : FALSE) . NBS . '14 days' . '</p>
			
			<p>' . form_label(lang('wgt_cp_analytics_chart_labels')) . form_radio('labels', 'y', $settings->labels == 'y' ? TRUE : FALSE) . NBS . 'Yes' . NBS . NBS . form_radio('labels', 'n', $settings->labels == 'n' ? TRUE : FALSE) . NBS . 'No' . '</p>
			
			<p>' . form_submit('save', lang('save')) . '</p>
			
			' . form_close();
    }
 public function form()
 {
     $this->data['awardees_select_options'] = $this->user_model->get_boss_ID_select_options();
     //載入可以用的選項
     $this->data['plan_select_options'] = $this->reward_model->get_plan_ID_select_options();
     $this->data['action_btn'][] = form_submit("", "送出", "class='btn btn-success'");
     $this->data['action_btn'][] = form_reset("", "重設", "class='btn'");
     $this->load->view('templates/header');
     $this->load->view('templates/sidebar');
     $this->load->view('reward/form', $this->data);
     $this->load->view('templates/footer');
 }
 /**
  * Index Function
  *
  * @return 	void
  */
 public function index()
 {
     ee()->load->model('addons_model');
     if (!ee()->addons_model->fieldtype_installed('grid') or !ee()->addons_model->fieldtype_installed('relationship')) {
         return '<p class="notice">' . lang('grid_relationships_not_installed') . '</p>';
     }
     $success_message = '';
     if (ee()->session->flashdata('success')) {
         $success_message = '<p class="success"><b>' . ee()->session->flashdata('success') . '</b></p>';
     }
     return $success_message . lang('el_playamatrix_importer_module_long_description') . form_open($this->_form_base_url . AMP . 'method=do_import') . form_submit('submit', lang('btn_import'), 'class="submit"') . form_close();
 }
function Questions_view($open_questions, $answered_questions, $ask_action)
{
    foreach ($open_questions as &$question) {
        $question['actions'] = '<a href="' . page_link_to("user_questions") . '&action=delete&id=' . $question['QID'] . '">' . _("delete") . '</a>';
        $question['Question'] = str_replace("\n", '<br />', $question['Question']);
    }
    foreach ($answered_questions as &$question) {
        $question['Question'] = str_replace("\n", '<br />', $question['Question']);
        $question['Answer'] = str_replace("\n", '<br />', $question['Answer']);
        $question['actions'] = '<a href="' . page_link_to("user_questions") . '&action=delete&id=' . $question['QID'] . '">' . _("delete") . '</a>';
    }
    return page_with_title(questions_title(), array(msg(), '<h2>' . _("Open questions") . '</h2>', table(array('Question' => _("Question"), 'actions' => ""), $open_questions), '<h2>' . _("Answered questions") . '</h2>', table(array('Question' => _("Question"), 'answer_user' => _("Answered by"), 'Answer' => _("Answer"), 'actions' => ""), $answered_questions), '<h2>' . _("Ask an archangel") . '</h2>', form(array(form_textarea('question', _("Your Question:"), ""), form_submit('submit', _("Save"))), $ask_action)));
}
Beispiel #29
0
 function showForm()
 {
     $this->output = form_open_multipart($this->data['segment'] . $this->data['id']);
     if (isset($this->data['id']) and $this->data['id'] != 0) {
         $this->output .= form_hidden('id', $this->data['id']);
     }
     foreach ($this->data['fields'] as $key => $value) {
         $this->output .= "\n" . '<div id="ssForm_' . $key . '">';
         switch ($value['type']) {
             case 'hidden':
                 $this->output .= "\n\t" . form_hidden($key, $value['value']);
                 break;
             case 'text':
                 $this->output .= "\n\t" . form_label($value['desc'], $key);
                 $this->output .= "\n\t" . form_input($key, $value['value']);
                 $this->output .= "\n" . form_error($key);
                 break;
             case 'date':
                 $this->output .= "\n\t" . form_label($value['desc'], $key);
                 $this->output .= "\n\t" . form_input($key, $value['value'], 'class="ssDate"');
                 $this->output .= "\n" . form_error($key);
                 break;
             case 'textarea':
                 $this->output .= "\n\t" . form_label($value['desc'], $key);
                 $this->output .= "\n\t" . form_textarea($key, $value['value']);
                 $this->output .= "\n" . form_error($key);
                 break;
             case 'dropdown':
                 $this->output .= "\n\t" . form_label($value['desc'], $key);
                 $this->output .= "\n\t" . form_dropdown($key, $value['options'], $value['value']);
                 $this->output .= "\n" . form_error($key);
                 break;
             case 'checkbox':
                 $this->output .= "\n\t" . form_label($value['desc'], $key);
                 $this->output .= "\n\t" . form_checkbox($key, $value['value'], $value['checked']);
                 $this->output .= "\n" . form_error($key);
                 break;
             case 'upload':
                 $this->output .= "\n\t" . form_label($value['desc'], $key);
                 $this->output .= "\n\t" . form_upload($key, $value['value']);
                 $this->output .= "\n" . is_array($this->upload_error) ? '<p>Err:' . $this->upload_error[$key] . '</p>' : '<p></p>';
                 break;
             default:
                 break;
         }
         $this->output .= '</div>';
     }
     $this->output .= "\n" . '<div>' . "\n\t" . form_submit('submit', $this->button, 'class="submit"') . "\n" . '</div>';
     $this->output .= "\n" . form_close();
     return $this->output;
 }
Beispiel #30
0
 function ingresarVentana()
 {
     $viene = $this->session->userdata('estaba');
     $data['estilos'] = style("estilos.css");
     $attributes = array('name' => 'ingresar_form');
     $data['cuerpo'] = form_open('bienvenido/autentificar', $attributes);
     $attributes = array('name' => 'user', 'size' => '6');
     $data['cuerpo'] .= '<table><tr><td>Usuario: </td><td>' . form_input($attributes) . '</td></tr>';
     $attributes = array('name' => 'pws', 'size' => '6', 'type' => 'password');
     $data['cuerpo'] .= '<tr><td> Clave:  </td><td>' . form_input($attributes) . '</td></tr>';
     $data['cuerpo'] .= '<tr><td></td><td>' . form_submit('usr_submit', 'Enviar') . form_close() . '</td></tr></table>';
     // Build the thing
     $this->load->view('ingreso', $data);
 }