|
|
@ -406,8 +406,8 @@ func (impl *ArticleDemandDAOImplement) RefreshArticleDemand() ([]model.ArticleDe |
|
|
|
******************************************************************************/ |
|
|
|
func (impl *ArticleDemandDAOImplement) SelectTop() (*model.ArticleDemand, error) { |
|
|
|
|
|
|
|
parameters := []interface{}{impl.plantNr} |
|
|
|
where := fmt.Sprintf("%s = ?", meta.ArticleDemand_PlantNr.ColumnName) |
|
|
|
parameters := []interface{}{impl.plantNr, 2} |
|
|
|
where := fmt.Sprintf("%s = ? and %s = ?", meta.ArticleDemand_PlantNr.ColumnName, meta.ArticleDemand_Status.ColumnName) |
|
|
|
|
|
|
|
session := impl.session.Table(impl.meta.TableName).Where(where, parameters...) |
|
|
|
session = session.OrderBy(meta.ArticleDemand_PlantNr.ColumnName) |
|
|
|