本文整理匯總了PHP中AppHelper::currentDate方法的典型用法代碼示例。如果您正苦於以下問題:PHP AppHelper::currentDate方法的具體用法?PHP AppHelper::currentDate怎麽用?PHP AppHelper::currentDate使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類AppHelper
的用法示例。
在下文中一共展示了AppHelper::currentDate方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: handleBankStatement
public function handleBankStatement()
{
$account = Account::findOrFail(Input::get('account'));
if (Input::get('bank_statement') == 1) {
$account->bank_statement = Input::get('bank_statement');
// store bank statement;
$account->save();
//update information to Valid table
$member_id = $account->membership_id;
//submit money to date
$toDate = $account->to;
//return $date;
//converting date to srting
$date = AppHelper::dateToString($toDate);
//validateion upto date
$upToDate = AppHelper::addThreeYear($toDate);
//converting date to srting
$upToDate = AppHelper::dateToString($upToDate);
$currentDate = AppHelper::currentDate();
//update valid database
DB::update('update valids set valid=1,toDate =' . $date . ',upToDate=' . $upToDate . ' where membership_id=' . $member_id);
if ($currentDate < $upToDate) {
DB::update('update members set status=1 where membership_id=' . $member_id);
}
return Redirect::action('AdminAccountController@index')->with('flash_edit_success', 'Congratulation,You have submitted a bank statement');
} else {
return Redirect::action('AdminAccountController@index')->with('flash_dlt_success', 'Sorry, You do not submitted any bank statement.');
}
}