phcdevworks_scripts 2.1.0 → 2.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7cef9eea0db3030cc0211815a8f257c4895a09f207bd16f185bf82660348382b
4
- data.tar.gz: 892e6153c66b558278193633ed36c93925b9e69d17096a68aae5f3dfe5139152
3
+ metadata.gz: 58c16b0cb1907233ffbc303517a50af84a28dff914cbd108643e00eebf29c061
4
+ data.tar.gz: 2babc2c1a9cd864ee6c059a406ce6b4eef0234bfffca4b567ec2f9b82c17b702
5
5
  SHA512:
6
- metadata.gz: b4ebb9aa1794205ea88251a1e142a42a8a6f0e3b1ba25e18de0ef89ab92061bfc4760101a28cf5c07704d3121a75300720ba0f63f323e6c0771fc1798a282fc4
7
- data.tar.gz: 4670dc812072190c1f7118bde35102df1747d0749552d699680f0ae12f9dcdfb0635272b62f9d273b1d61d2bcfe14099c0e37b80f89d7204532b7529f3e1c659
6
+ metadata.gz: 97908f2c23758ce8d87221d802a44074fe87c3d68ff0a008ff76062494af9730a1a9e593bbe46f8235a829d27c84589f8ee26d6e5d5e4f14dca87f92b1459295
7
+ data.tar.gz: e0ba03c971ff984e51cd50cd14681591cd24d09ef4972f632b0b7074afb534950b7b08e40ef6a342bbd18cd5b760d81b42754abcea9defdd0368296a6d30cff6
@@ -16,6 +16,7 @@ module PhcdevworksScripts
16
16
 
17
17
  # GET /snippet/posts/1
18
18
  def show
19
+ @snippet_post = Snippet::Post.friendly.find(params[:id])
19
20
  end
20
21
 
21
22
  # GET /snippet/posts/new
@@ -61,7 +61,7 @@ module PhcdevworksScripts
61
61
 
62
62
  # Common Callbacks
63
63
  def set_snippet_url
64
- @snippet_url = Snippet::Url.friendly.find(params[:id])
64
+ @snippet_url = Snippet::Url.find(params[:id])
65
65
  end
66
66
 
67
67
  def snippet_post
@@ -23,10 +23,12 @@ module PhcdevworksScripts
23
23
  format: { with: URI::regexp(%w(http https)), message: "Please follow this URL format http or https://www.**********.com" }
24
24
 
25
25
  # Clean URL Define
26
- friendly_id :phc_nice_url_slug, use: [:slugged, :finders]
26
+ friendly_id :phcdev_script_author_nice_urls, use: [:slugged, :finders]
27
27
 
28
- def phc_nice_url_slug
29
- [:author_first_name, :author_last_name]
28
+ def phcdev_script_author_nice_urls
29
+ [
30
+ [:author_first_name, :author_last_name]
31
+ ]
30
32
  end
31
33
 
32
34
  end
@@ -22,9 +22,9 @@ module PhcdevworksScripts
22
22
  presence: true
23
23
 
24
24
  # Clean URL Define
25
- friendly_id :phc_nice_url_slug, use: [:slugged, :finders]
25
+ friendly_id :phcdev_script_extension_nice_urls, use: [:slugged, :finders]
26
26
 
27
- def phc_nice_url_slug
27
+ def phcdev_script_extension_nice_urls
28
28
  [:script_extension]
29
29
  end
30
30
 
@@ -28,9 +28,9 @@ module PhcdevworksScripts
28
28
  format: { with: URI::regexp(%w(http https)), message: "Please follow this URL format http or https://www.**********.com" }
29
29
 
30
30
  # Clean URL Define
31
- friendly_id :phc_nice_url_slug, use: [:slugged, :finders]
31
+ friendly_id :phcdev_script_listing_nice_urls, use: [:slugged, :finders]
32
32
 
33
- def phc_nice_url_slug
33
+ def phcdev_script_listing_nice_urls
34
34
  [:listing_title]
35
35
  end
36
36
 
@@ -16,9 +16,9 @@ module PhcdevworksScripts
16
16
  presence: true
17
17
 
18
18
  # Clean URL Define
19
- friendly_id :phc_nice_url_slug, use: [:slugged, :finders]
19
+ friendly_id :phcdev_script_version_nice_urls, use: [:slugged, :finders]
20
20
 
21
- def phc_nice_url_slug
21
+ def phcdev_script_version_nice_urls
22
22
  [:script_version_number]
