Customer Dependent Pricing / Line Discounts

Time to read: 6 minutes


Introduction

This module was used to implement extensive pricing rules and discount regulations in the PepperShop. A PepperShop in the Enterprise version is required.

In contrast to the line discount rules, which are only displayed in the shopping basket, customer pricing already runs in the article catalog and therefore shows each registered customer or their groups their specific price immediately.

Pricing rules are very flexible and are defined per customer, customer price group, currency and date.

By import you can import complete pricing rules from ERP systems and update the shop periodically (CSV based).

Info 1: In addition to this accounts receivable pricing module, the pricing module1 is also available from the PepperShop Professional level onwards. With this module you can implement further control mechanisms on the basis of programmed pricing rules.

Info 2: Additionally, with the Enterprise Module Best Price Finding1, a system can be put into operation in the PepperShop that finds the best price for the customer (promotion / quantity discounts / voucher campaigns / …).

How the module works

Description of the application

Pricing is anchored quite deeply in the shop system, so that it is valid not only for the product catalogue but also for product search, product portal exports and the ordering and payment process.

This module provides CSV-based rule import for price definitions and discount definitions. CSV data is entered as a table via Excel and exported as a CSV file. You reference products, product discount groups, customers and customer price groups or customer discount groups.

Assignment of data

The assignment of products and customers is done by assigning so-called group fields or the respective ID. As soon as the module is installed, the following addition appears in the shop administration screens:

Article:

  • discount groups

Customer:

  • debitor number
  • debitor price group
  • debitor discount group

In this way, you can divide your assortment into discount groups and assign your customers to the customer price groups or discount groups (bronze, silver, gold and standard -> no group).

Difference between pricing and discounting

A note on the difference between pricing and discounting:

  • With pricing rules, people see their own prices immediately after logging in. This is very intuitive, so that a Gold Member for example immediately sees all item prices adjusted, not just as a discount in the shopping cart.
  • Line discount rules are displayed as discounts in the shopping cart.

Delivery of rules

The rules are delivered in a CSV file. CSV files correspond to Excel spreadsheets that have been saved under this format.

One rule is delivered per line. You can define prices per product, currency, period, quantity (scaling), which you then release to a customer, a customer group or for all. The narrower the target group (scope of the rule), the higher the priority of the rule.

You also specify for each rule whether the price can also be discounted (line discount rule). The system also tries to display the desired price on the basis of a best price determination and rejects contradictory rules (action cheaper than group price, …).

Define pricing as Excel file

Pricing rules are applied immediately and are already visible in the product catalogue from the product list level.

Now follows the description of the columns of an Excel file which can be delivered to the shop in CSV format:

CSV column name Data type Comment
Sales type enum('Debitor', 'Debitorenpreisgruppe', 'Alle Debitoren') 1
Sales code varchar(255) Customer number for sales type ‘Debitor’ Customer price group for sales type Debitorenpreisgruppe1
Product no varchar(255) 1
Currency char(3) chf,usd,eur,…1
Minimum order quantity double
Price double 1
Active from datetime(yyyyy-mm-dd hh:mm:ss) ..or date(yyyyy-mm-dd)
Active to datetime(yyyyy-mm-dd hh:mm:ss) ..or date(yyyyy-mm-dd)
Line discount allowed enum('true', 'false')

The file is delivered in the shop administration in the Caller Navigator at set_debitorenpreise. See also chapter Supplying price data.

Define row discounts as Excel file

Line discounts are only visible in the shopping cart.

CSV column name Data type Comment
Sales type enum('Debitor', 'Debitorenrabattgruppe', 'Alle Debitoren') 1
Sales code varchar(255) Debitor number for sales type Debitor Debitorenrabattgruppe for sales type Debitorenrabattgruppe 1
Type enum('Artikel', 'Artikelrabattgruppe') 1
Code varchar(255) Product no for type Article Article discount group for type Article discount group 1
Currency char(3) Currency code chf,eur,usd,… blank for discounts regardless of currency 1
Minimum order quantity double
Line discount double Discount in % (0 up to 100)
Active from datetime(yyyyy-mm-dd hh:mm:ss) ..or date(yyyyy-mm-dd)
Active to datetime(yyyyy-mm-dd hh:mm:ss) ..or date(yyyyy-mm-dd)
discount type varchar(255) freely usable

The file is delivered to the shop administration in the Caller Navigator at set_zeilenrabatte. See also chapter Supplying price data.

Deliver price data

Import of the created CSV file via Shop Administration → Import/Export → Caller-Navigator.

The following screenshot shows the relevant part of the import options:

Figure 1: Sample display for import of pricing data (Excel exports)

Installation

Requirements

In order to use the Accounts Receivable Pricing/Line Discounts module, a PepperShop Enterprise version 6.0 or higher is required.

Copy and upload files

The module essentially consists of three files that you have to copy into your installed PepperShop (contains the standard PepperShop pricing module). First unzip the included ZIP archive. The following files are included, shown here with the target directories:

{shopdir}/shop/debitorenpreise.def.php
{shopdir}/shop/preisfindung.def.php
{shopdir}/shop/preisfindung_helper.def.php

The files can be easily uploaded via FTP or SCP to the web server. The placeholder {shopdir} stands for the shop directory on the web server, where the file index.php together with README.txt can be found.

Module installation

After copying the files, the module is immediately ready for use.

Activation / deactivation / basic configuration

There is a central configuration control for the activation and deactivation of this module:

File: {shopdir}/shop/config.inc.php

PREISFINDUNG_VERWENDEN (default = false)
If the pricing module is installed, you can use this constant to control whether a special pricing for article prices is to be carried out.

If there is a false in the constant definition of PREISFINDUNG_VERWENDEN, the module is deactivated and all programming is not used. If there is a true, the module is active.

The following control constant can be used to deactivate pricing for the article list. This should be considered carefully. The default value is = true (switched on). You only save performance.

PREISFINDUNG_AUF_ERSTER_STUFE_VERWENDEN (default = true)
If the pricing module is installed and activated, you can use this constant to control whether pricing should also be applied to the first article level (tabular overview display of all articles in a category) when the two-level article display is activated. If, for example, external calls occur in ERP systems, you may want to use false here - then the customer will only see ‘his’ price in the detailed view, but the performance is ok.

PepperShop Enterprise API Reference

Documentation / API:

Please open this page in your browser:

Open the PDF document Data exchange API (direct link)

Go to chapter 11 on page 14 / 15 / 16 for a description of the two calls:

  • set_debitorenpreise
  • set_zeilenrabatte (discounts)

🌶️
🔥
🌶️