set image container & chg blog

This commit is contained in:
박서은
2025-06-18 15:35:02 +09:00
parent 4f48fcb91b
commit 17e6235c99
2 changed files with 99 additions and 95 deletions
@@ -14,6 +14,7 @@ import com.won.smarketing.content.presentation.dto.SnsContentCreateRequest;
import com.won.smarketing.content.presentation.dto.SnsContentCreateResponse;
import com.won.smarketing.content.presentation.dto.SnsContentSaveRequest;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.multipart.MultipartFile;
@@ -34,6 +35,9 @@ public class SnsContentService implements SnsContentUseCase {
private final AiContentGenerator aiContentGenerator;
private final BlobStorageService blobStorageService;
@Value("${azure.storage.container.poster-images:content-images}")
private String contentImageContainer;
/**
* SNS 콘텐츠 생성
*
@@ -45,7 +49,7 @@ public class SnsContentService implements SnsContentUseCase {
public SnsContentCreateResponse generateSnsContent(SnsContentCreateRequest request, List<MultipartFile> files) {
//파일들 주소 가져옴
if(files != null) {
List<String> urls = blobStorageService.uploadImage(files, "containerName");
List<String> urls = blobStorageService.uploadImage(files, contentImageContainer);
request.setImages(urls);
}