Subversion-Projekte lars-tiefland.laravel_shop

Revision

Revision 1617 | Revision 1620 | Zur aktuellen Revision | Ganze Datei anzeigen | Leerzeichen ignorieren | Details | Blame | Letzte Änderung | Log anzeigen | RSS feed

Revision 1617 Revision 1619
Zeile 74... Zeile 74...
74
    $countryIDs = ( isset( $GLOBALS['INI']['steuern']['use_countries_tax'] ) ) ? $GLOBALS['INI']['steuern']['use_countries_tax'] : $landID;
74
    $countryIDs = ( isset( $GLOBALS['INI']['steuern']['use_countries_tax'] ) ) ? $GLOBALS['INI']['steuern']['use_countries_tax'] : $landID;
Zeile 75... Zeile 75...
75
 
75
 
76
    $sql = "SELECT 
76
    $sql = "SELECT 
77
            *
77
            *
78
        FROM
78
        FROM
79
            countries_tax
79
            content_management.countries_tax
80
        WHERE
80
        WHERE
81
            country_id IN (" . $countryIDs . ")
81
            country_id IN (" . $countryIDs . ")
82
    ";
82
    ";
83
    $rows = DB::connection( "cms" )->select( $sql );
83
    $rows = DB::connection( "cms" )->select( $sql );
Zeile 344... Zeile 344...
344
            0,
344
            0,
345
            99
345
            99
346
        ] )->orderBy( 'kennung' )->orderBy( 'name' )->get();
346
        ] )->orderBy( 'kennung' )->orderBy( 'name' )->get();
347
        $items = Item::with( 'price', 'medium.medium', 'manufacturer' )->where( "directory_id", $dirId )->where( 'status', '=', 0 )->get();
347
        $items = Item::with( 'price', 'medium.medium', 'manufacturer' )->where( "directory_id", $dirId )->where( 'status', '=', 0 )->get();
348
        $subdir = Directory::with( 'medium.medium', 'template.template', 'manufacturer' )->find( $dirId );
348
        $subdir = Directory::with( 'medium.medium', 'template.template', 'manufacturer' )->find( $dirId );
349
        $subdir["subdirs"] = $dirs->reject( function ( $value, $key )
349
        $subdir["subdirs"] = $dirs->reject( function ( $value )
350
        {
350
        {
351
            return $value->articlemaster == 1;
351
            return $value->articlemaster == 1;
352
        } );
352
        } );
353
        $subdir["items"] = $items;
353
        $subdir["items"] = $items;
354
        $template = 'subdir';
354
        $template = 'subdir';
Zeile 376... Zeile 376...
376
                    $startPrice = min( $preise );
376
                    $startPrice = min( $preise );
377
                    $dir->anz = count( $items );
377
                    $dir->anz = count( $items );
378
                    $dir->mehrerePreise = count( array_unique( $preise ) ) > 1;
378
                    $dir->mehrerePreise = count( array_unique( $preise ) ) > 1;
379
                    $dir->startpreis_tpl = $startPrice;
379
                    $dir->startpreis_tpl = $startPrice;
380
                }
380
                }
381
                $subdir["items"] = $dirs->filter( function ( $value, $key )
381
                $subdir["items"] = $dirs->filter( function ( $value )
382
                {
382
                {
383
                    return $value->articlemaster == 1;
383
                    return $value->articlemaster == 1;
384
                } );
384
                } );
385
                /*$artstaemmeItems[$dir->id] = $dir;
385
                /*$artstaemmeItems[$dir->id] = $dir;
386
                $artstaemmeItems[$dir->id]["items"] = Item::with( 'medium.medium', 'price', 'manufacturer' )->where( 'directory_id', '=', $dir->id )->where( 'status', '=', 0 )->get();*/
386
                $artstaemmeItems[$dir->id]["items"] = Item::with( 'medium.medium', 'price', 'manufacturer' )->where( 'directory_id', '=', $dir->id )->where( 'status', '=', 0 )->get();*/
Zeile 403... Zeile 403...
403
 
403
 
404
 
404
 
405
    function getRechnungsLaender(): array
405
    function getRechnungsLaender(): array
406
    {
406
    {
407
        $arr = array();
407
        $arr = array();
408
        $laender = DB::connection( 'cms' )->select( 'SELECT id,name_de FROM countries WHERE rank > 0 ORDER BY rank' );
408
        $laender = DB::connection( 'cms' )->select( 'SELECT id,name_de FROM content_management.countries WHERE `rank` > 0 ORDER BY `rank`' );
409
        foreach ( $laender as $land )
409
        foreach ( $laender as $land )
410
        {
410
        {
411
            $arr[$land->id] = $land->name_de;
411
            $arr[$land->id] = $land->name_de;