Private
Public Access
cmbiamos algunos imports y cambiamos productos por repuestos
This commit is contained in:
1 parent
96048d7776
commit
e4542e48e6
26 files changed
+66
-74
No files matched your search
@@ -1,13 +0,0 @@
|
||||
package models_seguridad
|
||||
|
||||
type Empresa struct {
|
||||
ID string `gorm:"primaryKey;type:varchar(3)" json:"id"`
|
||||
Razon string `gorm:"uniqueIndex;not null;type:varchar(70)" json:"razon"`
|
||||
Direccion string `gorm:"type:text" json:"direccion,omitempty"`
|
||||
Telefono string `gorm:"type:varchar(20)" json:"telefono,omitempty"`
|
||||
Email string `gorm:"type:varchar(100)" json:"email,omitempty"`
|
||||
}
|
||||
|
||||
func (Empresa) TableName() string {
|
||||
return "empresa"
|
||||
}
|
||||
@@ -12,7 +12,7 @@ type Usuario struct {
|
||||
Password string `gorm:"not null" json:"-"`
|
||||
Name string `gorm:"not null" json:"name"`
|
||||
Grupos []Grupo `gorm:"many2many:user_groups;" json:"grupos,omitempty"`
|
||||
Empresas []Empresa `gorm:"many2many:user_empresa;" json:"empresas,omitempty"`
|
||||
// Empresas []Empresa `gorm:"many2many:user_empresa;" json:"empresas,omitempty"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
DeletedAt gorm.DeletedAt `gorm:"index" json:"-"`
|
||||
|
||||
Reference in new issue
Block a user