-
Notifications
You must be signed in to change notification settings - Fork 8
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
#2157 work package templates createedit form #2646
#2157 work package templates createedit form #2646
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't delete a work opackage template anymore. I think the link takes up the entire component.
The cancel button doesn't work on the edit page
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks mostly good just a couple comments
src/frontend/src/pages/AdminToolsPage/AdminToolsProjectsConfig.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/AdminToolsPage/ProjectsConfig/WorkPackageTemplateTable.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateForm.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! I really love the form, and it works really well!
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateFormView.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/AdminToolsPage/ProjectsConfig/WorkPackageTemplateTable.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/CreateWorkPackageTemplate.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/CreateWorkPackageTemplate.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateForm.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateForm.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/EditWorkPackageTemplate.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/EditWorkPackageTemplate.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateFormView.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
|
||
const { data: workPackageTemplate } = useSingleWorkPackageTemplate(workPackageTemplateId!); | ||
|
||
const defaultValues = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Import the type for this (which can be renamed WorkPackageTemplateFormInputs or something to declare the type here
You can actually use the spread operator for all of the fields, and will just manually need to override stage and blocked by
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateForm.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateFormView.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/EditWorkPackageTemplate.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateForm.tsx
Outdated
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateForm.tsx
Show resolved
Hide resolved
src/frontend/src/pages/WorkPackageTemplateForm/WorkPackageTemplateFormView.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Changes
Screenshots
Checklist
It can be helpful to check the
Checks
andFiles changed
tabs.Please review the contributor guide and reach out to your Tech Lead if anything is unclear.
Please request reviewers and ping on slack only after you've gone through this whole checklist.
yarn.lock
changes (unless dependencies have changed)Closes # (issue #2157 )