dev cont
This commit is contained in:
parent
7de07db812
commit
0daf487816
0
Gemfile.lock
Normal file → Executable file
0
Gemfile.lock
Normal file → Executable file
0
app/assets/images/glyphicons-halflings-white.png
Normal file → Executable file
0
app/assets/images/glyphicons-halflings-white.png
Normal file → Executable file
Before Width: | Height: | Size: 4.3 KiB After Width: | Height: | Size: 4.3 KiB |
0
app/assets/images/glyphicons-halflings.png
Normal file → Executable file
0
app/assets/images/glyphicons-halflings.png
Normal file → Executable file
Before Width: | Height: | Size: 4.3 KiB After Width: | Height: | Size: 4.3 KiB |
0
app/assets/images/rails.png
Normal file → Executable file
0
app/assets/images/rails.png
Normal file → Executable file
Before Width: | Height: | Size: 6.5 KiB After Width: | Height: | Size: 6.5 KiB |
0
app/assets/javascripts/application.js
Normal file → Executable file
0
app/assets/javascripts/application.js
Normal file → Executable file
0
app/assets/javascripts/bootstrap.min.js
vendored
Normal file → Executable file
0
app/assets/javascripts/bootstrap.min.js
vendored
Normal file → Executable file
10
app/assets/javascripts/mailr.js
Executable file
10
app/assets/javascripts/mailr.js
Executable file
|
@ -0,0 +1,10 @@
|
||||||
|
$(function() {
|
||||||
|
console.log("ready");
|
||||||
|
$("#toggleall").click(function() {
|
||||||
|
var checked_status = this.checked;
|
||||||
|
jQuery("input[type='checkbox']").each(function() {
|
||||||
|
this.checked = checked_status;
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
0
app/assets/stylesheets/application.css
Normal file → Executable file
0
app/assets/stylesheets/application.css
Normal file → Executable file
0
app/assets/stylesheets/bootstrap-responsive.min.css
vendored
Normal file → Executable file
0
app/assets/stylesheets/bootstrap-responsive.min.css
vendored
Normal file → Executable file
4
app/assets/stylesheets/bootstrap.min.css
vendored
Normal file → Executable file
4
app/assets/stylesheets/bootstrap.min.css
vendored
Normal file → Executable file
|
@ -220,8 +220,8 @@ table .span9{float:none;width:684px;margin-left:0;}
|
||||||
table .span10{float:none;width:764px;margin-left:0;}
|
table .span10{float:none;width:764px;margin-left:0;}
|
||||||
table .span11{float:none;width:844px;margin-left:0;}
|
table .span11{float:none;width:844px;margin-left:0;}
|
||||||
table .span12{float:none;width:924px;margin-left:0;}
|
table .span12{float:none;width:924px;margin-left:0;}
|
||||||
[class^="icon-"],[class*=" icon-"]{display:inline-block;width:14px;height:14px;line-height:14px;vertical-align:text-top;background-image:url("../img/glyphicons-halflings.png");background-position:14px 14px;background-repeat:no-repeat;*margin-right:.3em;}[class^="icon-"]:last-child,[class*=" icon-"]:last-child{*margin-left:0;}
|
[class^="icon-"],[class*=" icon-"]{display:inline-block;width:14px;height:14px;line-height:14px;vertical-align:text-top;background-image:url("/assets/glyphicons-halflings.png");background-position:14px 14px;background-repeat:no-repeat;*margin-right:.3em;}[class^="icon-"]:last-child,[class*=" icon-"]:last-child{*margin-left:0;}
|
||||||
.icon-white{background-image:url("../img/glyphicons-halflings-white.png");}
|
.icon-white{background-image:url("/assets/glyphicons-halflings-white.png");}
|
||||||
.icon-glass{background-position:0 0;}
|
.icon-glass{background-position:0 0;}
|
||||||
.icon-music{background-position:-24px 0;}
|
.icon-music{background-position:-24px 0;}
|
||||||
.icon-search{background-position:-48px 0;}
|
.icon-search{background-position:-48px 0;}
|
||||||
|
|
26
app/assets/stylesheets/mailr.css.sass
Normal file → Executable file
26
app/assets/stylesheets/mailr.css.sass
Normal file → Executable file
|
@ -1,7 +1,33 @@
|
||||||
body.simple
|
body.simple
|
||||||
margin-top: 20px
|
margin-top: 20px
|
||||||
margin-bottom: 20px
|
margin-bottom: 20px
|
||||||
|
|
||||||
#footer-simple
|
#footer-simple
|
||||||
text-align: center
|
text-align: center
|
||||||
|
|
||||||
.top-pix18
|
.top-pix18
|
||||||
margin-top: 18px
|
margin-top: 18px
|
||||||
|
|
||||||
|
body.application
|
||||||
|
margin-top: 10px
|
||||||
|
margin-bottom: 10px
|
||||||
|
|
||||||
|
#sidebar
|
||||||
|
.logo
|
||||||
|
img
|
||||||
|
margin-bottom: 10px
|
||||||
|
|
||||||
|
p.version
|
||||||
|
text-align: center
|
||||||
|
|
||||||
|
tr.unseen
|
||||||
|
font-weight: bold
|
||||||
|
|
||||||
|
.bottom-pix18
|
||||||
|
margin-bottom: 18px
|
||||||
|
|
||||||
|
table.header
|
||||||
|
td.field_name
|
||||||
|
text-align: right
|
||||||
|
font-weight: bold
|
||||||
|
padding-right: 10px
|
||||||
|
|
|
@ -2,7 +2,8 @@ require 'yaml'
|
||||||
|
|
||||||
class ApplicationController < ActionController::Base
|
class ApplicationController < ActionController::Base
|
||||||
|
|
||||||
protect_from_forgery
|
#logger.custom("session",session.inspect)
|
||||||
|
#protect_from_forgery
|
||||||
|
|
||||||
before_filter :load_settings,:current_user,:set_locale
|
before_filter :load_settings,:current_user,:set_locale
|
||||||
#before_filter :plugins_configuration
|
#before_filter :plugins_configuration
|
||||||
|
@ -33,6 +34,7 @@ class ApplicationController < ActionController::Base
|
||||||
|
|
||||||
def current_user
|
def current_user
|
||||||
@current_user ||= User.find(session[:user_id]) if session[:user_id]
|
@current_user ||= User.find(session[:user_id]) if session[:user_id]
|
||||||
|
logger.custom("current_user",@current_user.inspect)
|
||||||
end
|
end
|
||||||
|
|
||||||
def check_current_user
|
def check_current_user
|
||||||
|
|
|
@ -12,7 +12,7 @@ class FoldersController < ApplicationController
|
||||||
after_filter :close_imap_session, :except => [:index,:show_hide,:system]
|
after_filter :close_imap_session, :except => [:index,:show_hide,:system]
|
||||||
|
|
||||||
before_filter :get_folders
|
before_filter :get_folders
|
||||||
before_filter :prepare_buttons_to_folders
|
#before_filter :prepare_buttons_to_folders
|
||||||
|
|
||||||
#theme :theme_resolver
|
#theme :theme_resolver
|
||||||
|
|
||||||
|
@ -153,16 +153,16 @@ class FoldersController < ApplicationController
|
||||||
|
|
||||||
protected
|
protected
|
||||||
|
|
||||||
def prepare_buttons_to_folders
|
#def prepare_buttons_to_folders
|
||||||
@buttons = []
|
#@buttons = []
|
||||||
@buttons << {:text => 'show_hide',:scope=>'folder',:image => 'flag.png'}
|
#@buttons << {:text => 'show_hide',:scope=>'folder',:image => 'flag.png'}
|
||||||
@buttons << {:text => 'refresh',:scope=>'folder',:image => 'refresh.png'}
|
#@buttons << {:text => 'refresh',:scope=>'folder',:image => 'refresh.png'}
|
||||||
end
|
#end
|
||||||
|
|
||||||
def get_folders
|
def get_folders
|
||||||
@folders = @current_user.folders
|
@folders = @current_user.folders
|
||||||
@folders_shown = @current_user.folders.shown
|
@folders_shown = @current_user.folders.shown
|
||||||
#@folders_system = @current_user.folders.sys
|
@folders_system = @current_user.folders.sys
|
||||||
@current_user.folders.inbox.first.nil? ? @folder_inbox = "" : @folder_inbox = @current_user.folders.inbox.first.id
|
@current_user.folders.inbox.first.nil? ? @folder_inbox = "" : @folder_inbox = @current_user.folders.inbox.first.id
|
||||||
@current_user.folders.drafts.first.nil? ? @folder_drafts = "" : @folder_drafts = @current_user.folders.drafts.first.id
|
@current_user.folders.drafts.first.nil? ? @folder_drafts = "" : @folder_drafts = @current_user.folders.drafts.first.id
|
||||||
@current_user.folders.sent.first.nil? ? @folder_sent = "" : @folder_sent = @current_user.folders.sent.first.id
|
@current_user.folders.sent.first.nil? ? @folder_sent = "" : @folder_sent = @current_user.folders.sent.first.id
|
||||||
|
|
|
@ -9,13 +9,14 @@ class InternalController < ApplicationController
|
||||||
ERRORS = [
|
ERRORS = [
|
||||||
:internal_server_error,
|
:internal_server_error,
|
||||||
:not_found,
|
:not_found,
|
||||||
:unprocessable_entity
|
:unprocessable_entity,
|
||||||
|
:allready_configured
|
||||||
].freeze
|
].freeze
|
||||||
|
|
||||||
ERRORS.each do |e|
|
ERRORS.each do |e|
|
||||||
define_method e do
|
define_method e do
|
||||||
@title = t(e,:scope=>:internal)
|
@title = t(e,:scope=>:internal)
|
||||||
@error = t(e,:scope=>:internal)
|
flash[:error] = t(e,:scope=>:internal)
|
||||||
render 'error'
|
render 'error'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -39,12 +40,19 @@ class InternalController < ApplicationController
|
||||||
redirect_to :controller=>'user', :action => 'login'
|
redirect_to :controller=>'user', :action => 'login'
|
||||||
end
|
end
|
||||||
|
|
||||||
def onlycanlogins
|
#def onlycanlogins
|
||||||
reset_session
|
#reset_session
|
||||||
flash[:error] = t(:only_can_logins,:scope=>:user)
|
#flash[:error] = t(:only_can_logins,:scope=>:user)
|
||||||
@current_user = nil
|
#@current_user = nil
|
||||||
redirect_to :controller=>'user', :action => 'login'
|
#redirect_to :controller=>'user', :action => 'login'
|
||||||
end
|
#end
|
||||||
|
|
||||||
|
#def onlycanlogins
|
||||||
|
#reset_session
|
||||||
|
#flash[:error] = t(:allready_configured,:scope=>:user)
|
||||||
|
#@current_user = nil
|
||||||
|
#redirect_to :controller=>'user', :action => 'login'
|
||||||
|
#end
|
||||||
|
|
||||||
def about
|
def about
|
||||||
render 'internal/about', :layout => 'application'
|
render 'internal/about', :layout => 'application'
|
||||||
|
|
|
@ -16,9 +16,9 @@ class MessagesController < ApplicationController
|
||||||
before_filter :prepare_compose_buttons, :only => [:compose]
|
before_filter :prepare_compose_buttons, :only => [:compose]
|
||||||
before_filter :get_system_folders, :only => [:index]
|
before_filter :get_system_folders, :only => [:index]
|
||||||
before_filter :create_message_with_params, :only => [:compose]
|
before_filter :create_message_with_params, :only => [:compose]
|
||||||
before_filter :prepare_multi1_buttons, :only => [:index,:show]
|
#before_filter :prepare_multi1_buttons, :only => [:index,:show]
|
||||||
before_filter :prepare_multi2_buttons, :only => [:index]
|
#before_filter :prepare_multi2_buttons, :only => [:index]
|
||||||
before_filter :prepare_multi3_buttons, :only => [:show]
|
#before_filter :prepare_multi3_buttons, :only => [:show]
|
||||||
after_filter :close_imap_session
|
after_filter :close_imap_session
|
||||||
|
|
||||||
#theme :theme_resolver
|
#theme :theme_resolver
|
||||||
|
@ -129,7 +129,9 @@ class MessagesController < ApplicationController
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
part = Mail::Part.new(mail)
|
logger.custom('mail',mail.inspect)
|
||||||
|
part = mail
|
||||||
|
#part = Mail::Part.new(mail)
|
||||||
part.idx = 0
|
part.idx = 0
|
||||||
part.parent_id = @message.uid
|
part.parent_id = @message.uid
|
||||||
if part.isText?
|
if part.isText?
|
||||||
|
@ -175,7 +177,8 @@ class MessagesController < ApplicationController
|
||||||
if mail.multipart? == true
|
if mail.multipart? == true
|
||||||
attachments = mail.attachments
|
attachments = mail.attachments
|
||||||
else
|
else
|
||||||
attachments << Mail::Part.new(mail)
|
#attachments << Mail::Part.new(mail)
|
||||||
|
attachments << mail
|
||||||
end
|
end
|
||||||
a = attachments[params[:idx].to_i]
|
a = attachments[params[:idx].to_i]
|
||||||
headers['Content-type'] = a.main_type + "/" + a.sub_type
|
headers['Content-type'] = a.main_type + "/" + a.sub_type
|
||||||
|
@ -188,23 +191,23 @@ class MessagesController < ApplicationController
|
||||||
|
|
||||||
protected
|
protected
|
||||||
|
|
||||||
def prepare_multi2_buttons
|
#def prepare_multi2_buttons
|
||||||
@multi2_buttons = []
|
#@multi2_buttons = []
|
||||||
@multi2_buttons << {:text => 'trash',:scope=>:message,:image => 'trash.png'}
|
#@multi2_buttons << {:text => 'trash',:scope=>:message,:image => 'trash.png'}
|
||||||
@multi2_buttons << {:text => 'set_unread',:scope=>:message,:image => 'unseen.png'}
|
#@multi2_buttons << {:text => 'set_unread',:scope=>:message,:image => 'unseen.png'}
|
||||||
@multi2_buttons << {:text => 'set_read',:scope=>:message,:image => 'seen.png'}
|
#@multi2_buttons << {:text => 'set_read',:scope=>:message,:image => 'seen.png'}
|
||||||
end
|
#end
|
||||||
|
|
||||||
def prepare_multi1_buttons
|
#def prepare_multi1_buttons
|
||||||
@multi1_buttons = []
|
#@multi1_buttons = []
|
||||||
@multi1_buttons << {:text => 'copy',:scope=>:message,:image => 'copy.png'}
|
#@multi1_buttons << {:text => 'copy',:scope=>:message,:image => 'copy.png'}
|
||||||
@multi1_buttons << {:text => 'move',:scope=>:message,:image => 'move.png'}
|
#@multi1_buttons << {:text => 'move',:scope=>:message,:image => 'move.png'}
|
||||||
end
|
#end
|
||||||
|
|
||||||
def prepare_multi3_buttons
|
#def prepare_multi3_buttons
|
||||||
@multi3_buttons = []
|
#@multi3_buttons = []
|
||||||
@multi3_buttons << {:text => 'show_header',:scope=>:show,:image => 'zoom.png'}
|
#@multi3_buttons << {:text => 'show_header',:scope=>:show,:image => 'zoom.png'}
|
||||||
@multi3_buttons << {:text => 'trash',:scope=>:show,:image => 'trash.png'}
|
#@multi3_buttons << {:text => 'trash',:scope=>:show,:image => 'trash.png'}
|
||||||
@multi3_buttons << {:text => 'reply',:scope=>:show,:image => 'reply.png'}
|
#@multi3_buttons << {:text => 'reply',:scope=>:show,:image => 'reply.png'}
|
||||||
end
|
#end
|
||||||
end
|
end
|
||||||
|
|
|
@ -4,6 +4,12 @@ class UserController < ApplicationController
|
||||||
layout "simple"
|
layout "simple"
|
||||||
|
|
||||||
def login
|
def login
|
||||||
|
# database empty redirect to setup screen
|
||||||
|
users = User.all
|
||||||
|
if users.count.zero?
|
||||||
|
redirect_to :controller => 'user', :action => 'setup'
|
||||||
|
return false
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def logout
|
def logout
|
||||||
|
@ -14,29 +20,31 @@ class UserController < ApplicationController
|
||||||
|
|
||||||
def authenticate
|
def authenticate
|
||||||
|
|
||||||
users = User.all
|
# check if user can use application
|
||||||
if users.count.zero?
|
|
||||||
redirect_to :controller => 'user', :action => 'setup'
|
|
||||||
return false
|
|
||||||
end
|
|
||||||
|
|
||||||
if not $defaults["only_can_logins"].nil?
|
if not $defaults["only_can_logins"].nil?
|
||||||
if not $defaults["only_can_logins"].include?(params[:user][:login])
|
if not $defaults["only_can_logins"].include?(params[:user][:login])
|
||||||
redirect_to :controller => 'internal', :action => 'onlycanlogins'
|
flash[:error] = t(:only_can_logins,:scope=>:user)
|
||||||
|
redirect_to :action => 'login'
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
user = User.find_by_login(params[:user][:login])
|
user = User.find_by_login(params[:user][:login])
|
||||||
if user.nil?
|
if user.nil?
|
||||||
redirect_to :action => 'unknown' ,:login=> params[:user][:login]
|
|
||||||
|
flash[:error] = t(:login_failure,:scope=>:user)
|
||||||
|
redirect_to :action => 'login'
|
||||||
|
return false
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
session[:user_id] = user.id
|
session[:user_id] = user.id
|
||||||
user.set_cached_password(session,params[:user][:password])
|
user.set_cached_password(session,params[:user][:password])
|
||||||
|
|
||||||
if session["return_to"]
|
if session["return_to"]
|
||||||
redirect_to(session["return_to"])
|
redirect = session["return_to"]
|
||||||
session["return_to"] = nil
|
session["return_to"] = nil
|
||||||
|
redirect_to(redirect)
|
||||||
else
|
else
|
||||||
redirect_to :controller=> 'messages', :action=> 'index'
|
redirect_to :controller=> 'messages', :action=> 'index'
|
||||||
end
|
end
|
||||||
|
@ -44,17 +52,19 @@ class UserController < ApplicationController
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def loginfailure
|
#def loginfailure
|
||||||
end
|
#end
|
||||||
|
|
||||||
def setup
|
def setup
|
||||||
|
users = User.all
|
||||||
|
if !users.count.zero?
|
||||||
|
redirect_to :controller => 'internal', :action => 'allready_configured'
|
||||||
|
return false
|
||||||
|
end
|
||||||
@user = User.new
|
@user = User.new
|
||||||
@server = Server.new
|
@server = Server.new
|
||||||
end
|
end
|
||||||
|
|
||||||
def unknown
|
|
||||||
end
|
|
||||||
|
|
||||||
def create
|
def create
|
||||||
|
|
||||||
@user = User.new
|
@user = User.new
|
||||||
|
|
|
@ -2,333 +2,333 @@ require 'iconv'
|
||||||
|
|
||||||
module ApplicationHelper
|
module ApplicationHelper
|
||||||
|
|
||||||
def form_field(object,field,flabel,example,val)
|
#def form_field(object,field,flabel,example,val)
|
||||||
model_name = eval(object.class.model_name)
|
#model_name = eval(object.class.model_name)
|
||||||
html = ""
|
#html = ""
|
||||||
html << "<div class=\"param_group\">"
|
#html << "<div class=\"param_group\">"
|
||||||
if not object.errors[field.to_sym].empty?
|
#if not object.errors[field.to_sym].empty?
|
||||||
html << "<div class=\"fieldWithErrors\">"
|
#html << "<div class=\"fieldWithErrors\">"
|
||||||
|
|
||||||
end
|
#end
|
||||||
|
|
||||||
html << "<label class=\"label\">"
|
#html << "<label class=\"label\">"
|
||||||
flabel.nil? ? html << model_name.human_attribute_name(field) : html << t(flabel.to_sym)
|
#flabel.nil? ? html << model_name.human_attribute_name(field) : html << t(flabel.to_sym)
|
||||||
html << "</label>"
|
#html << "</label>"
|
||||||
|
|
||||||
if not object.errors[field.to_sym].empty?
|
#if not object.errors[field.to_sym].empty?
|
||||||
html << "<span class=\"error\"> "
|
#html << "<span class=\"error\"> "
|
||||||
html << object.errors[field.to_sym].to_s
|
#html << object.errors[field.to_sym].to_s
|
||||||
html << "</span>"
|
#html << "</span>"
|
||||||
html << "</div>"
|
#html << "</div>"
|
||||||
end
|
#end
|
||||||
html << "<input id=\""
|
#html << "<input id=\""
|
||||||
html << object.class.name.downcase+"_"+field
|
#html << object.class.name.downcase+"_"+field
|
||||||
html << "\""
|
#html << "\""
|
||||||
html << " name=\"#{object.class.name.downcase}[#{field}]\""
|
#html << " name=\"#{object.class.name.downcase}[#{field}]\""
|
||||||
html << " type=\"text\" class=\"text_field\" value=\""
|
#html << " type=\"text\" class=\"text_field\" value=\""
|
||||||
value = val || object.instance_eval(field) || ""
|
#value = val || object.instance_eval(field) || ""
|
||||||
html << value
|
#html << value
|
||||||
html << "\"/>"
|
#html << "\"/>"
|
||||||
html << "<span class=\"description\">"
|
#html << "<span class=\"description\">"
|
||||||
html << t(:example,:scope=>:common)
|
#html << t(:example,:scope=>:common)
|
||||||
html << ": "
|
#html << ": "
|
||||||
html << example
|
#html << example
|
||||||
html << "</span>"
|
#html << "</span>"
|
||||||
html << "</div>"
|
#html << "</div>"
|
||||||
|
|
||||||
end
|
#end
|
||||||
|
|
||||||
def show_param_view(object,field,value)
|
#def show_param_view(object,field,value)
|
||||||
model_name = eval(object.class.model_name)
|
#model_name = eval(object.class.model_name)
|
||||||
html = ""
|
#html = ""
|
||||||
html << "<div class=\"group clearfix\">"
|
#html << "<div class=\"group clearfix\">"
|
||||||
html << "<label class=\"label\">#{model_name.human_attribute_name(field)}: </label>"
|
#html << "<label class=\"label\">#{model_name.human_attribute_name(field)}: </label>"
|
||||||
html << value
|
#html << value
|
||||||
html << "</div>"
|
#html << "</div>"
|
||||||
html
|
#html
|
||||||
end
|
#end
|
||||||
|
|
||||||
def area_field(object,field,flabel,example,val,cols,rows)
|
#def area_field(object,field,flabel,example,val,cols,rows)
|
||||||
model_name = eval(object.class.model_name)
|
#model_name = eval(object.class.model_name)
|
||||||
html = ""
|
|
||||||
html << "<div class=\"group\">"
|
|
||||||
|
|
||||||
if not object.errors[field.to_sym].empty?
|
|
||||||
html << "<div class=\"fieldWithErrors\">"
|
|
||||||
end
|
|
||||||
|
|
||||||
html << "<label class=\"label\">"
|
|
||||||
flabel.nil? ? html << model_name.human_attribute_name(field) : html << t(flabel.to_sym)
|
|
||||||
html << "</label>"
|
|
||||||
|
|
||||||
if not object.errors[field.to_sym].empty?
|
|
||||||
html << "<span class=\"error\">"
|
|
||||||
html << object.errors[field.to_sym].to_s
|
|
||||||
html << "</span>"
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
name = object.class.name.downcase + '[' + field + ']'
|
|
||||||
id = object.class.name.downcase+"_"+field
|
|
||||||
value = val || object.instance_eval(field) || ""
|
|
||||||
html << "<textarea id=\"#{id}\" name=\"#{name}\" class=\"text_area\" cols=\"#{cols}\" rows=\"#{rows}\">#{value}</textarea>"
|
|
||||||
|
|
||||||
desc = t(:example,:scope=>:common) + ": " + example
|
|
||||||
html << "<span class=\"description\">#{desc}</span>"
|
|
||||||
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def form_button(text,image)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"group\">"
|
|
||||||
html << "<button class=\"button\" type=\"submit\">"
|
|
||||||
html << "<img src=\""
|
|
||||||
html << current_theme_image_path(image)
|
|
||||||
html << "\" alt=\""
|
|
||||||
html << t(text.to_sym)
|
|
||||||
html << "\" />"
|
|
||||||
html << t(text.to_sym)
|
|
||||||
html << "</button></div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def single_action(text,scope,image)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"actiongroup clearfix\">"
|
|
||||||
html << "<button class=\"button\" name=\"#{text}\" type=\"submit\">"
|
|
||||||
html << "<img src=\""
|
|
||||||
html << current_theme_image_path(image)
|
|
||||||
html << "\" alt=\""
|
|
||||||
html << t(text.to_sym, :scope => scope.to_sym)
|
|
||||||
html << "\" />"
|
|
||||||
html << t(text.to_sym, :scope => scope.to_sym)
|
|
||||||
html << "</button></div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def single_action_onclick(text,scope,image,onclick)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"actiongroup clearfix\">"
|
|
||||||
html << "<button class=\"button\" type=\"submit\" onclick=\"window.location='"
|
|
||||||
html << onclick
|
|
||||||
html << "'\">"
|
|
||||||
html << "<img src=\""
|
|
||||||
html << current_theme_image_path(image)
|
|
||||||
html << "\" alt=\""
|
|
||||||
html << t(text.to_sym, :scope => scope.to_sym)
|
|
||||||
html << "\" />"
|
|
||||||
html << t(text.to_sym, :scope => scope.to_sym)
|
|
||||||
html << "</button>"
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def group_action(buttons)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"actiongroup clearfix\">"
|
|
||||||
buttons.each do |b|
|
|
||||||
html << "<button class=\"button\" type=\"submit\" name=\"#{b[:text]}\">"
|
|
||||||
html << "<img src=\""
|
|
||||||
html << current_theme_image_path(b[:image])
|
|
||||||
html << "\" alt=\""
|
|
||||||
html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
|
||||||
html << "\" />"
|
|
||||||
html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
|
||||||
html << "</button> "
|
|
||||||
end
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def group_action_text(buttons,text)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"group\">"
|
|
||||||
buttons.each do |b|
|
|
||||||
html << "<button class=\"button\" type=\"submit\" name=\"#{b[:text]}\">"
|
|
||||||
html << "<img src=\""
|
|
||||||
html << current_theme_image_path(b[:image])
|
|
||||||
html << "\" alt=\""
|
|
||||||
html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
|
||||||
html << "\" />"
|
|
||||||
html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
|
||||||
html << "</button> "
|
|
||||||
end
|
|
||||||
html << text
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def form_buttons(buttons)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"group\">"
|
|
||||||
|
|
||||||
buttons.each do |b|
|
|
||||||
html << "<button class=\"button\" type=\"submit\" name=\"#{b[:text]}\">"
|
|
||||||
html << "<img src=\""
|
|
||||||
html << current_theme_image_path(b[:image])
|
|
||||||
html << "\" alt=\""
|
|
||||||
html << t(b[:text].to_sym)
|
|
||||||
html << "\" />"
|
|
||||||
html << t(b[:text].to_sym)
|
|
||||||
html << "</button> "
|
|
||||||
end
|
|
||||||
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def form_button_value(text,image,onclick)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"group\">"
|
|
||||||
html << "<button class=\"button\" type=\"submit\" onclick=\"window.location='"
|
|
||||||
html << onclick
|
|
||||||
html << "'\">"
|
|
||||||
html << "<img src=\""
|
|
||||||
html << current_theme_image_path(image)
|
|
||||||
html << "\" alt=\""
|
|
||||||
html << text
|
|
||||||
html << "\" />"
|
|
||||||
html << t(text.to_sym)
|
|
||||||
html << "</button></div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def simple_input_field(name,id,label,value)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"param_group\">"
|
|
||||||
html << "<label class=\"label\">#{label}</label>"
|
|
||||||
html << "<input name=\"#{name}[#{id}]\" id=\"#{name}_#{id} class=\"text_field\" type=\"text\" value=\"#{value}\">"
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def select_field(name,object,label,blank)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"group\">"
|
|
||||||
html << "<label class=\"label\">#{label}</label>"
|
|
||||||
html << select(name, name, object.all.collect {|p| [ p.name, p.id ] }, { :include_blank => (blank == true ? true : false)})
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def select_field_table(object,field,table_choices,choice,blank)
|
|
||||||
model_name = eval(object.class.model_name)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"param_group\">"
|
|
||||||
html << "<label class=\"label\">#{model_name.human_attribute_name(field)}</label>"
|
|
||||||
html << select(object.class.to_s.downcase, field, options_for_select(table_choices,choice), {:include_blank => blank})
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def select_field_table_t(object,field,table_choices,choice,blank)
|
|
||||||
model_name = eval(object.class.model_name)
|
|
||||||
html = ""
|
|
||||||
html << "<div class=\"param_group\">"
|
|
||||||
html << "<label class=\"label\">#{model_name.human_attribute_name(field)}</label>"
|
|
||||||
t = []
|
|
||||||
table_choices.each do |c|
|
|
||||||
t << [t(c.to_sym,:scope=>:prefs),c.to_s]
|
|
||||||
end
|
|
||||||
html << select(object.class.to_s.downcase, field, options_for_select(t,choice), {:include_blank => blank})
|
|
||||||
html << "</div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
#def form_simle_field(name,label,value)
|
|
||||||
#html = ""
|
#html = ""
|
||||||
#html << "<div class=\"group\">"
|
#html << "<div class=\"group\">"
|
||||||
# html << "<label class=\"label\">#{label}</label>"
|
|
||||||
# html << "<input class=\"text_field\" type=\"text\" value=\"#{value}\">"
|
#if not object.errors[field.to_sym].empty?
|
||||||
|
#html << "<div class=\"fieldWithErrors\">"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#html << "<label class=\"label\">"
|
||||||
|
#flabel.nil? ? html << model_name.human_attribute_name(field) : html << t(flabel.to_sym)
|
||||||
|
#html << "</label>"
|
||||||
|
|
||||||
|
#if not object.errors[field.to_sym].empty?
|
||||||
|
#html << "<span class=\"error\">"
|
||||||
|
#html << object.errors[field.to_sym].to_s
|
||||||
|
#html << "</span>"
|
||||||
#html << "</div>"
|
#html << "</div>"
|
||||||
#end
|
#end
|
||||||
|
|
||||||
#def nav_to_folders
|
#name = object.class.name.downcase + '[' + field + ']'
|
||||||
# link_to( t(:folders,:scope=>:folder), :controller=>:folders, :action=>:index )
|
#id = object.class.name.downcase+"_"+field
|
||||||
#end
|
#value = val || object.instance_eval(field) || ""
|
||||||
#
|
#html << "<textarea id=\"#{id}\" name=\"#{name}\" class=\"text_area\" cols=\"#{cols}\" rows=\"#{rows}\">#{value}</textarea>"
|
||||||
#def nav_to_messages
|
|
||||||
# link_to( t(:messages,:scope=>:message), :controller=>:messages, :action=>:index )
|
#desc = t(:example,:scope=>:common) + ": " + example
|
||||||
#end
|
#html << "<span class=\"description\">#{desc}</span>"
|
||||||
#
|
|
||||||
#def nav_to_compose
|
#html << "</div>"
|
||||||
# link_to( t(:compose,:scope=>:compose), :controller=>:messages, :action=>:compose )
|
|
||||||
#end
|
|
||||||
#
|
|
||||||
#def nav_to_contacts
|
|
||||||
# link_to( t(:contacts,:scope=>:contact), contacts_path )
|
|
||||||
#end
|
|
||||||
#
|
|
||||||
#def nav_to_prefs
|
|
||||||
# link_to( t(:prefs,:scope=>:prefs), prefs_look_path )
|
|
||||||
#end
|
#end
|
||||||
|
|
||||||
def single_navigation(label,scope)
|
#def form_button(text,image)
|
||||||
s = ""
|
#html = ""
|
||||||
s += "<ul>"
|
#html << "<div class=\"group\">"
|
||||||
s += "<li class=\"first active\">#{link_to(t(label,:scope=>scope),'#')}</li>"
|
#html << "<button class=\"button\" type=\"submit\">"
|
||||||
s += "<li class=\"last\"> </li>"
|
#html << "<img src=\""
|
||||||
s += "</ul>"
|
#html << current_theme_image_path(image)
|
||||||
end
|
#html << "\" alt=\""
|
||||||
|
#html << t(text.to_sym)
|
||||||
|
#html << "\" />"
|
||||||
|
#html << t(text.to_sym)
|
||||||
|
#html << "</button></div>"
|
||||||
|
#end
|
||||||
|
|
||||||
def main_navigation(active)
|
#def single_action(text,scope,image)
|
||||||
instance_variable_set("@#{active}", "active")
|
#html = ""
|
||||||
s = ""
|
#html << "<div class=\"actiongroup clearfix\">"
|
||||||
s += "<ul>"
|
#html << "<button class=\"button\" name=\"#{text}\" type=\"submit\">"
|
||||||
s += "<li class=\"first #{@messages_tab}\">#{link_to( t(:messages,:scope=>:message), messages_path )}</li>"
|
#html << "<img src=\""
|
||||||
s += "<li class=\"#{@compose_tab}\">#{link_to( t(:compose,:scope=>:compose), compose_path )}</li>"
|
#html << current_theme_image_path(image)
|
||||||
s += "<li class=\"#{@folders_tab}\">#{link_to( t(:folders,:scope=>:folder), folders_path )}</li>"
|
#html << "\" alt=\""
|
||||||
s += "<li class=\"#{@contacts_tab}\">#{link_to( t(:contacts,:scope=>:contact), contacts_path )}</li>"
|
#html << t(text.to_sym, :scope => scope.to_sym)
|
||||||
s += "<li class=\"#{@prefs_tab}\">#{link_to( t(:prefs,:scope=>:prefs), prefs_look_path )}</li>"
|
#html << "\" />"
|
||||||
s += "<li class=\"last #{@links_tab}\">#{link_to( t(:links,:scope=>:link), links_path )}</li>"
|
#html << t(text.to_sym, :scope => scope.to_sym)
|
||||||
s += "</ul>"
|
#html << "</button></div>"
|
||||||
end
|
#end
|
||||||
|
|
||||||
def prefs_navigation(active)
|
#def single_action_onclick(text,scope,image,onclick)
|
||||||
instance_variable_set("@#{active}", "active")
|
#html = ""
|
||||||
s = ""
|
#html << "<div class=\"actiongroup clearfix\">"
|
||||||
s += "<ul>"
|
#html << "<button class=\"button\" type=\"submit\" onclick=\"window.location='"
|
||||||
s += "<li class=\"first #{@look_tab}\">#{link_to( t(:look,:scope=>:prefs), prefs_look_path )}</li>"
|
#html << onclick
|
||||||
s += "<li class=\"#{@identity_tab}\">#{link_to( t(:identity,:scope=>:prefs), prefs_identity_path )}</li>"
|
#html << "'\">"
|
||||||
s += "<li class=\"last #{@servers_tab}\">#{link_to( t(:servers,:scope=>:prefs), prefs_servers_path )}</li>"
|
#html << "<img src=\""
|
||||||
s += "</ul>"
|
#html << current_theme_image_path(image)
|
||||||
end
|
#html << "\" alt=\""
|
||||||
|
#html << t(text.to_sym, :scope => scope.to_sym)
|
||||||
|
#html << "\" />"
|
||||||
|
#html << t(text.to_sym, :scope => scope.to_sym)
|
||||||
|
#html << "</button>"
|
||||||
|
#html << "</div>"
|
||||||
|
#end
|
||||||
|
|
||||||
def multi_select(id, name, objects, selected_objects, label, value,joiner,content = {})
|
#def group_action(buttons)
|
||||||
options = ""
|
#html = ""
|
||||||
objects.each do |o|
|
#html << "<div class=\"actiongroup clearfix\">"
|
||||||
selected = selected_objects.include?(o) ? " selected=\"selected\"" : ""
|
#buttons.each do |b|
|
||||||
option_value = escape_once(o.send(value))
|
#html << "<button class=\"button\" type=\"submit\" name=\"#{b[:text]}\">"
|
||||||
text = [option_value]
|
#html << "<img src=\""
|
||||||
unless content[:text].nil?
|
#html << current_theme_image_path(b[:image])
|
||||||
text = []
|
#html << "\" alt=\""
|
||||||
content[:text].each do |t|
|
#html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
||||||
text << o.send(t)
|
#html << "\" />"
|
||||||
end
|
#html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
||||||
text = text.join(joiner)
|
#html << "</button> "
|
||||||
end
|
#end
|
||||||
text.gsub!(/^\./,'')
|
#html << "</div>"
|
||||||
bracket = []
|
#end
|
||||||
unless content[:bracket].nil?
|
|
||||||
content[:bracket].each do |b|
|
|
||||||
bracket << o.send(b)
|
|
||||||
end
|
|
||||||
bracket = bracket.join(joiner)
|
|
||||||
end
|
|
||||||
option_content = bracket.empty? ? "#{text}" : "#{text} (#{bracket})"
|
|
||||||
options << "<option value=\"#{option_value}\"#{selected}> #{option_content} </option>\n"
|
|
||||||
end
|
|
||||||
"<div class=\"param_group\"><label class=\"label\">#{label}</label><select multiple=\"multiple\" size=10 id=\"#{id}\" name=\"#{name}\">\n#{options}</select></div>"
|
|
||||||
end
|
|
||||||
|
|
||||||
def force_charset(text)
|
#def group_action_text(buttons,text)
|
||||||
begin
|
#html = ""
|
||||||
Iconv.iconv("UTF-8",$defaults["msg_unknown_charset"],text)
|
#html << "<div class=\"group\">"
|
||||||
rescue
|
#buttons.each do |b|
|
||||||
text
|
#html << "<button class=\"button\" type=\"submit\" name=\"#{b[:text]}\">"
|
||||||
end
|
#html << "<img src=\""
|
||||||
end
|
#html << current_theme_image_path(b[:image])
|
||||||
|
#html << "\" alt=\""
|
||||||
|
#html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
||||||
|
#html << "\" />"
|
||||||
|
#html << t(b[:text].to_sym,:scope=>b[:scope].to_sym)
|
||||||
|
#html << "</button> "
|
||||||
|
#end
|
||||||
|
#html << text
|
||||||
|
#html << "</div>"
|
||||||
|
#end
|
||||||
|
|
||||||
def content_for_sidebar
|
#def form_buttons(buttons)
|
||||||
s = render :partial => 'sidebar/logo'
|
#html = ""
|
||||||
s += render :partial => 'folders/list'
|
#html << "<div class=\"group\">"
|
||||||
s += render :partial => 'sidebar/calendar_view'
|
|
||||||
s += render :partial => 'internal/version'
|
|
||||||
s
|
|
||||||
end
|
|
||||||
|
|
||||||
def boolean_answer(answer)
|
#buttons.each do |b|
|
||||||
answer == true ? t(:true_answer,:scope=>:common) : t(:false_answer,:scope=>:common)
|
#html << "<button class=\"button\" type=\"submit\" name=\"#{b[:text]}\">"
|
||||||
end
|
#html << "<img src=\""
|
||||||
|
#html << current_theme_image_path(b[:image])
|
||||||
|
#html << "\" alt=\""
|
||||||
|
#html << t(b[:text].to_sym)
|
||||||
|
#html << "\" />"
|
||||||
|
#html << t(b[:text].to_sym)
|
||||||
|
#html << "</button> "
|
||||||
|
#end
|
||||||
|
|
||||||
|
#html << "</div>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def form_button_value(text,image,onclick)
|
||||||
|
#html = ""
|
||||||
|
#html << "<div class=\"group\">"
|
||||||
|
#html << "<button class=\"button\" type=\"submit\" onclick=\"window.location='"
|
||||||
|
#html << onclick
|
||||||
|
#html << "'\">"
|
||||||
|
#html << "<img src=\""
|
||||||
|
#html << current_theme_image_path(image)
|
||||||
|
#html << "\" alt=\""
|
||||||
|
#html << text
|
||||||
|
#html << "\" />"
|
||||||
|
#html << t(text.to_sym)
|
||||||
|
#html << "</button></div>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def simple_input_field(name,id,label,value)
|
||||||
|
#html = ""
|
||||||
|
#html << "<div class=\"param_group\">"
|
||||||
|
#html << "<label class=\"label\">#{label}</label>"
|
||||||
|
#html << "<input name=\"#{name}[#{id}]\" id=\"#{name}_#{id} class=\"text_field\" type=\"text\" value=\"#{value}\">"
|
||||||
|
#html << "</div>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def select_field(name,object,label,blank)
|
||||||
|
#html = ""
|
||||||
|
#html << "<div class=\"group\">"
|
||||||
|
#html << "<label class=\"label\">#{label}</label>"
|
||||||
|
#html << select(name, name, object.all.collect {|p| [ p.name, p.id ] }, { :include_blank => (blank == true ? true : false)})
|
||||||
|
#html << "</div>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def select_field_table(object,field,table_choices,choice,blank)
|
||||||
|
#model_name = eval(object.class.model_name)
|
||||||
|
#html = ""
|
||||||
|
#html << "<div class=\"param_group\">"
|
||||||
|
#html << "<label class=\"label\">#{model_name.human_attribute_name(field)}</label>"
|
||||||
|
#html << select(object.class.to_s.downcase, field, options_for_select(table_choices,choice), {:include_blank => blank})
|
||||||
|
#html << "</div>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def select_field_table_t(object,field,table_choices,choice,blank)
|
||||||
|
#model_name = eval(object.class.model_name)
|
||||||
|
#html = ""
|
||||||
|
#html << "<div class=\"param_group\">"
|
||||||
|
#html << "<label class=\"label\">#{model_name.human_attribute_name(field)}</label>"
|
||||||
|
#t = []
|
||||||
|
#table_choices.each do |c|
|
||||||
|
#t << [t(c.to_sym,:scope=>:prefs),c.to_s]
|
||||||
|
#end
|
||||||
|
#html << select(object.class.to_s.downcase, field, options_for_select(t,choice), {:include_blank => blank})
|
||||||
|
#html << "</div>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
##def form_simle_field(name,label,value)
|
||||||
|
## html = ""
|
||||||
|
## html << "<div class=\"group\">"
|
||||||
|
## html << "<label class=\"label\">#{label}</label>"
|
||||||
|
## html << "<input class=\"text_field\" type=\"text\" value=\"#{value}\">"
|
||||||
|
## html << "</div>"
|
||||||
|
##end
|
||||||
|
|
||||||
|
##def nav_to_folders
|
||||||
|
## link_to( t(:folders,:scope=>:folder), :controller=>:folders, :action=>:index )
|
||||||
|
##end
|
||||||
|
##
|
||||||
|
##def nav_to_messages
|
||||||
|
## link_to( t(:messages,:scope=>:message), :controller=>:messages, :action=>:index )
|
||||||
|
##end
|
||||||
|
##
|
||||||
|
##def nav_to_compose
|
||||||
|
## link_to( t(:compose,:scope=>:compose), :controller=>:messages, :action=>:compose )
|
||||||
|
##end
|
||||||
|
##
|
||||||
|
##def nav_to_contacts
|
||||||
|
## link_to( t(:contacts,:scope=>:contact), contacts_path )
|
||||||
|
##end
|
||||||
|
##
|
||||||
|
##def nav_to_prefs
|
||||||
|
## link_to( t(:prefs,:scope=>:prefs), prefs_look_path )
|
||||||
|
##end
|
||||||
|
|
||||||
|
#def single_navigation(label,scope)
|
||||||
|
#s = ""
|
||||||
|
#s += "<ul>"
|
||||||
|
#s += "<li class=\"first active\">#{link_to(t(label,:scope=>scope),'#')}</li>"
|
||||||
|
#s += "<li class=\"last\"> </li>"
|
||||||
|
#s += "</ul>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def main_navigation(active)
|
||||||
|
#instance_variable_set("@#{active}", "active")
|
||||||
|
#s = ""
|
||||||
|
#s += "<ul>"
|
||||||
|
#s += "<li class=\"first #{@messages_tab}\">#{link_to( t(:messages,:scope=>:message), messages_path )}</li>"
|
||||||
|
#s += "<li class=\"#{@compose_tab}\">#{link_to( t(:compose,:scope=>:compose), compose_path )}</li>"
|
||||||
|
#s += "<li class=\"#{@folders_tab}\">#{link_to( t(:folders,:scope=>:folder), folders_path )}</li>"
|
||||||
|
#s += "<li class=\"#{@contacts_tab}\">#{link_to( t(:contacts,:scope=>:contact), contacts_path )}</li>"
|
||||||
|
#s += "<li class=\"#{@prefs_tab}\">#{link_to( t(:prefs,:scope=>:prefs), prefs_look_path )}</li>"
|
||||||
|
#s += "<li class=\"last #{@links_tab}\">#{link_to( t(:links,:scope=>:link), links_path )}</li>"
|
||||||
|
#s += "</ul>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def prefs_navigation(active)
|
||||||
|
#instance_variable_set("@#{active}", "active")
|
||||||
|
#s = ""
|
||||||
|
#s += "<ul>"
|
||||||
|
#s += "<li class=\"first #{@look_tab}\">#{link_to( t(:look,:scope=>:prefs), prefs_look_path )}</li>"
|
||||||
|
#s += "<li class=\"#{@identity_tab}\">#{link_to( t(:identity,:scope=>:prefs), prefs_identity_path )}</li>"
|
||||||
|
#s += "<li class=\"last #{@servers_tab}\">#{link_to( t(:servers,:scope=>:prefs), prefs_servers_path )}</li>"
|
||||||
|
#s += "</ul>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def multi_select(id, name, objects, selected_objects, label, value,joiner,content = {})
|
||||||
|
#options = ""
|
||||||
|
#objects.each do |o|
|
||||||
|
#selected = selected_objects.include?(o) ? " selected=\"selected\"" : ""
|
||||||
|
#option_value = escape_once(o.send(value))
|
||||||
|
#text = [option_value]
|
||||||
|
#unless content[:text].nil?
|
||||||
|
#text = []
|
||||||
|
#content[:text].each do |t|
|
||||||
|
#text << o.send(t)
|
||||||
|
#end
|
||||||
|
#text = text.join(joiner)
|
||||||
|
#end
|
||||||
|
#text.gsub!(/^\./,'')
|
||||||
|
#bracket = []
|
||||||
|
#unless content[:bracket].nil?
|
||||||
|
#content[:bracket].each do |b|
|
||||||
|
#bracket << o.send(b)
|
||||||
|
#end
|
||||||
|
#bracket = bracket.join(joiner)
|
||||||
|
#end
|
||||||
|
#option_content = bracket.empty? ? "#{text}" : "#{text} (#{bracket})"
|
||||||
|
#options << "<option value=\"#{option_value}\"#{selected}> #{option_content} </option>\n"
|
||||||
|
#end
|
||||||
|
#"<div class=\"param_group\"><label class=\"label\">#{label}</label><select multiple=\"multiple\" size=10 id=\"#{id}\" name=\"#{name}\">\n#{options}</select></div>"
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def force_charset(text)
|
||||||
|
#begin
|
||||||
|
#Iconv.iconv("UTF-8",$defaults["msg_unknown_charset"],text)
|
||||||
|
#rescue
|
||||||
|
#text
|
||||||
|
#end
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def content_for_sidebar
|
||||||
|
#s = render :partial => 'sidebar/logo'
|
||||||
|
#s += render :partial => 'folders/list'
|
||||||
|
#s += render :partial => 'sidebar/calendar_view'
|
||||||
|
#s += render :partial => 'internal/version'
|
||||||
|
#s
|
||||||
|
#end
|
||||||
|
|
||||||
|
#def boolean_answer(answer)
|
||||||
|
#answer == true ? t(:true_answer,:scope=>:common) : t(:false_answer,:scope=>:common)
|
||||||
|
#end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
17
app/helpers/contacts_helper.rb
Executable file
17
app/helpers/contacts_helper.rb
Executable file
|
@ -0,0 +1,17 @@
|
||||||
|
module ContactsHelper
|
||||||
|
|
||||||
|
def contacts_table_header
|
||||||
|
html = ""
|
||||||
|
$defaults["contacts_table_fields"].each do |f|
|
||||||
|
html << "<th>"
|
||||||
|
if params[:sort_field] == f
|
||||||
|
params[:sort_dir].nil? ? dir = 'desc' : dir = nil
|
||||||
|
end
|
||||||
|
|
||||||
|
html << link_to(Contact.human_attribute_name(f), {:controller => 'contacts',:action => 'index',:sort_field => f,:sort_dir => dir}, {:class=>"header"})
|
||||||
|
html << "</th>"
|
||||||
|
end
|
||||||
|
html
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
66
app/helpers/folder_helper.rb
Executable file
66
app/helpers/folder_helper.rb
Executable file
|
@ -0,0 +1,66 @@
|
||||||
|
module FolderHelper
|
||||||
|
|
||||||
|
def folder_link(folder)
|
||||||
|
|
||||||
|
folder.parent.empty? ? name = folder.name : name = folder.parent.gsub(/\./,'#') + "#" + folder.name
|
||||||
|
|
||||||
|
if folder.isInbox?
|
||||||
|
name_shown = t(:inbox_name,:scope => :folder)
|
||||||
|
elsif folder.isSent?
|
||||||
|
name_shown = t(:sent_name,:scope => :folder)
|
||||||
|
elsif folder.isDrafts?
|
||||||
|
name_shown = t(:drafts_name,:scope => :folder)
|
||||||
|
elsif folder.isTrash?
|
||||||
|
name_shown = t(:trash_name,:scope => :folder)
|
||||||
|
else
|
||||||
|
name_shown = folder.name.capitalize
|
||||||
|
end
|
||||||
|
|
||||||
|
if folder.isTrash?
|
||||||
|
if not folder.total.zero?
|
||||||
|
name_shown += " <button class=\"btn btn-mini btn-danger\" onclick=\"window.location='#{folders_emptybin_path}'\" href=\"#\">#{t(:emptybin,:scope=>:folder)}</button>"
|
||||||
|
#name_shown += raw link_to(t(:emptybin,:scope=>:folder),folders_emptybin_path)
|
||||||
|
#name_shown += ')'
|
||||||
|
end
|
||||||
|
else
|
||||||
|
if !folder.unseen.zero?
|
||||||
|
name_shown += ' (' + folder.unseen.to_s + ')'
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
link_to name_shown.html_safe, folders_select_path(:id => name)
|
||||||
|
end
|
||||||
|
|
||||||
|
def pretty_folder_name(folder)
|
||||||
|
if folder.nil?
|
||||||
|
t(:no_selected,:scope=>:folder)
|
||||||
|
else
|
||||||
|
if folder.isInbox?
|
||||||
|
t(:inbox_name,:scope => :folder)
|
||||||
|
elsif folder.isSent?
|
||||||
|
t(:sent_name,:scope => :folder)
|
||||||
|
elsif folder.isDrafts?
|
||||||
|
t(:drafts_name,:scope => :folder)
|
||||||
|
elsif folder.isTrash?
|
||||||
|
t(:trash_name,:scope => :folder)
|
||||||
|
else
|
||||||
|
folder.name.capitalize
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def select_for_folders(name,id,collection,label,choice,blank)
|
||||||
|
html = ""
|
||||||
|
html << "<div class=\"param_group\">"
|
||||||
|
html << "<label class=\"label\">#{label}</label>"
|
||||||
|
html << simple_select_for_folders(name,id,collection,choice,blank)
|
||||||
|
html << "</div>"
|
||||||
|
end
|
||||||
|
|
||||||
|
def simple_select_for_folders(name,id,collection,choice,blank)
|
||||||
|
html = ""
|
||||||
|
html << select(name , id, options_from_collection_for_select(collection, 'id', 'full_name', choice),{ :include_blank => (blank == true ? true : false)})
|
||||||
|
html
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
2
app/helpers/internal_helper.rb
Executable file
2
app/helpers/internal_helper.rb
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
module InternalHelper
|
||||||
|
end
|
17
app/helpers/links_helper.rb
Executable file
17
app/helpers/links_helper.rb
Executable file
|
@ -0,0 +1,17 @@
|
||||||
|
module LinksHelper
|
||||||
|
|
||||||
|
def links_table_header
|
||||||
|
html = ""
|
||||||
|
$defaults["links_table_fields"].each do |f|
|
||||||
|
html << "<th>"
|
||||||
|
if params[:sort_field] == f
|
||||||
|
params[:sort_dir].nil? ? dir = 'desc' : dir = nil
|
||||||
|
end
|
||||||
|
|
||||||
|
html << link_to(Link.human_attribute_name(f), {:controller => 'links',:action => 'index',:sort_field => f,:sort_dir => dir}, {:class=>"header"})
|
||||||
|
html << "</th>"
|
||||||
|
end
|
||||||
|
html
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
118
app/helpers/messages_helper.rb
Executable file
118
app/helpers/messages_helper.rb
Executable file
|
@ -0,0 +1,118 @@
|
||||||
|
module MessagesHelper
|
||||||
|
|
||||||
|
def size_formatter(size)
|
||||||
|
if size <= 2**10
|
||||||
|
"#{size} #{t(:bytes,:scope=>:common)}"
|
||||||
|
elsif size <= 2**20
|
||||||
|
sprintf("%.1f #{t(:kbytes,:scope=>:common)}",size.to_f/2**10)
|
||||||
|
else
|
||||||
|
sprintf("%.1f #{t(:mbytes,:scope=>:common)}",size.to_f/2**20)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def date_formatter(date)
|
||||||
|
date.nil? ? t(:no_date,:scope=>:message) : date.strftime("%Y-%m-%d %H:%M")
|
||||||
|
end
|
||||||
|
|
||||||
|
def address_formatter(addr,op)
|
||||||
|
s = ""
|
||||||
|
return s if addr.nil?
|
||||||
|
length = $defaults["msg_address_length"].to_i
|
||||||
|
|
||||||
|
case op
|
||||||
|
when :index
|
||||||
|
fs = addr.gsub(/\"/,"").split(/</)
|
||||||
|
fs[0].size.zero? ? s = fs[1] : s = fs[0]
|
||||||
|
s.length >= length ? s = s[0,length]+"..." : s
|
||||||
|
return h(s)
|
||||||
|
when :show
|
||||||
|
#addr = addr[0].charseted.gsub(/\"/,"")
|
||||||
|
return h(addr.gsub(/\"/,""))
|
||||||
|
when :raw
|
||||||
|
#fs = addr.gsub(/\"/,"").split(/</)
|
||||||
|
#fs[0].size.zero? ? s = fs[1] : s << fs[0] + " <" + fs[1] + ">"
|
||||||
|
s = h(addr)
|
||||||
|
return s
|
||||||
|
when :reply
|
||||||
|
return h(addr)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def body_formatter(body,op)
|
||||||
|
case op
|
||||||
|
when :reply
|
||||||
|
s = "\n\n\n"
|
||||||
|
body.gsub(/^\s+/,"").split(/\n/).each do |line|
|
||||||
|
s += ">" + line + "\n"
|
||||||
|
end
|
||||||
|
s
|
||||||
|
when :edit
|
||||||
|
return body
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def subject_formatter(message,op)
|
||||||
|
case op
|
||||||
|
when :index
|
||||||
|
if message.subject.nil? or message.subject.size.zero?
|
||||||
|
s = t(:no_subject,:scope=>:message)
|
||||||
|
else
|
||||||
|
length = $defaults["msg_subject_length"].to_i
|
||||||
|
message.subject.length >= length ? s = message.subject[0,length]+"..." : s = message.subject
|
||||||
|
end
|
||||||
|
link_to s,{:controller => 'messages', :action => 'show', :id => message.uid} , :title => message.subject
|
||||||
|
when :show
|
||||||
|
if message.subject.nil? or message.subject.size.zero?
|
||||||
|
t(:no_subject,:scope=>:message)
|
||||||
|
else
|
||||||
|
message.subject
|
||||||
|
end
|
||||||
|
when :reply
|
||||||
|
if message.nil? or message.size.zero?
|
||||||
|
t(:reply_string,:scope=>:show)
|
||||||
|
else
|
||||||
|
t(:reply_string,:scope=>:show) + " " + message
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
def attachment_formatter(message)
|
||||||
|
message.content_type =~ /^text\/plain/ ? "" : "<i class=\"icon-file\"></i>"
|
||||||
|
end
|
||||||
|
|
||||||
|
def headers_links
|
||||||
|
#if @current_folder.hasFullName?(@folder_sent_name) || @current_folder.hasFullName?(@folder_drafts_name)
|
||||||
|
if @current_folder == @sent_folder || @current_folder == @drafts_folder
|
||||||
|
fields = $defaults["msgs_sent_view_fields"]
|
||||||
|
else
|
||||||
|
fields = $defaults["msgs_inbox_view_fields"]
|
||||||
|
end
|
||||||
|
|
||||||
|
html = ""
|
||||||
|
fields.each do |f|
|
||||||
|
html << "<th>"
|
||||||
|
if params[:sort_field] == f
|
||||||
|
params[:sort_dir].nil? ? dir = 'desc' : dir = nil
|
||||||
|
end
|
||||||
|
|
||||||
|
html << link_to(Message.human_attribute_name(f), {:controller => 'messages',:action => 'index',:sort_field => f,:sort_dir => dir}, {:class=>"header"})
|
||||||
|
html << "</th>"
|
||||||
|
end
|
||||||
|
html
|
||||||
|
end
|
||||||
|
|
||||||
|
#def content_text_plain_for_render(text)
|
||||||
|
#html = "<pre class=\"clearfix\">"
|
||||||
|
##html << text.gsub!(/\r\n/,"\n")
|
||||||
|
#html << h(text)
|
||||||
|
#html << "</pre>"
|
||||||
|
#html
|
||||||
|
#end
|
||||||
|
|
||||||
|
def humanize_attr(object,attr)
|
||||||
|
model_name = eval(object.class.model_name)
|
||||||
|
return model_name.human_attribute_name(attr)
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
2
app/helpers/messages_ops_helper.rb
Executable file
2
app/helpers/messages_ops_helper.rb
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
module MessagesOpsHelper
|
||||||
|
end
|
16
app/helpers/prefs_helper.rb
Executable file
16
app/helpers/prefs_helper.rb
Executable file
|
@ -0,0 +1,16 @@
|
||||||
|
module PrefsHelper
|
||||||
|
def servers_table_header
|
||||||
|
html = ""
|
||||||
|
$defaults["servers_table_fields"].each do |f|
|
||||||
|
html << "<th>"
|
||||||
|
if params[:sort_field] == f
|
||||||
|
params[:sort_dir].nil? ? dir = 'desc' : dir = nil
|
||||||
|
end
|
||||||
|
|
||||||
|
html << link_to(Server.human_attribute_name(f), {:controller => 'prefs',:action => 'servers',:sort_field => f,:sort_dir => dir}, {:class=>"header"})
|
||||||
|
html << "</th>"
|
||||||
|
end
|
||||||
|
html
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
2
app/helpers/user_helper.rb
Executable file
2
app/helpers/user_helper.rb
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
module UserHelper
|
||||||
|
end
|
0
app/mailers/.gitkeep
Normal file → Executable file
0
app/mailers/.gitkeep
Normal file → Executable file
0
app/models/.gitkeep
Normal file → Executable file
0
app/models/.gitkeep
Normal file → Executable file
0
app/models/link.rb
Normal file → Executable file
0
app/models/link.rb
Normal file → Executable file
|
@ -4,7 +4,7 @@ class User < ActiveRecord::Base
|
||||||
|
|
||||||
#acts_as_notes_owner
|
#acts_as_notes_owner
|
||||||
|
|
||||||
validates_presence_of :first_name,:last_name
|
validates_presence_of :first_name,:last_name,:login
|
||||||
validates_uniqueness_of :login
|
validates_uniqueness_of :login
|
||||||
has_many :servers, :dependent => :destroy
|
has_many :servers, :dependent => :destroy
|
||||||
has_one :prefs, :dependent => :destroy
|
has_one :prefs, :dependent => :destroy
|
||||||
|
|
19
app/views/common/_button.html.haml
Executable file
19
app/views/common/_button.html.haml
Executable file
|
@ -0,0 +1,19 @@
|
||||||
|
|
||||||
|
- size ||= "btn-small"
|
||||||
|
- type ||= "btn-primary"
|
||||||
|
- icon ||= ""
|
||||||
|
- onclick ||= 'empty'
|
||||||
|
|
||||||
|
- def isOnclick(value)
|
||||||
|
- if value != 'empty'
|
||||||
|
- {:onclick => "#{value}"}
|
||||||
|
- else
|
||||||
|
- {}
|
||||||
|
|
||||||
|
%button{isOnclick(onclick),:class=>"btn #{size} #{type}",
|
||||||
|
:type=>"submit",
|
||||||
|
:name=>"#{name}"}
|
||||||
|
- if !icon.empty?
|
||||||
|
%i{:class=>"#{icon}"}
|
||||||
|
= caption
|
||||||
|
|
6
app/views/common/_click_button.html.haml
Executable file
6
app/views/common/_click_button.html.haml
Executable file
|
@ -0,0 +1,6 @@
|
||||||
|
- size ||= "btn-small"
|
||||||
|
- type ||= "btn-primary"
|
||||||
|
|
||||||
|
%button{:class=>"btn #{size} #{type}",:type=>"submit",:onclick=>"window.location='#{url}'"}
|
||||||
|
%i{:class=>"#{icon}"}
|
||||||
|
= t(text.to_sym, :scope => scope.to_sym)
|
6
app/views/common/_form_button_icon.html.haml
Executable file
6
app/views/common/_form_button_icon.html.haml
Executable file
|
@ -0,0 +1,6 @@
|
||||||
|
- size ||= "btn-small"
|
||||||
|
- type ||= "btn-primary"
|
||||||
|
|
||||||
|
%button{:class=>"btn #{size} #{type}",:type=>"submit", :name=>"#{name}"}
|
||||||
|
%i{:class=>"#{icon_class}"}
|
||||||
|
= text
|
|
@ -1,8 +1,26 @@
|
||||||
- model = eval(object.class.model_name)
|
- model = eval(object.class.model_name)
|
||||||
|
- model_string = object.class.model_name.downcase
|
||||||
- label.nil? ? model_label = model.human_attribute_name(attr) : model_label = t(label.to_sym)
|
- label.nil? ? model_label = model.human_attribute_name(attr) : model_label = t(label.to_sym)
|
||||||
|
- val = value || object.instance_eval(attr) || ""
|
||||||
|
- if object.errors[attr.to_sym].empty?
|
||||||
.control-group
|
.control-group
|
||||||
%label{:class=>"control-label",:for=>"#{attr}"}
|
%label{:class=>"control-label",:for=>"#{attr}"}
|
||||||
= model_label
|
= model_label
|
||||||
.controls
|
.controls
|
||||||
%input{:id=>"#{model}_#{attr}",:name=>"#{model}[#{attr}]"}
|
%input{:id=>"#{model_string}_#{attr}",:name=>"#{model_string}[#{attr}]",:value=>"#{val}"}
|
||||||
|
%p{:class=>"help-block"}
|
||||||
|
= t(:example,:scope=>:common)
|
||||||
|
= example
|
||||||
|
- else
|
||||||
|
.control-group.error
|
||||||
|
%label{:class=>"control-label",:for=>"#{attr}"}
|
||||||
|
= model_label
|
||||||
|
.controls
|
||||||
|
%input{:id=>"#{model_string}_#{attr}",:name=>"#{model_string}[#{attr}]",:value=>"#{val}"}
|
||||||
|
%span{:class=>"help-inline"}
|
||||||
|
= object.errors[attr.to_sym].to_s
|
||||||
|
%p{:class=>"help-block"}
|
||||||
|
= t(:example,:scope=>:common)
|
||||||
|
= example
|
||||||
|
|
||||||
|
-#= render :partial => "common/input_form_desc_field",:locals => {:object => @user,:attr => 'login',:label => nil,:example => 'joe.doe',:value => params[:user] ? params[:user][:login] : "" }
|
||||||
|
|
|
@ -2,4 +2,7 @@
|
||||||
%label{:class=>"control-label",:for=>"#{attr}"}
|
%label{:class=>"control-label",:for=>"#{attr}"}
|
||||||
= model.capitalize.constantize.human_attribute_name(attr)
|
= model.capitalize.constantize.human_attribute_name(attr)
|
||||||
.controls
|
.controls
|
||||||
%input{:id=>"#{model}_#{attr}",:name=>"#{model}[#{attr}]"}
|
%input{:type=>"text",:id=>"#{model}_#{attr}",:name=>"#{model}[#{attr}]"}
|
||||||
|
|
||||||
|
|
||||||
|
-#= render :partial => "common/input_form_field",:locals => { :model => 'user',:attr => 'login'}
|
||||||
|
|
5
app/views/common/_input_password_form_field.html.haml
Executable file
5
app/views/common/_input_password_form_field.html.haml
Executable file
|
@ -0,0 +1,5 @@
|
||||||
|
.control-group
|
||||||
|
%label{:class=>"control-label",:for=>"#{attr}"}
|
||||||
|
= model.capitalize.constantize.human_attribute_name(attr)
|
||||||
|
.controls
|
||||||
|
%input{:type=>"password",:id=>"#{model}_#{attr}",:name=>"#{model}[#{attr}]"}
|
2
app/views/common/_logo.html.haml
Executable file
2
app/views/common/_logo.html.haml
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
.logo
|
||||||
|
= link_to image_tag("logo.png",:alt=> t(:mailr,:scope=>:common)), root_path
|
22
app/views/common/_main_navigation.html.haml
Executable file
22
app/views/common/_main_navigation.html.haml
Executable file
|
@ -0,0 +1,22 @@
|
||||||
|
- messages ||= ""
|
||||||
|
- compose ||= ""
|
||||||
|
- folders ||= ""
|
||||||
|
- contacts ||= ""
|
||||||
|
- prefs ||= ""
|
||||||
|
- links ||= ""
|
||||||
|
|
||||||
|
%ul{:class=>"nav nav-pills"}
|
||||||
|
%li{:class=>"#{messages}"}
|
||||||
|
%a{:href=>messages_path}
|
||||||
|
= t(:messages,:scope=>:message)
|
||||||
|
%li{:class=>"#{compose}"}
|
||||||
|
= link_to( t(:compose,:scope=>:compose), compose_path )
|
||||||
|
%li{:class=>"#{folders}"}
|
||||||
|
= link_to( t(:folders,:scope=>:folder), folders_path )
|
||||||
|
%li{:class=>"#{contacts}"}
|
||||||
|
= link_to( t(:contacts,:scope=>:contact), contacts_path )
|
||||||
|
%li{:class=>"#{prefs}"}
|
||||||
|
= link_to( t(:prefs,:scope=>:prefs), prefs_look_path )
|
||||||
|
%li{:class=>"#{links}"}
|
||||||
|
= link_to( t(:links,:scope=>:link), links_path )
|
||||||
|
|
22
app/views/common/_multiselect.html.haml
Executable file
22
app/views/common/_multiselect.html.haml
Executable file
|
@ -0,0 +1,22 @@
|
||||||
|
%select{:multiple=>"multiple",:class=>"#{style}",:id=>"#{id}",:name=>"#{name}"}
|
||||||
|
- objects.each do |o|
|
||||||
|
- option_value = escape_once(o.send(value))
|
||||||
|
- option_text = [option_value]
|
||||||
|
|
||||||
|
- unless text.nil?
|
||||||
|
- option_text = []
|
||||||
|
- text.each do |t|
|
||||||
|
- option_text << o.send(t)
|
||||||
|
- option_text = option_text.join(joiner)
|
||||||
|
- option_text.gsub!(/^\./,'')
|
||||||
|
|
||||||
|
|
||||||
|
- if selected_objects.include?(o)
|
||||||
|
%option{:value=>"#{option_value}",:selected=>"selected"}
|
||||||
|
= option_text
|
||||||
|
- else
|
||||||
|
%option{:value=>"#{option_value}"}
|
||||||
|
= option_text
|
||||||
|
|
||||||
|
-#<%= raw multi_select("", 'folders_to_show[]', @folders, @folders_shown,t(:shown,:scope=>:folder),:id,"",{:text => [:parent,:delim,:name]}) %>
|
||||||
|
-#def multi_select(id, name, objects, selected_objects, label, value,joiner,content = {})
|
5
app/views/common/_select_for_folders.html.haml
Executable file
5
app/views/common/_select_for_folders.html.haml
Executable file
|
@ -0,0 +1,5 @@
|
||||||
|
.control-group
|
||||||
|
%label{:class=>"control-label"}
|
||||||
|
= label
|
||||||
|
.controls
|
||||||
|
= raw simple_select_for_folders(name,id,collection,choice,blank)
|
2
app/views/common/_version.html.haml
Executable file
2
app/views/common/_version.html.haml
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
%p{:class=>"version"}
|
||||||
|
= link_to (t(:version,:scope=>:common) + " " + $defaults["version"]),about_path
|
8
app/views/contacts/index.html.haml
Executable file
8
app/views/contacts/index.html.haml
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
= content_for :sidebar do
|
||||||
|
= render :partial => "sidebar/sidebar"
|
||||||
|
|
||||||
|
= content_for :title do
|
||||||
|
\-
|
||||||
|
= t(:contacts,:scope=>:contact)
|
||||||
|
|
||||||
|
= render :partial => 'common/main_navigation', :locals => { :contacts => :active }
|
8
app/views/folders/_create.html.haml
Executable file
8
app/views/folders/_create.html.haml
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
%form{:class=>"form-horizontal",:action=>folders_create_path,:method=>"post"}
|
||||||
|
%fieldset
|
||||||
|
= render :partial => "common/select_for_folders",:locals => { :label=> t(:parent,:scope=>:folder), :name => "folder", :id => "parent", :collection => @folders, :choice => "", :blank => true}
|
||||||
|
= render :partial => "common/input_form_field",:locals => { :model => 'folder',:attr => 'target'}
|
||||||
|
.control-group
|
||||||
|
.form-actions
|
||||||
|
= render :partial => "common/button",:locals => { :name=>:create, :caption => t(:create,:scope=>:common), :icon =>'icon-plus icon-white'}
|
||||||
|
|
6
app/views/folders/_delete.html.haml
Executable file
6
app/views/folders/_delete.html.haml
Executable file
|
@ -0,0 +1,6 @@
|
||||||
|
%form{:class=>"form-horizontal",:action=>folders_delete_path,:method=>"post"}
|
||||||
|
%fieldset
|
||||||
|
= render :partial => "common/select_for_folders",:locals => { :label=> t(:to_delete,:scope=>:folder), :name => "folder", :id => "delete", :collection => @folders, :choice => "", :blank => true}
|
||||||
|
.control-group
|
||||||
|
.form-actions
|
||||||
|
= render :partial => "common/button",:locals => { :name=>:delete, :caption => t(:delete,:scope=>:common), :icon =>'icon-minus icon-white'}
|
16
app/views/folders/_list.html.haml
Executable file
16
app/views/folders/_list.html.haml
Executable file
|
@ -0,0 +1,16 @@
|
||||||
|
.well{:style=>"padding: 8px 3pt;"}
|
||||||
|
- if @folders_shown.nil? or @folders_shown.size.zero?
|
||||||
|
%p
|
||||||
|
= t(:no_shown,:scope=>:folder)
|
||||||
|
= link_to t(:folders,:scope=>:folder), folders_path
|
||||||
|
- else
|
||||||
|
%ul{:class=>"nav nav-list"}
|
||||||
|
%li{:class=>"nav-header"}
|
||||||
|
=t(:folders,:scope=>:folder)
|
||||||
|
- @folders_shown.each do |folder|
|
||||||
|
- if folder == @current_folder
|
||||||
|
%li{:class=>"active"}
|
||||||
|
= folder_link(folder)
|
||||||
|
- else
|
||||||
|
%li
|
||||||
|
= folder_link(folder)
|
11
app/views/folders/_refresh.html.haml
Executable file
11
app/views/folders/_refresh.html.haml
Executable file
|
@ -0,0 +1,11 @@
|
||||||
|
%form{:class=>"form-horizontal",:action=>folders_refresh_path,:method=>"post"}
|
||||||
|
%fieldset
|
||||||
|
.control-group
|
||||||
|
%label{:class=>"control-label"}
|
||||||
|
= t(:presentation,:scope=>:folder)
|
||||||
|
.controls
|
||||||
|
= render :partial=>"common/multiselect",:locals => {:objects => @folders, :selected_objects => @folders_shown,:style=>"",:id=>"multiselect_form",:name=>"folders_to_show[]",:value=>:id,:joiner=>"",:text=>[:parent,:delim,:name]}
|
||||||
|
.control-group
|
||||||
|
.form-actions
|
||||||
|
= render :partial => "common/button",:locals => { :name=>:show_hide, :caption => t(:show_hide,:scope=>:folder), :icon =>'icon-eye-open icon-white'}
|
||||||
|
= render :partial => "common/button",:locals => { :name=>:refresh, :caption => t(:refresh,:scope=>:folder), :icon =>'icon-refresh icon-white'}
|
9
app/views/folders/_system.html.haml
Executable file
9
app/views/folders/_system.html.haml
Executable file
|
@ -0,0 +1,9 @@
|
||||||
|
%form{:class=>"form-horizontal",:action=>folders_system_path,:method=>"post"}
|
||||||
|
%fieldset
|
||||||
|
= render :partial => "common/select_for_folders",:locals => { :label=> t(:folder,:scope => :folder) + " " + t(:inbox_name,:scope=>:folder), :name => "folder", :id => "mailbox_inbox", :collection => @folders, :choice => @folder_inbox, :blank => true}
|
||||||
|
= render :partial => "common/select_for_folders",:locals => { :label=> t(:folder,:scope => :folder) + " " + t(:trash_name,:scope=>:folder), :name => "folder", :id => "mailbox_trash", :collection => @folders, :choice => @folder_trash, :blank => true}
|
||||||
|
= render :partial => "common/select_for_folders",:locals => { :label=> t(:folder,:scope => :folder) + " " + t(:sent_name,:scope=>:folder), :name => "folder", :id => "mailbox_sent", :collection => @folders, :choice => @folder_sent, :blank => true}
|
||||||
|
= render :partial => "common/select_for_folders",:locals => { :label=> t(:folder,:scope => :folder) + " " + t(:drafts_name,:scope=>:folder), :name => "folder", :id => "mailbox_drafts", :collection => @folders, :choice => @folder_drafts, :blank => true}
|
||||||
|
.control-group
|
||||||
|
.form-actions
|
||||||
|
= render :partial => "common/button",:locals => { :name=>:set, :caption => t(:set,:scope=>:common), :icon =>'icon-cog icon-white'}
|
16
app/views/folders/index.html.haml
Executable file
16
app/views/folders/index.html.haml
Executable file
|
@ -0,0 +1,16 @@
|
||||||
|
= content_for :sidebar do
|
||||||
|
= render :partial => "sidebar/sidebar"
|
||||||
|
|
||||||
|
= content_for :title do
|
||||||
|
\-
|
||||||
|
= t(:folders,:scope=>:folder)
|
||||||
|
|
||||||
|
= render :partial => 'common/main_navigation', :locals => { :folders => :active }
|
||||||
|
|
||||||
|
.row
|
||||||
|
.span9
|
||||||
|
= render :partial => "refresh"
|
||||||
|
= render :partial => "create"
|
||||||
|
= render :partial => "delete"
|
||||||
|
= render :partial => "system"
|
||||||
|
|
4
app/views/internal/_version.html.erb
Executable file
4
app/views/internal/_version.html.erb
Executable file
|
@ -0,0 +1,4 @@
|
||||||
|
<p class="version">
|
||||||
|
<%= link_to (t(:version,:scope=>:common) + " " + $defaults["version"]),about_path %>
|
||||||
|
</p>
|
||||||
|
|
33
app/views/internal/about.html.erb
Executable file
33
app/views/internal/about.html.erb
Executable file
|
@ -0,0 +1,33 @@
|
||||||
|
<% content_for :title do %>
|
||||||
|
- <%= t(:about,:scope=>:internal) %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% content_for :sidebar do %>
|
||||||
|
<%= content_for_sidebar %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="block">
|
||||||
|
<div class="navigation-tabs clearfix">
|
||||||
|
<%= raw single_navigation(:about,:internal) %>
|
||||||
|
</div>
|
||||||
|
<div class="content">
|
||||||
|
|
||||||
|
<h4>
|
||||||
|
<%= t(:current_version,:scope=>:internal) + ": " + $defaults["version"] %>
|
||||||
|
</h4>
|
||||||
|
|
||||||
|
<div class="md">
|
||||||
|
<%= raw BlueCloth::new(render :file => 'README.markdown').to_html %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="md">
|
||||||
|
<%= raw BlueCloth::new(render :file => 'CHANGES').to_html %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="md">
|
||||||
|
<%= raw BlueCloth::new(render :file => 'TODO').to_html %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
0
app/views/internal/error.html.haml
Executable file
0
app/views/internal/error.html.haml
Executable file
30
app/views/layouts/application.html.haml
Executable file
30
app/views/layouts/application.html.haml
Executable file
|
@ -0,0 +1,30 @@
|
||||||
|
!!!
|
||||||
|
%html
|
||||||
|
%head
|
||||||
|
%title
|
||||||
|
=t(:mailr,:scope=>:common)
|
||||||
|
= yield :title
|
||||||
|
= stylesheet_link_tag "application", :media => "all"
|
||||||
|
= javascript_include_tag "application"
|
||||||
|
= csrf_meta_tags
|
||||||
|
%body{:class=>"application"}
|
||||||
|
.container
|
||||||
|
.row
|
||||||
|
.span3#sidebar
|
||||||
|
= yield :sidebar
|
||||||
|
.span9#main
|
||||||
|
- if flash[:error]
|
||||||
|
.alert.alert-error
|
||||||
|
= flash[:error]
|
||||||
|
- elsif flash[:info]
|
||||||
|
.alert.alert-info
|
||||||
|
= flash[:info]
|
||||||
|
- elsif flash[:success]
|
||||||
|
.alert.alert-success
|
||||||
|
= flash[:success]
|
||||||
|
= yield
|
||||||
|
%hr/
|
||||||
|
.row
|
||||||
|
#footer-simple
|
||||||
|
%a{:href=>"https://github.com/musashimm/mailr"} MailR
|
||||||
|
\- open source web mail client
|
8
app/views/links/index.html.haml
Executable file
8
app/views/links/index.html.haml
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
= content_for :sidebar do
|
||||||
|
= render :partial => "sidebar/sidebar"
|
||||||
|
|
||||||
|
= content_for :title do
|
||||||
|
\-
|
||||||
|
= t(:links,:scope=>:link)
|
||||||
|
|
||||||
|
= render :partial => 'common/main_navigation', :locals => { :links => :active }
|
19
app/views/messages/_attachment.html.erb
Executable file
19
app/views/messages/_attachment.html.erb
Executable file
|
@ -0,0 +1,19 @@
|
||||||
|
<td>
|
||||||
|
<%= link_to attachment.filename_charseted, attachment_download_path(attachment.parent_id,attachment.idx) %>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<%= attachment.main_type %>/<%= attachment.sub_type %>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<%= attachment.charset %>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<%= attachment.content_transfer_encoding %>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<%= size_formatter(attachment.getSize) %>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<%= link_to image_tag(current_theme_image_path('download.png')), attachment_download_path(attachment.parent_id,attachment.idx) %>
|
||||||
|
</td>
|
||||||
|
|
14
app/views/messages/_attachment.html.haml
Executable file
14
app/views/messages/_attachment.html.haml
Executable file
|
@ -0,0 +1,14 @@
|
||||||
|
%td
|
||||||
|
= attachment.filename_charseted
|
||||||
|
%td
|
||||||
|
= attachment.main_type
|
||||||
|
\/
|
||||||
|
= attachment.sub_type
|
||||||
|
%td
|
||||||
|
= attachment.charset
|
||||||
|
%td
|
||||||
|
= attachment.content_transfer_encoding
|
||||||
|
%td
|
||||||
|
= size_formatter(attachment.getSize)
|
||||||
|
%td
|
||||||
|
= link_to "<i class=\"icon-download-alt\"></i>".html_safe, attachment_download_path(attachment.parent_id,attachment.idx)
|
13
app/views/messages/_attachments.html.erb
Executable file
13
app/views/messages/_attachments.html.erb
Executable file
|
@ -0,0 +1,13 @@
|
||||||
|
<div class="attachments">
|
||||||
|
<span class="title"><%= t(:attachments,:scope=>:message) %></span>
|
||||||
|
<table class="table">
|
||||||
|
|
||||||
|
<% trclass = :even %>
|
||||||
|
<% for idx in 0..@attachments.size-1 %>
|
||||||
|
<tr class="<%= trclass.to_s %>">
|
||||||
|
<%= render :partial => 'attachment', :object => @attachments[idx] %>
|
||||||
|
</tr>
|
||||||
|
<% trclass == :even ? trclass = :odd : trclass = :even %>
|
||||||
|
<% end %>
|
||||||
|
</table>
|
||||||
|
</div>
|
9
app/views/messages/_attachments.html.haml
Executable file
9
app/views/messages/_attachments.html.haml
Executable file
|
@ -0,0 +1,9 @@
|
||||||
|
%h1
|
||||||
|
%small
|
||||||
|
= t(:attachments,:scope=>:message)
|
||||||
|
%table{:class=>"table table-bordered"}
|
||||||
|
%tbody
|
||||||
|
- for idx in 0..@attachments.size-1
|
||||||
|
%tr
|
||||||
|
= render :partial => 'attachment', :locals => { :attachment => @attachments[idx] }
|
||||||
|
|
4
app/views/messages/_file_attach.html.erb
Executable file
4
app/views/messages/_file_attach.html.erb
Executable file
|
@ -0,0 +1,4 @@
|
||||||
|
<td><%= check_box_tag "files[]", file_attach[:name] %></td>
|
||||||
|
<td><%= file_attach[:name] %></td>
|
||||||
|
<td><%= size_formatter(file_attach[:size]) %></td>
|
||||||
|
<td class="last"> </td>
|
16
app/views/messages/_file_attachs.html.erb
Executable file
16
app/views/messages/_file_attachs.html.erb
Executable file
|
@ -0,0 +1,16 @@
|
||||||
|
<div class="attachments">
|
||||||
|
<span class="title"><%= t(:attachments,:scope=>:message) %></span>
|
||||||
|
<% if not @attachments.size.zero? %>
|
||||||
|
<% trclass = :even %>
|
||||||
|
<table class="table">
|
||||||
|
<% @attachments.each do |a| %>
|
||||||
|
<tr class="<%= trclass.to_s %>">
|
||||||
|
<%= render :partial => 'messages/file_attach', :object => a %>
|
||||||
|
</tr>
|
||||||
|
<% trclass == :even ? trclass = :odd : trclass = :even %>
|
||||||
|
<% end %>
|
||||||
|
</table>
|
||||||
|
<%= raw single_action('delete_marked','compose','minus.png') %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
|
9
app/views/messages/_file_select.html.erb
Executable file
9
app/views/messages/_file_select.html.erb
Executable file
|
@ -0,0 +1,9 @@
|
||||||
|
<div class="fileselect clearfix">
|
||||||
|
<label for="upload_file"><%= t(:select_file,:scope=>:compose) %></label>:
|
||||||
|
<%= file_field 'file', 'data' %>
|
||||||
|
<%= raw single_action('upload','compose','up.png') %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
14
app/views/messages/_header.html.erb
Executable file
14
app/views/messages/_header.html.erb
Executable file
|
@ -0,0 +1,14 @@
|
||||||
|
<div class="msg_header clearfix">
|
||||||
|
<%= raw show_param_view(@message,"from_addr",address_formatter(@from,:show)) %>
|
||||||
|
<%= raw show_param_view(@message,"to_addr",address_formatter(@to,:show)) %>
|
||||||
|
<% if not @cc.nil? %>
|
||||||
|
<%= raw show_param_view(@message,"cc_addr","CC jest") %>
|
||||||
|
<% end %>
|
||||||
|
<% if not @bcc.nil? %>
|
||||||
|
<%= raw show_param_view(@message,"bcc_addr","BCC jest ") %>
|
||||||
|
<% end %>
|
||||||
|
<%= raw show_param_view(@message,"subject",subject_formatter(@message,:show)) %>
|
||||||
|
<%= raw show_param_view(@message,"date",date_formatter(@date)) %>
|
||||||
|
<%= hidden_field_tag 'uids[]', @message.uid %>
|
||||||
|
<%= hidden_field_tag 'source', 'show' %>
|
||||||
|
</div>
|
39
app/views/messages/_header.html.haml
Executable file
39
app/views/messages/_header.html.haml
Executable file
|
@ -0,0 +1,39 @@
|
||||||
|
%table{:class=>"header bottom-pix18"}
|
||||||
|
%tbody
|
||||||
|
%tr
|
||||||
|
%td{:class=>"field_name"}
|
||||||
|
= humanize_attr(@message,'from_addr') + ':'
|
||||||
|
%td
|
||||||
|
= address_formatter(@from,:show)
|
||||||
|
%tr
|
||||||
|
%td{:class=>"field_name"}
|
||||||
|
= humanize_attr(@message,'to_addr') + ':'
|
||||||
|
%td
|
||||||
|
= address_formatter(@to,:show)
|
||||||
|
- if not @cc.nil?
|
||||||
|
%tr
|
||||||
|
%td{:class=>"field_name"}
|
||||||
|
= humanize_attr(@message,'cc_addr') + ':'
|
||||||
|
%td
|
||||||
|
"CC jest"
|
||||||
|
- if not @bcc.nil?
|
||||||
|
%tr
|
||||||
|
%td{:class=>"field_name"}
|
||||||
|
= humanize_attr(@message,'bcc_addr') + ':'
|
||||||
|
%td
|
||||||
|
"BCC jest"
|
||||||
|
%tr
|
||||||
|
%td{:class=>"field_name"}
|
||||||
|
= humanize_attr(@message,'subject') + ':'
|
||||||
|
%td
|
||||||
|
= subject_formatter(@message,:show)
|
||||||
|
%tr
|
||||||
|
%td{:class=>"field_name"}
|
||||||
|
= humanize_attr(@message,'date') + ':'
|
||||||
|
%td
|
||||||
|
= date_formatter(@date)
|
||||||
|
|
||||||
|
= hidden_field_tag 'uids[]', @message.uid
|
||||||
|
= hidden_field_tag 'source', 'show'
|
||||||
|
%pre{:class=>"header_raw",:style=>"display: none;"}
|
||||||
|
= @plain_header
|
3
app/views/messages/_html_part.html.erb
Executable file
3
app/views/messages/_html_part.html.erb
Executable file
|
@ -0,0 +1,3 @@
|
||||||
|
<iframe frameborder="0" src="<%= html_body_path(@message.uid) %>">
|
||||||
|
</iframe>
|
||||||
|
|
8
app/views/messages/_image.html.erb
Executable file
8
app/views/messages/_image.html.erb
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
<div class="image">
|
||||||
|
<%= image_tag(attachment_download_path(image.parent_id,image.idx), :size => @current_user.prefs.msg_image_thumbnail_size, :alt=>image.filename, :title=>image.filename) %>
|
||||||
|
<div class="desc">
|
||||||
|
<span class="name"><%= link_to (image.filename,attachment_download_path(image.parent_id,image.idx)) %></span>
|
||||||
|
<span class="size"><%= size_formatter(image.getSize) %></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
8
app/views/messages/_images.html.erb
Executable file
8
app/views/messages/_images.html.erb
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
<div class="images">
|
||||||
|
|
||||||
|
<% for idx in 0..@images.size-1 %>
|
||||||
|
<%= render :partial => 'image', :object => @images[idx] %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="clear"></div>
|
||||||
|
</div>
|
38
app/views/messages/_message.html.haml
Executable file
38
app/views/messages/_message.html.haml
Executable file
|
@ -0,0 +1,38 @@
|
||||||
|
%td
|
||||||
|
= check_box_tag "uids[]", message.uid
|
||||||
|
%td
|
||||||
|
= raw attachment_formatter(message)
|
||||||
|
%td
|
||||||
|
- if @current_folder == @sent_folder || @current_folder == @drafts_folder
|
||||||
|
= address_formatter(message.to_addr,:index)
|
||||||
|
- else
|
||||||
|
= address_formatter(message.from_addr,:index)
|
||||||
|
%td
|
||||||
|
= subject_formatter(message,:index)
|
||||||
|
%td
|
||||||
|
= date_formatter(message.date)
|
||||||
|
%td
|
||||||
|
= size_formatter(message.size)
|
||||||
|
%td
|
||||||
|
- if @current_folder == @drafts_folder
|
||||||
|
= link_to(t(:edit,:scope=>:message),edit_path(message.uid))
|
||||||
|
- else
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
-#
|
||||||
|
<td><%= check_box_tag "uids[]", message.uid %></td>
|
||||||
|
<td><%= attachment_formatter(message) %></td>
|
||||||
|
<% if @current_folder == @sent_folder || @current_folder == @drafts_folder %>
|
||||||
|
<td nowrap="nowrap"><%= address_formatter(message.to_addr,:index) %></td>
|
||||||
|
<% else %>
|
||||||
|
<td nowrap="nowrap"><%= address_formatter(message.from_addr,:index) %></td>
|
||||||
|
<% end %>
|
||||||
|
<td nowrap="nowrap"><%= subject_formatter(message,:index) %></td>
|
||||||
|
<td nowrap="nowrap"><%= date_formatter(message.date) %></td>
|
||||||
|
</td><td nowrap="nowrap"><%= size_formatter(message.size) %></td>
|
||||||
|
<% if @current_folder == @drafts_folder %>
|
||||||
|
<td><%= link_to(t(:edit,:scope=>:message),edit_path(message.uid)) %></td>
|
||||||
|
<% else %>
|
||||||
|
<td><%= raw(' ') %></td>
|
||||||
|
<% end %>
|
32
app/views/messages/_messages.html.haml
Executable file
32
app/views/messages/_messages.html.haml
Executable file
|
@ -0,0 +1,32 @@
|
||||||
|
.well{:style=>"padding: 5px 3pt;"}
|
||||||
|
%h3
|
||||||
|
= t(:current,:scope=>:folder)
|
||||||
|
\:
|
||||||
|
= pretty_folder_name(@current_folder)
|
||||||
|
%h5
|
||||||
|
= t(:total,:scope=>:message)
|
||||||
|
\:
|
||||||
|
= @messages.total_entries
|
||||||
|
|
||||||
|
= will_paginate @messages
|
||||||
|
|
||||||
|
%table{:class=>"table table-bordered"}
|
||||||
|
%thead
|
||||||
|
%tr
|
||||||
|
%th
|
||||||
|
%input{:id=>"toggleall",:type=>"checkbox",:name=>"allbox"}
|
||||||
|
%th
|
||||||
|
%i{:class=>"icon-file"}
|
||||||
|
= raw headers_links
|
||||||
|
%th
|
||||||
|
|
||||||
|
%tbody
|
||||||
|
- @messages.each do |m|
|
||||||
|
- m.unseen == true ? unseen = "unseen" : unseen = ""
|
||||||
|
%tr{:class=>"#{unseen}"}
|
||||||
|
= render :partial => 'messages/message', :locals => {:message => m}
|
||||||
|
|
||||||
|
|
||||||
|
= will_paginate @messages
|
||||||
|
|
||||||
|
|
20
app/views/messages/_multi_ops.html.haml
Executable file
20
app/views/messages/_multi_ops.html.haml
Executable file
|
@ -0,0 +1,20 @@
|
||||||
|
%p
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'copy',
|
||||||
|
:caption=>t('copy',:scope=>'message'),
|
||||||
|
:icon=>'icon-tags icon-white'}
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'move',
|
||||||
|
:caption=>t('move',:scope=>'message'),
|
||||||
|
:icon=>'icon-chevron-right icon-white'}
|
||||||
|
|
||||||
|
= t(:to_folder,:scope=>:folder) + " "
|
||||||
|
= raw simple_select_for_folders("folder","target",@folders_shown,'',true)
|
||||||
|
%p
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'trash',
|
||||||
|
:caption=>t('trash',:scope=>'message'),
|
||||||
|
:icon=>'icon-trash icon-white'}
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'set_unread',
|
||||||
|
:caption=>t('set_unread',:scope=>'message'),
|
||||||
|
:icon=>'icon-eye-close icon-white'}
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'set_read',
|
||||||
|
:caption=>t('set_read',:scope=>'message'),
|
||||||
|
:icon=>'icon-eye-open icon-white'}
|
27
app/views/messages/_new.html.erb
Executable file
27
app/views/messages/_new.html.erb
Executable file
|
@ -0,0 +1,27 @@
|
||||||
|
<div class="params">
|
||||||
|
<%= raw form_field( @message,
|
||||||
|
"to_addr",
|
||||||
|
nil,
|
||||||
|
"joe@domain.com"+', '+ t(:not_contain_at,:scope=>:compose),
|
||||||
|
address_formatter(@message.to_addr,@operation)
|
||||||
|
) %>
|
||||||
|
<%= raw form_field( @message,
|
||||||
|
"subject",
|
||||||
|
nil,
|
||||||
|
t(:subject_of_the_message,:scope=>:compose),
|
||||||
|
subject_formatter(@message.subject,@operation)
|
||||||
|
) %>
|
||||||
|
<%= raw area_field( @message,
|
||||||
|
"body",
|
||||||
|
nil,
|
||||||
|
t(:write_your_message_here,:scope=>:compose),
|
||||||
|
body_formatter(@message.body,@operation),
|
||||||
|
80,
|
||||||
|
20
|
||||||
|
) %>
|
||||||
|
</div>
|
||||||
|
<% if !@olduid.nil? %>
|
||||||
|
<%= hidden_field_tag 'olduid', @olduid %>
|
||||||
|
<% end %>
|
||||||
|
<%= raw group_action(@buttons) %>
|
||||||
|
|
10
app/views/messages/_search.html.erb
Executable file
10
app/views/messages/_search.html.erb
Executable file
|
@ -0,0 +1,10 @@
|
||||||
|
<div id="search" class="ops">
|
||||||
|
<p>
|
||||||
|
<%= t(:search) %>
|
||||||
|
<%= t(:in_message_field) %>
|
||||||
|
<select name="search_field"><%= options_for_select($defaults["msg_search_fields"])%></select>
|
||||||
|
<%= t(:string) %>
|
||||||
|
<input type="text" name="search_value" value="" size='16' id='search_value'/>
|
||||||
|
<%= submit_tag(t(:search), :name=>'search')%>
|
||||||
|
</p>
|
||||||
|
</div>
|
10
app/views/messages/_single_ops.html.erb
Executable file
10
app/views/messages/_single_ops.html.erb
Executable file
|
@ -0,0 +1,10 @@
|
||||||
|
<div class="ops clearfix">
|
||||||
|
<%= raw group_action_text(@multi1_buttons,t(:to_folder,:scope=>:folder)+ " " + simple_select_for_folders("folder","target",@folders_shown,'',true)) %>
|
||||||
|
<%= raw group_action(@multi3_buttons) %>
|
||||||
|
|
||||||
|
<div id="header_source" title="<%= t(:header_source,:scope=>:message)%>">
|
||||||
|
<pre>
|
||||||
|
<%= @plain_header %>
|
||||||
|
</pre>
|
||||||
|
</div>
|
||||||
|
</div>
|
25
app/views/messages/_single_ops.html.haml
Executable file
25
app/views/messages/_single_ops.html.haml
Executable file
|
@ -0,0 +1,25 @@
|
||||||
|
%p
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'copy',
|
||||||
|
:caption=>t('copy',:scope=>'message'),
|
||||||
|
:icon=>'icon-tags icon-white'}
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'move',
|
||||||
|
:caption=>t('move',:scope=>'message'),
|
||||||
|
:icon=>'icon-chevron-right icon-white'}
|
||||||
|
|
||||||
|
= t(:to_folder,:scope=>:folder) + " "
|
||||||
|
= raw simple_select_for_folders("folder","target",@folders_shown,'',true)
|
||||||
|
|
||||||
|
%p
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'show_header',
|
||||||
|
:caption=>t('show_header',:scope=>'show'),
|
||||||
|
:icon=>'icon-zoom-in icon-white'}
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'trash',
|
||||||
|
:caption=>t('trash',:scope=>'show'),
|
||||||
|
:icon=>'icon-trash icon-white'}
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'reply',
|
||||||
|
:caption=>t('reply',:scope=>'show'),
|
||||||
|
:icon=>'icon-arrow-left icon-white'}
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'forward',
|
||||||
|
:caption=>t('forward',:scope=>'show'),
|
||||||
|
:icon=>'icon-arrow-right icon-white'}
|
||||||
|
|
23
app/views/messages/compose.html.erb
Executable file
23
app/views/messages/compose.html.erb
Executable file
|
@ -0,0 +1,23 @@
|
||||||
|
<% content_for :sidebar do %>
|
||||||
|
<%= content_for_sidebar %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% content_for :title do %>
|
||||||
|
- <%= t(:compose,:scope=>:compose) %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="block">
|
||||||
|
<div class="navigation-tabs clearfix">
|
||||||
|
<%= raw main_navigation(:compose_tab) %>
|
||||||
|
</div>
|
||||||
|
<div class="content">
|
||||||
|
<h2><%= t(:new_message,:scope=>:compose) %></h2>
|
||||||
|
<div class="inner">
|
||||||
|
<%= form_tag(composed_path, :multipart => true) %>
|
||||||
|
<%= render :partial => 'messages/new' %>
|
||||||
|
<%= render :partial=> 'messages/file_attachs' %>
|
||||||
|
<%= render :partial => 'messages/file_select' %>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
44
app/views/messages/compose.html.haml
Executable file
44
app/views/messages/compose.html.haml
Executable file
|
@ -0,0 +1,44 @@
|
||||||
|
= content_for :sidebar do
|
||||||
|
= render :partial => "sidebar/sidebar"
|
||||||
|
|
||||||
|
= content_for :title do
|
||||||
|
= t(:compose,:scope=>:compose)
|
||||||
|
|
||||||
|
= render :partial => 'common/main_navigation', :locals => { :compose => :active }
|
||||||
|
|
||||||
|
%form{:multipart => 'true',:class=>"form-horizontal",:action=>composed_path,:method=>"post"}
|
||||||
|
.well{:style=>"padding: 5px 3pt;"}
|
||||||
|
%h3
|
||||||
|
= t(:new_message,:scope=>:compose)
|
||||||
|
%fieldset
|
||||||
|
= render :partial => "common/input_form_desc_field",:locals => {:object => @user,:attr => 'login',:label => nil,:example => 'joe.doe',:value => params[:user] ? params[:user][:login] : "" }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
-#
|
||||||
|
<div class="params">
|
||||||
|
<%= raw form_field( @message,
|
||||||
|
"to_addr",
|
||||||
|
nil,
|
||||||
|
"joe@domain.com"+', '+ t(:not_contain_at,:scope=>:compose),
|
||||||
|
address_formatter(@message.to_addr,@operation)
|
||||||
|
) %>
|
||||||
|
<%= raw form_field( @message,
|
||||||
|
"subject",
|
||||||
|
nil,
|
||||||
|
t(:subject_of_the_message,:scope=>:compose),
|
||||||
|
subject_formatter(@message.subject,@operation)
|
||||||
|
) %>
|
||||||
|
<%= raw area_field( @message,
|
||||||
|
"body",
|
||||||
|
nil,
|
||||||
|
t(:write_your_message_here,:scope=>:compose),
|
||||||
|
body_formatter(@message.body,@operation),
|
||||||
|
80,
|
||||||
|
20
|
||||||
|
) %>
|
||||||
|
</div>
|
||||||
|
<% if !@olduid.nil? %>
|
||||||
|
<%= hidden_field_tag 'olduid', @olduid %>
|
||||||
|
<% end %>
|
||||||
|
<%= raw group_action(@buttons) %>
|
2
app/views/messages/html_body.html.erb
Executable file
2
app/views/messages/html_body.html.erb
Executable file
|
@ -0,0 +1,2 @@
|
||||||
|
<%= raw @body -%>
|
||||||
|
|
20
app/views/messages/index.html.haml
Executable file
20
app/views/messages/index.html.haml
Executable file
|
@ -0,0 +1,20 @@
|
||||||
|
= content_for :sidebar do
|
||||||
|
= render :partial => "sidebar/sidebar"
|
||||||
|
|
||||||
|
= content_for :title do
|
||||||
|
\-
|
||||||
|
= t(:messages,:scope=>:message)
|
||||||
|
|
||||||
|
= render :partial => 'common/main_navigation', :locals => { :messages => :active }
|
||||||
|
|
||||||
|
%form{:class=>"form-horizontal top-pix18",:action=>"#{messages_ops_multi_path}",:method=>"post"}
|
||||||
|
- if @current_folder.nil?
|
||||||
|
.alert
|
||||||
|
= t(:no_selected,:scope=>:folder)
|
||||||
|
|
||||||
|
- if @messages.size.zero?
|
||||||
|
.alert
|
||||||
|
= t(:no_in,:scope=>:message)
|
||||||
|
- else
|
||||||
|
= render :partial => 'multi_ops'
|
||||||
|
= render :partial => 'messages'
|
33
app/views/messages/index2.html.erb
Executable file
33
app/views/messages/index2.html.erb
Executable file
|
@ -0,0 +1,33 @@
|
||||||
|
<% content_for :sidebar do %>
|
||||||
|
<%= content_for_sidebar %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% content_for :title do %>
|
||||||
|
- <%= t(:messages,:scope=>:message) %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="block">
|
||||||
|
<div class="navigation-tabs clearfix">
|
||||||
|
<%= raw main_navigation(:messages_tab) %>
|
||||||
|
</div>
|
||||||
|
<div class="content">
|
||||||
|
<%= form_tag({:controller=>'messages_ops', :action=>'multi'},{:name=>'messages'})%>
|
||||||
|
|
||||||
|
<% if @current_folder.nil? %>
|
||||||
|
<h2><%= t(:no_selected,:scope=>:folder) %></h2>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% if @messages.size.zero? %>
|
||||||
|
<div class="actions-bar wat-cf">
|
||||||
|
<div class="header_info"><%= t(:no_in,:scope=>:message) %></div>
|
||||||
|
</div>
|
||||||
|
<% else %>
|
||||||
|
<%= render :partial => 'multi_ops' %>
|
||||||
|
<%= render :partial => 'messages' %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
43
app/views/messages/show.html.erb
Executable file
43
app/views/messages/show.html.erb
Executable file
|
@ -0,0 +1,43 @@
|
||||||
|
<% content_for :sidebar do %>
|
||||||
|
<%= content_for_sidebar %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% content_for :title do %>
|
||||||
|
- <%= subject_formatter(@message,:show) %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="block">
|
||||||
|
<div class="navigation-tabs clearfix">
|
||||||
|
<%= raw main_navigation(:show) %>
|
||||||
|
</div>
|
||||||
|
<div class="content clearfix">
|
||||||
|
<%= form_tag(messages_ops_single_path)%>
|
||||||
|
<%= render :partial => 'header' %>
|
||||||
|
<%= render :partial => 'single_ops' %>
|
||||||
|
|
||||||
|
<% if not @attachments.size.zero? %>
|
||||||
|
<%= render :partial => 'attachments' %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% if not @images.size.zero? %>
|
||||||
|
<%= render :partial => 'images' %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% if not @html_part.nil? %>
|
||||||
|
<%= render :partial => 'html_part' %>
|
||||||
|
<% else %>
|
||||||
|
<div class="render_text clearfix">
|
||||||
|
<% if @text_part.nil? %>
|
||||||
|
<p>
|
||||||
|
<%= t(:no_content,:scope => :message) %>
|
||||||
|
</p>
|
||||||
|
<% else %>
|
||||||
|
<%= raw content_text_plain_for_render(@text_part) %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
29
app/views/messages/show.html.haml
Executable file
29
app/views/messages/show.html.haml
Executable file
|
@ -0,0 +1,29 @@
|
||||||
|
= content_for :sidebar do
|
||||||
|
= render :partial => "sidebar/sidebar"
|
||||||
|
|
||||||
|
= content_for :title do
|
||||||
|
\-
|
||||||
|
= subject_formatter(@message,:show)
|
||||||
|
|
||||||
|
= render :partial => 'common/main_navigation', :locals => { :show => :active }
|
||||||
|
|
||||||
|
%form{:class=>"form-horizontal top-pix18",:action=>"#{messages_ops_multi_path}",:method=>"post"}
|
||||||
|
= render :partial => 'header'
|
||||||
|
= render :partial => 'single_ops'
|
||||||
|
- if not @attachments.size.zero?
|
||||||
|
= render :partial => 'attachments'
|
||||||
|
- if not @images.size.zero?
|
||||||
|
render :partial => 'images'
|
||||||
|
- if not @html_part.nil?
|
||||||
|
= render :partial => 'html_part'
|
||||||
|
- else
|
||||||
|
- if @text_part.nil?
|
||||||
|
.alert
|
||||||
|
= t(:no_content,:scope => :message)
|
||||||
|
- else
|
||||||
|
%pre
|
||||||
|
= @text_part
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
8
app/views/prefs/look.html.haml
Executable file
8
app/views/prefs/look.html.haml
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
= content_for :sidebar do
|
||||||
|
= render :partial => "sidebar/sidebar"
|
||||||
|
|
||||||
|
= content_for :title do
|
||||||
|
\-
|
||||||
|
= t(:look,:scope=>:prefs)
|
||||||
|
|
||||||
|
= render :partial => 'common/main_navigation', :locals => { :prefs => :active }
|
0
app/views/sidebar/_calendar_view.html.haml
Executable file
0
app/views/sidebar/_calendar_view.html.haml
Executable file
11
app/views/sidebar/_sidebar.html.haml
Executable file
11
app/views/sidebar/_sidebar.html.haml
Executable file
|
@ -0,0 +1,11 @@
|
||||||
|
= render :partial => "common/logo"
|
||||||
|
= render :partial => "common/version"
|
||||||
|
= render :partial => "folders/list"
|
||||||
|
%p
|
||||||
|
= render :partial => "common/button", :locals => {:name=>'logout',
|
||||||
|
:type=>"btn-danger",
|
||||||
|
:caption=>t('logout',:scope=>'user'),
|
||||||
|
:icon=>'icon-off icon-white',
|
||||||
|
:onclick=>"window.location='#{user_logout_path}'"}
|
||||||
|
= render :partial => "sidebar/calendar_view"
|
||||||
|
|
6
app/views/user/login.html.haml
Normal file → Executable file
6
app/views/user/login.html.haml
Normal file → Executable file
|
@ -5,8 +5,10 @@
|
||||||
%form{:class=>"form-horizontal top-pix18",:action=>"#{url_for(:controller => 'user', :action => 'authenticate')}",:method=>"post"}
|
%form{:class=>"form-horizontal top-pix18",:action=>"#{url_for(:controller => 'user', :action => 'authenticate')}",:method=>"post"}
|
||||||
%fieldset
|
%fieldset
|
||||||
= render :partial => "common/input_form_field",:locals => { :model => 'user',:attr => 'login'}
|
= render :partial => "common/input_form_field",:locals => { :model => 'user',:attr => 'login'}
|
||||||
= render :partial => "common/input_form_field",:locals => { :model => 'user',:attr => 'password'}
|
= render :partial => "common/input_password_form_field",:locals => { :model => 'user',:attr => 'password'}
|
||||||
= render :partial => "common/form_button",:locals => { :text => t(:please_login,:scope=>:user)}
|
.control-group
|
||||||
|
.controls
|
||||||
|
= render :partial => "common/button",:locals => { :name=>'login', :caption => t(:please_login,:scope=>:user), :icon =>'icon-lock icon-white'}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -2,8 +2,14 @@
|
||||||
\-
|
\-
|
||||||
= t(:setup,:scope=>:user)
|
= t(:setup,:scope=>:user)
|
||||||
|
|
||||||
|
%div{:class=>"alert alert-info"}
|
||||||
|
= t(:no_config,:scope=>:user)
|
||||||
%form{:class=>"form-horizontal top-pix18",:action=>"#{url_for(:controller => 'user', :action => 'create')}",:method=>"post"}
|
%form{:class=>"form-horizontal top-pix18",:action=>"#{url_for(:controller => 'user', :action => 'create')}",:method=>"post"}
|
||||||
%legend
|
%legend
|
||||||
= t(:setup,:scope=>:user)
|
= t(:setup,:scope=>:user)
|
||||||
%fieldset
|
%fieldset
|
||||||
= render :partial => "common/input_form_desc_field",:locals => {:object => @user,:attr => 'login',:label => nil,:example => 'joe doe',:value => params[:user].nil? ? params[:login] : params[:user][:login]}
|
= render :partial => "common/input_form_desc_field",:locals => {:object => @user,:attr => 'login',:label => nil,:example => 'joe.doe',:value => params[:user] ? params[:user][:login] : "" }
|
||||||
|
= render :partial => "common/input_form_desc_field",:locals => {:object => @user,:attr => 'first_name',:label => nil,:example => 'Joe',:value => params[:user] ? params[:user][:first_name] : ""}
|
||||||
|
= render :partial => "common/input_form_desc_field",:locals => {:object => @user,:attr => 'last_name',:label => nil,:example => 'Doe',:value => params[:user] ? params[:user][:last_name] : ""}
|
||||||
|
= render :partial => "common/input_form_desc_field",:locals => {:object => @server,:attr => 'name',:label => nil,:example => 'server.domain',:value => params[:server] ? params[:server][:name] : ""}
|
||||||
|
= render :partial => "common/form_button_icon",:locals => { :text => t(:send_config,:scope=>:user), :icon_class =>'icon-ok icon-white'}
|
||||||
|
|
|
@ -1,16 +0,0 @@
|
||||||
<% content_for :title do %>
|
|
||||||
<%= t(:unknown_title,:scope=>:user) %>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<div class="box">
|
|
||||||
<div class="box2">
|
|
||||||
<div class="logo"><a href="/"><img src="" alt="Mailr"/></a>
|
|
||||||
</div>
|
|
||||||
<h2><%= t(:unknown_title,:scope=>:user) %></h2>
|
|
||||||
<div class="content">
|
|
||||||
<div class="flash"><div class="message warning"><p><%= t(:unknown_flash,:scope=>:user) %></p></div></div>
|
|
||||||
<p><%= t(:unknown_login,:scope=>:user) %> -> <%= link_to t(:login,:scope=>:user),user_login_path %></p>
|
|
||||||
<p><%= t(:unknown_setup,:scope=>:user) %> -> <%= link_to t(:setup,:scope=>:user),:controller => "user",:action => "setup",:login => params[:login] %></p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
0
config/application.rb
Normal file → Executable file
0
config/application.rb
Normal file → Executable file
0
config/boot.rb
Normal file → Executable file
0
config/boot.rb
Normal file → Executable file
0
config/environment.rb
Normal file → Executable file
0
config/environment.rb
Normal file → Executable file
0
config/environments/development.rb
Normal file → Executable file
0
config/environments/development.rb
Normal file → Executable file
0
config/environments/production.rb
Normal file → Executable file
0
config/environments/production.rb
Normal file → Executable file
0
config/environments/test.rb
Normal file → Executable file
0
config/environments/test.rb
Normal file → Executable file
0
config/initializers/backtrace_silencers.rb
Normal file → Executable file
0
config/initializers/backtrace_silencers.rb
Normal file → Executable file
0
config/initializers/inflections.rb
Normal file → Executable file
0
config/initializers/inflections.rb
Normal file → Executable file
0
config/initializers/mime_types.rb
Normal file → Executable file
0
config/initializers/mime_types.rb
Normal file → Executable file
0
config/initializers/secret_token.rb
Normal file → Executable file
0
config/initializers/secret_token.rb
Normal file → Executable file
0
config/initializers/session_store.rb
Normal file → Executable file
0
config/initializers/session_store.rb
Normal file → Executable file
0
config/initializers/wrap_parameters.rb
Normal file → Executable file
0
config/initializers/wrap_parameters.rb
Normal file → Executable file
|
@ -60,6 +60,9 @@ pl:
|
||||||
for_imap: IMAP?
|
for_imap: IMAP?
|
||||||
for_smtp: SMTP?
|
for_smtp: SMTP?
|
||||||
auth: Metoda autoryzacji
|
auth: Metoda autoryzacji
|
||||||
|
folder:
|
||||||
|
name: Nazwa folderu
|
||||||
|
|
||||||
|
|
||||||
contact:
|
contact:
|
||||||
compose_to_selected: Napisz do wybranych
|
compose_to_selected: Napisz do wybranych
|
||||||
|
@ -99,7 +102,7 @@ pl:
|
||||||
folder:
|
folder:
|
||||||
folder: Folder
|
folder: Folder
|
||||||
folders: Foldery
|
folders: Foldery
|
||||||
no_shown: Nie prezentowany jest żaden folder. Skonfiguruj widok folderów w zakładce
|
no_shown: Nie jest prezentowany żaden folder. Skonfiguruj widok folderów w zakładce
|
||||||
parent: Folder nadrzędny
|
parent: Folder nadrzędny
|
||||||
to_create: Folder do utworzenia
|
to_create: Folder do utworzenia
|
||||||
to_delete: Folder do usunięcia
|
to_delete: Folder do usunięcia
|
||||||
|
@ -127,6 +130,7 @@ pl:
|
||||||
not_configured_inbox: Folder Odebrane nie został przypisany
|
not_configured_inbox: Folder Odebrane nie został przypisany
|
||||||
show_hide: Pokaż/Ukryj
|
show_hide: Pokaż/Ukryj
|
||||||
refresh: Odśwież
|
refresh: Odśwież
|
||||||
|
presentation: Prezentacja folderów
|
||||||
|
|
||||||
message:
|
message:
|
||||||
messages: Wiadomości
|
messages: Wiadomości
|
||||||
|
@ -171,9 +175,10 @@ pl:
|
||||||
delete: Usuń
|
delete: Usuń
|
||||||
reply_string: "Odp: "
|
reply_string: "Odp: "
|
||||||
trash: Usuń
|
trash: Usuń
|
||||||
|
forward: Przekaż
|
||||||
|
|
||||||
user:
|
user:
|
||||||
login_failure: Nieudane logowanie. Podano błędny e-mail lub hasło.
|
login_failure: Nieudane logowanie. Podano błędny login lub hasło.
|
||||||
logged_out: Użytkownik wylogowany
|
logged_out: Użytkownik wylogowany
|
||||||
setup_done: Konfiguracja zakończona. Proszę się zalogować.
|
setup_done: Konfiguracja zakończona. Proszę się zalogować.
|
||||||
please_login: Logowanie
|
please_login: Logowanie
|
||||||
|
@ -186,6 +191,8 @@ pl:
|
||||||
only_can_logins: Podany identyfikator użytkownika nie uprawnia do korzystania z aplikacji
|
only_can_logins: Podany identyfikator użytkownika nie uprawnia do korzystania z aplikacji
|
||||||
logout: Wyloguj
|
logout: Wyloguj
|
||||||
has_no_domain: Użytkownik nie ma ustawionej domeny
|
has_no_domain: Użytkownik nie ma ustawionej domeny
|
||||||
|
send_config: Wyślij
|
||||||
|
no_config: W bazie nie znaleziono żadnego użytkownika. Prawdopodobnie aplikacja nie została jeszcze skonfigurowana. Wypełnij poniższy formularz, aby dokonać podtsawowej konfiguracji.
|
||||||
|
|
||||||
internal:
|
internal:
|
||||||
imap_error: Błąd protokołu IMAP
|
imap_error: Błąd protokołu IMAP
|
||||||
|
@ -196,6 +203,7 @@ pl:
|
||||||
about: Informacje o programie
|
about: Informacje o programie
|
||||||
current_version: Aktualna wersja
|
current_version: Aktualna wersja
|
||||||
general_error: Błąd aplikacji
|
general_error: Błąd aplikacji
|
||||||
|
allready_configured: Podstawowe parametry aplikacji zostały już skonfigurowane. Zaloguj się na utworzonego użytkownika i dokonaj dodatkowej konfiguracji.
|
||||||
|
|
||||||
common:
|
common:
|
||||||
false_answer: Nie
|
false_answer: Nie
|
||||||
|
@ -204,7 +212,7 @@ pl:
|
||||||
no_tmp_dir: Brak katalogu tymczasowego
|
no_tmp_dir: Brak katalogu tymczasowego
|
||||||
must_be_unique: musi być unikalny
|
must_be_unique: musi być unikalny
|
||||||
some_add_info: jakieś dodatkowe informacje
|
some_add_info: jakieś dodatkowe informacje
|
||||||
example: przykład
|
example: "przykład:"
|
||||||
create: Utwórz
|
create: Utwórz
|
||||||
delete: Usuń
|
delete: Usuń
|
||||||
mailr: MailR
|
mailr: MailR
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue