phcpress 50.0.0 → 51.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +2 -1
  3. data/app/assets/javascripts/phcpress/application.js +4 -1
  4. data/app/assets/javascripts/phcpress/article/categories.js +0 -0
  5. data/app/assets/javascripts/phcpress/article/posts.js +0 -0
  6. data/app/assets/javascripts/phcpress/blog/articles.js +0 -0
  7. data/app/assets/javascripts/phcpress/custom/custom.js +0 -0
  8. data/app/assets/stylesheets/phcpress/application.scss +3 -1
  9. data/app/assets/stylesheets/phcpress/article/categories.scss +0 -0
  10. data/app/assets/stylesheets/phcpress/article/posts.scss +0 -0
  11. data/app/assets/stylesheets/phcpress/blog/articles.scss +0 -0
  12. data/app/controllers/phcpress/api/v1/post_index.json.rabl +2 -0
  13. data/app/controllers/phcpress/api/v1/post_single.json.rabl +2 -0
  14. data/app/controllers/phcpress/application_controller.rb +20 -10
  15. data/app/controllers/phcpress/article/categories_controller.rb +72 -0
  16. data/app/controllers/phcpress/article/posts_controller.rb +17 -13
  17. data/app/controllers/phcpress/blog/articles_controller.rb +20 -0
  18. data/app/helpers/phcpress/application_helper.rb +2 -12
  19. data/app/helpers/phcpress/article/categories_helper.rb +4 -0
  20. data/app/helpers/phcpress/article/posts_helper.rb +4 -0
  21. data/app/jobs/phcpress/application_job.rb +2 -2
  22. data/app/mailers/phcpress/application_mailer.rb +4 -4
  23. data/app/models/phcpress/{modules → article}/category.rb +4 -3
  24. data/app/models/phcpress/article/post.rb +4 -4
  25. data/app/views/layouts/phcpress/application.html.erb +16 -19
  26. data/app/views/layouts/phcpress/components/backend/footer/_footer.html.erb +9 -1
  27. data/app/views/layouts/phcpress/components/backend/navigation/_top_menu.html.erb +3 -68
  28. data/app/views/layouts/phcpress/components/backend/sidebars/_side_menu.html.erb +98 -60
  29. data/app/views/layouts/phcpress/frontend.html.erb +5 -24
  30. data/app/views/phcpress/article/categories/_form.html.erb +13 -0
  31. data/app/views/phcpress/{modules → article}/categories/edit.html.erb +5 -4
  32. data/app/views/phcpress/{modules → article}/categories/index.html.erb +18 -5
  33. data/app/views/phcpress/{modules → article}/categories/new.html.erb +8 -5
  34. data/app/views/phcpress/article/categories/show.html.erb +9 -0
  35. data/app/views/phcpress/article/posts/_form.html.erb +17 -24
  36. data/app/views/phcpress/article/posts/edit.html.erb +14 -24
  37. data/app/views/phcpress/article/posts/index.html.erb +13 -2
  38. data/app/views/phcpress/article/posts/new.html.erb +16 -5
  39. data/app/views/phcpress/blog/articles/index.html.erb +69 -0
  40. data/app/views/phcpress/blog/articles/show.html.erb +1 -0
  41. data/config/routes.rb +12 -20
  42. data/db/migrate/20170517064030_create_phcpress_post_versions.rb +17 -0
  43. data/db/migrate/20170517064427_create_phcpress_category_versions.rb +17 -0
  44. data/db/migrate/{20160718204718_create_phcpress_article_posts.rb → 20190315010932_create_phcpress_article_posts.rb} +2 -3
  45. data/db/migrate/{20160716182936_create_phcpress_modules_categories.rb → 20190315040834_create_phcpress_article_categories.rb} +2 -3
  46. data/db/migrate/20190315173237_create_join_table_categories_posts.rb +8 -0
  47. data/lib/phcpress/engine.rb +66 -60
  48. data/lib/phcpress/version.rb +1 -1
  49. metadata +111 -130
  50. data/app/controllers/phcpress/api/v1/categories_controller.rb +0 -15
  51. data/app/controllers/phcpress/api/v1/posts_controller.rb +0 -20
  52. data/app/controllers/phcpress/frontend/articles_controller.rb +0 -21
  53. data/app/controllers/phcpress/modules/categories_controller.rb +0 -65
  54. data/app/controllers/phcpress/modules/connections_controller.rb +0 -65
  55. data/app/models/phcpress/api/v1/category.rb +0 -4
  56. data/app/models/phcpress/api/v1/post.rb +0 -4
  57. data/app/models/phcpress/connection_versions.rb +0 -5
  58. data/app/models/phcpress/frontend.rb +0 -7
  59. data/app/models/phcpress/frontend/article.rb +0 -4
  60. data/app/models/phcpress/modules.rb +0 -7
  61. data/app/models/phcpress/modules/connection.rb +0 -25
  62. data/app/views/phcpress/api/v1/categories/index.json.rabl +0 -2
  63. data/app/views/phcpress/api/v1/posts/index.json.rabl +0 -2
  64. data/app/views/phcpress/api/v1/posts/show.json.rabl +0 -2
  65. data/app/views/phcpress/frontend/articles/index.html.erb +0 -35
  66. data/app/views/phcpress/frontend/articles/show.html.erb +0 -35
  67. data/app/views/phcpress/modules/categories/_form.html.erb +0 -17
  68. data/app/views/phcpress/modules/categories/show.html.erb +0 -22
  69. data/app/views/phcpress/modules/connections/_form.html.erb +0 -24
  70. data/app/views/phcpress/modules/connections/edit.html.erb +0 -39
  71. data/app/views/phcpress/modules/connections/index.html.erb +0 -66
  72. data/app/views/phcpress/modules/connections/new.html.erb +0 -39
  73. data/app/views/phcpress/modules/connections/show.html.erb +0 -50
  74. data/db/migrate/20160719221205_create_phcpress_modules_connections.rb +0 -17
@@ -1,8 +1,9 @@
1
- <!-- Sidebar -->
1
+ <!-- Sidebar for Users and Admin -->
2
2
  <div data-scrollbar="true" data-height="100%">
3
- <% if current_user %>
4
- <!-- Sidebar - User Profile Menu -->
5
- <ul class="nav">
3
+
4
+ <!-- Sidebar - User Profile Menu -->
5
+ <ul class="nav">
6
+ <% if current_user %>
6
7
  <li class="nav-profile">
7
8
  <a href="javascript:;" data-toggle="nav-profile">
8
9
  <div class="cover with-shadow"></div>
@@ -11,7 +12,7 @@
11
12
  </div>
12
13
  <div class="info">
13
14
  <b class="caret pull-right"></b>
14
- <%= current_user.firstname %> <%= current_user.lastname %>
15
+ <%= current_user.firstname + ' ' + current_user.lastname %>
15
16
  <small><%= current_user.username %></small>
16
17
  </div>
17
18
  </a>
@@ -30,78 +31,113 @@
30
31
  </li>
31
32
  </ul>
32
33
  </li>
33
- </ul>
34
- <!-- Sidebar - User Profile Menu -->
35
- <!-- Sidebar - Sidebar Navigation -->
36
- <ul class="nav">
37
- <li class="nav-header">Accounts</li>
34
+ <% end %>
35
+ </ul>
36
+ <!-- Sidebar - User Profile Menu -->
37
+ <!-- Sidebar - Sidebar Navigation -->
38
+ <ul class="nav">
39
+
40
+ <% if defined?phcpress %>
41
+ <!-- Sidebar - Sidebar Navigation - PHCPress(Pro) -->
42
+ <li class="nav-header">Article Management</li>
38
43
  <li class="has-sub">
39
44
  <a href="javascript:;">
40
45
  <b class="caret"></b>
41
- <i class="fa fa-th-large"></i>
42
- <span>Accounts Dashboard</span>
46
+ <i class="fas fa-newspaper"></i>
47
+ <span>Article Posts</span>
43
48
  </a>
44
49
  <ul class="sub-menu">
45
- <li><%= link_to('Settings', phcaccounts.edit_user_registration_path) %></li>
46
- <li><%= link_to('Logout', phcaccounts.destroy_user_session_path, method: :delete) %></li>
50
+ <li class="<%= phc_menus_active_controller('phcpress/article/posts') %>"><%= link_to('Article Index', phcpress.article_posts_path) %></li>
51
+ <li class="<%= phc_menus_active_controller('phcpress/article/posts#new') %>"><%= link_to('New Aritcle', phcpress.new_article_post_path) %></li>
47
52
  </ul>
