mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2024-11-11 18:05:59 +08:00
25 lines
841 B
Go
25 lines
841 B
Go
|
package dto
|
||
|
|
||
|
import "time"
|
||
|
|
||
|
type MysqlDBInfo struct {
|
||
|
ID uint `json:"id"`
|
||
|
CreatedAt time.Time `json:"createdAt"`
|
||
|
Name string `json:"name"`
|
||
|
Format string `json:"format"`
|
||
|
Username string `json:"username"`
|
||
|
Password string `json:"password"`
|
||
|
Permission string `json:"permission"`
|
||
|
Description string `json:"description"`
|
||
|
}
|
||
|
|
||
|
type MysqlDBCreate struct {
|
||
|
Name string `json:"name" validate:"required"`
|
||
|
Format string `json:"format" validate:"required,oneof=utf8mb4 utf-8 gbk big5"`
|
||
|
Username string `json:"username" validate:"required"`
|
||
|
Password string `json:"password" validate:"required"`
|
||
|
Permission string `json:"permission" validate:"required,oneof=local all ip"`
|
||
|
PermissionIPs string `json:"permissionIPs"`
|
||
|
Description string `json:"description"`
|
||
|
}
|