提交 c40fbf42 作者: panda

删除多余System.out.println

上级 5cf48e37
...@@ -18,6 +18,7 @@ import io.swagger.annotations.Api; ...@@ -18,6 +18,7 @@ import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam; import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams; import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import springfox.documentation.annotations.ApiIgnore; import springfox.documentation.annotations.ApiIgnore;
...@@ -36,6 +37,7 @@ import java.util.*; ...@@ -36,6 +37,7 @@ import java.util.*;
@Api(tags = {"上传文件"}) @Api(tags = {"上传文件"})
@RestController @RestController
@RequestMapping("/upload") @RequestMapping("/upload")
@Slf4j
public class UploadController { public class UploadController {
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd/"); SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd/");
...@@ -174,7 +176,7 @@ public class UploadController { ...@@ -174,7 +176,7 @@ public class UploadController {
.build(OssConstant.ENDPOINT, OssConstant.ACCESSKEYID, OssConstant.ACCESSKEYSECRET); .build(OssConstant.ENDPOINT, OssConstant.ACCESSKEYID, OssConstant.ACCESSKEYSECRET);
List list = new LinkedList(); List list = new LinkedList();
if (uploadFile != null && uploadFile.length > 0) { if (uploadFile != null && uploadFile.length > 0) {
System.out.println("osses文件数量" + uploadFile.length); log.info("osses文件数量" + uploadFile.length);
for (int i = 0; i < uploadFile.length; i++) { for (int i = 0; i < uploadFile.length; i++) {
MultipartFile file = uploadFile[i]; MultipartFile file = uploadFile[i];
InputStream inputStream = null; InputStream inputStream = null;
...@@ -236,7 +238,7 @@ public class UploadController { ...@@ -236,7 +238,7 @@ public class UploadController {
clientBuilderConfiguration); clientBuilderConfiguration);
List list = new LinkedList(); List list = new LinkedList();
if (uploadFile != null && uploadFile.length > 0) { if (uploadFile != null && uploadFile.length > 0) {
System.out.println("osses文件数量" + uploadFile.length); log.info("osses文件数量" + uploadFile.length);
for (int i = 0; i < uploadFile.length; i++) { for (int i = 0; i < uploadFile.length; i++) {
MultipartFile file = uploadFile[i]; MultipartFile file = uploadFile[i];
InputStream inputStream = null; InputStream inputStream = null;
...@@ -257,7 +259,7 @@ public class UploadController { ...@@ -257,7 +259,7 @@ public class UploadController {
+ UUID.randomUUID().toString() + UUID.randomUUID().toString()
+ oldName.substring(oldName.lastIndexOf("."), oldName.length()); + oldName.substring(oldName.lastIndexOf("."), oldName.length());
ossClient.putObject(OssConstant.BUCKET, newName, bis); ossClient.putObject(OssConstant.BUCKET, newName, bis);
System.out.println("视频名称:" + newName); log.info("视频名称:" + newName);
list.add("https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName); list.add("https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName);
} }
} }
...@@ -300,7 +302,7 @@ public class UploadController { ...@@ -300,7 +302,7 @@ public class UploadController {
clientBuilderConfiguration); clientBuilderConfiguration);
Map map = new HashMap(); Map map = new HashMap();
if (uploadFile != null && uploadFile.length > 0) { if (uploadFile != null && uploadFile.length > 0) {
System.out.println("osses文件数量" + uploadFile.length); log.info("osses文件数量" + uploadFile.length);
for (int i = 0; i < uploadFile.length; i++) { for (int i = 0; i < uploadFile.length; i++) {
MultipartFile file = uploadFile[i]; MultipartFile file = uploadFile[i];
InputStream inputStream = null; InputStream inputStream = null;
...@@ -321,7 +323,7 @@ public class UploadController { ...@@ -321,7 +323,7 @@ public class UploadController {
+ UUID.randomUUID().toString() + UUID.randomUUID().toString()
+ oldName.substring(oldName.lastIndexOf("."), oldName.length()); + oldName.substring(oldName.lastIndexOf("."), oldName.length());
ossClient.putObject(OssConstant.BUCKET, newName, bis); ossClient.putObject(OssConstant.BUCKET, newName, bis);
System.out.println("视频名称:" + newName); log.info("视频名称:" + newName);
map.put( map.put(
"filePath", "filePath",
"https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName); "https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName);
...@@ -360,7 +362,7 @@ public class UploadController { ...@@ -360,7 +362,7 @@ public class UploadController {
.build(OssConstant.ENDPOINT, OssConstant.ACCESSKEYID, OssConstant.ACCESSKEYSECRET); .build(OssConstant.ENDPOINT, OssConstant.ACCESSKEYID, OssConstant.ACCESSKEYSECRET);
List list = new LinkedList(); List list = new LinkedList();
if (uploadFile != null && uploadFile.length > 0) { if (uploadFile != null && uploadFile.length > 0) {
System.out.println("osses文件数量" + uploadFile.length); log.info("osses文件数量" + uploadFile.length);
for (int i = 0; i < uploadFile.length; i++) { for (int i = 0; i < uploadFile.length; i++) {
MultipartFile file = uploadFile[i]; MultipartFile file = uploadFile[i];
InputStream inputStream = null; InputStream inputStream = null;
...@@ -382,7 +384,7 @@ public class UploadController { ...@@ -382,7 +384,7 @@ public class UploadController {
+ UUID.randomUUID().toString() + UUID.randomUUID().toString()
+ oldName.substring(oldName.lastIndexOf("."), oldName.length()); + oldName.substring(oldName.lastIndexOf("."), oldName.length());
ossClient.putObject(OssConstant.BUCKET, newName, bis); ossClient.putObject(OssConstant.BUCKET, newName, bis);
System.out.println("图片名称:" + newName); log.info("图片名称:" + newName);
list.add("https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName); list.add("https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName);
} }
} }
...@@ -438,7 +440,7 @@ public class UploadController { ...@@ -438,7 +440,7 @@ public class UploadController {
+ UUID.randomUUID().toString() + UUID.randomUUID().toString()
+ oldName.substring(oldName.lastIndexOf("."), oldName.length()); + oldName.substring(oldName.lastIndexOf("."), oldName.length());
ossClient.putObject(OssConstant.BUCKET, newName, bis); ossClient.putObject(OssConstant.BUCKET, newName, bis);
System.out.println("图片名称:" + newName); log.info("图片名称:" + newName);
list.add("https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName); list.add("https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName);
} }
} }
...@@ -471,7 +473,7 @@ public class UploadController { ...@@ -471,7 +473,7 @@ public class UploadController {
.build(OssConstant.ENDPOINT, OssConstant.ACCESSKEYID, OssConstant.ACCESSKEYSECRET); .build(OssConstant.ENDPOINT, OssConstant.ACCESSKEYID, OssConstant.ACCESSKEYSECRET);
Map map = new HashMap(); Map map = new HashMap();
if (uploadFile != null && uploadFile.length > 0) { if (uploadFile != null && uploadFile.length > 0) {
System.out.println("osses文件数量" + uploadFile.length); log.info("osses文件数量" + uploadFile.length);
for (int i = 0; i < uploadFile.length; i++) { for (int i = 0; i < uploadFile.length; i++) {
MultipartFile file = uploadFile[i]; MultipartFile file = uploadFile[i];
InputStream inputStream = null; InputStream inputStream = null;
...@@ -493,7 +495,7 @@ public class UploadController { ...@@ -493,7 +495,7 @@ public class UploadController {
+ UUID.randomUUID().toString() + UUID.randomUUID().toString()
+ oldName.substring(oldName.lastIndexOf("."), oldName.length()); + oldName.substring(oldName.lastIndexOf("."), oldName.length());
ossClient.putObject(OssConstant.BUCKET, newName, bis); ossClient.putObject(OssConstant.BUCKET, newName, bis);
System.out.println("图片名称:" + newName); log.info("图片名称:" + newName);
map.put( map.put(
"filePath", "filePath",
"https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName); "https://" + OssConstant.BUCKET + '.' + OssConstant.ENDPOINT + "/" + newName);
......
...@@ -22,6 +22,7 @@ import com.mmc.pms.model.sale.vo.QueryClassifyVO; ...@@ -22,6 +22,7 @@ import com.mmc.pms.model.sale.vo.QueryClassifyVO;
import com.mmc.pms.page.PageResult; import com.mmc.pms.page.PageResult;
import com.mmc.pms.service.BackstageTaskService; import com.mmc.pms.service.BackstageTaskService;
import com.mmc.pms.service.CategoriesService; import com.mmc.pms.service.CategoriesService;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -38,6 +39,7 @@ import java.util.stream.Collectors; ...@@ -38,6 +39,7 @@ import java.util.stream.Collectors;
* @createDate 2023-05-24 10:29:28 * @createDate 2023-05-24 10:29:28
*/ */
@Service @Service
@Slf4j
public class CategoriesServiceImpl implements CategoriesService { public class CategoriesServiceImpl implements CategoriesService {
@Autowired private CategoriesDao categoriesDao; @Autowired private CategoriesDao categoriesDao;
@Resource private GoodsInfoDao goodsInfoDao; @Resource private GoodsInfoDao goodsInfoDao;
...@@ -252,7 +254,7 @@ public class CategoriesServiceImpl implements CategoriesService { ...@@ -252,7 +254,7 @@ public class CategoriesServiceImpl implements CategoriesService {
.collect(Collectors.toList()); .collect(Collectors.toList());
Map<Integer, List<CategoriesInfoListDTO>> categoryMap = getCategoryMap(allCategoryDTOList); Map<Integer, List<CategoriesInfoListDTO>> categoryMap = getCategoryMap(allCategoryDTOList);
addSubCategories(allCategoryDTOList, categoryMap); addSubCategories(allCategoryDTOList, categoryMap);
System.out.println("Res: " + JSONObject.toJSON(allCategoryDTOList)); log.info("Res: " + JSONObject.toJSON(allCategoryDTOList));
return allCategoryDTOList; return allCategoryDTOList;
} }
return null; return null;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论