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,66 +0,0 @@
1
- <!-- Title System -->
2
- <% phc_title "PHCPress Plugin: Connections" %>
3
- <% phc_title_tagline "Connections Index" %>
4
- <% phc_breadcrumb_one yield(:phc_title_tagline) %>
5
- <!-- Title System -->
6
-
7
- <!-- Page Title Bar -->
8
- <section class="content-header">
9
- <!-- Page Title and BreadCrumb -->
10
- <h1><%= yield(:phc_title) %> <small><%= yield(:phc_title_tagline) %></small></h1>
11
- <ol class="breadcrumb">
12
- <li><%= yield(:phc_breadcrumb_one) %></li>
13
- <li class="active"><%= yield(:phc_breadcrumb_two) %></li>
14
- </ol>
15
- <!-- Page Title and BreadCrumb -->
16
- </section>
17
- <!-- Page Title Bar -->
18
-
19
- <!-- Main Content -->
20
- <section class="content">
21
- <div class="row">
22
- <div class="col-lg-12">
23
- <div class="box">
24
- <div class="box-header with-border">
25
- <h3 class="box-title"><%= yield(:phc_title) %></h3>
26
- </div>
27
- <div class="box-body">
28
-
29
- <!-- Index Table -->
30
- <div class="table-responsive">
31
- <table class="table table-bordered table-striped table-hover">
32
- <thead>
33
- <tr>
34
- <th>Category</th>
35
- <th>Posts</th>
36
- <th colspan="3"></th>
37
- </tr>
38
- </thead>
39
-
40
- <tbody>
41
- <% @modules_connections.each do |modules_connection| %>
42
- <tr>
43
- <td><%= modules_connection.category.catname %></td>
44
- <td><%= modules_connection.post.psttitle %></td>
45
- <td><%= link_to 'Show', modules_connection, class: "btn btn-primary btn-xs" %></td>
46
- <td><%= link_to 'Edit', edit_modules_connection_path(modules_connection), class: "btn btn-primary btn-xs" %></td>
47
- <td><%= link_to 'Destroy', modules_connection, class: "btn btn-primary btn-xs", method: :delete, data: { confirm: 'Are you sure?' } %></td>
48
- </tr>
49
- <% end %>
50
- </tbody>
51
- </table>
52
- </div>
53
- <!-- Index Table -->
54
-
55
- <!-- Panel Footer -->
56
- <div class="box-footer clearfix">
57
- <%= link_to 'New Connection', new_modules_connection_path, class: "btn btn-primary" %>
58
- </div>
59
- <!-- Panel Footer -->
60
-
61
- </div>
62
- </div>
63
- </div>
64
- </div>
65
- </section>
66
- <!-- Main Content -->
@@ -1,39 +0,0 @@
1
- <!-- Title System -->
2
- <% phc_title "PHCPress Plugin: Connections" %>
3
- <% phc_title_tagline "Create a New Plugin Connection" %>
4
- <% phc_breadcrumb_one link_to "Connection Index", phcpresspro.modules_connections_path %>
5
- <% phc_breadcrumb_two yield(:phc_title_tagline) %>
6
- <!-- Title System -->
7
-
8
- <!-- Page Title Bar -->
9
- <section class="content-header">
10
- <!-- Page Title and BreadCrumb -->
11
- <h1><%= yield(:phc_title) %> <small><%= yield(:phc_title_tagline) %></small></h1>
12
- <ol class="breadcrumb">
13
- <li><%= yield(:phc_breadcrumb_one) %></li>
14
- <li class="active"><%= yield(:phc_breadcrumb_two) %></li>
15
- </ol>
16
- <!-- Page Title and BreadCrumb -->
17
- </section>
18
- <!-- Page Title Bar -->
19
-
20
- <!-- Main Content -->
21
- <section class="content">
22
- <div class="row">
23
- <div class="col-lg-12">
24
- <div class="box">
25
- <div class="box-header with-border">
26
- <h3 class="box-title"><%= yield(:phc_title) %></h3>
27
- </div>
28
- <div class="box-body">
29
-
30
- <!-- Page Form (New) -->
31
- <%= render 'form', modules_connection: @modules_connection %>
32
- <!-- Page Form (New) -->
33
-
34
- </div>
35
- </div>
36
- </div>
37
- </div>
38
- </section>
39
- <!-- Main Content -->
@@ -1,50 +0,0 @@
1
- <!-- Title System -->
2
- <% phc_title "PHCPress Plugin: Connections" %>
3
- <% phc_title_tagline "Create a New Plugin Connection" %>
4
- <% phc_breadcrumb_one link_to "Connection Index", phcpresspro.modules_connections_path %>
5
- <% phc_breadcrumb_two yield(:phc_title_tagline) %>
6
- <!-- Title System -->
7
-
8
- <!-- Page Title Bar -->
9
- <section class="content-header">
10
- <!-- Page Title and BreadCrumb -->
11
- <h1><%= yield(:phc_title) %> <small><%= yield(:phc_title_tagline) %></small></h1>
12
- <ol class="breadcrumb">
13
- <li><%= yield(:phc_breadcrumb_one) %></li>
14
- <li class="active"><%= yield(:phc_breadcrumb_two) %></li>
15
- </ol>
16
- <!-- Page Title and BreadCrumb -->
17
- </section>
18
- <!-- Page Title Bar -->
19
-
20
- <!-- Main Content -->
21
- <section class="content">
22
- <div class="row">
23
- <div class="col-lg-12">
24
- <div class="box">
25
- <div class="box-header with-border">
26
- <h3 class="box-title"><%= yield(:phc_title) %></h3>
27
- </div>
28
- <div class="box-body">
29
-
30
- <!-- Show Content -->
31
- <p>
32
- <strong>Post:</strong>
33
- <%= @modules_connection.post_id %>
34
- </p>
35
-
36
- <p>
37
- <strong>Category:</strong>
38
- <%= @modules_connection.category_id %>
39
- </p>
40
-
41
- <%= link_to 'Edit', edit_modules_connection_path(@modules_connection) %> |
42
- <%= link_to 'Back', modules_connections_path %>
43
- <!-- Show Content -->
44
-
45
- </div>
46
- </div>
47
- </div>
48
- </div>
49
- </section>
50
- <!-- Main Content -->
@@ -1,17 +0,0 @@
1
- class CreatePhcpressModulesConnections < ActiveRecord::Migration[5.2]
2
- def change
3
- create_table :phcpress_modules_connections do |t|
4
-
5
- t.references :post
6
- t.references :category
7
-
8
- t.string :slug
9
-
10
- t.string :user_id
11
- t.string :org_id
12
-
13
- t.timestamps
14
-
15
- end
16
- end
17
- end