#5594 - New unified data path for appeals and forms + non punitive (Student UI)#5767
Conversation
…als-and-forms-student-ui
| }, | ||
| }, | ||
| setup(props) { | ||
| const label = computed(() => |
There was a problem hiding this comment.
Created the "maps" inside the components. The reason we have maps outside the component was to allow reuse, mainly between form.io definition and Vue UI, which is no longer the case in many cases.
If there is a strong feeling that this type of map must be done externally, please let me know, and I will move it.
There was a problem hiding this comment.
I also feel that this map must be done outside and also status and label can be an object which is derived at once based on props.status so they can be derived at once.
| }, | ||
| }, | ||
| setup(props) { | ||
| const chipStatus = computed(() => { |
There was a problem hiding this comment.
| Declined = "Declined", | ||
| } | ||
|
|
||
| export interface FormSubmissionItemApproval { |
There was a problem hiding this comment.
The DTOs FormSubmissionItemApproval, FormSubmissionItem, FormSubmissionItemSubmitted were based on existing appeals submissions and may be adapted in upcoming PRs once the API is fully connected.
| if (props.applicationId) { | ||
| try { | ||
| application = | ||
| await ApplicationService.shared.getApplicationForRequestChange( |
There was a problem hiding this comment.
This code remains from the previous solution, but a new solution should be implemented in upcoming PRs.
There was a problem hiding this comment.
Pull request overview
This PR introduces a new unified Student UI flow for “Forms” that consolidates standard forms and appeals into a single submission/history experience, supported by a new student API endpoint that returns dynamic form configurations by category.
Changes:
- Added new Student “Forms” pages (selector, submission, history, view) and navigation updates (menu + application summary deep link).
- Added a new student API controller endpoint to fetch dynamic form configurations for student submissions (forms + appeals).
- Introduced shared types/DTOs and a mocked web API client/service layer for form submissions.
Reviewed changes
Copilot reviewed 30 out of 30 changed files in this pull request and generated 31 comments.
Show a summary per file
| File | Description |
|---|---|
| sources/packages/web/src/views/student/form-submissions/StudentFormsSelectorFormsSection.vue | New “Standard forms” selection section. |
| sources/packages/web/src/views/student/form-submissions/StudentFormsSelectorAppealsSection.vue | New “Appeals” selection section with application-scoped and standalone appeal modes. |
| sources/packages/web/src/views/student/form-submissions/StudentFormsSelector.vue | Orchestrates selector sections and loads available configurations. |
| sources/packages/web/src/views/student/form-submissions/StudentFormsHistory.vue | New submission history UI with category filtering and navigation to read-only view. |
| sources/packages/web/src/views/student/form-submissions/StudentForms.vue | New tabbed container page for Submissions/History. |
| sources/packages/web/src/views/student/form-submissions/FormSubmissionView.vue | Read-only view for a submitted form submission and its items/decisions. |
| sources/packages/web/src/views/student/form-submissions/FormSubmission.vue | New submission view to render one-or-many Form.io forms and submit them. |
| sources/packages/web/src/views/student/StudentApplicationSummary.vue | Deep-link from application summary to new Forms selector when feature toggle is enabled. |
| sources/packages/web/src/views/student/AppStudent.vue | Replaces “Appeals” menu with “Forms” menu under feature toggle. |
| sources/packages/web/src/types/index.ts | Exposes new form submission contract types. |
| sources/packages/web/src/types/contracts/FormSubmissionContracts.ts | Adds shared enums/interfaces for form submissions in the web app. |
| sources/packages/web/src/types/AppRoutes.ts | Adds new student routes for Forms selector/history/submit/view. |
| sources/packages/web/src/services/http/dto/index.ts | Exposes new FormSubmission DTOs via the DTO barrel export. |
| sources/packages/web/src/services/http/dto/FormSubmission.dto.ts | Adds web DTOs for configurations + submission summary/details. |
| sources/packages/web/src/services/http/FormSubmissionsApi.ts | Adds HTTP client for form submissions (mocked summary/details). |
| sources/packages/web/src/services/http/ApiClient.ts | Registers FormSubmissionsApi in the shared API client. |
| sources/packages/web/src/services/FormSubmissionsService.ts | Adds service wrapper for form submission API calls. |
| sources/packages/web/src/router/StudentRoutes.ts | Wires new Forms routes into the student router. |
| sources/packages/web/src/constants/routes/RouteConstants.ts | Adds route name constants for Forms flows. |
| sources/packages/web/src/composables/useFeatureToggles.ts | Adds a local feature toggle for enabling the new Forms menu/flow. |
| sources/packages/web/src/composables/index.ts | Exports the new feature toggles composable. |
| sources/packages/web/src/components/generic/formio.vue | Extends the loaded event to include a formKey to correlate forms. |
| sources/packages/web/src/components/generic/StatusChipFormSubmissionDecision.vue | New chip component for per-item decision status. |
| sources/packages/web/src/components/generic/StatusChipFormSubmission.vue | New chip component for overall submission status (pending vs completed). |
| sources/packages/web/src/components/form-submissions/FormSubmissionItems.vue | New reusable component to render multiple Form.io forms and validate/submit them together. |
| sources/packages/backend/apps/api/src/services/dynamic-form-configuration/dynamic-form-configuration.service.ts | Adds ability to retrieve dynamic form configurations by form category and exposes extra fields. |
| sources/packages/backend/apps/api/src/route-controllers/index.ts | Exports the new form-submission controller and DTOs. |
| sources/packages/backend/apps/api/src/route-controllers/form-submission/models/form-submission.dto.ts | Adds API DTOs for returning student submission form configurations. |
| sources/packages/backend/apps/api/src/route-controllers/form-submission/form-submission.students.controller.ts | New students controller endpoint to return configurations for student forms/appeals. |
| sources/packages/backend/apps/api/src/app.students.module.ts | Registers the new students controller in the students module. |
| const programYearId = options?.programYearId ?? null; | ||
| const offeringIntensity = options?.offeringIntensity ?? null; | ||
| const dynamicForm = this.dynamicFormConfigurations.find( | ||
| return this.dynamicFormConfigurations.find( |
There was a problem hiding this comment.
As we are returning the complete object now, can we ensure to return a immutable copy?
There was a problem hiding this comment.
To ensure we are on the same page, by "immutable copy" you mean to return a copy of the object, similar to what is done for DTOs, but between services to prevent the consumer from updating the cache data?
Or, would it be something like Object.freeze that should have been done during the loadAllDynamicFormConfigurations?
There was a problem hiding this comment.
something like object.freeze to not allow the consumer to change the values, till now it is not required in loadAllDynamicFormConfigurations as only a string was exposed from the service but from the moment we return the object it has the potential to be modified at consumer.
There was a problem hiding this comment.
I can change it to be safe with the current implementation, but having this data in-memory was temporary. We must move this cached data to Redis, first ensuring Redis is stable and API will not crash if Redis is down.
There was a problem hiding this comment.
ha ha yes. For APIs we can also use the nestJS cache if we have issues with redis.
There was a problem hiding this comment.
Did the shallow freeze for the object and the array 😉
| return this.dynamicFormConfigurations.filter((dynamicFormConfiguration) => | ||
| formCategories.includes(dynamicFormConfiguration.formCategory), | ||
| ); |
There was a problem hiding this comment.
There was a problem hiding this comment.
| @@ -0,0 +1,164 @@ | |||
| <!-- Allow the student to submit a new form. --> | |||
| <template> | |||
There was a problem hiding this comment.
There was a problem hiding this comment.
Please feel free to bring it to the biz and ask if they are willing to move forward with some UI reorganization.
The suggestion seems mostly about navigation, which would allow the current components being built to still be useful 😉
There was a problem hiding this comment.
Not just the navigation was the intention. When I saw the form categories re-ordered based on where it came from and usage of filters to show form history vs appeals history, I started feeling like each form category can have it's own tab.
It can be either achieved by side nav or sub tabs, but then intention is to have a seperate area for a form category.
There was a problem hiding this comment.
Yeah, I am not feeling 100% about changing the order of those panels.
I am willing to get some biz feedback once presented to users.
|
Great start and thanks for the early PR to get feedback. Added some comments and suggestions. |
| (form) => !form.hasApplicationScope && !form.allowBundledSubmission, | ||
| ); | ||
| }, | ||
| { deep: true }, |
There was a problem hiding this comment.
Do we need { deep: true } here? The formsConfigurations in the current context is not having the properties modified individually. The object is assigned as a whole.
There was a problem hiding this comment.
I will review along upcming PRs 😉
What you just said makes sense. Let me give it a try and put more tests into it.
sh16011993
left a comment
There was a problem hiding this comment.
Superb work @andrewsignori-aot 👍
|
dheepak-aot
left a comment
There was a problem hiding this comment.
Thanks for making the changes. Looks good 👍




New Forms Menu
Submission Tab
Student formonsims.dynamic_form_configurations.form_category. Currently,has_application_scopeandallow_bundled_submissionare not being taken into consideration by the UI but the backend will use them in a generic way, allowing the functionality to be extended to these forms, following the same from the appeals.Student appealonsims.dynamic_form_configurations.form_category, thathas_application_scopeastrueandallow_bundled_submissionalsotrue.Student appealonsims.dynamic_form_configurations.form_category, thathas_application_scopeasfalseandallow_bundled_submissionalsofalse.Navigation from the Student application
When navigating from the student application, the "Appeas" section will be moved to the top to allow for quick interaction from the user.
History Tab
The history tab was refactored based on user feedback about a not clear separation between the appeals.
Forms/Appeals Submission View
sims.dynamic_form_configurations.form_type.Technical Considerations
truefor the review and will befalsebefore merge.views/student/form-submissions.views/student/appelashould be removed by the end of this effort. Note:appeal-legacyremoval to be discussed, but possible.Form.io UI References
form-key) and using it to relate the form submission to its data.SIMS/sources/packages/web/src/components/form-submissions/FormSubmissionItems.vue
Lines 39 to 45 in fae0120
Creating New-ish Components
v-for.Retrieving Dynamic Forms Configurations from the API
form-submissionscontroller, which will receive more API endpoints in upcoming PRs.