NAME

Dancer::Plugin::Nitesi::Routes - Routes for Nitesi Shop Machine

ROUTES

The following routes are automatically created by this plugin:

cart (/cart)

Route for displaying and updating the cart.

checkout (/checkout)

Route for the checkout process.

Route for displaying navigation pages, for example categories and menus.

product

Route for displaying products.

CONFIGURATION

The template for each route type can be configured:

plugins:
  Nitesi::Routes:
    cart:
      template: cart
    checkout:
      template: checkout
    navigation:
      template: listing
    product:
      template: product

This sample configuration shows the current defaults.

HOOKS

The following hooks are available to manipulate the values passed to the templates:

before_product_display

The hook sub receives the product data as hash reference.

before_cart_display
before_checkout_display
before_navigation_display

The hook sub receives the navigation data as hash reference. The list of products is the value of the products key.