|
|
@ -1,6 +1,7 @@ |
|
|
|
package com.ccsens.tall.web; |
|
|
|
|
|
|
|
import com.ccsens.tall.bean.dto.PluginDto; |
|
|
|
import com.ccsens.tall.bean.dto.TaskDto; |
|
|
|
import com.ccsens.tall.bean.dto.WeekMeetingDto; |
|
|
|
import com.ccsens.tall.bean.vo.PluginVo; |
|
|
|
import com.ccsens.tall.bean.vo.TaskVo; |
|
|
@ -9,6 +10,7 @@ import com.ccsens.tall.service.ITaskPluginService; |
|
|
|
import com.ccsens.util.JsonResponse; |
|
|
|
import com.ccsens.util.WebConstant; |
|
|
|
import com.ccsens.util.annotation.OperateType; |
|
|
|
import com.ccsens.util.bean.dto.QueryDto; |
|
|
|
import io.jsonwebtoken.Claims; |
|
|
|
import io.swagger.annotations.*; |
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
@ -222,4 +224,18 @@ public class PluginController { |
|
|
|
log.info("生成每日会议纪要完成"); |
|
|
|
return JsonResponse.newInstance().ok(wpsPath); |
|
|
|
} |
|
|
|
|
|
|
|
@ApiOperation(value = "打开excel", notes = "") |
|
|
|
@ApiImplicitParams({ |
|
|
|
}) |
|
|
|
@RequestMapping(value = "/openExcel", method = RequestMethod.POST, produces = {"application/json;charset=UTF-8"}) |
|
|
|
public JsonResponse<String> openExcel(HttpServletRequest request,@RequestParam(required = true) Long taskId) throws Exception { |
|
|
|
log.info("打开excel:{}",taskId); |
|
|
|
Long currentUserId = Long.valueOf(((Claims) request.getAttribute(WebConstant.REQUEST_KEY_CLAIMS)).getSubject()); |
|
|
|
String authHeader = request.getHeader(WebConstant.HEADER_KEY_TOKEN); |
|
|
|
String token = authHeader.substring(WebConstant.HEADER_KEY_TOKEN_PREFIX.length()); |
|
|
|
String path = taskPluginService.openExcel(taskId,token,currentUserId); |
|
|
|
log.info("excel的路径:{}",path); |
|
|
|
return JsonResponse.newInstance().ok(path); |
|
|
|
} |
|
|
|
} |
|
|
|