phcscriptcdn 0.9.5 → 0.9.6

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
  SHA1:
3
- metadata.gz: d8fa89609c5f62ffeeacdaff9cc5054e13bfa2ac
4
- data.tar.gz: beee306496faf4b4f997a476c7d6bc93abd08dfd
3
+ metadata.gz: 5ba4312be53efb01f933c61529b1ec21500bf43d
4
+ data.tar.gz: 03e1d2eb3febff37e745c16cfcb382f62b82fa6f
5
5
  SHA512:
6
- metadata.gz: 1c3aa06a800000200fe31c15224536fa22dfdeb2f9fe372d2a14e83fcf19926e331eb2082885291c31cb073544c3c6211d2bc6b77b0041d7dba6e25bfe6f405f
7
- data.tar.gz: 6c7430ef14def5bfa6510356dd29d73b147ca5131d1a3573e6b337aa643a727f8956fb09bb76e2fafe63156494b4030dec9ae707cc0b9d2f28e08f1f99e0fdb4
6
+ metadata.gz: 434b88542ac7791826f9f384a58982ce1ba5e8864f58e965fe9d60fa2d25bde7780f2378a3a3b66e8ff88ec03ef328810a8b0f90474c27ce96b0f9cd9a1984f9
7
+ data.tar.gz: 75e5c9b6bbcef8207f3d3a42a881c310c802fa4a859b09ad0d14750775ad46776cbf16f73cf560698332bf17b48d10b3c9c0089063d5f99a7e1b8feaad928be3
@@ -4,7 +4,7 @@ module Phcscriptcdn
4
4
  class Scriptcdn::ScriptsController < ApplicationController
5
5
 
6
6
  # Filters and Security
7
- before_action :set_scriptcdn_script, only: [:show, :edit, :update, :destroy]
7
+ before_action :set_scriptcdn_scriptversion, only: [:show, :edit, :update, :destroy]
8
8
 
9
9
  # ScriptCDN Index
10
10
  def index
@@ -7,19 +7,19 @@ module Phcscriptcdn
7
7
 
8
8
  # Index for Scriptcdn_script URLs
9
9
  def index
10
- scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:scriptversion_id])
10
+ scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:script_id])
11
11
  @scriptcdn_scripturls = scriptcdn_scriptversion.scripturls
12
12
  end
13
13
 
14
14
  # Scriptcdn_script URL Details Page
15
15
  def show
16
- scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:scriptversion_id])
16
+ scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:script_id])
17
17
  @scriptcdn_scripturl = scriptcdn_scriptversion.scripturls.find(params[:id])
18
18
  end
19
19
 
20
20
  # New Scriptcdn_script URL
21
21
  def new
22
- scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:scriptversion_id])
22
+ scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:script_id])
23
23
  @scriptcdn_scripturl = scriptcdn_scriptversion.scripturls.build
24
24
  respond_to do |format|
25
25
  format.html # new.html.erb
@@ -29,13 +29,13 @@ module Phcscriptcdn
29
29
 
30
30
  # Edit Scriptcdn_script URL
31
31
  def edit
32
- scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:scriptversion_id])
32
+ scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:script_id])
33
33
  @scriptcdn_scripturl = scriptcdn_scriptversion.scripturls.find(params[:id])
34
34
  end
35
35
 
36
36
  # POST Scriptcdn_script URL
37
37
  def create
38
- @scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:scriptversion_id])
38
+ @scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:script_id])
39
39
  @scriptcdn_scripturl = @scriptcdn_scriptversion.scripturls.create(scriptcdn_scripturl_params)
40
40
  respond_to do |format|
41
41
  if @scriptcdn_scripturl.save
@@ -63,7 +63,7 @@ module Phcscriptcdn
63
63
 
64
64
  # Delete Scriptcdn_script URL
65
65
  def destroy
66
- @scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:scriptversion_id])
66
+ @scriptcdn_scriptversion = Scriptcdn::Scriptversion.find(params[:script_id])
67
67
  @scriptcdn_scripturl = @scriptcdn_scriptversion.scripturls.find(params[:id])
68
68
  @scriptcdn_scripturl.destroy
69
69
  respond_to do |format|
@@ -1,6 +1,6 @@
1
1
  module Phcscriptcdn
2
2
  class Scriptcdn::Scriptversion < ActiveRecord::Base
3
3
  belongs_to :script
4
- belongs_to :scripturl
4
+ has_many :scripturls
5
5
  end
6
6
  end
@@ -1,6 +1,15 @@
1
1
  <%= form_for(@scriptcdn_script) do |f| %>
2
2
 
3
- <%= render 'phcnotifi/validations', :object => @scriptcdn_script %>
3
+ <% if @scriptcdn_script.errors.any? %>
4
+ <div id="error_explanation">
5
+ <h2><%= pluralize(@scriptcdn_script.errors.count, "error") %> prohibited this scriptcdn_script from being saved:</h2>
6
+ <ul>
7
+ <% @scriptcdn_script.errors.full_messages.each do |message| %>
8
+ <li><%= message %></li>
9
+ <% end %>
10
+ </ul>
11
+ </div>
12
+ <% end %>
4
13
 
5
14
  <div class="form-group">
6
15
  <%= f.label :scrptname, "Script Name" %>
@@ -12,7 +21,7 @@
12
21
  </div>
13
22
  <div class="form-group">
14
23
  <%= f.label :scriptversion_id, "Script Version" %>
15
- <%= collection_select(:scriptcdn_script, :scriptversion_id, Phcscriptcdn::Scriptcdn::Scriptversion.order('scrptversionpakname'), :id, :scrptversionpakname, {}, {class: "form-control"}) %>
24
+ <%= collection_select(:scriptcdn_script, :scriptversion_id, Phcscriptcdn::Scriptcdn::Scriptversion.order('scrptversion'), :id, :scrptversion, {}, {class: "form-control form-control-sm"}) %>
16
25
  </div>
17
26
 
18
27
  <div class="actions">
@@ -3,20 +3,20 @@
3
3
  <%= render 'phcnotifi/validations', :object => @scriptcdn_scripturl %>
4
4
 
5
5
  <div class="field">
6
- <%= f.label :scrpturlname, "Script Name" %>
6
+ <label><%= f.label :scrpturlname, "Script Name" %></label>
7
7
  <%= f.text_field :scrpturlname, class: "form-control" %>
8
8
  </div>
9
9
  <div class="field">
10
- <%= f.label :scrpturlphc, "Script URL (AWS)" %>
10
+ <label><%= f.label :scrpturlphc, "Script URL (AWS)" %></label>
11
11
  <%= f.text_field :scrpturlphc, class: "form-control" %>
12
12
  </div>
13
13
  <div class="field">
14
- <%= f.label :scrpturltype, "Script Type" %>
14
+ <label><%= f.label :scrpturltype, "Script Type" %></label>
15
15
  <%= f.select :scrpturltype, [['CSS','css'],['JS','js'],['font','Font']], class: "form-control" %>
16
16
  </div>
17
17
  <div class="form-group">
18
- <%= f.label :scriptversion_id, "Script Version" %>
19
- <%= collection_select(:scriptcdn_scripturl, :scriptversion_id, Phcscriptcdn::Scriptcdn::Scriptversion.order('scrptversion'), :id, :scrptversion, {}, {class: "form-control"}) %>
18
+ <label><%= f.label :scriptversion_id, "Script Version" %></label>
19
+ <%= collection_select(:scriptcdn_scripturl, :scriptversion_id, Phcscriptcdn::Scriptcdn::Scriptversion.order('scrptversion'), :id, :scrptversion, {}, {class: "form-control form-control-sm"}) %>
20
20
  </div>
