llTheBlankll / attendance-management-angular

robust Attendance Management System tailored for the Philippine education sector. Built with Spring Boot, WebSocket, and Angular, it offers real-time updates, secure JWT authentication, attendance analytics, and an intuitive interface. Efficiently track and manage attendance with tailored insights and notifications
Apache License 2.0
2 stars 1 forks source link

attendance-management-angular-13 (JS-0323) Detected usage of the `any… #14

Closed llTheBlankll closed 2 months ago

llTheBlankll commented 2 months ago

…` type

closes #13 by adding explicit type feat(app): enhance authentication service and improve DTO imports

Update AuthService to include LoginToken alongside LoginDTO for improved type safety during login requests
Adjust return types within AuthService:
    Replace generic Observable responses with specific HttpResponse variants involving either LoginToken/StatusMessageResponse or just StatusMessageResponse.
Modify AttendanceLineChartService's getAttendanceLineChart()/getSectionAttendanceLineChart() methods by specifying LineChartDTO in their return types while also importing it explicitly along with HttpResponse
Remove redundant HttpClient import statement from TopHeaderComponent
Enhance StudentService by returning more precise types:
    Convert countStudentsBySection() method's return value to an observable emitting HttpResponse wrapping around a CountDTO object
    Transform getAllStudents() method's result into an observable yielding StudentPaging objects rather than an unspecific any type
Refactor TeacherService to fetch Teacher entities wrapped inside HttpResponse instances via the getTeacherByUserId() function
Standardize SectionService by consistently utilizing observables encapsulating HTTP responses across all methods (createSection(), updateSection(), etc.) and importing required DTO classes like StatusMessageResponse upfront
Ensure proper typing throughout remaining components such as AnnouncementsComponent, AdminDashboardComponent, TeacherDashboardComponent, and TeacherStudentsComponent
deepsource-io[bot] commented 2 months ago

Here's the code health analysis summary for commits d7d9b98..b40cbde. View details on DeepSource ↗.

Analysis Summary

AnalyzerStatusSummaryLink
DeepSource JavaScript LogoJavaScript❌ Failure
❗ 10 occurences introduced
🎯 35 occurences resolved
View Check ↗

💡 If you’re a repository administrator, you can configure the quality gates from the settings.