|
|
@ -364,14 +364,13 @@ func (impl *ArtCheckRuleDAOImplement) SelectByArtId(artId string, projectId stri |
|
|
|
* @Reference LAPP_ACURA_MOM_BACKEND/dao/base/ArtCheckRuleDAO.SelectByArtId |
|
|
|
* |
|
|
|
******************************************************************************/ |
|
|
|
func (impl *ArtCheckRuleDAOImplement) SelectOperationCheckRule(artId string, attrCode int, projectId string, workLineId string) ([]model.ArtCheckRule, error) { |
|
|
|
func (impl *ArtCheckRuleDAOImplement) SelectOperationCheckRule(artId string, attrCode int, projectId string) ([]model.ArtCheckRule, error) { |
|
|
|
result := make([]model.ArtCheckRule, 0) |
|
|
|
parameters := []interface{}{impl.plantNr, attrCode, projectId, workLineId, model.MES_MATCH_ALL, artId} |
|
|
|
where := fmt.Sprintf("%s = ? and %s = ? and %s = ? and %s = ? and ( %s = ? or %s = ? )", |
|
|
|
parameters := []interface{}{impl.plantNr, attrCode, projectId, model.MES_MATCH_ALL, artId} |
|
|
|
where := fmt.Sprintf("%s = ? and %s = ? and %s = ? and ( %s = ? or %s = ? )", |
|
|
|
meta.ArtCheckRule_PlantNr.ColumnName, |
|
|
|
meta.ArtCheckRule_AttriCode.ColumnName, |
|
|
|
meta.ArtCheckRule_ProjectId.ColumnName, |
|
|
|
meta.ArtCheckRule_WorkLineId.ColumnName, |
|
|
|
meta.ArtCheckRule_SubObject.ColumnName, |
|
|
|
meta.ArtCheckRule_SubObject.ColumnName) |
|
|
|
err := impl.session.Table(impl.meta.TableName).Where(where, parameters...).OrderBy(meta.ArtCheckRule_AttriCode.SortColumnName).Find(&result) |
|
|
|