فهرست منبع

提交生成的dao、model

jianglw 4 سال پیش
والد
کامیت
3bb468e174

+ 36 - 0
dao/account/base_account.go

@@ -0,0 +1,36 @@
+// ============================================================================
+// This is auto-generated by gf cli tool only once. Fill this file as you wish.
+// ============================================================================
+
+package account
+
+import (
+	"lims_adapter/dao/account/internal"
+)
+
+// baseAccountDao is the manager for logic model data accessing
+// and custom defined data operations functions management. You can define
+// methods on it to extend its functionality as you wish.
+type baseAccountDao struct {
+	internal.BaseAccountDao
+}
+
+var (
+	// BaseAccount is globally public accessible object for table base_account operations.
+	BaseAccount = baseAccountDao{
+		internal.BaseAccount,
+	}
+)
+
+type BaseAccountDao struct {
+	internal.BaseAccountDao
+}
+
+func NewBaseAccountDao(tenant string) *BaseAccountDao {
+	dao := internal.NewBaseAccountDao(tenant)
+	return &BaseAccountDao{
+		dao,
+	}
+}
+
+// Fill with you ideas below.

+ 416 - 0
dao/account/internal/base_account.go

@@ -0,0 +1,416 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"context"
+	"database/sql"
+	"github.com/gogf/gf/database/gdb"
+	"github.com/gogf/gf/frame/g"
+	"github.com/gogf/gf/frame/gmvc"
+	model2 "lims_adapter/model/account"
+	"time"
+)
+
+// BaseAccountDao is the manager for logic model data accessing
+// and custom defined data operations functions management.
+type BaseAccountDao struct {
+	gmvc.M
+	DB      gdb.DB
+	Table   string
+	Columns baseAccountColumns
+}
+
+// BaseAccountColumns defines and stores column names for table base_account.
+type baseAccountColumns struct {
+	Id          string // 主键
+	Account     string // 账户
+	AccountName string // 账户名称
+	Surplus     string // 账户余额
+	Available   string // 可用余额
+	Limit       string // 使用限额
+	Advance     string // 优先级
+	DeletedAt   string
+}
+
+var (
+	// BaseAccount is globally public accessible object for table base_account operations.
+	BaseAccount = BaseAccountDao{
+		M:     g.DB("default").Model("base_account").Safe(),
+		DB:    g.DB("default"),
+		Table: "base_account",
+		Columns: baseAccountColumns{
+			Id:          "Id",
+			Account:     "Account",
+			AccountName: "AccountName",
+			Surplus:     "Surplus",
+			Available:   "Available",
+			Limit:       "Limit",
+			Advance:     "Advance",
+			DeletedAt:   "deletedAt",
+		},
+	}
+)
+
+func NewBaseAccountDao(tenant string) BaseAccountDao {
+	var dao BaseAccountDao
+	dao = BaseAccountDao{
+		M:     g.DB(tenant).Model("base_account").Safe(),
+		DB:    g.DB(tenant),
+		Table: "base_account",
+		Columns: baseAccountColumns{
+			Id:          "Id",
+			Account:     "Account",
+			AccountName: "AccountName",
+			Surplus:     "Surplus",
+			Available:   "Available",
+			Limit:       "Limit",
+			Advance:     "Advance",
+			DeletedAt:   "deletedAt",
+		},
+	}
+	return dao
+}
+
+// Ctx is a chaining function, which creates and returns a new DB that is a shallow copy
+// of current DB object and with given context in it.
+// Note that this returned DB object can be used only once, so do not assign it to
+// a global or package variable for long using.
+func (d *BaseAccountDao) Ctx(ctx context.Context) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Ctx(ctx)}
+}
+
+// As sets an alias name for current table.
+func (d *BaseAccountDao) As(as string) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.As(as)}
+}
+
+// TX sets the transaction for current operation.
+func (d *BaseAccountDao) TX(tx *gdb.TX) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.TX(tx)}
+}
+
+// Master marks the following operation on master node.
+func (d *BaseAccountDao) Master() *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Master()}
+}
+
+// Slave marks the following operation on slave node.
+// Note that it makes sense only if there's any slave node configured.
+func (d *BaseAccountDao) Slave() *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Slave()}
+}
+
+// Args sets custom arguments for model operation.
+func (d *BaseAccountDao) Args(args ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Args(args...)}
+}
+
+// LeftJoin does "LEFT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").LeftJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").LeftJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseAccountDao) LeftJoin(table ...string) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.LeftJoin(table...)}
+}
+
+// RightJoin does "RIGHT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").RightJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").RightJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseAccountDao) RightJoin(table ...string) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.RightJoin(table...)}
+}
+
+// InnerJoin does "INNER JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").InnerJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").InnerJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseAccountDao) InnerJoin(table ...string) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.InnerJoin(table...)}
+}
+
+// Fields sets the operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *BaseAccountDao) Fields(fieldNamesOrMapStruct ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Fields(fieldNamesOrMapStruct...)}
+}
+
+// FieldsEx sets the excluded operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *BaseAccountDao) FieldsEx(fieldNamesOrMapStruct ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.FieldsEx(fieldNamesOrMapStruct...)}
+}
+
+// Option sets the extra operation option for the model.
+func (d *BaseAccountDao) Option(option int) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Option(option)}
+}
+
+// OmitEmpty sets OPTION_OMITEMPTY option for the model, which automatically filers
+// the data and where attributes for empty values.
+func (d *BaseAccountDao) OmitEmpty() *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.OmitEmpty()}
+}
+
+// Filter marks filtering the fields which does not exist in the fields of the operated table.
+func (d *BaseAccountDao) Filter() *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Filter()}
+}
+
+// Where sets the condition statement for the model. The parameter <where> can be type of
+// string/map/gmap/slice/struct/*struct, etc. Note that, if it's called more than one times,
+// multiple conditions will be joined into where statement using "AND".
+// Eg:
+// Where("uid=10000")
+// Where("uid", 10000)
+// Where("money>? AND name like ?", 99999, "vip_%")
+// Where("uid", 1).Where("name", "john")
+// Where("status IN (?)", g.Slice{1,2,3})
+// Where("age IN(?,?)", 18, 50)
+// Where(User{ Id : 1, UserName : "john"})
+func (d *BaseAccountDao) Where(where interface{}, args ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Where(where, args...)}
+}
+
+// WherePri does the same logic as M.Where except that if the parameter <where>
+// is a single condition like int/string/float/slice, it treats the condition as the primary
+// key value. That is, if primary key is "id" and given <where> parameter as "123", the
+// WherePri function treats the condition as "id=123", but M.Where treats the condition
+// as string "123".
+func (d *BaseAccountDao) WherePri(where interface{}, args ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.WherePri(where, args...)}
+}
+
+// And adds "AND" condition to the where statement.
+func (d *BaseAccountDao) And(where interface{}, args ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.And(where, args...)}
+}
+
+// Or adds "OR" condition to the where statement.
+func (d *BaseAccountDao) Or(where interface{}, args ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Or(where, args...)}
+}
+
+// Group sets the "GROUP BY" statement for the model.
+func (d *BaseAccountDao) Group(groupBy string) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Group(groupBy)}
+}
+
+// Order sets the "ORDER BY" statement for the model.
+func (d *BaseAccountDao) Order(orderBy ...string) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Order(orderBy...)}
+}
+
+// Limit sets the "LIMIT" statement for the model.
+// The parameter <limit> can be either one or two number, if passed two number is passed,
+// it then sets "LIMIT limit[0],limit[1]" statement for the model, or else it sets "LIMIT limit[0]"
+// statement.
+func (d *BaseAccountDao) Limit(limit ...int) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Limit(limit...)}
+}
+
+// Offset sets the "OFFSET" statement for the model.
+// It only makes sense for some databases like SQLServer, PostgreSQL, etc.
+func (d *BaseAccountDao) Offset(offset int) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Offset(offset)}
+}
+
+// Page sets the paging number for the model.
+// The parameter <page> is started from 1 for paging.
+// Note that, it differs that the Limit function start from 0 for "LIMIT" statement.
+func (d *BaseAccountDao) Page(page, limit int) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Page(page, limit)}
+}
+
+// Batch sets the batch operation number for the model.
+func (d *BaseAccountDao) Batch(batch int) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Batch(batch)}
+}
+
+// Cache sets the cache feature for the model. It caches the result of the sql, which means
+// if there's another same sql request, it just reads and returns the result from cache, it
+// but not committed and executed into the database.
+//
+// If the parameter <duration> < 0, which means it clear the cache with given <name>.
+// If the parameter <duration> = 0, which means it never expires.
+// If the parameter <duration> > 0, which means it expires after <duration>.
+//
+// The optional parameter <name> is used to bind a name to the cache, which means you can later
+// control the cache like changing the <duration> or clearing the cache with specified <name>.
+//
+// Note that, the cache feature is disabled if the model is operating on a transaction.
+func (d *BaseAccountDao) Cache(duration time.Duration, name ...string) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Cache(duration, name...)}
+}
+
+// Data sets the operation data for the model.
+// The parameter <data> can be type of string/map/gmap/slice/struct/*struct, etc.
+// Eg:
+// Data("uid=10000")
+// Data("uid", 10000)
+// Data(g.Map{"uid": 10000, "name":"john"})
+// Data(g.Slice{g.Map{"uid": 10000, "name":"john"}, g.Map{"uid": 20000, "name":"smith"})
+func (d *BaseAccountDao) Data(data ...interface{}) *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Data(data...)}
+}
+
+// All does "SELECT FROM ..." statement for the model.
+// It retrieves the records from table and returns the result as []*model.BaseAccount.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *BaseAccountDao) All(where ...interface{}) ([]*model2.BaseAccount, error) {
+	all, err := d.M.All(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*model2.BaseAccount
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// One retrieves one record from table and returns the result as *model.BaseAccount.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *BaseAccountDao) One(where ...interface{}) (*model2.BaseAccount, error) {
+	one, err := d.M.One(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *model2.BaseAccount
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindOne retrieves and returns a single Record by M.WherePri and M.One.
+// Also see M.WherePri and M.One.
+func (d *BaseAccountDao) FindOne(where ...interface{}) (*model2.BaseAccount, error) {
+	one, err := d.M.FindOne(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *model2.BaseAccount
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindAll retrieves and returns Result by by M.WherePri and M.All.
+// Also see M.WherePri and M.All.
+func (d *BaseAccountDao) FindAll(where ...interface{}) ([]*model2.BaseAccount, error) {
+	all, err := d.M.FindAll(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*model2.BaseAccount
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// Struct retrieves one record from table and converts it into given struct.
+// The parameter <pointer> should be type of *struct/**struct. If type **struct is given,
+// it can create the struct internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not nil.
+//
+// Eg:
+// user := new(User)
+// err  := dao.User.Where("id", 1).Struct(user)
+//
+// user := (*User)(nil)
+// err  := dao.User.Where("id", 1).Struct(&user)
+func (d *BaseAccountDao) Struct(pointer interface{}, where ...interface{}) error {
+	return d.M.Struct(pointer, where...)
+}
+
+// Structs retrieves records from table and converts them into given struct slice.
+// The parameter <pointer> should be type of *[]struct/*[]*struct. It can create and fill the struct
+// slice internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not empty.
+//
+// Eg:
+// users := ([]User)(nil)
+// err   := dao.User.Structs(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Structs(&users)
+func (d *BaseAccountDao) Structs(pointer interface{}, where ...interface{}) error {
+	return d.M.Structs(pointer, where...)
+}
+
+// Scan automatically calls Struct or Structs function according to the type of parameter <pointer>.
+// It calls function Struct if <pointer> is type of *struct/**struct.
+// It calls function Structs if <pointer> is type of *[]struct/*[]*struct.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved and given pointer is not empty or nil.
+//
+// Eg:
+// user  := new(User)
+// err   := dao.User.Where("id", 1).Scan(user)
+//
+// user  := (*User)(nil)
+// err   := dao.User.Where("id", 1).Scan(&user)
+//
+// users := ([]User)(nil)
+// err   := dao.User.Scan(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Scan(&users)
+func (d *BaseAccountDao) Scan(pointer interface{}, where ...interface{}) error {
+	return d.M.Scan(pointer, where...)
+}
+
+// Chunk iterates the table with given size and callback function.
+func (d *BaseAccountDao) Chunk(limit int, callback func(entities []*model2.BaseAccount, err error) bool) {
+	d.M.Chunk(limit, func(result gdb.Result, err error) bool {
+		var entities []*model2.BaseAccount
+		err = result.Structs(&entities)
+		if err == sql.ErrNoRows {
+			return false
+		}
+		return callback(entities, err)
+	})
+}
+
+// LockUpdate sets the lock for update for current operation.
+func (d *BaseAccountDao) LockUpdate() *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.LockUpdate()}
+}
+
+// LockShared sets the lock in share mode for current operation.
+func (d *BaseAccountDao) LockShared() *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.LockShared()}
+}
+
+// Unscoped enables/disables the soft deleting feature.
+func (d *BaseAccountDao) Unscoped() *BaseAccountDao {
+	return &BaseAccountDao{M: d.M.Unscoped()}
+}

+ 420 - 0
dao/account/internal/settle_account_detail.go

@@ -0,0 +1,420 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"context"
+	"database/sql"
+	"github.com/gogf/gf/database/gdb"
+	"github.com/gogf/gf/frame/g"
+	"github.com/gogf/gf/frame/gmvc"
+	"time"
+
+	"lims_adapter/model/account"
+)
+
+// SettleAccountDetailDao is the manager for logic model data accessing
+// and custom defined data operations functions management.
+type SettleAccountDetailDao struct {
+	gmvc.M
+	DB      gdb.DB
+	Table   string
+	Columns settleAccountDetailColumns
+}
+
+// SettleAccountDetailColumns defines and stores column names for table settle_account_detail.
+type settleAccountDetailColumns struct {
+	Id             string // 主键
+	Pid            string // 结算明细主表Id
+	UnitPrice      string // 计费单价
+	Minutes        string // 计费时长(分钟)
+	PaymentType    string // 支出类型 1正常支出 2违约支出
+	PaymentAccount string // 支出金额
+	CreateUserId   string //
+	CreateBy       string //
+	CreateOn       string //
+}
+
+var (
+	// SettleAccountDetail is globally public accessible object for table settle_account_detail operations.
+	SettleAccountDetail = SettleAccountDetailDao{
+		M:     g.DB("default").Model("settle_account_detail").Safe(),
+		DB:    g.DB("default"),
+		Table: "settle_account_detail",
+		Columns: settleAccountDetailColumns{
+			Id:             "Id",
+			Pid:            "pid",
+			UnitPrice:      "UnitPrice",
+			Minutes:        "Minutes",
+			PaymentType:    "PaymentType",
+			PaymentAccount: "PaymentAccount",
+			CreateUserId:   "CreateUserId",
+			CreateBy:       "CreateBy",
+			CreateOn:       "CreateOn",
+		},
+	}
+)
+
+func NewSettleAccountDetailDao(tenant string) SettleAccountDetailDao {
+	var dao SettleAccountDetailDao
+	dao = SettleAccountDetailDao{
+		M:     g.DB(tenant).Model("settle_account_detail").Safe(),
+		DB:    g.DB(tenant),
+		Table: "settle_account_detail",
+		Columns: settleAccountDetailColumns{
+			Id:             "Id",
+			Pid:            "pid",
+			UnitPrice:      "UnitPrice",
+			Minutes:        "Minutes",
+			PaymentType:    "PaymentType",
+			PaymentAccount: "PaymentAccount",
+			CreateUserId:   "CreateUserId",
+			CreateBy:       "CreateBy",
+			CreateOn:       "CreateOn",
+		},
+	}
+	return dao
+}
+
+// Ctx is a chaining function, which creates and returns a new DB that is a shallow copy
+// of current DB object and with given context in it.
+// Note that this returned DB object can be used only once, so do not assign it to
+// a global or package variable for long using.
+func (d *SettleAccountDetailDao) Ctx(ctx context.Context) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Ctx(ctx)}
+}
+
+// As sets an alias name for current table.
+func (d *SettleAccountDetailDao) As(as string) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.As(as)}
+}
+
+// TX sets the transaction for current operation.
+func (d *SettleAccountDetailDao) TX(tx *gdb.TX) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.TX(tx)}
+}
+
+// Master marks the following operation on master node.
+func (d *SettleAccountDetailDao) Master() *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Master()}
+}
+
+// Slave marks the following operation on slave node.
+// Note that it makes sense only if there's any slave node configured.
+func (d *SettleAccountDetailDao) Slave() *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Slave()}
+}
+
+// Args sets custom arguments for model operation.
+func (d *SettleAccountDetailDao) Args(args ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Args(args...)}
+}
+
+// LeftJoin does "LEFT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").LeftJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").LeftJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *SettleAccountDetailDao) LeftJoin(table ...string) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.LeftJoin(table...)}
+}
+
+// RightJoin does "RIGHT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").RightJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").RightJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *SettleAccountDetailDao) RightJoin(table ...string) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.RightJoin(table...)}
+}
+
+// InnerJoin does "INNER JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").InnerJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").InnerJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *SettleAccountDetailDao) InnerJoin(table ...string) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.InnerJoin(table...)}
+}
+
+// Fields sets the operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *SettleAccountDetailDao) Fields(fieldNamesOrMapStruct ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Fields(fieldNamesOrMapStruct...)}
+}
+
+// FieldsEx sets the excluded operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *SettleAccountDetailDao) FieldsEx(fieldNamesOrMapStruct ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.FieldsEx(fieldNamesOrMapStruct...)}
+}
+
+// Option sets the extra operation option for the model.
+func (d *SettleAccountDetailDao) Option(option int) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Option(option)}
+}
+
+// OmitEmpty sets OPTION_OMITEMPTY option for the model, which automatically filers
+// the data and where attributes for empty values.
+func (d *SettleAccountDetailDao) OmitEmpty() *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.OmitEmpty()}
+}
+
+// Filter marks filtering the fields which does not exist in the fields of the operated table.
+func (d *SettleAccountDetailDao) Filter() *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Filter()}
+}
+
+// Where sets the condition statement for the model. The parameter <where> can be type of
+// string/map/gmap/slice/struct/*struct, etc. Note that, if it's called more than one times,
+// multiple conditions will be joined into where statement using "AND".
+// Eg:
+// Where("uid=10000")
+// Where("uid", 10000)
+// Where("money>? AND name like ?", 99999, "vip_%")
+// Where("uid", 1).Where("name", "john")
+// Where("status IN (?)", g.Slice{1,2,3})
+// Where("age IN(?,?)", 18, 50)
+// Where(User{ Id : 1, UserName : "john"})
+func (d *SettleAccountDetailDao) Where(where interface{}, args ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Where(where, args...)}
+}
+
+// WherePri does the same logic as M.Where except that if the parameter <where>
+// is a single condition like int/string/float/slice, it treats the condition as the primary
+// key value. That is, if primary key is "id" and given <where> parameter as "123", the
+// WherePri function treats the condition as "id=123", but M.Where treats the condition
+// as string "123".
+func (d *SettleAccountDetailDao) WherePri(where interface{}, args ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.WherePri(where, args...)}
+}
+
+// And adds "AND" condition to the where statement.
+func (d *SettleAccountDetailDao) And(where interface{}, args ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.And(where, args...)}
+}
+
+// Or adds "OR" condition to the where statement.
+func (d *SettleAccountDetailDao) Or(where interface{}, args ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Or(where, args...)}
+}
+
+// Group sets the "GROUP BY" statement for the model.
+func (d *SettleAccountDetailDao) Group(groupBy string) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Group(groupBy)}
+}
+
+// Order sets the "ORDER BY" statement for the model.
+func (d *SettleAccountDetailDao) Order(orderBy ...string) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Order(orderBy...)}
+}
+
+// Limit sets the "LIMIT" statement for the model.
+// The parameter <limit> can be either one or two number, if passed two number is passed,
+// it then sets "LIMIT limit[0],limit[1]" statement for the model, or else it sets "LIMIT limit[0]"
+// statement.
+func (d *SettleAccountDetailDao) Limit(limit ...int) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Limit(limit...)}
+}
+
+// Offset sets the "OFFSET" statement for the model.
+// It only makes sense for some databases like SQLServer, PostgreSQL, etc.
+func (d *SettleAccountDetailDao) Offset(offset int) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Offset(offset)}
+}
+
+// Page sets the paging number for the model.
+// The parameter <page> is started from 1 for paging.
+// Note that, it differs that the Limit function start from 0 for "LIMIT" statement.
+func (d *SettleAccountDetailDao) Page(page, limit int) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Page(page, limit)}
+}
+
+// Batch sets the batch operation number for the model.
+func (d *SettleAccountDetailDao) Batch(batch int) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Batch(batch)}
+}
+
+// Cache sets the cache feature for the model. It caches the result of the sql, which means
+// if there's another same sql request, it just reads and returns the result from cache, it
+// but not committed and executed into the database.
+//
+// If the parameter <duration> < 0, which means it clear the cache with given <name>.
+// If the parameter <duration> = 0, which means it never expires.
+// If the parameter <duration> > 0, which means it expires after <duration>.
+//
+// The optional parameter <name> is used to bind a name to the cache, which means you can later
+// control the cache like changing the <duration> or clearing the cache with specified <name>.
+//
+// Note that, the cache feature is disabled if the model is operating on a transaction.
+func (d *SettleAccountDetailDao) Cache(duration time.Duration, name ...string) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Cache(duration, name...)}
+}
+
+// Data sets the operation data for the model.
+// The parameter <data> can be type of string/map/gmap/slice/struct/*struct, etc.
+// Eg:
+// Data("uid=10000")
+// Data("uid", 10000)
+// Data(g.Map{"uid": 10000, "name":"john"})
+// Data(g.Slice{g.Map{"uid": 10000, "name":"john"}, g.Map{"uid": 20000, "name":"smith"})
+func (d *SettleAccountDetailDao) Data(data ...interface{}) *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Data(data...)}
+}
+
+// All does "SELECT FROM ..." statement for the model.
+// It retrieves the records from table and returns the result as []*model.SettleAccountDetail.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *SettleAccountDetailDao) All(where ...interface{}) ([]*model.SettleAccountDetail, error) {
+	all, err := d.M.All(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*model.SettleAccountDetail
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// One retrieves one record from table and returns the result as *model.SettleAccountDetail.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *SettleAccountDetailDao) One(where ...interface{}) (*model.SettleAccountDetail, error) {
+	one, err := d.M.One(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *model.SettleAccountDetail
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindOne retrieves and returns a single Record by M.WherePri and M.One.
+// Also see M.WherePri and M.One.
+func (d *SettleAccountDetailDao) FindOne(where ...interface{}) (*model.SettleAccountDetail, error) {
+	one, err := d.M.FindOne(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *model.SettleAccountDetail
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindAll retrieves and returns Result by by M.WherePri and M.All.
+// Also see M.WherePri and M.All.
+func (d *SettleAccountDetailDao) FindAll(where ...interface{}) ([]*model.SettleAccountDetail, error) {
+	all, err := d.M.FindAll(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*model.SettleAccountDetail
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// Struct retrieves one record from table and converts it into given struct.
+// The parameter <pointer> should be type of *struct/**struct. If type **struct is given,
+// it can create the struct internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not nil.
+//
+// Eg:
+// user := new(User)
+// err  := dao.User.Where("id", 1).Struct(user)
+//
+// user := (*User)(nil)
+// err  := dao.User.Where("id", 1).Struct(&user)
+func (d *SettleAccountDetailDao) Struct(pointer interface{}, where ...interface{}) error {
+	return d.M.Struct(pointer, where...)
+}
+
+// Structs retrieves records from table and converts them into given struct slice.
+// The parameter <pointer> should be type of *[]struct/*[]*struct. It can create and fill the struct
+// slice internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not empty.
+//
+// Eg:
+// users := ([]User)(nil)
+// err   := dao.User.Structs(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Structs(&users)
+func (d *SettleAccountDetailDao) Structs(pointer interface{}, where ...interface{}) error {
+	return d.M.Structs(pointer, where...)
+}
+
+// Scan automatically calls Struct or Structs function according to the type of parameter <pointer>.
+// It calls function Struct if <pointer> is type of *struct/**struct.
+// It calls function Structs if <pointer> is type of *[]struct/*[]*struct.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved and given pointer is not empty or nil.
+//
+// Eg:
+// user  := new(User)
+// err   := dao.User.Where("id", 1).Scan(user)
+//
+// user  := (*User)(nil)
+// err   := dao.User.Where("id", 1).Scan(&user)
+//
+// users := ([]User)(nil)
+// err   := dao.User.Scan(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Scan(&users)
+func (d *SettleAccountDetailDao) Scan(pointer interface{}, where ...interface{}) error {
+	return d.M.Scan(pointer, where...)
+}
+
+// Chunk iterates the table with given size and callback function.
+func (d *SettleAccountDetailDao) Chunk(limit int, callback func(entities []*model.SettleAccountDetail, err error) bool) {
+	d.M.Chunk(limit, func(result gdb.Result, err error) bool {
+		var entities []*model.SettleAccountDetail
+		err = result.Structs(&entities)
+		if err == sql.ErrNoRows {
+			return false
+		}
+		return callback(entities, err)
+	})
+}
+
+// LockUpdate sets the lock for update for current operation.
+func (d *SettleAccountDetailDao) LockUpdate() *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.LockUpdate()}
+}
+
+// LockShared sets the lock in share mode for current operation.
+func (d *SettleAccountDetailDao) LockShared() *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.LockShared()}
+}
+
+// Unscoped enables/disables the soft deleting feature.
+func (d *SettleAccountDetailDao) Unscoped() *SettleAccountDetailDao {
+	return &SettleAccountDetailDao{M: d.M.Unscoped()}
+}

+ 437 - 0
dao/account/internal/settle_account_main.go

@@ -0,0 +1,437 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"context"
+	"database/sql"
+	"github.com/gogf/gf/database/gdb"
+	"github.com/gogf/gf/frame/g"
+	"github.com/gogf/gf/frame/gmvc"
+	model2 "lims_adapter/model/account"
+	"time"
+)
+
+// SettleAccountMainDao is the manager for logic model data accessing
+// and custom defined data operations functions management.
+type SettleAccountMainDao struct {
+	gmvc.M
+	DB      gdb.DB
+	Table   string
+	Columns settleAccountMainColumns
+}
+
+// SettleAccountMainColumns defines and stores column names for table settle_account_main.
+type settleAccountMainColumns struct {
+	Id            string // 主键
+	BillId        string // 账单Id
+	AppointId     string // 预约Id
+	AppointUserId string // 预约人Id
+	AppointUser   string // 预约人
+	MainUserId    string // 主用户Id
+	MainUser      string // 主用户
+	FeeType       string // 费用类型 1机时计费 2样本计费
+	SettleStatus  string // 结算状态 1未确认 2已确认 3已结账
+	TotalPrice    string // 结算总价
+	SettleTime    string // 结算时间
+	CreateUserId  string //
+	CreateBy      string //
+	CreateOn      string //
+	DeletedAt     string // 删除时间
+}
+
+var (
+	// SettleAccountMain is globally public accessible object for table settle_account_main operations.
+	SettleAccountMain = SettleAccountMainDao{
+		M:     g.DB("default").Model("settle_account_main").Safe(),
+		DB:    g.DB("default"),
+		Table: "settle_account_main",
+		Columns: settleAccountMainColumns{
+			Id:            "Id",
+			BillId:        "BillId",
+			AppointId:     "AppointId",
+			AppointUserId: "AppointUserId",
+			AppointUser:   "AppointUser",
+			MainUserId:    "MainUserId",
+			MainUser:      "MainUser",
+			FeeType:       "FeeType",
+			SettleStatus:  "SettleStatus",
+			TotalPrice:    "TotalPrice",
+			SettleTime:    "SettleTime",
+			CreateUserId:  "CreateUserId",
+			CreateBy:      "CreateBy",
+			CreateOn:      "CreateOn",
+			DeletedAt:     "DeletedAt",
+		},
+	}
+)
+
+func NewSettleAccountMainDao(tenant string) SettleAccountMainDao {
+	var dao SettleAccountMainDao
+	dao = SettleAccountMainDao{
+		M:     g.DB(tenant).Model("settle_account_main").Safe(),
+		DB:    g.DB(tenant),
+		Table: "settle_account_main",
+		Columns: settleAccountMainColumns{
+			Id:            "Id",
+			BillId:        "BillId",
+			AppointId:     "AppointId",
+			AppointUserId: "AppointUserId",
+			AppointUser:   "AppointUser",
+			MainUserId:    "MainUserId",
+			MainUser:      "MainUser",
+			FeeType:       "FeeType",
+			SettleStatus:  "SettleStatus",
+			TotalPrice:    "TotalPrice",
+			SettleTime:    "SettleTime",
+			CreateUserId:  "CreateUserId",
+			CreateBy:      "CreateBy",
+			CreateOn:      "CreateOn",
+			DeletedAt:     "DeletedAt",
+		},
+	}
+	return dao
+}
+
+// Ctx is a chaining function, which creates and returns a new DB that is a shallow copy
+// of current DB object and with given context in it.
+// Note that this returned DB object can be used only once, so do not assign it to
+// a global or package variable for long using.
+func (d *SettleAccountMainDao) Ctx(ctx context.Context) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Ctx(ctx)}
+}
+
+// As sets an alias name for current table.
+func (d *SettleAccountMainDao) As(as string) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.As(as)}
+}
+
+// TX sets the transaction for current operation.
+func (d *SettleAccountMainDao) TX(tx *gdb.TX) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.TX(tx)}
+}
+
+// Master marks the following operation on master node.
+func (d *SettleAccountMainDao) Master() *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Master()}
+}
+
+// Slave marks the following operation on slave node.
+// Note that it makes sense only if there's any slave node configured.
+func (d *SettleAccountMainDao) Slave() *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Slave()}
+}
+
+// Args sets custom arguments for model operation.
+func (d *SettleAccountMainDao) Args(args ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Args(args...)}
+}
+
+// LeftJoin does "LEFT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").LeftJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").LeftJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *SettleAccountMainDao) LeftJoin(table ...string) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.LeftJoin(table...)}
+}
+
+// RightJoin does "RIGHT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").RightJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").RightJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *SettleAccountMainDao) RightJoin(table ...string) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.RightJoin(table...)}
+}
+
+// InnerJoin does "INNER JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").InnerJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").InnerJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *SettleAccountMainDao) InnerJoin(table ...string) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.InnerJoin(table...)}
+}
+
+// Fields sets the operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *SettleAccountMainDao) Fields(fieldNamesOrMapStruct ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Fields(fieldNamesOrMapStruct...)}
+}
+
+// FieldsEx sets the excluded operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *SettleAccountMainDao) FieldsEx(fieldNamesOrMapStruct ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.FieldsEx(fieldNamesOrMapStruct...)}
+}
+
+// Option sets the extra operation option for the model.
+func (d *SettleAccountMainDao) Option(option int) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Option(option)}
+}
+
+// OmitEmpty sets OPTION_OMITEMPTY option for the model, which automatically filers
+// the data and where attributes for empty values.
+func (d *SettleAccountMainDao) OmitEmpty() *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.OmitEmpty()}
+}
+
+// Filter marks filtering the fields which does not exist in the fields of the operated table.
+func (d *SettleAccountMainDao) Filter() *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Filter()}
+}
+
+// Where sets the condition statement for the model. The parameter <where> can be type of
+// string/map/gmap/slice/struct/*struct, etc. Note that, if it's called more than one times,
+// multiple conditions will be joined into where statement using "AND".
+// Eg:
+// Where("uid=10000")
+// Where("uid", 10000)
+// Where("money>? AND name like ?", 99999, "vip_%")
+// Where("uid", 1).Where("name", "john")
+// Where("status IN (?)", g.Slice{1,2,3})
+// Where("age IN(?,?)", 18, 50)
+// Where(User{ Id : 1, UserName : "john"})
+func (d *SettleAccountMainDao) Where(where interface{}, args ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Where(where, args...)}
+}
+
+// WherePri does the same logic as M.Where except that if the parameter <where>
+// is a single condition like int/string/float/slice, it treats the condition as the primary
+// key value. That is, if primary key is "id" and given <where> parameter as "123", the
+// WherePri function treats the condition as "id=123", but M.Where treats the condition
+// as string "123".
+func (d *SettleAccountMainDao) WherePri(where interface{}, args ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.WherePri(where, args...)}
+}
+
+// And adds "AND" condition to the where statement.
+func (d *SettleAccountMainDao) And(where interface{}, args ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.And(where, args...)}
+}
+
+// Or adds "OR" condition to the where statement.
+func (d *SettleAccountMainDao) Or(where interface{}, args ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Or(where, args...)}
+}
+
+// Group sets the "GROUP BY" statement for the model.
+func (d *SettleAccountMainDao) Group(groupBy string) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Group(groupBy)}
+}
+
+// Order sets the "ORDER BY" statement for the model.
+func (d *SettleAccountMainDao) Order(orderBy ...string) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Order(orderBy...)}
+}
+
+// Limit sets the "LIMIT" statement for the model.
+// The parameter <limit> can be either one or two number, if passed two number is passed,
+// it then sets "LIMIT limit[0],limit[1]" statement for the model, or else it sets "LIMIT limit[0]"
+// statement.
+func (d *SettleAccountMainDao) Limit(limit ...int) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Limit(limit...)}
+}
+
+// Offset sets the "OFFSET" statement for the model.
+// It only makes sense for some databases like SQLServer, PostgreSQL, etc.
+func (d *SettleAccountMainDao) Offset(offset int) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Offset(offset)}
+}
+
+// Page sets the paging number for the model.
+// The parameter <page> is started from 1 for paging.
+// Note that, it differs that the Limit function start from 0 for "LIMIT" statement.
+func (d *SettleAccountMainDao) Page(page, limit int) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Page(page, limit)}
+}
+
+// Batch sets the batch operation number for the model.
+func (d *SettleAccountMainDao) Batch(batch int) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Batch(batch)}
+}
+
+// Cache sets the cache feature for the model. It caches the result of the sql, which means
+// if there's another same sql request, it just reads and returns the result from cache, it
+// but not committed and executed into the database.
+//
+// If the parameter <duration> < 0, which means it clear the cache with given <name>.
+// If the parameter <duration> = 0, which means it never expires.
+// If the parameter <duration> > 0, which means it expires after <duration>.
+//
+// The optional parameter <name> is used to bind a name to the cache, which means you can later
+// control the cache like changing the <duration> or clearing the cache with specified <name>.
+//
+// Note that, the cache feature is disabled if the model is operating on a transaction.
+func (d *SettleAccountMainDao) Cache(duration time.Duration, name ...string) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Cache(duration, name...)}
+}
+
+// Data sets the operation data for the model.
+// The parameter <data> can be type of string/map/gmap/slice/struct/*struct, etc.
+// Eg:
+// Data("uid=10000")
+// Data("uid", 10000)
+// Data(g.Map{"uid": 10000, "name":"john"})
+// Data(g.Slice{g.Map{"uid": 10000, "name":"john"}, g.Map{"uid": 20000, "name":"smith"})
+func (d *SettleAccountMainDao) Data(data ...interface{}) *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Data(data...)}
+}
+
+// All does "SELECT FROM ..." statement for the model.
+// It retrieves the records from table and returns the result as []*model.SettleAccountMain.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *SettleAccountMainDao) All(where ...interface{}) ([]*model2.SettleAccountMain, error) {
+	all, err := d.M.All(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*model2.SettleAccountMain
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// One retrieves one record from table and returns the result as *model.SettleAccountMain.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *SettleAccountMainDao) One(where ...interface{}) (*model2.SettleAccountMain, error) {
+	one, err := d.M.One(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *model2.SettleAccountMain
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindOne retrieves and returns a single Record by M.WherePri and M.One.
+// Also see M.WherePri and M.One.
+func (d *SettleAccountMainDao) FindOne(where ...interface{}) (*model2.SettleAccountMain, error) {
+	one, err := d.M.FindOne(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *model2.SettleAccountMain
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindAll retrieves and returns Result by by M.WherePri and M.All.
+// Also see M.WherePri and M.All.
+func (d *SettleAccountMainDao) FindAll(where ...interface{}) ([]*model2.SettleAccountMain, error) {
+	all, err := d.M.FindAll(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*model2.SettleAccountMain
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// Struct retrieves one record from table and converts it into given struct.
+// The parameter <pointer> should be type of *struct/**struct. If type **struct is given,
+// it can create the struct internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not nil.
+//
+// Eg:
+// user := new(User)
+// err  := dao.User.Where("id", 1).Struct(user)
+//
+// user := (*User)(nil)
+// err  := dao.User.Where("id", 1).Struct(&user)
+func (d *SettleAccountMainDao) Struct(pointer interface{}, where ...interface{}) error {
+	return d.M.Struct(pointer, where...)
+}
+
+// Structs retrieves records from table and converts them into given struct slice.
+// The parameter <pointer> should be type of *[]struct/*[]*struct. It can create and fill the struct
+// slice internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not empty.
+//
+// Eg:
+// users := ([]User)(nil)
+// err   := dao.User.Structs(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Structs(&users)
+func (d *SettleAccountMainDao) Structs(pointer interface{}, where ...interface{}) error {
+	return d.M.Structs(pointer, where...)
+}
+
+// Scan automatically calls Struct or Structs function according to the type of parameter <pointer>.
+// It calls function Struct if <pointer> is type of *struct/**struct.
+// It calls function Structs if <pointer> is type of *[]struct/*[]*struct.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved and given pointer is not empty or nil.
+//
+// Eg:
+// user  := new(User)
+// err   := dao.User.Where("id", 1).Scan(user)
+//
+// user  := (*User)(nil)
+// err   := dao.User.Where("id", 1).Scan(&user)
+//
+// users := ([]User)(nil)
+// err   := dao.User.Scan(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Scan(&users)
+func (d *SettleAccountMainDao) Scan(pointer interface{}, where ...interface{}) error {
+	return d.M.Scan(pointer, where...)
+}
+
+// Chunk iterates the table with given size and callback function.
+func (d *SettleAccountMainDao) Chunk(limit int, callback func(entities []*model2.SettleAccountMain, err error) bool) {
+	d.M.Chunk(limit, func(result gdb.Result, err error) bool {
+		var entities []*model2.SettleAccountMain
+		err = result.Structs(&entities)
+		if err == sql.ErrNoRows {
+			return false
+		}
+		return callback(entities, err)
+	})
+}
+
+// LockUpdate sets the lock for update for current operation.
+func (d *SettleAccountMainDao) LockUpdate() *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.LockUpdate()}
+}
+
+// LockShared sets the lock in share mode for current operation.
+func (d *SettleAccountMainDao) LockShared() *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.LockShared()}
+}
+
+// Unscoped enables/disables the soft deleting feature.
+func (d *SettleAccountMainDao) Unscoped() *SettleAccountMainDao {
+	return &SettleAccountMainDao{M: d.M.Unscoped()}
+}

+ 36 - 0
dao/account/settle_account_bill.go

@@ -0,0 +1,36 @@
+// ============================================================================
+// This is auto-generated by gf cli tool only once. Fill this file as you wish.
+// ============================================================================
+
+package account
+
+import (
+	"lims_adapter/dao/account/internal"
+)
+
+// settleAccountBillDao is the manager for logic model data accessing
+// and custom defined data operations functions management. You can define
+// methods on it to extend its functionality as you wish.
+type settleAccountBillDao struct {
+	internal.SettleAccountBillDao
+}
+
+var (
+	// SettleAccountBill is globally public accessible object for table settle_account_bill operations.
+	SettleAccountBill = settleAccountBillDao{
+		internal.SettleAccountBill,
+	}
+)
+
+type SettleAccountBillDao struct {
+	internal.SettleAccountBillDao
+}
+
+func NewSettleAccountBillDao(tenant string) *SettleAccountBillDao {
+	dao := internal.NewSettleAccountBillDao(tenant)
+	return &SettleAccountBillDao{
+		dao,
+	}
+}
+
+// Fill with you ideas below.

+ 36 - 0
dao/account/settle_account_detail.go

@@ -0,0 +1,36 @@
+// ============================================================================
+// This is auto-generated by gf cli tool only once. Fill this file as you wish.
+// ============================================================================
+
+package account
+
+import (
+	"lims_adapter/dao/account/internal"
+)
+
+// settleAccountDetailDao is the manager for logic model data accessing
+// and custom defined data operations functions management. You can define
+// methods on it to extend its functionality as you wish.
+type settleAccountDetailDao struct {
+	internal.SettleAccountDetailDao
+}
+
+var (
+	// SettleAccountDetail is globally public accessible object for table settle_account_detail operations.
+	SettleAccountDetail = settleAccountDetailDao{
+		internal.SettleAccountDetail,
+	}
+)
+
+type SettleAccountDetailDao struct {
+	internal.SettleAccountDetailDao
+}
+
+func NewSettleAccountDetailDao(tenant string) *SettleAccountDetailDao {
+	dao := internal.NewSettleAccountDetailDao(tenant)
+	return &SettleAccountDetailDao{
+		dao,
+	}
+}
+
+// Fill with you ideas below.

+ 36 - 0
dao/system/base_program_group.go

@@ -0,0 +1,36 @@
+// ============================================================================
+// This is auto-generated by gf cli tool only once. Fill this file as you wish.
+// ============================================================================
+
+package system
+
+import (
+	"lims_adapter/dao/system/internal"
+)
+
+// baseProgramGroupDao is the manager for logic model data accessing
+// and custom defined data operations functions management. You can define
+// methods on it to extend its functionality as you wish.
+type baseProgramGroupDao struct {
+	internal.BaseProgramGroupDao
+}
+
+var (
+	// BaseProgramGroup is globally public accessible object for table base_program_group operations.
+	BaseProgramGroup = baseProgramGroupDao{
+		internal.BaseProgramGroup,
+	}
+)
+
+type BaseProgramGroupDao struct {
+	internal.BaseProgramGroupDao
+}
+
+func NewBaseProgramGroupDao(tenant string) *BaseProgramGroupDao {
+	dao := internal.NewBaseProgramGroupDao(tenant)
+	return &BaseProgramGroupDao{
+		dao,
+	}
+}
+
+// Fill with you ideas below.

+ 419 - 0
dao/system/internal/base_program_group.go

@@ -0,0 +1,419 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"context"
+	"database/sql"
+	"github.com/gogf/gf/database/gdb"
+	"github.com/gogf/gf/frame/g"
+	"github.com/gogf/gf/frame/gmvc"
+	"lims_adapter/model/system"
+	"time"
+)
+
+// BaseProgramGroupDao is the manager for logic model data accessing
+// and custom defined data operations functions management.
+type BaseProgramGroupDao struct {
+	gmvc.M
+	DB      gdb.DB
+	Table   string
+	Columns baseProgramGroupColumns
+}
+
+// BaseProgramGroupColumns defines and stores column names for table base_program_group.
+type baseProgramGroupColumns struct {
+	Id             string //
+	GroupName      string // 课题组名称
+	CreateOn       string //
+	CreateUserId   string //
+	CreateBy       string //
+	ModifiedOn     string //
+	ModifiedUserId string //
+	ModifiedBy     string //
+	DeletedAt      string //
+}
+
+var (
+	// BaseProgramGroup is globally public accessible object for table base_program_group operations.
+	BaseProgramGroup = BaseProgramGroupDao{
+		M:     g.DB("default").Model("base_program_group").Safe(),
+		DB:    g.DB("default"),
+		Table: "base_program_group",
+		Columns: baseProgramGroupColumns{
+			Id:             "Id",
+			GroupName:      "GroupName",
+			CreateOn:       "CreateOn",
+			CreateUserId:   "CreateUserId",
+			CreateBy:       "CreateBy",
+			ModifiedOn:     "ModifiedOn",
+			ModifiedUserId: "ModifiedUserId",
+			ModifiedBy:     "ModifiedBy",
+			DeletedAt:      "DeletedAt",
+		},
+	}
+)
+
+func NewBaseProgramGroupDao(tenant string) BaseProgramGroupDao {
+	var dao BaseProgramGroupDao
+	dao = BaseProgramGroupDao{
+		M:     g.DB(tenant).Model("base_program_group").Safe(),
+		DB:    g.DB(tenant),
+		Table: "base_program_group",
+		Columns: baseProgramGroupColumns{
+			Id:             "Id",
+			GroupName:      "GroupName",
+			CreateOn:       "CreateOn",
+			CreateUserId:   "CreateUserId",
+			CreateBy:       "CreateBy",
+			ModifiedOn:     "ModifiedOn",
+			ModifiedUserId: "ModifiedUserId",
+			ModifiedBy:     "ModifiedBy",
+			DeletedAt:      "DeletedAt",
+		},
+	}
+	return dao
+}
+
+// Ctx is a chaining function, which creates and returns a new DB that is a shallow copy
+// of current DB object and with given context in it.
+// Note that this returned DB object can be used only once, so do not assign it to
+// a global or package variable for long using.
+func (d *BaseProgramGroupDao) Ctx(ctx context.Context) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Ctx(ctx)}
+}
+
+// As sets an alias name for current table.
+func (d *BaseProgramGroupDao) As(as string) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.As(as)}
+}
+
+// TX sets the transaction for current operation.
+func (d *BaseProgramGroupDao) TX(tx *gdb.TX) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.TX(tx)}
+}
+
+// Master marks the following operation on master node.
+func (d *BaseProgramGroupDao) Master() *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Master()}
+}
+
+// Slave marks the following operation on slave node.
+// Note that it makes sense only if there's any slave node configured.
+func (d *BaseProgramGroupDao) Slave() *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Slave()}
+}
+
+// Args sets custom arguments for model operation.
+func (d *BaseProgramGroupDao) Args(args ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Args(args...)}
+}
+
+// LeftJoin does "LEFT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").LeftJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").LeftJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseProgramGroupDao) LeftJoin(table ...string) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.LeftJoin(table...)}
+}
+
+// RightJoin does "RIGHT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").RightJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").RightJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseProgramGroupDao) RightJoin(table ...string) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.RightJoin(table...)}
+}
+
+// InnerJoin does "INNER JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").InnerJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").InnerJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseProgramGroupDao) InnerJoin(table ...string) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.InnerJoin(table...)}
+}
+
+// Fields sets the operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *BaseProgramGroupDao) Fields(fieldNamesOrMapStruct ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Fields(fieldNamesOrMapStruct...)}
+}
+
+// FieldsEx sets the excluded operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *BaseProgramGroupDao) FieldsEx(fieldNamesOrMapStruct ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.FieldsEx(fieldNamesOrMapStruct...)}
+}
+
+// Option sets the extra operation option for the model.
+func (d *BaseProgramGroupDao) Option(option int) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Option(option)}
+}
+
+// OmitEmpty sets OPTION_OMITEMPTY option for the model, which automatically filers
+// the data and where attributes for empty values.
+func (d *BaseProgramGroupDao) OmitEmpty() *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.OmitEmpty()}
+}
+
+// Filter marks filtering the fields which does not exist in the fields of the operated table.
+func (d *BaseProgramGroupDao) Filter() *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Filter()}
+}
+
+// Where sets the condition statement for the model. The parameter <where> can be type of
+// string/map/gmap/slice/struct/*struct, etc. Note that, if it's called more than one times,
+// multiple conditions will be joined into where statement using "AND".
+// Eg:
+// Where("uid=10000")
+// Where("uid", 10000)
+// Where("money>? AND name like ?", 99999, "vip_%")
+// Where("uid", 1).Where("name", "john")
+// Where("status IN (?)", g.Slice{1,2,3})
+// Where("age IN(?,?)", 18, 50)
+// Where(User{ Id : 1, UserName : "john"})
+func (d *BaseProgramGroupDao) Where(where interface{}, args ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Where(where, args...)}
+}
+
+// WherePri does the same logic as M.Where except that if the parameter <where>
+// is a single condition like int/string/float/slice, it treats the condition as the primary
+// key value. That is, if primary key is "id" and given <where> parameter as "123", the
+// WherePri function treats the condition as "id=123", but M.Where treats the condition
+// as string "123".
+func (d *BaseProgramGroupDao) WherePri(where interface{}, args ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.WherePri(where, args...)}
+}
+
+// And adds "AND" condition to the where statement.
+func (d *BaseProgramGroupDao) And(where interface{}, args ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.And(where, args...)}
+}
+
+// Or adds "OR" condition to the where statement.
+func (d *BaseProgramGroupDao) Or(where interface{}, args ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Or(where, args...)}
+}
+
+// Group sets the "GROUP BY" statement for the model.
+func (d *BaseProgramGroupDao) Group(groupBy string) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Group(groupBy)}
+}
+
+// Order sets the "ORDER BY" statement for the model.
+func (d *BaseProgramGroupDao) Order(orderBy ...string) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Order(orderBy...)}
+}
+
+// Limit sets the "LIMIT" statement for the model.
+// The parameter <limit> can be either one or two number, if passed two number is passed,
+// it then sets "LIMIT limit[0],limit[1]" statement for the model, or else it sets "LIMIT limit[0]"
+// statement.
+func (d *BaseProgramGroupDao) Limit(limit ...int) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Limit(limit...)}
+}
+
+// Offset sets the "OFFSET" statement for the model.
+// It only makes sense for some databases like SQLServer, PostgreSQL, etc.
+func (d *BaseProgramGroupDao) Offset(offset int) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Offset(offset)}
+}
+
+// Page sets the paging number for the model.
+// The parameter <page> is started from 1 for paging.
+// Note that, it differs that the Limit function start from 0 for "LIMIT" statement.
+func (d *BaseProgramGroupDao) Page(page, limit int) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Page(page, limit)}
+}
+
+// Batch sets the batch operation number for the model.
+func (d *BaseProgramGroupDao) Batch(batch int) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Batch(batch)}
+}
+
+// Cache sets the cache feature for the model. It caches the result of the sql, which means
+// if there's another same sql request, it just reads and returns the result from cache, it
+// but not committed and executed into the database.
+//
+// If the parameter <duration> < 0, which means it clear the cache with given <name>.
+// If the parameter <duration> = 0, which means it never expires.
+// If the parameter <duration> > 0, which means it expires after <duration>.
+//
+// The optional parameter <name> is used to bind a name to the cache, which means you can later
+// control the cache like changing the <duration> or clearing the cache with specified <name>.
+//
+// Note that, the cache feature is disabled if the model is operating on a transaction.
+func (d *BaseProgramGroupDao) Cache(duration time.Duration, name ...string) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Cache(duration, name...)}
+}
+
+// Data sets the operation data for the model.
+// The parameter <data> can be type of string/map/gmap/slice/struct/*struct, etc.
+// Eg:
+// Data("uid=10000")
+// Data("uid", 10000)
+// Data(g.Map{"uid": 10000, "name":"john"})
+// Data(g.Slice{g.Map{"uid": 10000, "name":"john"}, g.Map{"uid": 20000, "name":"smith"})
+func (d *BaseProgramGroupDao) Data(data ...interface{}) *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Data(data...)}
+}
+
+// All does "SELECT FROM ..." statement for the model.
+// It retrieves the records from table and returns the result as []*model.BaseProgramGroup.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *BaseProgramGroupDao) All(where ...interface{}) ([]*system.BaseProgramGroup, error) {
+	all, err := d.M.All(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*system.BaseProgramGroup
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// One retrieves one record from table and returns the result as *model.BaseProgramGroup.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *BaseProgramGroupDao) One(where ...interface{}) (*system.BaseProgramGroup, error) {
+	one, err := d.M.One(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *system.BaseProgramGroup
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindOne retrieves and returns a single Record by M.WherePri and M.One.
+// Also see M.WherePri and M.One.
+func (d *BaseProgramGroupDao) FindOne(where ...interface{}) (*system.BaseProgramGroup, error) {
+	one, err := d.M.FindOne(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *system.BaseProgramGroup
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindAll retrieves and returns Result by by M.WherePri and M.All.
+// Also see M.WherePri and M.All.
+func (d *BaseProgramGroupDao) FindAll(where ...interface{}) ([]*system.BaseProgramGroup, error) {
+	all, err := d.M.FindAll(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*system.BaseProgramGroup
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// Struct retrieves one record from table and converts it into given struct.
+// The parameter <pointer> should be type of *struct/**struct. If type **struct is given,
+// it can create the struct internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not nil.
+//
+// Eg:
+// user := new(User)
+// err  := dao.User.Where("id", 1).Struct(user)
+//
+// user := (*User)(nil)
+// err  := dao.User.Where("id", 1).Struct(&user)
+func (d *BaseProgramGroupDao) Struct(pointer interface{}, where ...interface{}) error {
+	return d.M.Struct(pointer, where...)
+}
+
+// Structs retrieves records from table and converts them into given struct slice.
+// The parameter <pointer> should be type of *[]struct/*[]*struct. It can create and fill the struct
+// slice internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not empty.
+//
+// Eg:
+// users := ([]User)(nil)
+// err   := dao.User.Structs(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Structs(&users)
+func (d *BaseProgramGroupDao) Structs(pointer interface{}, where ...interface{}) error {
+	return d.M.Structs(pointer, where...)
+}
+
+// Scan automatically calls Struct or Structs function according to the type of parameter <pointer>.
+// It calls function Struct if <pointer> is type of *struct/**struct.
+// It calls function Structs if <pointer> is type of *[]struct/*[]*struct.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved and given pointer is not empty or nil.
+//
+// Eg:
+// user  := new(User)
+// err   := dao.User.Where("id", 1).Scan(user)
+//
+// user  := (*User)(nil)
+// err   := dao.User.Where("id", 1).Scan(&user)
+//
+// users := ([]User)(nil)
+// err   := dao.User.Scan(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Scan(&users)
+func (d *BaseProgramGroupDao) Scan(pointer interface{}, where ...interface{}) error {
+	return d.M.Scan(pointer, where...)
+}
+
+// Chunk iterates the table with given size and callback function.
+func (d *BaseProgramGroupDao) Chunk(limit int, callback func(entities []*system.BaseProgramGroup, err error) bool) {
+	d.M.Chunk(limit, func(result gdb.Result, err error) bool {
+		var entities []*system.BaseProgramGroup
+		err = result.Structs(&entities)
+		if err == sql.ErrNoRows {
+			return false
+		}
+		return callback(entities, err)
+	})
+}
+
+// LockUpdate sets the lock for update for current operation.
+func (d *BaseProgramGroupDao) LockUpdate() *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.LockUpdate()}
+}
+
+// LockShared sets the lock in share mode for current operation.
+func (d *BaseProgramGroupDao) LockShared() *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.LockShared()}
+}
+
+// Unscoped enables/disables the soft deleting feature.
+func (d *BaseProgramGroupDao) Unscoped() *BaseProgramGroupDao {
+	return &BaseProgramGroupDao{M: d.M.Unscoped()}
+}

+ 36 - 0
dao/user/base_user_relation.go

@@ -0,0 +1,36 @@
+// ============================================================================
+// This is auto-generated by gf cli tool only once. Fill this file as you wish.
+// ============================================================================
+
+package user
+
+import (
+	"lims_adapter/dao/user/internal"
+)
+
+// baseUserRelationDao is the manager for logic model data accessing
+// and custom defined data operations functions management. You can define
+// methods on it to extend its functionality as you wish.
+type baseUserRelationDao struct {
+	internal.BaseUserRelationDao
+}
+
+var (
+	// BaseUserRelation is globally public accessible object for table base_user_relation operations.
+	BaseUserRelation = baseUserRelationDao{
+		internal.BaseUserRelation,
+	}
+)
+
+type BaseUserRelationDao struct {
+	internal.BaseUserRelationDao
+}
+
+func NewBaseUserRelationDao(tenant string) *BaseUserRelationDao {
+	dao := internal.NewBaseUserRelationDao(tenant)
+	return &BaseUserRelationDao{
+		dao,
+	}
+}
+
+// Fill with you ideas below.

+ 36 - 0
dao/user/group_user_bind.go

@@ -0,0 +1,36 @@
+// ============================================================================
+// This is auto-generated by gf cli tool only once. Fill this file as you wish.
+// ============================================================================
+
+package user
+
+import (
+	internal2 "lims_adapter/dao/user/internal"
+)
+
+// groupUserBindDao is the manager for logic model data accessing
+// and custom defined data operations functions management. You can define
+// methods on it to extend its functionality as you wish.
+type groupUserBindDao struct {
+	internal2.GroupUserBindDao
+}
+
+var (
+	// GroupUserBind is globally public accessible object for table group_user_bind operations.
+	GroupUserBind = groupUserBindDao{
+		internal2.GroupUserBind,
+	}
+)
+
+type GroupUserBindDao struct {
+	internal2.GroupUserBindDao
+}
+
+func NewGroupUserBindDao(tenant string) *GroupUserBindDao {
+	dao := internal2.NewGroupUserBindDao(tenant)
+	return &GroupUserBindDao{
+		dao,
+	}
+}
+
+// Fill with you ideas below.

+ 413 - 0
dao/user/internal/base_user_relation.go

@@ -0,0 +1,413 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"context"
+	"database/sql"
+	"github.com/gogf/gf/database/gdb"
+	"github.com/gogf/gf/frame/g"
+	"github.com/gogf/gf/frame/gmvc"
+	"lims_adapter/model/user"
+	"time"
+)
+
+// BaseUserRelationDao is the manager for logic model data accessing
+// and custom defined data operations functions management.
+type BaseUserRelationDao struct {
+	gmvc.M
+	DB      gdb.DB
+	Table   string
+	Columns baseUserRelationColumns
+}
+
+// BaseUserRelationColumns defines and stores column names for table base_user_relation.
+type baseUserRelationColumns struct {
+	Id        string // 主键
+	UserId    string // 用户Id
+	UserName  string // 用户名
+	Pid       string // 主用户Id(主用户为0,初始化为-1)
+	PName     string // 主用户名
+	CreatedBy string // 创建人
+	CreatedAt string // 创建时间
+}
+
+var (
+	// BaseUserRelation is globally public accessible object for table base_user_relation operations.
+	BaseUserRelation = BaseUserRelationDao{
+		M:     g.DB("default").Model("base_user_relation").Safe(),
+		DB:    g.DB("default"),
+		Table: "base_user_relation",
+		Columns: baseUserRelationColumns{
+			Id:        "Id",
+			UserId:    "UserId",
+			UserName:  "UserName",
+			Pid:       "Pid",
+			PName:     "PName",
+			CreatedBy: "CreatedBy",
+			CreatedAt: "CreatedAt",
+		},
+	}
+)
+
+func NewBaseUserRelationDao(tenant string) BaseUserRelationDao {
+	var dao BaseUserRelationDao
+	dao = BaseUserRelationDao{
+		M:     g.DB(tenant).Model("base_user_relation").Safe(),
+		DB:    g.DB(tenant),
+		Table: "base_user_relation",
+		Columns: baseUserRelationColumns{
+			Id:        "Id",
+			UserId:    "UserId",
+			UserName:  "UserName",
+			Pid:       "Pid",
+			PName:     "PName",
+			CreatedBy: "CreatedBy",
+			CreatedAt: "CreatedAt",
+		},
+	}
+	return dao
+}
+
+// Ctx is a chaining function, which creates and returns a new DB that is a shallow copy
+// of current DB object and with given context in it.
+// Note that this returned DB object can be used only once, so do not assign it to
+// a global or package variable for long using.
+func (d *BaseUserRelationDao) Ctx(ctx context.Context) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Ctx(ctx)}
+}
+
+// As sets an alias name for current table.
+func (d *BaseUserRelationDao) As(as string) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.As(as)}
+}
+
+// TX sets the transaction for current operation.
+func (d *BaseUserRelationDao) TX(tx *gdb.TX) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.TX(tx)}
+}
+
+// Master marks the following operation on master node.
+func (d *BaseUserRelationDao) Master() *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Master()}
+}
+
+// Slave marks the following operation on slave node.
+// Note that it makes sense only if there's any slave node configured.
+func (d *BaseUserRelationDao) Slave() *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Slave()}
+}
+
+// Args sets custom arguments for model operation.
+func (d *BaseUserRelationDao) Args(args ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Args(args...)}
+}
+
+// LeftJoin does "LEFT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").LeftJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").LeftJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseUserRelationDao) LeftJoin(table ...string) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.LeftJoin(table...)}
+}
+
+// RightJoin does "RIGHT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").RightJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").RightJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseUserRelationDao) RightJoin(table ...string) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.RightJoin(table...)}
+}
+
+// InnerJoin does "INNER JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").InnerJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").InnerJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *BaseUserRelationDao) InnerJoin(table ...string) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.InnerJoin(table...)}
+}
+
+// Fields sets the operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *BaseUserRelationDao) Fields(fieldNamesOrMapStruct ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Fields(fieldNamesOrMapStruct...)}
+}
+
+// FieldsEx sets the excluded operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *BaseUserRelationDao) FieldsEx(fieldNamesOrMapStruct ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.FieldsEx(fieldNamesOrMapStruct...)}
+}
+
+// Option sets the extra operation option for the model.
+func (d *BaseUserRelationDao) Option(option int) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Option(option)}
+}
+
+// OmitEmpty sets OPTION_OMITEMPTY option for the model, which automatically filers
+// the data and where attributes for empty values.
+func (d *BaseUserRelationDao) OmitEmpty() *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.OmitEmpty()}
+}
+
+// Filter marks filtering the fields which does not exist in the fields of the operated table.
+func (d *BaseUserRelationDao) Filter() *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Filter()}
+}
+
+// Where sets the condition statement for the model. The parameter <where> can be type of
+// string/map/gmap/slice/struct/*struct, etc. Note that, if it's called more than one times,
+// multiple conditions will be joined into where statement using "AND".
+// Eg:
+// Where("uid=10000")
+// Where("uid", 10000)
+// Where("money>? AND name like ?", 99999, "vip_%")
+// Where("uid", 1).Where("name", "john")
+// Where("status IN (?)", g.Slice{1,2,3})
+// Where("age IN(?,?)", 18, 50)
+// Where(User{ Id : 1, UserName : "john"})
+func (d *BaseUserRelationDao) Where(where interface{}, args ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Where(where, args...)}
+}
+
+// WherePri does the same logic as M.Where except that if the parameter <where>
+// is a single condition like int/string/float/slice, it treats the condition as the primary
+// key value. That is, if primary key is "id" and given <where> parameter as "123", the
+// WherePri function treats the condition as "id=123", but M.Where treats the condition
+// as string "123".
+func (d *BaseUserRelationDao) WherePri(where interface{}, args ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.WherePri(where, args...)}
+}
+
+// And adds "AND" condition to the where statement.
+func (d *BaseUserRelationDao) And(where interface{}, args ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.And(where, args...)}
+}
+
+// Or adds "OR" condition to the where statement.
+func (d *BaseUserRelationDao) Or(where interface{}, args ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Or(where, args...)}
+}
+
+// Group sets the "GROUP BY" statement for the model.
+func (d *BaseUserRelationDao) Group(groupBy string) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Group(groupBy)}
+}
+
+// Order sets the "ORDER BY" statement for the model.
+func (d *BaseUserRelationDao) Order(orderBy ...string) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Order(orderBy...)}
+}
+
+// Limit sets the "LIMIT" statement for the model.
+// The parameter <limit> can be either one or two number, if passed two number is passed,
+// it then sets "LIMIT limit[0],limit[1]" statement for the model, or else it sets "LIMIT limit[0]"
+// statement.
+func (d *BaseUserRelationDao) Limit(limit ...int) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Limit(limit...)}
+}
+
+// Offset sets the "OFFSET" statement for the model.
+// It only makes sense for some databases like SQLServer, PostgreSQL, etc.
+func (d *BaseUserRelationDao) Offset(offset int) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Offset(offset)}
+}
+
+// Page sets the paging number for the model.
+// The parameter <page> is started from 1 for paging.
+// Note that, it differs that the Limit function start from 0 for "LIMIT" statement.
+func (d *BaseUserRelationDao) Page(page, limit int) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Page(page, limit)}
+}
+
+// Batch sets the batch operation number for the model.
+func (d *BaseUserRelationDao) Batch(batch int) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Batch(batch)}
+}
+
+// Cache sets the cache feature for the model. It caches the result of the sql, which means
+// if there's another same sql request, it just reads and returns the result from cache, it
+// but not committed and executed into the database.
+//
+// If the parameter <duration> < 0, which means it clear the cache with given <name>.
+// If the parameter <duration> = 0, which means it never expires.
+// If the parameter <duration> > 0, which means it expires after <duration>.
+//
+// The optional parameter <name> is used to bind a name to the cache, which means you can later
+// control the cache like changing the <duration> or clearing the cache with specified <name>.
+//
+// Note that, the cache feature is disabled if the model is operating on a transaction.
+func (d *BaseUserRelationDao) Cache(duration time.Duration, name ...string) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Cache(duration, name...)}
+}
+
+// Data sets the operation data for the model.
+// The parameter <data> can be type of string/map/gmap/slice/struct/*struct, etc.
+// Eg:
+// Data("uid=10000")
+// Data("uid", 10000)
+// Data(g.Map{"uid": 10000, "name":"john"})
+// Data(g.Slice{g.Map{"uid": 10000, "name":"john"}, g.Map{"uid": 20000, "name":"smith"})
+func (d *BaseUserRelationDao) Data(data ...interface{}) *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Data(data...)}
+}
+
+// All does "SELECT FROM ..." statement for the model.
+// It retrieves the records from table and returns the result as []*model.BaseUserRelation.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *BaseUserRelationDao) All(where ...interface{}) ([]*user.BaseUserRelation, error) {
+	all, err := d.M.All(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*user.BaseUserRelation
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// One retrieves one record from table and returns the result as *model.BaseUserRelation.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *BaseUserRelationDao) One(where ...interface{}) (*user.BaseUserRelation, error) {
+	one, err := d.M.One(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *user.BaseUserRelation
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindOne retrieves and returns a single Record by M.WherePri and M.One.
+// Also see M.WherePri and M.One.
+func (d *BaseUserRelationDao) FindOne(where ...interface{}) (*user.BaseUserRelation, error) {
+	one, err := d.M.FindOne(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *user.BaseUserRelation
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindAll retrieves and returns Result by by M.WherePri and M.All.
+// Also see M.WherePri and M.All.
+func (d *BaseUserRelationDao) FindAll(where ...interface{}) ([]*user.BaseUserRelation, error) {
+	all, err := d.M.FindAll(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*user.BaseUserRelation
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// Struct retrieves one record from table and converts it into given struct.
+// The parameter <pointer> should be type of *struct/**struct. If type **struct is given,
+// it can create the struct internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not nil.
+//
+// Eg:
+// user := new(User)
+// err  := dao.User.Where("id", 1).Struct(user)
+//
+// user := (*User)(nil)
+// err  := dao.User.Where("id", 1).Struct(&user)
+func (d *BaseUserRelationDao) Struct(pointer interface{}, where ...interface{}) error {
+	return d.M.Struct(pointer, where...)
+}
+
+// Structs retrieves records from table and converts them into given struct slice.
+// The parameter <pointer> should be type of *[]struct/*[]*struct. It can create and fill the struct
+// slice internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not empty.
+//
+// Eg:
+// users := ([]User)(nil)
+// err   := dao.User.Structs(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Structs(&users)
+func (d *BaseUserRelationDao) Structs(pointer interface{}, where ...interface{}) error {
+	return d.M.Structs(pointer, where...)
+}
+
+// Scan automatically calls Struct or Structs function according to the type of parameter <pointer>.
+// It calls function Struct if <pointer> is type of *struct/**struct.
+// It calls function Structs if <pointer> is type of *[]struct/*[]*struct.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved and given pointer is not empty or nil.
+//
+// Eg:
+// user  := new(User)
+// err   := dao.User.Where("id", 1).Scan(user)
+//
+// user  := (*User)(nil)
+// err   := dao.User.Where("id", 1).Scan(&user)
+//
+// users := ([]User)(nil)
+// err   := dao.User.Scan(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Scan(&users)
+func (d *BaseUserRelationDao) Scan(pointer interface{}, where ...interface{}) error {
+	return d.M.Scan(pointer, where...)
+}
+
+// Chunk iterates the table with given size and callback function.
+func (d *BaseUserRelationDao) Chunk(limit int, callback func(entities []*user.BaseUserRelation, err error) bool) {
+	d.M.Chunk(limit, func(result gdb.Result, err error) bool {
+		var entities []*user.BaseUserRelation
+		err = result.Structs(&entities)
+		if err == sql.ErrNoRows {
+			return false
+		}
+		return callback(entities, err)
+	})
+}
+
+// LockUpdate sets the lock for update for current operation.
+func (d *BaseUserRelationDao) LockUpdate() *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.LockUpdate()}
+}
+
+// LockShared sets the lock in share mode for current operation.
+func (d *BaseUserRelationDao) LockShared() *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.LockShared()}
+}
+
+// Unscoped enables/disables the soft deleting feature.
+func (d *BaseUserRelationDao) Unscoped() *BaseUserRelationDao {
+	return &BaseUserRelationDao{M: d.M.Unscoped()}
+}

+ 422 - 0
dao/user/internal/group_user_bind.go

@@ -0,0 +1,422 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"context"
+	"database/sql"
+	"github.com/gogf/gf/database/gdb"
+	"github.com/gogf/gf/frame/g"
+	"github.com/gogf/gf/frame/gmvc"
+	"lims_adapter/model/user"
+	"time"
+)
+
+// GroupUserBindDao is the manager for logic model data accessing
+// and custom defined data operations functions management.
+type GroupUserBindDao struct {
+	gmvc.M
+	DB      gdb.DB
+	Table   string
+	Columns groupUserBindColumns
+}
+
+// GroupUserBindColumns defines and stores column names for table group_user_bind.
+type groupUserBindColumns struct {
+	Id             string //
+	GroupId        string // 课题组ID
+	UserId         string // 用户ID
+	CreateOn       string //
+	CreateUserId   string //
+	CreateBy       string //
+	ModifiedOn     string //
+	ModifiedUserId string //
+	ModifiedBy     string //
+	DeletedAt      string //
+}
+
+var (
+	// GroupUserBind is globally public accessible object for table group_user_bind operations.
+	GroupUserBind = GroupUserBindDao{
+		M:     g.DB("default").Model("group_user_bind").Safe(),
+		DB:    g.DB("default"),
+		Table: "group_user_bind",
+		Columns: groupUserBindColumns{
+			Id:             "Id",
+			GroupId:        "GroupId",
+			UserId:         "UserId",
+			CreateOn:       "CreateOn",
+			CreateUserId:   "CreateUserId",
+			CreateBy:       "CreateBy",
+			ModifiedOn:     "ModifiedOn",
+			ModifiedUserId: "ModifiedUserId",
+			ModifiedBy:     "ModifiedBy",
+			DeletedAt:      "DeletedAt",
+		},
+	}
+)
+
+func NewGroupUserBindDao(tenant string) GroupUserBindDao {
+	var dao GroupUserBindDao
+	dao = GroupUserBindDao{
+		M:     g.DB(tenant).Model("group_user_bind").Safe(),
+		DB:    g.DB(tenant),
+		Table: "group_user_bind",
+		Columns: groupUserBindColumns{
+			Id:             "Id",
+			GroupId:        "GroupId",
+			UserId:         "UserId",
+			CreateOn:       "CreateOn",
+			CreateUserId:   "CreateUserId",
+			CreateBy:       "CreateBy",
+			ModifiedOn:     "ModifiedOn",
+			ModifiedUserId: "ModifiedUserId",
+			ModifiedBy:     "ModifiedBy",
+			DeletedAt:      "DeletedAt",
+		},
+	}
+	return dao
+}
+
+// Ctx is a chaining function, which creates and returns a new DB that is a shallow copy
+// of current DB object and with given context in it.
+// Note that this returned DB object can be used only once, so do not assign it to
+// a global or package variable for long using.
+func (d *GroupUserBindDao) Ctx(ctx context.Context) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Ctx(ctx)}
+}
+
+// As sets an alias name for current table.
+func (d *GroupUserBindDao) As(as string) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.As(as)}
+}
+
+// TX sets the transaction for current operation.
+func (d *GroupUserBindDao) TX(tx *gdb.TX) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.TX(tx)}
+}
+
+// Master marks the following operation on master node.
+func (d *GroupUserBindDao) Master() *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Master()}
+}
+
+// Slave marks the following operation on slave node.
+// Note that it makes sense only if there's any slave node configured.
+func (d *GroupUserBindDao) Slave() *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Slave()}
+}
+
+// Args sets custom arguments for model operation.
+func (d *GroupUserBindDao) Args(args ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Args(args...)}
+}
+
+// LeftJoin does "LEFT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").LeftJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").LeftJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *GroupUserBindDao) LeftJoin(table ...string) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.LeftJoin(table...)}
+}
+
+// RightJoin does "RIGHT JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").RightJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").RightJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *GroupUserBindDao) RightJoin(table ...string) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.RightJoin(table...)}
+}
+
+// InnerJoin does "INNER JOIN ... ON ..." statement on the model.
+// The parameter <table> can be joined table and its joined condition,
+// and also with its alias name, like:
+// Table("user").InnerJoin("user_detail", "user_detail.uid=user.uid")
+// Table("user", "u").InnerJoin("user_detail", "ud", "ud.uid=u.uid")
+func (d *GroupUserBindDao) InnerJoin(table ...string) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.InnerJoin(table...)}
+}
+
+// Fields sets the operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *GroupUserBindDao) Fields(fieldNamesOrMapStruct ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Fields(fieldNamesOrMapStruct...)}
+}
+
+// FieldsEx sets the excluded operation fields of the model, multiple fields joined using char ','.
+// The parameter <fieldNamesOrMapStruct> can be type of string/map/*map/struct/*struct.
+func (d *GroupUserBindDao) FieldsEx(fieldNamesOrMapStruct ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.FieldsEx(fieldNamesOrMapStruct...)}
+}
+
+// Option sets the extra operation option for the model.
+func (d *GroupUserBindDao) Option(option int) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Option(option)}
+}
+
+// OmitEmpty sets OPTION_OMITEMPTY option for the model, which automatically filers
+// the data and where attributes for empty values.
+func (d *GroupUserBindDao) OmitEmpty() *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.OmitEmpty()}
+}
+
+// Filter marks filtering the fields which does not exist in the fields of the operated table.
+func (d *GroupUserBindDao) Filter() *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Filter()}
+}
+
+// Where sets the condition statement for the model. The parameter <where> can be type of
+// string/map/gmap/slice/struct/*struct, etc. Note that, if it's called more than one times,
+// multiple conditions will be joined into where statement using "AND".
+// Eg:
+// Where("uid=10000")
+// Where("uid", 10000)
+// Where("money>? AND name like ?", 99999, "vip_%")
+// Where("uid", 1).Where("name", "john")
+// Where("status IN (?)", g.Slice{1,2,3})
+// Where("age IN(?,?)", 18, 50)
+// Where(User{ Id : 1, UserName : "john"})
+func (d *GroupUserBindDao) Where(where interface{}, args ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Where(where, args...)}
+}
+
+// WherePri does the same logic as M.Where except that if the parameter <where>
+// is a single condition like int/string/float/slice, it treats the condition as the primary
+// key value. That is, if primary key is "id" and given <where> parameter as "123", the
+// WherePri function treats the condition as "id=123", but M.Where treats the condition
+// as string "123".
+func (d *GroupUserBindDao) WherePri(where interface{}, args ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.WherePri(where, args...)}
+}
+
+// And adds "AND" condition to the where statement.
+func (d *GroupUserBindDao) And(where interface{}, args ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.And(where, args...)}
+}
+
+// Or adds "OR" condition to the where statement.
+func (d *GroupUserBindDao) Or(where interface{}, args ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Or(where, args...)}
+}
+
+// Group sets the "GROUP BY" statement for the model.
+func (d *GroupUserBindDao) Group(groupBy string) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Group(groupBy)}
+}
+
+// Order sets the "ORDER BY" statement for the model.
+func (d *GroupUserBindDao) Order(orderBy ...string) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Order(orderBy...)}
+}
+
+// Limit sets the "LIMIT" statement for the model.
+// The parameter <limit> can be either one or two number, if passed two number is passed,
+// it then sets "LIMIT limit[0],limit[1]" statement for the model, or else it sets "LIMIT limit[0]"
+// statement.
+func (d *GroupUserBindDao) Limit(limit ...int) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Limit(limit...)}
+}
+
+// Offset sets the "OFFSET" statement for the model.
+// It only makes sense for some databases like SQLServer, PostgreSQL, etc.
+func (d *GroupUserBindDao) Offset(offset int) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Offset(offset)}
+}
+
+// Page sets the paging number for the model.
+// The parameter <page> is started from 1 for paging.
+// Note that, it differs that the Limit function start from 0 for "LIMIT" statement.
+func (d *GroupUserBindDao) Page(page, limit int) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Page(page, limit)}
+}
+
+// Batch sets the batch operation number for the model.
+func (d *GroupUserBindDao) Batch(batch int) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Batch(batch)}
+}
+
+// Cache sets the cache feature for the model. It caches the result of the sql, which means
+// if there's another same sql request, it just reads and returns the result from cache, it
+// but not committed and executed into the database.
+//
+// If the parameter <duration> < 0, which means it clear the cache with given <name>.
+// If the parameter <duration> = 0, which means it never expires.
+// If the parameter <duration> > 0, which means it expires after <duration>.
+//
+// The optional parameter <name> is used to bind a name to the cache, which means you can later
+// control the cache like changing the <duration> or clearing the cache with specified <name>.
+//
+// Note that, the cache feature is disabled if the model is operating on a transaction.
+func (d *GroupUserBindDao) Cache(duration time.Duration, name ...string) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Cache(duration, name...)}
+}
+
+// Data sets the operation data for the model.
+// The parameter <data> can be type of string/map/gmap/slice/struct/*struct, etc.
+// Eg:
+// Data("uid=10000")
+// Data("uid", 10000)
+// Data(g.Map{"uid": 10000, "name":"john"})
+// Data(g.Slice{g.Map{"uid": 10000, "name":"john"}, g.Map{"uid": 20000, "name":"smith"})
+func (d *GroupUserBindDao) Data(data ...interface{}) *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Data(data...)}
+}
+
+// All does "SELECT FROM ..." statement for the model.
+// It retrieves the records from table and returns the result as []*model.GroupUserBind.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *GroupUserBindDao) All(where ...interface{}) ([]*user.GroupUserBind, error) {
+	all, err := d.M.All(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*user.GroupUserBind
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// One retrieves one record from table and returns the result as *model.GroupUserBind.
+// It returns nil if there's no record retrieved with the given conditions from table.
+//
+// The optional parameter <where> is the same as the parameter of M.Where function,
+// see M.Where.
+func (d *GroupUserBindDao) One(where ...interface{}) (*user.GroupUserBind, error) {
+	one, err := d.M.One(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *user.GroupUserBind
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindOne retrieves and returns a single Record by M.WherePri and M.One.
+// Also see M.WherePri and M.One.
+func (d *GroupUserBindDao) FindOne(where ...interface{}) (*user.GroupUserBind, error) {
+	one, err := d.M.FindOne(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entity *user.GroupUserBind
+	if err = one.Struct(&entity); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entity, nil
+}
+
+// FindAll retrieves and returns Result by by M.WherePri and M.All.
+// Also see M.WherePri and M.All.
+func (d *GroupUserBindDao) FindAll(where ...interface{}) ([]*user.GroupUserBind, error) {
+	all, err := d.M.FindAll(where...)
+	if err != nil {
+		return nil, err
+	}
+	var entities []*user.GroupUserBind
+	if err = all.Structs(&entities); err != nil && err != sql.ErrNoRows {
+		return nil, err
+	}
+	return entities, nil
+}
+
+// Struct retrieves one record from table and converts it into given struct.
+// The parameter <pointer> should be type of *struct/**struct. If type **struct is given,
+// it can create the struct internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not nil.
+//
+// Eg:
+// user := new(User)
+// err  := dao.User.Where("id", 1).Struct(user)
+//
+// user := (*User)(nil)
+// err  := dao.User.Where("id", 1).Struct(&user)
+func (d *GroupUserBindDao) Struct(pointer interface{}, where ...interface{}) error {
+	return d.M.Struct(pointer, where...)
+}
+
+// Structs retrieves records from table and converts them into given struct slice.
+// The parameter <pointer> should be type of *[]struct/*[]*struct. It can create and fill the struct
+// slice internally during converting.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved with the given conditions
+// from table and <pointer> is not empty.
+//
+// Eg:
+// users := ([]User)(nil)
+// err   := dao.User.Structs(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Structs(&users)
+func (d *GroupUserBindDao) Structs(pointer interface{}, where ...interface{}) error {
+	return d.M.Structs(pointer, where...)
+}
+
+// Scan automatically calls Struct or Structs function according to the type of parameter <pointer>.
+// It calls function Struct if <pointer> is type of *struct/**struct.
+// It calls function Structs if <pointer> is type of *[]struct/*[]*struct.
+//
+// The optional parameter <where> is the same as the parameter of Model.Where function,
+// see Model.Where.
+//
+// Note that it returns sql.ErrNoRows if there's no record retrieved and given pointer is not empty or nil.
+//
+// Eg:
+// user  := new(User)
+// err   := dao.User.Where("id", 1).Scan(user)
+//
+// user  := (*User)(nil)
+// err   := dao.User.Where("id", 1).Scan(&user)
+//
+// users := ([]User)(nil)
+// err   := dao.User.Scan(&users)
+//
+// users := ([]*User)(nil)
+// err   := dao.User.Scan(&users)
+func (d *GroupUserBindDao) Scan(pointer interface{}, where ...interface{}) error {
+	return d.M.Scan(pointer, where...)
+}
+
+// Chunk iterates the table with given size and callback function.
+func (d *GroupUserBindDao) Chunk(limit int, callback func(entities []*user.GroupUserBind, err error) bool) {
+	d.M.Chunk(limit, func(result gdb.Result, err error) bool {
+		var entities []*user.GroupUserBind
+		err = result.Structs(&entities)
+		if err == sql.ErrNoRows {
+			return false
+		}
+		return callback(entities, err)
+	})
+}
+
+// LockUpdate sets the lock for update for current operation.
+func (d *GroupUserBindDao) LockUpdate() *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.LockUpdate()}
+}
+
+// LockShared sets the lock in share mode for current operation.
+func (d *GroupUserBindDao) LockShared() *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.LockShared()}
+}
+
+// Unscoped enables/disables the soft deleting feature.
+func (d *GroupUserBindDao) Unscoped() *GroupUserBindDao {
+	return &GroupUserBindDao{M: d.M.Unscoped()}
+}

+ 38 - 0
model/account/base_account.go

@@ -0,0 +1,38 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. Fill this file as you wish.
+// ==========================================================================
+
+package model
+
+import (
+	"lims_adapter/model/account/internal"
+)
+
+// BaseAccount is the golang structure for table base_account.
+type BaseAccount internal.BaseAccount
+
+// Fill with you ideas below.
+type BaseAccountResp struct {
+	Id          int    `orm:"Id,primary"             json:"id"`          // 主键
+	Account     string `orm:"Account"                json:"account"`     // 账户
+	AccountName string `orm:"AccountName"            json:"accountName"` // 账户名称
+	Surplus     int    `orm:"Surplus"                json:"surplus"`     // 账户余额
+	Available   int    `orm:"Available"              json:"available"`   // 可用余额
+	Limit       int    `orm:"Limit"                  json:"limit"`       // 使用限额
+	Advance     int    `orm:"Advance"                json:"advance"`     // 优先级
+	UserId      int    `orm:"UserId"                 json:"userId"`      // 使用人Id
+	RealName    string `orm:"RealName"               json:"realName"`
+}
+
+type AccountReq struct {
+	PageNun     int    `json:"pageNum"`
+	PageSize    int    `json:"pageSize"`
+	Account     string `json:"account"`
+	AccountName string `json:"accountName"`
+	RealName    string `json:"realName"`
+}
+
+type BaseAccountRsp struct {
+	Records []BaseAccountResp `json:"records"`
+	Total   int               `json:"total"'`
+}

