phcscriptcdnpro 1.9.10 → 1.9.11

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: c9e958babde382e880a595b8d0f719a0fa654139
4
- data.tar.gz: 5b19d2e30046c98e1e511aea74905ed5bac4188f
3
+ metadata.gz: 5f04a02f52140249956e671844cbaf6af46d5551
4
+ data.tar.gz: 2e5305b331cc3707f0016a2de4ca52c3dfd753a2
5
5
  SHA512:
6
- metadata.gz: 945c8b3159a1e6eff0d60fbb861b74aab8a1c1f31a0c443d1d7a134c1cd4d799220afd0f511d7b84d89a419797b641da95bd06b5b176bf52571e3674da18d0c2
7
- data.tar.gz: d43a5bec50aa86706d01644623d05221ad2acf0edc8ea04e3c75a7d7131cf8b0dbc8478f961e1c11cfe77e513776e07e5a23c15c3a90cc916914392a805695c4
6
+ metadata.gz: baa1c229d2ffa1befeb357c1eddd65560019e4aa89934363730cc2264af0e342cc31bc9f46643508621e9600dc8e61d2979d47f27ac28b4f88ac716099075619
7
+ data.tar.gz: 69c7992c9518affe8385835151da7f9080d910fdb45fe36b65d9dc3c4d0f8c29d8cc303d44676e8b78b227fdd56848b6be54a180b3ae043c9d0b53ad33d84e55
@@ -1,3 +1,3 @@
1
- // Place all the styles related to the api/cdnlists controller here.
1
+ // Place all the styles related to the api/mains controller here.
2
2
  // They will automatically be included in application.css.
3
3
  // You can use Sass (SCSS) here: http://sass-lang.com/
@@ -1,7 +1,7 @@
1
1
  require_dependency "phcscriptcdnpro/application_controller"
2
2
 
3
3
  module Phcscriptcdnpro
4
- class Api::CdnlistsController < ApplicationController
4
+ class Api::MainsController < ApplicationController
5
5
 
6
6
  # Only Responds to API Requests
7
7
  respond_to :json
@@ -9,6 +9,13 @@ module Phcscriptcdnpro
9
9
  # Directory Category API
10
10
  def index
11
11
  @scriptcdn_mains = Scriptcdn::Main.all
12
+ respond_to do |format|
13
+ format.json { render :json => @scriptcdn_main }
14
+ end
15
+ end
16
+
17
+ def show
18
+ @scriptcdn_main = Scriptcdn::Main.find(params[:id])
12
19
  end
13
20
 
14
21
  end
@@ -1,4 +1,4 @@
1
1
  module Phcscriptcdnpro
2
- module Api::CdnlistsHelper
2
+ module Api::MainsHelper
3
3
  end
4
4
  end
@@ -0,0 +1,3 @@
1
+ collection @scriptcdn_mains
2
+
3
+ extends "mains/show"
@@ -1,5 +1,5 @@
1
- object @scriptcdn_mains
1
+ object @scriptcdn_main
2
2
  attributes :id, :information_id, :version_id
3
- child(:information) {
3
+ child :informations do
4
4
  attributes :scripttitle, :scriptdescription, :scriptcategory, :scriptwebsite, :scripttwitter, :scriptgithub, :scriptlicence, :scriptinitialrelease, :scriptplatform, :scriptstatus
5
- }
5
+ end
data/config/routes.rb CHANGED
@@ -19,12 +19,10 @@ Phcscriptcdnpro::Engine.routes.draw do
19
19
  end
20
20
 
21
21
  # Application API
22
- namespace :api do
22
+ namespace :api, :path => "", :constraints => {:subdomain => "api"} do
23
23
 
24
24
  # Routes for API
25
- resources :cdnlists, defaults: {format: 'json'} do
26
- resources :cdnlistings
27
- end
25
+ resources :mains, defaults: {format: 'json'}
28
26
 
29
27
  end
30
28
 
@@ -1,3 +1,3 @@
1
1
  module Phcscriptcdnpro
2
- VERSION = "1.9.10"
2
+ VERSION = "1.9.11"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: phcscriptcdnpro
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.10
4
+ version: 1.9.11
5
5
  platform: ruby
6
6
  authors:
7
7
  - BradPotts
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-25 00:00:00.000000000 Z
11
+ date: 2016-06-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -427,15 +427,12 @@ files:
427
427
  - LICENSE
428
428
  - README.md
429
429
  - Rakefile
430
- - app/assets/javascripts/phcscriptcdnpro/api/cdnlistings.js
431
- - app/assets/javascripts/phcscriptcdnpro/api/cdnlists.js
430
+ - app/assets/javascripts/phcscriptcdnpro/api/mains.js
432
431
  - app/assets/javascripts/phcscriptcdnpro/application.js
433
- - app/assets/stylesheets/phcscriptcdnpro/api/cdnlistings.scss
434
- - app/assets/stylesheets/phcscriptcdnpro/api/cdnlists.scss
432
+ - app/assets/stylesheets/phcscriptcdnpro/api/mains.scss
435
433
  - app/assets/stylesheets/phcscriptcdnpro/application.css.scss
436
434
  - app/assets/stylesheets/phcscriptcdnpro/custom.scss
437
- - app/controllers/phcscriptcdnpro/api/cdnlistings_controller.rb
438
- - app/controllers/phcscriptcdnpro/api/cdnlists_controller.rb
435
+ - app/controllers/phcscriptcdnpro/api/mains_controller.rb
439
436
  - app/controllers/phcscriptcdnpro/application_controller.rb
440
437
  - app/controllers/phcscriptcdnpro/frontend/cdnpages_controller.rb
441
438
  - app/controllers/phcscriptcdnpro/scriptcdn/authors_controller.rb
@@ -443,8 +440,7 @@ files:
443
440
  - app/controllers/phcscriptcdnpro/scriptcdn/mains_controller.rb
444
441
  - app/controllers/phcscriptcdnpro/scriptcdn/urls_controller.rb
445
442
  - app/controllers/phcscriptcdnpro/scriptcdn/versions_controller.rb
446
- - app/helpers/phcscriptcdnpro/api/cdnlistings_helper.rb
447
- - app/helpers/phcscriptcdnpro/api/cdnlists_helper.rb
443
+ - app/helpers/phcscriptcdnpro/api/mains_helper.rb
448
444
  - app/helpers/phcscriptcdnpro/application_helper.rb
449
445
  - app/models/phcscriptcdnpro/scripcdn.rb
450
446
  - app/models/phcscriptcdnpro/scriptcdn.rb
@@ -455,8 +451,8 @@ files:
455
451
  - app/models/phcscriptcdnpro/scriptcdn/version.rb
456
452
  - app/views/layouts/phcscriptcdnpro/application.html.erb
457
453
  - app/views/layouts/phcscriptcdnpro/frontend.html.erb
458
- - app/views/phcscriptcdnpro/api/cdnlistings/show.json.rabl
459
- - app/views/phcscriptcdnpro/api/cdnlists/index.json.rabl
454
+ - app/views/phcscriptcdnpro/api/mains/index.json.rabl
455
+ - app/views/phcscriptcdnpro/api/mains/show.json.rabl
460
456
  - app/views/phcscriptcdnpro/frontend/cdnpages/list.html.erb
461
457
  - app/views/phcscriptcdnpro/frontend/cdnpages/listing.html.erb
462
458
  - app/views/phcscriptcdnpro/scriptcdn/authors/_form.html.erb
@@ -1,2 +0,0 @@
1
- // Place all the behaviors and hooks related to the matching controller here.
2
- // All this logic will automatically be available in application.js.
@@ -1,3 +0,0 @@
1
- // Place all the styles related to the api/cdnlistings controller here.
2
- // They will automatically be included in application.css.
3
- // You can use Sass (SCSS) here: http://sass-lang.com/
@@ -1,15 +0,0 @@
1
- require_dependency "phcscriptcdnpro/application_controller"
2
-
3
- module Phcscriptcdnpro
4
- class Api::CdnlistingsController < ApplicationController
5
-
6
- # Only Responds to API Requests
7
- respond_to :json
8
-
9
- # Directory Category API
10
- def show
11
- @scriptcdn_mains = Scriptcdn::Main.find(params[:id])
12
- end
13
-
14
- end
15
- end
@@ -1,4 +0,0 @@
1
- module Phcscriptcdnpro
2
- module Api::CdnlistingsHelper
3
- end
4
- end
@@ -1,5 +0,0 @@
1
- object @scriptcdn_mains
2
- attributes :id, :information_id, :version_id
3
- child(:information) {
4
- attributes :scripttitle, :scriptdescription, :scriptcategory, :scriptwebsite, :scripttwitter, :scriptgithub, :scriptlicence, :scriptinitialrelease, :scriptplatform, :scriptstatus
5
- }