36 lines
1.2 KiB
Go
36 lines
1.2 KiB
Go
package models
|
|
|
|
import (
|
|
"gorm.io/gorm"
|
|
)
|
|
|
|
type User struct {
|
|
gorm.Model
|
|
Name string `gorm:"size:40;not null" json:"name"`
|
|
CompanyName string `gorm:"size:40;not null" json:"companyname"`
|
|
Email string `gorm:"size:40;not null;unique" json:"email"`
|
|
Password []byte `gorm:"size:100;not null;" json:"-"`
|
|
Channel string `gorm:"size:40;not null" json:"channel"`
|
|
Url string `gorm:"size:40;not null" json:"url"`
|
|
CpfCnpj string `gorm:"size:20;not null" json:"cpfcnpj"`
|
|
UserType string `gorm:"size:1;not null;default:U" json:"usertype"`
|
|
Plan string `gorm:"size:1;not null;default:A" json:"plan"`
|
|
Blocked string `gorm:"size:1;not null;default:N" json:"blocked"`
|
|
Cancelled string `gorm:"size:1;not null;default:N" json:"cancelled"`
|
|
CreatedBy string `gorm:"size:15;not null;default:Manual" json:"createdby"`
|
|
ServerId uint `gorm:"not null" json:"serverid"`
|
|
}
|
|
|
|
// Plan:
|
|
|
|
// A - Admin
|
|
// T - Trial
|
|
// FM - Fácil Mensal
|
|
// FT - Fácil Trimestral
|
|
// FS - Fácil Semestral
|
|
// FA - Fácil Anual
|
|
// FM - Fácil Plus Mensal
|
|
// FT - Fácil Plus Trimestral
|
|
// FS - Fácil Plus Semestral
|
|
// FA - Fácil Plus Anual
|