[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpcompta-dev] r4364 - phpcompta/trunk/include
From: |
phpcompta-dev |
Subject: |
[Phpcompta-dev] r4364 - phpcompta/trunk/include |
Date: |
Tue, 15 Nov 2011 21:55:47 +0100 (CET) |
Author: danydb
Date: 2011-11-15 21:55:45 +0100 (Tue, 15 Nov 2011)
New Revision: 4364
Modified:
phpcompta/trunk/include/class_acc_ledger_purchase.php
phpcompta/trunk/include/class_acc_ledger_sold.php
phpcompta/trunk/include/class_acc_payment.php
Log:
Fix small bugs payment method by ledger
Modified: phpcompta/trunk/include/class_acc_ledger_purchase.php
===================================================================
--- phpcompta/trunk/include/class_acc_ledger_purchase.php 2011-11-15
20:40:50 UTC (rev 4363)
+++ phpcompta/trunk/include/class_acc_ledger_purchase.php 2011-11-15
20:55:45 UTC (rev 4364)
@@ -733,7 +733,7 @@
/* jrnx */
$acseq=$this->db->get_next_seq('s_grpt');
- $acjrn=new Acc_Ledger($this->db,$mp->get_parameter('ledger'));
+ $acjrn=new
Acc_Ledger($this->db,$mp->get_parameter('ledger_target'));
$acinternal=$acjrn->compute_internal_code($acseq);
/* Insert paid by */
@@ -757,7 +757,7 @@
$acc_pay->amount=abs(round($cust_amount,2));
$acc_pay->desc=$e_comm;
$acc_pay->grpt=$acseq;
- $acc_pay->jrn=$mp->get_parameter('ledger');
+ $acc_pay->jrn=$mp->get_parameter('ledger_target');
$acc_pay->periode=$tperiode;
$acc_pay->type=($cust_amount>=0)?'c':'d';
$acc_pay->insert_jrnx();
@@ -770,7 +770,7 @@
$acc_pay->amount=abs(round($cust_amount,2));
$acc_pay->desc=$e_comm;
$acc_pay->grpt=$acseq;
- $acc_pay->jrn=$mp->get_parameter('ledger');
+ $acc_pay->jrn=$mp->get_parameter('ledger_target');
$acc_pay->periode=$tperiode;
$acc_pay->type=($cust_amount>=0)?'d':'c';
$let_other=$acc_pay->insert_jrnx();
@@ -819,7 +819,8 @@
echo '<span class="error">'.
'Erreur dans l\'enregistrement '.
__FILE__.':'.__LINE__.' '.
- $e->getMessage().$e->getTrace();
+ $e->getMessage().$e->getTraceAsString();
+
$this->db->rollback();
exit();
}
Modified: phpcompta/trunk/include/class_acc_ledger_sold.php
===================================================================
--- phpcompta/trunk/include/class_acc_ledger_sold.php 2011-11-15 20:40:50 UTC
(rev 4363)
+++ phpcompta/trunk/include/class_acc_ledger_sold.php 2011-11-15 20:55:45 UTC
(rev 4364)
@@ -493,7 +493,7 @@
/* jrnx */
$acseq=$this->db->get_next_seq('s_grpt');
- $acjrn=new Acc_Ledger($this->db,$mp->get_parameter('ledger'));
+ $acjrn=new
Acc_Ledger($this->db,$mp->get_parameter('ledger_target'));
$acinternal=$acjrn->compute_internal_code($acseq);
/* Insert paid by */
@@ -517,7 +517,7 @@
$acc_pay->amount=abs(round($cust_amount,2));
$acc_pay->desc=$e_comm;
$acc_pay->grpt=$acseq;
- $acc_pay->jrn=$mp->get_parameter('ledger');
+ $acc_pay->jrn=$mp->get_parameter('ledger_target');
$acc_pay->periode=$tperiode;
$acc_pay->type=($cust_amount>=0)?'d':'c';
$acc_pay->insert_jrnx();
@@ -530,7 +530,7 @@
$acc_pay->amount=abs(round($cust_amount,2));
$acc_pay->desc=$e_comm;
$acc_pay->grpt=$acseq;
- $acc_pay->jrn=$mp->get_parameter('ledger');
+ $acc_pay->jrn=$mp->get_parameter('ledger_target');
$acc_pay->periode=$tperiode;
$acc_pay->type=($cust_amount>=0)?'c':'d';
$let_other=$acc_pay->insert_jrnx();
@@ -1284,7 +1284,7 @@
$r.="</DIV>";
return $r;
}
-
+
/*!\brief test function
*/
static function test_me($p_string='')
Modified: phpcompta/trunk/include/class_acc_payment.php
===================================================================
--- phpcompta/trunk/include/class_acc_payment.php 2011-11-15 20:40:50 UTC
(rev 4363)
+++ phpcompta/trunk/include/class_acc_payment.php 2011-11-15 20:55:45 UTC
(rev 4364)
@@ -69,7 +69,10 @@
return $this->$idx;
}
else
+ {
+ throw new Exception("Attribut inexistant $p_string");
exit (__FILE__.":".__LINE__.'Erreur attribut inexistant');
+ }
}
public function set_parameter($p_string,$p_value)
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpcompta-dev] r4364 - phpcompta/trunk/include,
phpcompta-dev <=