fat_free_crm 0.13.3 → 0.13.4
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of fat_free_crm might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/Gemfile.lock +4 -1
- data/app/helpers/accounts_helper.rb +6 -6
- data/app/helpers/admin/field_groups_helper.rb +4 -2
- data/app/helpers/application_helper.rb +18 -16
- data/app/helpers/comments_helper.rb +0 -6
- data/app/helpers/home_helper.rb +1 -1
- data/app/helpers/tags_helper.rb +1 -1
- data/app/helpers/tasks_helper.rb +6 -6
- data/app/mailers/subscription_mailer.rb +1 -0
- data/app/models/polymorphic/email.rb +2 -2
- data/app/models/polymorphic/task.rb +1 -1
- data/app/views/accounts/_edit.html.haml +1 -1
- data/app/views/accounts/_index_brief.html.haml +2 -2
- data/app/views/accounts/_index_long.html.haml +2 -2
- data/app/views/accounts/_new.html.haml +1 -1
- data/app/views/accounts/_sidebar_index.html.haml +1 -1
- data/app/views/accounts/_sidebar_show.html.haml +2 -2
- data/app/views/accounts/_top_section.html.haml +1 -1
- data/app/views/accounts/update.js.haml +1 -1
- data/app/views/admin/fields/index.html.haml +1 -1
- data/app/views/admin/groups/_group.html.haml +3 -2
- data/app/views/admin/users/_user.html.haml +11 -6
- data/app/views/campaigns/_edit.html.haml +1 -1
- data/app/views/campaigns/_index_brief.html.haml +1 -1
- data/app/views/campaigns/_index_long.html.haml +1 -1
- data/app/views/campaigns/_new.html.haml +1 -1
- data/app/views/campaigns/_sidebar_index.html.haml +1 -1
- data/app/views/campaigns/_sidebar_show.html.haml +2 -2
- data/app/views/campaigns/_top_section.html.haml +1 -1
- data/app/views/campaigns/update.js.haml +1 -1
- data/app/views/comments/_new.html.haml +2 -1
- data/app/views/contacts/_edit.html.haml +1 -1
- data/app/views/contacts/_index_brief.html.haml +2 -2
- data/app/views/contacts/_index_full.html.haml +2 -2
- data/app/views/contacts/_index_long.html.haml +2 -2
- data/app/views/contacts/_new.html.haml +1 -1
- data/app/views/contacts/_sidebar_show.html.haml +2 -2
- data/app/views/contacts/_top_section.html.haml +1 -1
- data/app/views/contacts/update.js.haml +1 -1
- data/app/views/emails/_email.html.haml +12 -6
- data/app/views/entities/_basic_search.html.haml +1 -2
- data/app/views/fields/_group_view.html.haml +3 -1
- data/app/views/home/_account.html.haml +1 -1
- data/app/views/home/_activity.html.haml +6 -4
- data/app/views/home/_opportunity.html.haml +1 -1
- data/app/views/home/_options.html.haml +1 -1
- data/app/views/home/_task.html.haml +4 -4
- data/app/views/home/_users_menu.html.haml +1 -1
- data/app/views/layouts/500.html.haml +1 -1
- data/app/views/layouts/application.html.haml +2 -2
- data/app/views/leads/_edit.html.haml +1 -1
- data/app/views/leads/_index_brief.html.haml +1 -1
- data/app/views/leads/_index_long.html.haml +1 -1
- data/app/views/leads/_new.html.haml +1 -1
- data/app/views/leads/_sidebar_index.html.haml +1 -1
- data/app/views/leads/_sidebar_show.html.haml +2 -2
- data/app/views/leads/_top_section.html.haml +1 -1
- data/app/views/leads/update.js.haml +1 -1
- data/app/views/opportunities/_edit.html.haml +1 -1
- data/app/views/opportunities/_index_brief.html.haml +1 -1
- data/app/views/opportunities/_index_long.html.haml +1 -1
- data/app/views/opportunities/_new.html.haml +1 -1
- data/app/views/opportunities/_sidebar_index.html.haml +1 -1
- data/app/views/opportunities/_sidebar_show.html.haml +3 -3
- data/app/views/opportunities/_top_section.html.haml +1 -1
- data/app/views/opportunities/index.html.haml +1 -1
- data/app/views/opportunities/update.js.haml +1 -1
- data/app/views/shared/_comment.html.haml +2 -2
- data/app/views/shared/_inline_styles.html.haml +1 -1
- data/app/views/subscription_mailer/comment_notification.text.erb +1 -1
- data/app/views/tasks/_completed.html.haml +2 -2
- data/app/views/tasks/_pending.html.haml +3 -2
- data/app/views/tasks/_selector.html.haml +3 -3
- data/app/views/tasks/_top_section.html.haml +1 -1
- data/app/views/users/_profile.html.haml +1 -1
- data/app/views/users/_user.html.haml +2 -2
- data/app/views/users/show.html.haml +1 -1
- data/app/views/versions/_version.html.haml +2 -2
- data/config/locales/de_fat_free_crm.yml +2 -2
- data/config/locales/en-GB_fat_free_crm.yml +2 -6
- data/config/locales/en-US_fat_free_crm.yml +2 -6
- data/config/locales/fr_fat_free_crm.yml +2 -7
- data/config/locales/ru_fat_free_crm.yml +1 -1
- data/fat_free_crm.gemspec +1 -0
- data/lib/fat_free_crm/callback.rb +8 -9
- data/lib/fat_free_crm/exceptions.rb +1 -1
- data/lib/fat_free_crm/gem_ext.rb +0 -1
- data/lib/fat_free_crm/version.rb +1 -1
- data/spec/helpers/admin/field_groups_helper_spec.rb +1 -1
- data/spec/shared/models.rb +6 -6
- metadata +16 -3
- data/lib/fat_free_crm/gem_ext/rails/text_helper.rb +0 -129
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f1f47a58276803b794edae1b70657bb629208c40
|
4
|
+
data.tar.gz: 18d5955737c8fde5c65eba581eb2ce35c91ba284
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1f56e47132c12f361e4c8ea6bc2443e77ba52992cca4b7e21c8a4fd28044b0a5a111903bce7254596f9227929ee9e05bc155a4a6e7ab852b825c81ddb08f841d
|
7
|
+
data.tar.gz: a192fe3b3898da36d3dcc624909c835b276208c4afd7533940027fdd84d5a30bf3117583334884b01052a3fe0f0ca9926b2f700a25ea31c549b0f546b2b6a524
|
data/Gemfile.lock
CHANGED
@@ -199,6 +199,8 @@ GEM
|
|
199
199
|
rails_12factor (0.0.2)
|
200
200
|
rails_serve_static_assets
|
201
201
|
rails_stdout_logging
|
202
|
+
rails_autolink (1.1.6)
|
203
|
+
rails (> 3.1)
|
202
204
|
rails_serve_static_assets (0.0.2)
|
203
205
|
rails_stdout_logging (0.0.3)
|
204
206
|
railties (3.2.19)
|
@@ -251,7 +253,7 @@ GEM
|
|
251
253
|
rspec-expectations (~> 2.99.0)
|
252
254
|
rspec-mocks (~> 2.99.0)
|
253
255
|
rubyzip (1.1.6)
|
254
|
-
sass (3.4.
|
256
|
+
sass (3.4.1)
|
255
257
|
sass-rails (3.2.6)
|
256
258
|
railties (~> 3.2.0)
|
257
259
|
sass (>= 3.1.10)
|
@@ -356,6 +358,7 @@ DEPENDENCIES
|
|
356
358
|
rails (~> 3.2.12)
|
357
359
|
rails3-jquery-autocomplete
|
358
360
|
rails_12factor
|
361
|
+
rails_autolink
|
359
362
|
ransack (= 1.1.0)
|
360
363
|
ransack_ui (>= 1.1.0)
|
361
364
|
rb-fchange
|
@@ -46,16 +46,16 @@ module AccountsHelper
|
|
46
46
|
|
47
47
|
content_tag(:span, :id => 'account_create_title') do
|
48
48
|
"(#{t :create_new} #{t :or} <a href='#' onclick='crm.select_account(); return false;'>#{t :select_existing}</a>):".html_safe
|
49
|
-
end
|
49
|
+
end +
|
50
50
|
|
51
51
|
content_tag(:span, :id => 'account_select_title') do
|
52
52
|
"(<a href='#' onclick='crm.create_account(); return false;'>#{t :create_new}</a> #{t :or} #{t :select_existing}):".html_safe
|
53
|
-
end
|
53
|
+
end +
|
54
54
|
|
55
|
-
content_tag(:span, ':', :id => 'account_disabled_title')
|
56
|
-
end
|
55
|
+
content_tag(:span, ':', :id => 'account_disabled_title')
|
56
|
+
end +
|
57
57
|
|
58
|
-
account_select(options)
|
58
|
+
account_select(options) +
|
59
59
|
form.text_field(:name, :style => 'width:324px; display:none;')
|
60
60
|
end
|
61
61
|
|
@@ -72,7 +72,7 @@ module AccountsHelper
|
|
72
72
|
def account_with_title_and_department(contact)
|
73
73
|
text = if !contact.title.blank? && contact.account
|
74
74
|
# works_at: "{{h(job_title)}} at {{h(company)}}"
|
75
|
-
content_tag :div, t(:works_at, :job_title => h(contact.title), :company => account_with_url_for(contact)).html_safe
|
75
|
+
content_tag :div, t(:works_at, :job_title => h(contact.title), :company => h(account_with_url_for(contact))).html_safe
|
76
76
|
elsif !contact.title.blank?
|
77
77
|
content_tag :div, h(contact.title)
|
78
78
|
elsif contact.account
|
@@ -5,9 +5,11 @@
|
|
5
5
|
#------------------------------------------------------------------------------
|
6
6
|
module Admin::FieldGroupsHelper
|
7
7
|
|
8
|
+
include ::ERB::Util
|
9
|
+
|
8
10
|
def field_group_subtitle(field_group)
|
9
11
|
asset = field_group.klass_name.downcase
|
10
|
-
html = t(field_group.name, :default => field_group.label)
|
12
|
+
html = t(field_group.name, :default => h(field_group.label)).html_safe
|
11
13
|
html << content_tag(:small, :id => "#{asset}_field_group_#{field_group.id}_intro") do
|
12
14
|
if field_group.tag_id
|
13
15
|
t(:field_group_tag_restriction, :assets => asset.pluralize, :tag => field_group.tag.try(:name))
|
@@ -15,7 +17,7 @@ module Admin::FieldGroupsHelper
|
|
15
17
|
t(:field_group_unrestricted, :assets => asset.pluralize)
|
16
18
|
end
|
17
19
|
end
|
18
|
-
html
|
20
|
+
html
|
19
21
|
end
|
20
22
|
|
21
23
|
def link_to_confirm(field_group)
|
@@ -37,7 +37,7 @@ module ApplicationHelper
|
|
37
37
|
#----------------------------------------------------------------------------
|
38
38
|
def subtitle(id, hidden = true, text = id.to_s.split("_").last.capitalize)
|
39
39
|
content_tag("div",
|
40
|
-
link_to("<small>#{ hidden ? "►" : "▼" }</small> #{text}".html_safe,
|
40
|
+
link_to("<small>#{ hidden ? "►" : "▼" }</small> #{sanitize text}".html_safe,
|
41
41
|
url_for(:controller => :home, :action => :toggle, :id => id),
|
42
42
|
:remote => true,
|
43
43
|
:onclick => "crm.flip_subtitle(this)"
|
@@ -109,7 +109,7 @@ module ApplicationHelper
|
|
109
109
|
link_to(t(:edit),
|
110
110
|
options[:url] || polymorphic_url(record, :action => :edit),
|
111
111
|
:remote => true,
|
112
|
-
:onclick => "this.href = this.href.split('?')[0] + '?previous='+crm.find_form('edit_#{name}');".html_safe
|
112
|
+
:onclick => "this.href = this.href.split('?')[0] + '?previous='+crm.find_form('edit_#{h name}');".html_safe
|
113
113
|
)
|
114
114
|
end
|
115
115
|
|
@@ -211,7 +211,7 @@ module ApplicationHelper
|
|
211
211
|
|
212
212
|
#----------------------------------------------------------------------------
|
213
213
|
def confirm_delete(model, params = {})
|
214
|
-
question = %(<span class="warn">#{t(:confirm_delete, model.class.to_s.downcase)}</span>)
|
214
|
+
question = %(<span class="warn">#{t(:confirm_delete, model.class.to_s.downcase)}</span>)
|
215
215
|
yes = link_to(t(:yes_button), params[:url] || model, :method => :delete)
|
216
216
|
no = link_to_function(t(:no_button), "$('#menu').html($('#confirm').html());")
|
217
217
|
text = "$('#confirm').html( $('#menu').html() );\n"
|
@@ -250,7 +250,7 @@ module ApplicationHelper
|
|
250
250
|
else
|
251
251
|
url = "http://" << url unless url.match(/^https?:\/\//)
|
252
252
|
end
|
253
|
-
link_to(image_tag("#{site}.gif", :size => "15x15"), url, :"data-popup" => true, :title => t(:open_in_window, url))
|
253
|
+
link_to(image_tag("#{site}.gif", :size => "15x15"), h(url), :"data-popup" => true, :title => t(:open_in_window, h(url)))
|
254
254
|
end
|
255
255
|
end.compact.join("\n").html_safe
|
256
256
|
end
|
@@ -392,11 +392,11 @@ module ApplicationHelper
|
|
392
392
|
onclick = %Q{
|
393
393
|
var query = $('#query').val(),
|
394
394
|
values = [];
|
395
|
-
$('input[name="#{name}[]"]').filter(':checked').each(function () {
|
395
|
+
$('input[name="#{h name}[]"]').filter(':checked').each(function () {
|
396
396
|
values.push(this.value);
|
397
397
|
});
|
398
398
|
$('#loading').show();
|
399
|
-
$.post('#{url}', {#{name}: values.join(','), query: query}, function () {
|
399
|
+
$.post('#{url}', {#{h name}: values.join(','), query: query}, function () {
|
400
400
|
$('#loading').hide();
|
401
401
|
});
|
402
402
|
}.html_safe
|
@@ -413,8 +413,8 @@ module ApplicationHelper
|
|
413
413
|
else
|
414
414
|
fmt_value.gsub(/((http|ftp|https):\/\/[\w\-_]+(\.[\w\-_]+)+([\w\-\.,@?^=%&:\/\+#]*[\w\-\@?^=%&\/\+#])?)/, "<a href=\"\\1\">\\1</a>")
|
415
415
|
end
|
416
|
-
|
417
|
-
|
416
|
+
last_class = (last ? 'last' : nil)
|
417
|
+
content_tag(:th, title, class: last_class) + content_tag(:td, fmt_value, class: last_class)
|
418
418
|
end
|
419
419
|
|
420
420
|
#----------------------------------------------------------------------------
|
@@ -422,7 +422,7 @@ module ApplicationHelper
|
|
422
422
|
def section_title(id, hidden = true, text = nil, info_text = nil)
|
423
423
|
text = id.to_s.split("_").last.capitalize if text == nil
|
424
424
|
content_tag("div", :class => "subtitle show_attributes") do
|
425
|
-
content = link_to("<small>#{ hidden ? "►" : "▼" }</small> #{text}".html_safe,
|
425
|
+
content = link_to("<small>#{ hidden ? "►" : "▼" }</small> #{sanitize text}".html_safe,
|
426
426
|
url_for(:controller => :home, :action => :toggle, :id => id),
|
427
427
|
:remote => true,
|
428
428
|
:onclick => "crm.flip_subtitle(this)"
|
@@ -455,21 +455,23 @@ module ApplicationHelper
|
|
455
455
|
action = (params['action'] == 'show') ? 'show' : 'index' # create update redraw filter index actions all use index view
|
456
456
|
views = FatFreeCRM::ViewFactory.views_for(:controller => controller, :action => action)
|
457
457
|
return nil unless views.size > 1
|
458
|
+
lis = ''.html_safe
|
458
459
|
content_tag :ul, :class => 'format-buttons' do
|
459
460
|
views.collect do |view|
|
460
461
|
classes = if (current_view_name == view.name) or (current_view_name == nil and view.template == nil) # nil indicates default template.
|
461
|
-
"#{view.name}-button active"
|
462
|
+
"#{h view.name}-button active"
|
462
463
|
else
|
463
|
-
"#{view.name}-button"
|
464
|
+
"#{h view.name}-button"
|
464
465
|
end
|
465
|
-
content_tag(:li) do
|
466
|
+
lis << content_tag(:li) do
|
466
467
|
url = (action == "index") ? send("redraw_#{controller}_path") : send("#{controller.singularize}_path")
|
467
|
-
link_to('#', :title => t(view.name, :default => view.title), :"data-view" => view.name, :"data-url" => url, :"data-context" => action, :class => classes) do
|
468
|
+
link_to('#', :title => t(view.name, :default => h(view.title)), :"data-view" => h(view.name), :"data-url" => h(url), :"data-context" => action, :class => classes) do
|
468
469
|
icon = view.icon || 'fa-bars'
|
469
|
-
content_tag(:i, nil, class: "fa #{icon}")
|
470
|
+
content_tag(:i, nil, class: "fa #{h icon}")
|
470
471
|
end
|
471
472
|
end
|
472
|
-
end
|
473
|
+
end
|
474
|
+
lis
|
473
475
|
end
|
474
476
|
end
|
475
477
|
|
@@ -478,7 +480,7 @@ module ApplicationHelper
|
|
478
480
|
# <span class="timeago" datetime="2008-07-17T09:24:17Z">July 17, 2008</span>
|
479
481
|
def timeago(time, options = {})
|
480
482
|
options[:class] ||= "timeago"
|
481
|
-
content_tag(:span, time.to_s, options.merge( title: time.getutc.iso8601)) if time
|
483
|
+
content_tag(:span, h(time.to_s), options.merge( title: time.getutc.iso8601)) if time
|
482
484
|
end
|
483
485
|
|
484
486
|
#----------------------------------------------------------------------------
|
@@ -5,12 +5,6 @@
|
|
5
5
|
#------------------------------------------------------------------------------
|
6
6
|
module CommentsHelper
|
7
7
|
|
8
|
-
# Generates a list of links for the subscribed users
|
9
|
-
def subscribed_user_links(users)
|
10
|
-
links = users.map {|user| link_to(user.full_name, user_path(user)) }
|
11
|
-
links.join(", ").html_safe
|
12
|
-
end
|
13
|
-
|
14
8
|
def notification_emails_configured?
|
15
9
|
config = Setting.email_comment_replies || {}
|
16
10
|
config[:server].present? && config[:user].present? && config[:password].present?
|
data/app/helpers/home_helper.rb
CHANGED
@@ -27,7 +27,7 @@ module HomeHelper
|
|
27
27
|
#----------------------------------------------------------------------------
|
28
28
|
def sort_by_users
|
29
29
|
users = [[ "all_users", t(:option_all_users) ]] + @all_users.map do |user|
|
30
|
-
escaped =
|
30
|
+
escaped = sanitize(user.full_name)
|
31
31
|
[ escaped, escaped ]
|
32
32
|
end
|
33
33
|
|
data/app/helpers/tags_helper.rb
CHANGED
data/app/helpers/tasks_helper.rb
CHANGED
@@ -86,7 +86,7 @@ module TasksHelper
|
|
86
86
|
|
87
87
|
#----------------------------------------------------------------------------
|
88
88
|
def hide_task_and_possibly_bucket(task, bucket)
|
89
|
-
text = "$('##{dom_id(task)}').remove();\n"
|
89
|
+
text = "$('##{h dom_id(task)}').remove();\n"
|
90
90
|
text << "$('#list_#{h bucket.to_s}').fadeOut({ duration:500 });\n" if Task.bucket_empty?(bucket, current_user, @view)
|
91
91
|
text.html_safe
|
92
92
|
end
|
@@ -100,16 +100,16 @@ module TasksHelper
|
|
100
100
|
|
101
101
|
#----------------------------------------------------------------------------
|
102
102
|
def insert_content(task, bucket, view)
|
103
|
-
text = "$('#list_#{bucket}').show();\n"
|
103
|
+
text = "$('#list_#{bucket}').show();\n"
|
104
104
|
html = render(:partial => view, :collection => [ task ], :locals => { :bucket => bucket })
|
105
|
-
text << "$('##{h bucket.to_s}').prepend('#{ j html }');\n"
|
106
|
-
text << "$('##{dom_id(task)}').effect('highlight', { duration:1500 });\n"
|
107
|
-
text
|
105
|
+
text << "$('##{h bucket.to_s}').prepend('#{ j html }');\n"
|
106
|
+
text << "$('##{dom_id(task)}').effect('highlight', { duration:1500 });\n"
|
107
|
+
text.html_safe
|
108
108
|
end
|
109
109
|
|
110
110
|
#----------------------------------------------------------------------------
|
111
111
|
def tasks_flash(message)
|
112
|
-
text = "$('#flash').html('#{ message }');\n"
|
112
|
+
text = "$('#flash').html('#{ sanitize(message) }');\n"
|
113
113
|
text << "crm.flash('notice', true)\n"
|
114
114
|
text.html_safe
|
115
115
|
end
|
@@ -3,6 +3,7 @@
|
|
3
3
|
# Fat Free CRM is freely distributable under the terms of MIT license.
|
4
4
|
# See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
|
5
5
|
#------------------------------------------------------------------------------
|
6
|
+
|
6
7
|
class SubscriptionMailer < ActionMailer::Base
|
7
8
|
|
8
9
|
def comment_notification(user, comment)
|
@@ -41,9 +41,9 @@ class Email < ActiveRecord::Base
|
|
41
41
|
|
42
42
|
def body_with_textile
|
43
43
|
if defined?(RedCloth)
|
44
|
-
RedCloth.new(body_without_textile).to_html
|
44
|
+
RedCloth.new(body_without_textile).to_html
|
45
45
|
else
|
46
|
-
body_without_textile.to_s.gsub("\n", "<br/>")
|
46
|
+
body_without_textile.to_s.gsub("\n", "<br/>")
|
47
47
|
end
|
48
48
|
end
|
49
49
|
alias_method_chain :body, :textile
|
@@ -63,7 +63,7 @@ class Task < ActiveRecord::Base
|
|
63
63
|
where('user_id = ? OR assigned_to = ?', user.id, user.id)
|
64
64
|
}
|
65
65
|
|
66
|
-
# Show
|
66
|
+
# Show tasks which either belong to the user and are unassigned, or are assigned to the user
|
67
67
|
scope :visible_on_dashboard, ->(user) {
|
68
68
|
where('(user_id = :user_id AND assigned_to IS NULL) OR assigned_to = :user_id', :user_id => user.id).where('completed_at IS NULL')
|
69
69
|
}
|
@@ -10,7 +10,7 @@
|
|
10
10
|
= render "accounts/contact_info", :f => f, :edit => true
|
11
11
|
= render "fields/groups", :f => f, :edit => true
|
12
12
|
= render "entities/permissions", :f => f, :edit => true, :entity => @account
|
13
|
-
= hook(:entity_form, self, {f: f, entity: @account})
|
13
|
+
= hook(:entity_form, self, {f: f, entity: @account})
|
14
14
|
|
15
15
|
.buttonbar
|
16
16
|
- if Setting.compound_address
|
@@ -6,7 +6,7 @@
|
|
6
6
|
.strip{:style => "color: gray;"} #{t :other}
|
7
7
|
|
8
8
|
%ul.tools
|
9
|
-
= hook(:account_tools_before, self, :account => account)
|
9
|
+
= hook(:account_tools_before, self, :account => account)
|
10
10
|
|
11
11
|
- if can?(:update, account)
|
12
12
|
%li= link_to_edit(account)
|
@@ -29,4 +29,4 @@
|
|
29
29
|
= t('pluralize.contact', account.contacts.count) << " | "
|
30
30
|
= t('pluralize.opportunity', account.opportunities.count)
|
31
31
|
|
32
|
-
= hook(:account_bottom, self, :account => account)
|
32
|
+
= hook(:account_bottom, self, :account => account)
|
@@ -6,7 +6,7 @@
|
|
6
6
|
.strip{:style => "color: gray;"} #{t :other}
|
7
7
|
|
8
8
|
%ul.tools
|
9
|
-
= hook(:account_tools_before, self, :account => account)
|
9
|
+
= hook(:account_tools_before, self, :account => account)
|
10
10
|
|
11
11
|
- if can?(:update, account)
|
12
12
|
%li= link_to_edit(account)
|
@@ -39,4 +39,4 @@
|
|
39
39
|
%dt
|
40
40
|
.tags= tags_for_index(account)
|
41
41
|
|
42
|
-
= hook(:account_bottom, self, :account => account)
|
42
|
+
= hook(:account_bottom, self, :account => account)
|
@@ -10,7 +10,7 @@
|
|
10
10
|
= render "accounts/contact_info", :f => f
|
11
11
|
= render "fields/groups", :f => f
|
12
12
|
= render "entities/permissions", :f => f, :entity => @account
|
13
|
-
= hook(:entity_form, self, {f: f, entity: @account})
|
13
|
+
= hook(:entity_form, self, {f: f, entity: @account})
|
14
14
|
|
15
15
|
.buttonbar
|
16
16
|
- if Setting.compound_address
|
@@ -46,7 +46,7 @@
|
|
46
46
|
|
47
47
|
- unless @account.background_info.blank?
|
48
48
|
.caption #{t :background_info}
|
49
|
-
= auto_link(simple_format @account.background_info)
|
49
|
+
= auto_link(simple_format @account.background_info)
|
50
50
|
|
51
51
|
= render "fields/sidebar_show", :asset => @account
|
52
52
|
|
@@ -54,4 +54,4 @@
|
|
54
54
|
%dt
|
55
55
|
.tags= tags_for_index(@account)
|
56
56
|
|
57
|
-
= hook(:show_account_sidebar_bottom, self, :account => @account)
|
57
|
+
= hook(:show_account_sidebar_bottom, self, :account => @account)
|
@@ -6,10 +6,11 @@
|
|
6
6
|
- confirm = (count.zero? ? nil : "#{t(:confirm_group_delete, count)}")
|
7
7
|
%li= link_to_delete [:admin, group], :confirm => confirm
|
8
8
|
|
9
|
-
%span
|
9
|
+
%span
|
10
10
|
=link_to(group.name, {:action => :edit, :id => group.id}, {:remote => true,
|
11
11
|
:onclick => "this.href = this.href.split('?')[0] + '?previous='+crm.find_form('edit_group');"})
|
12
12
|
%tt
|
13
13
|
- if (users = group.users).present?
|
14
14
|
== #{t('group_members')}:
|
15
|
-
|
15
|
+
- users.map do |user|
|
16
|
+
= link_to( h(user.full_name), user )
|
@@ -20,17 +20,18 @@
|
|
20
20
|
- elsif user != current_user
|
21
21
|
= link_to_suspend(user) << " | "
|
22
22
|
- else
|
23
|
-
|
23
|
+
%span.grayed #{t :suspend}!
|
24
|
+
= " | "
|
24
25
|
|
25
26
|
- if user != current_user
|
26
27
|
= link_to_confirm(user)
|
27
28
|
- else
|
28
29
|
%span.grayed #{t :delete}?
|
29
30
|
|
30
|
-
%span.black #{link_to(
|
31
|
+
%span.black #{link_to( user.full_name, user)} (#{user.username})
|
31
32
|
%tt
|
32
|
-
= "- #{
|
33
|
-
= " " + t(:at) + " " +
|
33
|
+
= "- #{user.title}" unless user.title.blank?
|
34
|
+
= " " + t(:at) + " " + user.company unless user.company.blank?
|
34
35
|
|
35
36
|
%span.black= "|"
|
36
37
|
- if user.last_request_at && user.login_count > 0
|
@@ -45,8 +46,12 @@
|
|
45
46
|
%span.warn #{t :user_never_logged_in}
|
46
47
|
%dt{ :style => "padding: 2px 0px 0px 0px" }
|
47
48
|
= link_to_email(user.email.to_s) << " | "
|
48
|
-
|
49
|
-
|
49
|
+
- if user.phone?
|
50
|
+
= t(:phone_small) << ":"
|
51
|
+
= content_tag(:b, user.phone) << " | "
|
52
|
+
- if user.mobile?
|
53
|
+
= t(:mobile_small) << ":"
|
54
|
+
= content_tag(:b, user.mobile) << " | "
|
50
55
|
|
51
56
|
- if !user.suspended?
|
52
57
|
%span #{t(:user_since, l(user.created_at.to_date, :format => :mmddyy))}
|
@@ -10,7 +10,7 @@
|
|
10
10
|
= render "campaigns/objectives", :f => f, :edit => true
|
11
11
|
= render "fields/groups", :f => f, :edit => true
|
12
12
|
= render "entities/permissions", :f => f, :edit => true, :entity => @campaign
|
13
|
-
= hook(:entity_form, self, {f: f, entity: @campaign})
|
13
|
+
= hook(:entity_form, self, {f: f, entity: @campaign})
|
14
14
|
|
15
15
|
.buttonbar
|
16
16
|
= f.submit t(:save_campaign)
|