Creating and Configuring Channels
A channel is an avenue for selling products, such as a customer portal, a B2B marketplace, or back office phone sales. You must link a channel to a site to sell products on that site. Clarity operates two online stores, one for B2C customers and one for B2B customers. To support this, you must help Kyle create two channels and link them to their corresponding sites.
To create a channel,
-
Open the Global Menu () and navigate to Commerce → Channels.
-
Click Add () and enter the following details:
Name: Clarity B2C
Currency: USD
Type: Site
-
Click Add.
This creates a new channel for the B2C store. Repeat the steps to create a B2B channel with the following information.
Name | Currency | Type |
---|---|---|
Clarity B2B | USD | Site |
After creating both channels, you must link them to the corresponding Liferay sites and configure them.
Configuring the B2C Channel
For the B2C channel, you’ll configure a payment method, shipping method, and ensure that the site type is set to B2C.
-
In the Details section, set the Commerce Site Type to B2C. When the site type is B2C, every account in the site must be a personal account.
-
Select the Type tab and click Select Site.
-
Choose the Clarity B2C site
-
Click Save.
You can now use this channel to accept customer orders from your site.
Clarity offers their B2C customers an option to pay by PayPal. Customer orders are shipped using a flat rate shipping method. You can use Liferay’s out-of-the-box payment and shipping methods to implement both of these.
Configuring PayPal
-
Visit the PayPal Developer Dashboard and sign up for an account.
-
Switch to Sandbox mode.
-
Navigate to the Apps & Credentials tab.
-
Click Create App.
-
Enter Clarity as the name and set the type as Merchant.
-
Click Create App.
This creates the app with a name, client ID, and secret key.
-
Copy the client ID and secret key.
-
Now, go back to your Liferay instance. Open the Global Menu () and navigate to Commerce → Channels.
-
Select Clarity B2C.
-
Scroll down to the Payment Methods section and select PayPal.
-
Activate it using the toggle.
-
Click Save.
-
Go to the Configuration tab and paste the client ID and secret key copied from PayPal.
-
Set the Mode to sandbox.
-
Click Save.
Configuring Flat Rate Shipping Method
-
Go to the Shipping Methods section and select Flat Rate.
-
Activate it using the toggle.
-
Click Save.
-
Go to the Shipping Options page, click the Add () button.
-
Enter the name as Regular Shipping and amount as $4.99.
-
Click Save.
-
Click Add () once more.
-
Enter the name as Express Shipping and amount as $9.99.
-
Click Save.
Configuring the B2B Channel
For the B2B channel, you’ll configure a payment method, shipping method, and ensure that the site type is set to B2B.
-
In the Details section, set the Commerce Site Type to B2B. When the site type is B2B, every account in the site must be a business account.
-
Select the Type tab and click Select Site.
-
Choose the Clarity B2B site.
-
Click Save.
Clarity offers their B2B customers an option to pay by money order. They ship using a variable shipping rate that’s calculated based on the weight of the shipment. You can use Liferay’s out-of-the-box payment and shipping methods to implement both of these.
Configuring Money Order
-
Go to the Payment Methods section and select Money Order.
-
Activate it using the toggle.
-
Click Save.
This should be eligible for all order types.
Configuring Variable Rate Shipping Method
-
Now, go to the Shipping Methods section and select Variable Rate.
-
Activate it using the toggle.
-
Click Save.
-
Go to the Shipping Options page and click Add ().
-
Enter the name as Standard Shipping and click Save.
-
Go to Shipping Option Settings and click Add ().
-
Select the shipping option created earlier from the drop-down.
-
In the Settings section, enter the following details:
Shipping Option: Standard Shipping
Weight From: 0.0
Weight To: 10.0
Fixed Price: 4.99
Price per Unit of Weight: 2.99
-
Repeat this two more times with the following details:
Shipping Option Weight From Weight To Fixed Price Price per Unit of Weight Standard Shipping 10.01 20.0 5.99 3.99 Standard Shipping 20.01 30.0 6.99 4.99
In the next section, you’ll set up order notifications and enable buyer order approval workflows. This shows how the order life cycle changes when there’s a workflow in place, and how users are notified when an order is accepted.
Next: Configuring Workflows and Notifications