-
-
Notifications
You must be signed in to change notification settings - Fork 503
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make dropdown lists alphabetical order ( Part 1) #4663
base: main
Are you sure you want to change the base?
Changes from 2 commits
7660641
1debbbb
58766a5
48fbe14
4b03f49
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -801,4 +801,4 @@ DEPENDENCIES | |
webmock (~> 3.23) | ||
|
||
BUNDLED WITH | ||
2.5.16 | ||
2.5.19 |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,8 +15,9 @@ | |
<span class="li-name w-100"> | ||
<%= field.input :item_id, | ||
disabled: requested.present?, | ||
collection: @items, prompt: "Choose an item", | ||
include_blank: "", | ||
collection: @items, | ||
prompt: "Choose an item", | ||
include_blank: false, # We've got a prompt, so no need for an include blank | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
label: false, | ||
input_html: { class: "my-0 line_item_name", "data-controller": "select2" } %> | ||
<% if requested.present? %> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,8 @@ | |
label: label, | ||
error: error, | ||
selected: storage_location_for_source(source.object), | ||
include_blank: true, | ||
include_blank: false, | ||
prompt: "Choose a storage location", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
input_html: { | ||
data: { | ||
storage_location_inventory_path: inventory_storage_location_path( | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -149,7 +149,9 @@ def random_record_for_org(org, klass) | |
user = User.create( | ||
email: user_data[:email], | ||
password: 'password!', | ||
password_confirmation: 'password!' | ||
password_confirmation: 'password!', | ||
organization: user_data[:organization], # Any reason not to set this? | ||
name: user_data[:email].split('@').first # Any reason not to set this? | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Was there a reason why we weren't ensuring that an organization and name were in place for users? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Once upon a time we needed organizations for bank users. We changed to a role-based access for all users so it is no longer needed. Super users and partners wouldn't have had an organization from the get-go. As for names, I think all the bank users in production have names, but not all the partner users do. Does that help? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ahhhh I see, that does help thank you! I'll get rid of these two additions and keep that in mind moving forward. |
||
) | ||
|
||
if user_data[:organization] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This wasn't being used anywhere, so I opted to remove it and look to order user select fields on the instance vars defined in relevant controller files.