rails_crm 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (123) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +20 -0
  3. data/README.md +33 -0
  4. data/Rakefile +32 -0
  5. data/app/controllers/crm/admin/base_controller.rb +20 -0
  6. data/app/controllers/crm/admin/maintain_logs_controller.rb +65 -0
  7. data/app/controllers/crm/admin/maintain_source_templates_controller.rb +52 -0
  8. data/app/controllers/crm/admin/maintain_sources_controller.rb +62 -0
  9. data/app/controllers/crm/admin/maintain_tag_templates_controller.rb +56 -0
  10. data/app/controllers/crm/admin/maintain_tags_controller.rb +66 -0
  11. data/app/controllers/crm/admin/maintains_controller.rb +289 -0
  12. data/app/controllers/crm/my/base_controller.rb +4 -0
  13. data/app/models/crm/application_record.rb +5 -0
  14. data/app/models/crm/maintain.rb +6 -0
  15. data/app/models/crm/maintain_log.rb +5 -0
  16. data/app/models/crm/maintain_source.rb +5 -0
  17. data/app/models/crm/maintain_source_template.rb +5 -0
  18. data/app/models/crm/maintain_tag.rb +5 -0
  19. data/app/models/crm/maintain_tag_template.rb +5 -0
  20. data/app/models/crm/model/agency.rb +18 -0
  21. data/app/models/crm/model/maintain.rb +91 -0
  22. data/app/models/crm/model/maintain_log.rb +18 -0
  23. data/app/models/crm/model/maintain_source.rb +19 -0
  24. data/app/models/crm/model/maintain_source_template.rb +12 -0
  25. data/app/models/crm/model/maintain_tag.rb +44 -0
  26. data/app/models/crm/model/maintain_tag_template.rb +17 -0
  27. data/app/models/crm/model/member.rb +11 -0
  28. data/app/models/crm/model/order.rb +10 -0
  29. data/app/models/crm/model/organ.rb +15 -0
  30. data/app/models/crm.rb +11 -0
  31. data/app/views/admin/_crm_nav.html.erb +13 -0
  32. data/app/views/crm/admin/maintain_logs/_breadcrumb.html.erb +6 -0
  33. data/app/views/crm/admin/maintain_logs/_filter_form.html.erb +8 -0
  34. data/app/views/crm/admin/maintain_logs/_form.html.erb +6 -0
  35. data/app/views/crm/admin/maintain_logs/_index_tbody.html.erb +8 -0
  36. data/app/views/crm/admin/maintain_logs/_index_thead.html.erb +14 -0
  37. data/app/views/crm/admin/maintain_logs/_maintain_log.json.jbuilder +11 -0
  38. data/app/views/crm/admin/maintain_logs/_show.json.jbuilder +1 -0
  39. data/app/views/crm/admin/maintain_logs/_show_table.html.erb +16 -0
  40. data/app/views/crm/admin/maintain_logs/index.json.jbuilder +2 -0
  41. data/app/views/crm/admin/maintain_source_templates/_edit_form.html.erb +4 -0
  42. data/app/views/crm/admin/maintain_source_templates/_filter_form.html.erb +8 -0
  43. data/app/views/crm/admin/maintain_source_templates/_form.html.erb +2 -0
  44. data/app/views/crm/admin/maintain_source_templates/_index_tbody.html.erb +14 -0
  45. data/app/views/crm/admin/maintain_source_templates/_index_thead.html.erb +2 -0
  46. data/app/views/crm/admin/maintain_source_templates/_maintain_source.json.jbuilder +7 -0
  47. data/app/views/crm/admin/maintain_source_templates/_new_form.html.erb +4 -0
  48. data/app/views/crm/admin/maintain_source_templates/_show.json.jbuilder +1 -0
  49. data/app/views/crm/admin/maintain_source_templates/_show_table.html.erb +8 -0
  50. data/app/views/crm/admin/maintain_source_templates/index.json.jbuilder +1 -0
  51. data/app/views/crm/admin/maintain_sources/_breadcrumb.html.erb +6 -0
  52. data/app/views/crm/admin/maintain_sources/_edit_form.html.erb +4 -0
  53. data/app/views/crm/admin/maintain_sources/_filter_form.html.erb +9 -0
  54. data/app/views/crm/admin/maintain_sources/_form.html.erb +2 -0
  55. data/app/views/crm/admin/maintain_sources/_index_tbody.html.erb +12 -0
  56. data/app/views/crm/admin/maintain_sources/_index_thead.html.erb +3 -0
  57. data/app/views/crm/admin/maintain_sources/_maintain_source.json.jbuilder +6 -0
  58. data/app/views/crm/admin/maintain_sources/_new_form.html.erb +4 -0
  59. data/app/views/crm/admin/maintain_sources/_show.json.jbuilder +1 -0
  60. data/app/views/crm/admin/maintain_sources/_show_table.html.erb +8 -0
  61. data/app/views/crm/admin/maintain_sources/index.json.jbuilder +1 -0
  62. data/app/views/crm/admin/maintain_sources/templates.html.erb +18 -0
  63. data/app/views/crm/admin/maintain_tag_templates/_edit_form.html.erb +4 -0
  64. data/app/views/crm/admin/maintain_tag_templates/_filter_form.html.erb +8 -0
  65. data/app/views/crm/admin/maintain_tag_templates/_form.html.erb +7 -0
  66. data/app/views/crm/admin/maintain_tag_templates/_index_tbody.html.erb +8 -0
  67. data/app/views/crm/admin/maintain_tag_templates/_index_thead.html.erb +7 -0
  68. data/app/views/crm/admin/maintain_tag_templates/_maintain_tag_template.json.jbuilder +11 -0
  69. data/app/views/crm/admin/maintain_tag_templates/_new_form.html.erb +4 -0
  70. data/app/views/crm/admin/maintain_tag_templates/_show.json.jbuilder +1 -0
  71. data/app/views/crm/admin/maintain_tag_templates/_show_table.html.erb +20 -0
  72. data/app/views/crm/admin/maintain_tag_templates/index.json.jbuilder +1 -0
  73. data/app/views/crm/admin/maintain_tags/_breadcrumb.html.erb +6 -0
  74. data/app/views/crm/admin/maintain_tags/_edit_form.html.erb +4 -0
  75. data/app/views/crm/admin/maintain_tags/_filter_form.html.erb +9 -0
  76. data/app/views/crm/admin/maintain_tags/_form.html.erb +5 -0
  77. data/app/views/crm/admin/maintain_tags/_index_tbody.html.erb +7 -0
  78. data/app/views/crm/admin/maintain_tags/_index_thead.html.erb +6 -0
  79. data/app/views/crm/admin/maintain_tags/_maintain_tag.json.jbuilder +9 -0
  80. data/app/views/crm/admin/maintain_tags/_new_form.html.erb +4 -0
  81. data/app/views/crm/admin/maintain_tags/_show.json.jbuilder +1 -0
  82. data/app/views/crm/admin/maintain_tags/_show_table.html.erb +24 -0
  83. data/app/views/crm/admin/maintain_tags/index.json.jbuilder +1 -0
  84. data/app/views/crm/admin/maintain_tags/templates.html.erb +22 -0
  85. data/app/views/crm/admin/maintains/_button.html.erb +3 -0
  86. data/app/views/crm/admin/maintains/_create_detect.html.erb +23 -0
  87. data/app/views/crm/admin/maintains/_edit_assign.html.erb +21 -0
  88. data/app/views/crm/admin/maintains/_edit_form.html.erb +4 -0
  89. data/app/views/crm/admin/maintains/_edit_order.html.erb +5 -0
  90. data/app/views/crm/admin/maintains/_edit_transfer.html.erb +19 -0
  91. data/app/views/crm/admin/maintains/_filter_form.html.erb +12 -0
  92. data/app/views/crm/admin/maintains/_filter_table.html.erb +54 -0
  93. data/app/views/crm/admin/maintains/_form.html.erb +37 -0
  94. data/app/views/crm/admin/maintains/_index_thead.html.erb +40 -0
  95. data/app/views/crm/admin/maintains/_index_tr.html.erb +36 -0
  96. data/app/views/crm/admin/maintains/_maintain.json.jbuilder +24 -0
  97. data/app/views/crm/admin/maintains/_new_batch_assign.html.erb +13 -0
  98. data/app/views/crm/admin/maintains/_new_detect.html.erb +15 -0
  99. data/app/views/crm/admin/maintains/_new_form.html.erb +4 -0
  100. data/app/views/crm/admin/maintains/_show.json.jbuilder +1 -0
  101. data/app/views/crm/admin/maintains/_show_table.html.erb +54 -0
  102. data/app/views/crm/admin/maintains/create_detect.js.erb +3 -0
  103. data/app/views/crm/admin/maintains/edit_assign.js +8 -0
  104. data/app/views/crm/admin/maintains/edit_assign.js.erb +3 -0
  105. data/app/views/crm/admin/maintains/edit_order.js.erb +12 -0
  106. data/app/views/crm/admin/maintains/edit_transfer.js +8 -0
  107. data/app/views/crm/admin/maintains/edit_transfer.js.erb +3 -0
  108. data/app/views/crm/admin/maintains/index.html.erb +26 -0
  109. data/app/views/crm/admin/maintains/index.json.jbuilder +2 -0
  110. data/app/views/crm/admin/maintains/new.json.jbuilder +5 -0
  111. data/app/views/crm/admin/maintains/new_batch_assign.js.erb +3 -0
  112. data/app/views/crm/admin/maintains/new_detect.js.erb +1 -0
  113. data/app/views/crm/admin/maintains/orders.html.erb +54 -0
  114. data/app/views/crm/admin/maintains/public.html.erb +83 -0
  115. data/app/views/crm/admin/maintains/public.json.jbuilder +2 -0
  116. data/config/locales/zh.attributes.yml +33 -0
  117. data/config/locales/zh.controller.yml +35 -0
  118. data/config/locales/zh.enum.yml +10 -0
  119. data/config/routes.rb +41 -0
  120. data/lib/rails_crm/config.rb +9 -0
  121. data/lib/rails_crm/engine.rb +16 -0
  122. data/lib/rails_crm.rb +2 -0
  123. metadata +178 -0
@@ -0,0 +1,4 @@
1
+ module Crm
2
+ class My::BaseController < MyController
3
+ end
4
+ end
@@ -0,0 +1,5 @@
1
+ module Crm
2
+ class ApplicationRecord < ApplicationRecord
3
+ self.abstract_class = true
4
+ end
5
+ end
@@ -0,0 +1,6 @@
1
+ module Crm
2
+ class Maintain < ApplicationRecord
3
+ include Model::Maintain
4
+ include Eventual::Model::Planned if defined? RailsEvent
5
+ end
6
+ end
@@ -0,0 +1,5 @@
1
+ module Crm
2
+ class MaintainLog < ApplicationRecord
3
+ include Model::MaintainLog
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ module Crm
2
+ class MaintainSource < ApplicationRecord
3
+ include Model::MaintainSource
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ module Crm
2
+ class MaintainSourceTemplate < ApplicationRecord
3
+ include Model::MaintainSourceTemplate
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ module Crm
2
+ class MaintainTag < ApplicationRecord
3
+ include Model::MaintainTag
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ module Crm
2
+ class MaintainTagTemplate < ApplicationRecord
3
+ include Model::MaintainTagTemplate
4
+ end
5
+ end
@@ -0,0 +1,18 @@
1
+ module Crm
2
+ module Model::Agency
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ has_one :maintain, inverse_of: :agency
7
+ has_many :maintains
8
+
9
+ before_validation :sync_from_maintain, if: -> { self.maintain.present? }
10
+ end
11
+
12
+ def sync_from_maintain
13
+ self.agent = maintain.agent
14
+ self.client = maintain.client
15
+ end
16
+
17
+ end
18
+ end
@@ -0,0 +1,91 @@
1
+ module Crm
2
+ module Model::Maintain
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ attribute :note, :string
7
+ attribute :position, :integer
8
+
9
+ belongs_to :organ, optional: true
10
+ belongs_to :member, inverse_of: :maintains, optional: true
11
+ belongs_to :maintain_source, optional: true
12
+ belongs_to :task_template, optional: true
13
+ belongs_to :agency, optional: true, inverse_of: :maintain
14
+ belongs_to :client, class_name: 'Profile', inverse_of: :client_maintains
15
+ belongs_to :agent, class_name: 'User', inverse_of: :agent_maintains, optional: true
16
+ belongs_to :upstream, class_name: self.name
17
+ belongs_to :source, class_name: self.name
18
+
19
+ has_many :maintain_logs, dependent: :delete_all
20
+ has_many :maintain_tags, -> { distinct }, through: :maintain_logs
21
+ has_many :orders, dependent: :nullify
22
+
23
+ accepts_nested_attributes_for :agency, reject_if: :all_blank
24
+ accepts_nested_attributes_for :agent, reject_if: :all_blank
25
+ accepts_nested_attributes_for :client, reject_if: :all_blank
26
+
27
+ enum state: {
28
+ init: 'init',
29
+ transferred: 'transferred'
30
+ }, _default: 'init'
31
+
32
+ before_validation do
33
+ self.upstream ||= self
34
+ self.source ||= self
35
+ self.position = self.pipeline_member&.position
36
+ end
37
+ before_save :sync_pipeline_member, if: -> { pipeline_id_changed? }
38
+ end
39
+
40
+ def sync_pipeline_member
41
+ self.pipeline_member ||= self.pipeline.pipeline_members.first if self.pipeline
42
+ end
43
+
44
+ def tags
45
+ ids = maintain_logs.pluck(:maintain_tag_id).uniq
46
+ MaintainTag.cached.slice(*ids).values
47
+ end
48
+
49
+ def transfer!
50
+ self.state = 'transferred'
51
+
52
+ next_member = pipeline_member&.next_member
53
+ if next_member
54
+ m = Maintain.new
55
+ m.upstream = self
56
+ m.source = self.source
57
+ m.pipeline_member = next_member
58
+ m.assign_attributes self.attributes.slice('organ_id', 'client_type', 'client_id', 'agent_type', 'agent_id', 'agency_id', 'maintain_source_id', 'pipeline_id')
59
+
60
+ self.class.transaction do
61
+ self.save!
62
+ m.save!
63
+ end
64
+ m
65
+ else
66
+ self.save
67
+ end
68
+ end
69
+
70
+ def confirm_booker_time!(booked)
71
+ ml = self.maintain_logs.build
72
+ ml.member = self.member
73
+ ml.note = "已预约成功"
74
+ ml.logged = booked
75
+ mt = option_maintain_tags.find_by(logged_type: booked.class.name)
76
+ if mt
77
+ ml.maintain_tag = mt
78
+ end
79
+ ml.extra = {
80
+ booked_type: booked.booked_type,
81
+ booked_id: booked.booked_id
82
+ }
83
+ ml.save
84
+ end
85
+
86
+ def option_maintain_tags
87
+ MaintainTag.where(organ_id: self.organ_id)
88
+ end
89
+
90
+ end
91
+ end
@@ -0,0 +1,18 @@
1
+ module Crm
2
+ module Model::MaintainLog
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ attribute :note, :string
7
+ attribute :tag_str, :string
8
+ attribute :tag_sequence, :integer
9
+ attribute :extra, :json
10
+
11
+ belongs_to :maintain
12
+ belongs_to :member
13
+ belongs_to :logged, polymorphic: true, optional: true
14
+ belongs_to :maintain_tag, counter_cache: true, optional: true
15
+ end
16
+
17
+ end
18
+ end
@@ -0,0 +1,19 @@
1
+ module Crm
2
+ module Model::MaintainSource
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ attribute :name, :string
7
+ attribute :maintains_count, :integer, default: 0
8
+ belongs_to :organ, optional: true
9
+ belongs_to :maintain_source_template, optional: true
10
+
11
+ validates :name, presence: true
12
+
13
+ before_validation do
14
+ self.name = maintain_source_template.name if maintain_source_template
15
+ end
16
+ end
17
+
18
+ end
19
+ end
@@ -0,0 +1,12 @@
1
+ module Crm
2
+ module Model::MaintainSourceTemplate
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ attribute :name, :string
7
+
8
+ has_many :maintain_sources
9
+ end
10
+
11
+ end
12
+ end
@@ -0,0 +1,44 @@
1
+ module Crm
2
+ module Model::MaintainTag
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ attribute :name, :string
7
+ attribute :logged_type, :string # TimeBooking/Order
8
+ attribute :entity_column, :string # entity_type
9
+ attribute :entity_value, :string # lesson
10
+ attribute :sequence, :integer, default: 1
11
+ attribute :manual, :boolean, default: true
12
+ attribute :color, :string, default: '#2A92CA'
13
+ attribute :maintain_logs_count, :integer, default: 0
14
+
15
+ belongs_to :organ, optional: true
16
+ belongs_to :maintain_tag_template, optional: true
17
+
18
+ validates :logged_type, uniqueness: { scope: [:organ_id, :sequence] }, allow_blank: true
19
+ validates :name, presence: true
20
+
21
+ before_validation do
22
+ if maintain_tag_template
23
+ self.name = maintain_tag_template.name
24
+ self.color = maintain_tag_template.color
25
+ self.manual = false
26
+ end
27
+ end
28
+ after_update_commit :delete_default_cache
29
+ end
30
+
31
+ def delete_default_cache
32
+ Rails.cache.delete('maintain_tag')
33
+ end
34
+
35
+ class_methods do
36
+ def cached
37
+ Rails.cache.fetch('maintain_tag') do
38
+ MaintainTag.pluck(:id, :name).to_h
39
+ end
40
+ end
41
+ end
42
+
43
+ end
44
+ end
@@ -0,0 +1,17 @@
1
+ module Crm
2
+ module Model::MaintainTagTemplate
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ attribute :name, :string
7
+ attribute :logged_type, :string
8
+ attribute :entity_column, :string
9
+ attribute :entity_value, :string
10
+ attribute :color, :string
11
+ attribute :sequence, :integer, default: 1
12
+
13
+ has_many :maintain_tags
14
+ end
15
+
16
+ end
17
+ end
@@ -0,0 +1,11 @@
1
+ module Crm
2
+ module Model::Member
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ has_many :maintains
7
+ has_many :pupils, through: :maintains
8
+ end
9
+
10
+ end
11
+ end
@@ -0,0 +1,10 @@
1
+ module Crm
2
+ module Model::Order
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ belongs_to :maintain, optional: true
7
+ end
8
+
9
+ end
10
+ end
@@ -0,0 +1,15 @@
1
+ module Crm
2
+ module Model::Organ
3
+ extend ActiveSupport::Concern
4
+
5
+ included do
6
+ has_many :maintains, dependent: :nullify
7
+ has_many :pupils, through: :maintains
8
+ end
9
+
10
+ def maintains_count
11
+ maintains.select(:source_id).distinct.count
12
+ end
13
+
14
+ end
15
+ end
data/app/models/crm.rb ADDED
@@ -0,0 +1,11 @@
1
+ module Crm
2
+
3
+ def self.use_relative_model_naming?
4
+ true
5
+ end
6
+
7
+ def self.table_name_prefix
8
+ 'crm_'
9
+ end
10
+
11
+ end
@@ -0,0 +1,13 @@
1
+ <div class="<%= active_helper(modules: 'crm/admin', active: 'menu ex-accordion is-active', item: 'menu ex-accordion') %>" data-controller="menu">
2
+ <%= content_tag :div, class: 'menu-list' do %>
3
+ <%= link_to t('crm.admin.maintains.index.title'), { controller: 'crm/admin/maintains' }, class: active_helper(controllers: ['maintain_logs'], 'maintains': ['index', 'show'], active: 'is-active') %>
4
+ <%= link_to t('crm.admin.maintains.public.title'), { controller: 'crm/admin/maintains', action: 'public' }, class: active_helper('maintains': 'public', active: 'is-active') %>
5
+ <%= link_to t('crm.admin.maintain_source_templates.index.title'), { controller: 'crm/admin/maintain_source_templates' }, class: active_helper(controllers: 'maintain_source_templates', active: 'is-active') %>
6
+ <%= link_to t('crm.admin.maintain_tag_templates.index.title'), { controller: 'crm/admin/maintain_tag_templates' }, class: active_helper(controllers: 'maintain_tag_templates', active: 'is-active') -%>
7
+ <% end %>
8
+ <a class="menu-label" data-action="menu#toggle">
9
+ <i class="fas fa-chart-line fa-fw"></i>
10
+ <span><%= t('crm.admin.title') %></span>
11
+ <i class="fas dropdown"></i>
12
+ </a>
13
+ </div>
@@ -0,0 +1,6 @@
1
+ <div class="breadcrumb has-succeeds-separator">
2
+ <ul>
3
+ <li><%= link_to t('crm.admin.maintains.index.title'), { controller: 'maintains' } %></li>
4
+ <li class="is-active"><%= t('crm.admin.maintain_logs.index.title') %></li>
5
+ </ul>
6
+ </div>
@@ -0,0 +1,8 @@
1
+ <%= form_with theme: 'search', model: MaintainLog.new(params.permit(:name)) do |f| %>
2
+ <div class="field-body">
3
+ <%= f.text_field :name %>
4
+ <div class="field is-narrow">
5
+ <%= f.submit %>
6
+ </div>
7
+ </div>
8
+ <% end %>
@@ -0,0 +1,6 @@
1
+ <%= form_with model: [:admin, @maintain, @maintain_log] do |f| %>
2
+ <%= render 'shared/error_messages', target: @maintain_log %>
3
+ <%= f.collection_select :maintain_tag_id, @maintain_tags, :id, :name %>
4
+ <%= f.text_area :note %>
5
+ <%= f.submit %>
6
+ <% end %>
@@ -0,0 +1,8 @@
1
+ <td><%= model.maintain_tag&.name %></td>
2
+ <td><%= model.note %></td>
3
+ <td>
4
+ <p><%= model.logged_type %></p>
5
+ <p><%= model.logged_id %></p>
6
+ </td>
7
+ <td><%= simple_format model.extra %></td>
8
+ <td><time data-controller="time"><%= model.created_at.to_s(:rfc822) %></time></td>
@@ -0,0 +1,14 @@
1
+ <th>
2
+ <%= MaintainLog.human_attribute_name(:maintain_tag_id) %>
3
+ <%= link_to({ controller: 'maintain_tags' }, aria: { label: '标签设置' }, target: '_blank') do %>
4
+ <i class="fas fa-cog"></i>
5
+ <% end %>
6
+ </th>
7
+ <th><%= MaintainLog.human_attribute_name(:note) %></th>
8
+ <th>
9
+ <p><%= MaintainLog.human_attribute_name(:logged_type) %></p>
10
+ <p><%= MaintainLog.human_attribute_name(:logged_id) %></p>
11
+ </th>
12
+ <th><%= MaintainLog.human_attribute_name(:extra) %></th>
13
+ <th><%= MaintainLog.human_attribute_name(:created_at) %></th>
14
+ <th></th>
@@ -0,0 +1,11 @@
1
+ json.extract!(
2
+ maintain_log,
3
+ :id,
4
+ :note,
5
+ :logged_type,
6
+ :logged_id,
7
+ :created_at
8
+ )
9
+ if maintain_log.maintain_tag
10
+ json.maintain_tag maintain_log.maintain_tag, :id, :name, :color
11
+ end
@@ -0,0 +1 @@
1
+ json.maintain_log @maintain_log, partial: 'maintain_log', as: :maintain_log
@@ -0,0 +1,16 @@
1
+ <tr>
2
+ <td class="has-text-right"><%= MaintainLog.human_attribute_name(:note) %></td>
3
+ <td><%= @maintain_log.note %></td>
4
+ </tr>
5
+ <tr>
6
+ <td class="has-text-right"><%= MaintainLog.human_attribute_name(:logged_type) %></td>
7
+ <td><%= @maintain_log.logged_type %></td>
8
+ </tr>
9
+ <tr>
10
+ <td class="has-text-right"><%= MaintainLog.human_attribute_name(:logged_id) %></td>
11
+ <td><%= @maintain_log.logged_id %></td>
12
+ </tr>
13
+ <tr>
14
+ <td class="has-text-right"><%= MaintainLog.human_attribute_name(:created_at) %></td>
15
+ <td><%= @maintain_log.created_at %></td>
16
+ </tr>