Subversion-Projekte lars-tiefland.laravel_shop

Revision

Revision 1079 | Revision 1084 | Zur aktuellen Revision | Details | Vergleich mit vorheriger | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
964 lars 1
<?php
2
 
992 lars 3
    use App\Http\Controllers\BackendController;
1071 lars 4
    use App\Models\Web;
1076 lars 5
    use App\Models\WebProperty;
964 lars 6
    use Illuminate\Support\Facades\Route;
7
 
1068 lars 8
    /*$bc = new BackendController();
1061 lars 9
    $user_rechte = $bc->getUserRechte();
1068 lars 10
    \View::share( "user_rechte", $user_rechte );*/
1061 lars 11
 
1071 lars 12
    $w = new Web();
13
    $GLOBALS["web"] = $w->where( "domain", "=", env( 'shop' ) )->first();
14
    \View::share( "web", $GLOBALS["web"] );
1079 lars 15
    $web_rechte = WebProperty::where( "web_id", "=", $GLOBALS["web"]->ID )->get();
1081 lars 16
    foreach ( $web_rechte as $web_recht )
17
    {
18
        dd( $web_recht->tool );
19
    }
20
    //dump( $web_rechte );
1071 lars 21
 
980 lars 22
    $_SESSION["jquery_js"] = "/js/jquery-1.7.2.min.js";
23
    $_SESSION["jquery_ui_js"] = "/js/jquery-ui-1.8.23.custom.min.js";
24
    $_SESSION["jquery_style"] = "/css/start/jquery-ui.custom.css";
25
 
26
    $_SESSION["jquery_new"] = "/css/start_new/jquery.min.js";
27
    $_SESSION["jquery_ui_new"] = "/css/start_new/jquery-ui.min.js";
28
    $_SESSION["jquery_style_new"] = "/css/start_new/jquery-ui.custom.css";
29
 
30
    $_SESSION["loadingGif"] = "/images/navigation/loading.gif";
31
 
32
    /*if ( file_exists( $_SERVER["DOCUMENT_ROOT"] . "/css/" . $site . "/jquery-ui.custom.css" ) )
33
    {
34
        $_SESSION["jquery_style"] = "/css/" . $site . "/jquery-ui.custom.css";
35
    }
36
 
37
    if ( file_exists( $_SERVER["DOCUMENT_ROOT"] . "/css/" . $site . "/images/loading.gif" ) )
38
    {
39
        $_SESSION["loadingGif"] = "/css/" . $site . "/images/loading.gif";
40
    }
41
 
42
    if ( file_Exists( $_SERVER["DOCUMENT_ROOT"] . "/css/" . $site . "_new/jquery.min.js" ) )
43
    {
44
        $_SESSION["jquery_new"] = "/css/" . $site . "_new/jquery.min.js";
45
        $_SESSION["jquery_ui_new"] = "/css/" . $site . "_new/jquery-ui.min.js";
46
        $_SESSION["jquery_style_new"] = "/css/" . $site . "_new/jquery-ui.custom.css";
47
    }
48
    if ( file_exists( $_SERVER["DOCUMENT_ROOT"] . "/css/" . $site . "_new/images/loading.gif" ) )
49
    {
50
        $_SESSION["loadingGif"] = "/css/" . $site . "_new/images/loading.gif";
51
    }*/
52
 
1070 lars 53
    Route::get( '/admin/login', [ BackendController::class, 'create' ] )->name( 'login' );
992 lars 54
    Route::post( '/admin/login', [ BackendController::class, 'store' ] );
1067 lars 55
    Route::prefix( 'admin' )->middleware( 'auth:admin' )->group( function ()
964 lars 56
    {
1027 lars 57
        Route::get( '/logout', [ BackendController::class, 'destroy' ] )->name( 'logout' );
1041 lars 58
        Route::view( "/index", "admin/index" );
965 lars 59
    } );