48
53
  </li>
49
- <!-- Sidebar - Sidebar Minifier -->
50
- <li>
51
- <a href="javascript:;" class="sidebar-minify-btn" data-click="sidebar-minify">
52
- <i class="fa fa-angle-double-left"></i>
54
+ <li class="has-sub">
55
+ <a href="javascript:;">
56
+ <b class="caret"></b>
57
+ <i class="fas fa-sitemap"></i>
58
+ <span>Article Categories</span>
53
59
  </a>
60
+ <ul class="sub-menu">
61
+ <li class="<%= phc_menus_active_controller('phcpress/article/categories') %>"><%= link_to('Category Index', phcpress.article_categories_path) %></li>
62
+ <li class="<%= phc_menus_active_controller('phcpress/article/categories#new') %>"><%= link_to('New Category', phcpress.new_article_category_path) %></li>
63
+ </ul>
54
64
  </li>
55
- <!-- Sidebar - Sidebar Minifier -->
56
- </ul>
57
- <!-- Sidebar - Sidebar Navigation -->
58
- <% end %>
59
- <% if current_admin %>
60
- <!-- Sidebar - User Profile Menu -->
61
- <ul class="nav">
62
- <li class="nav-profile">
63
- <a href="javascript:;" data-toggle="nav-profile">
64
- <div class="cover with-shadow"></div>
65
- <div class="image">
66
- <%= image_tag current_admin.gravatar_url %>
67
- </div>
68
- <div class="info">
69
- <b class="caret pull-right"></b>
70
- <%= current_admin.firstname + ' ' + current_admin.lastname %>
71
- <small><%= current_admin.username %></small>
72
- </div>
65
+ <!-- Sidebar - Sidebar Navigation - PHCPress(Pro) -->
66
+ <% end %>
67
+
68
+ <% if defined?phcmembers %>
69
+ <!-- Sidebar - Sidebar Navigation - PHCPress(Pro) -->
70
+ <li class="nav-header">Membership Manager</li>
71
+ <li class="has-sub">
72
+ <a href="javascript:;">
73
+ <b class="caret"></b>
74
+ <i class="fas fa-users"></i>
75
+ <span>Member's Data</span>
73
76
  </a>
77
+ <ul class="sub-menu">
78
+ <li class="<%= phc_menus_active_controller('phcmembers/member/profiles') %>"><%= link_to('Profile Index', phcmembers.member_profiles_path) %></li>
79
+ <li class="<%= phc_menus_active_controller('phcmembers/member/profiles#new') %>"><%= link_to('New Member Profile', phcmembers.new_member_profile_path) %></li>
80
+ </ul>
74
81
  </li>
75
- <li>
76
- <ul class="nav nav-profile">
77
- <li>
78
- <%= link_to phcaccounts.edit_admin_registration_path do %>
79
- <i class="fas fa-cogs"></i> Account Settings
80
- <% end %>
81
- </li>
82
- <li>
83
- <%= link_to phcaccounts.destroy_admin_session_path do %>
84
- <i class="fas fa-sign-out-alt"></i> Logout
85
- <% end %>
86
- </li>
82
+ <li class="has-sub">
83
+ <a href="javascript:;">
84
+ <b class="caret"></b>
85
+ <i class="fas fa-list-alt"></i>
86
+ <span>Member's Directory</span>
87
+ </a>
88
+ <ul class="sub-menu">
89
+ <li class="<%= phc_menus_active_controller('phcmembers/directory/categories') %>"><%= link_to('Directory Index', phcmembers.directory_categories_path) %></li>
90
+ <li class="<%= phc_menus_active_controller('phcmembers/directory/categories#new') %>"><%= link_to('New Directory Listing', phcmembers.new_directory_category_path) %></li>
91
+ </ul>
92
+ </li>
93
+ <!-- Sidebar - Sidebar Navigation - PHCPress(Pro) -->
94
+ <% end %>
95
+
96
+ <% if defined?phcscriptcdn %>
97
+ <!-- Sidebar - Sidebar Navigation - PHCScriptCDN(Pro) -->
98
+ <li class="nav-header">Script Management</li>
99
+ <li class="has-sub">
100
+ <a href="javascript:;">
101
+ <b class="caret"></b>
102
+ <i class="fas fa-newspaper"></i>
103
+ <span>Script Posts</span>
104
+ </a>
105
+ <ul class="sub-menu">
106
+ <li class="<%= phc_menus_active_controller('phcscriptcdn/script/listings') %>"><%= link_to "All Script Listings", phcscriptcdn.script_listings_path %></li>
107
+ <li class="<%= phc_menus_active_controller('phcscriptcdn/script/listings#new') %>"><%= link_to "Add a New Listing", phcscriptcdn.new_script_listing_path %></li>
108
+ </ul>
109
+ </li>
110
+ <li class="has-sub">
111
+ <a href="javascript:;">
112
+ <b class="caret"></b>
113
+ <i class="fas fa-sitemap"></i>
114
+ <span>Script Extras</span>
115
+ </a>
116
+ <ul class="sub-menu">
117
+ <li class="<%= phc_menus_active_controller('phcscriptcdn/script/authors') %>"><%= link_to "Script Authors", phcscriptcdn.script_authors_path %></li>
118
+ <li class="<%= phc_menus_active_controller('phcscriptcdn/script/licences') %>"><%= link_to "Script Licences", phcscriptcdn.script_licences_path %></li>
119
+ <li class="<%= phc_menus_active_controller('phcscriptcdn/script/extensions') %>"><%= link_to "Script Extensions", phcscriptcdn.script_extensions_path %></li>
120
+ <li class="<%= phc_menus_active_controller('phcscriptcdn/script/versions') %>"><%= link_to "Script Versions", phcscriptcdn.script_versions_path %></li>
87
121
  </ul>
