mirror of
https://github.com/zulip/zulip.git
synced 2026-07-12 21:04:41 +08:00
settings_profile_fields: Pass Jquery consistently.
This commit is contained in:
parent
448870225b
commit
e40ef29e63
@ -271,7 +271,7 @@ function add_choice_row(e) {
|
||||
// which will not have the delete button so that there is at least one option present.
|
||||
$curr_choice_row.find("button.delete-choice").show();
|
||||
const choices_div = e.delegateTarget;
|
||||
create_choice_row(choices_div);
|
||||
create_choice_row($(choices_div));
|
||||
}
|
||||
|
||||
function delete_choice_row(row) {
|
||||
@ -665,7 +665,7 @@ export function do_populate_profile_fields(profile_fields_data) {
|
||||
function set_up_select_field() {
|
||||
const field_types = realm.custom_profile_field_types;
|
||||
|
||||
create_choice_row("#profile_field_choices");
|
||||
create_choice_row($("#profile_field_choices"));
|
||||
|
||||
if (current_user.is_admin) {
|
||||
const choice_list = $("#profile_field_choices")[0];
|
||||
|
||||
@ -36,7 +36,7 @@ function get_chosen_default_streams() {
|
||||
|
||||
function create_choice_row() {
|
||||
const $container = $("#default-stream-choices");
|
||||
const value = settings_profile_fields.get_value_for_new_option("#default-stream-choices");
|
||||
const value = settings_profile_fields.get_value_for_new_option($container);
|
||||
const stream_dropdown_widget_name = `select_default_stream_${value}`;
|
||||
const row_html = render_default_stream_choice({value, stream_dropdown_widget_name});
|
||||
$container.append($(row_html));
|
||||
|
||||
Loading…
Reference in New Issue
Block a user