+ 19 - 0
model/account/internal/base_account.go

@@ -0,0 +1,19 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import "github.com/gogf/gf/os/gtime"
+
+// BaseAccount is the golang structure for table base_account.
+type BaseAccount struct {
+	Id          int         `orm:"Id,primary"             json:"id"`          // 主键
+	Account     string      `orm:"Account"                json:"account"`     // 账户
+	AccountName string      `orm:"AccountName"            json:"accountName"` // 账户名称
+	Surplus     int         `orm:"Surplus"                json:"surplus"`     // 账户余额
+	Available   int         `orm:"Available"              json:"available"`   // 可用余额
+	Limit       int         `orm:"Limit"                  json:"limit"`       // 使用限额
+	Advance     int         `orm:"Advance"                json:"advance"`     // 优先级
+	DeletedAt   *gtime.Time `orm:"DeletedAt"              json:"deletedAt"`
+}

+ 29 - 0
model/account/internal/settle_account_bill.go

@@ -0,0 +1,29 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"github.com/gogf/gf/os/gtime"
+)
+
+// SettleAccountBill is the golang structure for table settle_account_bill.
+type SettleAccountBill struct {
+	Id                     int         `orm:"Id,primary"             json:"id"`                     // 主键
+	Code                   string      `orm:"Code"                   json:"code"`                   // 账单号
+	TotalCount             int         `orm:"TotalCount"             json:"totalCount"`             // 账单总额
+	SettleTime             *gtime.Time `orm:"SettleTime"             json:"settleTime"`             // 结算时间
+	StartDate              *gtime.Time `orm:"StartDate"              json:"startDate"`              // 账单开始时间
+	EndDate                *gtime.Time `orm:"EndDate"                json:"endDate"`                // 账单结束时间
+	Status                 string      `orm:"Status"                 json:"status"`                 // 账单状态  1待确认 2待核销 4已核销
+	ActualVerificationDate *gtime.Time `orm:"ActualVerificationDate" json:"actualVerificationDate"` // 实际核销时间
+	ActualVerificationUser int         `orm:"ActualVerificationUser" json:"actualVerificationUser"` // 实际核销人
+	VerificationUserId     int         `orm:"VerificationUserId"     json:"verificationUserId"`     // 核销人Id
+	VerificationUser       int         `orm:"VerificationUser"       json:"verificationUser"`       // 核销人
+	VerificationDate       *gtime.Time `orm:"VerificationDate"       json:"verificationDate"`       // 完成核销时间
+	CreateUserId           int         `orm:"CreateUserId"           json:"createUserId"`           //
+	CreateBy               string      `orm:"CreateBy"               json:"createBy"`               //
+	CreateOn               *gtime.Time `orm:"CreateOn"               json:"createOn"`               //
+	DeletedAt              *gtime.Time `orm:"DeletedAt"              json:"deletedAt"`              // 删除时间
+}

+ 21 - 0
model/account/internal/settle_account_detail.go

@@ -0,0 +1,21 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"github.com/gogf/gf/os/gtime"
+)
+
+// SettleAccountDetail is the golang structure for table settle_account_detail.
+type SettleAccountDetail struct {
+	Id             int         `orm:"Id,primary"     json:"id"`             // 主键
+	Pid            int         `orm:"pid"            json:"pid"`            // 结算明细主表Id
+	UnitPrice      int         `orm:"UnitPrice"      json:"unitPrice"`      // 计费单价
+	PaymentType    string      `orm:"PaymentType"    json:"paymentType"`    // 支出类型 1正常支出 2违约支出
+	PaymentAccount string      `orm:"PaymentAccount" json:"paymentAccount"` // 支出金额
+	CreateUserId   int         `orm:"CreateUserId"   json:"createUserId"`   //
+	CreateBy       string      `orm:"CreateBy"       json:"createBy"`       //
+	CreateOn       *gtime.Time `orm:"CreateOn"       json:"createOn"`       //
+}

+ 28 - 0
model/account/internal/settle_account_main.go

@@ -0,0 +1,28 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"github.com/gogf/gf/os/gtime"
+)
+
+// SettleAccountMain is the golang structure for table settle_account_main.
+type SettleAccountMain struct {
+	Id            int         `orm:"Id,primary"    json:"id"`            // 主键
+	BillId        int         `orm:"BillId"        json:"billId"`        // 账单Id
+	AppointId     int         `orm:"AppointId"     json:"appointId"`     // 预约Id
+	AppointUserId int         `orm:"AppointUserId" json:"appointUserId"` // 预约人Id
+	AppointUser   string      `orm:"AppointUser"   json:"appointUser"`   // 预约人
+	MainUserId    int         `orm:"MainUserId"    json:"mainUserId"`    // 主用户Id
+	MainUser      string      `orm:"MainUser"      json:"mainUser"`      // 主用户
+	FeeType       string      `orm:"FeeType"       json:"feeType"`       // 费用类型 1机时计费 2样本计费
+	SettleStatus  string      `orm:"SettleStatus"  json:"settleStatus"`  // 结算状态 1未确认 2已确认 3已结账
+	TotalPrice    int         `orm:"TotalPrice"    json:"totalPrice"`    // 结算总价
+	SettleTime    *gtime.Time `orm:"SettleTime"    json:"settleTime"`    // 结算时间
+	CreateUserId  int         `orm:"CreateUserId"  json:"createUserId"`  //
+	CreateBy      string      `orm:"CreateBy"      json:"createBy"`      //
+	CreateOn      *gtime.Time `orm:"CreateOn"      json:"createOn"`      //
+	DeletedAt     *gtime.Time `orm:"DeletedAt"     json:"deletedAt"`     // 删除时间
+}