88
122
  </li>
89
- </ul>
90
- <!-- Sidebar - User Profile Menu -->
91
- <!-- Sidebar - Sidebar Navigation -->
92
- <ul class="nav">
93
- <li class="nav-header">Accounts Menu</li>
123
+ <!-- Sidebar - Sidebar Navigation - PHCScriptCDN(Pro) -->
124
+ <% end %>
125
+
126
+ <% if current_user %>
127
+ <!-- Sidebar - Sidebar Navigation - PHCAccounts -->
128
+ <li class="nav-header">Account Settings</li>
94
129
  <li class="has-sub">
95
130
  <a href="javascript:;">
96
131
  <b class="caret"></b>
97
- <i class="fa fa-th-large"></i>
132
+ <i class="fas fa-user"></i>
98
133
  <span>Accounts Dashboard</span>
99
134
  </a>
100
135
  <ul class="sub-menu">
101
- <li><%= link_to('Settings', phcaccountspro.edit_admin_registration_path) %></li>
102
- <li><%= link_to('Logout', phcaccountspro.destroy_admin_session_path, method: :delete) %></li>
136
+ <li class="<%= phc_menus_active_controller('phcaccounts/admin/edit') %>"><%= link_to('Settings', phcaccounts.edit_user_registration_path) %></li>
137
+ <li class="<%= phc_menus_active_controller('phcaccounts/admin/new') %>"><%= link_to('Logout', phcaccounts.destroy_user_session_path, method: :delete) %></li>
103
138
  </ul>
104
139
  </li>
140
+ <!-- Sidebar - Sidebar Navigation - PHCAccounts -->
105
141
  <!-- Sidebar - Sidebar Minifier -->
106
142
  <li>
107
143
  <a href="javascript:;" class="sidebar-minify-btn" data-click="sidebar-minify">
@@ -109,8 +145,10 @@
109
145
  </a>
110
146
  </li>
111
147
  <!-- Sidebar - Sidebar Minifier -->
112
- </ul>
113
- <!-- Sidebar - Sidebar Navigation -->
114
- <% end %>
148
+ <% end %>
149
+
150
+ </ul>
151
+ <!-- Sidebar - Sidebar Navigation -->
152
+
115
153
  </div>
