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


PHP sessId函数代码示例

本文整理汇总了PHP中sessId函数的典型用法代码示例。如果您正苦于以下问题:PHP sessId函数的具体用法?PHP sessId怎么用?PHP sessId使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: load_notif_header

 public function load_notif_header()
 {
     $data['notification'] = GetAll('notifikasi', array('is_read' => 'where/0', 'receiver_id' => 'where/' . sessId(), 'limit' => 'limit/3', 'id' => 'order/desc'));
     $data['notifications'] = GetAll('notifikasi', array('is_read' => 'where/0', 'receiver_id' => 'where/' . sessId(), 'id' => 'order/desc'));
     $data['notification_num'] = GetAll('notifikasi', array('is_read' => 'where/0', 'receiver_id' => 'where/' . sessId()))->num_rows();
     $this->load->view('notification/head_notif_badge', $data);
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:7,代码来源:notification.php

示例2: update_component

 function update_component()
 {
     $comp = GetAllSelect('payroll_component', 'id')->result();
     foreach ($comp as $c) {
         $data = array('session_id' => $this->new_session, 'payroll_component_id' => $c->id);
         $filter = array('session_id' => 'where/' . $this->new_session, 'payroll_component_id' => 'where/' . $c->id);
         $num_rows = GetAllSelect('payroll_component_session', 'id', $filter)->num_rows();
         if ($num_rows > 0) {
             $this->db->where('session_id', $this->new_session)->where('payroll_component_id', $c->id)->update('payroll_component_session', $data);
         } else {
             $this->db->insert('payroll_component_session', $data);
         }
         $filter2 = array('session_id' => 'where/' . $this->old_session, 'payroll_component_id' => 'where/' . $c->id);
         $comp_sess_before = getValue('id', 'payroll_component_session', $filter2);
         print_ag($comp_sess_before);
         $comp_value = getAll('payroll_component_value', array('payroll_component_session_id' => 'where/' . $comp_sess_before))->row();
         print_ag($comp_value);
         $comp_sess_new = getValue('id', 'payroll_component_session', $filter);
         $num_rows_new = GetAllSelect('payroll_component_value', 'id', array('payroll_component_session_id' => 'where/' . $comp_sess_new))->num_rows();
         if (!empty($comp_value)) {
             $data2 = array('payroll_component_session_id' => $comp_sess_new, 'from' => $comp_value->from, 'to' => $comp_value->to, 'formula' => $comp_value->formula, 'is_condition' => $comp_value->is_condition, 'min' => $comp_value->min, 'max' => $comp_value->max, 'created_by' => sessId(), 'created_on' => dateNow());
             if ($num_rows_new > 0) {
                 $this->db->where('payroll_component_session_id', $comp_sess_new)->update('payroll_component_value', $data2);
             } else {
                 $this->db->insert('payroll_component_value', $data2);
             }
         }
         print_ag($this->db->last_query());
     }
 }
开发者ID:pay-test,项目名称:ci2,代码行数:30,代码来源:generate_new_session.php

示例3: ajax_update

 public function ajax_update()
 {
     //$this->_validate();
     $data = array('kode' => $this->input->post('kode'), 'title' => $this->input->post('title'), 'catatan' => $this->input->post('catatan'), 'lokasi_gudang_id' => $this->input->post('lokasi_gudang_id'), 'edited_by' => sessId(), 'edited_on' => dateNow());
     $this->gudang->update(array('id' => $this->input->post('id')), $data);
     echo json_encode(array("status" => TRUE));
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:7,代码来源:Gudang.php

示例4: ajax_add

 public function ajax_add()
 {
     //$this->_validate();
     $data = array('barang_id' => $this->input->post('barang_id'), 'gudang_id' => $this->input->post('gudang_id'), 'dalam_stok' => $this->input->post('dalam_stok'), 'minimum_stok' => $this->input->post('minimum_stok'), 'harga_beli' => $this->input->post('harga_beli'), 'harga_jual' => $this->input->post('harga_jual'), 'lokasi_detail' => $this->input->post('lokasi_detail'), 'created_by' => sessId(), 'created_on' => dateNow());
     $insert = $this->main->save($data);
     echo json_encode(array("status" => TRUE));
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:7,代码来源:lists.php

示例5: ajax_update

 public function ajax_update()
 {
     //$this->_validate();
     $data = array('code' => $this->input->post('kode'), 'name' => $this->input->post('title'), 'type' => $this->input->post('type'), 'ref_id' => $this->input->post('ref'), 'modify_user_id' => sessId(), 'modify_date' => dateNow());
     $this->coa_setup->update(array('id' => $this->input->post('id')), $data);
     echo json_encode(array("status" => TRUE));
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:7,代码来源:coa_setup.php

示例6: ajax_update

 public function ajax_update()
 {
     //$this->_validate();
     $data = array('mata_uang_asing' => $this->input->post('mata_uang_asing'), 'nilai_dalam_rupiah' => $this->input->post('nilai_dalam_rupiah'), 'catatan' => $this->input->post('catatan'), 'edited_by' => sessId(), 'edited_on' => dateNow());
     $this->main->update(array('id' => $this->input->post('id')), $data);
     echo json_encode(array("status" => TRUE));
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:7,代码来源:kurensi.php

示例7: add

 function add()
 {
     permissionUser();
     $list = array('kode_barang' => $this->input->post('kode_barang'), 'deskripsi' => $this->input->post('deskripsi'), 'diretur' => $this->input->post('diretur'), 'diterima' => $this->input->post('diterima'), 'satuan' => $this->input->post('satuan'));
     $data = array('no' => $this->input->post('no'), 'tanggal_transaksi' => date('Y-m-d', strtotime($this->input->post('tanggal_transaksi'))), 'pengeluaran_id' => $this->input->post('pengeluaran_id'), 'catatan' => $this->input->post('catatan'), 'created_by' => sessId(), 'created_on' => dateNow());
     $this->db->insert($this->table_name, $data);
     $insert_id = $this->db->insert_id();
     for ($i = 0; $i < sizeof($list['kode_barang']); $i++) {
         $data2 = array($this->file_name . '_id' => $insert_id, 'kode_barang' => $list['kode_barang'][$i], 'deskripsi' => $list['deskripsi'][$i], 'diretur' => str_replace(',', '', $list['diretur'][$i]), 'diterima' => str_replace(',', '', $list['diterima'][$i]), 'satuan_id' => $list['satuan'][$i]);
         $this->db->insert($this->table_name . '_list', $data2);
     }
     redirect($this->module . '/' . $this->file_name, 'refresh');
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:13,代码来源:retur.php

示例8: load_content

 function load_content($id)
 {
     $data['id'] = $id;
     $sess_id = sessId();
     $data['sess_name'] = getName(sessId());
     $data['buddy_name'] = getName($id);
     $q = "SELECT *\n            FROM chat\n            WHERE (sender_id = '{$sess_id}' AND receiver_id = '{$id}')\n            OR (sender_id = '{$id}' AND receiver_id = '{$sess_id}')\n            order by sent_on desc\n            limit 10\n            ";
     $data['message'] = $this->db->query($q);
     //lastq();
     $data['photo'] = '';
     $data['photo_chat'] = '';
     $this->db->where('sender_id', $id)->update('chat', array('is_read' => 1));
     $this->load->view('chat/content', $data);
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:14,代码来源:chat.php

示例9: add

 function add()
 {
     permissionUser();
     $list = array('barang_id' => $this->input->post('barang_id'), 'catatan_barang' => $this->input->post('catatan_barang'), 'buku' => $this->input->post('buku'), 'satuan_buku' => $this->input->post('satuan_buku'), 'fisik' => $this->input->post('fisik'), 'satuan_id' => $this->input->post('satuan_id'));
     $data = array('no' => $this->input->post('no'), 'tgl' => date('Y-m-d', strtotime($this->input->post('tgl'))), 'catatan' => $this->input->post('catatan'), 'created_by' => sessId(), 'created_on' => dateNow());
     $this->db->insert($this->module . '_' . $this->file_name, $data);
     $insert_id = $this->db->insert_id();
     for ($i = 0; $i < sizeof($list['barang_id']); $i++) {
         $data2 = array($this->file_name . '_id' => $insert_id, 'barang_id' => $list['barang_id'][$i], 'catatan' => $list['catatan_barang'][$i], 'buku' => str_replace(',', '', $list['buku'][$i]), 'satuan_buku' => str_replace(',', '', $list['satuan_buku'][$i]), 'fisik' => str_replace(',', '', $list['fisik'][$i]), 'satuan_id' => $list['satuan_id'][$i]);
         $this->db->insert($this->module . '_' . $this->file_name . '_list', $data2);
         $this->db->where(array('barang_id' => $list['barang_id'][$i]));
         $this->db->update('stok', array('dalam_stok' => $list['fisik'][$i]));
     }
     redirect($this->module . '/' . $this->file_name, 'refresh');
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:15,代码来源:penyesuaian.php

示例10: ajax_add

 public function ajax_add()
 {
     //$this->_validate();
     $dibayar = str_replace(',', '', $this->input->post('dibayar'));
     $kurensi = $this->input->post('kurensi');
     $list_id = $this->input->post('inv');
     $saldo = str_replace(',', '', $this->input->post('saldo'));
     $data = array('list_id' => $list_id, 'no' => $this->input->post('no'), 'coa_id' => $this->input->post('coa_id'), 'tgl_dibayar' => date('Y-m-d', strtotime($this->input->post('tgl_dibayar'))), 'dibayar' => $dibayar, 'catatan' => $this->input->post('catatan'), 'created_by' => sessId(), 'created_on' => dateNow());
     $insert = $this->main->save($data);
     $terbayar = getValue('terbayar', 'purchase_hutang_list', array('id' => 'where/' . $list_id));
     $terbayar = $terbayar + $dibayar;
     $status = $saldo > 0 ? 2 : 3;
     $data_list = array('terbayar' => $terbayar, 'saldo' => $saldo, 'status_hutang_id' => $status, 'edited_by' => sessId(), 'edited_on' => dateNow());
     $this->db->where('id', $list_id)->update('purchase_hutang_list', $data_list);
     rekening('purchase_hutang', $insert, $data['coa_id'], 'out', $data['dibayar'], 0, $kurensi);
     echo json_encode(array("status" => TRUE));
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:17,代码来源:debt_payment.php

示例11: add

 function add()
 {
     permissionUser();
     $list = array('kode_barang' => $this->input->post('kode_barang'), 'deskripsi' => $this->input->post('deskripsi'), 'diretur' => $this->input->post('diretur'), 'diterima' => $this->input->post('diterima'), 'satuan' => $this->input->post('satuan'));
     $data = array('no' => $this->input->post('no'), 'tanggal_transaksi' => date('Y-m-d', strtotime($this->input->post('tanggal_transaksi'))), 'ref_id' => $this->input->post('penerimaan_id'), 'catatan' => $this->input->post('catatan'), 'created_by' => sessId(), 'created_on' => dateNow());
     $this->db->insert($this->table_name, $data);
     $insert_id = $this->db->insert_id();
     for ($i = 0; $i < sizeof($list['kode_barang']); $i++) {
         $data2 = array($this->file_name . '_id' => $insert_id, 'kode_barang' => $list['kode_barang'][$i], 'deskripsi' => $list['deskripsi'][$i], 'diretur' => str_replace(',', '', $list['diretur'][$i]), 'diterima' => str_replace(',', '', $list['diterima'][$i]), 'satuan_id' => $list['satuan'][$i]);
         if ($this->db->insert($this->table_name . '_list', $data2)) {
             $sisa = getValue('dalam_stok', 'stok', array('barang_id' => 'where/' . $list['kode_barang'][$i])) - $list['diretur'][$i];
             $this->db->where('barang_id', $list['kode_barang'][$i])->update('stok', array('dalam_stok' => $sisa));
             $status = $list['diretur'][$i] >= $list['diterima'][$i] ? 4 : 5;
         }
     }
     $this->insert_po_status($this->input->post('penerimaan_id'));
     redirect($this->module . '/' . $this->file_name, 'refresh');
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:18,代码来源:retur.php

示例12: add

 function add()
 {
     permissionUser();
     $list = array('kode_barang' => $this->input->post('kode_barang'), 'deskripsi' => $this->input->post('deskripsi'), 'jumlah' => $this->input->post('jumlah'), 'satuan' => $this->input->post('satuan'), 'harga' => $this->input->post('harga'), 'disc' => $this->input->post('disc'), 'catatan_barang' => $this->input->post('catatan_barang'));
     //print_mz($list);
     $data = array('no' => $this->input->post('no'), 'tanggal_transaksi' => date('Y-m-d', strtotime($this->input->post('tanggal_transaksi'))), 'tanggal_pengiriman' => date('Y-m-d', strtotime($this->input->post('tanggal_pengiriman'))), 'po' => $this->input->post('po'), 'jatuh_tempo_pembayaran' => date('Y-m-d', strtotime($this->input->post('jatuh_tempo'))), 'no_faktur' => $this->input->post("no_faktur"), 'tanggal_faktur' => date('Y-m-d', strtotime($this->input->post('tanggal_faktur'))), 'catatan' => $this->input->post('catatan'), 'created_by' => sessId(), 'created_on' => dateNow());
     $this->db->where('po', $this->input->post('po'))->update('purchase_order', array('is_invoiced' => 1));
     $this->db->insert($this->table_name, $data);
     $insert_id = $this->db->insert_id();
     if ($this->input->post('metode_pembayaran_id') == 2) {
         $data_hutang = array('pembelian_id' => $insert_id, 'total' => str_replace(',', '', $this->input->post('saldo')), 'terbayar' => 0, 'saldo' => str_replace(',', '', $this->input->post('saldo')), 'status_hutang_id' => 1);
         $this->db->insert('purchase_hutang_list', $data_hutang);
     }
     for ($i = 0; $i < sizeof($list['kode_barang']); $i++) {
         $data2 = array($this->file_name . '_id' => $insert_id, 'kode_barang' => $list['kode_barang'][$i], 'deskripsi' => $list['deskripsi'][$i], 'jumlah' => str_replace(',', '', $list['jumlah'][$i]), 'satuan_id' => $list['satuan'][$i], 'harga' => str_replace(',', '', $list['harga'][$i]), 'disc' => str_replace(',', '', $list['disc'][$i]));
         $this->db->insert($this->table_name . '_list', $data2);
     }
     redirect($this->module . '/' . $this->file_name, 'refresh');
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:19,代码来源:pembelian.php

示例13: add

 function add()
 {
     permissionUser();
     $id = $this->input->post('id');
     $list = array('kode_barang' => $this->input->post('kode_barang'), 'jumlah' => $this->input->post('jumlah'), 'satuan' => $this->input->post('satuan'));
     $data = array('barang_id' => $this->input->post('output'), 'created_on' => date("Y-m-d"), 'created_by' => sessId());
     if ($id > 0) {
         $this->db->where('id', $id);
         $this->db->update($this->file_name, $data);
         $insert_id = $id;
         $this->db->query("DELETE FROM assembly_list WHERE assembly_id='{$id}'");
     } else {
         $this->db->insert($this->file_name, $data);
         $insert_id = $this->db->insert_id();
     }
     for ($i = 0; $i < sizeof($list['kode_barang']); $i++) {
         $data2 = array('assembly_id' => $insert_id, 'kode_barang' => $list['kode_barang'][$i], 'jumlah' => str_replace(',', '.', $list['jumlah'][$i]), 'satuan_id' => $list['satuan'][$i]);
         $this->db->insert($this->file_name . '_list', $data2);
     }
     redirect($this->module . '/' . $this->file_name, 'refresh');
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:21,代码来源:assembly.php

示例14: upload_excel

 function upload_excel()
 {
     $config['upload_path'] = './upload/files/excel';
     $config['allowed_types'] = 'xlsx|xls|csv';
     $config['overwrite'] = TRUE;
     $config['max_size'] = '10000';
     $val = 0;
     $this->load->library('upload', $config);
     if (!$this->upload->do_upload('excelfile')) {
         $error = array('error' => $this->upload->display_errors());
         die(print_r($error));
     } else {
         $data = array('upload_data' => $this->upload->data());
         // echo "success";
         $data_upload = $this->upload->data();
         //die(print_r($data_upload));
         $result = $this->run_import($data_upload);
         //die(print_r($result));
         foreach ($result as $row) {
             $employee_ext_id = $row['A'];
             $val = $row['C'];
             $employee_id = GetValue('employee_id', 'hris_employee', array('employee_ext_id' => 'where/' . $employee_ext_id));
             //count
             $count = GetAll('payroll_monthly_deduction_medical', array('payroll_period_id' => 'where/' . $this->input->post('periode'), 'employee_id' => 'where/' . $employee_id))->num_rows();
             if ($count > 0) {
                 $val_old = GetValue('value', 'payroll_monthly_deduction_medical', array('employee_id' => 'where/' . $employee_id, 'payroll_period_id' => 'where/' . $this->input->post('periode')));
                 $val_new = $val_old + $val;
                 $data_update = array('value' => $val_new);
                 $this->all_model->update('payroll_monthly_deduction_medical', $data_update, array('employee_id' => $employee_id, 'payroll_period_id' => $this->input->post('periode')));
                 //lastq();
             } else {
                 $data_insert = array('payroll_period_id' => $this->input->post('periode'), 'employee_id' => $employee_id, 'value' => $val, 'created_by' => sessId(), 'created_on' => date('Y-m-d H:i:s'));
                 $this->all_model->insert('payroll_monthly_deduction_medical', $data_insert);
             }
         }
     }
     redirect('payroll/medical');
 }
开发者ID:pay-test,项目名称:ci2,代码行数:38,代码来源:medical.php

示例15: send_notif

 function send_notif($id)
 {
     $group_id = array('3', '4', '8', '9', '10');
     $user_id = $this->db->select('user_id')->where_in('group_id', $group_id)->get('users_groups')->result();
     $r = [];
     $receiver = $this->db->select('user_id')->where_in('group_id', $group_id)->get('users_groups')->result_array();
     foreach ($receiver as $key => $value) {
         $r[] = getEmail($value['user_id']);
         //$r[] = 'abdul.ghanni@yahoo.co.id';
     }
     $r = implode(',', $r);
     $subject = 'Pembuatan Sales Order';
     $no = getValue('no', $this->table_name, array('id' => 'where/' . $id));
     $url = base_url() . $this->module . '/' . $this->file_name . '/detail/' . $id;
     $isi = $isi = getName(sessId()) . " membuat sales Order, Untuk melihat detail silakan <a href={$url}> KLIK DISINI </a>.";
     foreach ($user_id as $u) {
         $data = array('sender_id' => sessId(), 'receiver_id' => $u->user_id, 'sent_on' => dateNow(), 'judul' => $subject, 'no' => $no, 'isi' => $isi, 'url' => $url);
         $this->db->insert('notifikasi', $data);
     }
     $this->send_email($r, $subject, $isi);
 }
开发者ID:abdulghanni,项目名称:gsm,代码行数:21,代码来源:order.php


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