noalyss-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Noalyss-commit] [noalyss] 04/04: Bug : remove information when coming f


From: Dany De Bontridder
Subject: [Noalyss-commit] [noalyss] 04/04: Bug : remove information when coming from an operation template
Date: Mon, 29 Feb 2016 00:41:52 +0000

sparkyx pushed a commit to branch master
in repository noalyss.

commit b1cafb3e70575830bad449eb38bf278d9b902345
Author: Dany De Bontridder <address@hidden>
Date:   Mon Feb 29 01:31:07 2016 +0100

    Bug : remove information when coming from an operation template
---
 html/js/acc_ledger.js                   |    1 -
 include/class/class_acc_ledger_sold.php |    1 -
 include/compta_ach.inc.php              |    4 ++--
 include/compta_fin.inc.php              |    2 +-
 include/compta_ven.inc.php              |    4 ++--
 include/operation_ods_new.inc.php       |    4 ++--
 6 files changed, 7 insertions(+), 9 deletions(-)

diff --git a/html/js/acc_ledger.js b/html/js/acc_ledger.js
index 487a40d..ad61786 100644
--- a/html/js/acc_ledger.js
+++ b/html/js/acc_ledger.js
@@ -241,7 +241,6 @@ function success_update_bank(req)
  */
 function get_last_date()
 {
-    if (String.trim(document.getElementsByName('e_date')[0].value) != "") 
return;
     var jrn = g('p_jrn').value;
     var dossier = g('gDossier').value;
     var qs = 'gDossier=' + dossier + '&op=lastdate&p_jrn=' + jrn;
diff --git a/include/class/class_acc_ledger_sold.php 
b/include/class/class_acc_ledger_sold.php
index aa17334..cfc81d1 100644
--- a/include/class/class_acc_ledger_sold.php
+++ b/include/class/class_acc_ledger_sold.php
@@ -1028,7 +1028,6 @@ EOF;
         else
             $op_date = (!isset($e_date) ) ? '' : $e_date;
 
-
         $e_ech = (isset($e_ech)) ? $e_ech : "";
         $e_comm = (isset($e_comm)) ? $e_comm : "";
 
diff --git a/include/compta_ach.inc.php b/include/compta_ach.inc.php
index 240e85d..fa0fa25 100644
--- a/include/compta_ach.inc.php
+++ b/include/compta_ach.inc.php
@@ -254,7 +254,7 @@ try
     $payment=HtmlInput::default_value_request("e_mp", 0);
     echo "<FORM class=\"print\"NAME=\"form_detail\" METHOD=\"POST\" >";
     /* request for a predefined operation */
-    if (isset($_REQUEST['pre_def'])&&!isset($_POST['correct']))
+    if (isset($_REQUEST['pre_def'])&&!isset($_POST['correct']) && ! 
isset($correct) )
     {
         // used a predefined operation
         //
@@ -296,7 +296,7 @@ catch (Exception $e)
     alert($e->getMessage());
     return;
 }
-if (!isset($_POST['e_date']) && $g_parameter->MY_DATE_SUGGEST=='Y')
+if (!isset($_REQUEST['e_date']) && $g_parameter->MY_DATE_SUGGEST=='Y')
        echo create_script(" get_last_date()");
 echo create_script(" update_name()");
 echo '</div>';
diff --git a/include/compta_fin.inc.php b/include/compta_fin.inc.php
index 136b567..fdeae11 100644
--- a/include/compta_fin.inc.php
+++ b/include/compta_fin.inc.php
@@ -151,7 +151,7 @@ try
     echo HtmlInput::submit('save',_('Sauve'));
     echo HtmlInput::reset(_('Effacer'));
 
-    if ( ! isset ($_POST['e_date'])&& $g_parameter->MY_DATE_SUGGEST=='Y')
+    if ( ! isset($_REQUEST['e_date'])&& $g_parameter->MY_DATE_SUGGEST=='Y')
     {
             echo create_script(" get_last_date();ajax_saldo('first_sold');");
     }else {
diff --git a/include/compta_ven.inc.php b/include/compta_ven.inc.php
index 68877f1..d7ffd22 100644
--- a/include/compta_ven.inc.php
+++ b/include/compta_ven.inc.php
@@ -269,7 +269,7 @@ try
 
     echo "<FORM class=\"print\" NAME=\"form_detail\" METHOD=\"POST\" >";
     /* request for a predefined operation */
-    if (isset($_REQUEST['pre_def'])&&!isset($_POST['correct']))
+    if (isset($_REQUEST['pre_def'])&&!isset($_POST['correct']) && ! 
isset($correct))
     {
         // used a predefined operation
         //
@@ -334,7 +334,7 @@ echo '<div class="content">';
     {
                echo '<script> update_pj()</script>';
     }
-       if (!isset($_POST['e_date']) && $g_parameter->MY_DATE_SUGGEST=='Y')
+       if (!isset($_REQUEST['e_date']) && $g_parameter->MY_DATE_SUGGEST=='Y')
        {
                echo create_script(" get_last_date()");
        }
diff --git a/include/operation_ods_new.inc.php 
b/include/operation_ods_new.inc.php
index 396b871..99e8a5a 100644
--- a/include/operation_ods_new.inc.php
+++ b/include/operation_ods_new.inc.php
@@ -61,7 +61,7 @@ echo '</div>';
 // Show the predef operation
 // Don't forget the p_jrn
 $p_post=$_POST;
-if ( isset ($_GET['action']) && ! isset($_POST['correct']))
+if ( isset ($_GET['action']) && ! isset($_POST['correct']) && ! 
isset($correct) )
 {
        if ( $_GET['action']=='use_opd')
        {
@@ -108,7 +108,7 @@ echo '</form>';
 echo "<script>checkTotalDirect();</script>";
 echo create_script(" update_name()");
 
-if ($g_parameter->MY_DATE_SUGGEST=='Y')
+if (!isset($_REQUEST['e_date']) && $g_parameter->MY_DATE_SUGGEST=='Y')
 {
        echo create_script(" get_last_date()");
 }



reply via email to

[Prev in Thread] Current Thread [Next in Thread]