Allows negative amounts in the column Autre (Closes #919).
authorStéphane Jacob <sj@m4x.org>
Fri, 6 Nov 2009 21:22:22 +0000 (22:22 +0100)
committerStéphane Jacob <sj@m4x.org>
Sat, 7 Nov 2009 13:05:24 +0000 (14:05 +0100)
ChangeLog
modules/xnetevents.php

index ed76879..8beb078 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -38,6 +38,7 @@ Bug/Wish:
         - #983: Fixes issue with the professional email publicity          -JAC
 
     * XnetEvents:
+        - #919: Allows negative amounts in the column "Autre"              -JAC
         - #979: Fixes javascript for people who paid but did not book      -JAC
         - #985: Adds payment related email lists for events                -JAC
 
index de2fe0d..ebde459 100644 (file)
@@ -553,10 +553,9 @@ class XnetEventsModule extends PLModule
             // change the price paid by a participant
             if (Env::v('adm') == 'prix' && $member) {
                 XDB::execute("UPDATE groupex.evenements_participants
-                                 SET paid = IF(paid + {?} > 0, paid + {?}, 0)
+                                 SET paid = paid + {?}
                                WHERE uid = {?} AND eid = {?} AND item_id = 1",
                         strtr(Env::v('montant'), ',', '.'),
-                        strtr(Env::v('montant'), ',', '.'),
                         $member['uid'], $evt['eid']);
             }