Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wts #1

Open
wants to merge 13 commits into
base: master
Choose a base branch
from
10 changes: 7 additions & 3 deletions app/config/app.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@
'Illuminate\Auth\Reminders\ReminderServiceProvider',
'Illuminate\Database\SeedServiceProvider',
'Illuminate\Session\SessionServiceProvider',
'Illuminate\Translation\TranslationServiceProvider',
//'Illuminate\Translation\TranslationServiceProvider',
'Barryvdh\TranslationManager\TranslationServiceProvider',
'Illuminate\Validation\ValidationServiceProvider',
'Illuminate\View\ViewServiceProvider',
'Illuminate\Workbench\WorkbenchServiceProvider',
Expand All @@ -124,11 +125,13 @@
'Zizaco\Confide\ConfideServiceProvider',
'Thomaswelton\LaravelGravatar\LaravelGravatarServiceProvider',
'Adamkearsley\ConvertMigrations\ConvertMigrationsServiceProvider',
'Artdarek\OAuth\OAuthServiceProvider',
'Fbf\LaravelComments\LaravelCommentsServiceProvider',
'Atticmedia\Anvard\AnvardServiceProvider',
'Cviebrock\EloquentSluggable\SluggableServiceProvider',
'Orangehill\Iseed\IseedServiceProvider',
'Barryvdh\TranslationManager\ManagerServiceProvider',
'Krucas\Notification\NotificationServiceProvider',
'Zizaco\Entrust\EntrustServiceProvider',
),

/*
Expand Down Expand Up @@ -197,7 +200,8 @@
'Theme' => 'Teepluss\Theme\Facades\Theme',
'Confide' => 'Zizaco\Confide\ConfideFacade',
'Gravatar' => 'Thomaswelton\LaravelGravatar\Facades\Gravatar',
'OAuth' => 'Artdarek\OAuth\Facade\OAuth'
'Notification' => 'Krucas\Notification\Facades\Notification',
'Entrust' => 'Zizaco\Entrust\EntrustFacade',
),

);
2 changes: 1 addition & 1 deletion app/config/cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
|
*/

'driver' => 'apc',
'driver' => 'file',

/*
|--------------------------------------------------------------------------
Expand Down
125 changes: 0 additions & 125 deletions app/config/database.php

This file was deleted.

10 changes: 10 additions & 0 deletions app/config/user.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?php
return array(
'usersettings' => array(
'timezone' => 'Europe/Dublin',
'locale' => 'en',
'license' => 'MPL-2.0',
'dateformat' => 'as_short',
)
);

11 changes: 9 additions & 2 deletions app/controllers/BaseController.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,16 @@ function __construct()
if (Auth::Check()) {
$this->user = Auth::User();
$this->usersettings = unserialize($this->user->settings);
} else {
$this->usersettings = Config::Get('user.usersettings');
}
if (Auth::guest()) {
$lang = WtsHelper::getLanguage(Config::Get('wts.appLanguages'));
if ($lang) $this->usersettings['locale'] = $lang;
}
$lang = WtsHelper::getLanguage(Config::Get('wts.appLanguages'));
if ($lang) App::setLocale($lang);

App::setLocale($this->usersettings['locale']);

$this->theme = Theme::uses('babelzilla')->layout('default');
$this->theme->asset()->container('footer')->add('modernizr_js', 'themes/babelzilla/assets/js/vendor/modernizr.js');
$this->theme->asset()->container('footer')->add('jquery_js', 'themes/babelzilla/assets/js/vendor/jquery.js');
Expand Down
Loading