function Add() { $masterID = parent::GetLastID("mission_list_items", "list_row_no", "list_id=" . $this->list_id); $this->list_row_no = $masterID + 1; $query = " select person_type from staff \r\n\t where staff_id = " . $this->staff_id; $res = parent::runquery($query); if ($res[0]['person_type'] == HR_PROFESSOR) { $this->salary_item_type_id = 42; } else { if ($res[0]['person_type'] == HR_EMPLOYEE) { $this->salary_item_type_id = 43; } else { if ($res[0]['person_type'] == HR_CONTRACT) { $this->salary_item_type_id = 643; } } } $result = parent::insert("mission_list_items", $this); if ($result === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->list_id; $daObj->SubObjectID = $this->list_row_no; $daObj->TableName = "mission_list_items"; $daObj->execute(); return true; }
function Add($pdo = "") { if (PdoDataAccess::insert("staff_details", $this, $pdo) === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->staff_id; $daObj->TableName = "staff_details"; $daObj->execute($pdo); return true; }
function Add() { $return = parent::insert("cost_centers", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->cost_center_id; $daObj->TableName = "cost_centers"; $daObj->execute(); return true; }
function Add() { if (parent::insert("study_fields", $this) === false) { return false; } $this->sfid = parent::InsertID(); $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = PdoDataAccess::InsertID(); $daObj->TableName = "study_fields"; $daObj->execute(); return true; }
public function execute($pdo = null) { //------------------- fill data members -------------------- $this->DataAuditID = PDONULL; $this->PersonID = isset($_SESSION["USER"]["PersonID"]) ? $_SESSION["USER"]["PersonID"] : ""; $this->SystemID = SYSTEMID; $this->PageName = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : $_SERVER['SCRIPT_FILENAME']; $this->IPAddress = $_SESSION['LIPAddress']; $this->ActionTime = PDONOW; $this->QueryString = PdoDataAccess::GetLatestQueryString(); //---------------------------------------------------------- PdoDataAccess::insert("DataAudit", $this, $pdo); }
function ADD() { if (parent::insert("managmnt_extra_bylaw_items", $this) === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->bylaw_id; $daObj->SubObjectID = $this->post_id; $daObj->TableName = "managmnt_extra_bylaw_items"; $daObj->execute(); return true; }
function Add() { $return = parent::insert("priority", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->PriorityID; $daObj->TableName = "priority"; $daObj->execute(); return true; }
function Add() { $this->sbid = manage_study_branch::LastID($this->sfid) + 1; if (parent::insert("study_branchs", $this) === false) { return false; } $this->sfid = parent::InsertID(); $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = PdoDataAccess::InsertID(); $daObj->TableName = "study_branchs"; $daObj->execute(); return true; }
function Add() { $return = parent::insert("SalaryItemReport", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->SalaryItemReportID; $daObj->SubObjectID = $this->PersonType; $daObj->TableName = "SalaryItemReport"; $daObj->execute(); return true; }
function AddSub($DB = "") { $result = parent::insert($DB . "person_subtracts", $this); if ($result === false) { return false; } $this->subtract_id = parent::InsertID(); $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->subtract_id; $daObj->TableName = "person_subtracts"; $daObj->execute(); return true; }
function AddList() { $result = parent::insert("pay_get_lists", $this); if ($result === false) { return false; } $this->list_id = parent::InsertID(); $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->list_id; $daObj->TableName = "pay_get_lists"; $daObj->execute(); return true; }
function Add() { $return = parent::insert("evaluation_list_items", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->list_id; $daObj->SubObjectID = $this->staff_id; $daObj->TableName = "evaluation_list_items"; $daObj->execute(); return true; }
function AddDocument() { $this->RegPersonID = $_SESSION["USER"]["PersonID"]; if (!parent::insert("DMS_documents", $this)) { return false; } $this->DocumentID = parent::InsertID(); $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->DocumentID; $daObj->TableName = "DMS_documents"; $daObj->execute(); return true; }
function AddJobHistory() { $this->RowNO = manage_person_job::LastID($this->PersonID) + 1; if (PdoDataAccess::insert("PersonJobs", $this) === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->RelatedPersonID = $this->PersonID; $daObj->MainObjectID = $this->RowNO; $daObj->TableName = "PersonJobs"; $daObj->execute(); return true; }
function AddTaxItem() { $this->row_no = parent::GetLastID("HRM_tax_table_items", "row_no", " tax_table_id =" . $this->tax_table_id) + 1; $result = parent::insert("HRM_tax_table_items", $this); if ($result === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->tax_table_id; $daObj->SubObjectID = $this->row_no; $daObj->TableName = "HRM_tax_table_items"; $daObj->execute(); return true; }
function AddList() { $lastid = parent::GetLastID("evaluation_lists", "list_id"); $this->list_id = $lastid + 1; $return = parent::insert("evaluation_lists", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->list_id; $daObj->TableName = "evaluation_lists"; $daObj->execute(); return true; }
function AddMiscDoc() { $this->row_no = manage_person_misc_doc::LastID($this->PersonID) + 1; if (PdoDataAccess::insert("person_misc_docs", $this) === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->RelatedPersonType = DataAudit::PersonType_staff; $daObj->RelatedPersonID = $this->PersonID; $daObj->MainObjectID = $this->row_no; $daObj->TableName = "person_misc_docs"; $daObj->execute(); return true; }
function AddDependency() { $this->row_no = manage_person_dependency::LastID($this->PersonID) + 1; if (parent::insert("HRM_person_dependents", $this) === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->row_no; $daObj->RelatedPersonType = 5; $daObj->RelatedPersonID = $this->PersonID; $daObj->TableName = "HRM_person_dependents"; $daObj->execute(); return true; }
function Add() { $masterID = parent::GetLastID("pay_get_list_items", "list_row_no", "list_id=" . $this->list_id); $this->list_row_no = $masterID + 1; $result = parent::insert("pay_get_list_items", $this); if ($result === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->list_id; $daObj->SubObjectID = $this->list_row_no; $daObj->TableName = "pay_get_list_items"; $daObj->execute(); return true; }
function AddWST() { $wsid = PdoDataAccess::GetLastID("writ_subtypes", "writ_subtype_id", "person_type = :PT and writ_type_id = :WTI ", array(":PT" => $this->person_type, ":WTI" => $this->writ_type_id)); $wsid++; $this->writ_subtype_id = $wsid; $return = parent::insert("writ_subtypes", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->person_type . "-" . $this->writ_type_id . "-" . $this->writ_subtype_id; $daObj->TableName = "writ_subtypes"; $daObj->execute(); return true; }
function Add() { $qry = "select max(university_id) uid from universities where country_id = " . $this->country_id; $res = parent::runquery($qry); $this->university_id = $res[0]['uid'] + 1; $return = parent::insert("universities", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->university_id; $daObj->TableName = "universities"; $daObj->execute(); return true; }
function SaveStaffTaxHistory($PID) { if (!$this->date_overlap($PID)) { return false; } if (PdoDataAccess::insert("HRM_staff_tax_history", $this) === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->RelatedPersonType = 3; $daObj->RelatedPersonID = $this->staff_id; $daObj->TableName = "staff_tax_history"; $daObj->execute(); return true; }
function AddTax() { $tax_table_type_id = parent::GetLastID("HRM_tax_table_types", "tax_table_type_id"); $tax_table_type_id++; $this->tax_table_type_id = $tax_table_type_id; $result = parent::insert("HRM_tax_table_types", $this); if ($result === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->tax_table_type_id; $daObj->TableName = "HRM_tax_table_types"; $daObj->execute(); return true; }
function AddParam() { $param_type = parent::GetLastID("HRM_salary_param_types", "param_type", "person_type = :PT ", array(":PT" => $this->person_type)); $param_type++; $this->param_type = $param_type; $result = parent::insert("HRM_salary_param_types", $this); if ($result === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->param_type; $daObj->SubObjectID = $this->person_type; $daObj->TableName = "HRM_salary_param_types"; $daObj->execute(); return true; }
function Add($PID) { if (!$this->date_overlap($PID)) { return false; } $result = parent::insert("HRM_staff_include_history", $this); if ($result === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->RelatedPersonID = $this->staff_id; $daObj->RelatedPersonType = 3; $daObj->TableName = "HRM_staff_include_history"; $daObj->execute(); return true; }
function AddTax() { if (!$this->date_overlap()) { return false; } $result = parent::insert("HRM_tax_tables", $this); if ($result === false) { return false; } $this->tax_table_id = parent::InsertID(); $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->tax_table_id; $daObj->TableName = "HRM_tax_tables"; $daObj->execute(); return true; }
function AddEducation() { $this->row_no = manage_person_education::LastID($this->PersonID) + 1; if (parent::insert("HRM_person_educations", $this) === false) { print_r(ExceptionHandler::PopAllExceptions()); die; return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->RelatedPersonType = 3; $daObj->RelatedPersonID = $this->PersonID; $daObj->MainObjectID = $this->row_no; $daObj->TableName = "HRM_person_educations"; $daObj->execute(); return true; }
function Add() { $this->bank_id = parent::GetLastID("banks", "bank_id") + 1; if ($this->branch_code == 0 || $this->branch_code == null) { $this->branch_code = PDONULL; } $return = parent::insert("banks", $this); if ($return === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->bank_id; $daObj->TableName = "banks"; $daObj->execute(); return true; }
function ADD() { $this->row_no = self::LastID($this->staff_id) + 1; if (parent::insert("professor_exe_posts", $this) === false) { return false; } //echo parent::GetLatestQueryString(); die(); $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->RelatedPersonType = DataAudit::PersonType_staff; $daObj->RelatedPersonID = $this->staff_id; $daObj->MainObjectID = $this->staff_id; $daObj->SubObjectID = $this->row_no; $daObj->TableName = "professor_exe_posts"; $daObj->execute(); return true; }
function Add($pdo = "", $DB = "") { /*$qry = "select person_type from staff where staff_id =".$this->staff_id ; $res = parent::runquery($qry) ; if($res[0]['person_type'] == 1 || $res[0]['person_type'] == 2 || $res[0]['person_type'] == 3 ) $DB = "hrms." ; else $DB = "hrms_sherkati."; */ $result = parent::insert($DB . "payment_items", $this, $pdo); if ($result === false) { return false; } $daObj = new DataAudit(); $daObj->ActionType = DataAudit::Action_add; $daObj->MainObjectID = $this->staff_id; $daObj->TableName = "payment_items"; $daObj->execute($pdo); return true; }