ish_manager 0.1.8.505 → 0.1.8.506
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/ish_manager/application_controller.rb +1 -1
- data/app/controllers/ish_manager/email_actions_controller.rb +9 -1
- data/app/controllers/ish_manager/email_attachments_controller.rb +13 -0
- data/app/controllers/ish_manager/email_conversations_controller.rb +8 -0
- data/app/controllers/ish_manager/email_filters_controller.rb +1 -0
- data/app/views/ish_manager/application/_main_header_admin.haml +1 -1
- data/app/views/ish_manager/email_actions/index.haml +6 -2
- data/app/views/ish_manager/email_conversations/index.haml +12 -1
- data/app/views/ish_manager/email_conversations/show.haml +6 -0
- data/app/views/ish_manager/email_filters/_form.haml +36 -33
- data/app/views/ish_manager/email_filters/index.haml +7 -0
- data/config/routes.rb +8 -4
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4a1655bc4586c7be2fc0d3f600510d7d30536054ce87c2fdaf084314b78439fa
|
4
|
+
data.tar.gz: 6210a54fa0dbfa839adf118e85e9014a992eeb27d2dbeb3c9e95f2f038db095a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 67e252e726b3c850cbf53fb76eeae01dbf51ab0b02c2e4af139961a005a1d0fa7c1ca3f42601147a14c93095de7e66dbe8fdb5de023a1b672ca31aa1668fc77f
|
7
|
+
data.tar.gz: bfdc4132df9dc1f42d7b97841fd078627281cab3b92bf8e82e70ba422b5946c21e18b1dd2cf585e5891abc1a48483a790edaa1e32cc639313ff61bb287bf5d28
|
@@ -101,7 +101,7 @@ class IshManager::ApplicationController < ActionController::Base
|
|
101
101
|
@blank_template = Tmpl.new
|
102
102
|
|
103
103
|
@email_campaigns_list = [[nil,nil]] + Ish::EmailCampaign.all.map { |c| [ c.slug, c.id ] }
|
104
|
-
@email_actions_list =
|
104
|
+
@email_actions_list = EAct.list
|
105
105
|
@email_templates_list = [[nil,nil]] + Ish::EmailTemplate.all.map { |t| [ t.slug, t.id ] }
|
106
106
|
@email_tags_list = [[nil,nil]] + WpTag.email_tags.map { |t| [ t.name, t.id ] }
|
107
107
|
@leads_list = Lead.list
|
@@ -5,6 +5,14 @@ class ::IshManager::EmailActionsController < IshManager::ApplicationController
|
|
5
5
|
|
6
6
|
## Alphabetized : )
|
7
7
|
|
8
|
+
def destroy
|
9
|
+
@act = @email_action = Office::EmailAction.find( params[:id] )
|
10
|
+
authorize! :delete, @act
|
11
|
+
@act.update_attributes({ deleted_at: Time.now })
|
12
|
+
flash_notice 'Probably success'
|
13
|
+
redirect_to action: :index
|
14
|
+
end
|
15
|
+
|
8
16
|
def edit
|
9
17
|
@act = @email_action = Office::EmailAction.find( params[:id] )
|
10
18
|
@act.ties.push Office::EmailActionTie.new( next_email_action_id: nil )
|
@@ -12,7 +20,7 @@ class ::IshManager::EmailActionsController < IshManager::ApplicationController
|
|
12
20
|
end
|
13
21
|
|
14
22
|
def index
|
15
|
-
@email_actions = Office::EmailAction.
|
23
|
+
@email_actions = Office::EmailAction.where({ :deleted_at => nil })
|
16
24
|
|
17
25
|
authorize! :index, @new_email_action
|
18
26
|
end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
|
2
|
+
class ::IshManager::EmailAttachmentsController < IshManager::ApplicationController
|
3
|
+
|
4
|
+
def show
|
5
|
+
att = Office::EmailAttachment.find params[:id]
|
6
|
+
authorize! :show, att
|
7
|
+
send_data(
|
8
|
+
att.content,
|
9
|
+
filename: att.filename || "this_download",
|
10
|
+
type: att.content_type )
|
11
|
+
end
|
12
|
+
|
13
|
+
end
|
@@ -25,6 +25,14 @@ class ::IshManager::EmailConversationsController < IshManager::ApplicationContro
|
|
25
25
|
@email_conversations = @email_conversations.not_in_emailtag( params[:not_slug] )
|
26
26
|
end
|
27
27
|
|
28
|
+
if params[:subject].present?
|
29
|
+
@email_conversations = @email_conversations.where({ subject: /.*#{params[:subject]}.*/i })
|
30
|
+
end
|
31
|
+
|
32
|
+
if params[:from_email].present?
|
33
|
+
@email_conversations = @email_conversations.where({ from_emails: /.*#{params[:from_email]}.*/i })
|
34
|
+
end
|
35
|
+
|
28
36
|
@email_conversations = @email_conversations.order_by( latest_at: :desc
|
29
37
|
).includes( :email_messages # , :lead_ties
|
30
38
|
).page( params[:conv_page]
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
.header
|
5
5
|
%h2.title
|
6
|
-
Email Actions
|
6
|
+
Email Actions (#{@email_actions.length})
|
7
7
|
= link_to '[+]', new_email_action_path
|
8
8
|
|
9
9
|
%table.bordered
|
@@ -15,7 +15,11 @@
|
|
15
15
|
- @email_actions.each do |eact|
|
16
16
|
%tr
|
17
17
|
%td= check_box_tag 'abba'
|
18
|
-
%td
|
18
|
+
%td.flex-row
|
19
|
+
|
20
|
+
= link_to '[~]', edit_email_action_path( eact )
|
21
|
+
= button_to '[x]', email_action_path( eact ), data: { confirm: 'Are you sure?' }, method: :delete
|
22
|
+
|
19
23
|
%td
|
20
24
|
-# = link_to eact.slug, email_action_path( eact )
|
21
25
|
= eact.slug
|
@@ -22,7 +22,18 @@
|
|
22
22
|
%label New Tag:
|
23
23
|
= f.text_field :name
|
24
24
|
= f.submit '>'
|
25
|
-
|
25
|
+
.search.Card
|
26
|
+
.inline-block
|
27
|
+
= form_tag email_conversations_path do
|
28
|
+
%label Search from_email
|
29
|
+
= text_field_tag :from_email, params[:from_email]
|
30
|
+
-# = submit_tag '>'
|
31
|
+
-# .inline-block
|
32
|
+
-# = form_tag email_conversations_path do
|
33
|
+
%label by subject
|
34
|
+
= text_field_tag :subject, params[:subject]
|
35
|
+
= submit_tag '>'
|
36
|
+
.c
|
26
37
|
.actions
|
27
38
|
|
28
39
|
%a.btn.archive-btn{ href: "javascript: void(0)", data: { url: "/api/email_conversations/rmtag/#{WpTag::INBOX}" } }
|
@@ -20,9 +20,15 @@
|
|
20
20
|
.a <b>From:</b> #{lead.email}
|
21
21
|
.a <b>to's:</b> #{msg.tos&.join(", ")}
|
22
22
|
.a <b>cc's:</b> #{msg.ccs&.join(", ")}
|
23
|
+
|
23
24
|
.col-md-6
|
24
25
|
.a <b>msg.id:</b> #{msg.id}
|
25
26
|
.a <b>object_key:</b> #{msg.object_key}
|
27
|
+
.a
|
28
|
+
<b>N attachments:</b> #{msg.attachments.length}
|
29
|
+
<b>N email_attachments:</b>
|
30
|
+
- msg.email_attachments.each_with_index do |attachment, idx|
|
31
|
+
.a= link_to "Download #{attachment.filename} #{idx}", email_attachment_path( attachment )
|
26
32
|
|
27
33
|
|
28
34
|
.position-absolute.top-0.right-0.datetime
|
@@ -2,36 +2,39 @@
|
|
2
2
|
- url = email_filter.new_record? ? email_filters_path : email_filter_path( email_filter )
|
3
3
|
.email-filters--from
|
4
4
|
= form_for email_filter, url: url, as: :email_filter do |f|
|
5
|
-
.
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
5
|
+
.row.maxwidth
|
6
|
+
.col-md-6
|
7
|
+
.field
|
8
|
+
%label From Regex
|
9
|
+
= f.text_field :from_regex
|
10
|
+
.field
|
11
|
+
%label From Exact
|
12
|
+
= f.text_field :from_exact
|
13
|
+
.field
|
14
|
+
%label Subject Regex
|
15
|
+
= f.text_field :subject_regex
|
16
|
+
.field
|
17
|
+
%label Subject Exact
|
18
|
+
= f.text_field :subject_exact
|
19
|
+
-# .field
|
20
|
+
-# %label Body Regex
|
21
|
+
-# = f.text_field :body_regex
|
22
|
+
.field
|
23
|
+
%label Body Exact
|
24
|
+
= f.text_field :body_exact
|
25
|
+
.col-md-6
|
26
|
+
|
27
|
+
.field
|
28
|
+
%label Kind
|
29
|
+
= f.select :kind, options_for_select( ::Office::EmailFilter::KINDS, selected: email_filter.kind )
|
30
|
+
.field
|
31
|
+
%label Template
|
32
|
+
= f.select :email_template_id, options_for_select(@email_templates_list, selected: params[:email_template_id] || email_filter.email_template_id ), {}, { class: 'select2' }
|
33
|
+
.field
|
34
|
+
= f.label :email_action
|
35
|
+
= f.select :email_action, options_for_select( @email_actions_list, selected: email_filter.email_action_id ), {}, class: 'select2'
|
36
|
+
.field
|
37
|
+
= f.label :wp_term_id
|
38
|
+
= f.select :wp_term_id, options_for_select( @email_tags_list, selected: email_filter.wp_term_id ), {}, class: 'select2'
|
39
|
+
.actions
|
40
|
+
= f.submit
|
@@ -5,6 +5,13 @@
|
|
5
5
|
Email Filters (#{@email_filters.length})
|
6
6
|
= link_to '[+]', new_email_filter_path
|
7
7
|
|
8
|
+
|
9
|
+
.maxwidth
|
10
|
+
%hr
|
11
|
+
%h5.title.collapse-expand#newEmailFilter New Email Filter
|
12
|
+
= render 'form', email_filter: @email_filter
|
13
|
+
%hr
|
14
|
+
|
8
15
|
-# %input#dataTableSearch
|
9
16
|
%table.bordered.data-table
|
10
17
|
%thead
|
data/config/routes.rb
CHANGED
@@ -79,6 +79,8 @@ IshManager::Engine.routes.draw do
|
|
79
79
|
post :email_actions, to: 'email_actions#update'
|
80
80
|
resources :email_actions
|
81
81
|
|
82
|
+
get 'email_attachments/:id', to: 'email_attachments#show', as: :email_attachment
|
83
|
+
|
82
84
|
post 'email_campaigns/:id/send', to: 'email_campaigns#do_send', as: :send_email_campaign
|
83
85
|
resources :email_campaigns
|
84
86
|
|
@@ -91,10 +93,12 @@ IshManager::Engine.routes.draw do
|
|
91
93
|
get 'email_messages/stripped/:id', to: 'email_messages#show_stripped', as: :email_message_stripped
|
92
94
|
resources :email_messages
|
93
95
|
|
94
|
-
|
95
|
-
|
96
|
-
get
|
97
|
-
get
|
96
|
+
# post 'email_conversations/search', to: 'email_conversations#index', as: :search_email_convos
|
97
|
+
post 'email_conversations', to: 'email_conversations#index'
|
98
|
+
get 'email_conversations', to: 'email_conversations#index'
|
99
|
+
get 'email_conversations/in/:slug', to: 'email_conversations#index', as: :email_conversations_in
|
100
|
+
get 'email_conversations/notin/:not_slug', to: 'email_conversations#index', as: :email_conversations_notin
|
101
|
+
get 'email_conversations/show/:id', to: 'email_conversations#show', as: :email_conversation
|
98
102
|
|
99
103
|
get 'email_contexts/summary', to: 'email_contexts#summary', as: :email_contexts_summary
|
100
104
|
get 'email_contexts/for_lead/:lead_id', to: 'email_contexts#index', as: :email_contexts_for_lead
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ish_manager
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.8.
|
4
|
+
version: 0.1.8.506
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- piousbox
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-11-
|
11
|
+
date: 2023-11-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -489,6 +489,7 @@ files:
|
|
489
489
|
- app/controllers/ish_manager/application_mailer_controller.rb
|
490
490
|
- app/controllers/ish_manager/categories_controller.rb
|
491
491
|
- app/controllers/ish_manager/email_actions_controller.rb
|
492
|
+
- app/controllers/ish_manager/email_attachments_controller.rb
|
492
493
|
- app/controllers/ish_manager/email_campaign_leads_controller.rb
|
493
494
|
- app/controllers/ish_manager/email_campaigns_controller.rb
|
494
495
|
- app/controllers/ish_manager/email_contexts_controller.rb
|