platform_kuaishou_account_info.go 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. // ==========================================================================
  2. // Code generated by GoFrame CLI tool. DO NOT EDIT.
  3. // ==========================================================================
  4. package internal
  5. import (
  6. "context"
  7. "github.com/gogf/gf/database/gdb"
  8. "github.com/gogf/gf/frame/g"
  9. )
  10. // PlatformKuaishouAccountInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
  11. type PlatformKuaishouAccountInfoDao struct {
  12. Table string // Table is the underlying table name of the DAO.
  13. Group string // Group is the database configuration group name of current DAO.
  14. Columns PlatformKuaishouAccountInfoColumns // Columns is the short type for Columns, which contains all the column names of Table for convenient usage.
  15. }
  16. // PlatformKuaishouAccountInfoColumns defines and stores column names for table platform_kuaishou_account_info.
  17. type PlatformKuaishouAccountInfoColumns struct {
  18. KuaishouId string //
  19. TalentId string // 达人账号id(talent_info表id值)
  20. PlatformId string // 平台id,与third_platform_info中的id相同
  21. PlatformName string // 平台名称(冗余)
  22. PlatformIconUrl string // 平台icon的url(冗余)
  23. PlatformAccountId string // 在平台上的账号
  24. PlatformNickname string // 在平台上的昵称
  25. HomePageUrl string // 主页链接
  26. FansCount string // 粉丝数
  27. CompositionCount string // 作品数量
  28. SkilledAt string // 擅长领域(info_tallent_skilled_area表中的id的数组)
  29. IsSupportLive string // 是否支持直播
  30. IsOpenCart string // 是否开通购物车
  31. IsAppearInVideo string // 是否出镜
  32. HomePageCaptureUrl string // 主页截图图片url
  33. AccountFrom string // 账号来源(仅B端批量上传的账号需要填写)
  34. SubmitDate string // 提交时间
  35. ExamineFailAdminId string // 审核失败操作管理员id(user表中的id)
  36. ExamineDate string // 审核日期
  37. ExamineFailReason string // 审核失败原因
  38. UpdatedAt string // 更新时间
  39. ExamineSucAdminId string // 审核成功操作管理员id(user表中的id)
  40. }
  41. // platformKuaishouAccountInfoColumns holds the columns for table platform_kuaishou_account_info.
  42. var platformKuaishouAccountInfoColumns = PlatformKuaishouAccountInfoColumns{
  43. KuaishouId: "kuaishou_id",
  44. TalentId: "talent_id",
  45. PlatformId: "platform_id",
  46. PlatformName: "platform_name",
  47. PlatformIconUrl: "platform_icon_url",
  48. PlatformAccountId: "platform_account_id",
  49. PlatformNickname: "platform_nickname",
  50. HomePageUrl: "home_page_url",
  51. FansCount: "fans_count",
  52. CompositionCount: "composition_count",
  53. SkilledAt: "skilled_at",
  54. IsSupportLive: "is_support_live",
  55. IsOpenCart: "is_open_cart",
  56. IsAppearInVideo: "is_appear_in_video",
  57. HomePageCaptureUrl: "home_page_capture_url",
  58. AccountFrom: "account_from",
  59. SubmitDate: "submit_date",
  60. ExamineFailAdminId: "examine_fail_admin_id",
  61. ExamineDate: "examine_date",
  62. ExamineFailReason: "examine_fail_reason",
  63. UpdatedAt: "updated_at",
  64. ExamineSucAdminId: "examine_suc_admin_id",
  65. }
  66. // NewPlatformKuaishouAccountInfoDao creates and returns a new DAO object for table data access.
  67. func NewPlatformKuaishouAccountInfoDao() *PlatformKuaishouAccountInfoDao {
  68. return &PlatformKuaishouAccountInfoDao{
  69. Group: "default",
  70. Table: "platform_kuaishou_account_info",
  71. Columns: platformKuaishouAccountInfoColumns,
  72. }
  73. }
  74. // DB retrieves and returns the underlying raw database management object of current DAO.
  75. func (dao *PlatformKuaishouAccountInfoDao) DB() gdb.DB {
  76. return g.DB(dao.Group)
  77. }
  78. // Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.
  79. func (dao *PlatformKuaishouAccountInfoDao) Ctx(ctx context.Context) *gdb.Model {
  80. return dao.DB().Model(dao.Table).Safe().Ctx(ctx)
  81. }
  82. // Transaction wraps the transaction logic using function f.
  83. // It rollbacks the transaction and returns the error from function f if it returns non-nil error.
  84. // It commits the transaction and returns nil if function f returns nil.
  85. //
  86. // Note that, you should not Commit or Rollback the transaction in function f
  87. // as it is automatically handled by this function.
  88. func (dao *PlatformKuaishouAccountInfoDao) Transaction(ctx context.Context, f func(ctx context.Context, tx *gdb.TX) error) (err error) {
  89. return dao.Ctx(ctx).Transaction(ctx, f)
  90. }