feat(course): implement PATCH support for partial course updates and improve issue templates #79
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🔧 Overview
This pull request introduces multiple enhancements, including:
PATCH🗂️ Changes Breakdown
📄 Issue Templates
Removed the old bug report template:
🗑️ .github/ISSUE_TEMPLATE/bug_report.mdAdded two new structured templates:
.github/ISSUE_TEMPLATE/issue_en.md.github/ISSUE_TEMPLATE/issue_de.mdEach includes standard sections for:
🛠️ Backend: Partial Course Updates
Controller
PATCH /courses/{id}endpoint inCourseController→
updateCoursePartial(...)methodDTO
CourseUpdateRequestto support flexible, field-specific updatesService Layer
Extended
CourseServiceandCourseServiceImplwithupdateCoursePartial(...)Ensures safe merging of fields like:
Avoids overwriting unchanged fields
📄 Affected Files:
CourseController.javaCourseUpdateRequest.javaCourseService.javaCourseServiceImpl.java🧪 Backend: Unit Tests
Added dedicated tests for the new partial update logic in:
CourseControllerTest.javaCovers:
🌐 Client-Side: HTTP Method Update
Updated HTTP methods from
PUTtoPATCHfor:completeLesson(...)completeCourse(...)📄 File:
client/src/services/course.service.tsAligns client behavior with new backend support for partial updates
📌 Summary
This PR brings the course update functionality in line with REST best practices by introducing
PATCHsupport, improves flexibility with a clean DTO pattern, strengthens test coverage, and unifies backend/frontend behavior. It also introduces better structured, multilingual issue templates to streamline collaboration.