DEV.XFOR.TOP

Email: [email protected] Skype: utz0r2 Github: utz0r2
CSSHTMLPHPJSVideoNoty
E-commerce Scripts: vvStore | vvShop | Avox
© 2008 – 2020

laravel / airlock - легковесная система аутентификации для SPA и простых API

use App\User;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Hash;
use Illuminate\Validation\ValidationException;

Route::post('/airlock/token', function (Request $request) {
    $request->validate([
        'email' => 'required|email',
        'password' => 'required',
        'device_name' => 'required'
    ]);

    $user = User::where('email', $request->email)->first();

    if (! $user || ! Hash::check($request->password, $user->password)) {
        throw ValidationException::withMessages([
            'email' => ['The provided credentials are incorrect.'],
        ]);
    }

    return $user->createToken($request->device_name)->plainTextToken;
});

https://github.com/laravel/airlock

thomasjohnkane/snooze - пакет для упрощения автоматизации будущих уведомлений и напоминаний в Laravel

use Thomasjohnkane\Snooze\Traits\SnoozeNotifiable;

class User extends Model {
    use SnoozeNotifiable;

    // ...
}

// Schedule a birthday notification
$user->notifyAt(new BirthdayNotification, Carbon::parse($user->birthday));

// Schedule for a week from now
$user->notifyAt(new NextWeekNotification, Carbon::now()->addDays(7));

// Schedule for new years eve
$user->notifyAt(new NewYearNotification, Carbon::parse('last day of this year'));

https://github.com/thomasjohnkane/snooze

stefanzweifel/laravel-stats

stefanzweifel/laravel-stats

https://github.com/stefanzweifel/laravel-stats

glhd/aire - билдер форм для Laravel

Пример создания формы
{{ Aire::open()
  ->route('users.update')
  ->bind($user) }}

<div class="flex flex-col md:flex-row">

  {{ Aire::input('given_name', 'First/Given Name')
    ->id('given_name')
    ->autoComplete('off')
    ->groupClass('flex-1 mr-2') }}
    
  {{ Aire::input('family_name', 'Last/Family Name')
    ->id('family_name')
    ->autoComplete('off')
    ->groupClass('flex-1') }}
  
</div>
  
{{ Aire::email('email', 'Email Address') }}
  
{{ Aire::submit('Update User') }}
  
{{ Aire::close() }}

https://github.com/glhd/aire

pipe-dream/laravel - скрипт для быстрого развертывания приложения на laravel


https://github.com/pipe-dream/laravel

GitaminHQ/Gitamin - клон гихаба на Laravel

GitaminHQ/Gitamin - клон гихаба на Laravel

https://github.com/gitaminhq/gitamin
«»
Вверх