| | |
| | | import com.vincent.rsf.server.common.domain.KeyValVo; |
| | | import com.vincent.rsf.server.common.domain.PageParam; |
| | | import com.vincent.rsf.server.manager.entity.StockStatistic; |
| | | import com.vincent.rsf.server.manager.enums.TaskType; |
| | | import com.vincent.rsf.server.manager.service.StockStatisticService; |
| | | import com.vincent.rsf.server.system.controller.BaseController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | "COUNT(IF ( task_type = 101, 0, NULL)) out_anfme_count, " + |
| | | "SUM( CASE WHEN task_type = 1 THEN anfme ELSE 0 END ) in_anfme," + |
| | | "SUM( CASE WHEN task_type = 101 THEN anfme ELSE 0 END ) out_anfme"); |
| | | wrapper.groupBy("barcode, day_time"); |
| | | wrapper.in("task_type", Arrays.asList(TaskType.TASK_TYPE_IN.type, TaskType.TASK_TYPE_OUT.type)).groupBy("day_time"); |
| | | return R.ok().add(stockStatisticService.page(pageParam, wrapper)); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | @PreAuthorize("hasAuthority('manager:stockStatistic:list')") |
| | | @PostMapping("/stockStatistic/list") |