本文整理汇总了PHP中PdoDataAccess::insert方法的典型用法代码示例。如果您正苦于以下问题:PHP PdoDataAccess::insert方法的具体用法?PHP PdoDataAccess::insert怎么用?PHP PdoDataAccess::insert使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PdoDataAccess
的用法示例。
在下文中一共展示了PdoDataAccess::insert方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Add
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;
}
示例2: Add
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;
}
示例3: Add
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;
}
示例4: Add
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;
}
示例5: execute
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);
}
示例6: ADD
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;
}
示例7: Add
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;
}
示例8: Add
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;
}
示例9: Add
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;
}
示例10: AddSub
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;
}
示例11: AddList
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;
}
示例12: Add
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;
}
示例13: AddDocument
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;
}
示例14: AddJobHistory
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;
}
示例15: AddTaxItem
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;
}