Improved process with custom plugins for Craft CMS and Craft Commerce

Posted by Gary Renes on 2017-11-21

Plugins can be created to add all sorts of additional functionality to a Craft CMS site, but how can we use them to improve business workflow and processes?

One of the great things about Craft CMS is how easily it can be extended by using plugins. Building plugins for Craft is relatively quick and painless - there's even an online service that will quickly generate the plugin boiler plate for you. Part of the reason it's so easy to build plugins for Craft is because it's built on a decent MVC framework that uses component based development out of the box, as well as it having a number of useful events built in.

While we generally install a number of standard plugins to a Craft CMS build at the start of each project (post on this coming soon), we've found that by using custom plugins we can improve the functionality of the system for a number of business use cases that are not handled as standard with Craft or Commerce.

For example, one of our clients wanted us to help them use the CMS to run their and back-office processes. These processes previously involved a lot of manual work, using data exports and Excel spreadsheets. In this case, we could use plugins to improve functionality that would never be seen or used by a front-end user.

The Client

Makers Shed is a family run eCommerce business shipping hundreds of custom orders a month. Due to the volume of orders and the nature of its business, there is no avoiding some manual back-office work. However, a suitably customised Craft CMS and Craft Commerce build can help cut down on, if not fully alleviate, the majority of this manual process work.

Order Processing - Printing Invoices and Labels

Commerce comes with functionality to generate a single invoice - but what if you to generate ten or twenty at a time? We built a Batch plugin to do just this. By adding custom Element Actions to a plugin we can add new features to the Commerce / Orders page of the CMS.

Craft Commerce Orders dropdown
The Commerce Orders dropdown gets superpowers with the Batch plugin enabled.

We also added functionality to batch print branded address labels and invoices using the PHP FPDF library. This additional functionality allows us to generate as many PDF invoices and address labels as we need from the Commerce / Orders page, and send them straight to the printer.

Reporting - Cutting and Customisation Reports

One of the great things about the Makers Shed website is the ability for customers to customise many of the products. Each of the customised products needs to be programmed as a cutting file to a CNC machine, and it can be tedious work manually figuring out which products require customisation, and how many of each product need to be produced.

The Batch plugin is also responsible for sifting through orders and producing reports on which products needs to be customised, and how many of each item needs to be produced.

Custom Orders - Custom Shopping Baskets

In addition to the above, Makers Shed customers often ask for custom products to be created that are not listed on the website. To implement this functionality we created two Product Types in Craft, Main and Custom. Custom products are only accessible on the front end of the site if you have the product URL, and are not indexed by search engines. They are essentially invisible unless you know where to look for them!

We also developed a Customise Basket plugin for Craft. When coupled with Custom Product Types, this functionality allows an admin user to create a custom product, add it to a shopping cart for the user, and then send them an email to notify them that their basket and custom order is ready. When the customer clicks the link in the email, their shopping cart is pre-populated with their products, and they can continue the customer experience as desired by adding further products, changing quantities, and proceeding through checkout.

Shipping Times & Dispatch Dates

As an order will take a certain amount of time to produce (depending on how busy the business is), giving the customer an accurate dispatch can help manage their expectations appropriately, as well as eliminate the need for additional support calls and emails.

For this reason, we built a Dispatch Date Estimator plugin for the Makers Shed website. The plugin takes in to account UK holidays (using the excellent Yasumi PHP library), as well as dates the business will be closed (managed as Entries in the CMS). With this additional functionaliy, we can now give the customer an estimated date of dispatch. This date is then sent out on every piece of communication to the customer relating to their order.


As we’ve shown, custom plugin development for Craft and Craft Commerce can be used to in a number of different ways to alleviate some of the more repetitive tasks of running a business. Due to its flexibility, custom plugins for Craft can add an wide array of features for both front-end and back-end users of your website. If you’d like something similar for your project, get in touch and we'd be happy to help.

Red Robot Digital Ltd
4 Beau Street

t: 0845 004 0045

Social Media