This commit is contained in:
2025-07-07 20:11:59 +08:00
parent ab0fdbc447
commit 06e3aa2eb3
2009 changed files with 193082 additions and 0 deletions

View File

@ -0,0 +1,54 @@
// ==========================================================================
// GFast自动生成controller操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/controller/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package controller
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
systemController "github.com/tiger1103/gfast/v3/internal/app/system/controller"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
)
type testContactInfoController struct {
systemController.BaseController
}
var TestContactInfo = new(testContactInfoController)
// List 列表
func (c *testContactInfoController) List(ctx context.Context, req *test.TestContactInfoSearchReq) (res *test.TestContactInfoSearchRes, err error) {
res, err = service.TestContactInfo().List(ctx, req)
return
}
// Get 获取业主方联系人关联
func (c *testContactInfoController) Get(ctx context.Context, req *test.TestContactInfoGetReq) (res *test.TestContactInfoGetRes, err error) {
res = new(test.TestContactInfoGetRes)
res.TestContactInfoInfoRes, err = service.TestContactInfo().GetById(ctx, req.Id)
return
}
// Add 添加业主方联系人关联
func (c *testContactInfoController) Add(ctx context.Context, req *test.TestContactInfoAddReq) (res *test.TestContactInfoAddRes, err error) {
err = service.TestContactInfo().Add(ctx, req)
return
}
// Edit 修改业主方联系人关联
func (c *testContactInfoController) Edit(ctx context.Context, req *test.TestContactInfoEditReq) (res *test.TestContactInfoEditRes, err error) {
err = service.TestContactInfo().Edit(ctx, req)
return
}
// Delete 删除业主方联系人关联
func (c *testContactInfoController) Delete(ctx context.Context, req *test.TestContactInfoDeleteReq) (res *test.TestContactInfoDeleteRes, err error) {
err = service.TestContactInfo().Delete(ctx, req.Ids)
return
}

View File

@ -0,0 +1,54 @@
// ==========================================================================
// GFast自动生成controller操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/controller/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package controller
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
systemController "github.com/tiger1103/gfast/v3/internal/app/system/controller"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
)
type testFollowInfoController struct {
systemController.BaseController
}
var TestFollowInfo = new(testFollowInfoController)
// List 列表
func (c *testFollowInfoController) List(ctx context.Context, req *test.TestFollowInfoSearchReq) (res *test.TestFollowInfoSearchRes, err error) {
res, err = service.TestFollowInfo().List(ctx, req)
return
}
// Get 获取跟进信息
func (c *testFollowInfoController) Get(ctx context.Context, req *test.TestFollowInfoGetReq) (res *test.TestFollowInfoGetRes, err error) {
res = new(test.TestFollowInfoGetRes)
res.TestFollowInfoInfoRes, err = service.TestFollowInfo().GetById(ctx, req.Id)
return
}
// Add 添加跟进信息
func (c *testFollowInfoController) Add(ctx context.Context, req *test.TestFollowInfoAddReq) (res *test.TestFollowInfoAddRes, err error) {
err = service.TestFollowInfo().Add(ctx, req)
return
}
// Edit 修改跟进信息
func (c *testFollowInfoController) Edit(ctx context.Context, req *test.TestFollowInfoEditReq) (res *test.TestFollowInfoEditRes, err error) {
err = service.TestFollowInfo().Edit(ctx, req)
return
}
// Delete 删除跟进信息
func (c *testFollowInfoController) Delete(ctx context.Context, req *test.TestFollowInfoDeleteReq) (res *test.TestFollowInfoDeleteRes, err error) {
err = service.TestFollowInfo().Delete(ctx, req.Ids)
return
}

View File

@ -0,0 +1,54 @@
// ==========================================================================
// GFast自动生成controller操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/controller/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package controller
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
systemController "github.com/tiger1103/gfast/v3/internal/app/system/controller"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
)
type testOwnerInfoController struct {
systemController.BaseController
}
var TestOwnerInfo = new(testOwnerInfoController)
// List 列表
func (c *testOwnerInfoController) List(ctx context.Context, req *test.TestOwnerInfoSearchReq) (res *test.TestOwnerInfoSearchRes, err error) {
res, err = service.TestOwnerInfo().List(ctx, req)
return
}
// Get 获取业主方基本情况
func (c *testOwnerInfoController) Get(ctx context.Context, req *test.TestOwnerInfoGetReq) (res *test.TestOwnerInfoGetRes, err error) {
res = new(test.TestOwnerInfoGetRes)
res.TestOwnerInfoInfoRes, err = service.TestOwnerInfo().GetById(ctx, req.Id)
return
}
// Add 添加业主方基本情况
func (c *testOwnerInfoController) Add(ctx context.Context, req *test.TestOwnerInfoAddReq) (res *test.TestOwnerInfoAddRes, err error) {
err = service.TestOwnerInfo().Add(ctx, req)
return
}
// Edit 修改业主方基本情况
func (c *testOwnerInfoController) Edit(ctx context.Context, req *test.TestOwnerInfoEditReq) (res *test.TestOwnerInfoEditRes, err error) {
err = service.TestOwnerInfo().Edit(ctx, req)
return
}
// Delete 删除业主方基本情况
func (c *testOwnerInfoController) Delete(ctx context.Context, req *test.TestOwnerInfoDeleteReq) (res *test.TestOwnerInfoDeleteRes, err error) {
err = service.TestOwnerInfo().Delete(ctx, req.Ids)
return
}

View File

@ -0,0 +1,54 @@
// ==========================================================================
// GFast自动生成controller操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/controller/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package controller
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
systemController "github.com/tiger1103/gfast/v3/internal/app/system/controller"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
)
type testProjectInfoController struct {
systemController.BaseController
}
var TestProjectInfo = new(testProjectInfoController)
// List 列表
func (c *testProjectInfoController) List(ctx context.Context, req *test.TestProjectInfoSearchReq) (res *test.TestProjectInfoSearchRes, err error) {
res, err = service.TestProjectInfo().List(ctx, req)
return
}
// Get 获取项目备案信息
func (c *testProjectInfoController) Get(ctx context.Context, req *test.TestProjectInfoGetReq) (res *test.TestProjectInfoGetRes, err error) {
res = new(test.TestProjectInfoGetRes)
res.TestProjectInfoInfoRes, err = service.TestProjectInfo().GetById(ctx, req.Id)
return
}
// Add 添加项目备案信息
func (c *testProjectInfoController) Add(ctx context.Context, req *test.TestProjectInfoAddReq) (res *test.TestProjectInfoAddRes, err error) {
err = service.TestProjectInfo().Add(ctx, req)
return
}
// Edit 修改项目备案信息
func (c *testProjectInfoController) Edit(ctx context.Context, req *test.TestProjectInfoEditReq) (res *test.TestProjectInfoEditRes, err error) {
err = service.TestProjectInfo().Edit(ctx, req)
return
}
// Delete 删除项目备案信息
func (c *testProjectInfoController) Delete(ctx context.Context, req *test.TestProjectInfoDeleteReq) (res *test.TestProjectInfoDeleteRes, err error) {
err = service.TestProjectInfo().Delete(ctx, req.Ids)
return
}

View File

@ -0,0 +1,86 @@
// ==========================================================================
// GFast自动生成dao internal操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/dao/internal/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package internal
import (
"context"
"github.com/gogf/gf/v2/database/gdb"
"github.com/gogf/gf/v2/frame/g"
)
// TestContactInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
type TestContactInfoDao 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 TestContactInfoColumns // Columns is the short type for Columns, which contains all the column names of Table for convenient usage.
}
// TestContactInfoColumns defines and stores column names for table test_contact_info.
type TestContactInfoColumns struct {
Id string //
OwenerId string //
ContactName string //
ContactPost string //
ContactPhone string //
Creator string //
}
var testContactInfoColumns = TestContactInfoColumns{
Id: "id",
OwenerId: "owener_id",
ContactName: "contact_name",
ContactPost: "contact_post",
ContactPhone: "contact_phone",
Creator: "creator",
}
// NewTestContactInfoDao creates and returns a new DAO object for table data access.
func NewTestContactInfoDao() *TestContactInfoDao {
return &TestContactInfoDao{
group: "default",
table: "test_contact_info",
columns: testContactInfoColumns,
}
}
// DB retrieves and returns the underlying raw database management object of current DAO.
func (dao *TestContactInfoDao) DB() gdb.DB {
return g.DB(dao.group)
}
// Table returns the table name of current dao.
func (dao *TestContactInfoDao) Table() string {
return dao.table
}
// Columns returns all column names of current dao.
func (dao *TestContactInfoDao) Columns() TestContactInfoColumns {
return dao.columns
}
// Group returns the configuration group name of database of current dao.
func (dao *TestContactInfoDao) Group() string {
return dao.group
}
// Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.
func (dao *TestContactInfoDao) 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 *TestContactInfoDao) Transaction(ctx context.Context, f func(ctx context.Context, tx gdb.TX) error) (err error) {
return dao.Ctx(ctx).Transaction(ctx, f)
}

