feat: add endpoint and logic for retrieving transaction chart data, including SQL queries, models, and service integration
This commit is contained in:
@@ -52,3 +52,19 @@ type AnomalyItem struct {
|
||||
ComponentName string `json:"componentName"`
|
||||
ComponentUnit string `json:"componentUnit"`
|
||||
}
|
||||
|
||||
type TransactionChartRow struct {
|
||||
Date time.Time
|
||||
TransactionType string
|
||||
TotalQuantity int64
|
||||
}
|
||||
|
||||
type TransactionChartItem struct {
|
||||
Date string `json:"date"`
|
||||
ImportQuantity int64 `json:"importQuantity"`
|
||||
ExportQuantity int64 `json:"exportQuantity"`
|
||||
}
|
||||
|
||||
type TransactionChartData struct {
|
||||
Items []TransactionChartItem `json:"items"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user