12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- // ==========================================================================
- // Code generated by GoFrame CLI tool. DO NOT EDIT.
- // ==========================================================================
- package internal
- import (
- "context"
- "github.com/gogf/gf/database/gdb"
- "github.com/gogf/gf/frame/g"
- )
- // YoungeeTaskLogisticsDao is the manager for logic model data accessing and custom defined data operations functions management.
- type YoungeeTaskLogisticsDao struct {
- Table string // Table is the underlying table name of the DAO.
- Group string // Group is the database configuration group name of current DAO.
- Columns YoungeeTaskLogisticsColumns // Columns is the short type for Columns, which contains all the column names of Table for convenient usage.
- }
- // YoungeeTaskLogisticsColumns defines and stores column names for table youngee_task_logistics.
- type YoungeeTaskLogisticsColumns struct {
- LogisticsId string // 货物-id
- CompanyName string // 实物商品-物流公司名称
- LogisticsNumber string // 实物商品-物流单号
- ExplorestoreStarttime string // 线下探店-探店开始时间
- ExplorestoreEndtime string // 线下探店-探店结束时间
- ExplorestorePeriod string // 线下探店-探店持续时间
- CouponCodeInformation string // 虚拟产品-券码信息
- TaskId string // 任务id
- DeliveryTime string // 发货时间
- ThingsType string // 任务类型:1 实物,2:线下探店,3:虚拟产品
- SignedTime string // 实物商品-签收时间
- AutoSignAt string // 自动签收时间
- AutoScriptBreakAt string // 脚本违约自动处理时间
- AutoSketchBreakAt string // 初稿违约自动处理时间
- Status string // 签收状态,0为未签收,1为已签收
- }
- // youngeeTaskLogisticsColumns holds the columns for table youngee_task_logistics.
- var youngeeTaskLogisticsColumns = YoungeeTaskLogisticsColumns{
- LogisticsId: "logistics_id",
- CompanyName: "company_name",
- LogisticsNumber: "logistics_number",
- ExplorestoreStarttime: "explorestore_starttime",
- ExplorestoreEndtime: "explorestore_endtime",
- ExplorestorePeriod: "explorestore_period",
- CouponCodeInformation: "coupon_code_information",
- TaskId: "task_id",
- DeliveryTime: "delivery_time",
- ThingsType: "things_type",
- SignedTime: "signed_time",
- AutoSignAt: "auto_sign_at",
- AutoScriptBreakAt: "auto_script_break_at",
- AutoSketchBreakAt: "auto_sketch_break_at",
- Status: "status",
- }
- // NewYoungeeTaskLogisticsDao creates and returns a new DAO object for table data access.
- func NewYoungeeTaskLogisticsDao() *YoungeeTaskLogisticsDao {
- return &YoungeeTaskLogisticsDao{
- Group: "default",
- Table: "youngee_task_logistics",
- Columns: youngeeTaskLogisticsColumns,
- }
- }
- // DB retrieves and returns the underlying raw database management object of current DAO.
- func (dao *YoungeeTaskLogisticsDao) DB() gdb.DB {
- return g.DB(dao.Group)
- }
- // Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.
- func (dao *YoungeeTaskLogisticsDao) Ctx(ctx context.Context) *gdb.Model {
- return dao.DB().Model(dao.Table).Safe().Ctx(ctx)
- }
- // Transaction wraps the transaction logic using function f.
- // It rollbacks the transaction and returns the error from function f if it returns non-nil error.
- // It commits the transaction and returns nil if function f returns nil.
- //
- // Note that, you should not Commit or Rollback the transaction in function f
- // as it is automatically handled by this function.
- func (dao *YoungeeTaskLogisticsDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error) {
- return dao.Ctx(ctx).Transaction(ctx, f)
- }
|