73 lines
2.7 KiB
Go
73 lines
2.7 KiB
Go
// ==========================================================================
|
||
// GFast自动生成controller操作代码。
|
||
// 生成日期:2023-08-14 11:24:31
|
||
// 生成路径: internal/app/wxApplet/controller/bus_labourservice.go
|
||
// 生成人:gfast
|
||
// desc:劳务公司
|
||
// company:云南奇讯科技有限公司
|
||
// ==========================================================================
|
||
|
||
package controller
|
||
|
||
import (
|
||
"context"
|
||
"github.com/tiger1103/gfast/v3/api/wxApplet/wxApplet"
|
||
systemController "github.com/tiger1103/gfast/v3/internal/app/system/controller"
|
||
"github.com/tiger1103/gfast/v3/internal/app/wxApplet/service"
|
||
)
|
||
|
||
type busLabourserviceController struct {
|
||
systemController.BaseController
|
||
}
|
||
|
||
var BusLabourservice = new(busLabourserviceController)
|
||
|
||
// List 列表
|
||
func (c *busLabourserviceController) List(ctx context.Context, req *wxApplet.BusLabourserviceSearchReq) (res *wxApplet.BusLabourserviceSearchRes, err error) {
|
||
res, err = service.BusLabourservice().List(ctx, req)
|
||
return
|
||
}
|
||
|
||
// Get 获取劳务公司
|
||
func (c *busLabourserviceController) Get(ctx context.Context, req *wxApplet.BusLabourserviceGetReq) (res *wxApplet.BusLabourserviceGetRes, err error) {
|
||
res = new(wxApplet.BusLabourserviceGetRes)
|
||
res.BusLabourserviceInfoRes, err = service.BusLabourservice().GetById(ctx, req.Id)
|
||
return
|
||
}
|
||
|
||
// Add 添加劳务公司
|
||
func (c *busLabourserviceController) Add(ctx context.Context, req *wxApplet.BusLabourserviceAddReq) (res *wxApplet.BusLabourserviceAddRes, err error) {
|
||
err = service.BusLabourservice().Add(ctx, req)
|
||
return
|
||
}
|
||
|
||
// Edit 修改劳务公司
|
||
func (c *busLabourserviceController) Edit(ctx context.Context, req *wxApplet.BusLabourserviceEditReq) (res *wxApplet.BusLabourserviceEditRes, err error) {
|
||
err = service.BusLabourservice().Edit(ctx, req)
|
||
return
|
||
}
|
||
|
||
// Delete 删除劳务公司
|
||
func (c *busLabourserviceController) Delete(ctx context.Context, req *wxApplet.BusLabourserviceDeleteReq) (res *wxApplet.BusLabourserviceDeleteRes, err error) {
|
||
err = service.BusLabourservice().Delete(ctx, req.Ids)
|
||
return
|
||
}
|
||
|
||
// PcAdd pc劳务公司资料新增
|
||
func (c *busLabourserviceController) PcAdd(ctx context.Context, req *wxApplet.BusPcAddReq) (res *wxApplet.BusPcAddRes, err error) {
|
||
err = service.BusLabourservice().PcAdd(ctx, req)
|
||
return
|
||
}
|
||
|
||
// PcDel pc劳务公司资料删除
|
||
func (c *busLabourserviceController) PcDel(ctx context.Context, req *wxApplet.BusPcDelReq) (res *wxApplet.BusPcDelRes, err error) {
|
||
err = service.BusLabourservice().PcDel(ctx, req)
|
||
return
|
||
}
|
||
|
||
// PcFind pc劳务公司资料查询
|
||
func (c *busLabourserviceController) PcFind(ctx context.Context, req *wxApplet.BusPcFindReq) (res *wxApplet.BusPcFindRes, err error) {
|
||
res, err = service.BusLabourservice().PcFind(ctx, req)
|
||
return
|
||
}
|