Private
Public Access
16 lines
361 B
Go
16 lines
361 B
Go
package models
|
|
|
|
import (
|
|
"database/sql"
|
|
|
|
"gorm.io/gorm"
|
|
)
|
|
|
|
type Cliente struct {
|
|
gorm.Model
|
|
Nombre string `gorm:"type:varchar(40)" json:"nombre"`
|
|
Email sql.NullString `gorm:"type:varchar(80)" json:"email"`
|
|
Facturas []Factura `gorm:"foreignKey:facturaID" json:"facturas,omitempty"`
|
|
Recibos []Recibo `gorm:"foreignKey:reciboID"`
|
|
}
|