Set Options with fallback values and better boolean handling

This commit is contained in:
Bubka
2020-03-13 22:10:36 +01:00
parent a545716798
commit 76ebf847df
7 changed files with 81 additions and 24 deletions

View File

@ -2,6 +2,7 @@
namespace App\Http\Controllers;
use App\Classes\Options;
use Illuminate\Http\Request;
class SinglePageController extends Controller
@ -13,8 +14,6 @@ class SinglePageController extends Controller
*/
public function index()
{
$appSettings = \Illuminate\Support\Facades\DB::table('options')->pluck('value', 'key')->toJson();
return view('landing')->with('appSettings', $appSettings);
return view('landing')->with('appSettings', Options::get()->toJson());
}
}