ish_manager 0.1.8.474 → 0.1.8.476

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cbbc91cb570b304f736dd6e68707c5c7edfff70ad472c69abc16c3843da06ed8
4
- data.tar.gz: fa2e9004f24a7a65712a3cec0958a84cac0bd2897dc6ea0f2cc86373671447ba
3
+ metadata.gz: 25a1c311a0b599ca5647ea2f3125670e5f6d2a30961fd9bdc910cff357b2f898
4
+ data.tar.gz: 3e36fdeebf66357575f5f7dd03bf4423cb48efae59d01fae1b121e9f9f8b5023
5
5
  SHA512:
6
- metadata.gz: 556eeb65e43c306a5c38083d24dcc524e84cc29e0949f7dbf0f9c845181a58aafbc050887c98a53021b1000d686dfe796107a27119a7eea3e15dc082965aa66e
7
- data.tar.gz: cae31230ce606af64343b8dcb8401a1317da7b40dea460f345e492f5c3fb46286ce9def4a30c5ae2f1f225cd66941804783c982db65e19d38cd7283ef809dc1c
6
+ metadata.gz: 0d17b1fc1c52597aba2b6b1619528d037560c96ada41a32bf6a415fcf6ec18423a5a7ce645d1fd193c959fbad970b0fd1ce122eaa7e6508eed4dbfb28430df7d
7
+ data.tar.gz: 07ce5ba415150ee7183978f3816b433dd633cec7ab9b22248172a1833538742963f60229fcaff3303b87cbbbdb21476a6b2e525fad3b0a31a00dd85721a52f73
@@ -1,7 +1,7 @@
1
1
 
2
2
  class ::IshManager::EmailConversationsController < IshManager::ApplicationController
3
3
 
4
- before_action :set_lists
4
+ before_action :set_lists, except: [ :index ]
5
5
 
6
6
  def index
7
7
  authorize! :email_conversations_index, IshManager::Ability
@@ -23,6 +23,7 @@ class ::IshManager::EmailConversationsController < IshManager::ApplicationContro
23
23
  end
24
24
 
25
25
  @email_conversations = @email_conversations.order_by( latest_at: :desc
26
+ ).includes( :email_messages # , :lead_ties
26
27
  ).page( params[:conv_page]
27
28
  ).per( per_page )
28
29
  end
@@ -31,7 +32,7 @@ class ::IshManager::EmailConversationsController < IshManager::ApplicationContro
31
32
  def show
32
33
  authorize! :email_conversations_show, IshManager::Ability
33
34
  @email_conversation = ::Office::EmailConversation.find( params[:id] )
34
- @email_messages = @email_conversation.email_messages.order_by( date: :asc )
35
+ @email_messages = @email_conversation.email_messages.order_by( date: :asc )
35
36
  @email_conversation.update_attributes({ state: Conv::STATE_READ })
36
37
  end
37
38
 
@@ -132,11 +132,12 @@ class ::IshManager::LeadsController < IshManager::ApplicationController
132
132
  end
133
133
 
134
134
  def show
135
- @lead = Lead.find params[:id]
135
+ @lead = Lead.find params[:id]
136
136
  authorize! :show, @lead
137
- @schs = Sch.where( lead_id: @lead.id )
138
- @ctxs = Ctx.where( lead_id: @lead.id )
139
- @msgs = Msg.where( from: @lead.email )
137
+ @schs = Sch.where( lead_id: @lead.id )
138
+ @ctxs = Ctx.where( lead_id: @lead.id )
139
+ @convs = Conv.find( Office::EmailConversationLead.where( lead_id: @lead.id ).map( &:email_conversation_id ) )
140
+ @msgs = Msg.where( from: @lead.email )
140
141
  @galleries = @lead.galleries.page( params[:galleries_page] ).per( current_profile.per_page )
141
142
  @videos = @lead.videos.page( params[:videos_page] ).per( current_profile.per_page )
142
143
  end
@@ -12,7 +12,7 @@
12
12
  .a
13
13
  %ul
14
14
  %li
15
- = render 'ish_manager/galleries/menu', count: Gallery.all.count
15
+ = render 'ish_manager/galleries/menu', count: Gallery.all.length
16
16
  %li
17
17
  = link_to 'Reports', reports_path
18
18
  .inline-search
@@ -58,7 +58,7 @@
58
58
  = link_to "#{WpTag::INBOX} (#{Office::EmailConversation.in_emailtag(WpTag::INBOX).length})", email_conversations_in_path(WpTag::INBOX), class: 'chip'
59
59
  = link_to '[+]', new_email_context_path
60
60
  %li
61
- = link_to "Tmpls (#{Ish::EmailTemplate.all.count})", email_templates_path
61
+ = link_to "Tmpls (#{Ish::EmailTemplate.all.length})", email_templates_path
62
62
  = link_to '[+]', new_email_template_path
63
63
  %li
64
64
  = link_to "Companies (#{Leadset.kept.length})", leadsets_path
@@ -67,7 +67,7 @@
67
67
  = text_field_tag :q
68
68
  = link_to '[+]', new_leadset_path
69
69
  %li
70
- = link_to "EActions (#{Office::EmailAction.count})", email_actions_path
70
+ = link_to "EActions (#{Office::EmailAction.all.length})", email_actions_path
71
71
  = link_to '[+]', new_email_action_path
72
72
  %ul
73
73
  %li
@@ -97,10 +97,10 @@
97
97
  = link_to 'Lead Action Templatess', lead_action_templates_path
98
98
  -# = link_to '[+]', new_lead_action_template_path
99
99
  %li
100
- = link_to "Campaigns (#{Ish::EmailCampaign.count})", email_campaigns_path
100
+ = link_to "Campaigns (#{Ish::EmailCampaign.all.length})", email_campaigns_path
101
101
  = link_to '[+]', new_email_campaign_path
102
102
  %li
103
- = link_to "OActions (#{Office::Action.count})", office_actions_path
103
+ = link_to "OActions (#{Office::Action.all.length})", office_actions_path
104
104
  = link_to '[+]', new_office_action_path
105
105
 
106
106
  %ul
@@ -34,14 +34,14 @@
34
34
  %br
35
35
  = render 'paginate', resource: @email_conversations, param_name: :conv_page, views_prefix: :ish_manager
36
36
 
37
- %table.conversations
37
+ %table.conversations.bordered
38
38
  %tr
39
39
  %th
40
40
  .chip.select-all
41
41
  = check_box_tag :select_all
42
42
  .n-selected -
43
43
  %th Msgs
44
- %th Leads
44
+ %th From emails
45
45
  %th Subject
46
46
  %th Datetime
47
47
  %th Tags
@@ -51,10 +51,11 @@
51
51
  .item
52
52
  %td= check_box_tag 'email_conversation_ids[]', conv.id.to_s, nil, { class: 'i-sel' }
53
53
  %td.count
54
- (#{conv.email_messages.count})
54
+ (#{conv.email_messages.length})
55
55
 
56
56
  %td.leads
57
- = conv.leads.map { |lead| lead.email }.join(", ")
57
+ -# &lt;leads>
58
+ = conv.from_emails.join(", ")
58
59
 
59
60
  %td.subject
60
61
  = link_to conv.subject, email_conversation_path( conv )
@@ -65,9 +66,10 @@
65
66
 
66
67
  %td
67
68
  .tags
68
- - conv.tags.each do |tag|
69
- .chip
70
- = tag.name
69
+ &lt;tags>
70
+ -# - conv.tags.each do |tag|
71
+ -# .chip
72
+ -# = tag.name
71
73
 
72
74
  %br
73
75
  = render 'paginate', resource: @email_conversations, param_name: :conv_page, views_prefix: :ish_manager
@@ -71,13 +71,11 @@
71
71
 
72
72
  .row
73
73
  .col-md-12.msgs
74
- %h5 Email Messages (#{@msgs.length})
75
- .descr @TODO: these used to be links, but now they are broken. _vp_ 2023-08-10
74
+ %h5 Email Conversations (#{@convs.length})
76
75
  %ul
77
- - @msgs.each do |msg|
76
+ - @convs.each do |conv|
78
77
  %li
79
- = msg.subject
80
- -# = link_to msg.subject, email_conversation_path( msg.conv )
78
+ = link_to conv.subject, email_conversation_path( conv )
81
79
 
82
80
  .row
83
81
  .col-md-6
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.474
4
+ version: 0.1.8.476
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-09-23 00:00:00.000000000 Z
11
+ date: 2023-09-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails