コード例 #1
0
ファイル: index.php プロジェクト: geonef/gitted.clipperz.demo
function fixOTPStatusTable()
{
    $otpStatus = new onetimepasswordstatus();
    $otpStatusList = $otpStatus->GetList();
    if (count($otpStatusList) != 4) {
        $otpStatus->DeleteList();
        $otpStatus->code = "ACTIVE";
        $otpStatus->name = "Active";
        $otpStatus->description = "Active";
        $otpStatus->SaveNew();
        $otpStatus->code = "REQUESTED";
        $otpStatus->name = "Requested";
        $otpStatus->description = "Requested";
        $otpStatus->SaveNew();
        $otpStatus->code = "USED";
        $otpStatus->name = "Used";
        $otpStatus->description = "Used";
        $otpStatus->SaveNew();
        $otpStatus->code = "DISABLED";
        $otpStatus->name = "Disabled";
        $otpStatus->description = "Disabled";
        $otpStatus->SaveNew();
    }
}