+ 14 - 0
model/system/base_program_group.go

@@ -0,0 +1,14 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. Fill this file as you wish.
+// ==========================================================================
+
+package system
+
+import (
+	internal2 "lims_adapter/model/system/internal"
+)
+
+// BaseProgramGroup is the golang structure for table base_program_group.
+type BaseProgramGroup internal2.BaseProgramGroup
+
+// Fill with you ideas below.

+ 22 - 0
model/system/internal/base_program_group.go

@@ -0,0 +1,22 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"github.com/gogf/gf/os/gtime"
+)
+
+// BaseProgramGroup is the golang structure for table base_program_group.
+type BaseProgramGroup struct {
+	Id             int         `orm:"Id,primary"     json:"id"`             //
+	GroupName      string      `orm:"GroupName"      json:"groupName"`      // 课题组名称
+	CreateOn       *gtime.Time `orm:"CreateOn"       json:"createOn"`       //
+	CreateUserId   int         `orm:"CreateUserId"   json:"createUserId"`   //
+	CreateBy       string      `orm:"CreateBy"       json:"createBy"`       //
+	ModifiedOn     *gtime.Time `orm:"ModifiedOn"     json:"modifiedOn"`     //
+	ModifiedUserId int         `orm:"ModifiedUserId" json:"modifiedUserId"` //
+	ModifiedBy     string      `orm:"ModifiedBy"     json:"modifiedBy"`     //
+	DeletedAt      *gtime.Time `orm:"DeletedAt"      json:"deletedAt"`      //
+}

+ 14 - 0
model/user/base_user_relation.go

@@ -0,0 +1,14 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. Fill this file as you wish.
+// ==========================================================================
+
+package user
+
+import (
+	"lims_adapter/model/user/internal"
+)
+
+// BaseUserRelation is the golang structure for table base_user_relation.
+type BaseUserRelation internal.BaseUserRelation
+
+// Fill with you ideas below.

+ 14 - 0
model/user/group_user_bind.go

@@ -0,0 +1,14 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. Fill this file as you wish.
+// ==========================================================================
+
+package user
+
+import (
+	internal2 "lims_adapter/model/user/internal"
+)
+
+// GroupUserBind is the golang structure for table group_user_bind.
+type GroupUserBind internal2.GroupUserBind
+
+// Fill with you ideas below.

+ 20 - 0
model/user/internal/base_user_relation.go

@@ -0,0 +1,20 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"github.com/gogf/gf/os/gtime"
+)
+
+// BaseUserRelation is the golang structure for table base_user_relation.
+type BaseUserRelation struct {
+	Id        int         `orm:"Id,primary" json:"id"`        // 主键
+	UserId    int         `orm:"UserId"     json:"userId"`    // 用户Id
+	UserName  string      `orm:"UserName"   json:"userName"`  // 用户名
+	Pid       int         `orm:"Pid"        json:"pid"`       // 主用户Id(主用户为0,初始化为-1)
+	PName     string      `orm:"PName"      json:"pName"`     // 主用户名
+	CreatedBy int         `orm:"CreatedBy"  json:"createdBy"` // 创建人
+	CreatedAt *gtime.Time `orm:"CreatedAt"  json:"createdAt"` // 创建时间
+}

