Skip to content
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

cmartine/APPEALS-50366 #22618

Merged
merged 12 commits into from
Sep 3, 2024
Merged

Conversation

Chris-Martine
Copy link
Contributor

@Chris-Martine Chris-Martine commented Aug 27, 2024

Resolves Implement Banner on Edit Page

Description

Changes were made so a banner that states that compensation and pension type intakes are no longer editable in caseflow shows when the intakes benefit type in compensation or pension.

Acceptance Criteria

  • Method added in IntakeEditFrame with logic to only return the banner component if the benefit type is "compensation" or "pension" and remove_comp_and_pen_intake feature toggle is enabled
  • PageRoute for banner component added in IntakeEditFrame to display banner depending on method added
  • Banner component created using our standard banner component and the banner message string provided in UI mock up is saved in the COPY file and used in banner component
  • Jest tests exists to test:
  • banner displays when feature toggle is enabled and the benefit type is "compensation" or "pension" 
  • banner does NOT displays when feature toggle is enabled and the benefit type is NOT "compensation" or "pension" 
  • banner does NOT displays when feature toggle is disabled and the benefit type is "compensation" or "pension" 
  • banner does NOT displays when feature toggle is disabled and the benefit type is NOT "compensation" or "pension" 

Testing Plan

  1. Go to Write test plans for disablement of Edit page

Frontend

User Facing Changes

  • Screenshots of UI changes added to PR & Original Issue

BEFORE|AFTER
image
image

Tests

Test Coverage

Did you include any test coverage for your code? Check below:

  • RSpec
  • Jest
  • Other

Copy link
Contributor

@mattray-gov mattray-gov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mattray-gov mattray-gov merged commit 2e797d1 into feature/APPEALS-42187-49667 Sep 3, 2024
17 checks passed
mattray-gov added a commit that referenced this pull request Sep 12, 2024
* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
mattray-gov added a commit that referenced this pull request Sep 23, 2024
* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
mattray-gov added a commit that referenced this pull request Sep 24, 2024
* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* add metabase to m1 docker compose

* rename metabase container and specify a version

* add script for initial metabase setup

* script output formatting

* add metabase directory

* move to a dockerfile, implement VACOLS to setup script

* add metabase to original docker-compose

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* add step to initialize metabase in demo startup

* update demo startup.sh to initialize metabase with absolute path

* add make command for local metabase setup

* fix makefile syntax error

* update scripts to work in AWS

* update demo script to use apt-get instead of yum

* update demo script to use dns for vacols-db

* fix vacols DB docker DNS name

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Craig Reese <109101548+craigrva@users.noreply.github.com>
mattray-gov added a commit that referenced this pull request Oct 7, 2024
* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* add metabase to m1 docker compose

* rename metabase container and specify a version

* add script for initial metabase setup

* script output formatting

* add metabase directory

* move to a dockerfile, implement VACOLS to setup script

* add metabase to original docker-compose

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* add step to initialize metabase in demo startup

* update demo startup.sh to initialize metabase with absolute path

* add make command for local metabase setup

* fix makefile syntax error

* update scripts to work in AWS

* update demo script to use apt-get instead of yum

* update demo script to use dns for vacols-db

* fix vacols DB docker DNS name

* hotfix/APPEALS-23420: search defect

Add search query service for the api response for the `/search` page
  Add issues to legacy appeals
  Add assigned_to_judge
  Use correct id for list of request issues
  export proper attributes for hearing

* Revert "hotfix/APPEALS-23420: search defect" (#23011)

This reverts commit 25ed7f1.

* Merge `feature/APPEALS-41559` into `release/FY24Q4.6.1` (#23036)

* Start feature work tracking PR with a TODO comment

* Remove TODO comment for CodeClimate

* SeanC/APPEALS-42315 | Create separate Remand table, model and seed data (#22220)

* added migration file for adding type column to supplemental claims table

* created stub for remand model

* added type to supplemental claim factory and new remand trait

* added remand sc's to vha seeds

* updated migration name and fixed typo

* Changed migration to inherit from Caseflow::Mirgration

* schema changes

* reverting schema

* changed the setting of the type column

* fixed schema and renamed migration file

* fixed migration and schema

* updated the remands factory and seeds

* fixed comment in schema

---------

Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>

* TYLERB/APPEALS-42455: Display new and migrated Remands in Decision Review Queue tabs (#22206)

* Added support for remands to the business_line.rb model and the index.js util file that parses the decision review type filters for the decision review queue.

* Updated the business line spec file, the decision reviews controller spec tests, and the reviews spec feature test to support remands.

* Added a decision review polymorphic helper to DRY up some of the polymorphic appeal concerns.

* Overrode the remand model association to request issues so active record joins will work correctly.

* Added another helper for sti polymorphic relationships. Fixed filtering for STI decision review types for remands. Updated tests and added factories for testing.

* Code climate fixes and test fixes.

* Fixed more test failures. Removed the remand request issues relationship since it was incorrectly implemented. Added a scope to supplemental claims for remands. Fixed an issue where board grant effectuation tasks without request issues were missing from the new task type count method.

* Changed the UNION ALL to a UNION in the new task_type_count method to prevent duplicate row counts. Updated tests and fixed an issue where the board grant effectuation tasks were being counted for pending task queries.

* JHoang/APPEALS-42318 (#22270)

* some preliminary remand & sc model updates

* typo

* some preliminary hlr checks?

* undo seed change

* decision issue and sc updates

* attempt code climate fixes

* another code climate fix

* testing changes

* useless variable..

* fix conditional in decision issue

* fix undefined find_by method

* attempt rspec fix

* rspec fix attempt #2

* supplemental_claim_spec fix?

* remove comma

* code climate fix

* added comment for transparency on remand creation, attempt fix for remands route

* updated specs for decision_issue, hlr_spec, appeal_spec to account for remand creation type

* fix lint error

* fix lint error #2

---------

Co-authored-by: Jonathan Hoang <trinhjoanthan.hoang@va.gov>

* APPEALS-42458 (#22365)

* disable edit issues link for remands

* add banners explaining that remands are not editable

also makes sure that remands are not editable on the edit issues page

* TYLERB/APPEALS-44922: Update Generate task report page UI to include Remand in conditions (#22356)

* Initial commit. Changed the DecisionReviewType condition filter to a searchable dropdown and added the remands option to it as well. Updated the report page filter parsing to work with the searchable dropdown instead of checkboxes for the decision review type condition filter.

* Updated the ReportPage jest test and the report page feature test to work with the decision review type filter as a searchable dropdown instead of checkboxes.

* SeanC/APPEALS-42317 | Migrate existing Supplemental Claim Remands to Remand records via script (#22359)

* initial verison of update script

* remanded migration file

* updated sc spec with type

* schema

* fixed a few issues in the migration

* small fix to migration file

* moved the type column check into a seperate it block

* fixed wrong column in migration file

* created a new migration for creating the view

* updated the backfill migration file

---------

Co-authored-by: Brandon Lee Dorner <Brandondorner@yahoo.com>

* J hoang/appeals 44940 (#22428)

* initial

* some factory and spec updates

* change history query update and spec fixes

* code climate/lint fix

* change @claim_type identifier

* fix claim_history_event_spec.rb

* test coverage for change history with Remand claim type

* spec lint fixes

* refactor claim_type filtering to account for remand subtype

* business_line_spec fix

* decision_reviews_controller_spec update for remand claim type

* lint fixes for decision_reviews_controller_spec.rb

* comment updates in business_line.rb

* renamed mock data in change_history_reporter_spec

* trigger GA

* refactor claim type filter for less conditional handling

* business line spec fix

---------

Co-authored-by: Jonathan Hoang <trinhjoanthan.hoang@va.gov>

* Initial commit for the brakeman sql injection warning fixes. (#22598)

* Updated the business line reporter class to properly display Remands as a seperate type than SupplementalClaims. Also added additional testing logic for the business line reporter for hlr and scs since it was only covering appeals. (#22664)

Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>

* Fixed a bug where the frontend would error due to calling .toLowerCase() on a null or undefined value which could happen sometimes if the api filter options are in an incorrect state. (#22796)

Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>

* Updated the remand migration files to work with the rails 6 upgrade and the changes to Caseflow::Migration. (#22825)

* added fix for failing test in decision_reviews_controller_spec (#22829)

---------

Co-authored-by: Robert Travis Pierce <Pierce_Robert@ne.bah.com>
Co-authored-by: Sean Craig <110493538+seancva@users.noreply.github.com>
Co-authored-by: Tyler Broyles <109369527+TylerBroyles@users.noreply.github.com>
Co-authored-by: jonathanh-va <111081469+jonathanh-va@users.noreply.github.com>
Co-authored-by: Jonathan Hoang <trinhjoanthan.hoang@va.gov>
Co-authored-by: Brandon Lee Dorner <Brandondorner@yahoo.com>
Co-authored-by: Clay Sheppard <csheepy@gmail.com>

* APPEALS-50679 | Reassign Cases To Camo Change History (#23038)

* Start feature work tracking PR with a TODO comment

* Remove TODO comment for CodeClimate

* SeanC/APPEALS-42315 | Create separate Remand table, model and seed data (#22220)

* added migration file for adding type column to supplemental claims table

* created stub for remand model

* added type to supplemental claim factory and new remand trait

* added remand sc's to vha seeds

* updated migration name and fixed typo

* Changed migration to inherit from Caseflow::Mirgration

* schema changes

* reverting schema

* changed the setting of the type column

* fixed schema and renamed migration file

* fixed migration and schema

* updated the remands factory and seeds

* fixed comment in schema

---------

Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>

* TYLERB/APPEALS-42455: Display new and migrated Remands in Decision Review Queue tabs (#22206)

* Added support for remands to the business_line.rb model and the index.js util file that parses the decision review type filters for the decision review queue.

* Updated the business line spec file, the decision reviews controller spec tests, and the reviews spec feature test to support remands.

* Added a decision review polymorphic helper to DRY up some of the polymorphic appeal concerns.

* Overrode the remand model association to request issues so active record joins will work correctly.

* Added another helper for sti polymorphic relationships. Fixed filtering for STI decision review types for remands. Updated tests and added factories for testing.

* Code climate fixes and test fixes.

* Fixed more test failures. Removed the remand request issues relationship since it was incorrectly implemented. Added a scope to supplemental claims for remands. Fixed an issue where board grant effectuation tasks without request issues were missing from the new task type count method.

* Changed the UNION ALL to a UNION in the new task_type_count method to prevent duplicate row counts. Updated tests and fixed an issue where the board grant effectuation tasks were being counted for pending task queries.

* JHoang/APPEALS-42318 (#22270)

* some preliminary remand & sc model updates

* typo

* some preliminary hlr checks?

* undo seed change

* decision issue and sc updates

* attempt code climate fixes

* another code climate fix

* testing changes

* useless variable..

* fix conditional in decision issue

* fix undefined find_by method

* attempt rspec fix

* rspec fix attempt #2

* supplemental_claim_spec fix?

* remove comma

* code climate fix

* added comment for transparency on remand creation, attempt fix for remands route

* updated specs for decision_issue, hlr_spec, appeal_spec to account for remand creation type

* fix lint error

* fix lint error #2

---------

Co-authored-by: Jonathan Hoang <trinhjoanthan.hoang@va.gov>

* APPEALS-42458 (#22365)

* disable edit issues link for remands

* add banners explaining that remands are not editable

also makes sure that remands are not editable on the edit issues page

* TYLERB/APPEALS-44922: Update Generate task report page UI to include Remand in conditions (#22356)

* Initial commit. Changed the DecisionReviewType condition filter to a searchable dropdown and added the remands option to it as well. Updated the report page filter parsing to work with the searchable dropdown instead of checkboxes for the decision review type condition filter.

* Updated the ReportPage jest test and the report page feature test to work with the decision review type filter as a searchable dropdown instead of checkboxes.

* SeanC/APPEALS-42317 | Migrate existing Supplemental Claim Remands to Remand records via script (#22359)

* initial verison of update script

* remanded migration file

* updated sc spec with type

* schema

* fixed a few issues in the migration

* small fix to migration file

* moved the type column check into a seperate it block

* fixed wrong column in migration file

* created a new migration for creating the view

* updated the backfill migration file

---------

Co-authored-by: Brandon Lee Dorner <Brandondorner@yahoo.com>

* J hoang/appeals 44940 (#22428)

* initial

* some factory and spec updates

* change history query update and spec fixes

* code climate/lint fix

* change @claim_type identifier

* fix claim_history_event_spec.rb

* test coverage for change history with Remand claim type

* spec lint fixes

* refactor claim_type filtering to account for remand subtype

* business_line_spec fix

* decision_reviews_controller_spec update for remand claim type

* lint fixes for decision_reviews_controller_spec.rb

* comment updates in business_line.rb

* renamed mock data in change_history_reporter_spec

* trigger GA

* refactor claim type filter for less conditional handling

* business line spec fix

---------

Co-authored-by: Jonathan Hoang <trinhjoanthan.hoang@va.gov>

* Initial commit for the brakeman sql injection warning fixes. (#22598)

* Updated the business line reporter class to properly display Remands as a seperate type than SupplementalClaims. Also added additional testing logic for the business line reporter for hlr and scs since it was only covering appeals. (#22664)

Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>

* Fixed a bug where the frontend would error due to calling .toLowerCase() on a null or undefined value which could happen sometimes if the api filter options are in an incorrect state. (#22796)

Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>

* Updated the remand migration files to work with the rails 6 upgrade and the changes to Caseflow::Migration. (#22825)

* added fix for failing test in decision_reviews_controller_spec (#22829)

* Al/APPEALS-45335 (#22228)

* added additional option to check box list

* fixed some tests and code clean up

* fixed more tests

* fixed jest tests

* changes per Pr feedback

* added custom error display

* fixed style for error message

---------

Co-authored-by: Sean Craig <sean.craig2@va.gov>

* adding logic to bring in issue-modification request and updating the … (#22238)

* adding logic to bring in issue-modification request and updating the csv logic

* refactor logic to get pending status and null to request addition

* pending status filter work fixing

* adding withdrawal date and adding logic to display request issue components

* getting edit of request rows and fixing cancelled data

* fixing linter and fixing the query to make test happy

* fixing specs failures

* removing byebug

* removing frontend changes, adding test, fixing the query to replace higherlevel review,adding new field in serializer

* making code climate happy by doing some minor refactor

* fixing the serializer spec failure

* After merging APPEALS-45335, filter for Requested issues were broken, so refactored it and removed the unnecessary methood that i created

* fixing code climate and spec was failing because of hard coded date

* refactor the edit of request logic to take from version, refactored business line query to remove coalesce and fix test

* fixing codeclimate, remove unnecessary field

* refactor to make first comment appear first in edit of request

* fixing linter issue, spec and refactor to fix the bug

* fixing pending status filter issue and adding test for business line

* fixing broken spec failure

* adding user facilty

* fixing the lead and lag function to prevent entry of pending status multiple times

* fixing an issue in which in progress event was not being made

* adding decision reason that was missed and fixing the event logic one more time

* fixing the multiple issue modification request after decision has been made

* refactor inprogress logic for approved data

* fixing spec failure

* fixing the first version logic to be more simpler and fixing name and adding spec

* fixing more inprogess event

* removing the disabled complexity and taking out the boolean condition to a separate method

* Al/APPEALS-45334 Individual change history table which includes Reassign Cases to CAMO events (#22483)

* added logic for claim history events table

* fixed linting errors

* fixing test failures

* added change Pr feedback

* PR feedback round 2

* changes from round 2 of PR feedback

* Added logic event data versions and tests to cover more edgecases

* changed RequestedIssueFragment

* Updated the individual claim history spec file for test failures. Updated an attribute in the IndividualClaimHistory page that was using the wrong getter. Fixed a code climate linting error.

* Removing unnecessary clear filter

* Combined some of the individual claim history tests into one test so it will run more quickly.

* fixing the withdrawal date versioning issue for different level changes

* fixing the spec failure and linter

---------

Co-authored-by: Brandon Lee Dorner <Brandondorner@yahoo.com>
Co-authored-by: = <tyler.broyles@va.gov>
Co-authored-by: Prajwal Amatya <pamatya@take2it.com>

* TYLERB/APPEALS-57367: change-history-updates (#22479)

* Initial commit with new tests cases for issue modification requests for change history.

* Added two cte queries to the business line change history query to properly work with a lead for the issue modification requests. Added new methods into the claim history event to work with this new lead and modified the existing issue modification in progress and pending event generation methods to better reflect the state of a claim that is going through the issue modficiation process.

* Cleaned up unused code and todos.

* Updated the claim history event create_imr_in_progress_status_event? with even more logic and edge cases.

* Fixed a possible error when with a greater than operator could be used on a null value.

* Fixed a few rspec tests.

* Renamed a method and fixed a few code climate issues.

* Fixed a bug in event status generation if there is a task with versions but no versions that change status.

* Updated tests to work with new logic and remove a todo statement.

* Fixed code complexity warnings.

* Updated serializer spec to work with the bug fix.

* Adjusted the pending method to prevent possible race conditions.

* Fixed a bug where the incorrect decision event user would be shown for an issue modification request creation if the request has been decided when it should be the requestor as the event user.

* Added the correct css ids to a few IMR change history events so that the filtering would work correctly. Also added some additional sql to properly filter based on css id and station id for requestor and decider joins.

* Updated the IMR business line logic so that the decided at fields would always account for cancelled status since it uses updated at instead of decided at to determine when the IMR was closed. Fixed a bit of logic in the claim history event IMR in progress event generation to work another edge case.

* Added in previous IMR edit versions for displaying it to the user.

* Added a test for the change history service class to verify that request edit events have the correct attributes from the previous edits.

* Fixed a typo for one of the table aliases in the business line query.

* Fixed another typo where the facilities filter was using css id instead of station id from a copy/paste error.

* adding changes for previous state array and some test modification

* adding test for previous data

* Fixed some outstanding test failures.

* Fixed a linting error. Removed some duplicated code that happened when merging in the feature branch. Updated a factorybot method that was causing tests to fail.

* Fixed a few code climate warnings.

* Removed some puts statements in the individual claim history feature test.

---------

Co-authored-by: Prajwal Amatya <pamatya@take2it.com>

* TYLERB/APPEALS-58656: Change History CSV and Version Parsing fix (#22874)

* Fixed a modification request claim history in progress event generation bug that could occur when 3-4 pending requests were all created at the same time and then later cancelled at the same time. Also fixed an issue count bug used when building the issue type filter due to additional duplicate rows being inserted into issue type count query due to the left join to the issue modification requests table.

* Altered the version parsing for change history to work with commas in the version strings since that was causing parsing errors. Altered the business line query to use '|||' as a delimeter instead of comma and also changed the array_agg functions to string agg to avoid the '{}' array type casting that was happening between postgres and rails. Updated tests to work with this new parsing.

* Updated vha seed data to have associations to intake data so those seeded claims can correctly generate change history.

* TYLERB/CHANGE-HISTORY-YAML-QUOTE-FIX (#22910)

* Made an update to the claim history parse versions method to work with double quotations after the array_agg to string_agg change.

* Updated the tests to work with the new string agg and version parsing method.

* Skip flakey tests

These are possibly flakey now due to the rails upgrade. We can come
back and fix these once the work has been confirmed in UAT.

* Add rubocop disables for line length

These should be removed when the skips are removed.

* Updated the report_page feature test to reduce flakyness in github actions. Also updated the DownloadHelpers module.

---------

Co-authored-by: Brandon Dorner <brandonleedorner@gmail.com>

---------

Co-authored-by: Robert Travis Pierce <Pierce_Robert@ne.bah.com>
Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>
Co-authored-by: Sean Craig <110493538+seancva@users.noreply.github.com>
Co-authored-by: Tyler Broyles <109369527+TylerBroyles@users.noreply.github.com>
Co-authored-by: jonathanh-va <111081469+jonathanh-va@users.noreply.github.com>
Co-authored-by: Jonathan Hoang <trinhjoanthan.hoang@va.gov>
Co-authored-by: Clay Sheppard <csheepy@gmail.com>
Co-authored-by: almorbah <149511814+almorbah@users.noreply.github.com>
Co-authored-by: Sean Craig <sean.craig2@va.gov>
Co-authored-by: Prajwal Amatya <122557351+pamatyatake2@users.noreply.github.com>
Co-authored-by: = <tyler.broyles@va.gov>
Co-authored-by: Prajwal Amatya <pamatya@take2it.com>

* APPEALS-54874: Update PG and Ruby-oci8 gems (#23041)

* update minimum version in gemfile and ran bundle install (#22503)

* require ruby-oci8 in config/boot.rb to fix SIGV fault

* APPEALS-59294: Hearings seed file is creating DistributionTasks for legacy appeals (#23042)

* set parent task for legacy appeal hearing tasks to root task

* fix whitespace issue

* APPEALS-36292: Conditionally render banner alerts based on which environment it is deployed on (#23040)

* Conditionally render alerts based on which environment is deployed

* setting Env alert banner sitewide

* separate colors for different envs using the same alert type

* lighter reds for prodtest alert so the text is more readable

* give demo banner more contrast

* adjust specific language for demo env

* adjust logic to accept proper env var. Add style for preprod (yellow)

* isolate env alert styles

* remove duplicate 'demo' Alert

* remove development env banner to fix tests

* making conditional logic a little more bulletproof against 'production'

* update CaseWorkerIndex snapshot

* fix env var

* update snapshot from hard 'uat' setting

* conditionally render env alert on only the home page

* sticky env header statuses

* getting development alert banners to work

* target correct frontend dependency for NavigationBar changes

* connecting new frontend package with better prod exclusion logic

* make the prodtest env badge a more readable color

* cleaning up testing code

* fix linting issues

* Remove unnecessary space

* new NavigationBar update

* yarn install of new FE dependency

* remove extra package.json

* remove development env logic due to NODE_ENV bug

* fixing broken logo link padding and colors

* hardening logic to exclude other inputs

* correcting operator logic

* remove testing var

* point caseflow-frontend to master

* point at most recent caseflow-frontend master

* linting issues fix

* update Route and CaseWorker snapshot

* update snapshot for process.env.DEPLOY_ENV

---------

Co-authored-by: Sean Parker <Sean.Parker3@va.gov>

* Master to Main documentation changes (#23034)

* Update WINDOWS_11.md replacing master with main

* References to master are changed to main where applicable

* Hotfix/appeals 37269  (#23039)

* adds script and tests for the script

* adjust the way scheduled_for is created since the previous method was removed

* refactor some of the script

* rename test file to include _spec

* Empty-Commit

---------

Co-authored-by: Zackary Borges-Rowe <borges-rowe_zackary@bah.com>
Co-authored-by: Raymond Hughes <131811099+raymond-hughes@users.noreply.github.com>

* Revert "Release R2.6.0 FY24Q4.6.0"

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Craig Reese <109101548+craigrva@users.noreply.github.com>
Co-authored-by: ryanpmessner <163380175+ryanpmessner@users.noreply.github.com>
Co-authored-by: Ron Wabukenda <130374706+ronwabVa@users.noreply.github.com>
Co-authored-by: Robert Travis Pierce <robert@roberttravispierce.com>
Co-authored-by: Robert Travis Pierce <Pierce_Robert@ne.bah.com>
Co-authored-by: Sean Craig <110493538+seancva@users.noreply.github.com>
Co-authored-by: Tyler Broyles <109369527+TylerBroyles@users.noreply.github.com>
Co-authored-by: jonathanh-va <111081469+jonathanh-va@users.noreply.github.com>
Co-authored-by: Jonathan Hoang <trinhjoanthan.hoang@va.gov>
Co-authored-by: Brandon Lee Dorner <Brandondorner@yahoo.com>
Co-authored-by: Clay Sheppard <csheepy@gmail.com>
Co-authored-by: almorbah <149511814+almorbah@users.noreply.github.com>
Co-authored-by: Sean Craig <sean.craig2@va.gov>
Co-authored-by: Prajwal Amatya <122557351+pamatyatake2@users.noreply.github.com>
Co-authored-by: = <tyler.broyles@va.gov>
Co-authored-by: Prajwal Amatya <pamatya@take2it.com>
Co-authored-by: Sean Parker <Sean.Parker3@va.gov>
Co-authored-by: Raymond Hughes <131811099+raymond-hughes@users.noreply.github.com>
Co-authored-by: Zackary Borges-Rowe <borges-rowe_zackary@bah.com>
nkutub pushed a commit that referenced this pull request Oct 8, 2024
* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
nkutub added a commit that referenced this pull request Oct 8, 2024
* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>

* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------

Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* added bgs_source to parser, controller and serializer along with specs (#21621)

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>

* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------

Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>

* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------

Co-authored-by: nader k <nader@nkconsulting.net>

* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* renamed epe to singular method call (#22914)

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Feature/appeals 49667 prodtest1.1.0 (#23143)

* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Kodi Shiflett <kodishiflett@gmail.com>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
nkutub added a commit that referenced this pull request Oct 13, 2024
* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
nkutub added a commit that referenced this pull request Oct 13, 2024
* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Initial commit (#22494)

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

---------

Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
nkutub added a commit that referenced this pull request Oct 15, 2024
* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>

* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------

Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* added bgs_source to parser, controller and serializer along with specs (#21621)

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>

* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------

Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>

* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------

Co-authored-by: nader k <nader@nkconsulting.net>

* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* renamed epe to singular method call (#22914)

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------

Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* remove _ext_ table from schema

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
nkutub added a commit that referenced this pull request Oct 16, 2024
* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>

* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------

Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* added bgs_source to parser, controller and serializer along with specs (#21621)

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>

* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------

Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>

* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------

Co-authored-by: nader k <nader@nkconsulting.net>

* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* renamed epe to singular method call (#22914)

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------

Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
nkutub added a commit that referenced this pull request Oct 17, 2024
* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>

* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------

Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* added bgs_source to parser, controller and serializer along with specs (#21621)

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>

* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------

Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>

* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------

Co-authored-by: nader k <nader@nkconsulting.net>

* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* renamed epe to singular method call (#22914)

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------

Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
nkutub added a commit that referenced this pull request Oct 17, 2024
* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
nkutub added a commit that referenced this pull request Oct 18, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
craigrva added a commit that referenced this pull request Oct 18, 2024
…23276)

* Feature/appeals 49670 49667 phase ii release tested (#23257) (#23269)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* Update seed and test data files to fix typo

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
AdamShawBAH pushed a commit that referenced this pull request Oct 19, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
AdamShawBAH pushed a commit that referenced this pull request Oct 19, 2024
…23276)

* Feature/appeals 49670 49667 phase ii release tested (#23257) (#23269)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* Update seed and test data files to fix typo

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 20, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
AdamShawBAH pushed a commit that referenced this pull request Oct 20, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
AdamShawBAH pushed a commit that referenced this pull request Oct 20, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
AdamShawBAH pushed a commit that referenced this pull request Oct 20, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
hawkespoulterva pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
hawkespoulterva pushed a commit that referenced this pull request Oct 21, 2024
…23276)

* Feature/appeals 49670 49667 phase ii release tested (#23257) (#23269)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* Update seed and test data files to fix typo

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
ThorntonMatthew added a commit that referenced this pull request Oct 21, 2024
* Feature/appeals 49670 49667 phase ii release tested (#23257)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>

* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------

Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* added bgs_source to parser, controller and serializer along with specs (#21621)

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>

* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------

Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>

* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316c85e2c3d8cd94c1baae6d29d75503163d, reversing
changes made to 66cf311d1ddb18d11137b173b94ecbafaa022e2b.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830c5df26e9d4830fcf1d66ea77af4703346.

---------

Co-authored-by: nader k <nader@nkconsulting.net>

* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* renamed epe to singular method call (#22914)

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727ceb3211d4b2f910ab6a42dd5483fa3481.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------

Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a908239795bee8ae9c39e570d911697f85d.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96cb2a8859f526b710a71479dc44fb3017a.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f21ac6f1240a9c294046eabce1bb431d66c.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* hotfix/APPEALS-59737 and APPEALS-59667 (RC) (#23263)

* Have time slots handle aliased timezones properly

* Add Indianapolis alias

* Pluck RTL version of the ScheduleVeteranForm from the Node 18 upgrade branch.

Co-authored-by: AdamShawBAH <adam.shaw@va.gov>

* Add unrecognized timezones to tz initializer

* Add spec file for initializer

* Add Jest test coverage

* Fix undefined expectations

* Update snapshots

* Leverage timezone aliases

* Remove defunct TZ mapping overrides

* Add missing alias

* Refactor ReadOnlyHearingTimeWithZone's Jest test file to

utilize beginsAt values for hearing days that are formatted in the way they are in actuality within the app.

* WIP: Add service specs

* Add HearingDatetimeService tests

* Remove extra line of whitespace

* Make date consistent in tests

* Add legacy tests

* Update tz initializer spec

* Fix typo where I used 'subject' in place of 'is_expected'

* Fix use of wrong variable name

* Fix legacy hearing staging

* Add specs for HearingTimeService

* Add icol service test

* Fix hearing time service time_to_string method

* Change time expectations to meet actual behavior

* Fix mistake where I had accidentally set the expectation for the

Louisville, KY RO to be a time in the wrong timezone.

---------

Co-authored-by: Matthew Thornton <ThorntonMatthew@users.noreply.github.com>
Co-authored-by: AdamShawBAH <adam.shaw@va.gov>

* APPEALS-26734 and APPEALS-25121 HRT Phases 1 and 2 (#23258)

* APPEALS-25117: rspec fix + add docket and id as conference id

* APPEALS-25117: final service updates

* APPEALS-25117: adds webex service rspec and comments to create conference job spec, needs further review

* APPEALS-25117 spec update

* APPEALS-25117 update test

* APPEALS-25117 finish spec update

* APPEALS-25117 correct schema

* APPEALS-34501 update arguments

* APPEALS-34501 added port env var

* APPEALS-34501 updated the feature toggle

* APPEALS-34501 update spec

* Add helper methods to ExternalApi::WebexService::CreateRespons

* Add create_webex_conference

* Conference ID to string

* Set conference_id back

* Rename LinkService to PexipLinkService

* Remove conference_id setting since we dont use it

* Add env vars to controller spec

* Fix failing tests in pexip_conference_link_spec

* Remove nil check

* Fix pexip_link_service_spec failures

* Clean up test file a bit

* APPEALS-34517 render correct data guestlinks

* Fix test link

* Add fixes and fiel changes to create_conference_job_spec

* Whittle down create_conference_job

* Remove env vars that can come back out

* Add FTs to conf job

* APPEALS-34517 updated tests and guestLink DailyDocket

* Lint

* Remove unused mocks

* Fix conf link tests

* Maybe fix some tests

* Controller spec fixes

* Add fix to virtual hearing spec and update factory and model

* Remove defunct check for host link

* Update link_generation_initialized trait across app

* Resolve daily docket spec with new trait name

* Adjust StuckVirtualHearingsChecker

* Adjust daily docket

* Fix async pending tests

* APPEALS-34673: added conditional based on hearing conference provider to display links

* Add update for links

* Update to guestLink rendering

* APPEALS-34673: update snapshot tests, add hearing links to test runs

* APPEALS-34673: revert caseworkerindex snapshot and remove comment

* APPEALS-34673: update snapshot - passes locally

* APPEALS-34673: updates to snapshot

* APPEALS-34673: updates to snapshot

* APPEALS-34673: updates to snapshot

* APPEALS-34880: added nbf and exp methods to hearing day and virtual hearing

* APPEALS-34880: added nbf exp rspec to virtual hearing spec

* APPEALS-34880: added hearing day spec test for nbf and exp and removed comments

* APPEALS-34880: removed comments

* APPEALS-34880: removed comments

* APPEALS-34880: removed spacing in rspec

* APPEALS-34908: added one liners

* APPEALS-34908 update resp

* APPEALS-34908 update json parse

* APPEALS-34908 update send_webex method nil

* APPEALS-34908 update webex_conference_link to string

* APPEALS-34908 update create_response.rb sym to string

* DRY up generate_conference_information

* APPEALS-34908: service and fakes updates

* APPEALS-34908: update request body

* Change param passing

* APPEALS-34908 rspec test fix

* APPEALS-34908: updated webex service spec

* APPEALS-34908 converted hash to json in fake

* Change some names

* APPEALS-35033: change casing for Nbf Exp to nbf exp

* Correct spec file name

* Remove .gitignore diff

* Use .to_json

* APPEALS-35195: update sub to use unique hearing day id

* APPEALS-35195: update hearing day spec to have specific id for hearing day

* APPEALS-35195: change date format

* APPEALS-35728: initial updates to daily docket row

* APPEALS-35728: update logic for type vs conferenceProvider

* APPEALS-35728: updates to test, props, store, snapshot

* Test: Change hearing links label (#20082)

* Change hearing links label

* Update snapshot

* Fix tests

* More snapshots

---------

Co-authored-by: Matthew Thornton <ThorntonMatthew@users.noreply.github.com>

* Merge branch 'feature/APPEALS-26734' into feature/APPEALS-35295
<!-- Change JIRA-12345 to reflect the URL of the Jira item this PR is associated with -->
Resolves [Jira Issue Title](https://jira.devops.va.gov/browse/JIRA-12345)

# Description
Please explain the changes you made here.

## Acceptance Criteria
- [ ] Code compiles correctly

## Testing Plan
<!-- Change JIRA-12345 to reflect the URL of the location of the test plan(s) for this PR -->
1. Go to [Jira Issue/Test Plan Link](https://jira.devops.va.gov/browse/JIRA-12345) or list them below

- [ ] For feature branches merging into master: Was this deployed to UAT?

# Frontend
## User Facing Changes
 - [ ] Screenshots of UI changes added to PR & Original Issue

 BEFORE|AFTER
 ---|---

## Storybook Story
*For Frontend (Presentation) Components*
* [ ] Add a [Storybook](https://github.com/department-of-veterans-affairs/caseflow/wiki/Documenting-React-Components-with-Storybook) file alongside the component file (e.g. create `MyComponent.stories.js` alongside `MyComponent.jsx`)
* [ ] Give it a title that reflects the component's location within the overall Caseflow hierarchy
* [ ] Write a separate story (within the same file) for each discrete variation of the component

# Backend
## Database Changes
*Only for Schema Changes*

* [ ] Add typical timestamps (`created_at`, `updated_at`) for new tables
* [ ] Update column comments; include a "PII" prefix to indicate definite or potential [PII data content](https://github.com/department-of-veterans-affairs/appeals-team/blob/master/caseflow-team/0-how-we-work/pii-handbook.md#what-is-pii)
* [ ] Have your migration classes inherit from `Caseflow::Migration`, especially when adding indexes (use `add_safe_index`) (see [Writing DB migrations](https://github.com/department-of-veterans-affairs/caseflow/wiki/Writing-DB-migrations))
* [ ] Verify that `migrate:rollback` works as desired ([`change` supported functions](https://edgeguides.rubyonrails.org/active_record_migrations.html#using-the-change-method))
* [ ] Perform query profiling (eyeball Rails log, check bullet and fasterer output)
* [ ] For queries using raw sql was an explain plan run by System Team
* [ ] Add appropriate indexes (especially for foreign keys, polymorphic columns, unique constraints, and Rails scopes)
* [ ] Run `make check-fks`; add any missing foreign keys or add to `config/initializers/immigrant.rb` (see [Record associations and Foreign Keys](https://github.com/department-of-veterans-affairs/caseflow/wiki/Record-associations-and-Foreign-Keys))
* [ ] Add `belongs_to` for associations to enable the [schema diagrams](https://department-of-veterans-affairs.github.io/caseflow/task_trees/schema/schema_diagrams) to be automatically updated
* [ ] Document any non-obvious semantics or logic useful for interpreting database data at [Caseflow Data Model and Dictionary](https://github.com/department-of-veterans-affairs/caseflow/wiki/Caseflow-Data-Model-and-Dictionary)

## Integrations: Adding endpoints for external APIs
* [ ] Check that Caseflow's external API code for the endpoint matches the code in the relevant integration repo
  * [ ] Request: Service name, method name, input field names
  * [ ] Response: Check expected data structure
  * [ ] Check that calls are wrapped in MetricService record block
* [ ] Check that all configuration is coming from ENV variables
  * [ ] Listed all new ENV variables in description
  * [ ] Worked with or notified System Team that new ENV variables need to be set
* [ ] Update Fakes
* [ ] For feature branches: Was this tested in Caseflow UAT

# Best practices
## Code Documentation Updates
- [ ] Add or update code comments at the top of the class, module, and/or component.

## Tests
### Test Coverage
Did you include any test coverage for your code? Check below:
- [ ] RSpec
- [ ] Jest
- [ ] Other

### Code Climate
Your code does not add any new code climate offenses? If so why?
- [ ] No new code climate issues added

## Monitoring, Logging, Auditing, Error, and Exception Handling Checklist

### Monitoring
- [ ] Are performance metrics (e.g., response time, throughput) being tracked?
- [ ] Are key application components monitored (e.g., database, cache, queues)?
- [ ] Is there a system in place for setting up alerts based on performance thresholds?

### Logging
- [ ] Are logs being produced at appropriate log levels (debug, info, warn, error, fatal)?
- [ ] Are logs structured (e.g., using log tags) for easier querying and analysis?
- [ ] Are sensitive data (e.g., passwords, tokens) redacted or omitted from logs?
- [ ] Is log retention and rotation configured correctly?
- [ ] Are logs being forwarded to a centralized logging system if needed?

### Auditing
- [ ] Are user actions being logged for audit purposes?
- [ ] Are changes to critical data being tracked ?
- [ ] Are logs being securely stored and protected from tampering or exposing protected data?

### Error Handling
- [ ] Are errors being caught and handled gracefully?
- [ ] Are appropriate error messages being displayed to users?
- [ ] Are critical errors being reported to an error tracking system (e.g., Sentry, ELK)?
- [ ] Are unhandled exceptions being caught at the application level ?

### Exception Handling
- [ ] Are custom exceptions defined and used where appropriate?
- [ ] Is exception handling consistent throughout the codebase?
- [ ] Are exceptions logged with relevant context and stack trace information?
- [ ] Are exceptions being grouped and categorized for easier analysis and resolution?

* APPEALS-31618 add migration files

* APPEALS-31618 rmove migration

* APPEALS-31618 0fficial add co_host_hearing_link

* APPEALS-31618 Add co_host_link to conference_links

* APPEALS-31618 added code for co-host

* APPEALS-31618 remove attribute conferencelinks

* APPEALS-31618 update tests

* APPEALS-31618 update lint

* APPEALS-31618 update VirtualHearingsFields snapshot

* APPEALS-31618 update details.test.js snapshot

* APPEALS-31618 update create_conference_job_spec

* APPEALS-31618 updated Marcs sugestions rnd 1

* jefftmarks/APPEALS-31619 (#20515)

* APPEALS-31619 Created migration

* APPEALS-31619 Add xls column to migration

* APPEALS-31619 Update index name

* APPEALS-31619 Change null options on migration

* APPEALS-31619 Refactor transcription files table

* APPEALS-31619 Remove old migration

* APPEALS-31618 updated migration inheritance

* Min/APPEALS-31621 (#20523)

* APPEALS-31621 added the table

* APPEALS-31621 moved model under hearings folder

* APPEALS-31621 reverted schema back from testing table

* APPEALS-31621 added transcriptions association

* APPEALS-31621 fixed typo

* APPEALS-31621 removed migration file

* APPEALS-31621 added additional template methods in model and comments

* APPEALS-31621 fixed transcription typo

* APPEALS-31621 added additional template methods

* APPEALS-31621 changed name of model and controller

* APPEALS-31621 removed transcript association

* hotfix/APPEALS-35296-flaky-conference-job-test (#20555)

* akonhilas/APPEALS-31820 (#20510)

* APPEALS-31820: create transcription transactions serializer with outline until model complete

* APPEALS-31820: update aws link attributes

* APPEALS-31820: removed methods and has many relationship, change file name

* APPEALS-31820: updated file tree

* Revert "APPEALS-31820: updated file tree"

This reverts commit 4b58d5a93c3922582b97447e6b40c5cb1b087083.

* APPEALS-31820: updated serializer to match new db columns and updated AC

* APPEALS-35177 adjust spacing

* APPEALS-35177 fix lint

* APPEALS-35177 made final positioning adjustments

* APPEALS-35176 - Pull radio buttons closer and tidy up the CSS

* jefftmarks/APPEALS-31619 Remove unique contraints on indexes (#20620)

* APPEALS-31619 Created migration

* APPEALS-31619 Add xls column to migration

* APPEALS-31619 Update index name

* APPEALS-31619 Change null options on migration

* APPEALS-31619 Refactor transcription files table

* APPEALS-31619 Remove old migration

* APPEALS-31619 Remove unique contraints on indexes

* APPEALS-31619 Change index order

* APPEALS-31619 Move docket number in index

* Allow NonVirtual Webex hearings to display the HC link on the Hearing Details page

* APPEALS-36652 Backend changes

* Display only Virtual Hearing Links for virtual hearings and only Hearing Links for nonvirtual hearings

* APPEALS-36652

* APPEALS-35176 - Update html and css to better match the figma design

* Refine conference provider search so that correct links show up for pexip conferences

* APPEALS-35176 - Update radio button to align better with label

* Add daily docket conference links to legacy appeals

* Add daily docket conference link to the nonvirtual webex hearing links

* Show non virtual webex HC link

* APPEALS-35176 - Make margins more consistent across browsers

* Update feature tests to remove old conditions

* APPEALS-36652 heearing_spec update

* Updated jest testing in progress

* Add nonvirtual webex test - in Progress

* Add test with default props back into test file

* Remove unnecessary test and resolve testing errors with webex hearinglinks tests

* Show hearing links titles and clickable link

* Update jest snapshots

* Capitalize webex hearing styling

* akonhilas/APPEALS-38906 (#20664)

* APPEALS-38906: updates to service, created new file for job

* APPEALS-38906: response, updates to query, finalizing job, fakes

* APPEALS-38906: add query to call

* APPEALS-38906: add scheduled jobs, cgi formatting, exponential backoff, add get post to service, service spec updates

* APPEALS-38906: added get webex recording job spec, changed timing for to and from params in job

* APPEALS-38906: pushing failing tests for visibility

* APPEALS-38906: pushing tests for visibility

* APPEALS-38906: final test updates

* APPEALS-38906: remove comments, time updates, va ops email comment

* APPEALS-38906: fixed rspec and removed unnecessary error raise from job

* jefftmarks/APPEALS-38907 (#20659)

* APPEALS-31821 created job file and template

* APPEALS-38907 Create download transcription file job

* min/APPEALS-31821 made new helper method templates for use on perform

* APPEALS-38907 Continue prototype

* APPEALS-31821 basic webvtt to rtf conversion and tmp folder initializers

* APPEALS-38907 Complete basic structure for job

* APPEALS-38907 Update error handling

* APPEALS-31821 gathering info for the front page

* APPEALS-38907 Add error handling for invalid file name

* APPEALS-38907 Add error handling for invalid file type

* APPEALS-38907 Fix linting

* APPEALS-38907 Open URI CodeQL fix

* APPEALS-31821 generating a table for the front page info

* APPEALS-31821 generating header info for first page cell

* APPEALS-38907 Update initializer to create subdirectory for each file type

* APPEALS-38907 Update code comments

* APPEALS-31821 most info appearing on first page now

* APPEALS-31821 stashing regexes for future use

* APPEALS-31821 vtt fully converted to rtf

* APPEALS-38907 Implement S3 upload

* APPEALS-38907 Update comments

* APPEALS-31821 page numbers and footers now displaying

* APPEALS-31821 texts from the same speaker is now consolidated

* APPEALS-31821 refactored footer creation on document

* APPEALS-38907 Complete implementation of job minus va ops email

* APPEALS-38907 Update S3 bucket and folder names

* APPEALS-31821 S3 download and upload implemented and tmp file clean up

* APPEALS-31821 S3 download and upload implemented and tmp file clean up

* APPEALS-38907 Polish error handling before moving on to tests

* APPEALS-31821 added error handling and logging

* APPEALS-31821 repurposed class into a workflow

* APPEALS-31821 removed mailer

* APPEALS-38907 Connect job with TranscriptionTransformer workflow

* APPEALS-38907 Small fixes after writing xray tests

* APPEALS-31821 added rspec tests and refactored workflow

* APPEALS-38907 Finish spec files

* APPEALS-31821 removed the new datadog metrics that was made

* APPEALS-31821 removed the new datadog metrics that was made

* APPEALS-31821 added back old datadog metrics

* APPEALS-31821 removed ext_claim schema

* APPEALS-31821 moved transcription_transformer to workflow folder

* APPEALS-38907 Complete spec

* APPEALS-31821 adjusted rspec tests and fixed minor edgecase for empty string identifiers

* APPEALS-31821 fixed minor formatting issues

* APPEALS-31821 edited spacing

* APPEALS-31821 added error class back

* APPEALS-38907 Fix argument being passed to TranscriptionTransformer

* APPEALS-38907 Fix footer on rtf layout

* APPEALS-38907 Fix spec to mock TranscriptionTransformer correctly

* APPEALS-38907 Change URI.open call to be more safe

---------

Co-authored-by: Minhazur Rahaman <minhazur9@gmail.com>
Co-authored-by: msteele <Marc.Steele@va.gov>
Co-authored-by: Marc Steele <71673522+msteele96@users.noreply.github.com>

* Refactor double returns to a single return

* Update snapshots

* Remove unnecessary commented out code

* Update linting issues

* Fix linting error

* Update snapshots for jest testing

* jefftmarks/APPEALS-40657 (#20851)

* APPEALS-40657 Refactor DownloadTranscriptionFileJob

* APPEALS-40657 Refactor TranscriptionFile

* APPEALS-40657 Refactor UploadTranscriptionFileToS3 workflow

* APPEALS-40657 Refactor DownloadTranscriptionFileJob spec

* APPEALS-40657 Update migration and model for TranscriptionFile to associate with hearing instead of appeal

* APPEALS-40657 Update DownloadTranscription job to save records with hearing instead of appeal attributes

* APPEALS-40657 Update subject for conference to include hearing attributes instead of appeal

* APPEALS-40657 Schema

* APPEALS-40657 Fix failing spec in virtual hearing spec

* APPEALS-40657 Update comment in migration

* APPEALS-40657 Update schema

* Min/APPEALS-39905 (#20853)

* APPEALS-39905 audible text will now be displayed as [INAUDIBLE]

* APPEALS-39905 csv getting made and uploaded when inaudibles are found

* APPEALS-39905 turned tmp clean up back on

* APPEALS-39905 adjusted rspec tests

* APPEALS-39905 adjusted transformer rspec tests

* APPEALS-39905 added more rspec tests to transformer workflow

* APPEALS-39905 added guards for nil values in hearing info

* added byebug

* removed byebug

* APPEALS-39905 Resolve merge conflicts in download transcription job spec

* APPEALS-39905 changed inaudible display

* APPEALS-39905 changed test url back

* APPEALS-39905 converts input vtt to readable format if invalud utf is found

* APPEALS-39905 adjusted rspec tests

---------

Co-authored-by: Jeff Marks <jeff.t.marks@gmail.com>

* akonhilas/APPEALS-31620 (#20788)

* APPEALS-31620: initial commit

* APPEALS-31620: finished all webex service/response/fakes/spec updates

* APPEALS-31620: adding recording details job

* APPEALS-31620: cannot get past rspecs here

* APPEALS-31620: update rspecs

* APPEALS-31620: add file

* APPEALS-31620: finalized rspecs, removed Hearings prepend - unnecessary after rebuild

* APPEALS-31620: resolve webex service rspec

* APPEALS-31630: code cleanup

* APPEALS-31620: remove hearings prepend, perform_later, scheduled_for, regex

* APPEALS-31620: rspec

* jefftmarks/APPEALS-40909 (#20951)

* APPEALS-40909 Create migration and write spec tests

* APPEALS-40909 Update conference_link model to associate with polymorphic hearing

* APPEALS-40909 Write spec for add index to conference links

* APPEALS-40909 Add spec to test conference link factory after null constraint removed

* APPEALS-40909 Uncomment out code in migration to see if tests pass on GHA

* APPEALS-40909 Implement database cleaner fix and write down test for index migration

* APPEALS-40909 Test conference links can belong to hearings and hearing days

* APPEALS-40909 Remove migration tests

* APPEALS-40909 Refactor delete conference link job spec to avoid static record count

* APPEALS-40909 Fix duplicate examples in download transcription file spec

---------

Co-authored-by: Adam Ducker <adam.ducker@va.gov>

* APPEALS-39907  (#20952)

* APPEALS-39907 Initial commit

* APPEALS-39907 update convention

* APPEALS-39907 update render call

* APPEALS-39907 update to/from within .erb

* APPEALS-39907 added to and from attributes

* APPEALS-39907 to/from update

* APPEALS-39907 direction update

* APPEALS-39907 conditional added

* APPEALS-39907 update conditional

* b_reed/APPEALS-39907 added mailing in error handling for DownloadTranscriptionFileJob and GetWebexRecordingDetailsJob

* APPEALS-39907 added more mailing code for error handling

* APPEALS-39907 adjusted rspec tests

* APPEALS-39907 Unit tests complete

* APPEALS-39907 adjusted lint

* APPEALS-39907 update class ActionMailer

* APPEALS-39907 added comments

* APPEALS-39907 removed redundant unit test

* APPEALS-39907 update demo url

* APPEALS-39907 seperated env instances

* APPEALS-39907 update id fetch method ln: 209

* APPEALS-39907 remove filename parameter ln: 32

* APPEALS-39907 added filename argument back

* APPEALS-39907 added the lint disabler back

* APPEALS-39907 updated demo env test

* b_reed/APPEALS-39907 fixed minor issue with argument names

* APPEALS-39907 updated how appeal ids are found

* APPEALS-39907 more minor fixes

* APPEALS-39907

* APPEALS-39907 email address to send mail and cc now changes depending on rails env

* APPEALS-39907 fixed rspec tests

* APPEALS-39907 Update html doc layout

* APPEALS-39907 adjusted email addresses and some refactors

* APPEALS-39907 adjusted rspec tests

* APPEALS-39907 update case statements

* APPEALS-39907 email preview template

* APPEALS-39907 update values

* APPEALS-39907 added appeal id

* APPEALS-39907 previewer lint

* APPEALS-39907 remove blank space

* APEALS-39907 disable actionMailer lint

* APPEALS-39907 fixed rspecs

* APPEALS-39907 config file update

---------

Co-authored-by: Minhazur Rahaman <minhazur9@gmail.com>

* akonhilas/APPEALS-40915 (#20948)

* APPEALS-40915: ini…
hawkespoulterva pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
hawkespoulterva pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>

* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------

Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* added bgs_source to parser, controller and serializer along with specs (#21621)

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>

* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------

Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>

* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------

Co-authored-by: nader k <nader@nkconsulting.net>

* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* renamed epe to singular method call (#22914)

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------

Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>

* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------

Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------

Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>

* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* added bgs_source to parser, controller and serializer along with specs (#21621)

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>

* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------

Co-authored-by: Chris-Martine <christopher.martine@va.gov>

* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------

Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>

* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------

Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>

* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------

Co-authored-by: nader k <nader@nkconsulting.net>

* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------

Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>

* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>

* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------

Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>

* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>
Co-authored-by: Nader Kutub <nader.kutub@va.gov>

* renamed epe to singular method call (#22914)

Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MBP.lan>

* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------

Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------

Co-authored-by: Nader Kutub <nader.kutub@va.gov>
Co-authored-by: Nader Kutub <nader@nkconsulting.net>

* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------

Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>

* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------

Co-authored-by: kshiflett88 <kodishiflett@gmail.com>

* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
sbashamoni pushed a commit that referenced this pull request Oct 21, 2024
…#23281)

* APPEALS-36688- Build out Decision Review Created API route & Controller (#20569)

* added skeleton for api route

* removed duplicate code

* removed development envs for api and moved to creating an ApiKey

* removing any changes to development.rb

* removed extra auth code

* removed before action

---------



* APPEALS-38232 -Build out Decision Review Created Event Failure API route & Controller (#20601)

* APPEALS-38232 - renamed controller to AC req, added decision_review_created_error endpoint, added decision_review_created_error method, and added RSpec for new method

* APPEALS-38232 - add comments to RSpec

* Jonathan/appeals 36684 (#20516)

* initial Events migration and model creation

* created model for DecisionReviewCreatedEvent

* updated comment with example

* added spec for DRCE model

* APPEALS-36684 created event_records migration and added polymorphic associations to specific models, and added rspec for the event_record model

* APPEALS-36684 - Updated RSpec tests and updated variables and got unhappy path to pass

* cleaned lint

* saving DRCE spec changes

* fixed spec test

* changed has_many to has_one

* updated event model spec

* added validation for ER poly associations

* changed association to has_one

* added new method and updated tests

* added foreign key after running checks

* some PR comment changes

* refactored methods in EventConcern

---------




* added migration, scopes and specs for events (#20707)

* fixed migration to update existing events table

* rollbacked to fix schema

* schema fixes

---------



* Jr/APPEALS-38926  (#20714)

* APPEALS-38926 - Created DecisionReviewCreatedError Service Class, added logic for handling service error, updated DecisonReviewCreatedController, and DecisionReviewCreatedController spec, with the updated service logic

* APPEALS-38926- created RSpec Test for DecisionReviewCreatedError Service Class and edited the Rails.logger for the service class

* APPEALS-38926 Added new info column to update transaction and added it to the RSpec test

* APPEALS-38926 - added comments to the Service Class

* APPEALS-38926 - Code Changes from TL Code Review, added rescues and fails

* APPEALS-38926 - fixed lint

* Jonathan/appeals 36689 (#20671)

* created new service class

* add rspec test cases

* service class methods

* controller action and spec

* controller update

* CC fixes

* removed accidental line

* changed to find_or_create_by

* reworked error for redis lock

* additional rspec for controller

* fixed test

* rspec fix

* delete lock key afterwards

* moved Event creation back into lock block

---------



* APPEALS-39663 Create CreateUserOnEvent service class and add logic to create user if needed (#20838)

* added user creation class & test

* removed extra lines

* add comment to class

* added context for args from avro

---------



* Jr/APPEALS-39664 (#20898)

* APPEALS-39664 - Created updated_vacols_on_optin module class, and removed  extra private

* APPEALS-39664 - created UpdatedVacolsOnOptin module, RSpec file, as well as sudo code for SOC and SSOC optin check in main service class DecisionReviewCreated

* APPEALS-39664 - Created RSpec Test - PASS,  Updated method name.

* APPEALS-39664 - Added Error Handling to Sub Service Class

* APPEALS-39664 - Removed un-needed comments

* APPEALS-39664 - added include for the module UpdateVacolsOnOptin inside decision_review_created service

* APPEALS-39664 - Added Custom Error , and updated all .perform! to .process!

* APPEALS-39664 - Updated RSpec Test to reflect changes - all pass

* Updated comment for decision_review_created Service Class

* Will/appeals 36691 (#20909)

* Created attribute for failed claims on event and displaying failed claim

* passing all failed events back to serializer

* added controller tests for failed_claims and added class method for finding claims on events

* renamed failed_claims to claim_errors

---------



* JR/APPEALS-40954 Create CreateIntake service class and add logic to create Intake (#20967)

* APPEALS-40954 - Added Sudo Code for CreateIntake Logic

* APPEALS-40954 - added logic to CreateIntake module

* APPEALS-40954 - added Create Intake spec  with error handling - All pass

* APPEALS-40954 - Added CreateIntake Module to DecisionReviewCreated Main Service

* APPEALS-40954 - updated folder name and namespace

* APPEALS-40954 - Updated RSpec to match folder

* APPEALS-40954- Upated decision review created servie include to match folder

* Fixed failing test due to folder structure change

* Jonathan/appeals 40950 (#20965)

* Added new veteran creation module

* saving test changes

* rspec

* fixed datetime assign

* renamed var

---------



* APPEALS-40950 - update var veteran to vbms_veteran (#21050)

* APPEALS-40950 - update var veteran to vbms_veteran

* updated private method in controller to match happy path params dcr to drc

* Create CreateClaimantOnEvent service class and add logic to create claimant if needed (#21044)

* created service class and basic unit tests

* added conditionals for veteran claimants and will create veteran claimant now

* modified create claimant to use eventing data

* change to a class

* creating claimant correctly

* test fixes

* removed old comments

* fixed type for veteran_is_not_claimant

* changed specs to match pulling out hash params and removed event.reference id

* moved back to dot notation

* updated comments

* fixed create claimant issue

* updated process to use bang method and returning claimant

---------



* APPEALS-41968 Modify Issues Endpoints & Update Metric Service Logic (#21108)

* moved metricsService call to top of method

* modified rspec case

* moved metric logging spec case higher up

---------



* Resolved merge conflicts while merging master into feature/APPEALS-28… (#21167)

* Jonathan/APPEALS-41957 (#21171)

* added interface + parser class

* edited veteran parse methods

* renamed var to "payload"

* started refactor

* more refactor + rspec

* added EPE attr

* dateTime conversions

* added class comments

* rubocop lint changes

* fixed test case

---------



* Jr/appeals 41931 (#21192)

* APPEALS-41931 - Created create_ep_establishment file and class

* APPEALS-41931 - added process! method that creates epe from payload

* APPEALS-41931 - added logic for EventRecord being created and error handling

* APPEALS-41931 - added comments to process method

* APPEALS-41931 - set up rspec test

* APPEALS-41931 - removed lint

* APPEALS-41931-created Rspec and Test Pass

* APPEALS-41931 - cleaned lint and added error test 100% code coverage

* APPEALS-41931- fixed lint

* APPEALS-41931- fixed lint and fixed %100 code cov

* APPEALS-41931 - cleaned up lint and warn for Service Class

* APPEALS-41931 - Added CreateEpEstablishment.process! to the decision_review_created Parent Service Class

* APPEALS-41931 - refactor code to implement new parser

* fixed linting issues

* APPEALS-41931 - Updated Comments for CreateEpEstablishment

* APPEALS-41931 - moved logical date int to parser and refactored code in Class and RSepc

* edits

* Will/appeals 41929 (#21205)

* added an error and commented out call for createclaim

* added new parser logic

* merge request changes

* fixed rubocop issues and added checks for claim review attributes

---------



* APPEALS-42631- Create Rspec for Parser with sample payload method, and add additional parser methods  (#21294)

* APPEALS-42631 - create example.json

* APPEALS-42631 - implemented example_response and load_example method and works as expected

* APPEALS-42631 - created RSpec for DecisionReviewCreatedParser

* APPEALS-42631 - Refactored parser and Added RSpec for current praser

* APPEALS-42631 - added methods to parser for intake, claimant, and claim_review and added matching rspec for new methods

* APPEALS-42631 - updated code per TL Comments

* APPEALS-421631- added additional comments and fixing lint

* APPEALS-41934 (#21251)

* initial commit

* implementation & error

* renamed method

* rspec

* saving refactor progress

* finished refactoring class

* added comment

* minor parser/rspec updates

---------



* added RI parser methods to rspec (#21322)

* added RI parser methods to rspec

* updated config for Consumer

---------



* Update DecisionReviewCreated to make all calls and link all intake records (#21334)

* updated decision review created to uncomment actions and updated specs

* remove binding.pry

* removed comments

* fixed a bunch of broken tests

* fixed last broken tests

* fixed params for methods and specs

---------



* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* Jr/ama controller refactor (#21365)

* fixed test and refactored controller

* saving changes

* init commit passing all the way to request_issues

* all pass and functions as expected

* lint

* lint

* updated initializer to use deep_symbolize_keys

* updated headers to be more dry

* added missing Intake attributes

* fixed failing tests

* updated createIntake test

* fixed veteran rspec

* fixed RI test

* APPEALS-43446- Change name of BackfillRecord polymorphic model to EventedRecord (#21382)

* APPEALS-43446 - renamed columns for backfill record to evented record migrate and rollback work as intended

* APPEALS-43446 replaced all backfill_record with evented_record within the models associations and updated Rspec tests

* APPEALS-43446 fixed error message

* updated intake

* modified intake

---------



* redo init commit

* updated imp. logic

* attorney widget fix

* Create end to end , happy path rspec's for Decision Created event Feature (#21395)

* updated more tests and fixed user creation

* added in person creation

* corrected headers and fixed broken tests

* added type

* fixed failing spec

* creating event when person is created

* updated spec to account for both events being created

* ignored long lines for spec file

* linting fixes

* fixed more linting errors/ ignored long lines

---------



* Jonathan/appeals 43589 (#21397)

* saving

* saving user class error progress

* error handling for user creation

* updated error handling/raises

* validator methods

* validations

* update logical date converter

* changed veteran service class to use file_number

* added fields to hlr

* updated epe data

* removed byebug

* fixed typos

* Edit 5: adding detail_id to Intake

* EDIT 6: add claimant_participant_id to epe

* Edit 8: Intake is correctly linked to veteran

* Edit 7: RI additions

* fixed spacing

* fixed typo

* saving rspec changes

* rspec updates

* added datetime conversion for person dob

* fixed rspec

* remove unused methods

---------



* feature/APPEALS-35707-29633-29632 (uat) (#21435)

* 🔀 Squash merge AlecK/APPEALS-35707 - Replace `database_cleaner` with `database_cleaner-active_record`

* 🔀 Squash merge jcroteau/APPEALS-29632-fix-deprecation-action-view-base-instances

* 🔀 Squash merge jcroteau/APPEALS-29633-fix-deprecation-warning-active_record-result-to_hash

* awillis/APPEALS-45152 (#21506)

* APPEALS-45152 Updated the logic in create_claimant_on_event.rb to always generate a claimant record.  Updated RSPEC.

* APPEALS-45152 Cleaned up RSPEC.

* APPEALS-45152 Fixed Failing RSPEC within decision_review_created_spec.rb

* APPEALS-45152 Updated RSPEC within decision_review_created_spec.rb with addtional checks.

* APPEALS-44319 (#21449) (#21541)

* added logic for legacy issues in DRC

* more legacy logic

* updated rspec context lang

* error cov

---------




* Konstantin/APPEALS-45175 (#21517)

* logical_date_converter re-written to work with yyyymmdd numbers from json payload

* comments removed

* comments removed2

* method rewitten

* json example fixed

* date in scenario_b_spec.rb replaced by valid ones, additional check for empty string parameter added to the logical_date_converter

* removed filter for non rating request issue dropdown (#21480)

* removed filter for non rating request issue dropdown

* removed excluded types as we don't need to check this anymore

* fixed broken test

* added category back

* no longer need test to check for missing categories since we're returning them all.

---------



* Column added to RequestIssues table (#21578)

* added migration and simple spec to test

* fixed schema deleted issues

* updated spec to verify data being set

* error was no longer trigger from update. removed check and passed in correct variable

---------




* added bgs_source to parser, controller and serializer along with specs (#21621)



* Konstantin/appeals 45180 (#21591)

* bug is fixed, condition added to DecisionReviewCreatedController

* rspec test added

* json message updated

* comment added

* Update decision_review_created_controller.rb

comment updated

---------



* cmartine/APPEALS-42621 (#21599)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Fix linter errors

---------




* nrithner/APPEALS-45263 (#21617)

* Add remove_comp_and_pen_intake feature toggle to intakes controller

* Add new compensation and pension removal message to COPY.json

* Disable comp and pen radio buttons if remove_comp_and_pen_intake toggle is on

* Frontend test updates

* Add tooltip checks for review page integration tests

* fix frontend test lint errors

* frontend tests changes

* Add banner for non-vha

* Add banner for VHA employee

* Refactor conditionals

* Refactor logic for banners to display

* Add dangerouslySetHtml to banner

* Add test for no VHA employee

with vha_claim_review_establishment disabled.

* Add VHA employee scenario to display REMOVE_INTAKE_COMP_AND_PEN

* Complete non vha user scenarios

* Complete VHA employee scenarios

* Remove comments

* Fix linter errors

* Remove spaces preceding question marks

* Correct linting errors

---------





* Konstantin/appeals 45149 (#21644)

* RequestIssueSerializer attributes added

* development_item_reference_id, same_office, legacy_opt_in_approved attributes were added

* merge conflicts resolved

* merge conflict resolved

* fixed

* all datapoints were added

* empty line removed

* comment removed

* refactored

* app/controllers/api/docs/v3/ama_issues.yaml updated with new attributes

* example of request issue updated app/controllers/api/docs/v3/ama_issues.yaml

* null to nil edited in example ama_issues.yaml

* example ama_issues.yaml updated

* example ama_issues.yaml updated2

* linters fixed

* linters fixed2

* linters are fixed

* APPEALS-45883 - Remove End Product Establishment records within the Event Records table in Caseflow (#21745)

* APPEALS-45883 - changes to remove the creating of Event Records for epe

* APPEALS-45883 - remove removed event params from method calls

* APPEALS-45883 removed Event Double

* APPEALS-48553 updated event_record spec

* removed eventing from create claim review (#21718)

* removed eventing from create claim review

* checking why file is not being found for event_record

* removed event var and require dependency

* spec fixes

* updated specs

* fixed revert

---------




* Nrithner/appeals 45913 (#21716)

* Convert from milliseconds to datetime

* Add expection to have datetime after parsing

* Fix linting issues

* APPEALS - 45914 & 45915  (#21744)

* Decision review parser and spec changes

* remove byebug

* Added db seed and testing (#21284)

* Added db seed and testing

* Change ApiKey seed name to ConsumerApiKey, and associated changes

---------





* re-merge Cmartine/appeals 46861 (#21855)

* Edit DecisionReviewCreatedController to respond with ok status if event exists and is completed, edit test

* Move checking if event exists and is completed into event model, edit tests

* Fix linter errors

---------



* Nrithner/appeals 46860 (#21856)

* Set event info back to default

default state for info is an empty
json object

* Correct linting errors

* Test happy path with rspec

* Refactor rspec example

* Converte module to class

* Remove module import

---------



* Jonathan/appeals 45899/45878 (#21714)

* add "from event" value to Store

* updated setup guide for M3

* added new badges

* added jest

* storybook file

* additional story

* bugfix

* snap update

* Konstantin/appeals 46175 (#21768)

* draft processor method done

* process_nonrating method moved to DecisionReviewCreated service

* json example added, process_nonrating method updated

* 4 rspec test added

* useless json example removed

* commented lines removed

* condition added

* condition added.

* test updated

* first condition moved out of the method

* process_nonrating method call moved down

* 1 comment removed, 1 added

* process nonrating method rafactored, logic transferred into the parser

* method refactored, rspec tests updated

* rspec test slightly refactored

---------



* Edit Issues screen update (#21907)

* Edit Issues screen update

* relocated row

* updated capybara test

* updated capybara to check for new added text

* cmartine/APPEALS-46905 (#21884)

* Remove cache updating call for veteran when veteran is being created for an event

* Change seeds api_key.rb to consumer_api_key.rb

---------



* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

* Change edited_by_css_id to return users css_id

* Konstantin/appeals 48306 (#21998)

* ama_eventing_enabled feature check added

* toggle renamed

* rspec tests added

* 2 comments added

* toggle renamed, logic trasferred into controller, tests updated

* empty line removed

---------



* 930 code updates

* remove byebug

* Change edited_by_css_id to return users css_id (#22062)



* Nrithner/appeals 49245 (#22107)

* Update process_nonrating to process_nonrationg_issue_category

Remove extra logic

* Update rspec. Remove unused example

---------



* fix extra commas from merge

* APPEALS-51223: Disable ClaimantValidator for DecisionReviewCreatedEvents (#22132)

* APPEALS-51223 refactored the claimant_validator class method claimant_details_required? to consider the conditional statement

* APPEALS-51223 updated Rspec to confirm claimant address_line_1 is nil and error is empty

* APPEALS-51223 made changes to to claimant_validator to have all Unit test passing

* APPEALS-51223 added suggested changes

* Revert "fix merge conflict with AMA"

This reverts commit 6775316, reversing
changes made to 66cf311.

* added comments

* Delete docker-bin/build.sh, I didnt make these changes

* Revert "Delete docker-bin/build.sh, I didnt make these changes"

This reverts commit 03a3830.

---------



* Jonathan/appeals 51926 (#22215)

* Hide UI changes behind featureFlag

* fixed lint spacing warnings

* code climate spec fix (#22211)

* code climate spec fix

* up argument count

* created a parser helper for reusable methods

* reset codeclimate back to original and added issue parser

* modified methods to take in a hash instead of multiple params

* reduced create params down to 3 params

* added space inside

* swapped to safe navigator for intake check

* fixed spec

* fixed linting issue

* fixed failing spec

* fixed merge conflicts with code changes for helper

---------





* Konstantin/appeals 52321 (#22363)

* utc conversion method added in app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date method updated in RequestIssue model, updated contested_rating_issue_profile_date in  DecisionIssue model

* decision issue updated, tests added

* tests added, converters improve app/models/decision_issue.rb app/serializers/api/v3/issues/ama/request_issue_serializer.rb

* set_contested_rating_issue_profile_date restored in request issue model

* uneccessary logic removed

* 3 more tests added

* test added, error handling aaded in format_rating_profile_date method

* Update decision_issue.rb

* Update request_issue.rb

* Appeals 52317 (#22321)

* wip

* added the parser to skeleton

* removed commented code

* added in parser logic

* added dru_error route, error handling and params

* added rspecs and fixed routing for update error to be a post

* added empty spec

* updated dru params to match intake json

* rubocop fixes

* more rubocop fixes

* fixed routing to post now and updated specs

---------



* fixed logic for AMA issues API serializer attributes (#22358)

* fixed logic for added_by fields

* methods for fetching removed_by user

* withdrawn_by methods

* methods for edited_by & instance vars

* more logic for added_by methods

* fixed failing tests

* rspec updates

* rspec for RIU addition

* small changes

* fix test failure

* Initial commit (#22494)

* Konstantin/appeals 52318 (#22528)

* very loose prototype of class created

* hopeless variant removed

* updated parser per new design and updated specs

* request_issues_updated_event updated

* some improvments added

* unused methods removed, some methods updated

* after issues added

* tests added

* edited issues method returned, invalid tests removed

* tests updated

* 9 working tests added, RequestIssuesUpdateEvent variable instanciated

* tests improved, attribute writers added

* more test cases added, error handling in process! method added

* added new version of parser and tests to it from Will's PR

* uneccesary overrided classes removed

* process_job call removed

* process_job! restored, 3 more tests added

* validate before perfom removed

* linter issues addressed

* linter issues addressed2

---------



* Bug Fix for APPEALS-44115 (#22538)

* running ci

* testing category

* ci with conditional

* set back to false

* reverted to original spec

* running ci

* updated intake helpers to account for using none of these match option

* ignored metrics abc size

* removed from helper

* removed comments

* updated spec to check on each category

* removed single quotes

* fixed a flakey test that was failing on a duplicate key

* linting fix

* pushed up feature flag

* lint clean up

* swapped to different featureflag

* fixing spec feature toggle param

* added feature flags back

* checking if label is there

* flipped feature test to correct order

---------



* cmartine/APPEALS-50366 (#22618)

* Create EditDisabledBanner

* Add banner displaying logic and pageroute to IntakeEditFrame

* Add IntakeEditFrame jest tests for removeCompAndPenIntake feature toggle

* Edit displayEditDisabledBanner to use the disableEditingForCompensationAndPension method

* Re-add intakeEditFrame jest tests, re-add and move testProps

* Refactor intakeEditFrame jest tests

* Edit change testProps into static variable

* Add another test for intakeEditFrame

* Change testProps back into function return

* Change comp and pen removal text

* Change Intake Remove string back, add Intake Edit Disabled string, changed banner and tests to use this

* Ksarlett/appeals 50368 - Disable the remove issue, withdraw issue & edit issue options from drop down (#22637)

* ksarlett/APPEALS-50368 - Disable dropdown

* rermove console.log

* spec refactor

* spec fix

* spec refactor

* change test name

---------



* nrithner/APPEALS 50367 (#22640)

* Add disabled logic to add issue and edit claim

label buttons

* Add test buttons are disabled

When benefit is compensation

* Test buttons are disabled in supplemental_claim

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Test buttons are disabled in HLR

Add issue and Edit claim label
are disabled when benefits
pension or compensation are present

* Refactor to remove redundancy

* Test refactoring

---------




* APPEALS-53923 (#22727)

* new service class & error message

* rspec

* Update update_informal_conference_spec.rb

* Konstantin/appeals 52982 (#22715)

* eligibility-related methods added

* methods fixed, date conversion for closed_at added

* decision_review_updated_issue_parser created, json example updated, request_issues_update_event updated

* tests for parser fixed after json example update

* new attribute vbms_id added to request_issues table, decision_review_updated_issue_parser update respectively

* request_issues_update_event attr_writers added, decision_review_created_issue_parser class name update and call of that parser updated

* veteran removed from DecisionReviewUpdatedParser initilizer, methods marked for potential deletion

* decision_review_updated_issue_parser updated and test added for it, comments added to request_issues_update_event

* not necessary methods removed from parser, tests for them commented out for now

* attributes_from_intake_data method overrided

* :id replced by vbms_id, json example, parsers and test for it  updated

* parsers added, test updated

* css_id, station and detail_type commented from the parser

* parser cleaned, test for parser fixed, request_issues_update_event cleaned

* process_issues! overriden in app/models/request_issues_update_event.rb, linter offenses fixed, testtypo fixed

* vbms_id renamed to reference_id

* comment typo fixed

* Create Audit Tables for SC, HLR, Request Issues Appeals 55403 (#22689)

* migration added

* schema updated correctly

* added audit service and call to update evenr records

* logic for update type

* fixed typo in audit file and added spec

* added insert

* moved Insert DRUA to create request issues for created ones

* updated event record to take in update type

* passing in correct info attribute now

* disabled unused params, can enable once we use them

* remove <<<head

* updated migration and added request_issue to info json

* fixed spec where created at and updated timestamps format was different

---------




* fix merge conflic in seeds.rb

* remove cusoner seed files

* Konstantin/appeals 57291 (#22853)

* decision_review_created/decision_review_created_parser.rb updated

* rspec tests for decision_review_created parser added

* issue parser updated, tests added

* decision review updated parsers updated, tests added

* linter issue addressed

* Konstantin/appeals 57283 (#22851)

* reference_id added to parser, json example and create_request_issues.rb

* rspec tests for decision_review_created_issue_parser created

* reference_id null error handling added, tests for create_request_issues.rb added

* linter offenses fixed

* new param permitted added in app/controllers/api/events/v1/decision_review_created_controller.rb

* feature tests fixed

* APPEALS-55402 (#22768)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Konstantin/appeals 57279 (#22859)

* DecisionReviewUpdateMissingIssueError handling is created

* initializer added, typos fixed in request_issues_update_event.rb,more error handlings added,  tests updated and added

* little optimizationd added to app/models/request_issues_update_event.rb

* attributes_from_intake_data fixed

* commented code removed

* review defined in decision_review_updated.rb

* formatted a bit

* useless comments removed

* linter offenses cleaned, useless comments removed

* Update request_issues_update_event.rb

Result of auto conflict resolution fixed

* useless comment removed

* Update decision_review_updated.rb

Lines 21,22 uncommented.

* rubocop disable/enable added

* additional positive tests added, RequestIssuesUpdateEvent updated

* 2 tests added

* linter issue fixed

* Jonathan/appeals 58619 (#22875)

* service class and error

* adding to DRU class method

* linter line too long fix

* small fix to riue

* added rspec

* fixed typo

* Added new service class + fixed typo

* typos

* more typo fixes

* additional fields to epe.update

* updated sample payload

* unit test + time conversion

---------



* Process newly added fields passed for DecissionReviewUpdated (#22876)

* added parser changes

* removed empty line

* updated json to match updated design and removed unused methods

* remove ep code category

* removed unused methods

* fixing specs and linting

* linting fix

* updated json example to match

* added edited_description to spec

* added new json payload changes that required spec updates

* removed binding.pry

---------



* Refactor Created Events Logic to Handle Contested Issues (#22852)

* wip

* added check for contested with specs

* removed newline

* fixed contested setting to if not eligible and fixed specs

* removed setter for contested

---------



* issue parser applied (#22904)

* issue parser applied

* refactor request_issues_update_event

* refactor request_issues_update_event- remove temp files

* fix lint issues

* fix linting issues

* fix eligibility fields

* add gaurd for missing participant in request issues serializer

* add description fields to eligibility updates

* bug fixes with controller

---------




* renamed epe to singular method call (#22914)



* Edit DecisionReviewUpdatedController dru_params (#22939)

* API fix + epe feature test (#22956)

* API fix + epe feature test

* add specs

---------



* Feature/appeals 59173 (#22995)

* fix bug reatletd to new issues

* fix DRU bugs

* fix linting issue

* fix event records bug

* fix event records spec

* bug fixes for error logs, audits, claim id (#23015)

* bug fixes for error logs, audits, claim id

* fix redi lock on created event

* add reference id to AMA API (#23022)

* add reference id to AMA API

* add withdrawn audit

* audit spec fix

* Konstantin/appeals 58609 (#22970)

* draft test

* typo fixed, byebug inside find_or_build_request_issue_from_intake_data

* typo fixed, edited_description added to attributes in app/controllers/api/events/v1/decision_review_updated_controller.rb

* test file renamed

* commented lines removed

* Update spec_helper.rb

* Update scenario_edited_issues_spec.rb

typo

* success message updated, any updates check added, edited_description before check added

* audit find_by fix and add create scenario

---------




* Konstantin/withdrawn issues feature test (#23028)

* withdrawn feature test added

* more checks added to test

* temp change

* request_issue.reload removed

* fix ama api and closed rspec

* remove byebug and fix closed statu rspec

* Jonathan/appeals 59166 (#22972)

* feature test, update hlr/sc optin value

* featuretoggle change

* featuretoggle

* fix linting issues

* fix DRU removed and DRUs for eventing feature, added feature tests an… (#23055)

* fix DRU removed and DRUs for eventing feature, added feature tests and RIUs checks

* fix linting errors

* fix mutex error spec

* lint fixes

* disable DRU audit (#23064)

* Nader/audit sync fix (#23079)

* remove sync attemps on RequestIssuesUpdateEvent and add auditing, fix nil discription

* add audit record check on add issue scenario spec

* fix changes? call

* ermove audit mock

* fix HIGHER_LEVEL_REVIEW check

* Revert "fix HIGHER_LEVEL_REVIEW check"

This reverts commit 1499727.

* Konstantin/appeals 59181 (#22992)

* eligible to ineligible test added

* eligible_to_ineligible test added

* one added, 2 updated

* empty line removed

* spec_helper restored

* success message updated

* empty line removed

* succes message expectation update in tests

* wording updated

* typo fixed

* linter addressed

* scenario_create_issues_spec.rb deleted, it was an invalid draft accidently pushed in previous PR

* add last sync to RIU's, update contention updated and remoted at , ac… (#23092)

* add last sync to RIU's, update contention updated and remoted at , account for CF intaked RIs based on original_casflow_request_issue_id

* fix rspec

* fix discription texts

* fix missing descriptions

* fix epe's getting created and error on missing ineligible_due_to (#23103)

* update contention text fix for eligibility changes

* fix the unidentified_text and contention_refference_id (#23119)

* fix the unidentified_text and contention_refference_id

* fix rspec and lint

* Jonathan/dru eventrecord dupe fix (#23162)

* consolidating review update into 1 service class

* removing double find

* including test scenario for claimreview

* updating test

* Nader/cont ref id unid issu txt fix (#23164)

* fix the missing contention reference id and unidentified issue text

* fix spec

* fix before issues query

* fix filed asignments when nil

* fix lint issue

* refactor update logic to not depend on RequestIssuesUpdate (#23187)

* refactor update logic to not depend on RequestIssuesUpdate

* fix rspec

* Konstantin/prevent check for before ama! (#23180)

* issue_from_event? check added into close_if_ineligible!

* alternative approach added

* check if appeal added

* comments removed

* status ok changed to created, close_if_ineligible! updated, useless methods removed

* close_if_ineligible! updated

* cleaned

* adding "contested" to UI text

---------



* fix the remove of issues created from vbms, add before audit, all fie… (#23202)

* fix the remove of issues created from vbms, add before audit, all fields saved for all evenets except edit

* final fixes and changes to veteran_participant_id and legacy_issue processing call

* add legacy processing for eligibility change

* add more logic for eligibility changes with legacy issues

* fix verify_contentions

* Add disabling of edit contention title button on the edit issues page when feature toggle enabled (#23194)

* Pass disableEditingForCompAndPen toggle to EditContentionTitle, enable/disable edit button depending on toggle status

* add feature tests for contention title disable

* remove byebug

---------



* remove _ext_ table from schema

* add saftey operator for missing request_issues_update

* fix optin check to pull from parser not review

* Revert "fix optin check to pull from parser not review"

This reverts commit c9cd5a9.

* Revert "add saftey operator for missing request_issues_update"

This reverts commit 7f2fd96.

* Revert "remove _ext_ table from schema"

This reverts commit 63758f2.

* remove _ext_ table from schema

* add back _ext_ table

---------

Co-authored-by: Will Love <wlove29@gmail.com>
Co-authored-by: TuckerRose <tuckerrose@tuckerroses-mbp.lan>
Co-authored-by: Enrilo Ugalde <71367882+Jruuuu@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <98970951+jtsangVA@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <tsang_jonathan@bah.com>
Co-authored-by: Enrilo Ugalde <ugalde_enrilo@bah.com>
Co-authored-by: isaiahsaucedo <irsaucedo5@gmail.com>
Co-authored-by: Calvin <Calvin.Costa@va.gov>
Co-authored-by: Craig Reese <Reese_Craig@bah.com>
Co-authored-by: Jeremy Croteau <jcroteau@users.noreply.github.com>
Co-authored-by: (Jeffrey) Aaron Willis <98484567+Aaron-Willis@users.noreply.github.com>
Co-authored-by: Konstantin Shevtsov <166068160+KonstantinShevtsov@users.noreply.github.com>
Co-authored-by: TuckerRose <tuckerrose@TuckerRoses-MacBook-Pro.local>
Co-authored-by: Chris-Martine <135330019+Chris-Martine@users.noreply.github.com>
Co-authored-by: kshiflett88 <kodishiflett@gmail.com>
Co-authored-by: root <root@DESKTOP-IBDKNPF>
Co-authored-by: nicorithner-bah <148365039+nicorithner-bah@users.noreply.github.com>
Co-authored-by: Chris-Martine <christopher.martine@va.gov>
Co-authored-by: Matt Ray <matthew.ray@va.gov>
Co-authored-by: Nico Rithner <nicolas.rithner@va.gov>
Co-authored-by: Matt Ray <108031363+mattray-gov@users.noreply.github.com>
Co-authored-by: Jonathan Tsang <jonathan.tsang@va.gov>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants