diff --git a/modules/newsletter/actions.php b/modules/newsletter/actions.php index 48f1ff1dc..21810e5b7 100755 --- a/modules/newsletter/actions.php +++ b/modules/newsletter/actions.php @@ -40,7 +40,7 @@ switch (filter('op')) { $newsletter->completed_at = filter('completed_at'); $newsletter->subject = filter('subject'); - $newsletter->content = filter('content'); + $newsletter->content = $_POST['content']; //filter('content'); $newsletter->save(); diff --git a/templates/partitario_mastrino/init.php b/templates/partitario_mastrino/init.php index d5d484369..a705f2d66 100644 --- a/templates/partitario_mastrino/init.php +++ b/templates/partitario_mastrino/init.php @@ -27,7 +27,7 @@ if (get('lev') == '3') { $conto2 = $dbo->fetchOne('SELECT * FROM co_pianodeiconti2 WHERE id='.prepare($conto3['idpianodeiconti2'])); $conto1 = $dbo->fetchOne('SELECT * FROM co_pianodeiconti1 WHERE id='.prepare($conto2['idpianodeiconti1'])); // Movimenti - $records = $dbo->fetchArray('SELECT * FROM co_movimenti WHERE idconto='.prepare($id_record).' AND co_movimenti.data>='.prepare($date_start).' AND co_movimenti.data<='.prepare($date_end)); + $records = $dbo->fetchArray('SELECT * FROM co_movimenti WHERE idconto='.prepare($id_record).' AND co_movimenti.data>='.prepare($date_start).' AND co_movimenti.data<='.prepare($date_end).' ORDER BY co_movimenti.data'); } elseif (get('lev') == '2') { $records = $dbo->fetchArray('SELECT CONCAT(co_pianodeiconti3.numero, " ",co_pianodeiconti3.descrizione) AS descrizione, SUM(totale) AS totale FROM `co_movimenti` INNER JOIN co_pianodeiconti3 ON co_movimenti.idconto=co_pianodeiconti3.id WHERE idconto IN(SELECT id FROM co_pianodeiconti3 WHERE idpianodeiconti2='.prepare($id_record).') AND co_movimenti.data>='.prepare($date_start).' AND co_movimenti.data<='.prepare($date_end).' GROUP BY idconto HAVING totale!=0'); $conto2 = $dbo->fetchOne('SELECT * FROM co_pianodeiconti2 WHERE id='.prepare($id_record));