From 8005e0dbcef67389673194d4187fc9a5e9bc72f0 Mon Sep 17 00:00:00 2001 From: sparkyx Date: Mon, 18 Jan 2021 15:35:33 +0100 Subject: [PATCH] =?UTF-8?q?Tache=200001885:=20=20postes=20utilisables=20da?= =?UTF-8?q?ns=20Op=C3=A9ration=20ODS?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- html/js/accounting_item.js | 4 ++++ include/class/acc_ledger.class.php | 1 - include/class/fiche.class.php | 3 +++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/html/js/accounting_item.js b/html/js/accounting_item.js index f7445bb81..c58b0e6e0 100644 --- a/html/js/accounting_item.js +++ b/html/js/accounting_item.js @@ -77,6 +77,10 @@ function search_poste(obj) if ( obj.jrn) { queryString+="&j="+obj.jrn; + }else { + if ($("p_jrn")) { + queryString+="&j="+$("p_jrn").value; + } } if ( obj.account) { diff --git a/include/class/acc_ledger.class.php b/include/class/acc_ledger.class.php index d7efb992f..e9683ee31 100644 --- a/include/class/acc_ledger.class.php +++ b/include/class/acc_ledger.class.php @@ -927,7 +927,6 @@ class Acc_Ledger extends jrn_def_sql // Account $poste=new IPoste(); $poste->name='poste'.$i; - $poste->set_attribute('jrn', $this->id); $poste->set_attribute('ipopup', 'ipop_account'); $poste->set_attribute('label', 'ld'.$i); $poste->set_attribute('account', 'poste'.$i); diff --git a/include/class/fiche.class.php b/include/class/fiche.class.php index f2f8a01e7..e4942bb4a 100644 --- a/include/class/fiche.class.php +++ b/include/class/fiche.class.php @@ -477,6 +477,7 @@ class Fiche { $w=new IPoste("av_text".$attr->ad_id); $w->set_attribute('ipopup','ipop_account'); + $w->set_attribute('jrn','0'); $w->set_attribute('account',"av_text".$attr->ad_id); $w->dbl_click_history(); // account created automatically @@ -639,6 +640,7 @@ class Fiche $w->id=$p_in."av_text".$r->ad_id; $w->set_attribute('ipopup', 'ipop_account'); $w->set_attribute('account', $w->id); + $w->set_attribute('jrn','0'); $w->dbl_click_history(); // account created automatically $w->table=0; @@ -696,6 +698,7 @@ class Fiche $w->table=0; $bulle=Icon_Action::infobulle(14); $w->value=$r->av_text; + $w->set_attribute('jrn','0'); break; case 'card': $uniq=rand(0, 1000);