mumukit-platform 2.7.0 → 2.7.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f969d445c252af08ede5006b769d61be8422a2593a08b33e443b4af760bcd445
4
- data.tar.gz: 84c8377aa68cc79380b9add72056543dec575ad8aedc5a83be681157b66e24e5
3
+ metadata.gz: 4674e22f2ac37e9d5c43ae6b7a2136f3695192813677eeed02990c55e6673d1a
4
+ data.tar.gz: c2ae3de0955f92cc46d65ee90a0f46046b46f576a268606c8a175cac4f360baa
5
5
  SHA512:
6
- metadata.gz: a9f5fe8e06f49ffbe101c470e3c821b02288571547278401798d4ab3668b46a4c96e7eb20a3064a5af3a6dc036ab09f1a3787759f8e3c94fc9a15947c49ab300
7
- data.tar.gz: 3f993c297e4a6327f8fdfb52a5589135f5ab08cc1190eda7fc6b58213a4ad462445b6bd185657692c055cdc8abd4be6d790decfd5b60b5821dba990a74d03804
6
+ metadata.gz: 4fcb02e58c711f49984bfafc3929c4cca1b182735ef8a9533a2a564bc6d021089e71b2c4e3ce8008f56449b219abbaed27ebb2d2325b05eb33b19e7f8529a2a9
7
+ data.tar.gz: 639052fcfebe94565a3eec4060b45e88374a6d6ad0232eb98d21e1679444f1473241e528635951977cff19a39f52e3520c82120d80f96176e0b7f50e6c05bb94
@@ -28,7 +28,11 @@ class Mumukit::Platform::Application
28
28
  end
29
29
 
30
30
  def organic_url_for(organization, path)
31
- organic_uri(organization).url_for(path)
31
+ organic_uri(organization).url_for(relative_path path)
32
+ end
33
+
34
+ def relative_path(path)
35
+ path.start_with?('/') ? path[1..-1] : path
32
36
  end
33
37
 
34
38
  class Basic < Mumukit::Platform::Application
@@ -38,13 +42,15 @@ class Mumukit::Platform::Application
38
42
  end
39
43
 
40
44
  class Organic < Mumukit::Platform::Application
45
+ attr_reader :organization_mapping
46
+
41
47
  def initialize(url, organization_mapping)
42
48
  super(url)
43
49
  @organization_mapping = organization_mapping
44
50
  end
45
51
 
46
52
  def organic_uri(organization)
47
- @organization_mapping.organic_uri(uri, organization)
53
+ organization_mapping.organic_uri(uri, organization)
48
54
  end
49
55
  end
50
56
  end
@@ -48,6 +48,10 @@ module Mumukit::Platform::Organization::Helpers
48
48
  Mumukit::Platform.application.organic_url_for(name, path)
49
49
  end
50
50
 
51
+ def url
52
+ url_for '/'
53
+ end
54
+
51
55
  def domain
52
56
  Mumukit::Platform.application.organic_domain(name)
53
57
  end
@@ -1,5 +1,5 @@
1
1
  module Mumukit
2
2
  module Platform
3
- VERSION = '2.7.0'
3
+ VERSION = '2.7.1'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mumukit-platform
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.7.0
4
+ version: 2.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Franco Leonardo Bulgarelli
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-10-14 00:00:00.000000000 Z
11
+ date: 2018-10-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mumukit-nuntius