作者 陈志颖

fix:分红预算仓储增加产品ID检索条件

... ... @@ -317,6 +317,9 @@ func (repository *DividendsEstimateRepository) Find(queryOptions map[string]inte
if dividendsTypes, ok := queryOptions["dividendsTypes"]; ok && len(dividendsTypes.([]int32)) > 0 {
query.Where("dividends_type in (?)", pg.In(dividendsTypes.([]int32)))
}
if orderGoodId, ok := queryOptions["orderGoodId"]; ok && orderGoodId.(int64) != 0 {
query.Where("order_good_id = ?", orderGoodId)
}
if dividendsEstimateOrderNumber, ok := queryOptions["dividendsEstimateOrderNumber"]; ok && dividendsEstimateOrderNumber != "" {
query.Where("dividends_estimate_order_number ilike ?", fmt.Sprintf("%%%s%%", dividendsEstimateOrderNumber))
}
... ...