phcdevworks_scripts 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/MIT-LICENSE +20 -0
- data/README.md +35 -0
- data/Rakefile +32 -0
- data/app/assets/config/phcdevworks_scripts_manifest.js +1 -0
- data/app/assets/javascripts/phcdevworks_scripts/application.js +2 -0
- data/app/assets/javascripts/phcdevworks_scripts/script/versions.coffee +3 -0
- data/app/assets/stylesheets/phcdevworks_scripts/application.scss +2 -0
- data/app/assets/stylesheets/phcdevworks_scripts/script/authors.css +4 -0
- data/app/assets/stylesheets/phcdevworks_scripts/script/extensions.css +4 -0
- data/app/assets/stylesheets/phcdevworks_scripts/script/listings.css +4 -0
- data/app/assets/stylesheets/phcdevworks_scripts/script/urls.css +4 -0
- data/app/assets/stylesheets/phcdevworks_scripts/script/versions.scss +3 -0
- data/app/assets/stylesheets/phcdevworks_scripts/snippet/posts.css +4 -0
- data/app/assets/stylesheets/phcdevworks_scripts/snippet/urls.css +4 -0
- data/app/controllers/phcdevworks_scripts/application_controller.rb +13 -0
- data/app/controllers/phcdevworks_scripts/script/authors_controller.rb +82 -0
- data/app/controllers/phcdevworks_scripts/script/extensions_controller.rb +82 -0
- data/app/controllers/phcdevworks_scripts/script/listings_controller.rb +82 -0
- data/app/controllers/phcdevworks_scripts/script/urls_controller.rb +77 -0
- data/app/controllers/phcdevworks_scripts/script/versions_controller.rb +82 -0
- data/app/controllers/phcdevworks_scripts/snippet/posts_controller.rb +80 -0
- data/app/controllers/phcdevworks_scripts/snippet/urls_controller.rb +76 -0
- data/app/helpers/phcdevworks_scripts/application_helper.rb +4 -0
- data/app/helpers/phcdevworks_scripts/script/authors_helper.rb +4 -0
- data/app/helpers/phcdevworks_scripts/script/extensions_helper.rb +4 -0
- data/app/helpers/phcdevworks_scripts/script/listings_helper.rb +4 -0
- data/app/helpers/phcdevworks_scripts/script/urls_helper.rb +4 -0
- data/app/helpers/phcdevworks_scripts/script/versions_helper.rb +4 -0
- data/app/helpers/phcdevworks_scripts/snippet/posts_helper.rb +4 -0
- data/app/helpers/phcdevworks_scripts/snippet/urls_helper.rb +4 -0
- data/app/jobs/phcdevworks_scripts/application_job.rb +4 -0
- data/app/mailers/phcdevworks_scripts/application_mailer.rb +6 -0
- data/app/models/phcdevworks_scripts/application_record.rb +5 -0
- data/app/models/phcdevworks_scripts/author_versions.rb +5 -0
- data/app/models/phcdevworks_scripts/extension_versions.rb +5 -0
- data/app/models/phcdevworks_scripts/listing_versions.rb +5 -0
- data/app/models/phcdevworks_scripts/script.rb +7 -0
- data/app/models/phcdevworks_scripts/script/author.rb +33 -0
- data/app/models/phcdevworks_scripts/script/extension.rb +32 -0
- data/app/models/phcdevworks_scripts/script/listing.rb +38 -0
- data/app/models/phcdevworks_scripts/script/url.rb +24 -0
- data/app/models/phcdevworks_scripts/script/version.rb +26 -0
- data/app/models/phcdevworks_scripts/scriptversion_versions.rb +5 -0
- data/app/models/phcdevworks_scripts/snippet.rb +7 -0
- data/app/models/phcdevworks_scripts/snippet/post.rb +25 -0
- data/app/models/phcdevworks_scripts/snippet/url.rb +16 -0
- data/app/models/phcdevworks_scripts/url_versions.rb +5 -0
- data/app/views/layouts/phcdevworks_scripts/application.html.erb +94 -0
- data/app/views/layouts/phcdevworks_scripts/components/backend/footer/_footer.html.erb +16 -0
- data/app/views/layouts/phcdevworks_scripts/components/backend/navigation/_top_menu.html.erb +37 -0
- data/app/views/layouts/phcdevworks_scripts/components/backend/sidebars/_side_menu.html.erb +183 -0
- data/app/views/phcdevworks_scripts/script/authors/_form.html.erb +32 -0
- data/app/views/phcdevworks_scripts/script/authors/edit.html.erb +37 -0
- data/app/views/phcdevworks_scripts/script/authors/index.html.erb +63 -0
- data/app/views/phcdevworks_scripts/script/authors/new.html.erb +37 -0
- data/app/views/phcdevworks_scripts/script/authors/show.html.erb +49 -0
- data/app/views/phcdevworks_scripts/script/extensions/_form.html.erb +28 -0
- data/app/views/phcdevworks_scripts/script/extensions/edit.html.erb +37 -0
- data/app/views/phcdevworks_scripts/script/extensions/index.html.erb +59 -0
- data/app/views/phcdevworks_scripts/script/extensions/new.html.erb +37 -0
- data/app/views/phcdevworks_scripts/script/extensions/show.html.erb +49 -0
- data/app/views/phcdevworks_scripts/script/listings/_form.html.erb +62 -0
- data/app/views/phcdevworks_scripts/script/listings/edit.html.erb +35 -0
- data/app/views/phcdevworks_scripts/script/listings/index.html.erb +62 -0
- data/app/views/phcdevworks_scripts/script/listings/new.html.erb +36 -0
- data/app/views/phcdevworks_scripts/script/listings/show.html.erb +48 -0
- data/app/views/phcdevworks_scripts/script/urls/_form.html.erb +36 -0
- data/app/views/phcdevworks_scripts/script/urls/edit.html.erb +36 -0
- data/app/views/phcdevworks_scripts/script/urls/index.html.erb +61 -0
- data/app/views/phcdevworks_scripts/script/urls/new.html.erb +37 -0
- data/app/views/phcdevworks_scripts/script/urls/show.html.erb +49 -0
- data/app/views/phcdevworks_scripts/script/versions/_form.html.erb +20 -0
- data/app/views/phcdevworks_scripts/script/versions/edit.html.erb +37 -0
- data/app/views/phcdevworks_scripts/script/versions/index.html.erb +57 -0
- data/app/views/phcdevworks_scripts/script/versions/new.html.erb +37 -0
- data/app/views/phcdevworks_scripts/script/versions/show.html.erb +49 -0
- data/app/views/phcdevworks_scripts/snippet/posts/_form.html.erb +26 -0
- data/app/views/phcdevworks_scripts/snippet/posts/edit.html.erb +39 -0
- data/app/views/phcdevworks_scripts/snippet/posts/index.html.erb +68 -0
- data/app/views/phcdevworks_scripts/snippet/posts/new.html.erb +39 -0
- data/app/views/phcdevworks_scripts/snippet/posts/show.html.erb +71 -0
- data/app/views/phcdevworks_scripts/snippet/urls/_form.html.erb +22 -0
- data/app/views/phcdevworks_scripts/snippet/urls/edit.html.erb +39 -0
- data/app/views/phcdevworks_scripts/snippet/urls/index.html.erb +66 -0
- data/app/views/phcdevworks_scripts/snippet/urls/new.html.erb +39 -0
- data/app/views/phcdevworks_scripts/snippet/urls/show.html.erb +71 -0
- data/config/initializers/friendly_id.rb +107 -0
- data/config/routes.rb +32 -0
- data/db/migrate/20170509002355_create_phcdevworks_scripts_friendly_id_slugs.rb +18 -0
- data/db/migrate/20170517064030_create_phcdevworks_scripts_extension_versions.rb +17 -0
- data/db/migrate/20170517064049_create_phcdevworks_scripts_listing_versions.rb +17 -0
- data/db/migrate/20170517064114_create_phcdevworks_scripts_scriptversion_versions.rb +17 -0
- data/db/migrate/20170517064150_create_phcdevworks_scripts_url_versions.rb +17 -0
- data/db/migrate/20170517064208_create_phcdevworks_scripts_author_versions.rb +17 -0
- data/db/migrate/20170517064427_create_phcdevworks_scripts_licence_versions.rb +17 -0
- data/db/migrate/20190818022002_create_phcdevworks_scripts_snippet_posts.rb +16 -0
- data/db/migrate/20190818022024_create_phcdevworks_scripts_snippet_urls.rb +17 -0
- data/db/migrate/20190818022939_create_phcdevworks_scripts_script_authors.rb +18 -0
- data/db/migrate/20190818023353_create_phcdevworks_scripts_script_listings.rb +27 -0
- data/db/migrate/20190818023709_create_phcdevworks_scripts_script_extensions.rb +17 -0
- data/db/migrate/20190818023911_create_phcdevworks_scripts_script_urls.rb +21 -0
- data/db/migrate/20190818031653_create_phcdevworks_scripts_script_versions.rb +15 -0
- data/lib/phcdevworks_scripts.rb +5 -0
- data/lib/phcdevworks_scripts/engine.rb +33 -0
- data/lib/phcdevworks_scripts/version.rb +3 -0
- data/lib/tasks/phcdevworks_scripts_tasks.rake +4 -0
- metadata +352 -0
@@ -0,0 +1,24 @@
|
|
1
|
+
module PhcdevworksScripts
|
2
|
+
class Script::Url < ApplicationRecord
|
3
|
+
|
4
|
+
# Paper Trail Initialize
|
5
|
+
has_paper_trail :class_name => 'PhcdevworksScripts::UrlVersions'
|
6
|
+
|
7
|
+
# Relationships
|
8
|
+
belongs_to :listing, class_name: 'PhcdevworksScripts::Script::Listing'
|
9
|
+
belongs_to :extension, class_name: 'PhcdevworksScripts::Script::Extension'
|
10
|
+
belongs_to :version, class_name: 'PhcdevworksScripts::Script::Version', optional: true
|
11
|
+
|
12
|
+
# Form Fields Validation
|
13
|
+
validates :script_cdn_url,
|
14
|
+
presence: true,
|
15
|
+
format: { with: URI::regexp(%w(http https)), message: "Please follow this URL format http or https://www.**********.com" }
|
16
|
+
|
17
|
+
validates :script_cdn_url_release,
|
18
|
+
presence: true
|
19
|
+
|
20
|
+
validates :script_cdn_url_cdn_update,
|
21
|
+
presence: true
|
22
|
+
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
module PhcdevworksScripts
|
2
|
+
class Script::Version < ApplicationRecord
|
3
|
+
|
4
|
+
# Clean URL Initialize
|
5
|
+
extend FriendlyId
|
6
|
+
|
7
|
+
# Paper Trail Initialize
|
8
|
+
has_paper_trail :class_name => 'PhcdevworksScripts::ScriptversionVersions'
|
9
|
+
|
10
|
+
# Relationships
|
11
|
+
has_many :listings, class_name: 'PhcdevworksScripts::Script::Listing', :through => :urls
|
12
|
+
has_many :urls, class_name: 'PhcdevworksScripts::Script::Url'
|
13
|
+
|
14
|
+
# Form Fields Validation
|
15
|
+
validates :script_version_number,
|
16
|
+
presence: true
|
17
|
+
|
18
|
+
# Clean URL Define
|
19
|
+
friendly_id :phc_nice_url_slug, use: [:slugged, :finders]
|
20
|
+
|
21
|
+
def phc_nice_url_slug
|
22
|
+
[:script_version_number]
|
23
|
+
end
|
24
|
+
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
module PhcdevworksScripts
|
2
|
+
class Snippet::Post < ApplicationRecord
|
3
|
+
|
4
|
+
# Clean URL Initialize
|
5
|
+
extend FriendlyId
|
6
|
+
|
7
|
+
# Relationships
|
8
|
+
has_many :urls, class_name: 'PhcdevworksScripts::Script::Url'
|
9
|
+
|
10
|
+
# Form Fields Validation
|
11
|
+
validates :snippet_title,
|
12
|
+
presence: true
|
13
|
+
|
14
|
+
validates :snippet_code,
|
15
|
+
presence: true
|
16
|
+
|
17
|
+
# Clean URL Define
|
18
|
+
friendly_id :phc_nice_url_slug, use: [:slugged, :finders]
|
19
|
+
|
20
|
+
def phc_nice_url_slug
|
21
|
+
[:snippet_title]
|
22
|
+
end
|
23
|
+
|
24
|
+
end
|
25
|
+
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
module PhcdevworksScripts
|
2
|
+
class Snippet::Url < ApplicationRecord
|
3
|
+
|
4
|
+
# Include Core Validations
|
5
|
+
phc_domain_regx = URI::regexp(%w(http https))
|
6
|
+
|
7
|
+
# Relationships
|
8
|
+
belongs_to :snippet, class_name: 'PhcdevworksScripts::Script::Snippet'
|
9
|
+
|
10
|
+
# Form Fields Validation
|
11
|
+
validates :script_url,
|
12
|
+
presence: true,
|
13
|
+
format: { :with => phc_domain_regx, message: "Please follow this URL format http or https://www.**********.com" }
|
14
|
+
|
15
|
+
end
|
16
|
+
end
|
@@ -0,0 +1,94 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
|
5
|
+
<!-- SEO System -->
|
6
|
+
<% phc_seo_title "PHCScripts by PHCDevworks" %>
|
7
|
+
<% phc_seo_description "Script management engine for website script CDN and snippet listings." %>
|
8
|
+
<!-- SEO System -->
|
9
|
+
|
10
|
+
<!-- SEO and Site Description -->
|
11
|
+
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
12
|
+
<title><%= yield(:phc_seo_title) %></title>
|
13
|
+
<meta name="description" content="<%= yield(:phc_seo_description) %>">
|
14
|
+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" >
|
15
|
+
<link rel="canonical" href="http://phcdevworks.com">
|
16
|
+
<!-- SEO and Site Description -->
|
17
|
+
|
18
|
+
<!-- Rails Security Tags -->
|
19
|
+
<%= csrf_meta_tags %>
|
20
|
+
<%= csp_meta_tag %>
|
21
|
+
<!-- Rails Security Tags -->
|
22
|
+
|
23
|
+
<!-- CSS Styles -->
|
24
|
+
<%= stylesheet_link_tag 'phcdevworks_scripts/application', media: 'all', 'data-turbolinks-track': 'reload' %>
|
25
|
+
<!-- CSS Styles -->
|
26
|
+
|
27
|
+
<!-- Font -->
|
28
|
+
<link rel="stylesheet" type="text/css" href="https://fonts.googleapis.com/css?family=Open+Sans:300,400%7CRaleway:300,400,500,600,700%7CLato:300,400,400italic,600,700"/>
|
29
|
+
<!-- Font -->
|
30
|
+
|
31
|
+
</head>
|
32
|
+
<body>
|
33
|
+
|
34
|
+
<!-- Page Container -->
|
35
|
+
<div id="page-container" class="fade page-sidebar-fixed page-header-fixed">
|
36
|
+
|
37
|
+
<!-- Page Header -->
|
38
|
+
<div id="header" class="header navbar-default">
|
39
|
+
<%= render 'layouts/phcdevworks_scripts/components/backend/navigation/top_menu' %>
|
40
|
+
</div>
|
41
|
+
<!-- Page Header -->
|
42
|
+
|
43
|
+
<!-- Page Sidebar -->
|
44
|
+
<div id="sidebar" class="sidebar">
|
45
|
+
<%= render 'layouts/phcdevworks_scripts/components/backend/sidebars/side_menu' %>
|
46
|
+
</div>
|
47
|
+
<div class="sidebar-bg"></div>
|
48
|
+
<!-- Page Sidebar -->
|
49
|
+
|
50
|
+
<!-- Page Content -->
|
51
|
+
<div id="content" class="content">
|
52
|
+
<%= render 'phcdevworks_notifications/bootstrap/notifications' %>
|
53
|
+
<%= yield %>
|
54
|
+
</div>
|
55
|
+
<!-- Page Content -->
|
56
|
+
|
57
|
+
<!-- Footer Content -->
|
58
|
+
<div id="footer" class="footer mb-4">
|
59
|
+
<%= render 'layouts/phcdevworks_scripts/components/backend/footer/footer' %>
|
60
|
+
</div>
|
61
|
+
<!-- Footer Content -->
|
62
|
+
|
63
|
+
</div>
|
64
|
+
<!-- Page Container -->
|
65
|
+
|
66
|
+
<!-- JavaScript -->
|
67
|
+
<%= javascript_include_tag "phcdevworks_scripts/application", 'data-turbolinks-track': 'reload' %>
|
68
|
+
<!-- JavaScript -->
|
69
|
+
|
70
|
+
<!-- JavaScript CKEditor -->
|
71
|
+
<script>
|
72
|
+
ClassicEditor.create( document.querySelector( '#editor' ) )
|
73
|
+
.then( editor => {
|
74
|
+
window.editor = editor;
|
75
|
+
const wordCountPlugin = editor.plugins.get( 'WordCount' );
|
76
|
+
const wordCountWrapper = document.getElementById( 'word-count' );
|
77
|
+
wordCountWrapper.appendChild( wordCountPlugin.wordCountContainer );
|
78
|
+
} )
|
79
|
+
.catch( err => {
|
80
|
+
console.error( err.stack );
|
81
|
+
} );
|
82
|
+
</script>
|
83
|
+
<!-- JavaScript CKEditor -->
|
84
|
+
|
85
|
+
<!-- JavaScript Loader -->
|
86
|
+
<script>
|
87
|
+
$(document).ready(function() {
|
88
|
+
App.init();
|
89
|
+
});
|
90
|
+
</script>
|
91
|
+
<!-- JavaScript Loader -->
|
92
|
+
|
93
|
+
</body>
|
94
|
+
</html>
|
@@ -0,0 +1,16 @@
|
|
1
|
+
<!-- Footer Content - Left -->
|
2
|
+
<span>
|
3
|
+
<!-- Footer Content - Left - Time in Production -->
|
4
|
+
<i class="fab fa-osi font-weight-bolder"></i> 2012-<%= Time.now.year %> -
|
5
|
+
<span class="font-weight-bold">PHC</span>Devworks Scripts -
|
6
|
+
Engine v<%= Gem.loaded_specs["phcdevworks_scripts"].version.to_s %>
|
7
|
+
<!-- Footer Content - Left - Time in Production -->
|
8
|
+
</span>
|
9
|
+
<!-- Footer Content - Left -->
|
10
|
+
|
11
|
+
<!-- Footer Content - Right -->
|
12
|
+
<span class="float-right">
|
13
|
+
Developed with <i class="fas fa-heart hanna_hearts"></i> by
|
14
|
+
<a class="phcnet_copyright text-dark" href="https://phcdevworks.com/"><u><span class="font-weight-bold">PHC</span>Devworks</u></a>
|
15
|
+
</span>
|
16
|
+
<!-- Footer Content - Right -->
|
@@ -0,0 +1,37 @@
|
|
1
|
+
<!-- Topbar - Navigation Header -->
|
2
|
+
<div class="navbar-header">
|
3
|
+
<%= link_to phcdevworks_scripts.script_listings_path, class: "navbar-brand" do %>
|
4
|
+
<b>PHCDevworks</b> Scripts
|
5
|
+
<% end %>
|
6
|
+
<button type="button" class="navbar-toggle" data-click="sidebar-toggled">
|
7
|
+
<span class="icon-bar"></span>
|
8
|
+
<span class="icon-bar"></span>
|
9
|
+
<span class="icon-bar"></span>
|
10
|
+
</button>
|
11
|
+
</div>
|
12
|
+
<!-- Topbar - Navigation Header -->
|
13
|
+
|
14
|
+
<!-- Topbar - Navigation Main -->
|
15
|
+
<% if current_user %>
|
16
|
+
<ul class="navbar-nav navbar-right">
|
17
|
+
|
18
|
+
<!-- Topbar - Navigation Main - User Menu -->
|
19
|
+
<li class="dropdown navbar-user">
|
20
|
+
<a href="javascript:;" class="dropdown-toggle" data-toggle="dropdown">
|
21
|
+
<%= image_tag current_user.gravatar_url %>
|
22
|
+
<span class="d-none d-md-inline"><%= current_user.firstname + ' ' + current_user.lastname %></span> <b class="caret"></b>
|
23
|
+
</a>
|
24
|
+
<div class="dropdown-menu dropdown-menu-right">
|
25
|
+
<%= link_to phcdevworks_accounts.edit_user_registration_path, class: "dropdown-item" do %>
|
26
|
+
<i class="fad fa-cogs"></i> Account Settings
|
27
|
+
<% end %>
|
28
|
+
<%= link_to phcdevworks_accounts.destroy_user_session_path, method: :delete, class: "dropdown-item" do %>
|
29
|
+
<i class="fad fa-sign-out-alt"></i> Logout
|
30
|
+
<% end %>
|
31
|
+
</div>
|
32
|
+
</li>
|
33
|
+
<!-- Topbar - Navigation Main - User Menu -->
|
34
|
+
|
35
|
+
</ul>
|
36
|
+
<% end %>
|
37
|
+
<!-- Topbar - Navigation Main -->
|
@@ -0,0 +1,183 @@
|
|
1
|
+
<!-- Sidebar for PHCDevworks Engines -->
|
2
|
+
<div data-scrollbar="true" data-height="100%">
|
3
|
+
|
4
|
+
<!-- Sidebar - User Profile Menu -->
|
5
|
+
<ul class="nav">
|
6
|
+
<% if current_user %>
|
7
|
+
<li class="nav-profile">
|
8
|
+
<a href="javascript:;" data-toggle="nav-profile">
|
9
|
+
<div class="cover with-shadow"></div>
|
10
|
+
<div class="image">
|
11
|
+
<%= image_tag current_user.gravatar_url %>
|
12
|
+
</div>
|
13
|
+
<div class="info">
|
14
|
+
<b class="caret pull-right"></b>
|
15
|
+
<%= current_user.firstname + ' ' + current_user.lastname %>
|
16
|
+
<small><%= current_user.username %></small>
|
17
|
+
</div>
|
18
|
+
</a>
|
19
|
+
</li>
|
20
|
+
<li>
|
21
|
+
<ul class="nav nav-profile">
|
22
|
+
<li>
|
23
|
+
<%= link_to phcdevworks_accounts.edit_user_registration_path do %>
|
24
|
+
<i class="fad fa-cogs"></i> Account Settings
|
25
|
+
<% end %>
|
26
|
+
</li>
|
27
|
+
<li>
|
28
|
+
<%= link_to phcdevworks_accounts.destroy_user_session_path do %>
|
29
|
+
<i class="fad fa-sign-out-alt"></i> Logout
|
30
|
+
<% end %>
|
31
|
+
</li>
|
32
|
+
</ul>
|
33
|
+
</li>
|
34
|
+
<% end %>
|
35
|
+
</ul>
|
36
|
+
<!-- Sidebar - User Profile Menu -->
|
37
|
+
|
38
|
+
<!-- Sidebar - Sidebar Navigation -->
|
39
|
+
<ul class="nav">
|
40
|
+
|
41
|
+
<% if defined?phcdevworks_members %>
|
42
|
+
<!-- Sidebar - Sidebar Navigation - PHCDevworks Members -->
|
43
|
+
<li class="nav-header">Membership Manager</li>
|
44
|
+
<li class="has-sub">
|
45
|
+
<a href="javascript:;">
|
46
|
+
<b class="caret"></b>
|
47
|
+
<i class="fad fa-users"></i>
|
48
|
+
<span>Member's Data</span>
|
49
|
+
</a>
|
50
|
+
<ul class="sub-menu">
|
51
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_members/member/profiles') %>"><%= link_to('Profile Index', phcdevworks_members.member_profiles_path) %></li>
|
52
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_members/member/profiles#new') %>"><%= link_to('New Member Profile', phcdevworks_members.new_member_profile_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-list-alt"></i>
|
59
|
+
<span>Member's Directory</span>
|
60
|
+
</a>
|
61
|
+
<ul class="sub-menu">
|
62
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_members/directory/categories') %>"><%= link_to('Directory Index', phcdevworks_members.directory_categories_path) %></li>
|
63
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_members/directory/categories#new') %>"><%= link_to('New Directory Listing', phcdevworks_members.new_directory_category_path) %></li>
|
64
|
+
</ul>
|
65
|
+
</li>
|
66
|
+
<!-- Sidebar - Sidebar Navigation - PHCDevworks Members -->
|
67
|
+
<% end %>
|
68
|
+
|
69
|
+
<% if defined?phcdevworks_press %>
|
70
|
+
<!-- Sidebar - Sidebar Navigation - PHCPress CMS -->
|
71
|
+
<li class="nav-header">Article Management</li>
|
72
|
+
<li class="has-sub">
|
73
|
+
<a href="javascript:;">
|
74
|
+
<b class="caret"></b>
|
75
|
+
<i class="fad fa-newspaper"></i>
|
76
|
+
<span>Article Posts</span>
|
77
|
+
</a>
|
78
|
+
<ul class="sub-menu">
|
79
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_press/article/posts') %>"><%= link_to('Article Index', phcdevworks_press.article_posts_path) %></li>
|
80
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_press/article/posts#new') %>"><%= link_to('New Aritcle', phcdevworks_press.new_article_post_path) %></li>
|
81
|
+
</ul>
|
82
|
+
</li>
|
83
|
+
<li class="has-sub">
|
84
|
+
<a href="javascript:;">
|
85
|
+
<b class="caret"></b>
|
86
|
+
<i class="fad fa-sitemap"></i>
|
87
|
+
<span>Article Categories</span>
|
88
|
+
</a>
|
89
|
+
<ul class="sub-menu">
|
90
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_press/article/categories') %>"><%= link_to('Category Index', phcdevworks_press.article_categories_path) %></li>
|
91
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_press/article/categories#new') %>"><%= link_to('New Category', phcdevworks_press.new_article_category_path) %></li>
|
92
|
+
</ul>
|
93
|
+
</li>
|
94
|
+
<!-- Sidebar - Sidebar Navigation - PHCPress CMS -->
|
95
|
+
<% end %>
|
96
|
+
|
97
|
+
<% if defined?phcdevworks_scripts %>
|
98
|
+
<!-- Sidebar - Sidebar Navigation - PHCScripts CDN and Code Snippet Manager -->
|
99
|
+
<li class="nav-header">Script Management</li>
|
100
|
+
<li class="has-sub">
|
101
|
+
<a href="javascript:;">
|
102
|
+
<b class="caret"></b>
|
103
|
+
<i class="fad fa-laptop-code"></i>
|
104
|
+
<span>Script Posts</span>
|
105
|
+
</a>
|
106
|
+
<ul class="sub-menu">
|
107
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_scripts/script/listings') %>"><%= link_to "All Script Listings", phcdevworks_scripts.script_listings_path %></li>
|
108
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_scripts/script/listings#new') %>"><%= link_to "Add a New Listing", phcdevworks_scripts.new_script_listing_path %></li>
|
109
|
+
</ul>
|
110
|
+
</li>
|
111
|
+
<li class="has-sub">
|
112
|
+
<a href="javascript:;">
|
113
|
+
<b class="caret"></b>
|
114
|
+
<i class="fad fa-sitemap"></i>
|
115
|
+
<span>Script Extras</span>
|
116
|
+
</a>
|
117
|
+
<ul class="sub-menu">
|
118
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_scripts/script/authors') %>"><%= link_to "Script Authors", phcdevworks_scripts.script_authors_path %></li>
|
119
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_scripts/script/extensions') %>"><%= link_to "Script Extensions", phcdevworks_scripts.script_extensions_path %></li>
|
120
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_scripts/script/versions') %>"><%= link_to "Script Versions", phcdevworks_scripts.script_versions_path %></li>
|
121
|
+
</ul>
|
122
|
+
</li>
|
123
|
+
<li class="nav-header">Code Snippets</li>
|
124
|
+
<li class="has-sub">
|
125
|
+
<a href="javascript:;">
|
126
|
+
<b class="caret"></b>
|
127
|
+
<i class="fad fa-code"></i>
|
128
|
+
<span>Code Snippets</span>
|
129
|
+
</a>
|
130
|
+
<ul class="sub-menu">
|
131
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_scripts/script/posts') %>"><%= link_to 'Snippet Index', phcdevworks_scripts.snippet_posts_path %></li>
|
132
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_scripts/script/posts#new') %>"><%= link_to 'New Snippet', phcdevworks_scripts.new_snippet_post_path %></li>
|
133
|
+
</ul>
|
134
|
+
</li>
|
135
|
+
<!-- Sidebar - Sidebar Navigation - PHCScripts CDN and Code Snippet Manager -->
|
136
|
+
<% end %>
|
137
|
+
|
138
|
+
<% if current_user && current_user.admin? %>
|
139
|
+
<!-- Sidebar - Sidebar Navigation - PHCAccounts Admin Options -->
|
140
|
+
<li class="nav-header">User Administration</li>
|
141
|
+
<li class="has-sub">
|
142
|
+
<a href="javascript:;">
|
143
|
+
<b class="caret"></b>
|
144
|
+
<i class="fad fa-user"></i>
|
145
|
+
<span>Admin</span>
|
146
|
+
</a>
|
147
|
+
<ul class="sub-menu">
|
148
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_accounts/admin/users') %>"><%= link_to 'User List', phcdevworks_accounts.admin_users_index_path %></li>
|
149
|
+
</ul>
|
150
|
+
</li>
|
151
|
+
<!-- Sidebar - Sidebar Navigation - PHCAccounts Admin Options -->
|
152
|
+
<% end %>
|
153
|
+
|
154
|
+
<% if current_user %>
|
155
|
+
<!-- Sidebar - Sidebar Navigation - PHCAccounts User Options -->
|
156
|
+
<li class="nav-header">Your Account</li>
|
157
|
+
<li class="has-sub">
|
158
|
+
<a href="javascript:;">
|
159
|
+
<b class="caret"></b>
|
160
|
+
<i class="fad fa-user"></i>
|
161
|
+
<span>Accounts Settings</span>
|
162
|
+
</a>
|
163
|
+
<ul class="sub-menu">
|
164
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_accounts/user/edit') %>"><%= link_to 'Settings', phcdevworks_accounts.edit_user_registration_path %></li>
|
165
|
+
<li class="<%= phc_menu_active_controller('phcdevworks_accounts/user/new') %>"><%= link_to 'Logout', phcdevworks_accounts.destroy_user_session_path, method: :delete %></li>
|
166
|
+
</ul>
|
167
|
+
</li>
|
168
|
+
<!-- Sidebar - Sidebar Navigation - PHCAccounts User Options -->
|
169
|
+
<% end %>
|
170
|
+
|
171
|
+
<!-- Sidebar - Sidebar Minifier -->
|
172
|
+
<li>
|
173
|
+
<a href="javascript:;" class="sidebar-minify-btn" data-click="sidebar-minify">
|
174
|
+
<i class="fa fa-angle-double-left"></i>
|
175
|
+
</a>
|
176
|
+
</li>
|
177
|
+
<!-- Sidebar - Sidebar Minifier -->
|
178
|
+
|
179
|
+
</ul>
|
180
|
+
<!-- Sidebar - Sidebar Navigation -->
|
181
|
+
|
182
|
+
</div>
|
183
|
+
<!-- Sidebar for PHCDevworks Engines -->
|