gorpcontroller

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 12, 2022 License: MIT Imports: 3 Imported by: 9

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Controller

type Controller struct {
	*revel.Controller
	Txn *gorp.Transaction
	Db  *gorp.DbGorp
}

Controller definition for database transaction This controller is only useful if you intend to use the database instance defined in github.com/revel/modules/orm/gorp/app.Db.

func (*Controller) Begin

func (c *Controller) Begin() revel.Result

Begin a transaction.

func (*Controller) Commit

func (c *Controller) Commit() revel.Result

Commit the transaction.

func (*Controller) Rollback

func (c *Controller) Rollback() revel.Result

Rollback if it's still going (must have panicked).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL