command_update_role_response.go 425 字节
package role

import (
	"fmt"
	"github.com/astaxie/beego/validation"
)

type UpdateRoleResponse struct {
}

func (UpdateRoleResponse *UpdateRoleResponse) ValidateCommand() error {
	valid := validation.Validation{}
	b, err := valid.Valid(UpdateRoleResponse)
	if err != nil {
		return err
	}
	if !b {
		for _, validErr := range valid.Errors {
			return fmt.Errorf("%s  %s", validErr.Key, validErr.Message)
		}
	}
	return nil
}