plate_id 0.0.1 → 0.0.2

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: 6b3408e5e25f6c0c78ff3db6c74359db7dc0913c293c90e678ae6fb285956b07
4
- data.tar.gz: 2a550ab8594a96ca5cf34f8de198cf102f3ffe0d538b9f91cdfa0536f9d2e122
3
+ metadata.gz: 181a22aff751916e466a2a130eba6962b573866c6af2ec27eda43133a1560f4d
4
+ data.tar.gz: f2ebaa9a10793b74b30aa4b6add79513c76099a675f96cb736f960d319c3ed5f
5
5
  SHA512:
6
- metadata.gz: bd9126447d7684c761922f340ca3c49b40eb009aef03f2eb4aa4cef5858171fb82e82c0bc025930bc9e6912eeb7d0ee712521e678dae5a1b226821f8bfdc123c
7
- data.tar.gz: 49daf4c620fe31b64b2e20889a033a30f19353f059a80bb13dc16477eae67c4efcd03cf35cca782e36d51304486190fc9d0e45cf4bb46a927184acb073363ea4
6
+ metadata.gz: 35e1344db5692a9ff86b5d53919bfcd79a574465518ab2d06245026b1e692a30d4675c02bec1d61b62df760501830d6554d1d6efa38fd58da516156950ba6eb7
7
+ data.tar.gz: 01a1f5577e469b07722d64f44e61a3d12b33f8776fe0f31edf82d1c925c1d7c50c7b115e756c515e8a1a0d35b25446f383d6f92b474ae692352b4f95898cc7b6
data/lib/uri/plate_id.rb CHANGED
@@ -1,3 +1,5 @@
1
+ require 'cgi'
2
+
1
3
  module URI
2
4
  class PlateID < Generic
3
5
 
@@ -37,11 +39,12 @@ module URI
37
39
  "Org::Auth::User" => { host: "Auth", base_class: "User" },
38
40
  "Api::Integration" => { host: "Auth", base_class: "ApiIntegration" },
39
41
 
40
- # "Ngn::Auth::AccessControl::Policy" => { host: "AccessControl", base_class: "Policy" },
41
-
42
42
  "Org::Company" => { host: "Organization", base_class: "Company" },
43
43
  "Org::Partner" => { host: "Organization", base_class: "Partner" },
44
- "Org::FormMessage" => { host: "Organization", base_class: "FormMessage" }
44
+ "Org::FormMessage" => { host: "Organization", base_class: "FormMessage" },
45
+
46
+ # Access control
47
+ "AccessControl::Policy" => { host: "AccessControl", base_class: "Policy" }
45
48
  }
46
49
 
47
50
  attr_reader :base_class, :id
@@ -67,13 +70,13 @@ module URI
67
70
 
68
71
  # Create a new URI::PlateID from components with argument check.
69
72
  #
70
- # The allowed components are app, model_name, model_id and params, which
73
+ # The allowed components are model_name and model_id, which
71
74
  # can be either a hash or an array.
72
75
  #
73
76
  # Using a hash:
74
77
  #
75
78
  # URI::PlateID.build(
76
- # model_name: 'Ngn::ContentModelElementType',
79
+ # model_name: 'Ngn::ContentModel::ElementType',
77
80
  # model_id: '1'
78
81
  # )
79
82
  def build(args)
data/plate_id.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "plate_id"
5
- spec.version = "0.0.1"
5
+ spec.version = "0.0.2"
6
6
  spec.authors = ["Kobus Post"]
7
7
  spec.email = ["kobus@getplate.com"]
8
8
  spec.homepage = "https://www.getplate.com"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: plate_id
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kobus Post
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-02-15 00:00:00.000000000 Z
11
+ date: 2021-02-17 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Identify any Plate record or class with URIs. Somewhat based on Rails's
14
14
  GlobalID gem.