motor-admin 0.2.2 → 0.2.6

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: f43566e0fd7cd93d18edae286ca0f138bba3ed0f0d531264d0ad29579f704306
4
- data.tar.gz: e3b2860cd08bdad0eb465b71fb6963f53203117b11871a9b2ced77b086780376
3
+ metadata.gz: 9b0f19398ae8e7e11b2d3599dc83707c69acce2ef4731b73a1b7a0c9e006c069
4
+ data.tar.gz: 6c67d6492965989428dfab23a4b5315790ffb1408f572f2e9c38437385e53f60
5
5
  SHA512:
6
- metadata.gz: 8adc5697b41a7427c67e66b6024995431b630b787a41eacbed0501d2ccac8b815b10536eb7becf96dc7033ee76bdb49dc1decd481bcdaa95b2b7c8f75f50f96d
7
- data.tar.gz: 0dfc8b287097a5ff8c9e0b640625b53eddaa1ea302f674caa65f9a5e044c49b073d9d0c932ba5ffc0e8986d66640216fce785b1bb85332f4c3173bccb575cdb3
6
+ metadata.gz: e38ab5f4be4a8d340f2b2568b1cdfa586243ed895f6abdb39dc3509b14bb8d3556d6b0de22671d87ed3a6f11895eb29add8f10e542038b68975a2b89df6334cb
7
+ data.tar.gz: a5800734dc28bd4f1e8e0e559bb5a948756f9270cfd1dc873e8a943021a498dd66dd354361abec776113564e5cc97f7afc9f1447c8e78c17c88da792eb165cf0
@@ -262,3 +262,5 @@ en:
262
262
  activate: Activate
263
263
  load_existing_options_from_database: Load existing options from the database
264
264
  add_database: Add Database
265
+ audio: Audio
266
+ video: Video
@@ -262,6 +262,8 @@ es:
262
262
  activate: Activar
263
263
  load_existing_options_from_database: Cargar las opciones existentes de la base de datos
264
264
  add_database: Añadir base de datos
265
+ audio: Audio
266
+ video: Video
265
267
  i:
266
268
  locale: es
267
269
  select:
@@ -258,6 +258,8 @@ pt:
258
258
  visibility: "Visibilidade"
259
259
  visualization: "Visualização"
260
260
  write_only: "Somente gravação"
261
+ audio: Áudio
262
+ video: Vídeo
261
263
  i:
262
264
  locale: pt
263
265
  select:
data/lib/motor/admin.rb CHANGED
@@ -45,7 +45,7 @@ module Motor
45
45
  initializer 'motor.alerts.scheduler' do
46
46
  config.after_initialize do
47
47
  next unless Motor.server?
48
- next if Motor.development?
48
+ next unless Rails.env.production?
49
49
 
50
50
  Motor::Alerts::Scheduler::SCHEDULER_TASK.execute
51
51
  end
@@ -4,6 +4,8 @@ module Motor
4
4
  module CancanUtils
5
5
  module AbilityPatch
6
6
  def serialized_rules
7
+ return [] unless @rules
8
+
7
9
  @rules.map do |rule|
8
10
  {
9
11
  base_behavior: rule.base_behavior,
@@ -13,7 +13,7 @@ module Motor
13
13
  module_function
14
14
 
15
15
  def call(current_user = nil, current_ability = nil, cache_keys: LoadFromCache.load_cache_keys)
16
- CACHE_STORE.fetch("#{I18n.locale}#{cache_keys.hash}#{current_user&.id}") do
16
+ CACHE_STORE.fetch("#{I18n.locale}#{cache_keys.hash}#{current_user&.id}#{current_ability&.rules_hash}") do
17
17
  CACHE_STORE.clear
18
18
 
19
19
  data = build_data(cache_keys, current_user, current_ability)
@@ -14,7 +14,7 @@ module Motor
14
14
 
15
15
  maybe_fetch_from_cache(
16
16
  model,
17
- cache_key,
17
+ cache_key.to_s + model.object_id.to_s,
18
18
  lambda {
19
19
  resource_config = configs.find { |r| r.name == model.name.underscore }
20
20
 
data/lib/motor/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Motor
4
- VERSION = '0.2.2'
4
+ VERSION = '0.2.6'
5
5
  end
@@ -2601,9 +2601,9 @@
2601
2601
  "icons/zoom-out.svg.gz": "icons/zoom-out.svg.gz",
2602
2602
  "icons/zoom-question.svg": "icons/zoom-question.svg",
2603
2603
  "icons/zoom-question.svg.gz": "icons/zoom-question.svg.gz",
2604
- "main-5c903ff9235e54ac03f1.css.gz": "main-5c903ff9235e54ac03f1.css.gz",
2605
- "main-5c903ff9235e54ac03f1.js.LICENSE.txt": "main-5c903ff9235e54ac03f1.js.LICENSE.txt",
2606
- "main-5c903ff9235e54ac03f1.js.gz": "main-5c903ff9235e54ac03f1.js.gz",
2607
- "main.css": "main-5c903ff9235e54ac03f1.css",
2608
- "main.js": "main-5c903ff9235e54ac03f1.js"
2604
+ "main-32da50c51ef9fcddf634.css.gz": "main-32da50c51ef9fcddf634.css.gz",
2605
+ "main-32da50c51ef9fcddf634.js.LICENSE.txt": "main-32da50c51ef9fcddf634.js.LICENSE.txt",
2606
+ "main-32da50c51ef9fcddf634.js.gz": "main-32da50c51ef9fcddf634.js.gz",
2607
+ "main.css": "main-32da50c51ef9fcddf634.css",
2608
+ "main.js": "main-32da50c51ef9fcddf634.js"
2609
2609
  }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: motor-admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pete Matsyburka
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-09-14 00:00:00.000000000 Z
11
+ date: 2021-10-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord-filter
@@ -1523,8 +1523,8 @@ files:
1523
1523
  - ui/dist/icons/zoom-money.svg.gz
1524
1524
  - ui/dist/icons/zoom-out.svg.gz
1525
1525
  - ui/dist/icons/zoom-question.svg.gz
1526
- - ui/dist/main-5c903ff9235e54ac03f1.css.gz
1527
- - ui/dist/main-5c903ff9235e54ac03f1.js.gz
1526
+ - ui/dist/main-32da50c51ef9fcddf634.css.gz
1527
+ - ui/dist/main-32da50c51ef9fcddf634.js.gz
1528
1528
  - ui/dist/manifest.json
1529
1529
  homepage:
1530
1530
  licenses: