deleted edit function in project-flock, and must retest closing feat after fixing product warehouse

This commit is contained in:
ragilap
2025-12-04 18:44:56 +07:00
parent 6e3a8f3551
commit b43e2b44ec
9 changed files with 208 additions and 467 deletions
@@ -165,33 +165,6 @@ func (u *ProjectflockController) CreateOne(c *fiber.Ctx) error {
})
}
func (u *ProjectflockController) UpdateOne(c *fiber.Ctx) error {
req := new(validation.Update)
param := c.Params("id")
id, err := strconv.Atoi(param)
if err != nil {
return fiber.NewError(fiber.StatusBadRequest, "Invalid Id")
}
if err := c.BodyParser(req); err != nil {
return fiber.NewError(fiber.StatusBadRequest, "Invalid request body")
}
result, err := u.ProjectflockService.UpdateOne(c, req, uint(id))
if err != nil {
return err
}
return c.Status(fiber.StatusOK).
JSON(response.Success{
Code: fiber.StatusOK,
Status: "success",
Message: "Update projectflock successfully",
Data: dto.ToProjectFlockListDTO(*result),
})
}
func (u *ProjectflockController) DeleteOne(c *fiber.Ctx) error {
param := c.Params("id")