Skip to content

Commit

Permalink
no need for JS to disable/enable form according to tab, as they are a…
Browse files Browse the repository at this point in the history
…lways the same form #2134
  • Loading branch information
stuzart committed Mar 11, 2025
1 parent 82e2aab commit 2f2c966
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
2 changes: 0 additions & 2 deletions app/views/extended_metadata_types/_form.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@
let switchFormTarget = function () {
let form = $j('#extended_metadata_type_upload_from');
let id = $j('.tab-pane.active', form)[0].id;
$j('.tab-pane :input', form).attr('disabled', true);
$j('.tab-pane.active :input', form).attr('disabled', false);

if (id == 'from-json') {
form[0].action = '<%= extended_metadata_types_path -%>';
Expand Down
2 changes: 0 additions & 2 deletions app/views/sample_types/new.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@
let switchFormTarget = function () {
let form = $j('#new_sample_type');
let id = $j('.tab-pane.active', form)[0].id;
$j('.tab-pane :input', form).attr('disabled', true);
$j('.tab-pane.active :input', form).attr('disabled', false);

if (id == 'from-template') {
form[0].action = '<%= create_from_template_sample_types_path -%>';
Expand Down

0 comments on commit 2f2c966

Please sign in to comment.