View File

@ -0,0 +1,100 @@
// ==========================================================================
// GFast自动生成dao internal操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/dao/internal/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package internal
import (
"context"
"github.com/gogf/gf/v2/database/gdb"
"github.com/gogf/gf/v2/frame/g"
)
// TestFollowInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
type TestFollowInfoDao 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 TestFollowInfoColumns // Columns is the short type for Columns, which contains all the column names of Table for convenient usage.
}
// TestFollowInfoColumns defines and stores column names for table test_follow_info.
type TestFollowInfoColumns struct {
Id string //
ProjectId string // 关联的项目
FollowName string // 跟进人姓名
OwnerId string // 业主名
ContactName string // 对接人姓名
ConPostName string // 对接人职称
ContactPhone string // 对接人电话
FollowInfo string // 跟进情况
FollowFile string // 相关附件
CreatedAt string // 创建日期
UpdatedAt string // 修改日期
DeletedAt string // 删除日期
Creator string // 删除日期
}
var testFollowInfoColumns = TestFollowInfoColumns{
Id: "id",
ProjectId: "project_id",
FollowName: "follow_name",
OwnerId: "owner_id",
ContactName: "contact_name",
ConPostName: "con_post_name",
ContactPhone: "contact_phone",
FollowInfo: "follow_info",
FollowFile: "follow_file",
CreatedAt: "created_at",
UpdatedAt: "updated_at",
DeletedAt: "deleted_at",
Creator: "creator",
}
// NewTestFollowInfoDao creates and returns a new DAO object for table data access.
func NewTestFollowInfoDao() *TestFollowInfoDao {
return &TestFollowInfoDao{
group: "default",
table: "test_follow_info",
columns: testFollowInfoColumns,
}
}
// DB retrieves and returns the underlying raw database management object of current DAO.
func (dao *TestFollowInfoDao) DB() gdb.DB {
return g.DB(dao.group)
}
// Table returns the table name of current dao.
func (dao *TestFollowInfoDao) Table() string {
return dao.table
}
// Columns returns all column names of current dao.
func (dao *TestFollowInfoDao) Columns() TestFollowInfoColumns {
return dao.columns
}
// Group returns the configuration group name of database of current dao.
func (dao *TestFollowInfoDao) Group() string {
return dao.group
}
// Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.
func (dao *TestFollowInfoDao) 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 *TestFollowInfoDao) Transaction(ctx context.Context, f func(ctx context.Context, tx gdb.TX) error) (err error) {
return dao.Ctx(ctx).Transaction(ctx, f)
}

View File

@ -0,0 +1,96 @@
// ==========================================================================
// GFast自动生成dao internal操作代码。
// 生成日期2023-09-01 17:51:41
// 生成路径: internal/app/test/dao/internal/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package internal
import (
"context"
"github.com/gogf/gf/v2/database/gdb"
"github.com/gogf/gf/v2/frame/g"
)
// TestOwnerInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
type TestOwnerInfoDao 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 TestOwnerInfoColumns // Columns is the short type for Columns, which contains all the column names of Table for convenient usage.
}
// TestOwnerInfoColumns defines and stores column names for table test_owner_info.
type TestOwnerInfoColumns struct {
Id string //
CompanyName string // 企业名称
CompanyAddress string // 单位地址
RegistrationType string // 企业登记注册类型
RegisteredCapital string // 注册资金
Legaler string // 法人代表
LegalerPhone string // 法人电话
CreatedAt string // 创建日期
UpdatedAt string // 修改日期
DeletedAt string // 删除日期
Creator string // 删除日期
}
var testOwnerInfoColumns = TestOwnerInfoColumns{
Id: "id",
CompanyName: "company_name",
CompanyAddress: "company_address",
RegistrationType: "registration_type",
RegisteredCapital: "registered_capital",
Legaler: "legaler",
LegalerPhone: "legaler_phone",
CreatedAt: "created_at",
UpdatedAt: "updated_at",
DeletedAt: "deleted_at",
Creator: "creator",
}
// NewTestOwnerInfoDao creates and returns a new DAO object for table data access.
func NewTestOwnerInfoDao() *TestOwnerInfoDao {
return &TestOwnerInfoDao{
group: "default",
table: "test_owner_info",
columns: testOwnerInfoColumns,
}
}
// DB retrieves and returns the underlying raw database management object of current DAO.
func (dao *TestOwnerInfoDao) DB() gdb.DB {
return g.DB(dao.group)
}
// Table returns the table name of current dao.
func (dao *TestOwnerInfoDao) Table() string {
return dao.table
}
// Columns returns all column names of current dao.
func (dao *TestOwnerInfoDao) Columns() TestOwnerInfoColumns {
return dao.columns
}
// Group returns the configuration group name of database of current dao.
func (dao *TestOwnerInfoDao) Group() string {
return dao.group
}
// Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.
func (dao *TestOwnerInfoDao) 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 *TestOwnerInfoDao) Transaction(ctx context.Context, f func(ctx context.Context, tx gdb.TX) error) (err error) {
return dao.Ctx(ctx).Transaction(ctx, f)
}

View File

@ -0,0 +1,100 @@
// ==========================================================================
// GFast自动生成dao internal操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/dao/internal/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package internal
import (
"context"
"github.com/gogf/gf/v2/database/gdb"
"github.com/gogf/gf/v2/frame/g"
)
// TestProjectInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
type TestProjectInfoDao 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 TestProjectInfoColumns // Columns is the short type for Columns, which contains all the column names of Table for convenient usage.
}
// TestProjectInfoColumns defines and stores column names for table test_project_info.
type TestProjectInfoColumns struct {
Id string //
ProjectName string // 项目名称
ProjectAddress string // 单位地址
ProjectLeader string // 项目负责人
ResourceName string // 资源方
OwnerId string // 业主名id
ProjectType string // 项目类型
ProjectInfo string // 项目概况
ProjectState string // 项目状态(0未开始 1进行中 2已完成
CreatedAt string // 创建日期
UpdatedAt string // 修改日期
DeletedAt string // 删除日期
Creator string // 删除日期
}
var testProjectInfoColumns = TestProjectInfoColumns{
Id: "id",
ProjectName: "project_name",
ProjectAddress: "project_address",
ProjectLeader: "project_leader",
ResourceName: "resource_name",
OwnerId: "owner_id",
ProjectType: "project_type",
ProjectInfo: "project_info",
ProjectState: "project_state",
CreatedAt: "created_at",
UpdatedAt: "updated_at",
DeletedAt: "deleted_at",
Creator: "creator",
}
// NewTestProjectInfoDao creates and returns a new DAO object for table data access.
func NewTestProjectInfoDao() *TestProjectInfoDao {
return &TestProjectInfoDao{
group: "default",
table: "test_project_info",
columns: testProjectInfoColumns,
}
}
// DB retrieves and returns the underlying raw database management object of current DAO.
func (dao *TestProjectInfoDao) DB() gdb.DB {
return g.DB(dao.group)
}
// Table returns the table name of current dao.
func (dao *TestProjectInfoDao) Table() string {
return dao.table
}
// Columns returns all column names of current dao.
func (dao *TestProjectInfoDao) Columns() TestProjectInfoColumns {
return dao.columns
}
// Group returns the configuration group name of database of current dao.
func (dao *TestProjectInfoDao) Group() string {
return dao.group
}
// Ctx creates and returns the Model for current DAO, It automatically sets the context for current operation.
func (dao *TestProjectInfoDao) 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 *TestProjectInfoDao) Transaction(ctx context.Context, f func(ctx context.Context, tx gdb.TX) error) (err error) {
return dao.Ctx(ctx).Transaction(ctx, f)
}

View File

@ -0,0 +1,29 @@
// ==========================================================================
// GFast自动生成dao操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/dao/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package dao
import (
"github.com/tiger1103/gfast/v3/internal/app/test/dao/internal"
)
// testContactInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
// You can define custom methods on it to extend its functionality as you wish.
type testContactInfoDao struct {
*internal.TestContactInfoDao
}
var (
// TestContactInfo is globally public accessible object for table tools_gen_table operations.
TestContactInfo = testContactInfoDao{
internal.NewTestContactInfoDao(),
}
)
// Fill with you ideas below.

View File

@ -0,0 +1,29 @@
// ==========================================================================
// GFast自动生成dao操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/dao/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package dao
import (
"github.com/tiger1103/gfast/v3/internal/app/test/dao/internal"
)
// testFollowInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
// You can define custom methods on it to extend its functionality as you wish.
type testFollowInfoDao struct {
*internal.TestFollowInfoDao
}
var (
// TestFollowInfo is globally public accessible object for table tools_gen_table operations.
TestFollowInfo = testFollowInfoDao{
internal.NewTestFollowInfoDao(),
}
)
// Fill with you ideas below.

View File

@ -0,0 +1,29 @@
// ==========================================================================
// GFast自动生成dao操作代码。
// 生成日期2023-09-01 17:51:41
// 生成路径: internal/app/test/dao/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package dao
import (
"github.com/tiger1103/gfast/v3/internal/app/test/dao/internal"
)
// testOwnerInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
// You can define custom methods on it to extend its functionality as you wish.
type testOwnerInfoDao struct {
*internal.TestOwnerInfoDao
}
var (
// TestOwnerInfo is globally public accessible object for table tools_gen_table operations.
TestOwnerInfo = testOwnerInfoDao{
internal.NewTestOwnerInfoDao(),
}
)
// Fill with you ideas below.

View File

@ -0,0 +1,29 @@
// ==========================================================================
// GFast自动生成dao操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/dao/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package dao
import (
"github.com/tiger1103/gfast/v3/internal/app/test/dao/internal"
)
// testProjectInfoDao is the manager for logic model data accessing and custom defined data operations functions management.
// You can define custom methods on it to extend its functionality as you wish.
type testProjectInfoDao struct {
*internal.TestProjectInfoDao
}
var (
// TestProjectInfo is globally public accessible object for table tools_gen_table operations.
TestProjectInfo = testProjectInfoDao{
internal.NewTestProjectInfoDao(),
}
)
// Fill with you ideas below.

View File

@ -0,0 +1,6 @@
package logic
import _ "github.com/tiger1103/gfast/v3/internal/app/test/logic/testContactInfo"
import _ "github.com/tiger1103/gfast/v3/internal/app/test/logic/testFollowInfo"
import _ "github.com/tiger1103/gfast/v3/internal/app/test/logic/testOwnerInfo"
import _ "github.com/tiger1103/gfast/v3/internal/app/test/logic/testProjectInfo"

View File

@ -0,0 +1,140 @@
// ==========================================================================
// GFast自动生成logic操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/logic/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package logic
import (
"context"
"github.com/gogf/gf/v2/frame/g"
"github.com/gogf/gf/v2/util/gconv"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/system/consts"
ct "github.com/tiger1103/gfast/v3/internal/app/system/logic/context"
"github.com/tiger1103/gfast/v3/internal/app/test/dao"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
"github.com/tiger1103/gfast/v3/internal/app/test/model/do"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
"github.com/tiger1103/gfast/v3/library/liberr"
)
func init() {
service.RegisterTestContactInfo(New())
}
func New() *sTestContactInfo {
return &sTestContactInfo{}
}
type sTestContactInfo struct{}
func (s *sTestContactInfo) List(ctx context.Context, req *test.TestContactInfoSearchReq) (listRes *test.TestContactInfoSearchRes, err error) {
listRes = new(test.TestContactInfoSearchRes)
err = g.Try(ctx, func(ctx context.Context) {
m := dao.TestContactInfo.Ctx(ctx).WithAll()
if req.Id != "" {
m = m.Where(dao.TestContactInfo.Columns().Id+" = ?", req.Id)
}
//1、判断当前用户是否查看所有数据如果不是获取到手机号来查询数据
user := ct.New().GetLoginUser(ctx)
if user.IsData == "2" {
m = m.Where(dao.TestContactInfo.Columns().Creator+" = ?", user.Mobile)
}
if req.OwenerId != "" {
m = m.Where(dao.TestContactInfo.Columns().OwenerId+" = ?", gconv.Uint(req.OwenerId))
}
if req.ContactName != "" {
m = m.Where(dao.TestContactInfo.Columns().ContactName+" like ?", "%"+req.ContactName+"%")
}
if req.ContactPost != "" {
m = m.Where(dao.TestContactInfo.Columns().ContactPost+" like ?", "%"+req.ContactPost+"%")
}
if req.ContactPhone != "" {
m = m.Where(dao.TestContactInfo.Columns().ContactPhone+" = ?", req.ContactPhone)
}
listRes.Total, err = m.Count()
liberr.ErrIsNil(ctx, err, "获取总行数失败")
if req.PageNum == 0 {
req.PageNum = 1
}
listRes.CurrentPage = req.PageNum
if req.PageSize == 0 {
req.PageSize = consts.PageSize
}
order := "id asc"
if req.OrderBy != "" {
order = req.OrderBy
}
var res []*model.TestContactInfoInfoRes
err = m.Fields(test.TestContactInfoSearchRes{}).Page(req.PageNum, req.PageSize).Order(order).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取数据失败")
listRes.List = make([]*model.TestContactInfoListRes, len(res))
for k, v := range res {
listRes.List[k] = &model.TestContactInfoListRes{
Id: v.Id,
OwenerId: v.OwenerId,
LinkedOwenerId: v.LinkedOwenerId,
ContactName: v.ContactName,
ContactPost: v.ContactPost,
ContactPhone: v.ContactPhone,
Creator: v.Creator,
}
}
})
return
}
func (s *sTestContactInfo) GetById(ctx context.Context, id uint) (res *model.TestContactInfoInfoRes, err error) {
err = g.Try(ctx, func(ctx context.Context) {
err = dao.TestContactInfo.Ctx(ctx).WithAll().Where(dao.TestContactInfo.Columns().Id, id).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取信息失败")
})
return
}
func (s *sTestContactInfo) Add(ctx context.Context, req *test.TestContactInfoAddReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestContactInfo.Ctx(ctx).Insert(do.TestContactInfo{
OwenerId: req.OwenerId,
ContactName: req.ContactName,
ContactPost: req.ContactPost,
ContactPhone: req.ContactPhone,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "添加失败")
})
return
}
func (s *sTestContactInfo) Edit(ctx context.Context, req *test.TestContactInfoEditReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestContactInfo.Ctx(ctx).WherePri(req.Id).Update(do.TestContactInfo{
OwenerId: req.OwenerId,
ContactName: req.ContactName,
ContactPost: req.ContactPost,
ContactPhone: req.ContactPhone,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "修改失败")
})
return
}
func (s *sTestContactInfo) Delete(ctx context.Context, ids []uint) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
_, err = dao.TestContactInfo.Ctx(ctx).Delete(dao.TestContactInfo.Columns().Id+" in (?)", ids)
liberr.ErrIsNil(ctx, err, "删除失败")
})
return
}

View File

