作者 陈志颖

feat:增加任务名称模糊匹配

... ... @@ -1598,7 +1598,7 @@ func (cashPoolService *CashPoolService) ListExchangeCashPersonById(exportExchang
}
}
// TODO 员工兑换清单榜单
// 员工兑换清单榜单
func (cashPoolService *CashPoolService) ExchangeListRanking(exchangeListRankingQuery *query.ExchangeListRankingQuery) (interface{}, error) {
if err := exchangeListRankingQuery.ValidateCommand(); err != nil {
return nil, application.ThrowError(application.ARG_ERROR, err.Error())
... ...
... ... @@ -77,7 +77,7 @@ func (dao *CashPoolDao) CalculateActivityExchangedSuMoney(activityId int64) (map
}, nil
}
// TODO 返回兑换清单榜单
// 返回兑换清单榜单
func (dao *CashPoolDao) ExchangeCashListRanking(queryOptions map[string]interface{}) (map[string]interface{}, error) {
var retPeople []struct {
Uid int
... ...
... ... @@ -155,6 +155,10 @@ func (repository *TaskRepository) Find(queryOptions map[string]interface{}) (int
if taskContentMatch, ok := queryOptions["taskContentMatch"]; ok && (taskContentMatch != "") {
query = query.Where("task.task_name LIKE ?", fmt.Sprintf("%%%s%%", taskContentMatch.(string)))
}
if taskNameMatch, ok := queryOptions["taskNameMatch"]; ok && (taskNameMatch != "") {
query = query.Where("task.task_name LIKE ?", fmt.Sprintf("%%%s%%", taskNameMatch.(string)))
query = query.Where("task.task_type IN (?)", pg.In([]int{1, 2}))
}
if isRewardTake, ok := queryOptions["isRewardTake"]; ok && (isRewardTake != false) {
query = query.Where(`task.is_reward_take = ?`, isRewardTake)
}
... ...