+ 23 - 0
model/user/internal/group_user_bind.go

@@ -0,0 +1,23 @@
+// ==========================================================================
+// This is auto-generated by gf cli tool. DO NOT EDIT THIS FILE MANUALLY.
+// ==========================================================================
+
+package internal
+
+import (
+	"github.com/gogf/gf/os/gtime"
+)
+
+// GroupUserBind is the golang structure for table group_user_bind.
+type GroupUserBind struct {
+	Id             int         `orm:"Id,primary"     json:"id"`             //
+	GroupId        int         `orm:"GroupId"        json:"groupId"`        // 课题组ID
+	UserId         int         `orm:"UserId"         json:"userId"`         // 用户ID
+	CreateOn       *gtime.Time `orm:"CreateOn"       json:"createOn"`       //
+	CreateUserId   int         `orm:"CreateUserId"   json:"createUserId"`   //
+	CreateBy       string      `orm:"CreateBy"       json:"createBy"`       //
+	ModifiedOn     *gtime.Time `orm:"ModifiedOn"     json:"modifiedOn"`     //
+	ModifiedUserId int         `orm:"ModifiedUserId" json:"modifiedUserId"` //
+	ModifiedBy     string      `orm:"ModifiedBy"     json:"modifiedBy"`     //
+	DeletedAt      *gtime.Time `orm:"DeletedAt"      json:"deletedAt"`      //
+}