Last change
on this file since ff9da8b was 0924b6c, checked in by Özkan İliyaz <iliyaz_96@…>, 4 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
1.1 KB
|
Rev | Line | |
---|
[0924b6c] | 1 | {{-- Validation errors --}}
|
---|
| 2 | @if($errors->any())
|
---|
| 3 | @foreach ($errors->all() as $error)
|
---|
| 4 | <script>
|
---|
| 5 | require(['jquery', 'Noty'], function ($, Noty) {
|
---|
| 6 | $(function () {
|
---|
| 7 | new Noty({
|
---|
| 8 | type: "error",
|
---|
| 9 | layout: "topRight",
|
---|
| 10 | text: "{{ $error }}",
|
---|
| 11 | theme: "sunset",
|
---|
| 12 | timeout: 2500,
|
---|
| 13 | closeWith: ["click", "button"]
|
---|
| 14 | }).show();
|
---|
| 15 | });
|
---|
| 16 | });
|
---|
| 17 | </script>
|
---|
| 18 | @endforeach
|
---|
| 19 | @endif
|
---|
| 20 |
|
---|
| 21 | {{-- Http request alerts --}}
|
---|
| 22 | @if(session()->has("alert"))
|
---|
| 23 | <script>
|
---|
| 24 | require(['jquery', 'Noty'], function ($, Noty) {
|
---|
| 25 | $(function () {
|
---|
| 26 | new Noty({
|
---|
| 27 | type: "{{ session()->get("alert.type") }}",
|
---|
| 28 | layout: "topRight",
|
---|
| 29 | text: "{{ session()->get("alert.message") }}",
|
---|
| 30 | theme: "sunset",
|
---|
| 31 | timeout: 2500,
|
---|
| 32 | closeWith: ["click", "button"]
|
---|
| 33 | }).show();
|
---|
| 34 | });
|
---|
| 35 | });
|
---|
| 36 | </script>
|
---|
| 37 | @endif
|
---|
Note:
See
TracBrowser
for help on using the repository browser.