graphiti-openapi 0.1.4 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/models/graphiti/open_api/endpoint.rb +5 -1
- data/lib/graphiti/open_api/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 3e72f28f72e39813ba6776fa40544279bbf842fed200b5be56678aa40495981d
|
|
4
|
+
data.tar.gz: ebe5f2fd5206ad29590fec6b6336003e34b3433092a813f47d6caf7cd2c87b4a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 706bbdd8b08e6983b576d806e0af2dd23058ba1cc0a90a56be5a4591cf6d341e86ebbd06e137e001aa1525e358b4770f78e3c96abf3e212f411127330f5815dc
|
|
7
|
+
data.tar.gz: 4ba0e5eb35b63240bc917f1cd0984787d20218e47afcf65a5c449943bc40a17dec1aa486969926caf6a1b57515c36f9ea8cfe3c081e97876f916d64a2881948b
|
|
@@ -17,6 +17,10 @@ module Graphiti::OpenAPI
|
|
|
17
17
|
attribute :schema, Types::Any
|
|
18
18
|
attribute :path, Types::Coercible::String
|
|
19
19
|
|
|
20
|
+
def path
|
|
21
|
+
__attributes__[:path].gsub(/^#{Regexp.escape(ApplicationResource.endpoint_namespace)}/, '')
|
|
22
|
+
end
|
|
23
|
+
|
|
20
24
|
def resource_path
|
|
21
25
|
File.join(path.to_s, "{id}")
|
|
22
26
|
end
|
|
@@ -59,7 +63,7 @@ module Graphiti::OpenAPI
|
|
|
59
63
|
actions.select(&:collection?)
|
|
60
64
|
end
|
|
61
65
|
|
|
62
|
-
memoize :resource_path, :paths, :parameters, :resource, :resource_actions, :collection_actions
|
|
66
|
+
memoize :path, :resource_path, :paths, :parameters, :resource, :resource_actions, :collection_actions
|
|
63
67
|
end
|
|
64
68
|
|
|
65
69
|
class Endpoints < Hash
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: graphiti-openapi
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Alex Semyonov
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2019-01-
|
|
11
|
+
date: 2019-01-25 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: railties
|