2021-12-08 18:43:14 +03:00
|
|
|
package api
|
|
|
|
|
2022-02-03 10:32:03 +03:00
|
|
|
type Memo struct {
|
2022-02-04 11:51:48 +03:00
|
|
|
Id int `json:"id"`
|
|
|
|
CreatedTs int64 `json:"createdTs"`
|
|
|
|
UpdatedTs int64 `json:"updatedTs"`
|
|
|
|
RowStatus string `json:"rowStatus"`
|
2022-02-03 10:32:03 +03:00
|
|
|
|
2022-02-04 11:51:48 +03:00
|
|
|
Content string `json:"content"`
|
|
|
|
CreatorId int `json:"creatorId"`
|
2021-12-08 18:43:14 +03:00
|
|
|
}
|
|
|
|
|
2022-02-03 10:32:03 +03:00
|
|
|
type MemoCreate struct {
|
2022-02-04 11:51:48 +03:00
|
|
|
Content string `json:"content"`
|
2022-02-03 10:32:03 +03:00
|
|
|
CreatorId int
|
2021-12-08 18:43:14 +03:00
|
|
|
}
|
|
|
|
|
2022-02-03 10:32:03 +03:00
|
|
|
type MemoPatch struct {
|
|
|
|
Id int
|
2021-12-08 18:43:14 +03:00
|
|
|
|
2022-02-05 06:43:25 +03:00
|
|
|
Content *string `json:"content"`
|
|
|
|
RowStatus *string `json:"rowStatus"`
|
2021-12-09 17:02:57 +03:00
|
|
|
}
|
|
|
|
|
2022-02-03 10:32:03 +03:00
|
|
|
type MemoFind struct {
|
2022-02-05 06:43:25 +03:00
|
|
|
Id *int `json:"id"`
|
|
|
|
CreatorId *int `json:"creatorId"`
|
|
|
|
RowStatus *string `json:"rowStatus"`
|
2021-12-08 18:43:14 +03:00
|
|
|
}
|
|
|
|
|
2022-02-03 10:32:03 +03:00
|
|
|
type MemoDelete struct {
|
2022-02-04 11:51:48 +03:00
|
|
|
Id *int `json:"id"`
|
2022-02-03 10:32:03 +03:00
|
|
|
CreatorId *int
|
|
|
|
}
|
2021-12-10 08:41:17 +03:00
|
|
|
|
2022-02-03 10:32:03 +03:00
|
|
|
type MemoService interface {
|
|
|
|
CreateMemo(create *MemoCreate) (*Memo, error)
|
|
|
|
PatchMemo(patch *MemoPatch) (*Memo, error)
|
|
|
|
FindMemoList(find *MemoFind) ([]*Memo, error)
|
|
|
|
FindMemo(find *MemoFind) (*Memo, error)
|
|
|
|
DeleteMemo(delete *MemoDelete) error
|
2021-12-08 18:43:14 +03:00
|
|
|
}
|