Move $app_locale into AppComposer

This commit is contained in:
James Brooks
2015-11-21 22:58:25 +00:00
parent 49e33d0556
commit a2d7c49c2a
5 changed files with 5 additions and 4 deletions

View File

@@ -31,6 +31,7 @@ class AppComposer
$view->withAppBanner(Setting::get('app_banner'));
$view->withAppBannerType(Setting::get('app_banner_type'));
$view->withAppDomain(Setting::get('app_domain'));
$view->withAppLocale(Setting::get('app_locale'));
$view->withAppName(Setting::get('app_name'));
$view->withAppStylesheet(Setting::get('app_stylesheet'));
$view->withAppUrl(Config::get('app.url'));

View File

@@ -28,7 +28,7 @@
<script type="text/javascript">
var Global = {};
Global.locale = '{{ Setting::get('app_locale') }}';
Global.locale = '{{ $app_locale }}';
</script>
<script src="{{ elixir('dist/js/all.js') }}"></script>
</head>

View File

@@ -65,7 +65,7 @@
<select name="app_locale" class="form-control" required>
<option value="">Select Language</option>
@foreach($langs as $lang => $name)
<option value="{{ $lang }}" @if(Setting::get('app_locale') == $lang) selected @endif>
<option value="{{ $lang }}" @if($app_locale == $lang) selected @endif>
{{ $name }}
</option>
@endforeach

View File

@@ -52,7 +52,7 @@
<script type="text/javascript">
var Global = {};
Global.locale = '{{ Setting::get('app_locale') }}';
Global.locale = '{{ $app_locale }}';
</script>
<script src="{{ elixir('dist/js/all.js') }}"></script>
</head>

View File

@@ -1,4 +1,4 @@
@if(Setting::get('app_locale') === 'en-UD')
@if($app_locale === 'en-UD')
<script type="text/javascript">
var _jipt = [];
_jipt.push(['project', 'cachet']);