2022-04-05 16:38:25 +02:00
|
|
|
/**
|
|
|
|
* This file is part of VILLASweb-backend-go
|
2019-11-20 11:08:33 +01:00
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*********************************************************************************/
|
2022-04-05 16:38:25 +02:00
|
|
|
|
2021-02-05 22:44:45 +01:00
|
|
|
package api
|
2019-09-03 12:03:47 +02:00
|
|
|
|
2021-10-19 13:28:41 +02:00
|
|
|
//lint:file-ignore U1000 Ignore all unused code, it's generated
|
|
|
|
|
2019-11-09 11:40:56 +01:00
|
|
|
import "git.rwth-aachen.de/acs/public/villas/web-backend-go/database"
|
2019-09-03 12:03:47 +02:00
|
|
|
|
|
|
|
// This file defines the responses to any endpoint in the backend
|
|
|
|
// The defined structures are only used for documentation purposes with swaggo and are NOT used in the code
|
|
|
|
|
|
|
|
type ResponseError struct {
|
|
|
|
success bool
|
|
|
|
message string
|
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseAuthenticate struct {
|
|
|
|
success bool
|
|
|
|
token string
|
|
|
|
message string
|
2019-09-10 16:28:57 +02:00
|
|
|
user database.User
|
2019-09-03 12:03:47 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseUsers struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
users []database.User
|
2019-09-03 12:03:47 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseUser struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
user database.User
|
2019-09-03 12:03:47 +02:00
|
|
|
}
|
|
|
|
|
2020-03-04 16:34:24 +01:00
|
|
|
type ResponseICs struct {
|
|
|
|
ics []database.InfrastructureComponent
|
2019-09-03 12:03:47 +02:00
|
|
|
}
|
|
|
|
|
2020-03-04 16:34:24 +01:00
|
|
|
type ResponseIC struct {
|
|
|
|
ic database.InfrastructureComponent
|
2019-09-03 12:03:47 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseScenarios struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
scenarios []database.Scenario
|
2019-09-03 12:03:47 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseScenario struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
scenario database.Scenario
|
2019-09-03 12:03:47 +02:00
|
|
|
}
|
2019-09-05 12:23:44 +02:00
|
|
|
|
2020-03-06 15:14:29 +01:00
|
|
|
type ResponseConfigs struct {
|
|
|
|
configs []database.ComponentConfiguration
|
2019-09-05 12:23:44 +02:00
|
|
|
}
|
|
|
|
|
2020-03-06 15:14:29 +01:00
|
|
|
type ResponseConfig struct {
|
|
|
|
config database.ComponentConfiguration
|
2019-09-05 12:23:44 +02:00
|
|
|
}
|
2019-09-06 14:07:36 +02:00
|
|
|
|
|
|
|
type ResponseDashboards struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
dashboards []database.Dashboard
|
2019-09-06 14:07:36 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseDashboard struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
dashboard database.Dashboard
|
2019-09-06 14:07:36 +02:00
|
|
|
}
|
2019-09-06 15:10:25 +02:00
|
|
|
|
|
|
|
type ResponseWidgets struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
widgets []database.Widget
|
2019-09-06 15:10:25 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseWidget struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
widget database.Widget
|
2019-09-06 15:10:25 +02:00
|
|
|
}
|
2019-09-06 16:01:59 +02:00
|
|
|
|
|
|
|
type ResponseSignals struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
signals []database.Signal
|
2019-09-06 16:01:59 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseSignal struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
signal database.Signal
|
2019-09-06 16:01:59 +02:00
|
|
|
}
|
2019-09-06 17:04:40 +02:00
|
|
|
|
|
|
|
type ResponseFiles struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
files []database.File
|
2019-09-06 17:04:40 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseFile struct {
|
2019-09-10 16:28:57 +02:00
|
|
|
file database.File
|
2019-09-06 17:04:40 +02:00
|
|
|
}
|
2020-11-19 17:23:24 +01:00
|
|
|
|
|
|
|
type ResponseResults struct {
|
|
|
|
results []database.Result
|
|
|
|
}
|
|
|
|
|
|
|
|
type ResponseResult struct {
|
|
|
|
result database.Result
|
|
|
|
}
|