# NightAuditLogS3Controller.java

    package cloud.wconnect.frontoffice.controller.nightauditlog;

    import cloud.wconnect.commonlib.annotation.ApiId;
    import cloud.wconnect.commonlib.pojo.query.s3.DownloadFileUrlQuery;
    import cloud.wconnect.commonlib.pojo.query.s3.UploadFileUrlQuery;
    import cloud.wconnect.commonlib.util.S3ControllerUtil;
    import jakarta.validation.Valid;
    import org.springframework.beans.factory.annotation.Autowired;
    import org.springframework.web.bind.annotation.GetMapping;
    import org.springframework.web.bind.annotation.RequestMapping;
    import org.springframework.web.bind.annotation.RestController;

    import java.util.Map;

    /**
     * S3 控制层
     *
     * @author lichen
     * @date 2023/11/2
     */
    @RestController
    @RequestMapping("/night-audit-log")
    public class NightAuditLogS3Controller {

        @Autowired
        private S3ControllerUtil s3ControllerUtil;

        /**
         * 获取s3下载文件的url
         *
         * @param downloadFileUrlQuery 查询对象
         * @return java.util.Map
         * @author lichen
         * @date 2023/11/2
         */
        @ApiId(1462)
        @GetMapping("/s3/download-file-url")
        public Map getDownloadFileUrl(@Valid DownloadFileUrlQuery downloadFileUrlQuery) {
            return s3ControllerUtil.getDownloadFileUrl(downloadFileUrlQuery);
        }

        /**
         * 获取s3上传文件的url
         *
         * @param property           资产标识
         * @param uploadFileUrlQuery 查询对象
         * @return java.util.Map
         * @author lichen
         * @date 2023/11/2
         */
        @ApiId(1463)
        @GetMapping("/s3/upload-file-url")
        public Map getUploadFileUrl(String tenant, String property, @Valid UploadFileUrlQuery uploadFileUrlQuery) {
            return s3ControllerUtil.getUploadFileUrl(tenant, property, uploadFileUrlQuery);
        }

    }