本文整理汇总了PHP中Laracasts\Flash\Flash::overlay方法的典型用法代码示例。如果您正苦于以下问题:PHP Flash::overlay方法的具体用法?PHP Flash::overlay怎么用?PHP Flash::overlay使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Laracasts\Flash\Flash
的用法示例。
在下文中一共展示了Flash::overlay方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: organization_info_update
public function organization_info_update(UpdateOrganizationInfoFormRequest $request, $id)
{
$updateOrganization = new UpdateOrganizationInfo($request, $id);
$this->dispatch($updateOrganization);
Flash::overlay('Organization Info Updated!');
return redirect()->back();
}
示例2: store
/**
* Create a new Larabook user
* @param SaveUserRequest $request
* @return string
*/
public function store(SaveUserRequest $request)
{
$user = $this->dispatchFrom(RegisterUserJob::class, $request);
Auth::login($user);
Flash::overlay("Glad to have you as a new Larabook member!");
return redirect(route('home'));
}
示例3: store
/**
* @param Requests\SignUpRequest $request
* @param CommandDispatcher $commandDispatcher
*
* @return
*/
public function store(Requests\SignUpRequest $request, CommandDispatcher $commandDispatcher)
{
$commandDispatcher->dispatchFrom(RegisterUser::class, $request);
\Auth::login(User::where('username', $request['username'])->first());
Flash::overlay('Welcome!!');
return Redirect::home();
}
示例4: store
public function store()
{
$this->registrationForm->validate(Input::all());
$user = $this->execute(RegisterUserCommand::class);
Auth::login($user);
Flash::overlay('WELCOME! Glad to have you as a new Larabook member!');
return Redirect::home();
}
示例5: register
public function register(Request $request)
{
$validator = $this->validator($request->all());
if ($validator->fails()) {
$this->throwValidationException($request, $validator);
}
Auth::login($this->create($request->all()));
Flash::overlay('Votre compte a bien été crée !', 'Bienvenue');
return redirect($this->redirectPath());
}
示例6: update
public function update(PasswordChangeRequest $request, $id)
{
$check = auth()->validate(['email' => Auth::user()->email, 'password' => $request->input('current_password')]);
if (!$check) {
return redirect()->back()->withErrors('Current Password is incorrect.');
}
$userId = Auth::user()->id;
$password = $request->input('new_password');
$job = new SetPassword($userId, $password);
$this->dispatch($job);
Flash::overlay('Password successfully changed!');
return redirect()->back();
}
示例7: confirm
public function confirm($verification_token)
{
if (!$verification_token) {
throw new Exception("Invalid Confirmation Code", 1);
}
$user = User::where('verification_token', '=', $verification_token)->first();
if (!$user) {
throw new Exception("Invalid Confirmation Code", 1);
}
$user->status = 'active';
$user->verification_token = null;
$user->save();
Flash::overlay('You have successfully verified your account.', 'Congratulations');
return redirect('auth/login');
}
示例8: getRegistration
/**
* Display Registration Page
* @param [type] $id [description]
* @return [type] [description]
*/
public function getRegistration($id)
{
$event = $this->eventRepo->findById($id);
$hostOrg = $this->orgRepo->findById($event->organization_id);
$partners = $event->partners()->get();
$partners->prepend($hostOrg);
$partners->prepend('');
$organizations = $partners->lists('name', 'id');
$states = States::all();
$grades = Grades::all();
$genders = Gender::all();
$languages = Languages::all();
$sweatshirt_sizes = SweatshirtSizes::all();
if ($event->private) {
Flash::overlay('Note: This is a private event. Your email must be on the guest list to process registration.');
}
return view('public.events.registration', compact('event', 'organizations', 'states', 'languages', 'grades', 'sweatshirt_sizes', 'genders'));
}
示例9: sendRegistrationConfirmation
public function sendRegistrationConfirmation($id)
{
$attendee = $this->attendees->findById($id);
$event = $attendee->event()->first();
$this->dispatch(new SendRegistrationConfirmation($attendee, $event));
Flash::overlay('Registration confirmation sent!');
return redirect()->back();
}
示例10: sitioReparacion
public function sitioReparacion()
{
Flash::overlay('Bien! su mensaje se envio correctamente');
return Redirect::to('/');
}
示例11: store
/**
* Store a newly created resource in storage.
*
* @return Response
*/
public function store(ProdutoRequest $request)
{
Produto::create($request->all());
Flash::overlay("Produto adicionado!", 'Mensagem');
return \Redirect::route('cadastro.produtos.index');
}
示例12: sendRegistrationConfirmation
public function sendRegistrationConfirmation($id)
{
$user = $this->users->findById($id);
$this->dispatch(new SendWelcomeEmail($user));
Flash::overlay('Confirmation email resent!');
return redirect()->back();
}
示例13: updateamount
public function updateamount(Request $request, $id)
{
$validator = Validator::make(Input::all(), Expensive::$rules);
if ($validator->passes()) {
$project = Project::find($id);
$viatico = new Expensive();
$viatico->project_id = $project->id;
$viatico->concepto = Input::get('concepto');
$viatico->monto = Input::get('monto');
$viatico->fecha = Input::get('fecha');
/*
* validar si existe una imagen
*/
if (Input::has('file')) {
$user = Input::get('user_id');
$projectnumber = $project->id;
$file = $request->file('file');
$ruta = '/files/' . $user . '/' . $projectnumber . '/';
$nombre = sha1(Carbon::now()) . '.' . $file->guessExtension();
$fileupload = $file->move(getcwd() . $ruta, $nombre);
$viatico->ruta = $fileupload;
}
$viatico->save();
/*
* movimiento en la tabla de proyecto para el monto restante
*/
$monto = Input::get('monto');
DB::table('projects')->where('id', $id)->update(['montocambiante' => $monto]);
DB::table('projects')->where('id', $id)->decrement('montorestante', $monto);
Flash::overlay('Amount Updated Successfully');
return redirect('projects');
}
return redirect('projects/' . $id . '/uamount')->withErrors($validator)->withInput(Input::all())->with('message', 'There some problems with the inputs, please review and submit again :D !!');
}
示例14: destroy
/**
* Remove the specified resource from storage.
*
* @param int $item
* @return Response
*/
public function destroy($item)
{
$item->delete();
Flash::overlay('Your items/service has been deleted.', 'Done!');
return redirect('items');
}
示例15: unpublish
public function unpublish($id)
{
$attendees = $this->attendees->findAllThatPaid($id, 'firstname', 'asc');
if (!$attendees->isEmpty()) {
Flash::overlay('This event cannot be taken offline; registered attendees exist for this event.');
return redirect()->back();
}
$event = $this->eventRepo->findById($id);
$event->published = false;
$event->save();
return redirect()->back();
}