// Copyright (c) Shenyang Leading Edge Intelligent Technology Co., Ltd. All rights reserved.
|
|
|
|
package me
|
|
|
|
import (
|
|
"LAPP_ACURA_MOM_BACKEND/dao/me/implments"
|
|
"LAPP_ACURA_MOM_BACKEND/grmi"
|
|
model "LAPP_ACURA_MOM_BACKEND/models/me"
|
|
"github.com/go-xorm/xorm"
|
|
)
|
|
|
|
/******************************************************************************
|
|
*
|
|
* @Interface Name : ProductFamilyRelateDAO
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : ProductFamilyRelate的数据访问对象接口
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
type ProductFamilyRelateDAO interface {
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : InsertOne
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 插入一条ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 需要插入的ProductFamilyRelate
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-26 14:38:54
|
|
*
|
|
******************************************************************************/
|
|
InsertOne(*model.ProductFamilyRelate) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : DeleteOne
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 删除指定键的ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 主键
|
|
*
|
|
* @Function Parameters : 主键
|
|
*
|
|
* @Function Parameters : 主键
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
DeleteOne(string, string, string) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : SelectOne
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 查找指定键的ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 主键
|
|
*
|
|
* @Function Parameters : 主键
|
|
*
|
|
* @Function Parameters : 主键
|
|
*
|
|
* @Return Value : 查找到的ProductFamilyRelate
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
SelectOne(string, string, string) (*model.ProductFamilyRelate, error)
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : UpdateOne
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 修改ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 需要修改的ProductFamilyRelate
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
UpdateOne(*model.ProductFamilyRelate) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : Insert
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 插入多条ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 需要插入的ProductFamilyRelate列表
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
Insert(*[]model.ProductFamilyRelate) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : Delete
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 删除多条ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 需要删除的ProductFamilyRelate列表
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
Delete(*[]model.ProductFamilyRelate) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : DeleteWhere
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 按条件删除ProductFamilyRelate
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
DeleteWhere([]grmi.Predicate) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : Select
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 按条件查询ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 查询条件
|
|
*
|
|
* @Function Parameters : 排序字段
|
|
*
|
|
* @Return Value : 查询结果
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-26 14:38:54
|
|
*
|
|
******************************************************************************/
|
|
Select([]grmi.Predicate, []grmi.Field) ([]model.ProductFamilyRelate, error)
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : SelectAndPaging
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 按条件查询ProductFamilyRelate并分页
|
|
*
|
|
* @Function Parameters : 分页信息
|
|
*
|
|
* @Function Parameters : 查询条件
|
|
*
|
|
* @Function Parameters : 排序字段
|
|
*
|
|
* @Return Value : 查询结果
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
SelectAndPaging(*grmi.Paging, []grmi.Predicate, []grmi.Field) (grmi.PagingResult, error)
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : Update
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 修改多条ProductFamilyRelate
|
|
*
|
|
* @Function Parameters : 需要修改的ProductFamilyRelate列表
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
Update(*[]model.ProductFamilyRelate) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : UpdateWhere
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 按条件修改ProductFamilyRelate
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
UpdateWhere([]grmi.Predicate, *model.ProductFamilyRelate, ...string) error
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : SelectProductByFamilyId
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 通过项目ID和配置ID查询所有绑定的产品
|
|
*
|
|
* @Function Parameters : 项目ID
|
|
*
|
|
* @Function Parameters : 配置ID
|
|
*
|
|
* @Return Value : []model.Product
|
|
*
|
|
* @Return Value :执行时发生的错误
|
|
*
|
|
* @Author : zhangxin
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
SelectProductByFamilyId(projectId string, familyId string) ([]model.Product, error)
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : SelectProductByFamilyIdForCreateSerialOrder
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 通过项目ID和配置ID查询所有绑定的产品
|
|
*
|
|
* @Function Parameters : 项目ID
|
|
*
|
|
* @Function Parameters : 配置ID
|
|
*
|
|
* @Return Value : []model.Product
|
|
*
|
|
* @Return Value :执行时发生的错误
|
|
*
|
|
* @Author : zhangxin
|
|
*
|
|
* @Date : 2021-12-08
|
|
*
|
|
******************************************************************************/
|
|
SelectProductByFamilyIdForCreateSerialOrder(projectId string, familyId string) ([]model.Product, error)
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : GetMaxPos
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 获取packOrderId下最大的pos
|
|
*
|
|
* @Return Value : max pos
|
|
*
|
|
* @Return Value : 执行时发生的错误
|
|
*
|
|
* @Author : zhangxin
|
|
*
|
|
* @Date : 2021-11-01
|
|
*
|
|
******************************************************************************/
|
|
GetMaxPos(shipOrderId string) (int, error)
|
|
}
|
|
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : NewProductFamilyRelateDAO
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 创建一个ProductFamilyRelateDAO实例
|
|
*
|
|
* @Function Parameters : xorm会话
|
|
*
|
|
* @Function Parameters : 基本主键
|
|
*
|
|
* @Return Value : ProductFamilyRelateDAO实例
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-10-22 15:30:32
|
|
*
|
|
******************************************************************************/
|
|
func NewProductFamilyRelateDAO(session *xorm.Session, plantNr int, userid string) ProductFamilyRelateDAO {
|
|
return implments.NewProductFamilyRelateDAOImplement(session, plantNr, userid)
|
|
}
|