mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-05-13 08:45:01 +00:00
Set app locale
This commit is contained in:
@@ -22,10 +22,13 @@ class AppServiceProvider extends ServiceProvider
|
|||||||
*/
|
*/
|
||||||
public function boot()
|
public function boot()
|
||||||
{
|
{
|
||||||
$get_time_locale = App::getLocale() . '_' . mb_strtoupper(App::getLocale());
|
$app_locale = get_setting('language') ?? 'en';
|
||||||
|
|
||||||
|
// Set locale for application
|
||||||
|
app()->setLocale($app_locale);
|
||||||
|
|
||||||
// Set locale for carbon dates
|
// Set locale for carbon dates
|
||||||
setlocale(LC_TIME, $get_time_locale);
|
setlocale(LC_TIME, $app_locale . '_' . mb_strtoupper($app_locale));
|
||||||
|
|
||||||
// Get all migrations with all directories
|
// Get all migrations with all directories
|
||||||
$this->loadMigrationsFrom(
|
$this->loadMigrationsFrom(
|
||||||
|
|||||||
@@ -40,8 +40,7 @@
|
|||||||
let config = {
|
let config = {
|
||||||
host: '{{ url('/') }}',
|
host: '{{ url('/') }}',
|
||||||
api: '{{ url('/api') }}',
|
api: '{{ url('/api') }}',
|
||||||
locale: '{{ \Illuminate\Support\Facades\App::getLocale() }}',
|
locale: '{{ app()->getLocale() }}',
|
||||||
language: '{{ $settings->language ?? 'en' }}',
|
|
||||||
|
|
||||||
app_color: '{{ $settings->app_color ?? '#00BC7E' }}',
|
app_color: '{{ $settings->app_color ?? '#00BC7E' }}',
|
||||||
app_logo: '{{ $settings->app_logo ?? null }}',
|
app_logo: '{{ $settings->app_logo ?? null }}',
|
||||||
|
|||||||
Reference in New Issue
Block a user