đź’ś
storelocator
  • Overview
  • Installation
    • Setup Module
    • Extension Version Update
  • Config and Usage
    • Module Configuration Admin Site
    • Add Filter Tag’s and Categories
    • Add Storelocator
    • List StoreLocator at frontend page
    • Location Details Page
    • Run cron job to import storelocator items
    • Use couponcode for Lof Followup email
    • Use couponcode for Newsletter
    • How to use on frontend
    • Video Tutorial
    • FAQ
      • How to custom layout xml and template?
      • How to add content over slide image?
      • How to setup sample profile?
  • Other Module Guides
    • Magento 2 Step Recommendation
Powered by GitBook
On this page
  1. Config and Usage

Run cron job to import storelocator items

PreviousLocation Details PageNextUse couponcode for Lof Followup email

Last updated 2 years ago

On new version of the module we added cron job function allow import store locator information, tags, categories into database by csv files.

  • You should create 2 folders, and config permission 0777 for them:

pub/storelocator : the folder you will input the csv files which you want to import.

var/storelocator_imported : the folder will store the imported csv files.

  • You can config enable/disable cron job in admin > Store > Configuration > Landofcoder > Store locator > Scheduled Import Location Settings

  • To run cron job task of the module, please run command via SSH terminal:

  • php bin/magento cron:run –group=lof_storelocator

Also you can force run the cron job task click on menu item: admin > Landofcoder > Store Locator > Force Run Cron Job

Before run cron job, you should add the csv file into the folder “pub/storelocator/”. You can view the sample file at here:

To add tag and categories for storelocator item you should add the columns in csv file as this:

1.Tags:

tag_name : can use comma to add more tag name

tag_description : can use the char | to add more tag description

tag_position: can use the char | to add more tag position

For example:

tag_name,tag_description,tag_position

“tag name 1,tag name 2,tag name 3″,”tag desc1|tag desc2″,”1|2|3”

2.Categories:

category_name : can use comma to add more category name

category_description : can use the char | to add morecategory description

category_position: can use the char | to add morecategory position

For example:

category_name,category_description,category_position

“category name 1,category name 2,category name 3″,”category desc1|category desc2″,”1|2|3”

Note:

  • If you want to import new information for exist store locator item, you should add column “id“

  • If you want to import store locator for multi store views. You should add the value (store view ids of your site) for the column “store_id“. Use comma for multi store view, For example: 2,3,4

sample_storelocator.csv