So, I'm working on this mysql model Using GO and GORM where the user can input their data
`package table
import (
//"gorm.io/driver/mysql"
"gorm.io/gorm"
)
var Department = []string{"Computer Science", "Engineering", "Medical Science"}
type Account struct {
gorm.Model
Accountname string `json:"name"` //AccountName
AccontNumber int64 ` json:"number"` //AccountNumber Text(40)
//need users to select one of the values from the Department Array
}`
I want my user to select a value from the ones provided in the Department array and store it in my table, how can I go about doing it?
gorm:"type:enum('published', 'pending', 'deleted');default:'pending'"