21
21
 
22
22
  <div class="actions">
@@ -3,19 +3,19 @@
3
3
  <%= render 'phcnotifi/validations', :object => @scriptcdn_scripturl %>
4
4
 
5
5
  <div class="field">
6
- <%= f.label :scrpturlname, "Script Name" %>
6
+ <label><%= f.label :scrpturlname, "Script Name" %></label>
7
7
  <%= f.text_field :scrpturlname, class: "form-control" %>
8
8
  </div>
9
9
  <div class="field">
10
- <%= f.label :scrpturlphc, "Script URL (AWS)" %>
10
+ <label><%= f.label :scrpturlphc, "Script URL (AWS)" %></label>
11
11
  <%= f.text_field :scrpturlphc, class: "form-control" %>
12
12
  </div>
13
13
  <div class="field">
14
- <%= f.label :scrpturltype, "Script Type" %>
14
+ <label><%= f.label :scrpturltype, "Script Type" %></label>
15
15
  <%= f.select :scrpturltype, [['CSS','css'],['JS','js'],['font','Font']], class: "form-control" %>
16
16
  </div>
17
17
  <div class="form-group">
18
- <%= f.label :scriptversion_id, "Script Version" %>
18
+ <label><%= f.label :scriptversion_id, "Script Version" %></label>
19
19
  <%= collection_select(:scriptcdn_scripturl, :scriptversion_id, Phcscriptcdn::Scriptcdn::Scriptversion.order('scrptversion'), :id, :scrptversion, {}, {class: "form-control form-control-sm"}) %>
20
20
  </div>
21
21
 
@@ -3,12 +3,12 @@
3
3
  <%= render 'phcnotifi/validations', :object => @scriptcdn_scriptversion %>
4
4
 
5
5
  <div class="form-group">
6
- <%= f.label :scrptversionpakname, "Version Pak Name" %>
6
+ <label><%= f.label :scrptversionpakname, "Version Pak Name" %></label>
7
7
  <%= f.text_field :scrptversionpakname %>
8
8
  </div>
9
9
 
10
10
  <div class="form-group">
11
- <%= f.label :scrptversion, "Script Versions" %>
11
+ <label><%= f.label :scrptversion, "Script Versions" %></label>
12
12
  <%= f.text_field :scrptversion %>
13
13
  </div>
14
14
 
@@ -4,8 +4,6 @@ class CreatePhcscriptcdnScriptcdnScripts < ActiveRecord::Migration
4
4
 
5
5
  t.string :scrptname
6
6
  t.text :scrptdescription
7
-
8
- t.references :scriptversion, index: true
9
7
 
10
8
  t.timestamps null: false
11
9
 
@@ -1,3 +1,3 @@
1
1
  module Phcscriptcdn
2
- VERSION = "0.9.5"
2
+ VERSION = "0.9.6"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: phcscriptcdn
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.5
4
+ version: 0.9.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - BradPotts
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-19 00:00:00.000000000 Z
11
+ date: 2016-05-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -354,7 +354,7 @@ dependencies:
354
354
  - - "~>"
355
355
  - !ruby/object:Gem::Version
356
356
  version: '2.53'
357
- description: PHC ScriptCDN is listing software to manage script CDN listings on websites.
357
+ description: PHCScript CDN is script listing software to manage script CDN listings.
358
358
  email:
359
359
  - bradley.j.potts@gmail.com
360
360
  executables: []
@@ -410,7 +410,7 @@ files:
410
410
  - lib/phcscriptcdn/engine.rb
411
411
  - lib/phcscriptcdn/version.rb
412
412
  - lib/tasks/phcscriptcdn_tasks.rake
413
- homepage: https://phcnetworks.net/script-cdn
413
+ homepage: https://www.phcnetworks.net/content-delivery-networks-scripts
414
414
  licenses:
415
415
  - GPL-3.0
416
416
  metadata: {}