From 6acf00a556e1180564d5845211beb70016d61195 Mon Sep 17 00:00:00 2001
From: Juan Ferrer Toribio
Date: Mon, 22 Jan 2018 09:52:43 +0100
Subject: [PATCH] Code and DB refactor
---
conf/apache.conf | 1 -
conf/config.php | 3 +--
debian/changelog | 2 +-
debian/control | 2 +-
forms/account/address-list/address-list.js | 2 +-
forms/account/address-list/ui.xml | 4 ++--
forms/account/address/ui.xml | 2 +-
forms/account/conf/ui.xml | 2 +-
forms/admin/users/users.js | 4 ++--
forms/ecomerce/checkout/ui.xml | 18 +++++++++---------
forms/ecomerce/confirm/ui.xml | 16 ++++++++--------
package.json | 2 +-
12 files changed, 28 insertions(+), 30 deletions(-)
diff --git a/conf/apache.conf b/conf/apache.conf
index c502e40a..d572f9cb 100644
--- a/conf/apache.conf
+++ b/conf/apache.conf
@@ -22,4 +22,3 @@
AllowOverride FileInfo Options
Require all granted
-
diff --git a/conf/config.php b/conf/config.php
index b70f7288..e237a29c 100644
--- a/conf/config.php
+++ b/conf/config.php
@@ -12,7 +12,7 @@
*
* - http://www.mydomain.org -> config.www.php
* - http://test.mydomain.org -> config.test.php
- **/
+ */
return [
/**
@@ -27,4 +27,3 @@ return [
]
];
-
diff --git a/debian/changelog b/debian/changelog
index 4a3246f8..2aa1a9f6 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-hedera-web (1.405.72) stable; urgency=low
+hedera-web (1.405.73) stable; urgency=low
* Initial Release.
diff --git a/debian/control b/debian/control
index f3611f39..e2022a32 100644
--- a/debian/control
+++ b/debian/control
@@ -4,7 +4,7 @@ Maintainer: Juan Ferrer Toribio
Build-Depends: build-essential, debhelper, nodejs
Standards-Version: 3.9.3
Section: misc
-Homepage: http://www.verdnatura.es
+Homepage: https://verdnatura.es
Vcs-Git: https://git.verdnatura.es/hedera-web
Package: hedera-web
diff --git a/forms/account/address-list/address-list.js b/forms/account/address-list/address-list.js
index 710fb324..527cc6da 100644
--- a/forms/account/address-list/address-list.js
+++ b/forms/account/address-list/address-list.js
@@ -26,7 +26,7 @@ Hedera.AddressList = new Class
{
if (confirm (_('AreYouSureDeleteAddress')))
{
- form.set ('active', false);
+ form.set ('isActive', false);
form.refresh ();
}
}
diff --git a/forms/account/address-list/ui.xml b/forms/account/address-list/ui.xml
index 3baab1ed..4623a1a6 100644
--- a/forms/account/address-list/ui.xml
+++ b/forms/account/address-list/ui.xml
@@ -11,11 +11,11 @@
SELECT a.id, a.nickname, p.name province, a.postalCode,
- a.city, a.street, a.active, c.country
+ a.city, a.street, a.isActive, c.country
FROM myAddress a
LEFT JOIN vn.province p ON p.id = a.provinceFk
JOIN vn.country c ON c.id = p.countryFk
- WHERE a.active != FALSE
+ WHERE a.isActive
diff --git a/forms/account/address/ui.xml b/forms/account/address/ui.xml
index 0596de11..0406dfdd 100644
--- a/forms/account/address/ui.xml
+++ b/forms/account/address/ui.xml
@@ -15,7 +15,7 @@
FROM myAddress a
LEFT JOIN vn.province p ON p.id = a.provinceFk
JOIN vn.country c ON c.id = p.countryFk
- WHERE a.active AND a.id = #address
+ WHERE a.id = #address
diff --git a/forms/account/conf/ui.xml b/forms/account/conf/ui.xml
index c4d51e37..6e74d98e 100644
--- a/forms/account/conf/ui.xml
+++ b/forms/account/conf/ui.xml
@@ -53,7 +53,7 @@
- SELECT code, name FROM language WHERE active
+ SELECT code, name FROM language WHERE isActive
diff --git a/forms/admin/users/users.js b/forms/admin/users/users.js
index 28076b39..52a1de8b 100644
--- a/forms/admin/users/users.js
+++ b/forms/admin/users/users.js
@@ -26,9 +26,9 @@ Hedera.Users = new Class
this.onUserSupplant.bind (this));
}
- ,onUserSupplant: function (userName)
+ ,onUserSupplant: function ()
{
- this.hash.set ({'form': 'ecomerce/orders'});
+ this.hash.set ({form: 'ecomerce/orders'});
}
});
diff --git a/forms/ecomerce/checkout/ui.xml b/forms/ecomerce/checkout/ui.xml
index c5826442..1c1ba068 100644
--- a/forms/ecomerce/checkout/ui.xml
+++ b/forms/ecomerce/checkout/ui.xml
@@ -123,20 +123,20 @@
renderer="addressRenderer">
- SELECT a.id, a.consignee, p.name province, a.zip_code, a.city, a.name, a.active, c.Pais country
- FROM address_view a
- LEFT JOIN vn2008.province p ON a.province_id = p.province_id
- JOIN vn2008.Paises c ON c.Id = p.Paises_Id
- WHERE active != FALSE
+ SELECT a.id, a.nickname, p.name province, a.city, a.street, a.isActive, c.country
+ FROM myAddress a
+ LEFT JOIN vn.province p ON p.id = a.provinceFk
+ JOIN vn.country c ON c.id = p.countryFk
+ WHERE a.isActive
@@ -171,7 +171,7 @@
-
+
Agency
@@ -191,7 +191,7 @@
-
+
ReceiveThroughtRoute
diff --git a/forms/ecomerce/confirm/ui.xml b/forms/ecomerce/confirm/ui.xml
index b59a46f9..bf9898b9 100644
--- a/forms/ecomerce/confirm/ui.xml
+++ b/forms/ecomerce/confirm/ui.xml
@@ -6,13 +6,13 @@
CALL basketGetTax;
SELECT o.id, o.date_send, o.note, o.company_id,
ag.description agency, v.code method,
- ad.consignee, ad.zip_code, ad.city, ad.name address,
+ ad.nickname, ad.postalCode, ad.city, ad.street,
t.*, c.credit, myClientGetDebt(NULL) debt
FROM basket o
- JOIN vn2008.Agencias ag ON ag.Id_Agencia = o.agency_id
- LEFT JOIN address_view ad ON ad.id = o.address_id
- JOIN vn2008.Vistas v ON v.vista_id = o.delivery_method_id
- JOIN customer_view c
+ JOIN vn.agencyMode ag ON ag.id = o.agency_id
+ LEFT JOIN myAddress ad ON ad.id = o.address_id
+ JOIN vn.deliveryMethod v ON v.id = o.delivery_method_id
+ JOIN myClient c
JOIN (
SELECT
IFNULL(SUM(taxBase), 0) taxBase,
@@ -47,13 +47,13 @@
diff --git a/package.json b/package.json
index 6ef9071e..fcc92c8f 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "hedera-web",
- "version": "1.405.72",
+ "version": "1.405.73",
"description": "Verdnatura web page",
"license": "GPL-3.0",
"repository": {