homebox/backend/internal/mapper/users_automapper.go

28 lines
613 B
Go
Raw Normal View History

2022-08-30 02:30:36 +00:00
// Code generated by "/pkgs/automapper"; DO NOT EDIT.
package mapper
import (
2022-08-30 02:40:54 +00:00
"github.com/hay-kot/content/backend/ent"
"github.com/hay-kot/content/backend/internal/types"
2022-08-30 02:30:36 +00:00
)
func UserOutFromModel(from ent.User) types.UserOut {
return types.UserOut{
ID: from.ID,
Name: from.Name,
Email: from.Email,
Password: from.Password,
IsSuperuser: from.IsSuperuser,
}
}
func UserOutToModel(from types.UserOut) ent.User {
return ent.User{
ID: from.ID,
Name: from.Name,
Email: from.Email,
Password: from.Password,
IsSuperuser: from.IsSuperuser,
}
}