webmail_controller moded from components to app
This commit is contained in:
parent
789f813b42
commit
ab8bf72949
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,3 +1,4 @@
|
||||||
log
|
log
|
||||||
config/database.yml
|
config/database.yml
|
||||||
.*.sw?
|
.*.sw?
|
||||||
|
config/site.rb
|
||||||
|
|
|
@ -19,7 +19,7 @@ class LoginController < ApplicationController
|
||||||
session["wmp"] = params['login_user']["password"]
|
session["wmp"] = params['login_user']["password"]
|
||||||
end
|
end
|
||||||
if session["return_to"]
|
if session["return_to"]
|
||||||
redirect_to_path(session["return_to"])
|
redirect_to(session["return_to"])
|
||||||
session["return_to"] = nil
|
session["return_to"] = nil
|
||||||
else
|
else
|
||||||
redirect_to :action=>"index"
|
redirect_to :action=>"index"
|
||||||
|
|
|
@ -4,7 +4,7 @@ require 'net/imap'
|
||||||
require 'mail2screen'
|
require 'mail2screen'
|
||||||
require 'ezcrypto'
|
require 'ezcrypto'
|
||||||
|
|
||||||
class Webmail::WebmailController < ApplicationController
|
class WebmailController < ApplicationController
|
||||||
# uses_component_template_root
|
# uses_component_template_root
|
||||||
|
|
||||||
# Administrative functions
|
# Administrative functions
|
||||||
|
@ -365,7 +365,7 @@ class Webmail::WebmailController < ApplicationController
|
||||||
load_folders
|
load_folders
|
||||||
rescue Exception => ex
|
rescue Exception => ex
|
||||||
logger.error("Exception on loggin webmail session - #{ex} - #{ex.backtrace.join("\t\n")}")
|
logger.error("Exception on loggin webmail session - #{ex} - #{ex.backtrace.join("\t\n")}")
|
||||||
render_action "error_connection"
|
render :action => "error_connection"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
require 'cdfutils'
|
require 'cdfutils'
|
||||||
require 'mail2screen'
|
require 'mail2screen'
|
||||||
|
|
||||||
module Webmail::WebmailHelper
|
module WebmailHelper
|
||||||
include Mail2Screen
|
include Mail2Screen
|
||||||
def link_folders
|
def link_folders
|
||||||
link_to(_('Folders'), :controller=>"/webmail/webmail", :action=>"messages")
|
link_to(_('Folders'), :controller=>"/webmail/webmail", :action=>"messages")
|
|
@ -5,7 +5,7 @@ ActionController::Routing::Routes.draw do |map|
|
||||||
# Here's a sample route:
|
# Here's a sample route:
|
||||||
# map.connect 'products/:id', :controller => 'catalog', :action => 'view'
|
# map.connect 'products/:id', :controller => 'catalog', :action => 'view'
|
||||||
# Keep in mind you can assign values other than :controller and :action
|
# Keep in mind you can assign values other than :controller and :action
|
||||||
map.connect '', :controller=>'webmail/webmail', :action=>'index'
|
map.connect '', :controller=>'webmail', :action=>'index'
|
||||||
|
|
||||||
map.connect 'webmail', :controller=>'webmail/webmail', :action=>'index'
|
map.connect 'webmail', :controller=>'webmail/webmail', :action=>'index'
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue