|
@@ -1522,7 +1522,7 @@ func GetReportFieldsByIds(ids []int, fields []string) (items []*Report, err erro
|
|
// GetReportListByClassifyId 根据分类id 获取报告列表
|
|
// GetReportListByClassifyId 根据分类id 获取报告列表
|
|
func GetReportListByClassifyId(classifyId int) (items []*Report, err error) {
|
|
func GetReportListByClassifyId(classifyId int) (items []*Report, err error) {
|
|
o := orm.NewOrmUsingDB("rddp")
|
|
o := orm.NewOrmUsingDB("rddp")
|
|
- sql := `SELECT * FROM report WHERE classify_id_first = ? classify_id_second = ? or classify_id_third = ?`
|
|
|
|
|
|
+ sql := `SELECT * FROM report WHERE classify_id_first = ? or classify_id_second = ? or classify_id_third = ?`
|
|
_, err = o.Raw(sql, classifyId, classifyId, classifyId).QueryRows(&items)
|
|
_, err = o.Raw(sql, classifyId, classifyId, classifyId).QueryRows(&items)
|
|
return items, err
|
|
return items, err
|
|
}
|
|
}
|