1
0
mirror of https://github.com/astaxie/beego.git synced 2025-07-16 02:22:15 +00:00

#436 support insert multi

This commit is contained in:
slene
2014-01-06 11:07:03 +08:00
parent 6f3a759ba5
commit b766f65c26
5 changed files with 167 additions and 51 deletions

View File

@@ -21,6 +21,7 @@ type Fielder interface {
type Ormer interface {
Read(interface{}, ...string) error
Insert(interface{}) (int64, error)
InsertMulti(int, interface{}) (int64, error)
Update(interface{}, ...string) (int64, error)
Delete(interface{}) (int64, error)
LoadRelated(interface{}, string, ...interface{}) (int64, error)
@@ -109,7 +110,8 @@ type txEnder interface {
type dbBaser interface {
Read(dbQuerier, *modelInfo, reflect.Value, *time.Location, []string) error
Insert(dbQuerier, *modelInfo, reflect.Value, *time.Location) (int64, error)
InsertValue(dbQuerier, *modelInfo, []string, []interface{}) (int64, error)
InsertMulti(dbQuerier, *modelInfo, reflect.Value, int, *time.Location) (int64, error)
InsertValue(dbQuerier, *modelInfo, bool, []string, []interface{}) (int64, error)
InsertStmt(stmtQuerier, *modelInfo, reflect.Value, *time.Location) (int64, error)
Update(dbQuerier, *modelInfo, reflect.Value, *time.Location, []string) (int64, error)
Delete(dbQuerier, *modelInfo, reflect.Value, *time.Location) (int64, error)