|
@ -1,5 +1,7 @@ |
|
|
package com.epmet.controller; |
|
|
package com.epmet.controller; |
|
|
|
|
|
|
|
|
|
|
|
import com.epmet.commons.tools.annotation.LoginUser; |
|
|
|
|
|
import com.epmet.commons.tools.security.dto.TokenDto; |
|
|
import com.epmet.commons.tools.utils.Result; |
|
|
import com.epmet.commons.tools.utils.Result; |
|
|
import com.epmet.commons.tools.validator.ValidatorUtils; |
|
|
import com.epmet.commons.tools.validator.ValidatorUtils; |
|
|
import com.epmet.dto.form.work.*; |
|
|
import com.epmet.dto.form.work.*; |
|
@ -82,8 +84,9 @@ public class WorkActDraftController { |
|
|
* @Date 2020/7/21 17:24 |
|
|
* @Date 2020/7/21 17:24 |
|
|
**/ |
|
|
**/ |
|
|
@PostMapping("preview") |
|
|
@PostMapping("preview") |
|
|
public Result<ActPreviewResultDTO> previewActDetail(@RequestBody ActPreviewFormDTO formDTO){ |
|
|
public Result<ActPreviewResultDTO> previewActDetail(@LoginUser TokenDto tokenDto, @RequestBody ActPreviewFormDTO formDTO){ |
|
|
ValidatorUtils.validateEntity(formDTO,ActPreviewFormDTO.UserInternalGroup.class); |
|
|
ValidatorUtils.validateEntity(formDTO,ActPreviewFormDTO.UserInternalGroup.class); |
|
|
|
|
|
formDTO.setCustomerId(tokenDto.getCustomerId()); |
|
|
ActPreviewResultDTO resultDTO=workActDraftService.previewActDetail(formDTO); |
|
|
ActPreviewResultDTO resultDTO=workActDraftService.previewActDetail(formDTO); |
|
|
return new Result<ActPreviewResultDTO>().ok(resultDTO); |
|
|
return new Result<ActPreviewResultDTO>().ok(resultDTO); |
|
|
} |
|
|
} |
|
|