Add Company Feedback Statistics Endpoint and Update API Documentation

- Introduced a new endpoint to retrieve comprehensive feedback statistics for the authenticated user's company, including total likes, dislikes, and percentage calculations.
- Implemented the GetCompanyFeedbackStats method in the feedback handler to handle requests, ensuring proper authentication and error handling.
- Updated Swagger JSON, YAML, and Go documentation to accurately reflect the new endpoint, including detailed descriptions, parameters, and response formats for the CompanyFeedbackStatsResponse.
- Enhanced the feedback repository and service layers to support the new statistics functionality, improving the overall data handling capabilities of the tender management system.
- These changes enhance the usability and functionality of the API, providing valuable insights into company feedback statistics.
This commit is contained in:
n.nakhostin
2025-08-25 13:39:35 +03:30
parent 488d43380b
commit 0e14a11daf
8 changed files with 477 additions and 76 deletions
+1
View File
@@ -152,6 +152,7 @@ func RegisterPublicRoutes(e *echo.Echo, customerHandler *customer.Handler, tende
feedbackGP.GET("", feedbackHandler.PublicListFeedback)
feedbackGP.GET("/tender/:tender_id", feedbackHandler.PublicGetFeedbackByTenderID)
feedbackGP.GET("/:id", feedbackHandler.PublicGetFeedback)
feedbackGP.GET("/stats/company", feedbackHandler.GetCompanyFeedbackStats)
}
// Public Tender Approvals Routes