本文整理汇总了PHP中Confide::confirm方法的典型用法代码示例。如果您正苦于以下问题:PHP Confide::confirm方法的具体用法?PHP Confide::confirm怎么用?PHP Confide::confirm使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Confide
的用法示例。
在下文中一共展示了Confide::confirm方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: confirm
/**
* Attempt to confirm account with code
*
* @param string $code
*
* @return Illuminate\Http\Response
*/
public function confirm($code)
{
if (Confide::confirm($code)) {
$notice_msg = Lang::get('confide::confide.alerts.confirmation');
return Redirect::action('UsersController@login')->with('notice', $notice_msg);
} else {
$error_msg = Lang::get('confide::confide.alerts.wrong_confirmation');
return Redirect::action('UsersController@login')->with('error', $error_msg);
}
}
示例2: wizard
public function wizard($code)
{
if (Confide::confirm($code)) {
$user = User::where('confirmation_code', '=', $code)->pluck('email');
$user_auth = User::where('confirmation_code', '=', $code)->first();
Auth::login($user_auth);
if (Auth::check()) {
$urbanism_types = UrbanismType::orderBy('id', 'ASC')->lists('type', 'id');
$countries = Country::orderBy('id', 'ASC')->lists('name', 'id');
$states = State::orderBy('id', 'ASC')->lists('name', 'id');
$country_default = 'México';
$selected_country = Country::where('name', '=', $country_default)->first();
return View::make('dashboard.colonies.config.initial_config', ['urbanism_types' => $urbanism_types, 'user' => $user, 'countries' => $countries, 'states' => $states, 'code' => $code, 'selected_country' => [$selected_country->id], 'select' => ['' => 'Seleccione tipo de desarrollo'], 'select_1' => ['' => 'Seleccione País'], 'select_2' => ['' => 'Seleccione Estado'], 'select_3' => ['' => 'Seleccione Ciudad']]);
}
} else {
$error_msg = Lang::get('confide::confide.alerts.wrong_confirmation');
return Redirect::action('UsersController@login')->with('error', $error_msg);
}
}
示例3: confirm
/**
* Attempt to confirm account with code
*
* @param string $code
*/
public function confirm($code)
{
if (Confide::confirm($code)) {
$notice_msg = trans('texts.confide.confirmation');
$user = User::where('confirmation_code', '=', $code)->get()->first();
$user->confirmation_code = '';
$user->save();
if ($user->public_id) {
Auth::login($user);
return Redirect::to('user/reset');
} else {
return Redirect::action('UserController@login')->with('message', $notice_msg);
}
} else {
$error_msg = trans('texts.confide.wrong_confirmation');
return Redirect::action('UserController@login')->with('error', $error_msg);
}
}
示例4: getConfirm
/**
* Attempt to confirm account with code
*
* @param string $code
* @return \Illuminate\Http\RedirectResponse
*/
public function getConfirm($code)
{
if (Confide::confirm($code)) {
return Redirect::to('user/login')->with('notice', Lang::get('confide::confide.alerts.confirmation'));
} else {
return Redirect::to('user/login')->with('error', Lang::get('confide::confide.alerts.wrong_confirmation'));
}
}
示例5: confirm
/**
* Attempt to confirm account with code
*
* @param string $code
*/
public function confirm($code)
{
if (Confide::confirm($code)) {
$notice_msg = trans('texts.confide.confirmation');
$user = User::where('confirmation_code', '=', $code)->get()->first();
$user->confirmation_code = '';
$user->save();
if ($user->public_id) {
Auth::login($user);
return Redirect::to('user/reset');
} else {
if (Session::has(REQUESTED_PRO_PLAN)) {
Session::forget(REQUESTED_PRO_PLAN);
$invitation = $this->accountRepo->enableProPlan();
return Redirect::to($invitation->getLink());
} else {
return Redirect::action('UserController@login')->with('message', $notice_msg);
}
}
} else {
$error_msg = trans('texts.confide.wrong_confirmation');
return Redirect::action('UserController@login')->with('error', $error_msg);
}
}
示例6: getConfirm
public function getConfirm($code)
{
return Confide::confirm($code) ? Redirect::to('user/login')->with('success', Lang::get('confide::confide.alerts.confirmation')) : Redirect::to('user/login')->with('error', Lang::get('confide::confide.alerts.wrong_confirmation'));
}