作者 Your Name

修复一些错误

@@ -134,7 +134,7 @@ func (c *PGRewardSummaryStaticService) CreateRewardSummaryByEmployeeProductRecor @@ -134,7 +134,7 @@ func (c *PGRewardSummaryStaticService) CreateRewardSummaryByEmployeeProductRecor
134 "sectionId": param.WorkStation.SectionId, 134 "sectionId": param.WorkStation.SectionId,
135 "workshopId": param.WorkStation.WorkshopId, 135 "workshopId": param.WorkStation.WorkshopId,
136 "workerId": param.ProductWorker.UserId, 136 "workerId": param.ProductWorker.UserId,
137 - "recordDateStr": param.CreatedAt.Format("200-01-02"), 137 + "recordDateStr": param.CreatedAt.Format("2006-01-02"),
138 } 138 }
139 139
140 _, summaryList, err := rewardSummaryRepo.Find(condtion) 140 _, summaryList, err := rewardSummaryRepo.Find(condtion)
@@ -137,6 +137,10 @@ func (repo *RewardSummaryRepository) Find(queryOptions map[string]interface{}) ( @@ -137,6 +137,10 @@ func (repo *RewardSummaryRepository) Find(queryOptions map[string]interface{}) (
137 if v, ok := queryOptions["recordDateStr"]; ok { 137 if v, ok := queryOptions["recordDateStr"]; ok {
138 query.Where("record_date_str=?", v) 138 query.Where("record_date_str=?", v)
139 } 139 }
  140 + //用户id
  141 + if v, ok := queryOptions["workerId"]; ok {
  142 + query.Where(`worker->>'userId'='?'`, v)
  143 + }
140 cnt, err := query.SelectAndCount() 144 cnt, err := query.SelectAndCount()
141 if err != nil { 145 if err != nil {
142 return 0, nil, err 146 return 0, nil, err