23
23
  end
24
24
 
@@ -15,9 +15,9 @@ module PhcdevworksScripts
15
15
  presence: true
16
16
 
17
17
  # Clean URL Define
18
- friendly_id :phc_nice_url_slug, use: [:slugged, :finders]
18
+ friendly_id :phcdev_snippet_post_nice_urls, use: [:slugged, :finders]
19
19
 
20
- def phc_nice_url_slug
20
+ def phcdev_snippet_post_nice_urls
21
21
  [:snippet_title]
22
22
  end
23
23
 
@@ -1,6 +1,6 @@
1
1
  module PhcdevworksScripts
2
2
  class Snippet::Url < ApplicationRecord
3
-
3
+
4
4
  # Include Core Validations
5
5
  phc_domain_regx = URI::regexp(%w(http https))
6
6
 
@@ -11,6 +11,6 @@ module PhcdevworksScripts
11
11
  validates :script_url,
12
12
  presence: true,
13
13
  format: { :with => phc_domain_regx, message: "Please follow this URL format http or https://www.**********.com" }
14
-
14
+
15
15
  end
16
16
  end
@@ -1,7 +1,7 @@
1
1
  <%= form_with(model: script_extension, local: true) do |form| %>
2
2
 
3
3
  <!-- PHCNotifi Render Validation -->
4
- <%= render 'phcdevworks_notifications/bootstrap/validations', :object => @script_extension %>
4
+ <%= render "phcdevworks_notifications/bootstrap/validations", :object => @script_extension %>
5
5
  <!-- PHCNotifi Render Validation -->
6
6
 
7
7
  <!-- Form Input Fields -->
@@ -1,7 +1,7 @@
1
1
  <%= form_with(model: script_listing, local: true) do |form| %>
2
2
 
3
3
  <!-- PHCNotifi Render Validation -->
4
- <%= render 'phcdevworks_notifications/bootstrap/validations', :object => @script_listing %>
4
+ <%= render "phcdevworks_notifications/bootstrap/validations", :object => @script_listing %>
5
5
  <!-- PHCNotifi Render Validation -->
6
6
 
7
7
  <!-- Form Input Fields -->
@@ -45,11 +45,11 @@
45
45
  </div>
46
46
  <div class="form-group field_with_errorss">
47
47
  <label>Script Author</label>
48
- <%= collection_select(:script_listing, :author_id, PhcdevworksScripts::Script::Author.order('author_first_name'), :id, :author_first_name, {}, {class: "form-control"}) %>
48
+ <%= collection_select(:script_listing, :author_id, PhcdevworksScripts::Script::Author.order("author_first_name"), :id, :author_first_name, {}, {class: "form-control"}) %>
49
49
  </div>
50
50
  <div class="form-group field_with_errors">
51
51
  <%= form.label :listing_script_status, "Script Status" %>
52
- <%= form.select( :listing_script_status, [['Active','Active'],['Outdated','Out Dated'],['Deactivated','Not Active']], {}, {class: "form-control"}) %>
52
+ <%= form.select( :listing_script_status, [["Active","Active"],["Outdated","Out Dated"],["Deactivated","Not Active"]], {}, {class: "form-control"}) %>
53
53
  </div>
54
54
  <!-- Form Input Fields -->
55
55
 
@@ -1,13 +1,13 @@
1
1
  <%= form_with(model: [ @script_listing, @script_url], url: form_url, local: true) do |form| %>
2
2
 
3
3
  <!-- PHCNotifi Render Validation -->
4
- <%= render 'phcdevworks_notifications/bootstrap/validations', :object => @script_url %>
4
+ <%= render "phcdevworks_notifications/bootstrap/validations", :object => @script_url %>
5
5
  <!-- PHCNotifi Render Validation -->
6
6
 
7
7
  <!-- Form Input Fields -->
8
8
  <div class="form-group field_with_errors">
9
9
  <%= form.label :script_cdn_url, "Script URL" %>
10
- <%= form.text_field :script_cdn_url, placeholder: "Script URL", class: "form-control" %>
10
+ <%= form.text_field :script_cdn_url, placeholder: "Script URL", class: "form-control" %>
11
11
  </div>
12
12
  <div class="form-group field_with_errors">
13
13
  <%= form.label :script_cdn_url_release, "Initial Release" %>
@@ -19,11 +19,11 @@
19
19
  </div>
20
20
  <div class="form-group field_with_errorss">
21
21
  <label>Script Version</label>
22
- <%= collection_select(:script_url, :version_id, PhcdevworksScripts::Script::Version.order('script_version_number'), :id, :script_version_number, {}, {class: "form-control"}) %>
22
+ <%= collection_select(:script_url, :version_id, PhcdevworksScripts::Script::Version.order("script_version_number"), :id, :script_version_number, {}, {class: "form-control"}) %>
23
23
  </div>
24
24
  <div class="form-group field_with_errorss">
25
25
  <label>Script Extensions</label>
26
- <%= collection_select(:script_url, :extension_id, PhcdevworksScripts::Script::Extension.order('script_extension_name'), :id, :script_extension, {}, {class: "form-control"}) %>
26
+ <%= collection_select(:script_url, :extension_id, PhcdevworksScripts::Script::Extension.order("script_extension_name"), :id, :script_extension, {}, {class: "form-control"}) %>
27
27
  </div>
28
28
  <!-- Form Input Fields -->
29
29
 
@@ -1,13 +1,13 @@
1
1
  <%= form_with(model: script_version, local: true) do |form| %>
2
2
 
3
3
  <!-- PHCNotifi Render Validation -->
4
- <%= render 'phcdevworks_notifications/bootstrap/validations', :object => @script_version %>
4
+ <%= render "phcdevworks_notifications/bootstrap/validations", :object => @script_version %>
5
5
  <!-- PHCNotifi Render Validation -->
6
6
 
7
7
  <!-- Form Input Fields -->
8
8
  <div class="form-group field_with_errors">
9
9
  <%= form.label :script_version_number, "Version Number" %>
10
- <%= form.text_field :script_version_number, placeholder: "Version Number", class: "form-control" %>
10
+ <%= form.text_field :script_version_number, placeholder: "Version Number", class: "form-control" %>
11
11
  </div>
12
12
  <!-- Form Input Fields -->
13
13
 
@@ -2,17 +2,17 @@
2
2
  <%= form_with(model: @snippet_post, local: true) do |form| %>
3
3
 
4
4
  <!-- PHCNotifi Render Validation -->
5
- <%= render 'phcdevworks_notifications/bootstrap/validations', :object => @snippet_post %>
5
+ <%= render "phcdevworks_notifications/bootstrap/validations", :object => @snippet_post %>
6
6
  <!-- PHCNotifi Render Validation -->
7
7
 
8
8
  <!-- Form Input Fields -->
9
9
  <div class="form-group field_with_errors">
10
10
  <%= form.label :snippet_title, "Snippet Title" %>
11
- <%= form.text_field :snippet_title, class: 'form-control', placeholder: 'Snippet Title' %>
11
+ <%= form.text_field :snippet_title, placeholder: "Snippet Title", class: "form-control" %>
12
12
  </div>
13
13
  <div class="form-group field_with_errors">
14
14
  <%= form.label :snippet_code, "Code Snippet" %>
15
- <%= form.text_area :snippet_code, class: 'form-control', placeholder: 'Code Snippet', rows: '10' %>
15
+ <%= form.text_area :snippet_code, placeholder: "Code Snippet", rows: "10", class: "form-control" %>
16
16
  </div>
17
17
  <!-- Form Input Fields -->
18
18
 
@@ -2,13 +2,13 @@
2
2
  <%= form_with(model: [ @script_snippet, @script_url], url: form_url, local: true) do |form| %>
3
3
 
4
4
  <!-- PHCNotifi Render Validation -->
5
- <%= render 'phcdevworks_notifications/bootstrap/validations', :object => @article_post %>
5
+ <%= render "phcdevworks_notifications/bootstrap/validations", :object => @article_post %>
6
6
  <!-- PHCNotifi Render Validation -->
7
7
 
8
8
  <!-- Form Input Fields -->
9
9
  <div class="form-group field_with_errors">
10
10
  <%= form.label :script_url %>
11
- <%= form.text_field :script_url, class: 'form-control', placeholder: 'Script Url' %>
11
+ <%= form.text_field :script_url, placeholder: "Script Url", class: "form-control" %>
12
12
  </div>
13
13
  <!-- Form Input Fields -->
14
14
 
@@ -1,3 +1,3 @@
1
1
  module PhcdevworksScripts
2
- VERSION = '2.1.0'
2
+ VERSION = '2.1.1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: phcdevworks_scripts
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - PHCDevworks
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-15 00:00:00.000000000 Z
11
+ date: 2019-09-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails