Forum: Rails France Helpers et ActionMailer

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Ralph H. (Guest)
on 2009-03-02 13:13
Salut y a t'il un moyen d'utiliser les helpers dans les modules
ActionMailer ?
Stéphane Akkaoui (Guest)
on 2009-03-02 13:20
(Received via mailing list)
Le 2 mars 09 à 12:13, Ralph H. a écrit :

>
> Salut y a t'il un moyen d'utiliser les helpers dans les modules
> ActionMailer ?

Oui.
Avec la methode helper.
(http://api.rubyonrails.org/classes/ActionControlle...
)

exemple :
class Notifier < ActionMailer::Base
   helper ApplicationHelper

   ...
end

HTH,

--
Stéphane Akkaoui
http://imeuble.info
http://sociabliz.com
Ralph H. (Guest)
on 2009-03-02 14:09
je m escuse svp mais je n arrive tjrs pas a envoye les mails malgre que
j ai ajoute le module helper

application_helper.rb
def cal
end

class Infomailer < ActionMailer::Base
   helper ApplicationHelper

et ds le view /app/views/infomailer/send_mailer.html.erb

<%= cal %>


?????????????????????????????
Joël AZÉMAR (Guest)
on 2009-03-02 14:24
(Received via mailing list)
class Infomailer < ActionMailer::Base
    helper :application

2009/3/2 Ralph H. <removed_email_address@domain.invalid>
Ralph H. (Guest)
on 2009-03-02 14:30
class Infomailer < ActionMailer::Base
    helper :application

sans success !!!!!!!!!!!!!


je ny comprend plus rien la
Stéphane Akkaoui (Guest)
on 2009-03-02 14:41
(Received via mailing list)
Le 2 mars 09 à 13:30, Ralph H. a écrit :

>
> class Infomailer < ActionMailer::Base
>    helper :application

Normalement, d'après la doc, helper accepte indifféremment les nom de
module ou les symbole.

Du coup si l'un ne marche pas, il est logique que l'autre non plus.

Tu peux nous montrer les logs de l'erreur ?

--
Stéphane Akkaoui
http://sociabliz.com
http://imeuble.info
Ralph H. (Guest)
on 2009-03-02 14:53
Processing PagesController#send_orderprice (for 192.168.1.203 at
2009-03-02 15:15:49) [POST]
  Session ID:
BAh7BzoLbG9jYWxlIgdydSIKZmxhc2hJQzonQWN0aW9uQ29udHJvbGxlcjo6%0ARmxhc2g6OkZsYXNoSGFzaHsABjoKQHVzZWR7AA%3D%3D--8ec70590aa5452f16dc3072c2bef56868a30de3d
  Parameters: {"order"=>{"order_type"=>"Новый ", "panel_num"=>"2",
"y_paneli"=>"222", "provodnik"=>">=0.15", "structure"=>"не задана",
"e_test"=>"да", "number"=>"2", "y_plati"=>"222", "surface"=>">=0.15",
"dieletrik"=>"FR4", "plat_type"=>"жесткая", "tolshina"=>"2",
"postavka"=>"нет", "x_paneli"=>"222", "pokrit_plo"=>"горячее 
лужение
(HASL)", "glu"=>"нет", "dateline"=>"2", "sloev"=>"2", "folga"=>"18 и/или
35 мкм", "x_plati"=>"222", "impedance"=>"нет", "standart_ipc"=>"IPC
class 2"}, "action"=>"send_orderprice", "controller"=>"pages"}
WARNING: You're using the Ruby-based MySQL library that ships with
Rails. This library is not suited for production. Please install the
C-based MySQL library instead (gem install mysql).
PAGE NOT FOUND for front_end/pages send_orderprice
Rendering template within layouts/pages
Rendering pages/orderprice
Ralph H. (Guest)
on 2009-03-02 14:55
voila ce ke montre le log en fait il nya pas d erreurs mais a cause de
la valeur provenant du helper ke j utilise il me redirect vers l action
precedente et sans cette valeur il envoi le mail sans probleme
This topic is locked and can not be replied to.