From 7d9f7d7219f5c06fa11037223a1b3aa2710af98c Mon Sep 17 00:00:00 2001 From: Ryan Eddy <44847768+RyanEddyIC@users.noreply.github.com> Date: Fri, 17 Jan 2025 08:45:57 -0500 Subject: [PATCH] Csp cucumber fixes 3 (#4922) * benefit application warning modal cucumber fix * broker employers cucumber fixes * fix disabled button check * general agency staff cucumber fixes * broker search cucumber fixes * job income cucumber fixes * ee waive cucumber fixes * update disabled button css selector * new plan year cucumber fixes * plan year filter cucumber fixes * fix admin paper cucumber step * extend oe cucumber fixes * rubocop fix * actual rubocop fix * update radio input checked selector --- app/assets/javascripts/group_selection.js | 11 ++-- app/assets/javascripts/plan_shopping.js.erb | 4 ++ .../ui-components/sidebars/plan_filters.js | 7 +++ .../_edit_open_enrollment.html.erb | 11 +--- .../_new_benefit_application.html.slim | 2 +- .../_oe_extendable_applications.html.erb | 14 +---- .../hbx_profiles/edit_open_enrollment.js.erb | 10 +++- .../new_benefit_application.js.erb | 4 ++ .../oe_extendable_applications.js.erb | 16 ++++- app/views/shared/_signup_progress.html.haml | 2 +- .../v1/filters/_plan_filters.html.erb | 6 +- ..._broker_agency_staff_information.html.slim | 20 +------ ...general_agency_staff_information.html.slim | 20 +------ .../benefit_sponsors/application.js.erb | 11 +++- .../broker_agency_staff_roles.js | 42 +++++++++++++ .../general_agency_staff_roles.js | 59 +++++++++++++++++++ .../broker_agency_staff_roles/_form.html.erb | 9 +-- .../_search_broker_agency.html.erb | 14 +---- .../broker_agency_staff_roles/new.html.slim | 29 +-------- .../broker_agency_staff_roles/new.js.erb | 8 +++ .../my_account/_benefits.html.erb | 6 +- .../general_agency_staff_roles/_form.html.erb | 6 -- .../_search_general_agency.html.erb | 2 +- .../general_agency_staff_roles/new.html.slim | 32 +--------- .../general_agency_staff_roles/new.js.erb | 9 ++- .../benefit_sponsors/application.html.slim | 1 + .../financial_assistance/income.js | 4 +- .../incomes/_job_income_form.html.erb | 5 +- .../_employers.html.erb | 18 ------ .../broker_agency_profiles/employers.js.erb | 17 +++++- .../carriers/_carriers_list.html.erb | 15 ++--- .../carriers/index.js.erb | 10 ++++ .../_relationship_benefit_fields.html.erb | 5 +- .../_plan_selection_form.html.erb | 17 ------ .../plan_selections/new.js.erb | 23 ++++++++ .../plans/_plans.html.erb | 22 +------ .../plan_design_proposals/plans/index.js.erb | 23 ++++++++ .../step_definitions/admin_paper_phone.rb | 2 +- .../household_info_continue_button_steps.rb | 2 +- features/step_definitions/renewal_steps.rb | 2 +- 40 files changed, 283 insertions(+), 237 deletions(-) create mode 100644 components/benefit_sponsors/app/assets/javascripts/benefit_sponsors/broker_agency_staff_roles.js create mode 100644 components/benefit_sponsors/app/assets/javascripts/benefit_sponsors/general_agency_staff_roles.js diff --git a/app/assets/javascripts/group_selection.js b/app/assets/javascripts/group_selection.js index 39dbb7896b0..e87ad36fe28 100644 --- a/app/assets/javascripts/group_selection.js +++ b/app/assets/javascripts/group_selection.js @@ -8,13 +8,12 @@ $(document).on('change', '#market_kind_coverall', function() { }); function setGroupSelectionHandlers(){ - var employers = $("[id^=census_employee_]"); hideAllErrors(); if ($("#employer-selection .n-radio-group .n-radio-row").length) { - var checked_er = $("#employer-selection .n-radio-group .n-radio-row input[checked^= 'checked']:enabled"); + var checked_er = $("#employer-selection .n-radio-group .n-radio-row input:checked:enabled"); if (checked_er.length) { var employer_id = checked_er.val(); @@ -158,9 +157,9 @@ function errorsForChangeInEmployer(element) { } function errorsForChangeInCoverageKind(employer_id){ - $('#coverage_kind_health').on('change', function() { + $(document).on('change', '#coverage_kind_health', function() { hideAllErrors(); - if ($("#employer-selection .n-radio-group .n-radio-row input[checked^= 'checked']:enabled").length) { + if ($("#employer-selection .n-radio-group .n-radio-row input:checked:enabled").length) { $(".health_errors_" + employer_id ).show(); disableShopHealthIneligible(employer_id); @@ -173,9 +172,9 @@ function errorsForChangeInCoverageKind(employer_id){ } }); - $('#coverage_kind_dental').on('change', function() { + $(document).on('change', '#coverage_kind_dental', function() { hideAllErrors(); - if ($("#employer-selection .n-radio-group .n-radio-row input[checked^= 'checked']:enabled").length) { + if ($("#employer-selection .n-radio-group .n-radio-row input:checked:enabled").length) { $(".dental_errors_" + employer_id ).show(); disableShopDentalIneligible(employer_id); diff --git a/app/assets/javascripts/plan_shopping.js.erb b/app/assets/javascripts/plan_shopping.js.erb index 032290e1562..88dbd6225a6 100644 --- a/app/assets/javascripts/plan_shopping.js.erb +++ b/app/assets/javascripts/plan_shopping.js.erb @@ -443,6 +443,10 @@ $(document).on("click", ".reference_plan_info h4 span", function() { $(this).parents(".reference_plan_info").find('.content').toggle(); }); +$(document).on('click', '.waive-disable-selectric-btn', function() { + disableSelectricInModal() +}) + function disableSelectricInModal() { $('#waive_confirm').on('shown.bs.modal', function (e) { $('select#waiver_reason_selection_dropdown').selectric('destroy'); diff --git a/app/assets/javascripts/ui-components/sidebars/plan_filters.js b/app/assets/javascripts/ui-components/sidebars/plan_filters.js index 0dd19735bc7..a5c3866d0c2 100644 --- a/app/assets/javascripts/ui-components/sidebars/plan_filters.js +++ b/app/assets/javascripts/ui-components/sidebars/plan_filters.js @@ -29,6 +29,8 @@ function filterPlanNetwork(element) { processValues(element); } +$(document).on('change', '.plan-carrier-selection-filter.v1-filter', function() { filterPlanCarriers(this) }) + function filterPlanCarriers(element) { filterParams.selectedCarrier = element.value; } @@ -115,6 +117,11 @@ function clearAll() { filterParams.deductibleToAmountValue = ''; } +$(document).on('click', '.apply-filters-btn', function(e) { + e.preventDefault() + filterResults() +}) + // Gets the filtered Results function filterResults() { filterResultsSelections(filterParams); diff --git a/app/views/exchanges/hbx_profiles/_edit_open_enrollment.html.erb b/app/views/exchanges/hbx_profiles/_edit_open_enrollment.html.erb index 682fded968b..e4de9d40435 100644 --- a/app/views/exchanges/hbx_profiles/_edit_open_enrollment.html.erb +++ b/app/views/exchanges/hbx_profiles/_edit_open_enrollment.html.erb @@ -40,22 +40,15 @@