phcpresspro 20.0.0 → 21.0.0
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9eaee0dfbf91a73623c60a1518ee2899b5e9fbf8
|
4
|
+
data.tar.gz: 608a3275da3c6747e4245a7b9f8f9075d5a854c1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 49447e5ce28b1527151f1dee304136de397f9f11db120aad90b490f8dc70b45058451b2d353a8ae603fe58e732cdeabb62b76a261398e5fcd0df449315455553
|
7
|
+
data.tar.gz: d4aa8ee449211e7926f4fd11180d0000d1cc447d51996d08f2246eab6ef1002e0161bab45a4f4cfe6d1dca00336432495c51640ed8a3440b70d180356da2a4f1
|
@@ -8,12 +8,12 @@ module Phcpresspro
|
|
8
8
|
|
9
9
|
# Article Category API
|
10
10
|
def index
|
11
|
-
@
|
11
|
+
@phcpresspro_frontend_article_index = Phcpressproindexapi.get_phcpresspro_index_api
|
12
12
|
end
|
13
13
|
|
14
14
|
# Article Show
|
15
15
|
def show
|
16
|
-
@
|
16
|
+
@phcpresspro_frontend_article_show = Article::Post.find(params[:id])
|
17
17
|
end
|
18
18
|
|
19
19
|
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
module Phcpresspro
|
2
|
+
|
3
|
+
require 'httparty'
|
4
|
+
|
5
|
+
class Phcpressproindexapi
|
6
|
+
|
7
|
+
include HTTParty
|
8
|
+
format :json
|
9
|
+
|
10
|
+
base_uri 'phcnetworks.net'
|
11
|
+
|
12
|
+
attr_accessor :id, :psttitle, :psttext, :pststatus, :pstimage
|
13
|
+
|
14
|
+
def initialize(response)
|
15
|
+
@phc_press_id = response['phcpresspro_article_post']['id']
|
16
|
+
@phc_press_psttitle = response['phcpresspro_article_post']['psttitle']
|
17
|
+
@phc_press_psttext = response['phcpresspro_article_post']['psttext']
|
18
|
+
@phc_press_pststatus = response['phcpresspro_article_post']['pststatus']
|
19
|
+
@phc_press_pstimage = response['phcpresspro_article_post']['pstimage']
|
20
|
+
end
|
21
|
+
|
22
|
+
def self.get_phcpresspro_index_api
|
23
|
+
response = get("/cms/api/v1/posts.json")
|
24
|
+
if response.success?
|
25
|
+
new(response)
|
26
|
+
else
|
27
|
+
raise response.response
|
28
|
+
end
|
29
|
+
end
|
30
|
+
|
31
|
+
end
|
32
|
+
|
33
|
+
end
|
data/lib/phcpresspro/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: phcpresspro
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 21.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- BradPotts
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-09-
|
11
|
+
date: 2017-09-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: paper_trail
|
@@ -380,6 +380,20 @@ dependencies:
|
|
380
380
|
- - ">="
|
381
381
|
- !ruby/object:Gem::Version
|
382
382
|
version: 5.2.1
|
383
|
+
- !ruby/object:Gem::Dependency
|
384
|
+
name: httparty
|
385
|
+
requirement: !ruby/object:Gem::Requirement
|
386
|
+
requirements:
|
387
|
+
- - "~>"
|
388
|
+
- !ruby/object:Gem::Version
|
389
|
+
version: 0.15.6
|
390
|
+
type: :runtime
|
391
|
+
prerelease: false
|
392
|
+
version_requirements: !ruby/object:Gem::Requirement
|
393
|
+
requirements:
|
394
|
+
- - "~>"
|
395
|
+
- !ruby/object:Gem::Version
|
396
|
+
version: 0.15.6
|
383
397
|
- !ruby/object:Gem::Dependency
|
384
398
|
name: phcnotifi
|
385
399
|
requirement: !ruby/object:Gem::Requirement
|
@@ -750,6 +764,7 @@ files:
|
|
750
764
|
- db/migrate/20170517064114_create_phcpresspro_connection_versions.rb
|
751
765
|
- db/migrate/20170517064427_create_phcpresspro_category_versions.rb
|
752
766
|
- lib/phcpresspro.rb
|
767
|
+
- lib/phcpresspro/apis/phcpresspro.rb
|
753
768
|
- lib/phcpresspro/engine.rb
|
754
769
|
- lib/phcpresspro/version.rb
|
755
770
|
- lib/tasks/phcpresspro_tasks.rake
|