@ -0,0 +1,171 @@
// ==========================================================================
// GFast自动生成logic操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/logic/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package logic
import (
"context"
"fmt"
"github.com/gogf/gf/v2/frame/g"
"github.com/gogf/gf/v2/util/gconv"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/system/consts"
ct "github.com/tiger1103/gfast/v3/internal/app/system/logic/context"
"github.com/tiger1103/gfast/v3/internal/app/test/dao"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
"github.com/tiger1103/gfast/v3/internal/app/test/model/do"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
"github.com/tiger1103/gfast/v3/library/liberr"
)
func init() {
fmt.Println("注册逻辑层服务")
service.RegisterTestFollowInfo(New())
}
func New() *sTestFollowInfo {
return &sTestFollowInfo{}
}
type sTestFollowInfo struct{}
func (s *sTestFollowInfo) List(ctx context.Context, req *test.TestFollowInfoSearchReq) (listRes *test.TestFollowInfoSearchRes, err error) {
listRes = new(test.TestFollowInfoSearchRes)
err = g.Try(ctx, func(ctx context.Context) {
m := dao.TestFollowInfo.Ctx(ctx).WithAll()
//1、判断当前用户是否查看所有数据如果不是获取到手机号来查询数据
user := ct.New().GetLoginUser(ctx)
if user.IsData == "2" {
m = m.Where(dao.TestFollowInfo.Columns().Creator+" = ?", user.Mobile)
}
if req.Id != "" {
m = m.Where(dao.TestFollowInfo.Columns().Id+" = ?", req.Id)
}
if req.ProjectId != "" {
m = m.Where(dao.TestFollowInfo.Columns().ProjectId+" = ?", gconv.Int(req.ProjectId))
}
if req.FollowName != "" {
m = m.Where(dao.TestFollowInfo.Columns().FollowName+" like ?", "%"+req.FollowName+"%")
}
if req.OwnerId != "" {
m = m.Where(dao.TestFollowInfo.Columns().OwnerId+" = ?", gconv.Uint(req.OwnerId))
}
if req.ContactName != "" {
m = m.Where(dao.TestFollowInfo.Columns().ContactName+" like ?", "%"+req.ContactName+"%")
}
if req.ConPostName != "" {
m = m.Where(dao.TestFollowInfo.Columns().ConPostName+" like ?", "%"+req.ConPostName+"%")
}
if req.ContactPhone != "" {
m = m.Where(dao.TestFollowInfo.Columns().ContactPhone+" = ?", req.ContactPhone)
}
if req.FollowInfo != "" {
m = m.Where(dao.TestFollowInfo.Columns().FollowInfo+" = ?", req.FollowInfo)
}
if req.FollowFile != "" {
m = m.Where(dao.TestFollowInfo.Columns().FollowFile+" = ?", req.FollowFile)
}
if len(req.DateRange) != 0 {
m = m.Where(dao.TestFollowInfo.Columns().CreatedAt+" >=? AND "+dao.TestFollowInfo.Columns().CreatedAt+" <=?", req.DateRange[0], req.DateRange[1])
}
listRes.Total, err = m.Count()
liberr.ErrIsNil(ctx, err, "获取总行数失败")
if req.PageNum == 0 {
req.PageNum = 1
}
listRes.CurrentPage = req.PageNum
if req.PageSize == 0 {
req.PageSize = consts.PageSize
}
order := "id asc"
if req.OrderBy != "" {
order = req.OrderBy
}
var res []*model.TestFollowInfoInfoRes
err = m.Fields(test.TestFollowInfoSearchRes{}).Page(req.PageNum, req.PageSize).Order(order).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取数据失败")
listRes.List = make([]*model.TestFollowInfoListRes, len(res))
for k, v := range res {
listRes.List[k] = &model.TestFollowInfoListRes{
Id: v.Id,
ProjectId: v.ProjectId,
LinkedProjectId: v.LinkedProjectId,
FollowName: v.FollowName,
OwnerId: v.OwnerId,
LinkedOwnerId: v.LinkedOwnerId,
ContactName: v.ContactName,
ConPostName: v.ConPostName,
ContactPhone: v.ContactPhone,
FollowInfo: v.FollowInfo,
FollowFile: v.FollowFile,
CreatedAt: v.CreatedAt,
Creator: v.Creator,
}
}
})
return
}
func (s *sTestFollowInfo) GetById(ctx context.Context, id uint) (res *model.TestFollowInfoInfoRes, err error) {
err = g.Try(ctx, func(ctx context.Context) {
err = dao.TestFollowInfo.Ctx(ctx).WithAll().Where(dao.TestFollowInfo.Columns().Id, id).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取信息失败")
})
return
}
func (s *sTestFollowInfo) Add(ctx context.Context, req *test.TestFollowInfoAddReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestFollowInfo.Ctx(ctx).Insert(do.TestFollowInfo{
ProjectId: req.ProjectId,
FollowName: req.FollowName,
OwnerId: req.OwnerId,
ContactName: req.ContactName,
ConPostName: req.ConPostName,
ContactPhone: req.ContactPhone,
FollowInfo: req.FollowInfo,
FollowFile: req.FollowFile,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "添加失败")
})
return
}
func (s *sTestFollowInfo) Edit(ctx context.Context, req *test.TestFollowInfoEditReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestFollowInfo.Ctx(ctx).WherePri(req.Id).Update(do.TestFollowInfo{
ProjectId: req.ProjectId,
FollowName: req.FollowName,
OwnerId: req.OwnerId,
ContactName: req.ContactName,
ConPostName: req.ConPostName,
ContactPhone: req.ContactPhone,
FollowInfo: req.FollowInfo,
FollowFile: req.FollowFile,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "修改失败")
})
return
}
func (s *sTestFollowInfo) Delete(ctx context.Context, ids []uint) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
_, err = dao.TestFollowInfo.Ctx(ctx).Delete(dao.TestFollowInfo.Columns().Id+" in (?)", ids)
liberr.ErrIsNil(ctx, err, "删除失败")
})
return
}

View File

@ -0,0 +1,156 @@
// ==========================================================================
// GFast自动生成logic操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/logic/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package logic
import (
"context"
"github.com/gogf/gf/v2/frame/g"
"github.com/gogf/gf/v2/util/gconv"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/system/consts"
ct "github.com/tiger1103/gfast/v3/internal/app/system/logic/context"
"github.com/tiger1103/gfast/v3/internal/app/test/dao"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
"github.com/tiger1103/gfast/v3/internal/app/test/model/do"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
"github.com/tiger1103/gfast/v3/library/liberr"
)
func init() {
service.RegisterTestOwnerInfo(New())
}
func New() *sTestOwnerInfo {
return &sTestOwnerInfo{}
}
type sTestOwnerInfo struct{}
func (s *sTestOwnerInfo) List(ctx context.Context, req *test.TestOwnerInfoSearchReq) (listRes *test.TestOwnerInfoSearchRes, err error) {
listRes = new(test.TestOwnerInfoSearchRes)
err = g.Try(ctx, func(ctx context.Context) {
m := dao.TestOwnerInfo.Ctx(ctx).WithAll()
//1、判断当前用户是否查看所有数据如果不是获取到手机号来查询数据
user := ct.New().GetLoginUser(ctx)
if user.IsData == "2" {
m = m.Where(dao.TestOwnerInfo.Columns().Creator+" = ?", user.Mobile)
}
if req.Id != "" {
m = m.Where(dao.TestOwnerInfo.Columns().Id+" = ?", req.Id)
}
if req.CompanyName != "" {
m = m.Where(dao.TestOwnerInfo.Columns().CompanyName+" like ?", "%"+req.CompanyName+"%")
}
if req.CompanyAddress != "" {
m = m.Where(dao.TestOwnerInfo.Columns().CompanyAddress+" = ?", req.CompanyAddress)
}
if req.RegistrationType != "" {
m = m.Where(dao.TestOwnerInfo.Columns().RegistrationType+" = ?", req.RegistrationType)
}
if req.RegisteredCapital != "" {
m = m.Where(dao.TestOwnerInfo.Columns().RegisteredCapital+" = ?", gconv.Int(req.RegisteredCapital))
}
if req.Legaler != "" {
m = m.Where(dao.TestOwnerInfo.Columns().Legaler+" like ?", "%"+req.Legaler+"%")
}
if req.LegalerPhone != "" {
m = m.Where(dao.TestOwnerInfo.Columns().LegalerPhone+" = ?", req.LegalerPhone)
}
if len(req.DateRange) != 0 {
m = m.Where(dao.TestOwnerInfo.Columns().CreatedAt+" >=? AND "+dao.TestOwnerInfo.Columns().CreatedAt+" <=?", req.DateRange[0], req.DateRange[1])
}
listRes.Total, err = m.Count()
liberr.ErrIsNil(ctx, err, "获取总行数失败")
if req.PageNum == 0 {
req.PageNum = 1
}
listRes.CurrentPage = req.PageNum
if req.PageSize == 0 {
req.PageSize = consts.PageSize
}
order := "id asc"
if req.OrderBy != "" {
order = req.OrderBy
}
var res []*model.TestOwnerInfoInfoRes
err = m.Fields(test.TestOwnerInfoSearchRes{}).Page(req.PageNum, req.PageSize).Order(order).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取数据失败")
listRes.List = make([]*model.TestOwnerInfoListRes, len(res))
for k, v := range res {
listRes.List[k] = &model.TestOwnerInfoListRes{
Id: v.Id,
CompanyName: v.CompanyName,
CompanyAddress: v.CompanyAddress,
RegistrationType: v.RegistrationType,
RegisteredCapital: v.RegisteredCapital,
Legaler: v.Legaler,
LegalerPhone: v.LegalerPhone,
Children: v.Children,
CreatedAt: v.CreatedAt,
Creator: v.Creator,
}
}
})
return
}
func (s *sTestOwnerInfo) GetById(ctx context.Context, id uint) (res *model.TestOwnerInfoInfoRes, err error) {
err = g.Try(ctx, func(ctx context.Context) {
err = dao.TestOwnerInfo.Ctx(ctx).WithAll().Where(dao.TestOwnerInfo.Columns().Id, id).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取信息失败")
})
return
}
func (s *sTestOwnerInfo) Add(ctx context.Context, req *test.TestOwnerInfoAddReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestOwnerInfo.Ctx(ctx).Insert(do.TestOwnerInfo{
CompanyName: req.CompanyName,
CompanyAddress: req.CompanyAddress,
RegistrationType: req.RegistrationType,
RegisteredCapital: req.RegisteredCapital,
Legaler: req.Legaler,
LegalerPhone: req.LegalerPhone,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "添加失败")
})
return
}
func (s *sTestOwnerInfo) Edit(ctx context.Context, req *test.TestOwnerInfoEditReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestOwnerInfo.Ctx(ctx).WherePri(req.Id).Update(do.TestOwnerInfo{
CompanyName: req.CompanyName,
CompanyAddress: req.CompanyAddress,
RegistrationType: req.RegistrationType,
RegisteredCapital: req.RegisteredCapital,
Legaler: req.Legaler,
LegalerPhone: req.LegalerPhone,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "修改失败")
})
return
}
func (s *sTestOwnerInfo) Delete(ctx context.Context, ids []uint) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
_, err = dao.TestOwnerInfo.Ctx(ctx).Delete(dao.TestOwnerInfo.Columns().Id+" in (?)", ids)
liberr.ErrIsNil(ctx, err, "删除失败")
})
return
}

