active_scaffold 4.0.0 → 4.0.1

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: cadefffe75f1a7bdf8afba8418f0ffff986086b93a5045b4680b06c4ffe47c1a
4
- data.tar.gz: ca800128c2c114e3acd598c3ec35172cff9b271171b1dd6a95c098ba1114ae94
3
+ metadata.gz: 18ae38a98f317aedf4c54ade9d6cf3090b9de8e7042104dbe8493b10f173603a
4
+ data.tar.gz: 63548a6d7f130d6771818f8387be0b548e74bcd1ed7dc856733b3f72c2a96fda
5
5
  SHA512:
6
- metadata.gz: c26cfb49d8896404c8702bf908740e2e1a19f3b18478411bd1244f3a7b4f940dacf89b2cbd260e7ea1ab90afc4b262a637f3260f784bd5b58f8fe7fd0f9b9571
7
- data.tar.gz: 6327f74958e882da485fffefaa098845016ccf83d4dc19b46d525e6d6d7f6017e57ec0ea612c39431f54c5f925615dd3c279b453126998033875ffd81da8762c
6
+ metadata.gz: e1380da8c13475de3a825f828bb3d9109a52690f45d49cabd1be5bcbb138a2f36d985a676b9637e8a992a6ee551dc0f204b9103916e17845ee3990673219ab2c
7
+ data.tar.gz: 1861237d6327330311899eb90f0f4e8baee3cf81287f6336fb2c0634ab86073c41fa3838b7c2f923a11093e43ae07d074ac0a1a68bdc8df0ed1b23f91356bee2
data/CHANGELOG.rdoc CHANGED
@@ -1,3 +1,7 @@
1
+ - Add :text_editor show_ui, to avoid escaping html code
2
+ - Fix action link on association column named record
3
+
4
+ = 4.0.0
1
5
  - Add tabbed_by to group of columns in forms. The columns in the group must be collection associations, with a common column or association, used to partition them in different tabs.
2
6
  - Fix tableless in rails >= 7.1
3
7
  - Stop using cow_proxy for thread safety:
@@ -7,6 +11,9 @@
7
11
  - Thread safety enabled by default, can't be disabled, deprecate ActiveScaffold.threadsafe!
8
12
  - Support subgroups on field search
9
13
 
14
+ = 3.7.11.1
15
+ - Fix action link on association column named record
16
+
10
17
  = 3.7.11
11
18
  - Add partial list_messages_content to reduce code duplication, and better support replacing list view with other way to render records
12
19
  - Support selector for records body in create_record_row JS method, better support replacing list view with other way to render records
@@ -1301,8 +1301,8 @@
1301
1301
  if (element.length > 0) {
1302
1302
  element.data(); // $ 1.4.2 workaround
1303
1303
  if (typeof(element.data('action_link')) === 'undefined' && !element.hasClass('as_adapter')) {
1304
- var parent = element.closest('.record');
1305
- if (parent.length === 0) parent = element.closest('.actions');
1304
+ var parent = element.parent().closest('.record');
1305
+ if (parent.length === 0) parent = element.parent().closest('.actions');
1306
1306
  if (parent.is('.record')) {
1307
1307
  // record action
1308
1308
  var target = parent.find('a.as_action');
@@ -14,14 +14,13 @@ module ActiveScaffold::Actions
14
14
  # don't apply if scope, subform inside subform, because constraints won't apply to parent_record
15
15
  apply_constraints_to_record parent_record unless @scope
16
16
  create_association_with_parent parent_record, check_match: true if nested?
17
+ cache_generated_id(parent_record, params[:generated_id])
17
18
  parent_record
18
19
  end
19
20
 
20
21
  def do_edit_associated
21
22
  @scope = params[:scope]
22
23
  @parent_record = params[:id].nil? ? new_parent_record : find_if_allowed(params[:id], :update)
23
-
24
- cache_generated_id(@parent_record, params[:generated_id]) if @parent_record.new_record?
25
24
  @column = active_scaffold_config.columns[params[:child_association]]
26
25
 
27
26
  @record = (find_associated_record if params[:associated_id]) ||
@@ -36,5 +36,14 @@ class ActiveScaffold::Bridges::TinyMce
36
36
  base.class_eval { alias_method :active_scaffold_search_text_editor, :active_scaffold_search_text }
37
37
  end
38
38
  end
39
+
40
+ module ShowColumnHelpers
41
+ def active_scaffold_show_text_editor(record, column, ui_options: column.options)
42
+ record.send(column.name).html_safe # rubocop:disable Rails/OutputSafety
43
+ end
44
+
45
+ # Alias, in case the column uses :tinymce form_ui
46
+ alias active_scaffold_show_tinymce active_scaffold_show_text_editor
47
+ end
39
48
  end
40
49
  end
@@ -2,7 +2,7 @@ module ActiveScaffold
2
2
  module Version
3
3
  MAJOR = 4
4
4
  MINOR = 0
5
- PATCH = 0
5
+ PATCH = 1
6
6
  FIX = nil
7
7
 
8
8
  STRING = [MAJOR, MINOR, PATCH, FIX].compact.join('.')
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_scaffold
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 4.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Many, see README
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-01-16 00:00:00.000000000 Z
11
+ date: 2025-02-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails