add password reset model ; create entry in database; send email
This commit is contained in:
@@ -8,16 +8,17 @@ import (
|
||||
)
|
||||
|
||||
type transaction struct {
|
||||
tx *sql.Tx
|
||||
users *userRepo
|
||||
rides *rideRepo
|
||||
visits *visitRepo
|
||||
provider *providerRepo
|
||||
notification *notificationRepo
|
||||
profile *profileRepo
|
||||
organization *organizationRepo
|
||||
zipcodes *zipcodeRepo
|
||||
plan *planRepo
|
||||
tx *sql.Tx
|
||||
users *userRepo
|
||||
rides *rideRepo
|
||||
visits *visitRepo
|
||||
provider *providerRepo
|
||||
notification *notificationRepo
|
||||
profile *profileRepo
|
||||
organization *organizationRepo
|
||||
zipcodes *zipcodeRepo
|
||||
plan *planRepo
|
||||
passwordReset *passwordResetRepo
|
||||
}
|
||||
|
||||
func newTransaction(tx *sql.Tx) *transaction {
|
||||
@@ -34,6 +35,7 @@ func newTransaction(tx *sql.Tx) *transaction {
|
||||
t.organization = newOrganizationRepo(tx)
|
||||
t.zipcodes = newZipcodeRepo(tx)
|
||||
t.plan = newPlanRepo(tx)
|
||||
t.passwordReset = newPasswordResetRepo(tx)
|
||||
|
||||
return t
|
||||
}
|
||||
@@ -81,6 +83,10 @@ func (t transaction) Plans() contract.PlanRepo {
|
||||
return t.plan
|
||||
}
|
||||
|
||||
func (t transaction) PasswordReset() contract.PasswordResetRepo {
|
||||
return t.passwordReset
|
||||
}
|
||||
|
||||
func (t *transaction) Commit() error {
|
||||
|
||||
err := t.tx.Commit()
|
||||
|
||||
Reference in New Issue
Block a user