FloorVisualizer/internal/model/response.go
dindang cb7e595c27 Fix lint warnings and code cleanup
- Remove duplicate calc structs, use model.CalcXxx
- Replace log.Printf with logger in recommend handler
- Remove dead code (unused var, dummy imports)
- Clean up response helpers
- Add api/ package with route registration

Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-16 10:29:11 +08:00

31 lines
715 B
Go

package model
// ── Common API response envelope ─────────────────────────
// ApiResponse wraps all API responses.
type ApiResponse struct {
Code int `json:"code"`
Data any `json:"data,omitempty"`
}
// ApiError wraps error responses.
type ApiError struct {
Code int `json:"code"`
Error string `json:"error"`
}
// ── Simple response types ─────────────────────────────────
type OKResponse struct {
OK string `json:"ok"`
}
type JobResponse struct {
JobID string `json:"job_id"`
}
type UploadResponse struct {
URL string `json:"url"`
Filename string `json:"filename"`
}