diff --git a/site/blueprints/pages/product.yml b/site/blueprints/pages/product.yml index 1e51ea9..9963f7b 100644 --- a/site/blueprints/pages/product.yml +++ b/site/blueprints/pages/product.yml @@ -1 +1,25 @@ title: Produit + +tabs: + contentTab: + columns: + - width: 1/3 + sections: + gallery: + label: Galerie + type: files + layout: cards + min: 1 + max: 1 + - width: 2/3 + fields: + price: + label: Prix + type: number + after: € + width: 1/3 + description: + type: writer + nodes: false + marks: false + width: 2/3 diff --git a/site/blueprints/pages/shop.yml b/site/blueprints/pages/shop.yml new file mode 100644 index 0000000..37ea190 --- /dev/null +++ b/site/blueprints/pages/shop.yml @@ -0,0 +1,10 @@ +title: Boutique + +tabs: + contentTab: + sections: + products: + label: Produits + type: pages + template: product + ratio: 4/3 diff --git a/site/config/config.php b/site/config/config.php index 1395ec8..d761de4 100644 --- a/site/config/config.php +++ b/site/config/config.php @@ -22,4 +22,7 @@ return [ ], ], ], + 'panel' => [ + 'menu' => require_once __DIR__ . '/menu.php' + ] ]; \ No newline at end of file diff --git a/site/config/menu.php b/site/config/menu.php new file mode 100644 index 0000000..c9eabe6 --- /dev/null +++ b/site/config/menu.php @@ -0,0 +1,22 @@ + [ + 'label' => 'Soutien', + 'icon' => 'home', + 'link' => 'pages/support', + 'current' => function ($current) { + $path = Kirby::instance()->request()->path()->toString(); + return Str::contains($path, 'pages/support'); + }, + ], + 'shop' => [ + 'label' => 'Boutique', + 'icon' => 'cart', + 'link' => 'pages/boutique', + 'current' => function ($current) { + $path = Kirby::instance()->request()->path()->toString(); + return Str::contains($path, 'pages/boutique'); + }, + ], +]; \ No newline at end of file diff --git a/site/templates/shop.php b/site/templates/shop.php new file mode 100644 index 0000000..e69de29 diff --git a/site/templates/support.php b/site/templates/support.php index 09937e3..a39a081 100644 --- a/site/templates/support.php +++ b/site/templates/support.php @@ -144,55 +144,18 @@

Vous pouvez également soutenir Index en commandant des articles disponibles sur notre boutique.

-
-
- -
-

T-shirt Index 01

-

35€

- -
- - + children() as $product): ?>
-
- -
- -

Publication

-

Éclairages/Spotlights

-

35€

- -
- -
-
- -
-

Casquette

-

35€

- -
- - -
-
- -
-

T-shirt Index 01

-

35€

- -
- -
-
- -
-

Publication

-

Éclairages/Spotlights

-

35€

+ hasFiles()): ?> +
+ +
+ +

title() ?>

+ description() ?>
+