Removes check on Xorg NL validation to always send text, adds text sending to events...
authorPierre-Etienne Marx <pierre-etienne.marx_git@polytechnique.org>
Mon, 8 Apr 2013 09:55:06 +0000 (11:55 +0200)
committerPierre-Etienne Marx <pierre-etienne.marx_git@polytechnique.org>
Tue, 9 Apr 2013 21:15:36 +0000 (23:15 +0200)
include/validations/evts.inc.php
include/validations/nl.inc.php

index 7437e7e..70a33c8 100644 (file)
@@ -131,6 +131,19 @@ class EvtReq extends Validate
     }
 
     // }}}
+    // {{{ function _mail_ps
+
+    protected function _mail_ps($isok)
+    {
+        $maildate = make_datetime($this->expiration)->format('d / m / Y');
+        return "\nPS : pour rappel, en voici le contenu :"
+            . "\n--------------------------------------------------------------------------\n"
+            . $this->titre
+            . "\n--------------------------------------------------------------------------\n"
+            . $this->texte . "\n\nPour les promotions de " . $this->pmin . " à " . $this->pmax . ", avec expiration le " . $maildate . ".\n";
+    }
+
+    // }}}
     // {{{ function commit()
 
     public function commit()
index e939bd4..2fc3678 100644 (file)
@@ -92,9 +92,6 @@ class NLReq extends Validate
 
     protected function _mail_ps($isok)
     {
-        if ($isok) {
-            return '';
-        }
         return "\nPS : pour rappel, en voici le contenu :"
             . "\n--------------------------------------------------------------------------\n"
             . $this->art->title()