116
- <!-- Sidebar -->
154
+ <!-- Sidebar for Users and Admin -->
@@ -1,24 +1,5 @@
1
- <!DOCTYPE html>
2
- <html>
3
-
4
- <head>
5
-
6
- <title>PHCPress - Rails CMS Engine</title>
7
-
8
- <%= stylesheet_link_tag "phcpress/application", media: "all" %>
9
- <%= javascript_include_tag "phcpress/application" %>
10
- <%= csrf_meta_tags %>
11
-
12
- </head>
13
-
14
- <body class="hold-transition skin-blue sidebar-mini">
15
-
16
- <!-- Page Content -->
17
- <div class="content-wrapper">
18
- <%= yield %>
19
- </div>
20
- <!-- Page Content -->
21
-
22
- </body>
23
-
24
- </html>
1
+ <!-- Page Content -->
2
+ <div id="content" class="content">
3
+ <%= yield %>
4
+ </div>
5
+ <!-- Page Content -->
@@ -0,0 +1,13 @@
1
+ <%= form_with(model: article_category, local: true) do |form| %>
2
+
3
+ <!-- PHCPress - Category Form -->
4
+ <div class="form-group">
5
+ <%= form.label :catname, "Category Name" %>
6
+ <%= form.text_field :catname, class: "form-control" %>
7
+ </div>
8
+ <div class="actions">
9
+ <%= form.submit class: "btn btn-primary" %>
10
+ </div>
11
+ <!-- PHCPress - Category Form -->
12
+
13
+ <% end %>
@@ -1,8 +1,9 @@
1
1
  <!-- Title System -->
2
- <% phc_title "Plugin: Article Category Manager" %>
2
+ <% phc_title "Article Category Manager" %>
3
3
  <% phc_title_tagline "Update Category Data" %>
4
- <% phc_breadcrumb_one link_to "Category Index", phcpress.modules_categories_path %>
5
- <% phc_breadcrumb_two yield(:phc_title_tagline) %>
4
+ <% phc_breadcrumb_one yield(:phc_title) %>
5
+ <% phc_breadcrumb_two link_to "Category Index", phcpress.article_categories_path %>
6
+ <% phc_breadcrumb_three yield(:phc_title_tagline) %>
6
7
  <!-- Title System -->
7
8
 
8
9
  <!-- Page Content -->
@@ -17,7 +18,7 @@
17
18
  </div>
18
19
  <div class="panel-body">
19
20
  <!-- Table - Category Edit Form -->
20
- <%= render 'form', modules_category: @modules_category %>
21
+ <%= render 'form', article_category: @article_category %>
21
22
  <!-- Table - Category Edit Form -->
22
23
  </div>
23
24
  </div>
@@ -1,9 +1,22 @@
1
1
  <!-- Title System -->
2
- <% phc_title "Plugin: Article Category Manager" %>
2
+ <% phc_title "Article Category Manager" %>
3
3
  <% phc_title_tagline "Category Index" %>
4
- <% phc_breadcrumb_one yield(:phc_title_tagline) %>
4
+ <% phc_breadcrumb_one yield(:phc_title) %>
5
+ <% phc_breadcrumb_two link_to "Category Index", phcpress.article_categories_path %>
6
+ <% phc_breadcrumb_three yield(:phc_title_tagline) %>
5
7
  <!-- Title System -->
6
8
 
9
+ <!-- Page Bradcrumbs -->
10
+ <ol class="breadcrumb pull-right">
11
+ <li class="breadcrumb-item"><%= yield(:phc_breadcrumb_one) %></li>
12
+ <li class="breadcrumb-item active"><%= yield(:phc_breadcrumb_two) %></li>
13
+ </ol>
14
+ <!-- Page Bradcrumbs -->
15
+
16
+ <!-- Page Header -->
17
+ <h1 class="page-header"><%= yield(:phc_title) %></h1>
18
+ <!-- Page Header -->
19
+
7
20
  <!-- Page Content -->
8
21
  <div class="panel panel-inverse">
9
22
  <div class="panel-heading">
@@ -25,10 +38,10 @@
25
38
  </tr>
26
39
  </thead>
27
40
  <tbody>
28
- <% @modules_categories.each do |modules_category| %>
41
+ <% @article_categories.each do |article_category| %>
29
42
  <tr>
30
- <td><%= link_to modules_category.catname, phcpress.edit_modules_category_path(modules_category) %></td>
31
- <td><%= link_to 'Trash', modules_category, class: "btn btn-danger btn-xs", method: :delete, data: { confirm: 'Are you sure?' } %></td>
43
+ <td><%= link_to article_category.catname, phcpress.edit_article_category_path(article_category) %></td>
44
+ <td><%= link_to 'Trash', article_category, class: "btn btn-danger btn-xs", method: :delete, data: { confirm: 'Are you sure?' } %></td>
32
45
  </tr>
33
46
  <% end %>
34
47
  </tbody>
@@ -1,8 +1,9 @@
1
1
  <!-- Title System -->
2
- <% phc_title "Plugin: Article Category Manager" %>
3
- <% phc_title_tagline "Category Details" %>
4
- <% phc_breadcrumb_one link_to "Category Index", phcpress.modules_categories_path %>
5
- <% phc_breadcrumb_two yield(:phc_title_tagline) %>
2
+ <% phc_title "Article Category Manager" %>
3
+ <% phc_title_tagline "Create a New Category" %>
4
+ <% phc_breadcrumb_one yield(:phc_title) %>
5
+ <% phc_breadcrumb_two link_to "Category Index", phcpress.article_categories_path %>
6
+ <% phc_breadcrumb_three yield(:phc_title_tagline) %>
6
7
  <!-- Title System -->
7
8
 
8
9
  <!-- Page Content -->
@@ -16,7 +17,9 @@
16
17
  <h4 class="panel-title"><%= yield(:phc_title_tagline) %></h4>
17
18
  </div>
18
19
  <div class="panel-body">
19
-
20
+ <!-- Table - Category New Form -->
21
+ <%= render 'form', article_category: @article_category %>
22
+ <!-- Table - Category New Form -->
20
23
  </div>
21
24
  </div>
22
25
  <!-- Page Content -->
@@ -0,0 +1,9 @@
1
+ <p id="notice"><%= notice %></p>
2
+
3
+ <p>
4
+ <strong>Catname:</strong>
5
+ <%= @article_category.catname %>
6
+ </p>
7
+
8
+ <%= link_to 'Edit', edit_article_category_path(@article_category) %> |
9
+ <%= link_to 'Back', article_categories_path %>
@@ -1,4 +1,4 @@
1
- <%= form_for(@article_post, :html => {:multipart => true}) do |phc_press_article_post| %>
1
+ <%= form_with(model: article_post, local: true) do |form| %>
2
2
  <div class="row">
3
3
  <div class="col-md-3">
4
4
 
@@ -8,11 +8,11 @@
8
8
  </div>
9
9
  <div class="panel-body">
10
10
  <div class="form-group">
11
- <%= phc_press_article_post.label :pststatus, "Post Status" %>
12
- <%= phc_press_article_post.select( :pststatus, [['Draft','draft'],['Published','published'],['Review','review']], {}, {class: "form-control form-control-sm"}) %>
11
+ <%= form.label :pststatus, "Post Status" %>
12
+ <%= form.select( :pststatus, [['Draft','draft'],['Published','published'],['Review','review']], {}, {class: "form-control form-control-sm"}) %>
13
13
  </div>
14
14
  <div class="actions">
15
- <%= phc_press_article_post.submit class: "btn btn-primary waves-effect" %>
15
+ <%= form.submit class: "btn btn-primary waves-effect" %>
16
16
  </div>
17
17
  </div>
18
18
  </div>
@@ -23,13 +23,13 @@
23
23
  </div>
24
24
  <div class="panel-body">
25
25
  <div class="form-group">
26
- <%= phc_press_article_post.label :pstimage, "Featured Image" %>
27
- <%= phc_press_article_post.file_field :pstimage, class: "form-control" %>
26
+ <%= form.label :pstimage, "Featured Image" %>
27
+ <%= form.file_field :pstimage, class: "form-control" %>
28
28
  </div>
29
- <% if phc_press_article_post.object.pstimage? %>
30
- <%= image_tag phc_press_article_post.object.pstimage_url, class: "img-responsive img-thumbnail" %>
31
- <%= phc_press_article_post.label :remove_pstimage %>
32
- <%= phc_press_article_post.check_box :remove_pstimage %>
29
+ <% if form.object.pstimage? %>
30
+ <%= image_tag form.object.pstimage_url, class: "img-responsive img-thumbnail" %>
31
+ <%= form.label :remove_pstimage %>
32
+ <%= form.check_box :remove_pstimage %>
33
33
  <% end %>
34
34
  </div>
35
35
  </div>
@@ -39,7 +39,7 @@
39
39
  <h4 class="panel-title">Post Categories</h4>
40
40
  </div>
41
41
  <div class="panel-body">
