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

Enhance/tprm #861

Merged
merged 35 commits into from
Oct 11, 2024
Merged

Enhance/tprm #861

merged 35 commits into from
Oct 11, 2024

Conversation

Mohamed-Hacene
Copy link
Collaborator

@Mohamed-Hacene Mohamed-Hacene commented Sep 23, 2024

  • Add a "send mail" button to send the internal questionnaire
  • Align TPRM permissions with base access control model
  • Export the questionnaire
  • Allow base audit view for third party
  • Add a tag to know if requirements contain questions
  • Improve EntityAssessment/Audit ownership
  • Improve requirement assessment edit page server complexity

@Mohamed-Hacene Mohamed-Hacene marked this pull request as ready for review September 27, 2024 08:57
@Mohamed-Hacene Mohamed-Hacene marked this pull request as ready for review October 4, 2024 08:29
@Mohamed-Hacene Mohamed-Hacene requested review from nas-tabchiche, ab-smith and eric-intuitem and removed request for nas-tabchiche October 4, 2024 08:29
Copy link
Contributor

Choose a reason for hiding this comment

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

We should not put model-specific logic and components here, but rather use slots.


export const load: PageServerLoad = async (event) => {
return loadDetail({ event, model: getModelInfo('entity-assessments'), id: event.params.id });
};

export const actions: Actions = {
mailing: async ({ request, fetch, cookies }) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

mailing is not a very explicit name. Would we not gain better readability if we actually stated what this action does? E.g. emailQuestionnaire...
The URL of the endpoint should also be more specific than /entity-assessments/mailing

Copy link
Collaborator Author

@Mohamed-Hacene Mohamed-Hacene Oct 10, 2024

Choose a reason for hiding this comment

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

Yes I agree for the name, we'll need to change it anyway to add another action to send the external questionnaire by mail.
However, the endpoint is /compliance-assessments/mailing because we send the audit and not the entity-assessment. It is not explicit because it could be useful to send other audits than questionnaires in the future with the same endpoint as it is the same process but maybe with a different template.

Copy link
Contributor

@nas-tabchiche nas-tabchiche Oct 10, 2024

Choose a reason for hiding this comment

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

Was a typo, meant compliance-assessment/mailing.
The point is that the word 'mailing' does not explicitly convey what the endpoint actually does. That is, emailing the questionnaire to the designated representatives

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Actually not, the endpoint is sending an audit to its authors so the name cannot be focused on the questionnaire, but it should be more precise I agree, like "send_mail" or "send_audit" maybe

Copy link
Contributor

@nas-tabchiche nas-tabchiche left a comment

Choose a reason for hiding this comment

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

LGTM

@nas-tabchiche nas-tabchiche merged commit 5ca3019 into main Oct 11, 2024
18 checks passed
@nas-tabchiche nas-tabchiche deleted the enhance/tprm branch October 11, 2024 09:12
@github-actions github-actions bot locked and limited conversation to collaborators Oct 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants