[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Noalyss-commit] [noalyss] 01/08: Task #0001421: Détail fiche : recherc
From: |
Dany De Bontridder |
Subject: |
[Noalyss-commit] [noalyss] 01/08: Task #0001421: Détail fiche : recherche poste comptable |
Date: |
Sat, 25 Mar 2017 08:29:39 -0400 (EDT) |
sparkyx pushed a commit to branch master
in repository noalyss.
commit 5f0e1d149c1e5aae5c98b0d63a8b30e334891b49
Author: Dany De Bontridder <address@hidden>
Date: Fri Mar 24 23:47:53 2017 +0100
Task #0001421: Détail fiche : recherche poste comptable
---
include/ajax/ajax_card.php | 3 ++-
include/class/class_fiche.php | 13 ++++++++-----
include/lib/class_iposte.php | 2 +-
3 files changed, 11 insertions(+), 7 deletions(-)
diff --git a/include/ajax/ajax_card.php b/include/ajax/ajax_card.php
index 6c6d515..22b9a7b 100644
--- a/include/ajax/ajax_card.php
+++ b/include/ajax/ajax_card.php
@@ -114,6 +114,7 @@ case 'rmfa':
catch (Exception $e)
{
$cn->rollback();
+ record_log($e->getTraceAsString());
echo $e->getMessage();
}
$html=ob_get_contents();
@@ -136,7 +137,7 @@ case 'dc':
$can_modify=0;
}
if ( $can_modify==1)
- $card=$f->Display(false);
+ $card=$f->Display(false,$ctl);
else
$card=$f->Display(true);
if ( $card == 'FNT' )
diff --git a/include/class/class_fiche.php b/include/class/class_fiche.php
index c4e5d02..062daeb 100644
--- a/include/class/class_fiche.php
+++ b/include/class/class_fiche.php
@@ -539,11 +539,12 @@ class Fiche
* \brief Display object instance, getAttribute
* sort the attribute and add missing ones
* \param $p_readonly true= if can not modify, otherwise false
- *
+ *\param string $p_in if called from an ajax it is the id of the html
+ * elt containing
*
* \return string to display or FNT string for fiche non trouvé
*/
- function Display($p_readonly)
+ function Display($p_readonly,$p_in="")
{
$this->GetAttribut();
$attr=$this->attribut;
@@ -579,8 +580,9 @@ class Fiche
if ($r->ad_id==ATTR_DEF_ACCOUNT)
{
$w=new IPoste("av_text".$r->ad_id);
+ $w->id=$p_in."av_text".$r->ad_id;
$w->set_attribute('ipopup', 'ipop_account');
- $w->set_attribute('account', "av_text".$r->ad_id);
+ $w->set_attribute('account', $w->id);
$w->dbl_click_history();
// account created automatically
$w->table=0;
@@ -854,6 +856,7 @@ class Fiche
}
catch (Exception $e)
{
+ record_log($e->getTraceAsString());
$this->cn->rollback();
throw ($e);
return;
@@ -994,8 +997,8 @@ class Fiche
echo '<span class="error">'.
$e->getMessage().
'</span>';
- error_log($e->getMessage());
- error_log($e->getTraceAsString());
+ record_log($e->getMessage());
+ record_log($e->getTraceAsString());
$this->cn->rollback();
return;
}
diff --git a/include/lib/class_iposte.php b/include/lib/class_iposte.php
index a8d887f..71e10a6 100644
--- a/include/lib/class_iposte.php
+++ b/include/lib/class_iposte.php
@@ -194,7 +194,7 @@ class IPoste extends HtmlInput
*/
public function dbl_click_history()
{
- $r='
ondblclick="get_history_account(\''.$this->name.'\',\''.dossier::id().'\')"';
+ $r='
ondblclick="get_history_account(\''.$this->id.'\',\''.dossier::id().'\')"';
$this->javascript=$r;
}
static public function test_me()
- [Noalyss-commit] [noalyss] branch master updated (70e0a4e -> 0aa186b), Dany De Bontridder, 2017/03/25
- [Noalyss-commit] [noalyss] 01/08: Task #0001421: Détail fiche : recherche poste comptable,
Dany De Bontridder <=
- [Noalyss-commit] [noalyss] 08/08: Task #1419: Déconnexion dans le popup Add a close window button for the ajax disconnect Fix bug, Dany De Bontridder, 2017/03/25
- [Noalyss-commit] [noalyss] 07/08: Security : improve a potential weakness, Dany De Bontridder, 2017/03/25
- [Noalyss-commit] [noalyss] 02/08: task #1420: Fonction error_log manquante, Dany De Bontridder, 2017/03/25
- [Noalyss-commit] [noalyss] 06/08: task #0001422: Installation : améliorer la page, Dany De Bontridder, 2017/03/25
- [Noalyss-commit] [noalyss] 05/08: 1418: Affichage Balance - soldes et sous-totaux, Dany De Bontridder, 2017/03/25
- [Noalyss-commit] [noalyss] 03/08: Task #1420: Fonction error_log manquante Generalisation de la fonction, Dany De Bontridder, 2017/03/25
- [Noalyss-commit] [noalyss] 04/08: Update translation, Dany De Bontridder, 2017/03/25