From 7abc42831ea24d20a46312224f429f78270b337a Mon Sep 17 00:00:00 2001
From: Damien <damien.burel@maarch.org>
Date: Tue, 17 Apr 2018 17:05:57 +0200
Subject: [PATCH] [VERSION] Only branch in database xml

---
 .../class/class_business_app_tools_Abstract.php                 | 2 +-
 apps/maarch_entreprise/xml/database_version.xml                 | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/apps/maarch_entreprise/class/class_business_app_tools_Abstract.php b/apps/maarch_entreprise/class/class_business_app_tools_Abstract.php
index b901bf3fe8e..e0e72dadf53 100755
--- a/apps/maarch_entreprise/class/class_business_app_tools_Abstract.php
+++ b/apps/maarch_entreprise/class/class_business_app_tools_Abstract.php
@@ -635,7 +635,7 @@ abstract class business_app_tools_Abstract extends Database
             $_SESSION['maarch_entreprise']['database_version'] = "none";
         } else {
             $vbg = $stmt->fetchObject();
-            $_SESSION['maarch_entreprise']['database_version'] = $vbg->param_value_string;
+            $_SESSION['maarch_entreprise']['database_version'] = substr($vbg->param_value_string, 0, 5);
             $_SESSION['maarch_entreprise']['database_version_minor'] = $vbg->param_value_string;
         }
         //If this two parameters is not find, this is the end of this function
diff --git a/apps/maarch_entreprise/xml/database_version.xml b/apps/maarch_entreprise/xml/database_version.xml
index e4f1e794e92..260422cc6e9 100755
--- a/apps/maarch_entreprise/xml/database_version.xml
+++ b/apps/maarch_entreprise/xml/database_version.xml
@@ -1,4 +1,4 @@
 <?xml version="1.0" encoding="utf-8"?>
 <root>
-    <database_version>18.04.1</database_version> <!-- 18.04 -->
+    <database_version>18.04</database_version> <!-- 18.04 -->
 </root>
-- 
GitLab