本文整理汇总了PHP中grocery_CRUD::set_primary_key方法的典型用法代码示例。如果您正苦于以下问题:PHP grocery_CRUD::set_primary_key方法的具体用法?PHP grocery_CRUD::set_primary_key怎么用?PHP grocery_CRUD::set_primary_key使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类grocery_CRUD
的用法示例。
在下文中一共展示了grocery_CRUD::set_primary_key方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
function city_management()
{
$crud = new grocery_CRUD();
$crud->set_table('city_master');
$crud->set_subject('City');
$crud->columns('city', 'state_id', 'status');
$crud->fields('city', 'state_id', 'status');
$crud->required_fields('city', 'state_id');
$crud->display_as('state_id', 'State');
$crud->set_primary_key('state_id', 'state_master');
$crud->set_relation('state_id', 'state_master', 'state_name');
$output = $crud->render(array('name' => 'City Management'));
$this->_example_output($output);
}
示例2: createtable
public function createtable($db)
{
$this->db = $this->load->database($db, true);
$crud = new grocery_CRUD();
$crud->set_table('alert_logger');
$crud->set_primary_key('id');
$crud->columns('alert', 'all_alg_data', 'all_alg_file_data', 'toa', 'alert_name', 'status', 'del');
$crud->display_as('alert', 'Alert')->display_as('all_alg_file_data', 'ALG File.')->display_as('all_alg_data', 'ALG Ref.')->display_as('toa', 'Date')->display_as('alert_name', 'Name')->display_as('del', 'Deletion date');
$crud->unset_add();
$crud->unset_edit();
$crud->unset_delete();
$crud->callback_column('status', array($this, '_column_status'));
$output = $crud->render();
$this->db->close();
$this->_example_output($output);
}
示例3: suratperunit
public function suratperunit()
{
$crud = new grocery_CRUD();
$crud->set_table('distribusi');
$crud->where('id_unit', $this->uri->segment(3));
$crud->set_primary_key('id_unit', 'distribusi');
$crud->set_relation('id_unit', 'unit', 'namaGroup');
$crud->set_relation('id_surat', 'surat', 'nomorSurat');
$crud->columns('id_surat');
$crud->display_as('id_surat', 'nomor surat');
$crud->unset_add();
$crud->unset_edit();
//$crud->columns('nomorSurat','perihal','tanggal');
$output = $crud->render();
$this->_outputs($output);
}
示例4: persutujuan_daftar_user
public function persutujuan_daftar_user()
{
try {
$crud = new grocery_CRUD();
$state = $crud->getState();
$id_user_penilai = $this->get_user_login();
//echo $id_user_penilai; exit;
//$crud->where('user_kategori', 'pegawai');
$crud->where('id_user_penilai', $id_user_penilai);
$crud->set_table('view_penilai_user');
$crud->set_primary_key('id_user_pegawai');
$crud->set_subject('Daftar Pegawai');
$crud->fields('nama_depan', 'Users');
$crud->columns('nama', 'nip', 'jenjang_jabatan', 'jenjang_golongan');
$crud->add_action('Daftar Kegiatan', '', 'penilai/persutujuan_daftar_kegiatan', 'fa fa-list');
$crud->display_as("Users", "Pegawai")->display_as("nama_depan", "Tim Penilai");
$crud->order_by('nama', 'asc');
$crud->change_field_type('nama_depan', 'readonly');
$crud->unset_save();
$crud->unset_add();
$crud->unset_edit();
$crud->unset_read();
$crud->unset_delete();
$sitemap = $this->get_sitemap();
$output = $crud->render($sitemap);
$this->load->view('theme/theme_pegawai', $output);
} catch (Exception $e) {
show_error($e->getMessage() . ' --- ' . $e->getTraceAsString());
}
}
示例5: vperusahaan
public function vperusahaan($jenis)
{
$crud = new grocery_CRUD();
$crud->set_table('vperusahaan');
$crud->columns('npwp', 'nama', 'alamat');
$crud->set_primary_key('id', 'vperusahaan');
$crud->display_as('npwp', 'NPWP Perusahaan');
$crud->display_as('nama', 'Nama Perusahaan');
$crud->add_action('Pilih', '', 'perus', 'sk-icon');
$crud->unset_export();
$crud->unset_add();
$crud->unset_edit();
$crud->unset_delete();
$crud->unset_print();
$crud->unset_read();
$crud->set_crud_url_path(site_url(strtolower(__CLASS__ . "/" . __FUNCTION__)), site_url(strtolower(__CLASS__ . "/" . $jenis)));
$output = $crud->render();
return $output;
}
示例6: kegiatan_lama
public function kegiatan_lama()
{
$status = $this->input->get("status");
$crud = new grocery_CRUD();
$crud->where("tbl_kegiatan_transaksi.status", "Lama");
$crud->set_table('tbl_kegiatan_transaksi');
$crud->set_subject('Kegiatan Lama');
$crud->set_relation('change_by', 'tbl_user', 'email');
$crud->set_relation('id_user', 'tbl_user', '{nama_depan} {nama_belakang}');
$crud->set_relation('id_kegiatan_butir', 'view_kegiatan_butir', '{unsur} - {subunsur} - {butir}');
$crud->set_primary_key('id_kegiatan_butir', 'view_kegiatan_butir');
$crud->required_fields('tanggal_kegiatan', 'tanggal_kegiatan_selesai');
$crud->fields('id_user', 'id_kegiatan_butir', 'tanggal_kegiatan', 'tanggal_kegiatan_selesai', 'lembur', 'keterangan', 'status', 'change_by', 'change_date');
$crud->columns('id_user', 'id_kegiatan_butir', 'tanggal_kegiatan', 'tanggal_kegiatan_selesai', 'status');
$crud->display_as("id_kegiatan_butir", "Butir Kegiatan")->display_as("tanggal_kegiatan", "Tanggal Mulai")->display_as("tanggal_kegiatan_selesai", "Tanggal Selesai")->display_as("id_user", "Oleh")->display_as("change_date", "Tanggal")->display_as("id_periode", "Periode")->display_as("id_kegiatan_jabatan", "Bertindak Sebagai");
$crud->callback_add_field('id_user', array($this, '_form_get_user_callback'));
$crud->callback_edit_field('id_user', array($this, '_form_get_user_callback'));
$crud->callback_add_field('status', array($this, '_kegiatan_lama_get_status_callback'));
$crud->callback_edit_field('status', array($this, '_kegiatan_lama_get_status_callback'));
$crud->callback_before_update(array($this, 'get_change_by_callback'));
$crud->callback_before_insert(array($this, 'get_change_by_callback'));
$crud->callback_field('change_date', array($this, 'format_date_callback'));
$crud->change_field_type('id_user', 'readonly');
$crud->change_field_type('change_by', 'readonly');
$crud->change_field_type('change_date', 'readonly');
$crud->add_action('Unggah Bukti', '', 'pegawai/daftar_kegiatan_berkas', 'fa fa-upload');
$crud->unset_read();
$crud->order_by('id_kegiatan_transaksi', 'desc');
$sitemap = $this->get_sitemap();
$output = $crud->render($sitemap);
$this->load->view('theme/theme_pegawai', $output);
}
示例7: search_student1
public function search_student1()
{
$user_login = $this->ion_auth->user()->row();
$colid = $user_login->col_id;
$cc_id = $this->m_student_management->get_cc_id_by_col_id($colid);
$array_cc_id = "";
foreach ($cc_id as $key) {
$array_cc_id .= $key->cc_id . ",";
}
$array_cc_id = substr($array_cc_id, 0, -1);
$nama = $this->input->get('name');
$angka_giliran = $this->input->get('angka_giliran');
$mykad = $this->input->get('mykad');
$course = $this->input->get('kursus');
$result = $this->m_student_management->search_student1($nama, $angka_giliran, $mykad, $course);
$crud = new grocery_CRUD();
$crud->set_table('student');
$crud->set_primary_key('cc_id', 'student');
$crud->set_relation_n_n('Course', 'college_course', 'course', 'cc_id', 'cou_id', 'cou_name');
$crud->set_relation_n_n('College', 'college_course', 'college', 'cc_id', "col_ida={$colid}", 'col_name');
// $crud->where('college.col_id',$colid);
$crud->columns('stu_mykad', 'stu_name', 'stu_matric_no', 'College', 'Course', 'stu_current_sem');
if ($nama != '') {
$crud->or_like('stu_name', $nama, 'both');
} elseif ($angka_giliran != '') {
$crud->or_like('stu_matric_no', $angka_giliran, 'both');
} elseif ($mykad != '') {
$crud->or_like('stu_mykad', $mykad, 'both');
} elseif ($course != '') {
$crud->or_like('cou_name', $course, 'both');
}
//Modification Log : 27092013 by Mior - comment 2 line code below because searching not function
//$query_where= "temp_cc_id IN ($array_cc_id)";
//$crud -> where($query_where);
$crud->callback_column('stu_mykad', array($this, '_callback_webpage_url'));
$crud->callback_column('stu_name', array($this, '_callback_webpage_url'));
$crud->callback_column('stu_matric_no', array($this, '_callback_webpage_url'));
$crud->display_as('stu_mykad', 'MyKad')->display_as('stu_name', 'Nama')->display_as('stu_matric_no', 'Angka Giliran')->display_as('Course', 'Kursus')->display_as('College', 'KV')->display_as('stu_current_sem', 'Semester Sekarang');
$crud->unset_add();
$crud->unset_edit();
$crud->unset_delete();
$output = $crud->render();
echo $this->_empty_output($output);
}
示例8: createtable
public function createtable($db)
{
$this->db = $this->load->database($db, true);
$crud = new grocery_CRUD();
$crud->where('toa<=', date('Y-m-d'));
if ($this->session->userdata('role') != 1) {
$crud->where('alert_name', $this->session->userdata('user_name'));
}
$crud->set_table('alert_view');
$crud->set_primary_key('id');
if ($this->session->userdata('role') != 1) {
$crud->columns('alert', 'all_alg_data', 'all_alg_file_data', 'toa', 'next_action', 'next_alert', 'alert_date');
} else {
$crud->columns('alert', 'all_alg_data', 'all_alg_file_data', 'toa', 'alert_name', 'next_action', 'next_alert', 'alert_date');
}
$crud->display_as('alert', 'Alert')->display_as('all_alg_file_data', 'ALG File.')->display_as('all_alg_data', 'ALG Ref.')->display_as('toa', 'Date')->display_as('alert_name', 'Name');
$crud->callback_column('alert', array($this, '_full_text'));
$crud->callback_column('all_alg_file_data', array($this, '_full_text1'));
$crud->callback_column('alert_name', array($this, '_column_bonus_right_align'));
$crud->callback_column('next_action', array($this, '_column_next_action'));
$crud->callback_column('next_alert', array($this, '_column_next_alert_action'));
$crud->callback_column('alert_date', array($this, '_column_alert_date_action'));
$crud->unset_add();
$crud->unset_edit();
$crud->unset_delete();
if ($this->session->userdata('role') == 1) {
$crud->add_action('Save', '', '', 'save-icon save-alert hidden', array($this, '_save_alert'));
} else {
$crud->add_action('Completed', '', '', 'success-icon save-alert hidden', array($this, '_save_alert'));
}
$output = $crud->render();
$this->db->close();
$this->_example_output($output);
}
示例9: pgtoav
function pgtoav()
{
$crud = new grocery_CRUD();
$crud->set_theme('datatables');
$datemonth1 = date('Y-m-d', strtotime("-3 days"));
$crud->set_table('pgtoav');
$crud->set_relation('member_id', 'members', 'member_id');
$crud->where('TxnEnd >=', $datemonth1);
$crud->columns('merchantTxnID', 'gateway');
$crud->where('status !=', '1');
$crud->set_primary_key('member_id', 'pgtoav');
$crud->set_field_upload('message', 'assets/uploads/files/registration');
$crud->display_as('message', 'Transaction Slip or Message');
$crud->add_action('Activate', '', 'admin/activatepgtoav', 'ui-icon-plus');
$crud->unset_print();
$crud->unset_export();
//$crud->unset_add();
// $crud->unset_edit();
$crud->unset_delete();
$output = $crud->render();
$this->_example_output($output);
}
示例10: main
function main()
{
$user_login = $this->ion_auth->user()->row();
$colid = $user_login->col_id;
$userId = $user_login->user_id;
$state_id = $user_login->state_id;
$user_groups = $this->ion_auth->get_users_groups($userId)->row();
$ul_type = $user_groups->ul_type;
$user_id = $this->session->userdata('user_id');
$crud = new grocery_CRUD();
$crud->set_table('announcement');
$crud->set_subject('pengumuman');
$crud->unset_delete();
$crud->callback_delete(array($this, 'delete_ann'));
$crud->unset_columns('ann_status_push');
if ($ul_type == 'KV') {
$crud->set_primary_key('ann_id', 'announcement_college');
$crud->set_relation('user_id', 'user', 'user_name');
$crud->set_relation('ann_id', 'announcement_college', 'col_id');
$crud->set_relation_n_n('Kolej', 'announcement_college', 'college', 'ann_id', 'col_id', 'col_name');
// $crud->callback_add_field('Kolej',array($this,'add_field_kolej'));
$crud->callback_after_insert(array($this, 'insert_announcement_college'));
$crud->field_type('ann_open_date', 'date');
$crud->field_type('ann_close_date', 'date');
$crud->field_type('user_id', 'hidden', $userId);
$crud->field_type('ann_status_push', 'hidden', 1);
$crud->field_type('ann_status', 'dropdown', array('1' => 'Aktif', '0' => 'Tak Aktif'));
$crud->display_as('ann_title', 'Perkara')->display_as('ann_id', 'Id')->display_as('ann_content', 'Pengumuman')->display_as('ann_open_date', 'Tarikh Mula')->display_as('ann_close_date', 'Tarikh Akhir')->display_as('ann_status', 'Status Pengumuman')->display_as('user_id', 'Pengguna')->display_as('college', 'Kolej Vokasional');
// $crud->callback_field('ann_title',array($this,'fc_ann_tite')); - FDP
// $crud->callback_field('ann_content',array($this,'fc_ann_content')); - FDP
// $crud->callback_field('ann_open_date',array($this,'fc_ann_open_date')); - FDP
// $crud->callback_field('ann_close_date',array($this,'fc_ann_close_date')); - FDP
// $crud->callback_field('ann_status',array($this,'fc_ann_status')); - FDP
// $crud->callback_field('college',array($this,'fc_college')); - FDP
$crud->where('j7f822d59.col_id', $colid);
$crud->unset_fields('Kolej');
$crud->required_fields('ann_title', 'ann_content', 'ann_open_date', 'ann_close_date', 'ann_status');
} elseif ($ul_type == 'LP') {
$crud->set_relation('user_id', 'user', 'user_name');
$crud->set_relation_n_n('Kolej', 'announcement_college', 'college', 'ann_id', 'col_id', 'col_name');
$crud->callback_after_insert(array($this, 'insert_announcement_college'));
$crud->field_type('ann_open_date', 'date');
$crud->field_type('ann_close_date', 'date');
$crud->field_type('user_id', 'hidden', $user_id);
$crud->field_type('ann_status_push', 'hidden', 1);
$crud->field_type('ann_status', 'dropdown', array('1' => 'Aktif', '0' => 'Tak Aktif'));
$crud->display_as('ann_title', 'Perkara')->display_as('ann_content', 'Pengumuman')->display_as('ann_open_date', 'Tarikh Mula')->display_as('ann_close_date', 'Tarikh Akhir')->display_as('ann_status', 'Status Pengumuman')->display_as('user_id', 'Pengguna')->display_as('college', 'Kolej Vokasional');
// $crud->callback_field('ann_title',array($this,'fc_ann_tite')); - FDP
// $crud->callback_field('ann_content',array($this,'fc_ann_content')); - FDP
// $crud->callback_field('ann_open_date',array($this,'fc_ann_open_date')); - FDP
// $crud->callback_field('ann_close_date',array($this,'fc_ann_close_date')); - FDP
// $crud->callback_field('ann_status',array($this,'fc_ann_status')); - FDP
// $crud->callback_field('college',array($this,'fc_college')); - FDP
$crud->required_fields('ann_title', 'ann_content', 'ann_open_date', 'ann_close_date', 'ann_status');
}
$output = $crud->render();
$js = '<script>$(document).ready(function()
{
$("#addStudent").validationEngine();
});</script>';
$header = $js . "<legend><h3>Penyenggaraan Pengumuman</h3></legend>";
$this->_main_output($output, $header);
}
示例11: daftar_kegiatan_status
public function daftar_kegiatan_status($status = NULL)
{
try {
$status = $this->uri->segment(3);
$id_user = $this->get_user_login();
$crud = new grocery_CRUD();
$state = $crud->getState();
$crud->set_table('view_kegiatan_transaksi');
$crud->set_primary_key('id_kegiatan_transaksi');
$crud->where("id_user", $id_user);
$crud->where("status", $status);
$crud->set_subject('Daftar Kegiatan');
$crud->columns('subunsur', 'butir', 'satuan_hasil', 'angka_kredit', 'keterangan');
$crud->callback_column('butir', array($this, '_callback_daftar_kegiatan_column'));
$crud->callback_column('subunsur', array($this, '_callback_daftar_kegiatan_column'));
$crud->callback_column('satuan_hasil', array($this, '_callback_daftar_kegiatan_column'));
//$crud->add_action('Edit', '', 'pegawai/daftar_kegiatan_transaksi/edit/','fa fa-pencil');
$crud->unset_delete();
$crud->unset_edit();
$crud->unset_add();
$crud->unset_read();
$sitemap = $this->get_sitemap();
$output = $crud->render($sitemap);
$this->load->view('theme/theme_pegawai', $output);
} catch (Exception $e) {
show_error($e->getMessage() . ' --- ' . $e->getTraceAsString());
}
}
示例12: array
function _set_common_report_crud($columns)
{
$crud = new grocery_CRUD();
// default columns excludes: token address_id simply because FMS/FMS-endpoint doesn't use them
$default_columns = array('report_id', 'status', 'requested_datetime', 'updated_datetime', 'expected_datetime', 'priority', 'category_id', 'media_url', 'status_notes', 'description', 'agency_responsible', 'service_notice', 'address', 'postal_code', 'lat', 'long', 'device_id', 'source_client', 'account_id', 'first_name', 'last_name', 'email', 'phone', 'engineer');
$columns = $columns ? $columns : $default_columns;
foreach ($columns as &$colname) {
if ($colname == 'report_id') {
$colname = 'xxx_report_id';
}
}
$crud->columns($columns);
$crud->order_by('requested_datetime', 'desc');
$crud->edit_fields($default_columns);
$crud->set_theme('twitter-bootstrap');
$crud->set_table('reports');
$crud->set_subject('Report');
$crud->set_relation('category_id', 'categories', 'category_name', null, 'category_name ASC');
$crud->set_relation('priority', 'priorities', 'prio_name', null, 'prio_value ASC');
$crud->set_relation('status', 'statuses', 'status_name', null, 'status_name ASC');
$crud->set_primary_key('url_slug', 'agencies');
$crud->set_relation('agency_responsible', 'agencies', 'name', null, 'name ASC');
$crud->set_relation('source_client', 'open311_clients', '<a href="admin/open311_clients/{id}">{name}</a>', null, 'name ASC');
$crud->display_as('client_id', 'Client');
$crud->callback_column('media_url', array($this, '_linkify'));
$crud->callback_column('external_id', array($this, '_get_external_url'));
$crud->callback_edit_field('media_url', array($this, '_text_media_url_field'));
$crud->display_as('requested_datetime', 'Received')->display_as('updated_datetime', 'Last Updated')->display_as('expected_datetime', 'Expected')->display_as('category_id', 'Category')->display_as('media_url', 'Media URL');
$external_id_col_name = config_item('external_id_col_name');
$crud->display_as('external_id', empty($external_id_col_name) ? 'External ID' : $external_id_col_name);
$crud->unset_texteditor('description', 'address', 'status_notes', 'service_notice');
$crud->add_action('View', site_url('assets/fms-endpoint/images/report.png'), 'admin/report');
$crud->callback_column('xxx_report_id', array($this, '_report_id_link_field'));
$crud->callback_column('requested_datetime', array($this, '_report_datetime_field'));
$crud->callback_column('updated_datetime', array($this, '_report_datetime_field'));
$crud->callback_column('description', array($this, '_report_description_field'));
$crud->callback_column($this->unique_field_name('status'), array($this, '_report_status_button'));
$crud->callback_column($this->unique_field_name('category_id'), array($this, '_report_category_button'));
$crud->display_as('xxx_report_id', 'ID');
$crud->callback_edit_field('xxx_report_id', array($this, '_read_only_report_id_field'));
//$crud->fields($default_columns);
//$crud->field_type('updated_datetime','invisible');
//$crud->callback_before_update(function($post_array){
// $post_array['updated_datetime'] = date('Y-m-d H:i:s');
// return $post_array;
//});
$crud->callback_field('updated_datetime', array($this, '_set_update_time'));
$crud->callback_field('requested_datetime', array($this, '_set_requested_datetime'));
$crud->field_type('report_id', 'readonly');
$crud->callback_before_update(array($this, '_fix_zero_prio_callback'));
$crud->callback_after_update(array($this, '_check_for_status_update_after'));
if (!$this->ion_auth->is_admin()) {
$crud->unset_delete();
}
// If we're not an admin restrict list to reports we have permissions for
if (!$this->ion_auth->is_admin()) {
return $this->filter_query_permissions($crud);
} else {
return $crud;
}
}
示例13: GroceryCrud
public function GroceryCrud()
{
try {
$crud = new grocery_CRUD();
$crud->set_theme('twitter-bootstrap');
$crud->set_table('Employee_Master');
$crud->set_subject('Employee');
$crud->set_primary_key('VEEVA_Employee_ID', 'Employee_Master');
$output = $crud->render();
$data['output'] = $output->output;
$data['css_files'] = $output->css_files;
$data['js_files'] = $output->js_files;
$data = array('title' => 'Profile_Completion', 'content' => 'admin/GroceryCrud', 'view_data' => $data);
$this->load->view('template3', $data);
} catch (Exception $e) {
show_error($e->getMessage() . ' --- ' . $e->getTraceAsString());
}
}
示例14: persutujuan_daftar_kegiatan
public function persutujuan_daftar_kegiatan()
{
try {
$this->load->model("user_m");
$crud = new grocery_CRUD();
$state = $crud->getState();
$id_user = $this->uri->segment(3);
$status = $this->uri->segment(4);
$data = $this->user_m->detail($id_user);
$row = $data[0];
$nama_depan = isset($row->nama_depan) ? $row->nama_depan : "";
$nama_belakang = isset($row->nama_belakang) ? $row->nama_belakang : "";
if ($state == 'edit') {
$crud->where('tbl_kegiatan_transaksi.id_user', $id_user);
$crud->where('tbl_kegiatan_transaksi.status', $status);
$crud->set_table('tbl_kegiatan_transaksi');
} else {
$crud->where('view_penguji_daftar_karya_ilmiah.id_user', $id_user);
$crud->where('view_penguji_daftar_karya_ilmiah.status', $status);
$crud->set_table('view_penguji_daftar_karya_ilmiah');
$crud->set_primary_key('id_kegiatan_transaksi');
}
$crud->set_relation('id_user', 'tbl_user', '{nama_depan} {nama_belakang}');
$crud->set_subject('Daftar Kegiatan');
$crud->fields('id_user', 'tanggal_kegiatan', 'tanggal_kegiatan_selesai', 'lembur', 'keterangan', 'status', 'status_deskripsi', 'angka_kredit');
$crud->columns('id_user', 'tanggal_kegiatan', 'tanggal_kegiatan_selesai', 'keterangan', 'status', 'angka_kredit');
$crud->add_action('Daftar Berkas', '', 'penilai/persutujuan_daftar_kegiatan_berkas', 'fa fa-upload');
$crud->display_as("tanggal_kegiatan", "Tanggal Mulai")->display_as("tanggal_kegiatan_selesai", "Tanggal Selesai")->display_as("id_user", "Pegawai");
$crud->order_by('id_kegiatan_transaksi', 'desc');
$crud->change_field_type('tanggal_kegiatan', 'readonly');
$crud->change_field_type('tanggal_kegiatan_selesai', 'readonly');
$crud->change_field_type('id_user', 'readonly');
$crud->change_field_type('lembur', 'readonly');
$crud->change_field_type('keterangan', 'readonly');
$crud->change_field_type('angka_kredit', 'readonly');
$crud->unset_add();
$crud->unset_save();
$crud->unset_read();
$crud->unset_delete();
$sitemap = $this->get_sitemap();
$output = $crud->render($sitemap);
$this->load->view('theme/theme_pegawai', $output);
} catch (Exception $e) {
show_error($e->getMessage() . ' --- ' . $e->getTraceAsString());
}
}
示例15: kenaikan_pangkat
public function kenaikan_pangkat()
{
try {
$crud = new grocery_CRUD();
$crud->where('user_kategori', 'pegawai');
$crud->set_table('view_user');
$crud->set_subject('Daftar Pegawai');
$crud->set_primary_key('id_user');
$crud->columns('nip', 'nama_depan', 'nama_belakang', 'status');
$crud->add_action('Detail', '', 'admin/kenaikan_pangkat_daftar', 'fa fa-edit');
//$crud->display_as("id_user", "Penanya");
$crud->unset_save();
$crud->unset_edit();
$crud->unset_delete();
$crud->unset_read();
$crud->unset_add();
$crud->order_by('nip', 'desc');
$sitemap = $this->get_sitemap();
$output = $crud->render($sitemap);
$this->load->view('theme/theme_default', $output);
} catch (Exception $e) {
show_error($e->getMessage() . ' --- ' . $e->getTraceAsString());
}
}