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

10074 bug: Auto Scroll Issues on Petitions Clerk Create Case Form (and more) #5382

Merged
merged 35 commits into from
Sep 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
4dd0483
10074-bug: initial work
Mwindo Sep 13, 2024
d63f3bc
10074-bug: fix more onBlurs
Mwindo Sep 13, 2024
285a98e
10074-bug: trying to standardize onBlurs in the form
Mwindo Sep 13, 2024
19b8053
10074-bug: fixing some missed onBlurs, adding typing to onBlur
Mwindo Sep 16, 2024
82e3b6a
10074-bug: update even more onBlurs
Mwindo Sep 16, 2024
b169982
10074-bug: update PetitionPaymentForm
Mwindo Sep 19, 2024
bb241d6
10074-bug: add allowEmptyString so that petitionPaymentMethod is actu…
Mwindo Sep 19, 2024
c4cb6e8
10074-bug: rename onValidate to validateFormData
Mwindo Sep 19, 2024
cc5e87b
10074-bug: fix integration test
Mwindo Sep 19, 2024
0706b7e
10074-bug: merge test into branch
Mwindo Sep 19, 2024
4bf80c7
10074-bug: update trial sessions form to keep errornotification in sy…
Mwindo Sep 19, 2024
ec8583b
10074-bug: fix rename issue
Mwindo Sep 19, 2024
eed3942
10075-bug: trying a different strategy to see if it is better
Mwindo Sep 19, 2024
8b3c5a5
10074-bug: fix other forms too
Mwindo Sep 19, 2024
02014eb
10074-bug: fix document selection form
Mwindo Sep 19, 2024
c5b0ef8
10074-bug: fix a couple more forms
Mwindo Sep 19, 2024
6f7b9db
10074-bug: add live validation to status report order form
Mwindo Sep 20, 2024
9ba2682
10074-bug: fix EditDocketEntryMeta
Mwindo Sep 20, 2024
7753a96
10074-bug: fix docektEntryQC
Mwindo Sep 20, 2024
eb57afe
10074-bug: fix more forms
Mwindo Sep 20, 2024
0aba290
10074-bug: remove console.log
Mwindo Sep 20, 2024
3f08d23
10074-bug: update pretty much every submit sequence
Mwindo Sep 20, 2024
5fa5ee1
10074-bug: add scroll to some report sequences
Mwindo Sep 20, 2024
2f10204
Merge remote-tracking branch 'ustc/test' into 10074-bug-to-test
Mwindo Sep 23, 2024
6d2a075
10074: fix error as well as a type; add a test
Mwindo Sep 23, 2024
de8d665
10074-bug: fix a couple of breaking tests
Mwindo Sep 23, 2024
479b89d
10074-bug-to-test: fix test
Mwindo Sep 23, 2024
c23a088
10074-bug: update test name after review feedback
Mwindo Sep 23, 2024
1650c94
10074-bug: get openCompleteAndSendMessageModalSequence to mimic compl…
Mwindo Sep 23, 2024
e85f96d
10074-bug: update case advanced search form, which I overlooked
Mwindo Sep 23, 2024
eebcfaf
10074-bug: update validateAddPetitionSequernce to sync ErrorNotificat…
Mwindo Sep 23, 2024
3d2e2fc
10074-bug: update advanced search forms
Mwindo Sep 23, 2024
dd6d219
10074-bug: fix failing tests
Mwindo Sep 23, 2024
8fb1b8d
10074-bug: update a few more overlooked forms
Mwindo Sep 24, 2024
8a08e96
10074-bug: fix failing tests
Mwindo Sep 24, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { respondentModifiesContactInfo } from '../../../../helpers/myAccount/res
const BAR_NUMBER = 'WN7777';
const USER = 'irspractitioner2';

