2022-09-16 18:53:45 +08:00
|
|
|
package dto
|
|
|
|
|
|
|
|
import "time"
|
|
|
|
|
|
|
|
type BackupOperate struct {
|
2022-12-13 18:54:28 +08:00
|
|
|
ID uint `json:"id"`
|
2022-09-16 18:53:45 +08:00
|
|
|
Type string `json:"type" validate:"required"`
|
|
|
|
Bucket string `json:"bucket"`
|
2022-12-22 15:03:43 +08:00
|
|
|
AccessKey string `json:"accessKey"`
|
2022-09-16 18:53:45 +08:00
|
|
|
Credential string `json:"credential"`
|
2023-06-23 23:06:13 +08:00
|
|
|
BackupPath string `json:"backupPath"`
|
2022-09-16 18:53:45 +08:00
|
|
|
Vars string `json:"vars" validate:"required"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type BackupInfo struct {
|
2023-06-23 23:06:13 +08:00
|
|
|
ID uint `json:"id"`
|
|
|
|
CreatedAt time.Time `json:"createdAt"`
|
|
|
|
Type string `json:"type"`
|
|
|
|
Bucket string `json:"bucket"`
|
|
|
|
BackupPath string `json:"backupPath"`
|
|
|
|
Vars string `json:"vars"`
|
2022-09-16 18:53:45 +08:00
|
|
|
}
|
|
|
|
|
2023-02-13 15:48:18 +08:00
|
|
|
type BackupSearchFile struct {
|
|
|
|
Type string `json:"type" validate:"required"`
|
|
|
|
}
|
|
|
|
|
2023-02-21 19:06:24 +08:00
|
|
|
type CommonBackup struct {
|
2023-08-29 10:50:15 +08:00
|
|
|
Type string `json:"type" validate:"required,oneof=app mysql mariadb redis website"`
|
2023-02-21 19:06:24 +08:00
|
|
|
Name string `json:"name"`
|
|
|
|
DetailName string `json:"detailName"`
|
|
|
|
}
|
|
|
|
type CommonRecover struct {
|
2023-07-06 14:30:25 +08:00
|
|
|
Source string `json:"source" validate:"required,oneof=OSS S3 SFTP MINIO LOCAL COS KODO OneDrive"`
|
2023-08-29 10:50:15 +08:00
|
|
|
Type string `json:"type" validate:"required,oneof=app mysql mariadb redis website"`
|
2023-02-21 19:06:24 +08:00
|
|
|
Name string `json:"name"`
|
|
|
|
DetailName string `json:"detailName"`
|
|
|
|
File string `json:"file"`
|
|
|
|
}
|
|
|
|
|
2022-11-29 17:39:10 +08:00
|
|
|
type RecordSearch struct {
|
|
|
|
PageInfo
|
|
|
|
Type string `json:"type" validate:"required"`
|
2023-10-27 17:19:04 +08:00
|
|
|
Name string `json:"name"`
|
2022-11-29 17:39:10 +08:00
|
|
|
DetailName string `json:"detailName"`
|
|
|
|
}
|
|
|
|
|
2022-10-27 23:09:39 +08:00
|
|
|
type BackupRecords struct {
|
2022-10-31 17:26:15 +08:00
|
|
|
ID uint `json:"id"`
|
|
|
|
CreatedAt time.Time `json:"createdAt"`
|
|
|
|
Source string `json:"source"`
|
|
|
|
BackupType string `json:"backupType"`
|
|
|
|
FileDir string `json:"fileDir"`
|
|
|
|
FileName string `json:"fileName"`
|
2022-10-27 23:09:39 +08:00
|
|
|
}
|
|
|
|
|
2022-10-28 11:02:47 +08:00
|
|
|
type DownloadRecord struct {
|
2023-07-06 14:30:25 +08:00
|
|
|
Source string `json:"source" validate:"required,oneof=OSS S3 SFTP MINIO LOCAL COS KODO OneDrive"`
|
2022-10-28 11:02:47 +08:00
|
|
|
FileDir string `json:"fileDir" validate:"required"`
|
|
|
|
FileName string `json:"fileName" validate:"required"`
|
|
|
|
}
|
|
|
|
|
2022-09-16 18:53:45 +08:00
|
|
|
type ForBuckets struct {
|
|
|
|
Type string `json:"type" validate:"required"`
|
2022-12-22 15:03:43 +08:00
|
|
|
AccessKey string `json:"accessKey"`
|
2022-09-16 18:53:45 +08:00
|
|
|
Credential string `json:"credential" validate:"required"`
|
|
|
|
Vars string `json:"vars" validate:"required"`
|
|
|
|
}
|