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

Communication: Add FAQs to Artemis #9325

Merged
merged 125 commits into from
Oct 3, 2024
Merged

Conversation

cremertim
Copy link
Contributor

@cremertim cremertim commented Sep 17, 2024

Checklist

General

Server

  • Important: I implemented the changes with a very good performance and prevented too many (unnecessary) and too complex database calls.
  • I strictly followed the principle of data economy for all database calls.
  • I strictly followed the server coding and design guidelines.
  • I added multiple integration tests (Spring) related to the features (with a high test coverage).
  • I added pre-authorization annotations according to the guidelines and checked the course groups for all new REST Calls (security).
  • I documented the Java code using JavaDoc style.

Client

  • Important: I implemented the changes with a very good performance, prevented too many (unnecessary) REST calls and made sure the UI is responsive, even with large data (e.g. using paging).
  • I strictly followed the principle of data economy for all client-server REST calls.
  • I strictly followed the client coding and design guidelines.
  • Following the theming guidelines, I specified colors only in the theming variable files and checked that the changes look consistent in both the light and the dark theme.
  • I added multiple integration tests (Jest) related to the features (with a high test coverage), while following the test guidelines.
  • I added authorities to all new routes and checked the course groups for displaying navigation elements (links, buttons).
  • I documented the TypeScript code using JSDoc style.
  • I added multiple screenshots/screencasts of my UI changes.
  • I translated all newly inserted strings into English and German.

Motivation and Context

It is tedious to answer the same question over and over again. To tackle this issue, this PR introduces a FAQ feature, which allows the custom creation of frequently asked questions.

Description

Server side:
I added the the basic structure of FAQ's. Also, i updated courses to have multiple FAQ's and a flag, that enables using them.

Client side:
The whole interface for creating, updating and deleting new FAQs in a Management Page (Instructor Side)
The whole interface for students to view and filter for FAQs in the Course Overview of a Course (new tab, if faqs are enabled)

Steps for Testing

Prerequisites:

  • 1 Instructor
  • 1 Editor
  • 1 Students
  1. Log in to Artemis as Instructor

  2. Navigate to Course Management

  3. Create a new Course with FAQs enabled / Enable FAQs for a existing course

  4. Go to the FAQ Management

  5. Create / Delete / Update FAQ's
    6 Filter for FAQ's in the Management Page

  6. Try to go to the FAQ Management as an Editor/Tutor, this should not be possible.

  7. Log into Artemis as Student within the same course

  8. Go to Course Overview

  9. See previously created FAQ's

  10. Filter the FAQ's

Testserver States

Note

These badges show the state of the test servers.
Green = Currently available, Red = Currently locked
Click on the badges to get to the test servers.







Review Progress

Performance Review

  • I (as a reviewer) confirm that the client changes (in particular related to REST calls and UI responsiveness) are implemented with a very good performance even for very large courses with more than 2000 students.
  • I (as a reviewer) confirm that the server changes (in particular related to database calls) are implemented with a very good performance even for very large courses with more than 2000 students.

Code Review

  • Code Review 1
  • Code Review 2

Manual Tests

  • Test 1
  • Test 2

Exam Mode Test

  • Test 1
  • Test 2

Performance Tests

  • Test 1
  • Test 2

Test Coverage

Client

Class/File Line Coverage Confirmation (assert/expect)
faq.component.ts 95,8%
faq-update.component.ts 98,57%
faq-service.component.ts 100%
faq-utils.component.ts 90%
course-faq.component.ts 97,72%
course-faq-accordion.component.ts 100%

Server

Class/File Line Coverage Confirmation (assert/expect)
FaqRessource.java 100%

Screenshots

image
Student view (Course Overview FAQ Tab)
image
Instructor view (FAQ Management Page)
image
Creation / Update Dialog
image
Flag to enable FAQ

Summary by CodeRabbit

Summary by CodeRabbit

  • New Features

    • Introduced a Frequently Asked Questions (FAQ) management system, allowing users to create, update, retrieve, and delete FAQs associated with courses.
    • Enhanced FAQ management with a dedicated component for improved user interaction.
    • Added a user-friendly interface for editing FAQs, including a Markdown editor and category selector.
    • Implemented role-based access control for FAQ actions.
  • Bug Fixes

    • Resolved various issues related to the display and management of FAQs.
  • Documentation

    • Updated localization files to include new strings for FAQ features in English and German.
  • Style

    • Enhanced UI components for better accessibility and user experience in FAQ management.
  • Chores

    • Minor adjustments to coverage thresholds in testing configurations.

Copy link
Contributor

@JohannesStoehr JohannesStoehr left a comment

Choose a reason for hiding this comment

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

Change of category length looks also good to me

Copy link
Contributor

@DominikRemo DominikRemo left a comment

Choose a reason for hiding this comment

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

Re-tested on ts4. Thank you for addressing my change requests 🚀

Copy link
Contributor

@pzdr7 pzdr7 left a comment

Choose a reason for hiding this comment

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

Thanks for incorporating my change requests. Code 👍

Copy link
Contributor

@coolchock coolchock left a comment

Choose a reason for hiding this comment

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

re-approve

Copy link
Member

@farisd16 farisd16 left a comment

Choose a reason for hiding this comment

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

Retested on ts4, worked as expected

@krusche krusche added this to the 7.5.6 milestone Oct 3, 2024
@krusche krusche changed the title Feature: Implement FAQ system to Artemis Communication: Add FAQs to Artemis Oct 3, 2024
@krusche krusche merged commit c3ab176 into develop Oct 3, 2024
18 of 24 checks passed
@krusche krusche deleted the feature/faq/implement-faq-basis branch October 3, 2024 19:03
@coderabbitai coderabbitai bot mentioned this pull request Oct 4, 2024
19 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
client Pull requests that update TypeScript code. (Added Automatically!) communication Pull requests that affect the corresponding module core Pull requests that affect the corresponding module database Pull requests that update the database. (Added Automatically!). Require a CRITICAL deployment. playwright ready to merge server Pull requests that update Java code. (Added Automatically!) tests
Projects
Status: Merged
Development

Successfully merging this pull request may close these issues.