refactor db accessor

This commit is contained in:
2024-08-26 13:10:34 -05:00
parent 3bf2b4d71f
commit e6947e714d
19 changed files with 516 additions and 302 deletions

14
core/nkode/db_accessor.go Normal file
View File

@@ -0,0 +1,14 @@
package nkode
import (
"go-nkode/core/model"
)
type DbAccessor interface {
GetCustomer(m.CustomerId) (*Customer, error)
GetUser(m.Username, m.CustomerId) (*User, error)
WriteNewCustomer(Customer) error
WriteNewUser(User) error
UpdateUserInterface(m.UserId, UserInterface) error
Renew(m.CustomerId) error
}