tramway-admin 4.1.1.5 → 4.1.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: fbc4343d5cbd090f126128c0297e8e9f3bf5056a79701e012b561a50ccbb359d
4
- data.tar.gz: 9cff857408d5167428271bff18f34ea5b4d9707615d24c8a03bca80bb6b827fe
3
+ metadata.gz: c1c137f5de12ed85d0f9ce6c51f86ca517f69d0aa4eec605341f96dc2dcb0c25
4
+ data.tar.gz: 04d8e076bc5d4ecfda9004febade75f119f51e45cbfad9b5849ad1fb3a6836da
5
5
  SHA512:
6
- metadata.gz: 84f99f777be52faa2e8f702b64aef5965a63617f12e791def97ae4caf7468d0f08c82ab4a7f7f84aed9e4290054bcbc9eeac52f1ad1c1d605a8a34d3d8c5405b
7
- data.tar.gz: e62a5caf162502c4669c4739b42fab56510694e4ce03bf091b4aa924852080c42708cfa35acd353ac7ba787f1958b791b7c882ad72bbad7d1f4ccc425abc9034
6
+ metadata.gz: ed4113ee3d7fe5ef589d580932e766bf41570a4215aa9a20ad4cd5bd25500167cfdc0760ed0d3b13c542959420246c07bc41f2a5c6abc9c7c724e367f311a733
7
+ data.tar.gz: 6a43532b53b33d8b0e40399648752284be107c296ba808f65728213028974ce192862d20222fec35800e9cc69c77078ce41866661af84179882567ff03f33a0f
@@ -29,7 +29,8 @@
29
29
  %br
30
30
  %br
31
31
  .btn-group{ data: { toggle: :buttons } }
32
- - record.model.class.state_machines_names.each do |state_machine_name|
32
+ - state_machine_names = record.listed_state_machines || record.model.class.state_machines_names
33
+ - state_machine_names.each do |state_machine_name|
33
34
  - unless state_machine_name == 'default'
34
35
  = state_events_buttons record, state_method: state_machine_name, model_param_name: :record, controller: 'tramway/admin/records', action: :update, parameters: { redirect: current_model_records_path(page: params[:page], scope: params[:scope], filter: params[:filter], focus: focus_selector(index)), model: record.class.model_name }, button_options: { class: :smart_button }
35
36
  = paginate @records, theme: 'twitter-bootstrap-4'
@@ -5,8 +5,9 @@
5
5
  %td
6
6
  = link_to association_object.name, record_path(association_object.id, model: association.options[:class_name])
7
7
  - if association_object.model.class.state_machines_names.count > 1
8
+ - state_machine_names = association_object.listed_state_machines || association_object.model.class.state_machines_names
8
9
  %td
9
- - association_object.model.class.state_machines_names.each do |state_method|
10
+ - state_machine_names.each do |state_method|
10
11
  - unless state_method == 'default'
11
12
  = state_events_buttons association_object, state_method: state_method, model_param_name: :record, controller: 'tramway/admin/records', action: :update, parameters: { redirect: current_model_record_path(object.id), model: association_object.class.model_name }, button_options: { class: :smart_button }
12
13
  %td{ style: 'display: flex; justify-content: space-evenly' }
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Tramway
4
4
  module Admin
5
- VERSION = '4.1.1.5'
5
+ VERSION = '4.1.2'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tramway-admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.1.5
4
+ version: 4.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pavel Kalashnikov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-05-02 00:00:00.000000000 Z
11
+ date: 2022-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: tramway-core
@@ -331,7 +331,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
331
331
  - !ruby/object:Gem::Version
332
332
  version: '0'
333
333
  requirements: []
334
- rubygems_version: 3.2.3
334
+ rubygems_version: 3.1.6
335
335
  signing_key:
336
336
  specification_version: 4
337
337
  summary: Engine for admin