describe('a repondent modifies their address', () => {
describe('a respondent modifies their address', () => {
it('should generate a notice of change address for all cases associated with the respondent', function () {
loginAsPetitioner();
petitionerCreatesElectronicCase().then(docketNumber => {
Expand Down
4 changes: 2 additions & 2 deletions shared/src/business/entities/cases/Case.ts
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,7 @@ export class Case extends JoiValidationEntity {
mailingDate: JoiValidationConstants.STRING.max(25)
.when('isPaper', {
is: true,
otherwise: joi.allow(null).optional(),
otherwise: joi.optional().allow(null),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Just making the order of these consistent in the file.

then: joi.required(),
})
.description('Date that petition was mailed to the court.')
Expand Down Expand Up @@ -617,7 +617,7 @@ export class Case extends JoiValidationEntity {
'petitionPaymentStatus',
{
is: PAYMENT_STATUS.WAIVED,
otherwise: joi.allow(null).optional(),
otherwise: joi.optional().allow(null),
then: JoiValidationConstants.ISO_DATE.max('now').required(),
},
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ describe('Docket clerk opinion advanced search', () => {

expect(cerebralTest.getState('alertError')).toEqual({
messages: ['Start date cannot be in the future. Enter valid start date.'],
title: 'Please correct the following errors:',
scrollToErrorNotification: true,
title: 'Please correct the following errors on the page:',
});

await cerebralTest.runSequence('advancedSearchTabChangeSequence');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,7 @@ describe('Docket clerk advanced order search', () => {
cerebralTest.setState('advancedSearchForm', {
orderSearch: {
dateRange: DATE_RANGE_SEARCH_OPTIONS.CUSTOM_DATES,
scrollToErrorNotification: true,
startDate: '01/01/3001',
},
});
Expand All @@ -155,7 +156,8 @@ describe('Docket clerk advanced order search', () => {

expect(cerebralTest.getState('alertError')).toEqual({
messages: ['Start date cannot be in the future. Enter valid start date.'],
title: 'Please correct the following errors:',
scrollToErrorNotification: true,
title: 'Please correct the following errors on the page:',
});

await cerebralTest.runSequence('advancedSearchTabChangeSequence');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ export const petitionsClerkUpdatesCaseDetail = cerebralTest => {
});
expect(cerebralTest.getState('alertError')).toEqual({
messages: ['Select a case type', 'Select a case procedure'],
scrollToErrorNotification: true,
title: 'Please correct the following errors on the page:',
});

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export const setScrollToErrorNotificationAction = ({ props }) => {
return {
...props,
scrollToErrorNotification: true,
};
};
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ describe('setValidationAlertErrors', () => {
});
expect(state.alertError).toMatchObject({
messages: ['Some issue occurred'],
scrollToErrorNotification: false,
});
});

Expand Down Expand Up @@ -140,4 +141,23 @@ describe('setValidationAlertErrors', () => {
messages: ['second nested', 'first nested'],
});
});

it('should set state.alertError to true when scrollToErrorNotification is true', async () => {
const { state } = await runAction(setValidationAlertErrorsAction, {
modules: {
presenter,
},
props: {
errors: {
irsNoticeDate: 'Some issue occurred',
},
scrollToErrorNotification: true,
},
state: {},
});
expect(state.alertError).toMatchObject({
messages: ['Some issue occurred'],
scrollToErrorNotification: true,
});
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ export const setValidationAlertErrorsAction = ({
}
}),
),
scrollToErrorNotification: props.scrollToErrorNotification || false,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This gives us a way explicitly telling the app when to scroll to the ErrorNotification banner. By default, we don't scroll. To change the default, we can call the above setScrollToErrorNotificationAction.

title: 'Please correct the following errors on the page:',
};
store.set(state.alertError, alertError);
Expand Down
3 changes: 3 additions & 0 deletions web-client/src/presenter/actions/validateCaseDetailsAction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ export const validateCaseDetailsAction = async ({
caseDetail: {
...caseDetail,
...form,
caseType: form.caseType || null,
petitionPaymentDate: form.petitionPaymentDate || null,
petitionPaymentMethod: form.petitionPaymentMethod || null,
Comment on lines +22 to +23
Copy link
Contributor Author

@Mwindo Mwindo Sep 20, 2024

Choose a reason for hiding this comment

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

This fixes issue 2 as listed in the PR description by triggering the validation rather than allowing the form to pass and then cause a 400.

preferredTrialCity: form.preferredTrialCity
? form.preferredTrialCity
: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ describe('validatePetitionerAction', () => {
},
});

expect(result.state.validationErrors.contact).toEqual(null);
expect(result.state.validationErrors).toBeUndefined();
expect(successStub.mock.calls.length).toEqual(1);
});

Expand Down
5 changes: 1 addition & 4 deletions web-client/src/presenter/actions/validatePetitionerAction.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ export const validatePetitionerAction = ({
applicationContext,
get,
path,
store,
}: ActionProps) => {
const { contact } = get(state.form);
const caseDetail = get(state.caseDetail);
Expand All @@ -26,11 +25,9 @@ export const validatePetitionerAction = ({
existingPetitioners: caseDetail.petitioners,
});

store.set(state.validationErrors.contact, errors);

if (isEmpty(errors)) {
return path.success();
} else {
return path.error({ errors });
return path.error({ errors: { contact: errors } });
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The way this action was functioning was failing to update the corresponding form (EditPetitionerInformationInternal.tsx) appropriately.

}
};
1 change: 0 additions & 1 deletion web-client/src/presenter/computeds/alertHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ export const alertHelper = (get: Get): any => {

return {
messagesDeduped: uniq(alertError.messages).filter(Boolean),
preventAutoScroll: false,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is useless since it is always false.

responseCode: alertError.responseCode,
showErrorAlert:
!!alertError.title || !!alertError.message || !!alertError.messages,
Expand Down
2 changes: 2 additions & 0 deletions web-client/src/presenter/presenter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -604,6 +604,7 @@ import { validateRemoveFromTrialSessionSequence } from './sequences/validateRemo
import { validateSelectDocumentTypeSequence } from './sequences/validateSelectDocumentTypeSequence';
import { validateSetForHearingSequence } from './sequences/validateSetForHearingSequence';
import { validateStampSequence } from './sequences/validateStampSequence';
import { validateStatusReportOrderSequence } from '@web-client/presenter/sequences/StatusReportOrder/validateStatusReportOrderSequence';
import { validateTrialSessionHearingNoteSequence } from './sequences/validateTrialSessionHearingNoteSequence';
import { validateTrialSessionNoteSequence } from './sequences/validateTrialSessionNoteSequence';
import { validateTrialSessionPlanningSequence } from './sequences/validateTrialSessionPlanningSequence';
Expand Down Expand Up @@ -1594,6 +1595,7 @@ export const presenterSequences = {
validateSetForHearingSequence:
validateSetForHearingSequence as unknown as Function,
validateStampSequence: validateStampSequence as unknown as Function,
validateStatusReportOrderSequence,
validateTrialSessionHearingNoteSequence:
validateTrialSessionHearingNoteSequence as unknown as Function,
validateTrialSessionNoteSequence:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ import { getPendingMotionDocketEntriesAction } from '@web-client/presenter/actio
import { getSubmittedAndCavCasesByJudgeAction } from '@web-client/presenter/actions/JudgeActivityReport/getSubmittedAndCavCasesByJudgeAction';
import { parallel } from 'cerebral';
import { resetHasUserSubmittedFormAction } from '@web-client/presenter/actions/JudgeActivityReport/resetHasUserSubmittedFormAction';
import { setAlertErrorAction } from '../../actions/setAlertErrorAction';
import { setCavAndSubmittedCasesAction } from '@web-client/presenter/actions/JudgeActivityReport/setCavAndSubmittedCasesAction';
import { setDefaultSubmittedAndCavSortOrderAction } from '@web-client/presenter/actions/JudgeActivityReport/setDefaultSubmittedAndCavSortOrderAction';
import { setJudgeActivityReportFiltersAction } from '@web-client/presenter/actions/JudgeActivityReport/setJudgeActivityReportFiltersAction';
import { setPendingMotionDocketEntriesForCurrentJudgeAction } from '@web-client/presenter/actions/PendingMotion/setPendingMotionDocketEntriesForCurrentJudgeAction';
import { setScrollToErrorNotificationAction } from '@web-client/presenter/actions/setScrollToErrorNotificationAction';
import { setValidationAlertErrorsAction } from '../../actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '@web-client/presenter/utilities/showProgressSequenceDecorator';
Expand All @@ -27,8 +27,8 @@ export const submitJudgeActivityReportSequence = showProgressSequenceDecorator([
validateJudgeActivityReportSearchAction,
{
error: [
setAlertErrorAction,
Copy link
Contributor Author

@Mwindo Mwindo Sep 20, 2024

Choose a reason for hiding this comment

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

Throughout, I have removed setAlertErrorAction when it precedes setValidationAlertErrorsAction since the latter overwrites the former. On submissions, I have called setScrollToErrorNotificationsAction. A good portion of this PR is refactoring sequences to follow this pattern.

setValidationErrorsAction,
setScrollToErrorNotificationAction,
setValidationAlertErrorsAction,
],
success: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import { getCasesClosedByJudgeAction } from '../../actions/JudgeActivityReport/g
import { getJudgeActivityReportCountsAction } from '../../actions/JudgeActivityReport/getJudgeActivityReportCountsAction';
import { getTrialSessionsForJudgeActivityReportAction } from '../../actions/JudgeActivityReport/getTrialSessionsForJudgeActivityReportAction';
import { parallel } from 'cerebral';
import { setAlertErrorAction } from '../../actions/setAlertErrorAction';
import { setHasUserSubmittedFormAction } from '@web-client/presenter/actions/JudgeActivityReport/setHasUserSubmittedFormAction';
import { setJudgeActivityReportDataAction } from '@web-client/presenter/actions/JudgeActivityReport/setJudgeActivityReportDataAction';
import { setScrollToErrorNotificationAction } from '@web-client/presenter/actions/setScrollToErrorNotificationAction';
import { setValidationAlertErrorsAction } from '../../actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '@web-client/presenter/utilities/showProgressSequenceDecorator';
Expand All @@ -21,8 +21,8 @@ export const submitJudgeActivityStatisticsReportSequence =
validateJudgeActivityStatisticsReportSearchAction,
{
error: [
setAlertErrorAction,
setValidationErrorsAction,
setScrollToErrorNotificationAction,
setValidationAlertErrorsAction,
],
success: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { setSaveAlertsForNavigationAction } from '@web-client/presenter/actions/
import { setTokenAction } from '@web-client/presenter/actions/Login/setTokenAction';
import { setUserAction } from '@web-client/presenter/actions/setUserAction';
import { setUserPermissionsAction } from '@web-client/presenter/actions/setUserPermissionsAction';
import { setValidationAlertErrorsAction } from '@web-client/presenter/actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '@web-client/presenter/actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '../../utilities/showProgressSequenceDecorator';
import { submitChangePasswordAction } from '@web-client/presenter/actions/Login/submitChangePasswordAction';
import { validateChangePasswordFormAction } from '@web-client/presenter/actions/Login/validateChangePasswordFormAction';
Expand All @@ -18,7 +18,7 @@ export const submitChangePasswordSequence = [
clearAlertsAction,
validateChangePasswordFormAction,
{
error: [setValidationAlertErrorsAction],
error: [setValidationErrorsAction],
success: [
submitChangePasswordAction,
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ import { clearSearchResultsAction } from '../../actions/AdvancedSearch/clearSear
import { clearSearchTermAction } from '../../actions/clearSearchTermAction';
import { defaultCaseSearchDatesAction } from '@web-client/presenter/actions/AdvancedSearch/defaultCaseSearchDatesAction';
import { setAdvancedSearchResultsAction } from '../../actions/AdvancedSearch/setAdvancedSearchResultsAction';
import { setAlertErrorAction } from '../../actions/setAlertErrorAction';
import { setScrollToErrorNotificationAction } from '@web-client/presenter/actions/setScrollToErrorNotificationAction';
import { setValidationAlertErrorsAction } from '@web-client/presenter/actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '../../utilities/showProgressSequenceDecorator';
import { startShowValidationAction } from '@web-client/presenter/actions/startShowValidationAction';
Expand All @@ -16,10 +17,11 @@ export const submitPublicCaseAdvancedSearchSequence = [
validateCaseAdvancedSearchAction,
{
error: [
setAlertErrorAction,
startShowValidationAction,
setValidationErrorsAction,
setScrollToErrorNotificationAction,
setValidationAlertErrorsAction,
clearSearchResultsAction,
startShowValidationAction,
],
success: showProgressSequenceDecorator([
clearAlertsAction,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ import { caseExistsAction } from '../../actions/caseExistsAction';
import { clearSearchResultsAction } from '../../actions/AdvancedSearch/clearSearchResultsAction';
import { clearSearchTermAction } from '../../actions/clearSearchTermAction';
import { navigateToCaseDetailAction } from '../../actions/navigateToCaseDetailAction';
import { setAlertErrorAction } from '../../actions/setAlertErrorAction';
import { setDocketNumberFromAdvancedSearchAction } from '../../actions/AdvancedSearch/setDocketNumberFromAdvancedSearchAction';
import { setNoMatchesCaseSearchAction } from '../../actions/AdvancedSearch/setNoMatchesCaseSearchAction';
import { setScrollToErrorNotificationAction } from '@web-client/presenter/actions/setScrollToErrorNotificationAction';
import { setValidationAlertErrorsAction } from '@web-client/presenter/actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '../../utilities/showProgressSequenceDecorator';
import { startShowValidationAction } from '../../actions/startShowValidationAction';
Expand All @@ -17,8 +18,9 @@ export const submitPublicCaseDocketNumberSearchSequence = [
validateCaseDocketNumberSearchAction,
{
error: [
setAlertErrorAction,
setValidationErrorsAction,
setScrollToErrorNotificationAction,
setValidationAlertErrorsAction,
clearSearchResultsAction,
],
success: showProgressSequenceDecorator([
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ import { clearAlertsAction } from '../../actions/clearAlertsAction';
import { clearSearchResultsAction } from '../../actions/AdvancedSearch/clearSearchResultsAction';
import { clearSearchTermAction } from '../../actions/clearSearchTermAction';
import { setAdvancedSearchResultsAction } from '../../actions/AdvancedSearch/setAdvancedSearchResultsAction';
import { setAlertErrorAction } from '../../actions/setAlertErrorAction';
import { setScrollToErrorNotificationAction } from '@web-client/presenter/actions/setScrollToErrorNotificationAction';
import { setValidationAlertErrorsAction } from '@web-client/presenter/actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '../../utilities/showProgressSequenceDecorator';
import { startShowValidationAction } from '../../actions/startShowValidationAction';
Expand All @@ -14,10 +15,11 @@ export const submitPublicOpinionAdvancedSearchSequence = [
validateOpinionAdvancedSearchAction,
{
error: [
setAlertErrorAction,
startShowValidationAction,
setValidationErrorsAction,
setScrollToErrorNotificationAction,
setValidationAlertErrorsAction,
clearSearchResultsAction,
startShowValidationAction,
],
success: showProgressSequenceDecorator([
clearAlertsAction,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ import { clearAlertsAction } from '../../actions/clearAlertsAction';
import { clearSearchResultsAction } from '../../actions/AdvancedSearch/clearSearchResultsAction';
import { clearSearchTermAction } from '../../actions/clearSearchTermAction';
import { setAdvancedSearchResultsAction } from '../../actions/AdvancedSearch/setAdvancedSearchResultsAction';
import { setAlertErrorAction } from '../../actions/setAlertErrorAction';
import { setScrollToErrorNotificationAction } from '@web-client/presenter/actions/setScrollToErrorNotificationAction';
import { setValidationAlertErrorsAction } from '@web-client/presenter/actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '../../utilities/showProgressSequenceDecorator';
import { startShowValidationAction } from '../../actions/startShowValidationAction';
Expand All @@ -14,10 +15,11 @@ export const submitPublicOrderAdvancedSearchSequence = [
validateOrderAdvancedSearchAction,
{
error: [
setAlertErrorAction,
startShowValidationAction,
setValidationErrorsAction,
setScrollToErrorNotificationAction,
setValidationAlertErrorsAction,
clearSearchResultsAction,
startShowValidationAction,
],
success: showProgressSequenceDecorator([
clearAlertsAction,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { clearAlertsAction } from '@web-client/presenter/actions/clearAlertsActi
import { navigateToPathAction } from '@web-client/presenter/actions/navigateToPathAction';
import { prepareStatusReportOrderAction } from '../../actions/StatusReportOrder/prepareStatusReportOrderAction';
import { setAlertErrorAction } from '@web-client/presenter/actions/setAlertErrorAction';
import { setScrollToErrorNotificationAction } from '@web-client/presenter/actions/setScrollToErrorNotificationAction';
import { setValidationAlertErrorsAction } from '@web-client/presenter/actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '../../utilities/showProgressSequenceDecorator';
Expand All @@ -13,7 +14,11 @@ export const submitStatusReportOrderSequence = [
clearAlertsAction,
validateStatusReportOrderFormAction,
{
error: [setValidationErrorsAction, setValidationAlertErrorsAction],
error: [
setValidationErrorsAction,
setScrollToErrorNotificationAction,
setValidationAlertErrorsAction,
],
success: [
prepareStatusReportOrderAction,
submitCourtIssuedOrderSequence,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import { clearAlertsAction } from '@web-client/presenter/actions/clearAlertsAction';
import { setValidationAlertErrorsAction } from '@web-client/presenter/actions/setValidationAlertErrorsAction';
import { setValidationErrorsAction } from '../../actions/setValidationErrorsAction';
import { showProgressSequenceDecorator } from '../../utilities/showProgressSequenceDecorator';
import { validateStatusReportOrderFormAction } from '../../actions/StatusReportOrder/validateStatusReportOrderFormAction';

export const validateStatusReportOrderSequence = [
showProgressSequenceDecorator([
clearAlertsAction,
validateStatusReportOrderFormAction,
{
error: [setValidationErrorsAction, setValidationAlertErrorsAction],
success: [clearAlertsAction],
},
]),
] as unknown as () => void;
Loading
Loading