View File

@ -0,0 +1,165 @@
// ==========================================================================
// GFast自动生成logic操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/logic/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package logic
import (
"context"
"github.com/gogf/gf/v2/frame/g"
"github.com/gogf/gf/v2/util/gconv"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/system/consts"
ct "github.com/tiger1103/gfast/v3/internal/app/system/logic/context"
"github.com/tiger1103/gfast/v3/internal/app/test/dao"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
"github.com/tiger1103/gfast/v3/internal/app/test/model/do"
"github.com/tiger1103/gfast/v3/internal/app/test/service"
"github.com/tiger1103/gfast/v3/library/liberr"
)
func init() {
service.RegisterTestProjectInfo(New())
}
func New() *sTestProjectInfo {
return &sTestProjectInfo{}
}
type sTestProjectInfo struct{}
func (s *sTestProjectInfo) List(ctx context.Context, req *test.TestProjectInfoSearchReq) (listRes *test.TestProjectInfoSearchRes, err error) {
listRes = new(test.TestProjectInfoSearchRes)
err = g.Try(ctx, func(ctx context.Context) {
m := dao.TestProjectInfo.Ctx(ctx).WithAll()
//1、判断当前用户是否查看所有数据如果不是获取到手机号来查询数据
user := ct.New().GetLoginUser(ctx)
if user.IsData == "2" {
m = m.Where(dao.TestProjectInfo.Columns().Creator+" = ?", user.Mobile)
}
if req.ProjectAddress != "" {
m = m.Where(dao.TestProjectInfo.Columns().ProjectAddress+" = ?", req.ProjectAddress)
}
if req.ProjectLeader != "" {
m = m.Where(dao.TestProjectInfo.Columns().ProjectLeader+" = ?", req.ProjectLeader)
}
if req.OwnerId != "" {
m = m.Where(dao.TestProjectInfo.Columns().OwnerId+" = ?", gconv.Int(req.OwnerId))
}
if req.ProjectType != "" {
m = m.Where(dao.TestProjectInfo.Columns().ProjectType+" = ?", req.ProjectType)
}
if req.ProjectInfo != "" {
m = m.Where(dao.TestProjectInfo.Columns().ProjectInfo+" = ?", req.ProjectInfo)
}
if req.ProjectState != "" {
m = m.Where(dao.TestProjectInfo.Columns().ProjectState+" = ?", gconv.Int(req.ProjectState))
}
if req.ProjectName != "" {
m = m.Where(dao.TestProjectInfo.Columns().ProjectName+" like ?", "%"+req.ProjectName+"%")
}
if req.ResourceName != "" {
m = m.Where(dao.TestProjectInfo.Columns().ResourceName+" like ?", "%"+req.ResourceName+"%")
}
if len(req.DateRange) != 0 {
m = m.Where(dao.TestProjectInfo.Columns().CreatedAt+" >=? AND "+dao.TestProjectInfo.Columns().CreatedAt+" <=?", req.DateRange[0], req.DateRange[1])
}
listRes.Total, err = m.Count()
liberr.ErrIsNil(ctx, err, "获取总行数失败")
if req.PageNum == 0 {
req.PageNum = 1
}
listRes.CurrentPage = req.PageNum
if req.PageSize == 0 {
req.PageSize = consts.PageSize
}
order := "id asc"
if req.OrderBy != "" {
order = req.OrderBy
}
var res []*model.TestProjectInfoInfoRes
err = m.Fields(test.TestProjectInfoSearchRes{}).Page(req.PageNum, req.PageSize).Order(order).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取数据失败")
listRes.List = make([]*model.TestProjectInfoListRes, len(res))
for k, v := range res {
listRes.List[k] = &model.TestProjectInfoListRes{
Id: v.Id,
ProjectName: v.ProjectName,
ProjectAddress: v.ProjectAddress,
ProjectLeader: v.ProjectLeader,
ResourceName: v.ResourceName,
OwnerId: v.OwnerId,
LinkedOwnerId: v.LinkedOwnerId,
ProjectType: v.ProjectType,
ProjectInfo: v.ProjectInfo,
ProjectState: v.ProjectState,
CreatedAt: v.CreatedAt,
Creator: v.Creator,
}
}
})
return
}
func (s *sTestProjectInfo) GetById(ctx context.Context, id uint) (res *model.TestProjectInfoInfoRes, err error) {
err = g.Try(ctx, func(ctx context.Context) {
err = dao.TestProjectInfo.Ctx(ctx).WithAll().Where(dao.TestProjectInfo.Columns().Id, id).Scan(&res)
liberr.ErrIsNil(ctx, err, "获取信息失败")
})
return
}
func (s *sTestProjectInfo) Add(ctx context.Context, req *test.TestProjectInfoAddReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestProjectInfo.Ctx(ctx).Insert(do.TestProjectInfo{
ProjectName: req.ProjectName,
ProjectAddress: req.ProjectAddress,
ProjectLeader: req.ProjectLeader,
ResourceName: req.ResourceName,
OwnerId: req.OwnerId,
ProjectType: req.ProjectType,
ProjectInfo: req.ProjectInfo,
ProjectState: req.ProjectState,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "添加失败")
})
return
}
func (s *sTestProjectInfo) Edit(ctx context.Context, req *test.TestProjectInfoEditReq) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
if req.WxOrPc == "1" {
req.Creator = ct.New().GetLoginUser(ctx).Mobile
}
_, err = dao.TestProjectInfo.Ctx(ctx).WherePri(req.Id).Update(do.TestProjectInfo{
ProjectName: req.ProjectName,
ProjectAddress: req.ProjectAddress,
ProjectLeader: req.ProjectLeader,
ResourceName: req.ResourceName,
OwnerId: req.OwnerId,
ProjectType: req.ProjectType,
ProjectInfo: req.ProjectInfo,
ProjectState: req.ProjectState,
Creator: req.Creator,
})
liberr.ErrIsNil(ctx, err, "修改失败")
})
return
}
func (s *sTestProjectInfo) Delete(ctx context.Context, ids []uint) (err error) {
err = g.Try(ctx, func(ctx context.Context) {
_, err = dao.TestProjectInfo.Ctx(ctx).Delete(dao.TestProjectInfo.Columns().Id+" in (?)", ids)
liberr.ErrIsNil(ctx, err, "删除失败")
})
return
}

