Back to Top

Akeneo Auto SKU Generator

Updated 29 March 2023

Introduction

With the help of this module, the merchants can generate the SKU automatically in Akeneo. This module will help the merchants to save lots of time and manual work to generate the SKU in Akeneo. If the store owners generate the SKU automatically in Akeneo then they can easily add the other product details and increase the efficiency of creating products. This module will work for product and product variants in Akeneo to generate the product SKU.

Check an overview of the plugin functionality –

sODH7pKMIYo

Basic Requirements:

  • This module works with Akeneo 2.0.x, 2.1.x, 2.2.x, 2.3.x, 3.0.x, 3.1.x, 3.2.x, 4.0.x,5.0.x,6.0.x and 7.0.x. Download Akeneo from here
  • Node and Yarn packages need to be installed.
  • This module is compatible with the Akeneo community and Enterprise(Flexibility) edition.
  • If you want to use this extension on Akeneo EE Serenity mode, please contact us.
  • For the Akeneo installation, your Akeneo server should meet these system requirements.

Features

  • It will reduce the duplicity of the products.
  • It will save time and also reduces manual work.
  • The user can predefine the prefix and suffix to generate the SKU.
  • This module is compatible with the latest Akeneo version 7.0.x
  • The modules will be helpful in generating thousand of SKUs in less time which will increase productivity.
  • The user can generate the SKU for simple and variant both types of products.
  • The user can set the pattern for generating the SKU.

Composer Installation

Read This Blog

Before beginning the composer installation

1: Get the ACCESS KEYS [Create a support ticket]
2: In Akeneo composer.json, add our repository as well as the installation script.

Searching for an experienced
Akeneo Company ?
Find out More

For Akeneo 6.x and 7.x

{
  "scripts": {
        "post-update-cmd": [
           "vendor/webkul/autoskugeneratorbundle/src/Webkul/AutoSkuGeneratorBundle/install/config.sh COMPOSER=true NO_DOCKER=true"
        ],
        "post-install-cmd": [
           "vendor/webkul/autoskugeneratorbundle/src/Webkul/AutoSkuGeneratorBundle/install/config.sh COMPOSER=true NO_DOCKER=true"
        ],
        "post-create-project-cmd": [
          "vendor/webkul/autoskugeneratorbundle/src/Webkul/AutoSkuGeneratorBundle/install/config.sh COMPOSER=true NO_DOCKER=true"
       ]
   },
  "repositories": [{
    "type": "composer",
    "url": "https://akeneorepo.webkul.com/"
  }]
}

For Akeneo <=5.x 

{
  "scripts": {
        "post-update-cmd": [
           
"vendor/webkul/autoskugeneratorbundle/composer_install.sh"
        ],
        "post-install-cmd": [
           
"vendor/webkul/autoskugeneratorbundle/composer_install.sh"
        ],
        "post-create-project-cmd": [
         
"vendor/webkul/autoskugeneratorbundle/composer_install.sh"
       ]
   },
  "repositories": [{
    "type": "composer",
    "url": "https://akeneorepo.webkul.com/"
  }]
}

3: Use composer to install the extension.

        composer require webkul/autoskugeneratorbundle

4: Complete the authentication form.
5: Send a Message of Success
6: Delete your browser’s cache.

Manual Installation For Akeneo 6 and 7

  •  After unzipping the appropriate extension zip, merge the “src” folder into the akeneo project.
  • From the PIM directory, run the following command over the NO-DOCKER Instance.
./src/Webkul/AutoSkuGeneratorBundle/install/config.sh COMPOSER=false NO_DOCKER=true
  •  Run the command below over the PIM directory’s DOCKER instance.
./src/Webkul/AutoSkuGeneratorBundle/install/config.sh COMPOSER=false NO_DOCKER=false

Module Installation for Version 4. x to 5. x

Please follow the below steps for installing the Akeneo Auto SKU Generator module in your Akeneo PIM platform.

1. Unzip the respective extension zip then merge the “src” folder into the akeneo project root directory.

src_4_x-all-mod

2. Goto config/Bundles.php then add the line:

Webkul\AutoSkuGeneratorBundle\AutoSkuGeneratorBundle::class => ['all' => true],
Screenshot-from-2021-02-25-10-47-41

3- Copy the “config” folder into akeneo project root directory for routing.

conf-new

4. You have to navigate first to Akeneo installation directory (Ex: cd /opt/bitnami/apps/akeneo/htdocs). After SSH, you have to run the command to your Akeneo server by the terminal.

  rm -rf ./var/cache/ && php bin/console cache:warmup && php bin/console skugenerator:setup:install

5. If you are using php-fpm then you need to restart the php-fpm services and apache web server.

For Akeneo 5

sudo service php-fpm7.4 restart

For Akeneo 4

sudo service php-fpm7.3 restart

Docker Installation Command :

For Akeneo 5

alias docker_php='docker-compose run -u www-data --rm php php';
alias docker_yarn='docker-compose run -u node --rm node yarn';
docker_php bin/console cache:clear --env=prod;
docker_php bin/console pim:installer:assets --symlink --clean --env=prod;
docker_php bin/console d:s:u --force;
docker_yarn run webpack;
docker_yarn run update-extensions;
docker_yarn run less;

For Akeneo 4

alias docker_php='docker-compose run -u www-data --rm php php';
alias docker_yarn='docker-compose run -u node --rm node yarn';
docker_php bin/console cache:clear --env=prod;
docker_php bin/console pim:installer:assets --symlink --clean --env=prod;
docker_php bin/console d:s:u --force;
docker_yarn run webpack;
docker_yarn run less;

Module Installation for Version 2.x to 3.x

Please follow the below steps for installing the Akeneo Auto SKU Generator module in your Akeneo PIM platform.

  • Unzip the respective extension zip then merge the “src” folder into Akeneo project root directory.
Akeneo-autoSKUgenerator-installation-1
  • Goto app/AppKernel.php then add the following line in function registerProjectBundles()
new Webkul\AutoSkuGeneratorBundle\AutoSkuGeneratorBundle(),
Akeneo-autoSKUgenerator-installation3
  • Goto app/config/routing.yml then add these lines at top of the file
Akeneo-autoSKUgenerator-installation2
autoSkuGenerator:
        resource: "@AutoSkuGeneratorBundle/Resources/config/routing.yml"
        prefix: /

You have to navigate first to Akeneo installation directory (Ex: cd /opt/bitnami/apps/akeneo/htdocs). After SSH, you have to run the command to your Akeneo server by the terminal.

rm -rf ./var/cache/ && php bin/console cache:warmup && php bin/console skugenerator:setup:install

After that, you need to restart your web server like Apache, Nginx. Run the below command for Apache web server.

sudo service apache2 restart

If you are using php-fpm. Then you need to restart the php-fpm services.

sudo service php-fpm7.2 restart

Common Issues After Installation

It might happen that even after proper installation, upon opening your Akeneo admin dashboard, you see a loading screen. In that case, do check for the following solution:

  • Webpack Installation: If you get the below error

It means that a web pack is not installed in your system. Run the following command

npm install --save-prod webpack npm install
  • Module routing.yml is not configured properly. Re-check the routing.yml file as mentioned in the 3rd step of Module Installation
  • Clear your browser cache.

Uninstall Module: For Akeneo 6 and 7

  • From the PIM directory, run the command below over the NO-DOCKER Instance.
./src/Webkul/AutoSkuGeneratorBundle/uninstall/uninstall.sh COMPOSER=false NO_DOCKER=true
  • Run the command below over the PIM directory’s DOCKER instance.
./src/Webkul/AutoSkuGeneratorBundle/uninstall/uninstall.sh COMPOSER=false NO_DOCKER=false

Module Configuration

After successfully installing the module in Akeneo, you need to set up the Auto SKU Generator configuration first.

You will see the Auto Sku Generator icon in Akeneo from the bottom left as shown below.

Dashboard-5-1

After clicking on the Auto SKU generator, you can see the Auto SKU Generator page.

So here, you have to follow the below settings:

  • Auto SKU Start Sequence From: Here, you have to define the number in digits from where SKU should start.

Note: Given SKU Sequence must be greater than created SKU.

  • Autogenerate SKU Options: Select the attribute label for autogenerating SKU. A respected attribute code will appear in SKU if you have applied that option to the product. This will appear just after the defined prefix. This support select type, text type, and number type attribute.
  • Prefix: Define prefix, it supports alphanumeric numbers.
  • Suffix: Define suffix, it also supports alphanumeric numbers.
  • SKU Separator: Select the required separator from the drop-down.
  • Select Default Locale: Choose the default locale from the dropdown, and the selected locale value will be added to the SKU generated.
sku-credential

Create a Product Model in Akeneo

To create a new product in Akeneo

1 – Go to Products > Create then select the Product option.

Akeneo-auto-SKU-generator-create-product

2 – Here, you’ll get the SKU number. This SKU would be constant mean you can’t modify it.

After that choose a product family.

Note: When you’ll create the next product, the SKU number automatically will increase.

Products-11

3 – After that, fill in all the product information for this new product.

Product-model-Braided-Hat-_-Edit

Once you’ll save the product, SKU will be created automatically as shown below:

Product-Braided-hat-_-Edit

That’s all about the Akeneo Auto SKU Generator module. Now, the user can generate SKU for their product automatically in Akeneo.

Support

Moreover, For any issues related to this module, please create a support ticket at- https://webkul.uvdesk.com/en/customer/create-ticket Also, for any pre-sales queries or customization discussion, please drop an email to [email protected]

Please explore our Akeneo Development Services and Quality Akeneo Extensions.

Current Product Version - 2 to 5 || 2.0.0, Akeneo 6 || 3.0.0 and Akeneo 7 || 4.0.0

Supported Framework Version - Akeneo 2.0.x, 2.1.x, 2.2.x , 2.3.x, 3.0.x, 3.1.x, 3.2.x, 4.0.x, 5.0.x, 6.0.x and 7.0.x

Blog Version - Akeneo 2.0.x, 2.1.x, 2.2.x , 2.3.x, 3.0.x, 3.1.x, 3.2.x, 4.0.x, 5.0.x, 6.0.x and 7.0.x
  • Version Akeneo 2.0.x, 2.1.x, 2.2.x , 2.3.x, 3.0.x, 3.1.x, 3.2.x, and 4.0.x
  • Version Akeneo 2.0.x, 2.1.x, 2.2.x , 2.3.x, 3.0.x, 3.1.x, 3.2.x, 4.0.x, 5.0.x, 6.0.x and 7.0.x
  • Version Akeneo 2.0.x, 2.1.x, 2.2.x , 2.3.x, 3.0.x, 3.1.x, 3.2.x, 4.0.x, 5.0.x and 6.0.x
  • Version Akeneo 2.0.x, 2.1.x, 2.2.x , 2.3.x, 3.0.x, 3.1.x, 3.2.x, 4.0.x and 5.0.x
  • Version Akeneo 2.0.x, 2.1.x, 2.2.x , 2.3.x, 3.0.x, 3.1.x and 3.2.x
. . .

Leave a Comment

Your email address will not be published. Required fields are marked*


4 comments

  • Thibault
    • Adarsh Shukla (Moderator)
  • Marwan
    • Adarsh Shukla (Moderator)
  • Back to Top

    Message Sent!

    If you have more details or questions, you can reply to the received confirmation email.

    Back to Home

    Table of Content