phcdevworks_core_modules 2.0.1 → 6.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/phcdevworks_core_modules/marketing/optimizations_controller.rb +2 -2
- data/app/controllers/phcdevworks_core_modules/post/categories_controller.rb +2 -2
- data/app/models/phcdevworks_core_modules/marketing/optimization.rb +35 -14
- data/app/models/phcdevworks_core_modules/marketing_optimization_versions.rb +5 -0
- data/app/models/phcdevworks_core_modules/post/category.rb +26 -19
- data/app/models/phcdevworks_core_modules/post_category_versions.rb +5 -0
- data/app/views/layouts/phcdevworks_core_modules/components/backend/sidebars/_side_menu.html.erb +54 -32
- data/app/views/phcdevworks_core_modules/marketing/optimizations/_form.html.erb +37 -35
- data/app/views/phcdevworks_core_modules/marketing/optimizations/index.html.erb +5 -5
- data/app/views/phcdevworks_core_modules/marketing/optimizations/show.html.erb +23 -18
- data/app/views/phcdevworks_core_modules/post/categories/_form.html.erb +7 -2
- data/app/views/phcdevworks_core_modules/post/categories/index.html.erb +1 -1
- data/app/views/phcdevworks_core_modules/post/categories/show.html.erb +1 -1
- data/db/migrate/{20200705225433_create_phcdevworks_core_modules_optimization_versions.rb → 20170517064427_create_phcdevworks_core_modules_post_category_versions.rb} +18 -17
- data/db/migrate/20200705223718_create_phcdevworks_core_modules_marketing_optimizations.rb +11 -10
- data/db/migrate/20200705225433_create_phcdevworks_core_modules_marketing_optimization_versions.rb +18 -0
- data/db/migrate/20200706094820_create_phcdevworks_core_modules_post_categories.rb +3 -1
- data/lib/phcdevworks_core_modules.rb +1 -1
- data/lib/phcdevworks_core_modules/engine.rb +2 -2
- data/lib/phcdevworks_core_modules/version.rb +1 -1
- metadata +23 -24
- data/app/models/phcdevworks_core_modules/core_category_versions.rb +0 -5
- data/app/models/phcdevworks_core_modules/core_optimization_versions.rb +0 -5
- data/db/migrate/20170517064427_create_phcdevworks_core_modules_category_versions.rb +0 -17
- data/db/migrate/20200706091346_create_phcdevworks_core_modules_categories_optimizations.rb +0 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2f5cd35a068f12357a9e4457f175ab363f0c50542875b8a12b27f7a51cc9fe08
|
4
|
+
data.tar.gz: e7ee1dcd4e213670c07cd9a05e216efd07cfa7b5f526691d0ef85243d4f68739
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 62ece7922d5cdff4c0eec443d91baf6d7e1de1ae9ac56045790de6dd8e28cf4dc8c2672b8c34afbb68ebe30e20cf2f0ffca1b4e087bd0d41f6a19ad3f57b995a
|
7
|
+
data.tar.gz: d5de11b220fb81caf206a08ba90b3fff75820b4894dab27a8a6dc69a29292bf74181325d98c279ed81342d72b73033165d8899c1f8f84349b40aa8ffe81a0e7e
|
@@ -11,7 +11,7 @@ module PhcdevworksCoreModules
|
|
11
11
|
|
12
12
|
# GET /marketing/optimizations
|
13
13
|
def index
|
14
|
-
@marketing_optimizations = Marketing::Optimization.order('
|
14
|
+
@marketing_optimizations = Marketing::Optimization.order('marketing_optimization_page_title ASC')
|
15
15
|
end
|
16
16
|
|
17
17
|
# GET /marketing/optimizations/1
|
@@ -74,7 +74,7 @@ module PhcdevworksCoreModules
|
|
74
74
|
|
75
75
|
# Whitelist
|
76
76
|
def marketing_optimization_params
|
77
|
-
params.require(:marketing_optimization).permit(:
|
77
|
+
params.require(:marketing_optimization).permit(:marketing_optimization_page_title, :marketing_optimization_page_description, :marketing_optimization_og_title, :marketing_optimization_og_description, :marketing_optimization_og_type, :marketing_optimization_og_url, :marketing_optimization_twitter_title, :marketing_optimization_twitter_description, :marketing_optimization_twitter_type, :marketing_optimization_twitter_url, :marketing_optimization_twitter_image, :marketing_optimization_og_image, :slug, :user_id, :org_id)
|
78
78
|
end
|
79
79
|
|
80
80
|
end
|
@@ -11,7 +11,7 @@ module PhcdevworksCoreModules
|
|
11
11
|
|
12
12
|
# GET /post/categories
|
13
13
|
def index
|
14
|
-
@post_categories = Post::Category.order('
|
14
|
+
@post_categories = Post::Category.order('post_category_name ASC')
|
15
15
|
end
|
16
16
|
|
17
17
|
# GET /post/categories/1
|
@@ -74,7 +74,7 @@ module PhcdevworksCoreModules
|
|
74
74
|
|
75
75
|
# Whitelist
|
76
76
|
def post_category_params
|
77
|
-
params.require(:post_category).permit(:
|
77
|
+
params.require(:post_category).permit(:post_category_name, :slug, :optimization_id, :user_id, :org_id)
|
78
78
|
end
|
79
79
|
|
80
80
|
end
|
@@ -5,34 +5,55 @@ module PhcdevworksCoreModules
|
|
5
5
|
extend FriendlyId
|
6
6
|
|
7
7
|
# Image Upload
|
8
|
-
has_one_attached :
|
9
|
-
has_one_attached :
|
8
|
+
has_one_attached :marketing_optimization_twitter_image
|
9
|
+
has_one_attached :marketing_optimization_og_image
|
10
10
|
|
11
11
|
# Paper Trail Initialize
|
12
|
-
has_paper_trail :class_name => "PhcdevworksCoreModules::
|
12
|
+
has_paper_trail :class_name => "PhcdevworksCoreModules::MarketingOptimizationVersions"
|
13
13
|
|
14
|
-
# Relationships
|
14
|
+
# Relationships for Local
|
15
15
|
belongs_to :user, class_name: "PhcdevworksAccounts::User"
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
16
|
+
has_many :categories, class_name: "PhcdevworksCoreModules::Post::Category"
|
17
|
+
|
18
|
+
# Relationships for PHCDevworks Plugins
|
19
|
+
if defined?phcdevworks_members
|
20
|
+
has_many :listings, class_name: "PhcdevworksMembers::Member::Listing"
|
21
|
+
end
|
22
|
+
|
23
|
+
if defined?phcdevworks_scripts
|
24
|
+
has_many :listings, class_name: "PhcdevworksScripts::Script::Listing"
|
25
|
+
end
|
26
|
+
|
27
|
+
if defined?phcdevworks_press
|
28
|
+
has_many :posts, class_name: "PhcdevworksPress::Article::Post"
|
29
|
+
has_many :posts, class_name: "PhcdevworksPress::Review::Post"
|
30
|
+
has_many :posts, class_name: "PhcdevworksPress::List::Post"
|
31
|
+
end
|
32
|
+
|
33
|
+
if defined?phcdevworks_portfolio
|
34
|
+
has_many :posts, class_name: "PhcdevworksPortfolio::Project::Post"
|
35
|
+
end
|
36
|
+
|
37
|
+
if defined?phcdevworks_tutorials
|
38
|
+
has_many :posts, class_name: "PhcdevworksTutorials::Tutorial::Post"
|
39
|
+
has_many :posts, class_name: "PhcdevworksTutorials::Command::Post"
|
40
|
+
end
|
20
41
|
|
21
42
|
# Form Fields Validation
|
22
|
-
validates :
|
43
|
+
validates :marketing_optimization_page_title,
|
23
44
|
presence: true
|
24
45
|
|
25
|
-
validates :
|
46
|
+
validates :marketing_optimization_og_title,
|
26
47
|
presence: true
|
27
48
|
|
28
|
-
validates :
|
49
|
+
validates :marketing_optimization_twitter_title,
|
29
50
|
presence: true
|
30
51
|
|
31
52
|
# Clean URL Define
|
32
|
-
friendly_id :
|
53
|
+
friendly_id :marketing_optimization_nice_urls, use: [:slugged, :finders]
|
33
54
|
|
34
|
-
def
|
35
|
-
[:
|
55
|
+
def marketing_optimization_nice_urls
|
56
|
+
[:marketing_optimization_page_title]
|
36
57
|
end
|
37
58
|
|
38
59
|
end
|
@@ -4,33 +4,40 @@ module PhcdevworksCoreModules
|
|
4
4
|
# Clean URL Initialize
|
5
5
|
extend FriendlyId
|
6
6
|
|
7
|
-
# Image Upload
|
8
|
-
has_one_attached :seo_twitter_image
|
9
|
-
has_one_attached :seo_open_graph_image
|
10
|
-
|
11
7
|
# Paper Trail Initialize
|
12
|
-
has_paper_trail :class_name => "PhcdevworksCoreModules::
|
8
|
+
has_paper_trail :class_name => "PhcdevworksCoreModules::PostCategoryVersions"
|
13
9
|
|
14
|
-
# Relationships
|
10
|
+
# Relationships for Local
|
15
11
|
belongs_to :user, class_name: "PhcdevworksAccounts::User"
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
12
|
+
belongs_to :optimization, class_name: "PhcdevworksCoreModules::Marketing::Optimization", optional: true
|
13
|
+
|
14
|
+
# Relationships for PHCDevworks Plugins
|
15
|
+
if defined?phcdevworks_press
|
16
|
+
has_and_belongs_to_many :posts, class_name: "PhcdevworksPress::Article::Post", :join_table => "phcdevworks_press_article_categories_posts", :dependent => :destroy
|
17
|
+
has_and_belongs_to_many :posts, class_name: "PhcdevworksPress::Review::Post", :join_table => "phcdevworks_press_review_categories_posts", :dependent => :destroy
|
18
|
+
has_and_belongs_to_many :posts, class_name: "PhcdevworksPress::List::Post", :join_table => "phcdevworks_press_list_categories_posts", :dependent => :destroy
|
19
|
+
end
|
20
|
+
|
21
|
+
if defined?phcdevworks_portfolio
|
22
|
+
has_and_belongs_to_many :posts, class_name: "PhcdevworksPortfolio::Project::Post", :join_table => "phcdevworks_portfolio_project_categories_posts", :dependent => :destroy
|
23
|
+
end
|
24
|
+
|
25
|
+
if defined?phcdevworks_tutorials
|
26
|
+
has_and_belongs_to_many :posts, class_name: "PhcdevworksTutorials::Tutorial::Post", :join_table => "phcdevworks_tutorials_tutorial_categories_posts", :dependent => :destroy
|
27
|
+
has_and_belongs_to_many :posts, class_name: "PhcdevworksTutorials::Command::Post", :join_table => "phcdevworks_tutorials_command_categories_posts", :dependent => :destroy
|
28
|
+
end
|
21
29
|
|
22
30
|
# Form Fields Validation
|
23
|
-
validates :
|
31
|
+
validates :post_category_name,
|
24
32
|
presence: true,
|
25
33
|
uniqueness: true
|
26
|
-
|
34
|
+
|
27
35
|
# Clean URL Define
|
28
|
-
friendly_id :
|
29
|
-
|
30
|
-
def
|
31
|
-
|
36
|
+
friendly_id :post_category_nice_urls, use: [:slugged, :finders]
|
37
|
+
|
38
|
+
def post_category_nice_urls
|
39
|
+
[:post_category_name]
|
32
40
|
end
|
33
|
-
|
34
|
-
|
41
|
+
|
35
42
|
end
|
36
43
|
end
|
data/app/views/layouts/phcdevworks_core_modules/components/backend/sidebars/_side_menu.html.erb
CHANGED
@@ -45,18 +45,40 @@
|
|
45
45
|
<a href="javascript:;">
|
46
46
|
<b class="caret"></b>
|
47
47
|
<i class="fad fa-newspaper"></i>
|
48
|
-
<span>
|
48
|
+
<span>Blog Articles</span>
|
49
49
|
</a>
|
50
50
|
<ul class="sub-menu">
|
51
51
|
<li class="<%= phc_menu_active_controller("phcdevworks_press/article/posts") %>"><%= link_to("Article Index", phcdevworks_press.article_posts_path) %></li>
|
52
|
-
<li class="<%= phc_menu_active_controller("phcdevworks_press/article/posts#new") %>"><%= link_to("New Aritcle", phcdevworks_press.new_article_post_path) %></li>
|
52
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_press/article/posts#new") %>"><%= link_to("Add a New Aritcle", phcdevworks_press.new_article_post_path) %></li>
|
53
|
+
</ul>
|
54
|
+
</li>
|
55
|
+
<li class="has-sub">
|
56
|
+
<a href="javascript:;">
|
57
|
+
<b class="caret"></b>
|
58
|
+
<i class="fad fa-star-half"></i>
|
59
|
+
<span>Review Articles</span>
|
60
|
+
</a>
|
61
|
+
<ul class="sub-menu">
|
62
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_press/review/posts") %>"><%= link_to("Reviews Index", phcdevworks_press.review_posts_path) %></li>
|
63
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_press/review/posts#new") %>"><%= link_to("Add a New Review", phcdevworks_press.new_review_post_path) %></li>
|
64
|
+
</ul>
|
65
|
+
</li>
|
66
|
+
<li class="has-sub">
|
67
|
+
<a href="javascript:;">
|
68
|
+
<b class="caret"></b>
|
69
|
+
<i class="fad fa-th-list"></i>
|
70
|
+
<span>List Articles</span>
|
71
|
+
</a>
|
72
|
+
<ul class="sub-menu">
|
73
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_press/list/posts") %>"><%= link_to("Lists Index", phcdevworks_press.list_posts_path) %></li>
|
74
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_press/list/posts#new") %>"><%= link_to("Add a New List", phcdevworks_press.new_list_post_path) %></li>
|
53
75
|
</ul>
|
54
76
|
</li>
|
55
77
|
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Press -->
|
56
78
|
<% end %>
|
57
79
|
|
58
80
|
<% if defined?phcdevworks_portfolio %>
|
59
|
-
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks
|
81
|
+
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Portfolio -->
|
60
82
|
<li class="nav-header">Portfolio</li>
|
61
83
|
<li class="has-sub">
|
62
84
|
<a href="javascript:;">
|
@@ -80,7 +102,7 @@
|
|
80
102
|
<li class="<%= phc_menu_active_controller("phcdevworks_portfolio/project/posts#new") %>"><%= link_to("New Types", phcdevworks_portfolio.new_project_type_path) %></li>
|
81
103
|
</ul>
|
82
104
|
</li>
|
83
|
-
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks
|
105
|
+
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Portfolio -->
|
84
106
|
<% end %>
|
85
107
|
|
86
108
|
<% if defined?phcdevworks_tutorials %>
|
@@ -112,34 +134,6 @@
|
|
112
134
|
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Tutorials -->
|
113
135
|
<% end %>
|
114
136
|
|
115
|
-
<% if defined?phcdevworks_core_modules %>
|
116
|
-
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Core Modules -->
|
117
|
-
<li class="nav-header">Core Modules</li>
|
118
|
-
<li class="has-sub">
|
119
|
-
<a href="javascript:;">
|
120
|
-
<b class="caret"></b>
|
121
|
-
<i class="fad fa-sitemap"></i>
|
122
|
-
<span>Categories</span>
|
123
|
-
</a>
|
124
|
-
<ul class="sub-menu">
|
125
|
-
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/post/categories") %>"><%= link_to("Category Index", phcdevworks_core_modules.post_categories_path) %></li>
|
126
|
-
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/post/categories#new") %>"><%= link_to("New Category", phcdevworks_core_modules.new_post_category_path) %></li>
|
127
|
-
</ul>
|
128
|
-
</li>
|
129
|
-
<li class="has-sub">
|
130
|
-
<a href="javascript:;">
|
131
|
-
<b class="caret"></b>
|
132
|
-
<i class="fad fa-analytics"></i>
|
133
|
-
<span>Marketing</span>
|
134
|
-
</a>
|
135
|
-
<ul class="sub-menu">
|
136
|
-
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/marketing/optimizations") %>"><%= link_to("SEO Data Index", phcdevworks_core_modules.marketing_optimizations_path) %></li>
|
137
|
-
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/marketing/optimizations#new") %>"><%= link_to("Add SEO Data", phcdevworks_core_modules.new_marketing_optimization_path) %></li>
|
138
|
-
</ul>
|
139
|
-
</li>
|
140
|
-
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Core Modules -->
|
141
|
-
<% end %>
|
142
|
-
|
143
137
|
<% if defined?phcdevworks_members %>
|
144
138
|
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Members -->
|
145
139
|
<li class="nav-header">Membership Manager</li>
|
@@ -238,6 +232,34 @@
|
|
238
232
|
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks RealEstate -->
|
239
233
|
<% end %>
|
240
234
|
|
235
|
+
<% if defined?phcdevworks_core_modules %>
|
236
|
+
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Core Modules -->
|
237
|
+
<li class="nav-header">Core Modules</li>
|
238
|
+
<li class="has-sub">
|
239
|
+
<a href="javascript:;">
|
240
|
+
<b class="caret"></b>
|
241
|
+
<i class="fad fa-sitemap"></i>
|
242
|
+
<span>Categories</span>
|
243
|
+
</a>
|
244
|
+
<ul class="sub-menu">
|
245
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/post/categories") %>"><%= link_to("Category Index", phcdevworks_core_modules.post_categories_path) %></li>
|
246
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/post/categories#new") %>"><%= link_to("New Category", phcdevworks_core_modules.new_post_category_path) %></li>
|
247
|
+
</ul>
|
248
|
+
</li>
|
249
|
+
<li class="has-sub">
|
250
|
+
<a href="javascript:;">
|
251
|
+
<b class="caret"></b>
|
252
|
+
<i class="fad fa-analytics"></i>
|
253
|
+
<span>Marketing</span>
|
254
|
+
</a>
|
255
|
+
<ul class="sub-menu">
|
256
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/marketing/optimizations") %>"><%= link_to("SEO Data Index", phcdevworks_core_modules.marketing_optimizations_path) %></li>
|
257
|
+
<li class="<%= phc_menu_active_controller("phcdevworks_core_modules/marketing/optimizations#new") %>"><%= link_to("Add SEO Data", phcdevworks_core_modules.new_marketing_optimization_path) %></li>
|
258
|
+
</ul>
|
259
|
+
</li>
|
260
|
+
<!-- -PHC- Sidebar - Sidebar Navigation - PHCDevworks Core Modules -->
|
261
|
+
<% end %>
|
262
|
+
|
241
263
|
<% if current_user && current_user.admin? %>
|
242
264
|
<!-- -PHC- Sidebar - Sidebar Navigation - PHCAccounts Admin Options -->
|
243
265
|
<li class="nav-header">User Administration</li>
|
@@ -7,74 +7,76 @@
|
|
7
7
|
|
8
8
|
<!-- Form Input Fields -->
|
9
9
|
<div class="form-group">
|
10
|
-
<%= form.label :
|
11
|
-
<%= form.text_field :
|
10
|
+
<%= form.label :marketing_optimization_page_title, "Page Title" %>
|
11
|
+
<%= form.text_field :marketing_optimization_page_title, class: "form-control" %>
|
12
12
|
</div>
|
13
13
|
|
14
14
|
<div class="form-group">
|
15
|
-
<%= form.label :
|
16
|
-
<%= form.text_area :
|
15
|
+
<%= form.label :marketing_optimization_page_description, "Page Description" %>
|
16
|
+
<%= form.text_area :marketing_optimization_page_description, class: "form-control" %>
|
17
17
|
</div>
|
18
18
|
|
19
19
|
<div class="form-group">
|
20
|
-
<%= form.label :
|
21
|
-
<%= form.text_field :
|
20
|
+
<%= form.label :marketing_optimization_og_title, "Open Graph Title" %>
|
21
|
+
<%= form.text_field :marketing_optimization_og_title, class: "form-control" %>
|
22
22
|
</div>
|
23
23
|
|
24
24
|
<div class="form-group">
|
25
|
-
<%= form.label :
|
26
|
-
<%= form.text_field :
|
25
|
+
<%= form.label :marketing_optimization_og_description, "Open Graph Description" %>
|
26
|
+
<%= form.text_field :marketing_optimization_og_description, class: "form-control" %>
|
27
27
|
</div>
|
28
28
|
|
29
29
|
<div class="form-group">
|
30
|
-
<%= form.label :
|
31
|
-
<%= form.text_field :
|
30
|
+
<%= form.label :marketing_optimization_og_type, "Open Graph Type" %>
|
31
|
+
<%= form.text_field :marketing_optimization_og_type, class: "form-control" %>
|
32
|
+
</div>
|
33
|
+
|
34
|
+
<div class="form-group">
|
35
|
+
<%= form.label :marketing_optimization_og_url, "Open Graph URL" %>
|
36
|
+
<%= form.text_field :marketing_optimization_og_url, class: "form-control" %>
|
32
37
|
</div>
|
33
38
|
|
34
39
|
<div class="form-group field_with_errors">
|
35
|
-
<%= form.label :
|
36
|
-
<%= form.file_field :
|
37
|
-
<% if form.object.
|
38
|
-
<%= image_tag main_app.url_for(form.object.
|
39
|
-
<%= form.label :
|
40
|
-
<%= form.check_box :
|
40
|
+
<%= form.label :marketing_optimization_og_image, "Featured Image" %>
|
41
|
+
<%= form.file_field :marketing_optimization_og_image, class: "form-control" %>
|
42
|
+
<% if form.object.marketing_optimization_og_image.attached? %>
|
43
|
+
<%= image_tag main_app.url_for(form.object.marketing_optimization_og_image), class: "img-responsive img-thumbnail" %>
|
44
|
+
<%= form.label :remove_marketing_optimization_og_image %>
|
45
|
+
<%= form.check_box :remove_marketing_optimization_og_image %>
|
41
46
|
<% end %>
|
42
47
|
</div>
|
43
|
-
|
48
|
+
|
44
49
|
<div class="form-group">
|
45
|
-
<%= form.label :
|
46
|
-
<%= form.text_field :
|
50
|
+
<%= form.label :marketing_optimization_twitter_title, "Twitter Card Title" %>
|
51
|
+
<%= form.text_field :marketing_optimization_twitter_title, class: "form-control" %>
|
47
52
|
</div>
|
48
53
|
|
49
54
|
<div class="form-group">
|
50
|
-
<%= form.label :
|
51
|
-
<%= form.
|
55
|
+
<%= form.label :marketing_optimization_twitter_description, "Twitter Card Description" %>
|
56
|
+
<%= form.text_area :marketing_optimization_twitter_description, class: "form-control" %>
|
52
57
|
</div>
|
53
58
|
|
54
59
|
<div class="form-group">
|
55
|
-
<%= form.label :
|
56
|
-
<%= form.
|
60
|
+
<%= form.label :marketing_optimization_twitter_type, "Twitter Card Type" %>
|
61
|
+
<%= form.text_field :marketing_optimization_twitter_type, class: "form-control" %>
|
57
62
|
</div>
|
58
63
|
|
59
64
|
<div class="form-group">
|
60
|
-
<%= form.label :
|
61
|
-
<%= form.text_field :
|
65
|
+
<%= form.label :marketing_optimization_twitter_url, "Twitter Card URL" %>
|
66
|
+
<%= form.text_field :marketing_optimization_twitter_url, class: "form-control" %>
|
62
67
|
</div>
|
63
68
|
|
64
69
|
<div class="form-group field_with_errors">
|
65
|
-
<%= form.label :
|
66
|
-
<%= form.file_field :
|
67
|
-
<% if form.object.
|
68
|
-
<%= image_tag main_app.url_for(form.object.
|
69
|
-
<%= form.label :
|
70
|
-
<%= form.check_box :
|
70
|
+
<%= form.label :marketing_optimization_twitter_image, "Featured Image" %>
|
71
|
+
<%= form.file_field :marketing_optimization_twitter_image, class: "form-control" %>
|
72
|
+
<% if form.object.marketing_optimization_twitter_image.attached? %>
|
73
|
+
<%= image_tag main_app.url_for(form.object.marketing_optimization_twitter_image), class: "img-responsive img-thumbnail" %>
|
74
|
+
<%= form.label :remove_marketing_optimization_twitter_image %>
|
75
|
+
<%= form.check_box :remove_marketing_optimization_twitter_image %>
|
71
76
|
<% end %>
|
72
77
|
</div>
|
73
78
|
|
74
|
-
|
75
|
-
<%= form.label :seo_twitter_url, "SEO Twitter URL" %>
|
76
|
-
<%= form.text_field :seo_twitter_url, class: "form-control" %>
|
77
|
-
</div>
|
79
|
+
|
78
80
|
<!-- Form Input Fields -->
|
79
81
|
|
80
82
|
<!-- Form Submition Button -->
|
@@ -50,11 +50,11 @@
|
|
50
50
|
<tbody>
|
51
51
|
<% @marketing_optimizations.each do |marketing_optimization| %>
|
52
52
|
<tr>
|
53
|
-
<td><%= marketing_optimization.
|
54
|
-
<td><%= marketing_optimization.
|
55
|
-
<td><%= marketing_optimization.
|
56
|
-
<td><%= marketing_optimization.
|
57
|
-
<td><%= marketing_optimization.
|
53
|
+
<td><%= marketing_optimization.marketing_optimization_page_title %></td>
|
54
|
+
<td><%= marketing_optimization.marketing_optimization_og_title %></td>
|
55
|
+
<td><%= marketing_optimization.marketing_optimization_og_type %></td>
|
56
|
+
<td><%= marketing_optimization.marketing_optimization_twitter_title %></td>
|
57
|
+
<td><%= marketing_optimization.marketing_optimization_twitter_type %></td>
|
58
58
|
<td>
|
59
59
|
<div class="btn-group d-flex" role="group">
|
60
60
|
<%= link_to "SEO Details", marketing_optimization, class: "btn btn-purple btn-xs" %>
|
@@ -1,48 +1,53 @@
|
|
1
1
|
<p id="notice"><%= notice %></p>
|
2
2
|
|
3
3
|
<p>
|
4
|
-
<strong>
|
5
|
-
<%= @marketing_optimization.
|
4
|
+
<strong>Page Title:</strong>
|
5
|
+
<%= @marketing_optimization.marketing_optimization_page_title %>
|
6
6
|
</p>
|
7
7
|
|
8
8
|
<p>
|
9
|
-
<strong>
|
10
|
-
<%= @marketing_optimization.
|
9
|
+
<strong>Page Description:</strong>
|
10
|
+
<%= @marketing_optimization.marketing_optimization_page_description %>
|
11
11
|
</p>
|
12
12
|
|
13
13
|
<p>
|
14
|
-
<strong>
|
15
|
-
<%= @marketing_optimization.
|
14
|
+
<strong>Open Graph Title:</strong>
|
15
|
+
<%= @marketing_optimization.marketing_optimization_og_title %>
|
16
16
|
</p>
|
17
17
|
|
18
18
|
<p>
|
19
|
-
<strong>
|
20
|
-
<%= @marketing_optimization.
|
19
|
+
<strong>Open Graph Description:</strong>
|
20
|
+
<%= @marketing_optimization.marketing_optimization_og_description %>
|
21
21
|
</p>
|
22
22
|
|
23
23
|
<p>
|
24
|
-
<strong>
|
25
|
-
<%= @marketing_optimization.
|
24
|
+
<strong>Open Graph Type:</strong>
|
25
|
+
<%= @marketing_optimization.marketing_optimization_og_type %>
|
26
26
|
</p>
|
27
27
|
|
28
28
|
<p>
|
29
|
-
<strong>
|
30
|
-
<%= @marketing_optimization.
|
29
|
+
<strong>Open Graph URL:</strong>
|
30
|
+
<%= @marketing_optimization.marketing_optimization_og_url %>
|
31
31
|
</p>
|
32
32
|
|
33
33
|
<p>
|
34
|
-
<strong>
|
35
|
-
<%= @marketing_optimization.
|
34
|
+
<strong>Twitter Title:</strong>
|
35
|
+
<%= @marketing_optimization.marketing_optimization_twitter_title %>
|
36
36
|
</p>
|
37
37
|
|
38
38
|
<p>
|
39
|
-
<strong>
|
40
|
-
<%= @marketing_optimization.
|
39
|
+
<strong>Twitter Description:</strong>
|
40
|
+
<%= @marketing_optimization.marketing_optimization_twitter_description %>
|
41
41
|
</p>
|
42
42
|
|
43
43
|
<p>
|
44
|
-
<strong>
|
45
|
-
<%= @marketing_optimization.
|
44
|
+
<strong>Twitter Type:</strong>
|
45
|
+
<%= @marketing_optimization.marketing_optimization_twitter_type %>
|
46
|
+
</p>
|
47
|
+
|
48
|
+
<p>
|
49
|
+
<strong>Twitter URL:</strong>
|
50
|
+
<%= @marketing_optimization.marketing_optimization_twitter_url %>
|
46
51
|
</p>
|
47
52
|
|
48
53
|
<%= link_to 'Edit', edit_marketing_optimization_path(@marketing_optimization) %> |
|
@@ -7,9 +7,14 @@
|
|
7
7
|
|
8
8
|
<!-- Form Input Fields -->
|
9
9
|
<div class="form-group">
|
10
|
-
<%= form.label :
|
11
|
-
<%= form.text_field :
|
10
|
+
<%= form.label :post_category_name, "Category Name" %>
|
11
|
+
<%= form.text_field :post_category_name, class: "form-control" %>
|
12
12
|
</div>
|
13
|
+
|
14
|
+
<div class="form-group">
|
15
|
+
<label>Attach SEO Data</label>
|
16
|
+
<%= collection_select(:post_category, :optimization_id, PhcdevworksCoreModules::Marketing::Optimization.order("marketing_optimization_page_title"), :id, :marketing_optimization_page_title, {}, {class: "form-control"}) %>
|
17
|
+
</div>
|
13
18
|
<!-- Form Input Fields -->
|
14
19
|
|
15
20
|
<!-- Form Submition Button -->
|
@@ -46,7 +46,7 @@
|
|
46
46
|
<tbody>
|
47
47
|
<% @post_categories.each do |post_category| %>
|
48
48
|
<tr>
|
49
|
-
<td><%= post_category.
|
49
|
+
<td><%= post_category.post_category_name %></td>
|
50
50
|
<td>
|
51
51
|
<div class="btn-group d-flex" role="group">
|
52
52
|
<%= link_to "Category Details", post_category, class: "btn btn-purple btn-xs" %>
|
@@ -1,17 +1,18 @@
|
|
1
|
-
class
|
2
|
-
TEXT_BYTES = 1_073_741_823
|
3
|
-
def change
|
4
|
-
|
5
|
-
|
6
|
-
t.string :item_type, {:null=>false}
|
7
|
-
t.integer :item_id, null: false
|
8
|
-
t.string :event, null: false
|
9
|
-
t.string :whodunnit
|
10
|
-
t.text :object, limit: TEXT_BYTES
|
11
|
-
t.datetime :created_at
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
end
|
1
|
+
class CreatePhcdevworksCoreModulesPostCategoryVersions < ActiveRecord::Migration[6.0]
|
2
|
+
TEXT_BYTES = 1_073_741_823
|
3
|
+
def change
|
4
|
+
create_table :phcdevworks_core_modules_post_category_versions do |t|
|
5
|
+
|
6
|
+
t.string :item_type, {:null=>false}
|
7
|
+
t.integer :item_id, null: false
|
8
|
+
t.string :event, null: false
|
9
|
+
t.string :whodunnit
|
10
|
+
t.text :object, limit: TEXT_BYTES
|
11
|
+
t.datetime :created_at
|
12
|
+
|
13
|
+
end
|
14
|
+
|
15
|
+
add_index :phcdevworks_core_modules_post_category_versions, %i(item_type item_id), :name => 'post_category_versions'
|
16
|
+
|
17
|
+
end
|
18
|
+
end
|
@@ -2,22 +2,23 @@ class CreatePhcdevworksCoreModulesMarketingOptimizations < ActiveRecord::Migrati
|
|
2
2
|
def change
|
3
3
|
create_table :phcdevworks_core_modules_marketing_optimizations do |t|
|
4
4
|
|
5
|
-
t.string :
|
6
|
-
t.text :
|
5
|
+
t.string :marketing_optimization_page_title
|
6
|
+
t.text :marketing_optimization_page_description
|
7
7
|
|
8
|
-
t.string :
|
9
|
-
t.
|
10
|
-
t.string :
|
11
|
-
t.
|
8
|
+
t.string :marketing_optimization_og_title
|
9
|
+
t.text :marketing_optimization_og_description
|
10
|
+
t.string :marketing_optimization_og_type
|
11
|
+
t.string :marketing_optimization_og_url
|
12
12
|
|
13
|
-
t.string :
|
14
|
-
t.
|
15
|
-
t.string :
|
16
|
-
t.
|
13
|
+
t.string :marketing_optimization_twitter_title
|
14
|
+
t.text :marketing_optimization_twitter_description
|
15
|
+
t.string :marketing_optimization_twitter_type
|
16
|
+
t.string :marketing_optimization_twitter_url
|
17
17
|
|
18
18
|
t.string :slug
|
19
19
|
t.string :user_id
|
20
20
|
t.string :org_id
|
21
|
+
|
21
22
|
t.timestamps
|
22
23
|
|
23
24
|
end
|
data/db/migrate/20200705225433_create_phcdevworks_core_modules_marketing_optimization_versions.rb
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
class CreatePhcdevworksCoreModulesMarketingOptimizationVersions < ActiveRecord::Migration[6.0]
|
2
|
+
TEXT_BYTES = 1_073_741_823
|
3
|
+
def change
|
4
|
+
create_table :phcdevworks_core_modules_marketing_optimization_versions do |t|
|
5
|
+
|
6
|
+
t.string :item_type, {:null=>false}
|
7
|
+
t.integer :item_id, null: false
|
8
|
+
t.string :event, null: false
|
9
|
+
t.string :whodunnit
|
10
|
+
t.text :object, limit: TEXT_BYTES
|
11
|
+
t.datetime :created_at
|
12
|
+
|
13
|
+
end
|
14
|
+
|
15
|
+
add_index :phcdevworks_core_modules_marketing_optimization_versions, %i(item_type item_id), :name => 'marketing_optimization_versions'
|
16
|
+
|
17
|
+
end
|
18
|
+
end
|
@@ -2,12 +2,14 @@ class CreatePhcdevworksCoreModulesPostCategories < ActiveRecord::Migration[6.0]
|
|
2
2
|
def change
|
3
3
|
create_table :phcdevworks_core_modules_post_categories do |t|
|
4
4
|
|
5
|
-
t.string :
|
5
|
+
t.string :post_category_name
|
6
6
|
|
7
7
|
t.string :slug
|
8
8
|
t.string :user_id
|
9
9
|
t.string :org_id
|
10
10
|
|
11
|
+
t.string :optimization_id
|
12
|
+
|
11
13
|
t.timestamps
|
12
14
|
|
13
15
|
end
|
@@ -1,6 +1,6 @@
|
|
1
1
|
module PhcdevworksCoreModules
|
2
2
|
class Engine < ::Rails::Engine
|
3
|
-
|
3
|
+
|
4
4
|
# Load Main Dependencies
|
5
5
|
require "jbuilder"
|
6
6
|
require "paper_trail"
|
@@ -28,7 +28,7 @@ module PhcdevworksCoreModules
|
|
28
28
|
|
29
29
|
# Load User Accounts
|
30
30
|
require "phcdevworks_accounts"
|
31
|
-
|
31
|
+
|
32
32
|
# Engine Namespace
|
33
33
|
isolate_namespace PhcdevworksCoreModules
|
34
34
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: phcdevworks_core_modules
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 6.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- PHCDevworks
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-07-
|
11
|
+
date: 2020-07-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -64,84 +64,84 @@ dependencies:
|
|
64
64
|
requirements:
|
65
65
|
- - "~>"
|
66
66
|
- !ruby/object:Gem::Version
|
67
|
-
version: '
|
67
|
+
version: '2.0'
|
68
68
|
type: :runtime
|
69
69
|
prerelease: false
|
70
70
|
version_requirements: !ruby/object:Gem::Requirement
|
71
71
|
requirements:
|
72
72
|
- - "~>"
|
73
73
|
- !ruby/object:Gem::Version
|
74
|
-
version: '
|
74
|
+
version: '2.0'
|
75
75
|
- !ruby/object:Gem::Dependency
|
76
76
|
name: phcthemes_web_theme_pack
|
77
77
|
requirement: !ruby/object:Gem::Requirement
|
78
78
|
requirements:
|
79
79
|
- - "~>"
|
80
80
|
- !ruby/object:Gem::Version
|
81
|
-
version: '
|
81
|
+
version: '2.0'
|
82
82
|
type: :runtime
|
83
83
|
prerelease: false
|
84
84
|
version_requirements: !ruby/object:Gem::Requirement
|
85
85
|
requirements:
|
86
86
|
- - "~>"
|
87
87
|
- !ruby/object:Gem::Version
|
88
|
-
version: '
|
88
|
+
version: '2.0'
|
89
89
|
- !ruby/object:Gem::Dependency
|
90
90
|
name: phcdevworks_active_menus
|
91
91
|
requirement: !ruby/object:Gem::Requirement
|
92
92
|
requirements:
|
93
93
|
- - "~>"
|
94
94
|
- !ruby/object:Gem::Version
|
95
|
-
version: '
|
95
|
+
version: '2.0'
|
96
96
|
type: :runtime
|
97
97
|
prerelease: false
|
98
98
|
version_requirements: !ruby/object:Gem::Requirement
|
99
99
|
requirements:
|
100
100
|
- - "~>"
|
101
101
|
- !ruby/object:Gem::Version
|
102
|
-
version: '
|
102
|
+
version: '2.0'
|
103
103
|
- !ruby/object:Gem::Dependency
|
104
104
|
name: phcdevworks_core
|
105
105
|
requirement: !ruby/object:Gem::Requirement
|
106
106
|
requirements:
|
107
107
|
- - "~>"
|
108
108
|
- !ruby/object:Gem::Version
|
109
|
-
version: '
|
109
|
+
version: '2.0'
|
110
110
|
type: :runtime
|
111
111
|
prerelease: false
|
112
112
|
version_requirements: !ruby/object:Gem::Requirement
|
113
113
|
requirements:
|
114
114
|
- - "~>"
|
115
115
|
- !ruby/object:Gem::Version
|
116
|
-
version: '
|
116
|
+
version: '2.0'
|
117
117
|
- !ruby/object:Gem::Dependency
|
118
118
|
name: phcdevworks_notifications
|
119
119
|
requirement: !ruby/object:Gem::Requirement
|
120
120
|
requirements:
|
121
121
|
- - "~>"
|
122
122
|
- !ruby/object:Gem::Version
|
123
|
-
version: '
|
123
|
+
version: '2.0'
|
124
124
|
type: :runtime
|
125
125
|
prerelease: false
|
126
126
|
version_requirements: !ruby/object:Gem::Requirement
|
127
127
|
requirements:
|
128
128
|
- - "~>"
|
129
129
|
- !ruby/object:Gem::Version
|
130
|
-
version: '
|
130
|
+
version: '2.0'
|
131
131
|
- !ruby/object:Gem::Dependency
|
132
132
|
name: phcdevworks_titleseo
|
133
133
|
requirement: !ruby/object:Gem::Requirement
|
134
134
|
requirements:
|
135
135
|
- - "~>"
|
136
136
|
- !ruby/object:Gem::Version
|
137
|
-
version: '
|
137
|
+
version: '3.0'
|
138
138
|
type: :runtime
|
139
139
|
prerelease: false
|
140
140
|
version_requirements: !ruby/object:Gem::Requirement
|
141
141
|
requirements:
|
142
142
|
- - "~>"
|
143
143
|
- !ruby/object:Gem::Version
|
144
|
-
version: '
|
144
|
+
version: '3.0'
|
145
145
|
- !ruby/object:Gem::Dependency
|
146
146
|
name: wicked
|
147
147
|
requirement: !ruby/object:Gem::Requirement
|
@@ -190,14 +190,14 @@ dependencies:
|
|
190
190
|
requirements:
|
191
191
|
- - "~>"
|
192
192
|
- !ruby/object:Gem::Version
|
193
|
-
version: '1.
|
193
|
+
version: '1.74'
|
194
194
|
type: :runtime
|
195
195
|
prerelease: false
|
196
196
|
version_requirements: !ruby/object:Gem::Requirement
|
197
197
|
requirements:
|
198
198
|
- - "~>"
|
199
199
|
- !ruby/object:Gem::Version
|
200
|
-
version: '1.
|
200
|
+
version: '1.74'
|
201
201
|
- !ruby/object:Gem::Dependency
|
202
202
|
name: google-cloud-storage
|
203
203
|
requirement: !ruby/object:Gem::Requirement
|
@@ -232,14 +232,14 @@ dependencies:
|
|
232
232
|
requirements:
|
233
233
|
- - "~>"
|
234
234
|
- !ruby/object:Gem::Version
|
235
|
-
version: '
|
235
|
+
version: '2.0'
|
236
236
|
type: :runtime
|
237
237
|
prerelease: false
|
238
238
|
version_requirements: !ruby/object:Gem::Requirement
|
239
239
|
requirements:
|
240
240
|
- - "~>"
|
241
241
|
- !ruby/object:Gem::Version
|
242
|
-
version: '
|
242
|
+
version: '2.0'
|
243
243
|
- !ruby/object:Gem::Dependency
|
244
244
|
name: sqlite3
|
245
245
|
requirement: !ruby/object:Gem::Requirement
|
@@ -256,7 +256,7 @@ dependencies:
|
|
256
256
|
version: '1.4'
|
257
257
|
description: Core modules for PHCDevworks plugins.
|
258
258
|
email:
|
259
|
-
-
|
259
|
+
- developers@phcdevworks.com
|
260
260
|
executables: []
|
261
261
|
extensions: []
|
262
262
|
extra_rdoc_files: []
|
@@ -281,13 +281,13 @@ files:
|
|
281
281
|
- app/jobs/phcdevworks_core_modules/application_job.rb
|
282
282
|
- app/mailers/phcdevworks_core_modules/application_mailer.rb
|
283
283
|
- app/models/phcdevworks_core_modules/application_record.rb
|
284
|
-
- app/models/phcdevworks_core_modules/core_category_versions.rb
|
285
|
-
- app/models/phcdevworks_core_modules/core_optimization_versions.rb
|
286
284
|
- app/models/phcdevworks_core_modules/marketing.rb
|
287
285
|
- app/models/phcdevworks_core_modules/marketing/optimization.rb
|
286
|
+
- app/models/phcdevworks_core_modules/marketing_optimization_versions.rb
|
288
287
|
- app/models/phcdevworks_core_modules/modules.rb
|
289
288
|
- app/models/phcdevworks_core_modules/post.rb
|
290
289
|
- app/models/phcdevworks_core_modules/post/category.rb
|
290
|
+
- app/models/phcdevworks_core_modules/post_category_versions.rb
|
291
291
|
- app/views/layouts/phcdevworks_core_modules/application.html.erb
|
292
292
|
- app/views/layouts/phcdevworks_core_modules/components/backend/footer/_footer.html.erb
|
293
293
|
- app/views/layouts/phcdevworks_core_modules/components/backend/navigation/_top_menu.html.erb
|
@@ -303,10 +303,9 @@ files:
|
|
303
303
|
- app/views/phcdevworks_core_modules/post/categories/new.html.erb
|
304
304
|
- app/views/phcdevworks_core_modules/post/categories/show.html.erb
|
305
305
|
- config/routes.rb
|
306
|
-
- db/migrate/
|
306
|
+
- db/migrate/20170517064427_create_phcdevworks_core_modules_post_category_versions.rb
|
307
307
|
- db/migrate/20200705223718_create_phcdevworks_core_modules_marketing_optimizations.rb
|
308
|
-
- db/migrate/
|
309
|
-
- db/migrate/20200706091346_create_phcdevworks_core_modules_categories_optimizations.rb
|
308
|
+
- db/migrate/20200705225433_create_phcdevworks_core_modules_marketing_optimization_versions.rb
|
310
309
|
- db/migrate/20200706094820_create_phcdevworks_core_modules_post_categories.rb
|
311
310
|
- lib/phcdevworks_core_modules.rb
|
312
311
|
- lib/phcdevworks_core_modules/engine.rb
|
@@ -1,17 +0,0 @@
|
|
1
|
-
class CreatePhcdevworksCoreModulesCategoryVersions < ActiveRecord::Migration[6.0]
|
2
|
-
TEXT_BYTES = 1_073_741_823
|
3
|
-
def change
|
4
|
-
|
5
|
-
create_table :phcdevworks_core_modules_category_versions do |t|
|
6
|
-
t.string :item_type, {:null=>false}
|
7
|
-
t.integer :item_id, null: false
|
8
|
-
t.string :event, null: false
|
9
|
-
t.string :whodunnit
|
10
|
-
t.text :object, limit: TEXT_BYTES
|
11
|
-
t.datetime :created_at
|
12
|
-
end
|
13
|
-
|
14
|
-
add_index :phcdevworks_core_modules_category_versions, %i(item_type item_id), :name => 'core_category_versions'
|
15
|
-
|
16
|
-
end
|
17
|
-
end
|