@@ 60-75 (lines=16) @@ | ||
57 | } |
|
58 | } |
|
59 | ||
60 | if (!function_exists('admin_toastr')) { |
|
61 | ||
62 | /** |
|
63 | * Flash a toastr message bag to session. |
|
64 | * |
|
65 | * @param string $message |
|
66 | * @param string $type |
|
67 | * @param array $options |
|
68 | */ |
|
69 | function admin_toastr($message = '', $type = 'success', $options = []) |
|
70 | { |
|
71 | $toastr = new MessageBag(get_defined_vars()); |
|
72 | ||
73 | session()->flash('toastr', $toastr); |
|
74 | } |
|
75 | } |
|
76 | ||
77 | if (!function_exists('admin_success')) { |
|
78 | ||
@@ 119-134 (lines=16) @@ | ||
116 | } |
|
117 | } |
|
118 | ||
119 | if (!function_exists('admin_info')) { |
|
120 | ||
121 | /** |
|
122 | * Flash a message bag to session. |
|
123 | * |
|
124 | * @param string $title |
|
125 | * @param string $message |
|
126 | * @param string $type |
|
127 | */ |
|
128 | function admin_info($title, $message = '', $type = 'info') |
|
129 | { |
|
130 | $message = new MessageBag(get_defined_vars()); |
|
131 | ||
132 | session()->flash($type, $message); |
|
133 | } |
|
134 | } |
|
135 | ||
136 | if (!function_exists('admin_asset')) { |
|
137 |