links on message page (back to list, reply, forward)

master-old
Eugene Korbut 2009-02-08 06:06:12 +10:00
parent a997c9d97a
commit 9c9ccc429d
4 changed files with 11 additions and 10 deletions

1
.gitignore vendored
View File

@ -3,3 +3,4 @@ config/database.yml
.*.sw?
config/site.rb
tmp
mail_temp

View File

@ -124,7 +124,7 @@ class WebmailController < ApplicationController
@mail = prepare_mail
@mail.reply(@tmail, fb, get_mail_prefs.mail_type)
render_action("compose")
render :action => 'compose'
end
def forward
@ -136,7 +136,7 @@ class WebmailController < ApplicationController
@mail = prepare_mail
@mail.forward(@tmail, fb)
render_action("compose")
render :action => 'compose'
end
def compose

View File

@ -30,7 +30,7 @@
<div id="topmenu">
<ul class="actionmenu">
<li>
<%= link_to(_("&#171; Back to list"), :controller=>"/webmail/webmail", :action=>"messages") %>
<%= link_to(_("&#171; Back to list"), :controller=>"webmail", :action=>"messages") %>
</li>
<li><%=link_reply_to_sender(@msg_id)%></li>
<li><%=link_forward_message(@msg_id)%></li>

View File

@ -140,13 +140,13 @@ class CDF::Mail
end
def reply(tmail, fb, type)
decoded_subject = mime_encoded?(tmail.subject) ? mime_decode(tmail.subject) : tmail.subject
self.subject = "[Re: #{decoded_subject}]"
tm = tmail.setup_reply(tmail)
self.to = tm.to
footer = ""
msg_id = ""
mt = MailTransform.new
decoded_subject = mime_encoded?(tmail.subject) ? mime_decode(tmail.subject) : tmail.subject
self.subject = "Re: #{decoded_subject}"
tm = tmail.create_reply
self.to = tm.to
footer = ""
msg_id = ""
mt = MailTransform.new
self.body = mt.get_body(tmail, type)
end