检测是否绑定过wifi、绑定wifi、增加用户使用记录、获取用户使用记录、添加设备使用人、设备使用人列表
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
package validator
|
||||
|
||||
import "lone-services/pkg/validate"
|
||||
|
||||
// GroupValidator 查看列表
|
||||
type GroupValidator struct {
|
||||
HostCode string `validate:"required"`
|
||||
UserId int64 `validate:"required"`
|
||||
}
|
||||
|
||||
// GetMessage 查看列表 - 提示消息
|
||||
func (p GroupValidator) GetMessage() validate.ValidatorMessages {
|
||||
return validate.ValidatorMessages{
|
||||
"HostCode.required": "设备不能为空",
|
||||
"UserId.required": "用户不能为空",
|
||||
}
|
||||
}
|
||||
|
||||
type GroupItemsValidator struct {
|
||||
HostCode string `validate:"required"`
|
||||
}
|
||||
|
||||
// GetMessage 查看列表 - 提示消息
|
||||
func (p GroupItemsValidator) GetMessage() validate.ValidatorMessages {
|
||||
return validate.ValidatorMessages{
|
||||
"HostCode.required": "设备不能为空",
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user