Added completed user. Some fixes and more more more...

This commit is contained in:
KamilM1205 2026-01-02 22:56:25 +04:00
parent b96dd39795
commit ea8ab7c0ed
33 changed files with 576 additions and 212 deletions

View file

@ -36,6 +36,7 @@ func CreateImagesController(images_path string, service *services.ImagesService)
// @Success 200 {object} responses.ImageResponse
// @Failure 500 {object} responses.ErrorResponse
// @Router /images/ [post]
// @Security BasicAuth
func (r *ImagesController) PostImage(c *gin.Context) {
file, err := c.FormFile("file")
if err != nil {
@ -139,6 +140,21 @@ func (r *ImagesController) GetImage(c *gin.Context) {
c.File(filePath)
}
// @Summary Delete image by path
// @Description Delete image from server by given path
// @Tags images
// @Param filename path string true "Path to image"
// @Produce image/png
// @Produce image/jpeg
// @Success 200 {object} responses.GetAllImagesList
// @Failure 400 {object} responses.ErrorResponse
// @Failure 404 {object} responses.ErrorResponse
// @Failure 500 {object} responses.ErrorResponse
// @Router /images [get]
func (r *ImagesController) GetAllImage(c *gin.Context) {
panic("Not implemented")
}
// @Summary Delete image by path
// @Description Delete image from server by given path
// @Tags images
@ -150,6 +166,7 @@ func (r *ImagesController) GetImage(c *gin.Context) {
// @Failure 404 {object} responses.ErrorResponse
// @Failure 500 {object} responses.ErrorResponse
// @Router /images/{path} [delete]
// @Security BasicAuth
func (r *ImagesController) DeleteImage(c *gin.Context) {
panic("Not implemented")
}