refactor: add structs for board

This commit is contained in:
Dinesh Salunke
2023-11-25 12:54:26 +05:30
parent 0b8d198b89
commit 44f20b34a0

View File

@@ -0,0 +1,35 @@
// Copyright 2021 The Gitea Authors. All rights reserved.
// SPDX-License-Identifier: MIT
package structs
import "time"
type ProjectBoard struct {
ID int64 `json:"id"`
Title string `json:"title"`
Default bool `json:"default"`
Color string `json:"color"`
Sorting int8 `json:"sorting"`
Project *Project `json:"project"`
Creator *User `json:"creator"`
// swagger:strfmt date-time
Created time.Time `json:"created_at"`
// swagger:strfmt date-time
Updated time.Time `json:"updated_at"`
}
// swagger:model
type NewProjectBoardPayload struct {
// required:true
Title string `json:"title"`
Default bool `json:"default"`
Color string `json:"color"`
Sorting int8 `json:"sorting`
}
// swagger:model
type UpdateProjectBoardPayload struct {
Title string `json:"title"`
Color string `json:"color"`
}