chores: refactor struct and structure project
This commit is contained in:
@@ -1,11 +1,13 @@
|
||||
package staffrepository
|
||||
|
||||
import authdomain "legalgo-BE-go/internal/domain/auth"
|
||||
import (
|
||||
staffdomain "legalgo-BE-go/internal/domain/staff"
|
||||
)
|
||||
|
||||
func (ur *StaffRepository) Create(spec *authdomain.Staff) (*authdomain.Staff, error) {
|
||||
if err := ur.DB.Create(&spec).Error; err != nil {
|
||||
return nil, err
|
||||
func (ur *impl) Create(spec staffdomain.Staff) error {
|
||||
if err := ur.db.Create(&spec).Error; err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return spec, nil
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user