42
- <%= phc_press_article_post.collection_check_boxes :category_ids, Phcpress::Modules::Category.all, :id, :catname do |post_category| %>
42
+ <%= form.collection_check_boxes :category_ids, Phcpress::Article::Category.where(org_id: current_user.org_id), :id, :catname do |post_category| %>
43
43
  <%= post_category.check_box %>
44
44
  <%= post_category.label %></br>
45
45
  <% end %>
@@ -52,17 +52,6 @@
52
52
  <!-- PHCNotifi Render Validation -->
53
53
  <%= render 'phcnotifi/validations', :object => @article_post %>
54
54
  <!-- PHCNotifi Render Validation -->
55
- <div class="panel panel-inverse">
56
- <div class="panel-heading">
57
- <h4 class="panel-title">Article TItle</h4>
58
- </div>
59
- <div class="panel-body">
60
- <div class="form-group">
61
- <%= phc_press_article_post.label :psttitle, "Article Title" %>
62
- <%= phc_press_article_post.text_field :psttitle, class: "form-control" %>
63
- </div>
64
- </div>
65
- </div>
66
55
 
67
56
  <div class="panel panel-inverse">
68
57
  <div class="panel-heading">
@@ -73,9 +62,13 @@
73
62
  </div>
74
63
  <h4 class="panel-title"><%= yield(:phc_title_tagline) %></h4>
75
64
  </div>
76
- <div class="panel-body panel-form">
65
+ <div class="panel-body ">
66
+ <div class="form-group">
67
+ <%= form.label :psttittle, "Article Title" %>
68
+ <%= form.text_field :psttittle, class: "form-control" %>
69
+ </div>
77
70
  <div class="form-group">
78
- <%= phc_press_article_post.text_area :psttext, :class => "ckeditor form-control", :id => "editor1", :rows => 20, :cols => 60 %>
71
+ <%= form.text_area :psttext, :class => "ckeditor form-control", :id => "editor1", :rows => 20, :cols => 60 %>
79
72
  </div>
80
73
  </div>
81
74
  </div>
@@ -1,33 +1,23 @@
1
1
  <!-- Title System -->
2
2
  <% phc_title "Article Manager" %>
3
3
  <% phc_title_tagline "Update Article" %>
4
- <% phc_breadcrumb_one link_to "Article Index", phcpress.article_posts_path %>
5
- <% phc_breadcrumb_two yield(:phc_title_tagline) %>
4
+ <% phc_breadcrumb_one yield(:phc_title) %>
5
+ <% phc_breadcrumb_two link_to "Article Index", phcpress.article_posts_path %>
6
+ <% phc_breadcrumb_three yield(:phc_title_tagline) %>
6
7
  <!-- Title System -->
7
8
 
9
+ <!-- Page Bradcrumbs -->
10
+ <ol class="breadcrumb pull-right">
11
+ <li class="breadcrumb-item"><%= yield(:phc_breadcrumb_one) %></li>
12
+ <li class="breadcrumb-item"><%= yield(:phc_breadcrumb_two) %></li>
13
+ <li class="breadcrumb-item active"><%= yield(:phc_breadcrumb_three) %></li>
14
+ </ol>
15
+ <!-- Page Bradcrumbs -->
16
+
8
17
  <!-- Page Header -->
9
- <div class="row wrapper border-bottom white-bg page-heading">
10
- <div class="col-sm-8">
11
- <h2><%= yield(:phc_title) %></h2>
12
- <!-- Bread Crumb -->
13
- <ol class="breadcrumb">
14
- <li><%= yield(:phc_breadcrumb_one) %></li>
15
- <li class="active"><%= yield(:phc_breadcrumb_two) %></li>
16
- </ol>
17
- <!-- Bread Crumb -->
18
- </div>
19
- <div class="col-sm-4">
20
- <div class="title-action">
21
- <%= link_to phcpress.article_posts_path, class: "btn btn-default" do %>
22
- <i class="fa fa fa-arrow-left"></i> Back to Article Index
23
- <% end %>
24
- </div>
25
- </div>
26
- </div>
18
+ <h1 class="page-header"><%= yield(:phc_title) %></h1>
27
19
  <!-- Page Header -->
28
-
20
+
29
21
  <!-- Page Content -->
30
- <div class="wrapper wrapper-content animated fadeInRight">
31
- <%= render 'form', article_post: @article_post %>
32
- </div>
22
+ <%= render 'form', article_post: @article_post %>
33
23
  <!-- Page Content -->