login.go 413 B

123456789101112131415161718192021222324252627282930313233
  1. package models
  2. import
  3. // Login types.
  4. "github.com/go-xorm/core"
  5. /*const (
  6. LT_PLAIN = iota + 1
  7. LT_LDAP
  8. LT_SMTP
  9. )*/
  10. var _ core.Conversion = &LDAPConfig{}
  11. type LDAPConfig struct {
  12. }
  13. // implement
  14. func (cfg *LDAPConfig) FromDB(bs []byte) error {
  15. return nil
  16. }
  17. func (cfg *LDAPConfig) ToDB() ([]byte, error) {
  18. return nil, nil
  19. }
  20. type LoginSource struct {
  21. Id int64
  22. Type int
  23. Name string
  24. Cfg LDAPConfig
  25. }