Added password token entity.
This commit is contained in:
parent
1ac68b7d9f
commit
c9d50cb3d4
25 changed files with 3489 additions and 20 deletions
|
|
@ -5,6 +5,7 @@ package ent
|
|||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"goweb/ent/passwordtoken"
|
||||
"goweb/ent/user"
|
||||
|
||||
"entgo.io/ent"
|
||||
|
|
@ -29,7 +30,8 @@ type OrderFunc func(*sql.Selector)
|
|||
// columnChecker returns a function indicates if the column exists in the given column.
|
||||
func columnChecker(table string) func(string) error {
|
||||
checks := map[string]func(string) bool{
|
||||
user.Table: user.ValidColumn,
|
||||
passwordtoken.Table: passwordtoken.ValidColumn,
|
||||
user.Table: user.ValidColumn,
|
||||
}
|
||||
check, ok := checks[table]
|
||||
if !ok {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue