From eb5c69edb357249baf9fdf37b5e95de573ae3277 Mon Sep 17 00:00:00 2001 From: max-baranikov Date: Wed, 21 Sep 2022 17:03:29 +0300 Subject: [PATCH] Added versioning for the settings page frontend files --- .../templates/RetailcrmSettingsTemplate.php | 4 ++++ retailcrm/views/index.html | 1 - retailcrm/views/templates/admin/index.tpl | 24 +++++++++++++++---- 3 files changed, 24 insertions(+), 5 deletions(-) delete mode 100644 retailcrm/views/index.html diff --git a/retailcrm/lib/templates/RetailcrmSettingsTemplate.php b/retailcrm/lib/templates/RetailcrmSettingsTemplate.php index 9eac062..fe9b9a6 100644 --- a/retailcrm/lib/templates/RetailcrmSettingsTemplate.php +++ b/retailcrm/lib/templates/RetailcrmSettingsTemplate.php @@ -42,6 +42,10 @@ class RetailcrmSettingsTemplate extends RetailcrmAbstractTemplate { $this->data = [ 'assets' => $this->assets, + 'appVersioning' => [ + 'app' => filemtime(_PS_MODULE_DIR_ . '/retailcrm/views/js/app.js'), + 'chunk-vendors' => filemtime(_PS_MODULE_DIR_ . '/retailcrm/views/js/chunk-vendors.js'), + ], 'appData' => [ 'locale' => $this->getCurrentLanguageISO(), 'debug' => RetailcrmTools::isDebug(), diff --git a/retailcrm/views/index.html b/retailcrm/views/index.html deleted file mode 100644 index 360f168..0000000 --- a/retailcrm/views/index.html +++ /dev/null @@ -1 +0,0 @@ -prestashop
diff --git a/retailcrm/views/templates/admin/index.tpl b/retailcrm/views/templates/admin/index.tpl index c236fc4..b26d750 100644 --- a/retailcrm/views/templates/admin/index.tpl +++ b/retailcrm/views/templates/admin/index.tpl @@ -34,8 +34,24 @@ * Don't forget to prefix your containers with your own identifier * to avoid any conflicts with others containers. *} - -{include file='./../../index.html'} + + + + + + + + prestashop + + + + + +
+ + + + +