alchemy_crm 2.0.1 → 2.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +10 -11
- data/alchemy_crm.gemspec +21 -21
- data/app/assets/javascripts/alchemy_crm/alchemy_crm.base.js +54 -54
- data/app/assets/stylesheets/alchemy_crm/base.css.scss +199 -199
- data/app/controllers/alchemy_crm/admin/base_controller.rb +5 -5
- data/app/controllers/alchemy_crm/admin/contact_groups_controller.rb +15 -15
- data/app/controllers/alchemy_crm/admin/contacts_controller.rb +95 -95
- data/app/controllers/alchemy_crm/admin/deliveries_controller.rb +66 -66
- data/app/controllers/alchemy_crm/admin/elements_controller_extension.rb +23 -23
- data/app/controllers/alchemy_crm/admin/mailings_controller.rb +44 -44
- data/app/controllers/alchemy_crm/admin/newsletters_controller.rb +16 -16
- data/app/controllers/alchemy_crm/admin/tags_controller.rb +60 -59
- data/app/controllers/alchemy_crm/base_controller.rb +3 -3
- data/app/controllers/alchemy_crm/contacts_controller.rb +88 -88
- data/app/controllers/alchemy_crm/mailings_controller.rb +16 -16
- data/app/controllers/alchemy_crm/recipients_controller.rb +30 -30
- data/app/controllers/alchemy_crm/subscriptions_controller.rb +54 -54
- data/app/helpers/alchemy/pages_helper_extension.rb +14 -14
- data/app/helpers/alchemy_crm/admin/base_helper.rb +8 -8
- data/app/helpers/alchemy_crm/mailings_helper.rb +175 -175
- data/app/mailers/alchemy_crm/bounce_receiver.rb +9 -9
- data/app/mailers/alchemy_crm/contacts_mailer.rb +21 -21
- data/app/mailers/alchemy_crm/mailings_mailer.rb +46 -46
- data/app/mailers/alchemy_crm/subscriptions_mailer.rb +12 -12
- data/app/models/alchemy/essence_element_teaser.rb +14 -14
- data/app/models/alchemy_crm/contact.rb +260 -260
- data/app/models/alchemy_crm/contact_group.rb +15 -15
- data/app/models/alchemy_crm/contact_group_filter.rb +17 -17
- data/app/models/alchemy_crm/delivery.rb +54 -54
- data/app/models/alchemy_crm/element_extension.rb +23 -23
- data/app/models/alchemy_crm/mailing.rb +90 -90
- data/app/models/alchemy_crm/newsletter.rb +33 -33
- data/app/models/alchemy_crm/reaction.rb +5 -5
- data/app/models/alchemy_crm/recipient.rb +46 -46
- data/app/models/alchemy_crm/subscription.rb +4 -4
- data/app/views/alchemy/admin/elements/fill.js.erb +11 -11
- data/app/views/alchemy/elements/_newsletter_article_view.html.erb +14 -14
- data/app/views/alchemy/elements/_newsletter_greeting_view.html.erb +9 -9
- data/app/views/alchemy/elements/_newsletter_signout_form_view.html.erb +18 -18
- data/app/views/alchemy/elements/_newsletter_signup_form_view.html.erb +62 -62
- data/app/views/alchemy/essences/_essence_element_teaser_editor.html.erb +29 -29
- data/app/views/alchemy/newsletter_layouts/_standard.html.erb +37 -37
- data/app/views/alchemy_crm/admin/contact_groups/_contact_group.html.erb +30 -30
- data/app/views/alchemy_crm/admin/contact_groups/_filter.html.erb +28 -28
- data/app/views/alchemy_crm/admin/contact_groups/_form.html.erb +45 -45
- data/app/views/alchemy_crm/admin/contact_groups/_tag.html.erb +4 -4
- data/app/views/alchemy_crm/admin/contact_groups/add_filter.js.erb +7 -7
- data/app/views/alchemy_crm/admin/contact_groups/index.html.erb +28 -28
- data/app/views/alchemy_crm/admin/contacts/_contact.html.erb +42 -42
- data/app/views/alchemy_crm/admin/contacts/_form.html.erb +76 -76
- data/app/views/alchemy_crm/admin/contacts/import.html.erb +27 -27
- data/app/views/alchemy_crm/admin/contacts/index.html.erb +39 -39
- data/app/views/alchemy_crm/admin/contacts/vcf_import_result.html.erb +24 -24
- data/app/views/alchemy_crm/admin/deliveries/_delivery.html.erb +30 -30
- data/app/views/alchemy_crm/admin/deliveries/_form.html.erb +61 -61
- data/app/views/alchemy_crm/admin/deliveries/_recipient.html.erb +36 -36
- data/app/views/alchemy_crm/admin/deliveries/index.html.erb +21 -21
- data/app/views/alchemy_crm/admin/deliveries/show.html.erb +61 -61
- data/app/views/alchemy_crm/admin/elements/teasables.html.erb +53 -53
- data/app/views/alchemy_crm/admin/mailings/_form.html.erb +41 -41
- data/app/views/alchemy_crm/admin/mailings/_mailing.html.erb +73 -73
- data/app/views/alchemy_crm/admin/mailings/edit_content.html.erb +170 -170
- data/app/views/alchemy_crm/admin/mailings/import_result.html.erb +18 -18
- data/app/views/alchemy_crm/admin/mailings/index.html.erb +25 -25
- data/app/views/alchemy_crm/admin/newsletters/_form.html.erb +52 -52
- data/app/views/alchemy_crm/admin/newsletters/_tag_with_radiobutton.html.erb +5 -5
- data/app/views/alchemy_crm/admin/newsletters/index.html.erb +29 -29
- data/app/views/alchemy_crm/admin/newsletters/new.html.erb +4 -4
- data/app/views/alchemy_crm/admin/tags/_radio_tag.html.erb +4 -4
- data/app/views/alchemy_crm/admin/tags/_tag.html.erb +30 -30
- data/app/views/alchemy_crm/admin/tags/edit.html.erb +32 -32
- data/app/views/alchemy_crm/admin/tags/index.html.erb +23 -23
- data/app/views/alchemy_crm/admin/tags/new.html.erb +14 -14
- data/app/views/alchemy_crm/contacts_mailer/signout_mail.html.erb +6 -6
- data/app/views/alchemy_crm/contacts_mailer/signout_mail.text.erb +2 -2
- data/app/views/alchemy_crm/contacts_mailer/signup_mail.html.erb +9 -9
- data/app/views/alchemy_crm/contacts_mailer/signup_mail.text.erb +2 -2
- data/app/views/alchemy_crm/mailings_mailer/verification_mail.html.erb +9 -9
- data/app/views/alchemy_crm/subscriptions/index.html.erb +4 -4
- data/app/views/alchemy_crm/subscriptions_mailer/overview_mail.html.erb +25 -25
- data/app/views/alchemy_crm/subscriptions_mailer/overview_mail.text.erb +2 -2
- data/app/views/csv_magic/import_errors.html.erb +23 -23
- data/app/views/csv_magic/mapper.html.erb +46 -46
- data/app/views/layouts/alchemy_crm/mailings.html.erb +177 -177
- data/config/initializers/assets.rb +2 -2
- data/config/locales/alchemy_crm.de.yml +1 -1
- data/config/locales/alchemy_crm.en.yml +1 -0
- data/config/locales/localized_country_select.de.rb +260 -260
- data/config/locales/localized_country_select.en.rb +274 -274
- data/config/routes.rb +67 -67
- data/db/migrate/20111104125306_remove_sent_mailing_pdf_id_from_sent_mailings.rb +1 -1
- data/db/migrate/20111124145923_namespace_alchemy_crm_models.rb +13 -13
- data/db/migrate/20120307160721_rename_alchemy_crm_recipients_sent_mailing_id.rb +3 -3
- data/db/migrate/20120320103412_add_indexes_to_alchemy_crm_sha1_columns.rb +3 -3
- data/db/migrate/20120327174301_add_more_indexes_to_alchemy_crm_tables.rb +10 -10
- data/lib/alchemy_crm.rb +15 -15
- data/lib/alchemy_crm/bounced_delivery.rb +38 -38
- data/lib/alchemy_crm/config.rb +25 -25
- data/lib/alchemy_crm/engine.rb +31 -31
- data/lib/alchemy_crm/i18n_helpers.rb +28 -28
- data/lib/alchemy_crm/newsletter_layout.rb +28 -28
- data/lib/alchemy_crm/seeder.rb +26 -26
- data/lib/alchemy_crm/version.rb +1 -1
- data/lib/generators/alchemy_crm/scaffold/files/newsletters.html.erb +19 -19
- data/lib/generators/alchemy_crm/scaffold/scaffold_generator.rb +2 -2
- data/lib/tasks/alchemy_crm.rake +22 -22
- data/lib/tasks/routes.rake +25 -25
- data/spec/config_spec.rb +24 -24
- data/spec/controllers/alchemy_crm/contacts_controller_spec.rb +147 -147
- data/spec/controllers/alchemy_crm/mailings_controller_spec.rb +62 -62
- data/spec/controllers/alchemy_crm/recipients_controller_spec.rb +109 -109
- data/spec/helpers/alchemy_crm/mailings_helper_spec.rb +165 -165
- data/spec/mailers/alchemy_crm/contacts_mailer_spec.rb +84 -84
- data/spec/mailers/alchemy_crm/mailings_mailer_spec.rb +29 -29
- data/spec/models/alchemy_crm/contact_group_spec.rb +25 -25
- data/spec/models/alchemy_crm/contact_spec.rb +71 -71
- data/spec/models/alchemy_crm/delivery_spec.rb +43 -39
- data/spec/models/alchemy_crm/mailing_spec.rb +46 -42
- data/spec/models/alchemy_crm/newsletter_spec.rb +29 -29
- data/spec/spec_helper.rb +36 -36
- metadata +6 -8
- data/rails/init.rb +0 -1
- data/recipes/alchemy-mailings-capistrano-tasks.rb +0 -12
@@ -1,194 +1,194 @@
|
|
1
1
|
<%- content_for(:javascript_includes) do -%>
|
2
|
-
|
2
|
+
<%= javascript_include_tag "alchemy_crm/scripts.js" %>
|
3
3
|
<%- end -%>
|
4
4
|
|
5
5
|
<%- content_for(:stylesheets) do -%>
|
6
|
-
|
6
|
+
<%= stylesheet_link_tag('alchemy_crm/styles') %>
|
7
7
|
<%- end -%>
|
8
8
|
|
9
9
|
<%- content_for(:subnav_additions) do -%>
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
10
|
+
<label><%= ::I18n.t('Active Mailing', :scope => :alchemy_crm) %> »</label>
|
11
|
+
<span class="page_status_and_name">
|
12
|
+
<span class="page_name"><%= @mailing.name %></span>
|
13
|
+
</span>
|
14
14
|
<%- end -%>
|
15
15
|
<%- content_for(:toolbar) do -%>
|
16
16
|
<div id="toolbar_buttons">
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
17
|
+
<div class="button_with_label">
|
18
|
+
<%= form_tag(
|
19
|
+
alchemy.unlock_admin_page_path(
|
20
|
+
@page,
|
21
|
+
:redirect_to => admin_mailings_path
|
22
|
+
),
|
23
|
+
:onsubmit => "return Alchemy.checkPageDirtyness(this, {title: '#{ t('Warning!') }', message: '#{ t('You have unsaved elements on this page. Do you really want to leave this page?') }', okLabel: '#{ t('Yes') }', cancelLabel: '#{ t('No') }'});"
|
24
|
+
) do %>
|
25
|
+
<button class="icon_button" title="<%= t('explain_unlocking') %>">
|
26
|
+
<%= render_icon('close') %>
|
27
|
+
</button>
|
28
|
+
<label><%= t("unlock_page") %></label>
|
29
|
+
<% end %>
|
30
|
+
</div>
|
31
|
+
<div class="button_with_label">
|
32
|
+
<%= link_to_overlay_window(
|
33
|
+
render_icon('mailing_edit'),
|
34
|
+
alchemy_crm.edit_admin_mailing_path(@mailing),
|
35
|
+
{
|
36
|
+
:title => alchemy_crm_t(:edit_mailing),
|
37
|
+
:size => '450x270'
|
38
|
+
},
|
39
|
+
{
|
40
|
+
:class => 'icon_button',
|
41
|
+
:title => alchemy_crm_t(:edit_mailing)
|
42
|
+
}
|
43
|
+
) -%><br />
|
44
|
+
<label><%= alchemy_crm_t(:edit_mailing) %></label>
|
45
|
+
</div>
|
46
|
+
<div class="button_with_label">
|
47
|
+
<%= link_to_overlay_window(
|
48
|
+
render_icon('send_mailing'),
|
49
|
+
alchemy_crm.new_admin_delivery_path(:mailing_id => @mailing.id),
|
50
|
+
{
|
51
|
+
:title => alchemy_crm_t('Send Mailing'),
|
52
|
+
:size => '420x210'
|
53
|
+
},
|
54
|
+
{
|
55
|
+
:title => alchemy_crm_t('Send Mailing'),
|
56
|
+
:class => 'icon_button'
|
57
|
+
}
|
58
|
+
) %>
|
59
|
+
<label><%= alchemy_crm_t('Send Mailing') %></label>
|
60
|
+
</div>
|
61
|
+
<div class="button_with_label">
|
62
|
+
<%= link_to(
|
63
|
+
render_icon('plain_text_view'),
|
64
|
+
alchemy_crm.admin_mailing_path(@mailing, :format => :text),
|
65
|
+
:title => alchemy_crm_t(:show_as_plain_text),
|
66
|
+
:class => 'icon_button',
|
67
|
+
:id => "toggle_preview_frame_button"
|
68
|
+
) %>
|
69
|
+
<label><%= alchemy_crm_t(:show_as_plain_text) %></label>
|
70
|
+
</div>
|
71
71
|
</div>
|
72
72
|
<div id="toolbar_buttons_right">
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
73
|
+
<div class="button_with_label" id="show_preview_window">
|
74
|
+
<%= link_to_function(
|
75
|
+
render_icon('preview_window'),
|
76
|
+
"AlchemyCrm.openPreviewWindow()",
|
77
|
+
{
|
78
|
+
:title => t('Show Preview Window'),
|
79
|
+
:class => 'icon_button'
|
80
|
+
}
|
81
|
+
) %><br />
|
82
|
+
<label><%= t('Show Preview Window') %></label>
|
83
|
+
</div>
|
84
|
+
<div class="button_with_label" id="show_element_window">
|
85
|
+
<%= link_to_function(
|
86
|
+
render_icon('element_window'),
|
87
|
+
"AlchemyCrm.openElementsWindow()",
|
88
|
+
{
|
89
|
+
:title => t('Show Elements Window'),
|
90
|
+
:class => 'icon_button'
|
91
|
+
}
|
92
|
+
) %><br />
|
93
|
+
<label><%= t('Show Elements Window') %></label>
|
94
|
+
</div>
|
95
95
|
</div>
|
96
96
|
<%- end -%>
|
97
97
|
<%- content_for :javascripts do -%>
|
98
98
|
<%= tinymce_javascript_tags %>
|
99
99
|
<script type="text/javascript" charset="utf-8">
|
100
100
|
|
101
|
-
|
102
|
-
|
103
|
-
|
101
|
+
AlchemyCrm.openPreviewWindow = function() {
|
102
|
+
Alchemy.PreviewWindow.init('<%= alchemy_crm.admin_mailing_path(@mailing) %>', '<%= t("Page Preview") -%>');
|
103
|
+
}
|
104
104
|
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
105
|
+
AlchemyCrm.openElementsWindow = function() {
|
106
|
+
Alchemy.ElementsWindow.init('<%= alchemy.admin_elements_path(:page_id => @page.id) -%>', {
|
107
|
+
texts: {
|
108
|
+
title: '<%= t("Elements") -%>',
|
109
|
+
dirtyTitle: '<%= t("Warning!") -%>',
|
110
|
+
dirtyMessage: '<%= t(:element_dirty_close_window_notice) -%>',
|
111
|
+
okLabel: '<%= t("Yes") -%>',
|
112
|
+
cancelLabel: '<%= t("No") -%>'
|
113
|
+
},
|
114
|
+
toolbarButtons: [
|
115
|
+
{
|
116
|
+
title: '<%= t("New Element") -%>',
|
117
|
+
label: '<%= t("New Element") -%>',
|
118
|
+
iconClass: 'new_element',
|
119
|
+
onClick: function() {
|
120
|
+
Alchemy.openWindow(
|
121
|
+
'<%= alchemy.new_admin_element_path(:page_id => @page.id) -%>',
|
122
|
+
'<%= t("New Element") -%>',
|
123
|
+
'320',
|
124
|
+
'120',
|
125
|
+
false,
|
126
|
+
true,
|
127
|
+
true
|
128
|
+
);
|
129
|
+
}
|
130
|
+
},
|
131
|
+
{
|
132
|
+
title: '<%= t("Clipboard") -%>',
|
133
|
+
label: '<%= t("Show clipboard") -%>',
|
134
|
+
iconClass: 'clipboard<%= clipboard_empty?("elements") ? "" : " full" -%>',
|
135
|
+
buttonId: 'clipboard_button',
|
136
|
+
onClick: function() {
|
137
|
+
Alchemy.openWindow(
|
138
|
+
'<%= alchemy.admin_clipboard_path(:remarkable_type => "elements") -%>',
|
139
|
+
'<%= t("Clipboard") -%>',
|
140
|
+
'380',
|
141
|
+
'270',
|
142
|
+
false,
|
143
|
+
true,
|
144
|
+
true
|
145
|
+
);
|
146
|
+
}
|
147
|
+
},
|
148
|
+
{
|
149
|
+
title: '<%= t("Show trash") -%>',
|
150
|
+
label: '<%= t("Show trash") -%>',
|
151
|
+
iconClass: 'trash<%= trash_empty?("elements") ? "" : " full" -%>',
|
152
|
+
buttonId: 'element_trash_button',
|
153
|
+
onClick: function() {
|
154
|
+
Alchemy.openTrashWindow(<%= @page.id %>, '<%= t("Trash") -%>');
|
155
|
+
}
|
156
|
+
}
|
157
|
+
]
|
158
|
+
}, function() {
|
159
|
+
Alchemy.SortableElements(<%= @page.id %>, '<%= form_authenticity_token %>');
|
160
|
+
Alchemy.ElementEditorSelector.init();
|
161
|
+
Alchemy.SelectBox('.element_editor select');
|
162
|
+
Alchemy.Tinymce.init(function() {
|
163
|
+
Alchemy.ElementDirtyObserver('#element_area');
|
164
|
+
});
|
165
|
+
jQuery('#cells').tabs();
|
166
|
+
jQuery('#cells').tabs('paging', { follow: true, followOnSelect: true } );
|
167
|
+
});
|
168
|
+
}
|
169
169
|
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
170
|
+
jQuery(document).ready(function($) {
|
171
|
+
var texts = {
|
172
|
+
title: '<%= t("Warning!") %>',
|
173
|
+
message: '<%= t(:element_dirty_page_leave_warning) %>',
|
174
|
+
okLabel: '<%= t("Yes") %>',
|
175
|
+
cancelLabel: '<%= t("No") %>'
|
176
|
+
};
|
177
|
+
$('#unlock_page_form, #visit_page_form, #publish_page_form').on('submit', function(event) {
|
178
|
+
var not_dirty = Alchemy.checkPageDirtyness(this, texts);
|
179
|
+
if (!not_dirty) Alchemy.pleaseWaitOverlay(false);
|
180
|
+
return not_dirty;
|
181
|
+
});
|
182
|
+
Alchemy.PageLeaveObserver(texts);
|
183
|
+
AlchemyCrm.openElementsWindow();
|
184
|
+
AlchemyCrm.openPreviewWindow();
|
185
185
|
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
186
|
+
$('#toggle_preview_frame_button').on('click', function(e) {
|
187
|
+
e.preventDefault();
|
188
|
+
AlchemyCrm.togglePreviewFrame(this, '<%= alchemy_crm.admin_mailing_path(@mailing, :format => :text) -%>', '<%= alchemy_crm.admin_mailing_path(@mailing) -%>');
|
189
|
+
return false;
|
190
|
+
});
|
191
|
+
});
|
192
192
|
|
193
193
|
</script>
|
194
194
|
<%- end -%>
|
@@ -1,23 +1,23 @@
|
|
1
1
|
<%- content_for(:javascript_includes) do -%>
|
2
|
-
|
2
|
+
<%= javascript_include_tag "alchemy_crm/scripts.js" %>
|
3
3
|
<%- end -%>
|
4
4
|
|
5
5
|
<%- content_for(:stylesheets) do -%>
|
6
|
-
|
6
|
+
<%= stylesheet_link_tag('alchemy_crm/styles') %>
|
7
7
|
<%- end -%>
|
8
8
|
|
9
9
|
<% toolbar(
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
10
|
+
:buttons => [
|
11
|
+
{
|
12
|
+
:icon => :close,
|
13
|
+
:label => t(:cancel),
|
14
|
+
:url => alchemy_crm.admin_contacts_path,
|
15
|
+
:title => t(:cancel),
|
16
|
+
:overlay => false,
|
17
|
+
:if_permitted_to => [:index, :alchemy_crm_admin_contacts]
|
18
|
+
}
|
19
|
+
],
|
20
|
+
:search => false
|
21
21
|
) -%>
|
22
22
|
|
23
23
|
<% if @errors -%>
|
@@ -28,10 +28,10 @@
|
|
28
28
|
|
29
29
|
<table>
|
30
30
|
<% @contacts.each do |contact| -%>
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
31
|
+
<tr>
|
32
|
+
<td><%= contact.fullname %></td>
|
33
|
+
<td><%= contact.email %></td>
|
34
|
+
<td><%= contact.errors.full_messages %></td>
|
35
|
+
</tr>
|
36
36
|
<% end -%>
|
37
37
|
</table>
|
@@ -1,39 +1,39 @@
|
|
1
1
|
<%- content_for(:stylesheets) do -%>
|
2
|
-
|
2
|
+
<%= stylesheet_link_tag('alchemy_crm/styles') %>
|
3
3
|
<%- end -%>
|
4
4
|
<%- content_for(:javascript_includes) do -%>
|
5
|
-
|
5
|
+
<%= javascript_include_tag('alchemy_crm/scripts') %>
|
6
6
|
<%- end -%>
|
7
7
|
|
8
8
|
<%- content_for :toolbar do -%>
|
9
9
|
<div id="toolbar_buttons">
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
10
|
+
<%= toolbar_button(
|
11
|
+
:icon => 'mailing_add',
|
12
|
+
:url => new_admin_mailing_path,
|
13
|
+
:title => alchemy_crm_t(:add_mailing),
|
14
|
+
:label => alchemy_crm_t(:add_mailing),
|
15
|
+
:overlay_options => {
|
16
|
+
:title => alchemy_crm_t(:add_mailing),
|
17
|
+
:size => '464x270'
|
18
|
+
},
|
19
|
+
:if_permitted_to => [:new, :alchemy_crm_admin_mailings]
|
20
|
+
) %>
|
21
21
|
</div>
|
22
22
|
<%= render 'alchemy/admin/partials/search_form' %>
|
23
23
|
<%- end -%>
|
24
24
|
|
25
25
|
<table class="list">
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
26
|
+
<%- unless @mailings.blank? -%>
|
27
|
+
<tr class="legend">
|
28
|
+
<th class="icon"></th>
|
29
|
+
<th class="name"><%= translate_model_attribute(:mailing, :name) %></th>
|
30
|
+
<th class="name"><%= translate_model_attribute(:mailing, :subject) %></th>
|
31
|
+
<th style="width: 120px"><%= translate_model_attribute(:mailing, :newsletter) %></th>
|
32
|
+
<th class="size" style="width: 120px"><%= translate_model_attribute(:mailing, :recipients_count) %></th>
|
33
|
+
<th class="time"><%= translate_model_attribute(:mailing, :next_delivery_at) %></th>
|
34
|
+
<th class="tools" style="width: 88px"></th>
|
35
|
+
</tr>
|
36
|
+
<%- end -%>
|
37
|
+
<%= render @mailings %>
|
38
38
|
</table>
|
39
39
|
<%= render 'alchemy/admin/partials/pagination_links', :items => @mailings %>
|