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


PHP PdoDataAccess::FillObjectByJsonData方法代码示例

本文整理汇总了PHP中PdoDataAccess::FillObjectByJsonData方法的典型用法代码示例。如果您正苦于以下问题:PHP PdoDataAccess::FillObjectByJsonData方法的具体用法?PHP PdoDataAccess::FillObjectByJsonData怎么用?PHP PdoDataAccess::FillObjectByJsonData使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PdoDataAccess的用法示例。


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

示例1: SaveBase

function SaveBase()
{
    $obj = new manage_bases();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    // بررسی گروه های تشویقی که بیشتر از 5 برای یک نفر نباشد
    /*if(in_array($obj->BaseType, array(27,23,24,21,3,4,5)))
    	{
    		$query = "select sum(BaseValue) from bases 
    			where	PersonID=? AND 
    					BaseType in(27,23,24,21,3,4,5) AND 
    					BaseStatus = 'NORMAL'
    					";
    		$st = PdoDataAccess::runquery($query, array($obj->PersonID));
    		if(count($st) > 0 && (int)$st[0][0] + (int)$obj->BaseValue > 5)
    		{
    			echo Response::createObjectiveResponse(false, "OverMaxCGroup");
    			die();
    		}
    	}*/
    //----------------------------
    if (empty($obj->RowID)) {
        $obj->RegDate = PDONOW;
        $return = $obj->Add();
    } else {
        unset($obj->RegDate);
        $return = $obj->Edit();
    }
    if (!$return) {
        echo Response::createObjectiveResponse($return, ExceptionHandler::GetExceptionsToString());
        die;
    }
    echo Response::createObjectiveResponse(true, "");
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:34,代码来源:bases.data.php

示例2: removeTaxHistory

function removeTaxHistory()
{
    $obj = new manage_staff_tax();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    echo $obj->Remove() ? "true" : "false";
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:7,代码来源:staff_tax.data.php

示例3: SaveJob

function SaveJob()
{
    $obj = new manage_person_job();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    $obj->FromDate = DateModules::Shamsi_to_Miladi($obj->FromDate);
    $obj->ToDate = DateModules::Shamsi_to_Miladi($obj->ToDate);
    if (empty($obj->RowNO)) {
        $return = $obj->AddJobHistory();
    } else {
        $return = $obj->EditJobHistory();
    }
    echo $return ? Response::createObjectiveResponse(true, $obj->RowNO) : Response::createObjectiveResponse(false, ExceptionHandler::GetExceptionsToString("\n"));
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:14,代码来源:job_history.data.php

示例4: SaveStep

function SaveStep()
{
    $obj = new WFM_FlowSteps();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    if ($obj->StepRowID > 0) {
        $result = $obj->EditFlowStep();
    } else {
        $dt = PdoDataAccess::runquery("select ifnull(max(StepID),0) from WFM_FlowSteps where FlowID=? AND IsActive='YES' AND IsOuter='NO'", array($obj->FlowID));
        $obj->StepID = $dt[0][0] * 1 + 1;
        $result = $obj->AddFlowStep();
    }
    echo Response::createObjectiveResponse($result, "");
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:14,代码来源:wfm.data.php

示例5: SaveBank

function SaveBank()
{
    $obj = new manage_bank();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    if ($obj->bank_id) {
        $return = $obj->Edit();
    } else {
        $return = $obj->Add();
    }
    if ($return) {
        echo Response::createResponse(true, $obj->bank_id);
    } else {
        echo Response::createResponse(false, ExceptionHandler::ConvertExceptionsToJsObject());
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:16,代码来源:banks.data.php

示例6: SaveSIR

function SaveSIR()
{
    $obj = new manage_salary_item_report();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    if ($obj->SalaryItemReportID == "") {
        $return = $obj->Add();
    } else {
        $return = $obj->Edit();
    }
    if ($return) {
        echo Response::createResponse(true, $obj->SalaryItemReportID);
    } else {
        echo Response::createResponse(false, ExceptionHandler::ConvertExceptionsToJsObject());
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:16,代码来源:salary_item_report.data.php

示例7: saveTax

function saveTax()
{
    $obj = new manage_tax_table_types();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    if ($obj->tax_table_type_id == "") {
        $return = $obj->AddTax();
    } else {
        $return = $obj->EditTax($obj->tax_table_type_id);
    }
    if ($return) {
        echo Response::createResponse(true, $obj->tax_table_type_id);
    } else {
        echo Response::createResponse(false, '');
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:16,代码来源:tax_table_types.data.php

示例8: SaveBranch

function SaveBranch()
{
    $obj = new manage_study_branch();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    if (empty($obj->sbid)) {
        $return = $obj->Add();
    } else {
        $return = $obj->Edit();
    }
    if (!$return) {
        echo Response::createObjectiveResponse($return, ExceptionHandler::GetExceptionsToString());
        die;
    }
    echo Response::createObjectiveResponse(true, "");
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:16,代码来源:study_fields.data.php

示例9: SaveSubInfo

function SaveSubInfo()
{
    $obj = new manage_subInfo();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    if ($_GET['newMode'] == 1) {
        $return = $obj->Add();
    } else {
        $return = $obj->Edit();
    }
    if ($return) {
        echo Response::createResponse(true, $obj->SalaryItemTypeID);
    } else {
        echo Response::createResponse(false, ExceptionHandler::ConvertExceptionsToJsObject());
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:16,代码来源:subtract_info.data.php

示例10: saveTaxItem

function saveTaxItem()
{
    $obj = new manage_Tax_Table_Item();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    $obj->tax_table_id = $_POST["tax_table_id"];
    if ($obj->row_no == "") {
        $return = $obj->AddTaxItem($obj->tax_table_id);
    } else {
        $return = $obj->EditTaxItem($obj->tax_table_id, $obj->row_no);
    }
    if ($return) {
        echo Response::createResponse(true, $obj->tax_table_id, $obj->row_no);
    } else {
        echo Response::createResponse(false, ExceptionHandler::GetExceptionsToString());
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:17,代码来源:tax_table_items.data.php

示例11: saveParam

function saveParam()
{
    $obj = new manage_salary_param_types();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    $obj->person_type = 3;
    if ($obj->param_type == "") {
        $return = $obj->AddParam();
    } else {
        $return = $obj->EditParam($obj->param_type);
    }
    if ($return) {
        echo Response::createResponse(true, $obj->param_type);
    } else {
        echo Response::createResponse(false, '');
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:17,代码来源:salary_param_type.data.php

示例12: saveTax

function saveTax()
{
    $obj = new manage_Tax_Table();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    $obj->tax_table_type_id = $_POST["tax_table_type_id"];
    if ($obj->tax_table_id == "") {
        $return = $obj->AddTax();
    } else {
        $return = $obj->EditTax($obj->tax_table_id);
    }
    if ($return) {
        echo Response::createResponse(true, $obj->tax_table_id);
    } else {
        echo Response::createResponse(false, ExceptionHandler::ConvertExceptionsToJsObject());
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:17,代码来源:tax_tables.data.php

示例13: saveParam

function saveParam()
{
    $obj = new manage_salary_params();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    $obj->param_type = $_POST["param_type"];
    $obj->person_type = 3;
    if ($obj->param_id == "") {
        $return = $obj->AddParam();
    } else {
        $return = $obj->EditParam($obj->param_id);
    }
    if ($return) {
        echo Response::createResponse(true, $obj->param_type);
    } else {
        echo Response::createResponse(false, ExceptionHandler::GetExceptionsToString());
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:18,代码来源:salary_param.data.php

示例14: SavePriority

function SavePriority()
{
    $obj = new manage_priority();
    PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
    $where = " where PriorityID=" . $obj->PriorityID;
    $res = manage_priority::GetAll($where);
    if (count($res) > 0) {
        $return = $obj->Edit();
    } else {
        $return = $obj->Add();
    }
    if ($return) {
        echo Response::createResponse(true, $obj->PriorityID);
    } else {
        echo Response::createResponse(false, ExceptionHandler::ConvertExceptionsToJsObject());
    }
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:18,代码来源:priority.data.php

示例15: SaveMenu

function SaveMenu()
{
    if (isset($_POST["record"])) {
        $obj = new FRW_Menus();
        PdoDataAccess::FillObjectByJsonData($obj, $_POST["record"]);
        $st = stripslashes(stripslashes($_POST["record"]));
        $data = json_decode($st);
        $obj->ParentID = $data->GroupID;
        $res = $obj->EditMenu();
    } else {
        $obj = new FRW_Menus();
        PdoDataAccess::FillObjectByArray($obj, $_POST);
        if (isset($_POST["MenuID"]) && $_POST["MenuID"] > 0) {
            $res = $obj->EditMenu();
        } else {
            $res = $obj->AddMenu();
        }
    }
    //print_r(ExceptionHandler::PopAllExceptions());
    echo Response::createObjectiveResponse($res, "");
    die;
}
开发者ID:jafarkhani,项目名称:rtfund,代码行数:22,代码来源:framework.data.php


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