Class PhotoHttpImpl
java.lang.Object
io.github.seenings.photo.api.impl.PhotoHttpImpl
- All Implemented Interfaces:
HttpPhotoService
@RestController
@RequestMapping("seen/feign-v1/file/photo")
public class PhotoHttpImpl
extends Object
implements HttpPhotoService
PhotoController
- Since:
- 2022-12-31
- Author:
- chixuehui
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionphotoIdToFileName(Set<Integer> photoIds) 根据照片ID获取文件名photoIdToLongPhotoUrl(Set<Integer> photoIds) 根据照片ID获取长照片路径(含路径头)photoIdToPhotoUrl(Set<Integer> photoIds) 根据照片ID获取照片路径photoIdToStorageTypeAndPath(Set<Integer> photoIds) 根据照片ID获取文件设置路径setPathByMinio(String path, Long userId) 设置路径
-
Constructor Details
-
PhotoHttpImpl
public PhotoHttpImpl()
-
-
Method Details
-
photoIdToPhotoUrl
@PostMapping("photo-id-to-photo-url") public Map<Integer,String> photoIdToPhotoUrl(@RequestBody Set<Integer> photoIds) 根据照片ID获取照片路径- Specified by:
photoIdToPhotoUrlin interfaceHttpPhotoService- Parameters:
photoIds- 照片ID- Returns:
- 照片ID对应照片路径
-
photoIdToLongPhotoUrl
@PostMapping("photo-id-to-long-photo-url") public Map<Integer,String> photoIdToLongPhotoUrl(@RequestBody Set<Integer> photoIds) 根据照片ID获取长照片路径(含路径头)- Specified by:
photoIdToLongPhotoUrlin interfaceHttpPhotoService- Parameters:
photoIds- 照片ID- Returns:
- 照片ID对应照片路径
- See Also:
-
setPath
@PostMapping("set-path") public Integer setPath(@RequestParam("path") String path, @RequestParam("userId") Long userId) 设置路径- Specified by:
setPathin interfaceHttpPhotoService- Parameters:
path- 路径userId- 用户- Returns:
- 路径ID
-
setPathByMinio
@PostMapping("set-path-minio") public Integer setPathByMinio(@RequestParam("path") String path, @RequestParam("userId") Long userId) 设置路径- Specified by:
setPathByMinioin interfaceHttpPhotoService- Parameters:
path- 路径userId- 用户- Returns:
- 路径ID
-
photoIdToStorageTypeAndPath
@PostMapping("photo-id-to-storage-type-and-path") public Map<Integer, StorageTypeAndPath> photoIdToStorageTypeAndPath(@RequestBody Set<Integer> photoIds) 根据照片ID获取文件- Specified by:
photoIdToStorageTypeAndPathin interfaceHttpPhotoService- Parameters:
photoIds- 照片ID- Returns:
- 照片ID对应文件
-
photoIdToFileName
@PostMapping("photo-id-to-file-name") public Map<Integer,String> photoIdToFileName(@RequestBody Set<Integer> photoIds) 根据照片ID获取文件名- Specified by:
photoIdToFileNamein interfaceHttpPhotoService- Parameters:
photoIds- 照片ID- Returns:
- 照片ID对应文件名
-