weicd
2023-12-01 3bb8a496bb332a45ec71ce622bda039cada1a33a
eladmin-master/eladmin-system/src/main/java/me/zhengjie/modules/task/rest/TaskUserController.java
@@ -15,10 +15,10 @@
*/
package me.zhengjie.modules.task.rest;
import com.alipay.api.domain.ObjectKeyWord;
import me.zhengjie.annotation.Log;
import me.zhengjie.modules.task.domain.TaskUserMongo;
import me.zhengjie.modules.task.service.TaskUserService;
import me.zhengjie.modules.task.service.dto.TaskGenerateDto;
import me.zhengjie.modules.task.service.dto.TaskUserMongoDto;
import me.zhengjie.modules.task.service.dto.TaskUserQueryCriteria;
import me.zhengjie.utils.SecurityUtils;
@@ -31,7 +31,7 @@
import org.springframework.web.bind.annotation.*;
import io.swagger.annotations.*;
import java.io.IOException;
import java.util.Arrays;
import java.text.ParseException;
import javax.servlet.http.HttpServletResponse;
/**
@@ -170,4 +170,25 @@
    public ResponseEntity<Object> getTaskDetail(String taskMongoId) {
        return new ResponseEntity<>(taskUserService.getTaskDetail(taskMongoId),HttpStatus.OK);
    }
    @GetMapping("/getPerformanceg")
    public ResponseEntity<Object> getPerformanceg(String taskHours, Long userId){
        return new ResponseEntity<>(taskUserService.getPerformanceg(taskHours, userId),HttpStatus.OK);
    }
    @GetMapping("/getTaskUserAdvent")
    public ResponseEntity<Object> getTaskUserAdvent(String taskUserMongoId,int page, int size){
        return new ResponseEntity<>(taskUserService.getTaskUserAdvent(taskUserMongoId,page,size),HttpStatus.OK);
    }
    @PostMapping("/generate")
    public ResponseEntity<Object> generate(@RequestBody TaskGenerateDto taskGenerateDto) throws ParseException {
        taskUserService.generate(taskGenerateDto);
        return new ResponseEntity<>(HttpStatus.OK);
    }
    @GetMapping("/exportUser")
    public void exportUser(HttpServletResponse response, String taskId) throws IOException {
        taskUserService.exportUser(response, taskId);
    }
}