View File

@ -0,0 +1,25 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/model/entity/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package do
import (
"github.com/gogf/gf/v2/util/gmeta"
)
// TestContactInfo is the golang structure for table test_contact_info.
type TestContactInfo struct {
gmeta.Meta `orm:"table:test_contact_info, do:true"`
Id interface{} `orm:"id,primary" json:"id"`
OwenerId interface{} `orm:"owener_id" json:"owenerId"`
ContactName interface{} `orm:"contact_name" json:"contactName"`
ContactPost interface{} `orm:"contact_post" json:"contactPost"`
ContactPhone interface{} `orm:"contact_phone" json:"contactPhone"`
Creator interface{} `orm:"creator,primary" json:"creator"`
}

View File

@ -0,0 +1,33 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/model/entity/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package do
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestFollowInfo is the golang structure for table test_follow_info.
type TestFollowInfo struct {
gmeta.Meta `orm:"table:test_follow_info, do:true"`
Id interface{} `orm:"id,primary" json:"id"` //
ProjectId interface{} `orm:"project_id" json:"projectId"` // 关联的项目
FollowName interface{} `orm:"follow_name" json:"followName"` // 跟进人姓名
OwnerId interface{} `orm:"owner_id" json:"ownerId"` // 业主名
ContactName interface{} `orm:"contact_name" json:"contactName"` // 对接人姓名
ConPostName interface{} `orm:"con_post_name" json:"conPostName"` // 对接人职称
ContactPhone interface{} `orm:"contact_phone" json:"contactPhone"` // 对接人电话
FollowInfo interface{} `orm:"follow_info" json:"followInfo"` // 跟进情况
FollowFile interface{} `orm:"follow_file" json:"followFile"` // 相关附件
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
Creator interface{} `orm:"creator,primary" json:"creator"` //
}

View File

@ -0,0 +1,31 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/model/entity/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package do
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestOwnerInfo is the golang structure for table test_owner_info.
type TestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info, do:true"`
Id interface{} `orm:"id,primary" json:"id"` //
CompanyName interface{} `orm:"company_name" json:"companyName"` // 企业名称
CompanyAddress interface{} `orm:"company_address" json:"companyAddress"` // 单位地址
RegistrationType interface{} `orm:"registration_type" json:"registrationType"` // 企业登记注册类型
RegisteredCapital interface{} `orm:"registered_capital" json:"registeredCapital"` // 注册资金
Legaler interface{} `orm:"legaler" json:"legaler"` // 法人代表
LegalerPhone interface{} `orm:"legaler_phone" json:"legalerPhone"` // 法人电话
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
Creator interface{} `orm:"creator,primary" json:"creator"` //
}

View File

@ -0,0 +1,33 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/model/entity/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package do
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestProjectInfo is the golang structure for table test_project_info.
type TestProjectInfo struct {
gmeta.Meta `orm:"table:test_project_info, do:true"`
Id interface{} `orm:"id,primary" json:"id"` //
ProjectName interface{} `orm:"project_name" json:"projectName"` // 项目名称
ProjectAddress interface{} `orm:"project_address" json:"projectAddress"` // 单位地址
ProjectLeader interface{} `orm:"project_leader" json:"projectLeader"` // 项目负责人
ResourceName interface{} `orm:"resource_name" json:"resourceName"` // 资源方
OwnerId interface{} `orm:"owner_id" json:"ownerId"` // 业主名id
ProjectType interface{} `orm:"project_type" json:"projectType"` // 项目类型
ProjectInfo interface{} `orm:"project_info" json:"projectInfo"` // 项目概况
ProjectState interface{} `orm:"project_state" json:"projectState"` // 项目状态(0未开始 1进行中 2已完成
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
Creator interface{} `orm:"creator,primary" json:"creator"` //
}

View File

@ -0,0 +1,31 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/model/entity/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package entity
import (
"github.com/gogf/gf/v2/util/gmeta"
)
// TestContactInfo is the golang structure for table test_contact_info.
type TestContactInfo struct {
gmeta.Meta `orm:"table:test_contact_info"`
Id uint `orm:"id,primary" json:"id"` //
OwenerId uint `orm:"owener_id" json:"owenerId"` //
LinkedOwenerId *LinkedTestContactInfoTestOwnerInfo `orm:"with:id=owener_id" json:"linkedOwenerId"`
ContactName string `orm:"contact_name" json:"contactName"` //
ContactPost string `orm:"contact_post" json:"contactPost"` //
ContactPhone string `orm:"contact_phone" json:"contactPhone"` //
}
type LinkedTestContactInfoTestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
}

View File

@ -0,0 +1,46 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/model/entity/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package entity
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestFollowInfo is the golang structure for table test_follow_info.
type TestFollowInfo struct {
gmeta.Meta `orm:"table:test_follow_info"`
Id uint `orm:"id,primary" json:"id"` //
ProjectId int `orm:"project_id" json:"projectId"` // 关联的项目
LinkedProjectId *LinkedTestFollowInfoTestProjectInfo `orm:"with:id=project_id" json:"linkedProjectId"`
FollowName string `orm:"follow_name" json:"followName"` // 跟进人姓名
OwnerId uint `orm:"owner_id" json:"ownerId"` // 业主名
LinkedOwnerId *LinkedTestFollowInfoTestOwnerInfo `orm:"with:id=owner_id" json:"linkedOwnerId"`
ContactName string `orm:"contact_name" json:"contactName"` // 对接人姓名
ConPostName string `orm:"con_post_name" json:"conPostName"` // 对接人职称
ContactPhone string `orm:"contact_phone" json:"contactPhone"` // 对接人电话
FollowInfo string `orm:"follow_info" json:"followInfo"` // 跟进情况
FollowFile string `orm:"follow_file" json:"followFile"` // 相关附件
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
}
type LinkedTestFollowInfoTestProjectInfo struct {
gmeta.Meta `orm:"table:test_project_info"`
Id uint `orm:"id" json:"id"` //
ProjectName string `orm:"project_name" json:"projectName"` // 项目名称
}
type LinkedTestFollowInfoTestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
}

View File

@ -0,0 +1,30 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/model/entity/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package entity
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestOwnerInfo is the golang structure for table test_owner_info.
type TestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id,primary" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
CompanyAddress string `orm:"company_address" json:"companyAddress"` // 单位地址
RegistrationType string `orm:"registration_type" json:"registrationType"` // 企业登记注册类型
RegisteredCapital int `orm:"registered_capital" json:"registeredCapital"` // 注册资金
Legaler string `orm:"legaler" json:"legaler"` // 法人代表
LegalerPhone string `orm:"legaler_phone" json:"legalerPhone"` // 法人电话
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
}

View File

@ -0,0 +1,39 @@
// ==========================================================================
// GFast自动生成model entity操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/model/entity/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package entity
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestProjectInfo is the golang structure for table test_project_info.
type TestProjectInfo struct {
gmeta.Meta `orm:"table:test_project_info"`
Id uint `orm:"id,primary" json:"id"` //
ProjectName string `orm:"project_name" json:"projectName"` // 项目名称
ProjectAddress string `orm:"project_address" json:"projectAddress"` // 单位地址
ProjectLeader string `orm:"project_leader" json:"projectLeader"` // 项目负责人
ResourceName string `orm:"resource_name" json:"resourceName"` // 资源方
OwnerId int `orm:"owner_id" json:"ownerId"` // 业主名id
LinkedOwnerId *LinkedTestProjectInfoTestOwnerInfo `orm:"with:id=owner_id" json:"linkedOwnerId"`
ProjectType string `orm:"project_type" json:"projectType"` // 项目类型
ProjectInfo string `orm:"project_info" json:"projectInfo"` // 项目概况
ProjectState int `orm:"project_state" json:"projectState"` // 项目状态(0未开始 1进行中 2已完成
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
}
type LinkedTestProjectInfoTestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
}

View File

@ -0,0 +1,42 @@
// ==========================================================================
// GFast自动生成model操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/model/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package model
import (
"github.com/gogf/gf/v2/util/gmeta"
)
// TestContactInfoInfoRes is the golang structure for table test_contact_info.
type TestContactInfoInfoRes struct {
gmeta.Meta `orm:"table:test_contact_info"`
Id uint `orm:"id,primary" json:"id"` //
OwenerId uint `orm:"owener_id" json:"owenerId"` //
LinkedOwenerId *LinkedTestContactInfoTestOwnerInfo `orm:"with:id=owener_id" json:"linkedOwenerId"`
ContactName string `orm:"contact_name" json:"contactName"` //
ContactPost string `orm:"contact_post" json:"contactPost"` //
ContactPhone string `orm:"contact_phone" json:"contactPhone"` //
Creator string `orm:"creator" json:"creator"` //
}
type LinkedTestContactInfoTestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
}
type TestContactInfoListRes struct {
Id uint `json:"id"`
OwenerId uint `json:"owenerId"`
LinkedOwenerId *LinkedTestContactInfoTestOwnerInfo `orm:"with:id=owener_id" json:"linkedOwenerId"`
ContactName string `json:"contactName"`
ContactPost string `json:"contactPost"`
ContactPhone string `json:"contactPhone"`
Creator string `json:"creator"`
}

View File

@ -0,0 +1,62 @@
// ==========================================================================
// GFast自动生成model操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/model/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package model
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestFollowInfoInfoRes is the golang structure for table test_follow_info.
type TestFollowInfoInfoRes struct {
gmeta.Meta `orm:"table:test_follow_info"`
Id uint `orm:"id,primary" json:"id"` //
ProjectId int `orm:"project_id" json:"projectId"` // 关联的项目
LinkedProjectId *LinkedTestFollowInfoTestProjectInfo `orm:"with:id=project_id" json:"linkedProjectId"`
FollowName string `orm:"follow_name" json:"followName"` // 跟进人姓名
OwnerId uint `orm:"owner_id" json:"ownerId"` // 业主名
LinkedOwnerId *LinkedTestFollowInfoTestOwnerInfo `orm:"with:id=owner_id" json:"linkedOwnerId"`
ContactName string `orm:"contact_name" json:"contactName"` // 对接人姓名
ConPostName string `orm:"con_post_name" json:"conPostName"` // 对接人职称
ContactPhone string `orm:"contact_phone" json:"contactPhone"` // 对接人电话
FollowInfo string `orm:"follow_info" json:"followInfo"` // 跟进情况
FollowFile string `orm:"follow_file" json:"followFile"` // 相关附件
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
Creator string `orm:"creator" json:"creator"` //
}
type LinkedTestFollowInfoTestProjectInfo struct {
gmeta.Meta `orm:"table:test_project_info"`
Id uint `orm:"id" json:"id"` //
ProjectName string `orm:"project_name" json:"projectName"` // 项目名称
}
type LinkedTestFollowInfoTestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
}
type TestFollowInfoListRes struct {
Id uint `json:"id" dc:"主键ID"`
ProjectId int `json:"projectId" dc:"项目id"`
LinkedProjectId *LinkedTestFollowInfoTestProjectInfo `orm:"with:id=project_id" json:"linkedProjectId"`
FollowName string `json:"followName" dc:"跟进人姓名"`
OwnerId uint `json:"ownerId" dc:"业主名"`
LinkedOwnerId *LinkedTestFollowInfoTestOwnerInfo `orm:"with:id=owner_id" json:"linkedOwnerId"`
ContactName string `json:"contactName" dc:"对接人姓名"`
ConPostName string `json:"conPostName" dc:"对接人职称"`
ContactPhone string `json:"contactPhone" dc:"对接人电话"`
FollowInfo string `json:"followInfo" dc:"跟进情况"`
FollowFile string `json:"followFile" dc:"相关附件"`
CreatedAt *gtime.Time `json:"createdAt"`
Creator string `json:"creator"`
}

View File

@ -0,0 +1,56 @@
// ==========================================================================
// GFast自动生成model操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/model/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package model
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestOwnerInfoInfoRes is the golang structure for table test_owner_info.
type TestOwnerInfoInfoRes struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id,primary" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
CompanyAddress string `orm:"company_address" json:"companyAddress"` // 单位地址
RegistrationType string `orm:"registration_type" json:"registrationType"` // 企业登记注册类型
RegisteredCapital int `orm:"registered_capital" json:"registeredCapital"` // 注册资金
Legaler string `orm:"legaler" json:"legaler"` // 法人代表
LegalerPhone string `orm:"legaler_phone" json:"legalerPhone"` // 法人电话
Children []*LinkedTestOwnerInfoTestContact `orm:"with:owener_id=id" `
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
Creator string `orm:"creator" json:"creator"` //
}
// 增加owner表子数据array
type LinkedTestOwnerInfoTestContact struct {
gmeta.Meta `orm:"table:test_contact_info"`
Id uint `orm:"id,primary" json:"id"`
OwenerId uint `orm:"owener_id" json:"owenerId"` //业主方id
ContactName string `orm:"contact_name" json:"contactName"` //对接人姓名
ContactPost string `orm:"contact_post" json:"contactPost"` //对接人职称
ContactPhone string `orm:"contact_phone" json:"contactPhone"` //对接人电话
}
type TestOwnerInfoListRes struct {
Id uint `json:"id"`
CompanyName string `json:"companyName"`
CompanyAddress string `json:"companyAddress"`
RegistrationType string `json:"registrationType"`
RegisteredCapital int `json:"registeredCapital"`
Legaler string `json:"legaler"`
LegalerPhone string `json:"legalerPhone"`
Children []*LinkedTestOwnerInfoTestContact `orm:"with:owener_id=id" `
CreatedAt *gtime.Time `json:"createdAt"`
Creator string `json:"creator"`
}

View File

@ -0,0 +1,55 @@
// ==========================================================================
// GFast自动生成model操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/model/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package model
import (
"github.com/gogf/gf/v2/os/gtime"
"github.com/gogf/gf/v2/util/gmeta"
)
// TestProjectInfoInfoRes is the golang structure for table test_project_info.
type TestProjectInfoInfoRes struct {
gmeta.Meta `orm:"table:test_project_info"`
Id uint `orm:"id,primary" json:"id"` //
ProjectName string `orm:"project_name" json:"projectName"` // 项目名称
ProjectAddress string `orm:"project_address" json:"projectAddress"` // 单位地址
ProjectLeader string `orm:"project_leader" json:"projectLeader"` // 项目负责人
ResourceName string `orm:"resource_name" json:"resourceName"` // 资源方
OwnerId int `orm:"owner_id" json:"ownerId"` // 业主名id
LinkedOwnerId *LinkedTestProjectInfoTestOwnerInfo `orm:"with:id=owner_id" json:"linkedOwnerId"`
ProjectType string `orm:"project_type" json:"projectType"` // 项目类型
ProjectInfo string `orm:"project_info" json:"projectInfo"` // 项目概况
ProjectState int `orm:"project_state" json:"projectState"` // 项目状态(0未开始 1进行中 2已完成
CreatedAt *gtime.Time `orm:"created_at" json:"createdAt"` // 创建日期
UpdatedAt *gtime.Time `orm:"updated_at" json:"updatedAt"` // 修改日期
DeletedAt *gtime.Time `orm:"deleted_at" json:"deletedAt"` // 删除日期
Creator string `orm:"creator" json:"creator"` //
}
type LinkedTestProjectInfoTestOwnerInfo struct {
gmeta.Meta `orm:"table:test_owner_info"`
Id uint `orm:"id" json:"id"` //
CompanyName string `orm:"company_name" json:"companyName"` // 企业名称
}
type TestProjectInfoListRes struct {
Id uint `json:"id"`
ProjectName string `json:"projectName" dc:"项目名称"`
ProjectAddress string `json:"projectAddress" dc:"单位地址"`
ProjectLeader string `json:"projectLeader" dc:"项目负责人"`
ResourceName string `json:"resourceName" dc:"资源方"`
OwnerId int `json:"ownerId" dc:"业主名id"`
LinkedOwnerId *LinkedTestProjectInfoTestOwnerInfo `orm:"with:id=owner_id" json:"linkedOwnerId" `
ProjectType string `json:"projectType" dc:"项目类型"`
ProjectInfo string `json:"projectInfo" dc:"项目概况"`
ProjectState int `json:"projectState" dc:"项目状态(0未开始 1进行中 2已完成"`
CreatedAt *gtime.Time `json:"createdAt" dc:"创建日期"`
Creator string `json:"creator"`
}

View File

@ -0,0 +1,41 @@
// ==========================================================================
// GFast自动生成router操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/router/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package router
import (
"context"
"github.com/gogf/gf/v2/net/ghttp"
"github.com/tiger1103/gfast/v3/internal/app/system/service"
"github.com/tiger1103/gfast/v3/internal/app/test/controller"
"github.com/tiger1103/gfast/v3/library/libRouter"
)
var R = new(Router)
type Router struct{}
func (router *Router) BindController(ctx context.Context, group *ghttp.RouterGroup) {
group.Group("/", func(group *ghttp.RouterGroup) {
//登录验证拦截
service.GfToken().Middleware(group)
////context拦截器
group.Middleware(service.Middleware().Ctx, service.Middleware().Auth)
//后台操作日志记录
group.Hook("/*", ghttp.HookAfterOutput, service.OperateLog().OperationLog)
group.Bind(
controller.TestContactInfo,
controller.TestFollowInfo,
)
//自动绑定定义的控制器
if err := libRouter.RouterAutoBind(ctx, router, group); err != nil {
panic(err)
}
})
}

View File

@ -0,0 +1,24 @@
// ==========================================================================
// GFast自动生成router操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/router/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package router
import (
"context"
"github.com/gogf/gf/v2/net/ghttp"
"github.com/tiger1103/gfast/v3/internal/app/test/controller"
)
func (router *Router) BindTestContactInfoController(ctx context.Context, group *ghttp.RouterGroup) {
group.Group("/testContactInfo", func(group *ghttp.RouterGroup) {
group.Bind(
controller.TestContactInfo,
)
})
}

View File

@ -0,0 +1,24 @@
// ==========================================================================
// GFast自动生成router操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/router/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package router
import (
"context"
"github.com/gogf/gf/v2/net/ghttp"
"github.com/tiger1103/gfast/v3/internal/app/test/controller"
)
func (router *Router) BindTestFollowInfoController(ctx context.Context, group *ghttp.RouterGroup) {
group.Group("/testFollowInfo", func(group *ghttp.RouterGroup) {
group.Bind(
controller.TestFollowInfo,
)
})
}

View File

@ -0,0 +1,24 @@
// ==========================================================================
// GFast自动生成router操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/router/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package router
import (
"context"
"github.com/gogf/gf/v2/net/ghttp"
"github.com/tiger1103/gfast/v3/internal/app/test/controller"
)
func (router *Router) BindTestOwnerInfoController(ctx context.Context, group *ghttp.RouterGroup) {
group.Group("/testOwnerInfo", func(group *ghttp.RouterGroup) {
group.Bind(
controller.TestOwnerInfo,
)
})
}

View File

@ -0,0 +1,24 @@
// ==========================================================================
// GFast自动生成router操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/router/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package router
import (
"context"
"github.com/gogf/gf/v2/net/ghttp"
"github.com/tiger1103/gfast/v3/internal/app/test/controller"
)
func (router *Router) BindTestProjectInfoController(ctx context.Context, group *ghttp.RouterGroup) {
group.Group("/testProjectInfo", func(group *ghttp.RouterGroup) {
group.Bind(
controller.TestProjectInfo,
)
})
}

View File

@ -0,0 +1,37 @@
// ==========================================================================
// GFast自动生成service操作代码。
// 生成日期2023-09-01 17:36:18
// 生成路径: internal/app/test/service/test_contact_info.go
// 生成人yqq
// desc:业主方联系人关联
// company:云南奇讯科技有限公司
// ==========================================================================
package service
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
)
type ITestContactInfo interface {
List(ctx context.Context, req *test.TestContactInfoSearchReq) (res *test.TestContactInfoSearchRes, err error)
GetById(ctx context.Context, Id uint) (res *model.TestContactInfoInfoRes, err error)
Add(ctx context.Context, req *test.TestContactInfoAddReq) (err error)
Edit(ctx context.Context, req *test.TestContactInfoEditReq) (err error)
Delete(ctx context.Context, Id []uint) (err error)
}
var localTestContactInfo ITestContactInfo
func TestContactInfo() ITestContactInfo {
if localTestContactInfo == nil {
panic("implement not found for interface ITestContactInfo, forgot register?")
}
return localTestContactInfo
}
func RegisterTestContactInfo(i ITestContactInfo) {
localTestContactInfo = i
}

View File

@ -0,0 +1,37 @@
// ==========================================================================
// GFast自动生成service操作代码。
// 生成日期2023-09-01 16:38:07
// 生成路径: internal/app/test/service/test_follow_info.go
// 生成人yqq
// desc:跟进信息
// company:云南奇讯科技有限公司
// ==========================================================================
package service
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
)
type ITestFollowInfo interface {
List(ctx context.Context, req *test.TestFollowInfoSearchReq) (res *test.TestFollowInfoSearchRes, err error)
GetById(ctx context.Context, Id uint) (res *model.TestFollowInfoInfoRes, err error)
Add(ctx context.Context, req *test.TestFollowInfoAddReq) (err error)
Edit(ctx context.Context, req *test.TestFollowInfoEditReq) (err error)
Delete(ctx context.Context, Id []uint) (err error)
}
var localTestFollowInfo ITestFollowInfo
func TestFollowInfo() ITestFollowInfo {
if localTestFollowInfo == nil {
panic("implement not found for interface ITestFollowInfo, forgot register?")
}
return localTestFollowInfo
}
func RegisterTestFollowInfo(i ITestFollowInfo) {
localTestFollowInfo = i
}

View File

@ -0,0 +1,37 @@
// ==========================================================================
// GFast自动生成service操作代码。
// 生成日期2023-09-01 17:51:42
// 生成路径: internal/app/test/service/test_owner_info.go
// 生成人yqq
// desc:业主方基本情况
// company:云南奇讯科技有限公司
// ==========================================================================
package service
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
)
type ITestOwnerInfo interface {
List(ctx context.Context, req *test.TestOwnerInfoSearchReq) (res *test.TestOwnerInfoSearchRes, err error)
GetById(ctx context.Context, Id uint) (res *model.TestOwnerInfoInfoRes, err error)
Add(ctx context.Context, req *test.TestOwnerInfoAddReq) (err error)
Edit(ctx context.Context, req *test.TestOwnerInfoEditReq) (err error)
Delete(ctx context.Context, Id []uint) (err error)
}
var localTestOwnerInfo ITestOwnerInfo
func TestOwnerInfo() ITestOwnerInfo {
if localTestOwnerInfo == nil {
panic("implement not found for interface ITestOwnerInfo, forgot register?")
}
return localTestOwnerInfo
}
func RegisterTestOwnerInfo(i ITestOwnerInfo) {
localTestOwnerInfo = i
}

View File

@ -0,0 +1,37 @@
// ==========================================================================
// GFast自动生成service操作代码。
// 生成日期2023-09-01 16:15:09
// 生成路径: internal/app/test/service/test_project_info.go
// 生成人yqq
// desc:项目备案信息
// company:云南奇讯科技有限公司
// ==========================================================================
package service
import (
"context"
"github.com/tiger1103/gfast/v3/api/v1/test"
"github.com/tiger1103/gfast/v3/internal/app/test/model"
)
type ITestProjectInfo interface {
List(ctx context.Context, req *test.TestProjectInfoSearchReq) (res *test.TestProjectInfoSearchRes, err error)
GetById(ctx context.Context, Id uint) (res *model.TestProjectInfoInfoRes, err error)
Add(ctx context.Context, req *test.TestProjectInfoAddReq) (err error)
Edit(ctx context.Context, req *test.TestProjectInfoEditReq) (err error)
Delete(ctx context.Context, Id []uint) (err error)
}
var localTestProjectInfo ITestProjectInfo
func TestProjectInfo() ITestProjectInfo {
if localTestProjectInfo == nil {
panic("implement not found for interface ITestProjectInfo, forgot register?")
}
return localTestProjectInfo
}
func RegisterTestProjectInfo(i ITestProjectInfo) {
localTestProjectInfo = i
}