scrivito_ui 1.6.0.rc3 → 1.6.0.rc4

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: 96d4ae87973c78fa558d664d06c608fe942fa2c2
4
- data.tar.gz: 20f4cbbd4b725ea9fe24eb114f5b8ee645271162
3
+ metadata.gz: d637ad3434211372a0a9072de8f5e96f730293cd
4
+ data.tar.gz: a2a8380e8b38e2db75205837d8fbfe5f5e873dc1
5
5
  SHA512:
6
- metadata.gz: 1bfc6ce10feb6d0d4c9679eb4c22443dddd2a7f5214a4fc2e8c4e18009b248da4a5676d581c4064a34f1879541b5ce61e9a4ca476d868a17c2861e220cc26e23
7
- data.tar.gz: 30e47b16dccb5fccace23aa6d289fb7494ba2372ed3b77b5ce45c7b470fb8f161081275f0a4f5eea7079631b895147820bcfd7da95bc513f371a2ae3acb60cd7
6
+ metadata.gz: 320ba19b99993afcb831343fa34742c95d944885f05b3fd488564f5015971e30986c361067a19d608f322b4eec703fbce1b61a386d7a3801dd6ed4433d4862de
7
+ data.tar.gz: 3bc38f366ca56966dfd1c161ecd8bb06d06e82edf8eded0b20d54e8e7603eb2d47087bffee1f208d488b9753ee591ce3a003f05e9f049e67eeb702c5dfaa2c5a
@@ -52580,7 +52580,10 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
52580
52580
  }, {
52581
52581
  key: 'get',
52582
52582
  value: function get(id) {
52583
- return new scrivito.Workspace(id);
52583
+ var workspace = new scrivito.Workspace(id);
52584
+ workspace.ensureAvailable();
52585
+
52586
+ return workspace;
52584
52587
  }
52585
52588
  }, {
52586
52589
  key: 'byModifiedObj',
@@ -52614,6 +52617,8 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
52614
52617
  value: function storeWithAttributes(id, attributes) {
52615
52618
  var workspace = new scrivito.Workspace(id);
52616
52619
  workspace.assignAttributes(attributes);
52620
+
52621
+ return workspace;
52617
52622
  }
52618
52623
  }, {
52619
52624
  key: 'published',
@@ -52623,8 +52628,15 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
52623
52628
  }, {
52624
52629
  key: 'selected',
52625
52630
  get: function get() {
52626
- var selectedWorkspaceId = scrivito.editingContext.selectedWorkspace.id();
52627
- return this.get(selectedWorkspaceId);
52631
+ try {
52632
+ return this.get(scrivito.editingContext.selectedWorkspace.id());
52633
+ } catch (error) {
52634
+ if (error instanceof scrivito.ResourceNotFoundError) {
52635
+ return this.published;
52636
+ }
52637
+
52638
+ throw error;
52639
+ }
52628
52640
  }
52629
52641
  }]);
52630
52642
 
@@ -52695,6 +52707,11 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
52695
52707
  return _this4.assignAttributes(newAttributes);
52696
52708
  });
52697
52709
  }
52710
+ }, {
52711
+ key: 'ensureAvailable',
52712
+ value: function ensureAvailable() {
52713
+ this._loadableData.get();
52714
+ }
52698
52715
  }, {
52699
52716
  key: 'id',
52700
52717
  get: function get() {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scrivito_ui
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0.rc3
4
+ version: 1.6.0.rc4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scrivito
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-11-18 00:00:00.000000000 Z
11
+ date: 2016-11-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties