Quellcode durchsuchen

Merge remote-tracking branch 'origin/develop' into jsh77b

tsit14 vor 4 Jahren
Ursprung
Commit
07043f6fd9
28 geänderte Dateien mit 723 neuen und 301 gelöschten Zeilen
  1. 9 0
      src/main/java/com/style24/admin/biz/dao/TsaEnvsetDao.java
  2. 13 7
      src/main/java/com/style24/admin/biz/dao/TsaGoodsDao.java
  3. 9 0
      src/main/java/com/style24/admin/biz/dao/TsaReviewDao.java
  4. 4 0
      src/main/java/com/style24/admin/biz/service/TsaEnvsetService.java
  5. 42 31
      src/main/java/com/style24/admin/biz/service/TsaGoodsService.java
  6. 11 0
      src/main/java/com/style24/admin/biz/service/TsaReviewService.java
  7. 79 56
      src/main/java/com/style24/admin/biz/web/TsaGoodsController.java
  8. 14 15
      src/main/java/com/style24/admin/biz/web/TsaMarketingController.java
  9. 22 12
      src/main/java/com/style24/admin/biz/web/TsaStockController.java
  10. 5 0
      src/main/java/com/style24/persistence/domain/AdKeyword.java
  11. 9 0
      src/main/java/com/style24/persistence/mybatis/shop/TsaEnvset.xml
  12. 45 19
      src/main/java/com/style24/persistence/mybatis/shop/TsaGoods.xml
  13. 59 1
      src/main/java/com/style24/persistence/mybatis/shop/TsaReview.xml
  14. 26 1
      src/main/webapp/WEB-INF/views/display/MainGnbContentsPopupForm.html
  15. 4 0
      src/main/webapp/WEB-INF/views/envset/CustomerGradePolicyForm.html
  16. 20 13
      src/main/webapp/WEB-INF/views/goods/GoodsAdKeywordForm.html
  17. 2 2
      src/main/webapp/WEB-INF/views/goods/GoodsDetailSizeStockForm.html
  18. 13 12
      src/main/webapp/WEB-INF/views/goods/GoodsEpSkipForm.html
  19. 17 11
      src/main/webapp/WEB-INF/views/goods/GoodsImageForm.html
  20. 101 25
      src/main/webapp/WEB-INF/views/goods/GoodsNaverPriceForm.html
  21. 112 30
      src/main/webapp/WEB-INF/views/goods/GoodsNoticeForm.html
  22. 18 11
      src/main/webapp/WEB-INF/views/goods/GoodsReserveSellForm.html
  23. 16 0
      src/main/webapp/WEB-INF/views/marketing/CouponPopupForm.html
  24. 1 1
      src/main/webapp/WEB-INF/views/marketing/ReviewDetailForm.html
  25. 5 1
      src/main/webapp/WEB-INF/views/marketing/ReviewForm.html
  26. 65 51
      src/main/webapp/WEB-INF/views/stock/GoodsSizeStockForm.html
  27. 1 1
      src/main/webapp/WEB-INF/views/system/MenuForm.html
  28. 1 1
      src/main/webapp/dx5/dextuploadx5-configuration.js

+ 9 - 0
src/main/java/com/style24/admin/biz/dao/TsaEnvsetDao.java

@@ -32,6 +32,15 @@ public interface TsaEnvsetDao {
 	 */
 	Collection<Envset> getEnvsetList(Envset envset);
 
+	/**
+	 * 회원등급정책PK 건수
+	 * @param policy - 회원등급정책 정보
+	 * @return
+	 * @author gagamel
+	 * @since 2021. 7. 25
+	 */
+	int getCustomerGradePolicyPrimaryKeyCount(CustGradePolicy policy);
+
 	/**
 	 * 회원등급정책 저장
 	 * @param policy - 회원등급정책 정보

+ 13 - 7
src/main/java/com/style24/admin/biz/dao/TsaGoodsDao.java

@@ -204,7 +204,6 @@ public interface TsaGoodsDao {
 	 */
 	Collection<GagaMap> getGoodsInfoExcelList(GoodsSearch goodsSearch);
 
-
 	/**
 	 * 상품 이미지 필수 항목 입력 여부 조회
 	 *
@@ -862,7 +861,7 @@ public interface TsaGoodsDao {
 	 * @since 2021. 07. 09
 	 */
 	Collection<GagaMap> getGoodsNaverExcelList(GoodsSearch goodsSearch);
-	
+
 	/**
 	 * 상품 네이버 최저가 최종 작업일
 	 *
@@ -1050,6 +1049,15 @@ public interface TsaGoodsDao {
 	 */
 	public void createGoodsImage(GoodsImg goodsImg);
 
+	/**
+	 * 상품기본이미지명 조회
+	 * @param goodsImg - 상품이미지 정보
+	 * @throws
+	 * @author eskim
+	 * @since 2021. 07. 25
+	 */
+	public String getGoodsDefaultImageName(GoodsImg goodsImg);
+
 	/**
 	 * 사은품 목록
 	 *
@@ -1101,7 +1109,7 @@ public interface TsaGoodsDao {
 	 * @since 2021. 01. 05
 	 */
 	public void saveGoodsWmsIncomelot(WmsGoods wmsGoods);
-	
+
 	/**
 	 *  WMS 입고상품  상품 구분 저장
 	 * @param wmsGoods
@@ -1292,7 +1300,7 @@ public interface TsaGoodsDao {
 	 * @since 2021. 07. 04
 	 */
 	int getBrandSupplyCount(Brand brand);
-	
+
 	/**
 	 * 상품 색상, 사이즈 정보 조회
 	 *
@@ -1302,7 +1310,7 @@ public interface TsaGoodsDao {
 	 * @since 2021. 07. 05
 	 */
 	Goods getGoodsColorSize(Goods goods);
-	
+
 	/**
 	 * 상품 대표색상 설정
 	 *
@@ -1353,7 +1361,6 @@ public interface TsaGoodsDao {
 	 */
 	void updateGoodsContents(GoodsContents goodsContents);
 
-	
 	/**
 	 * 상품 상세 컨텐츠 상품 저장
 	 *
@@ -1364,7 +1371,6 @@ public interface TsaGoodsDao {
 	 */
 	void saveGoodsContent(GoodsContentsData goodsContentsData);
 
-	
 	/**
 	 * 상품 상세 컨텐츠 상품 삭제
 	 *

+ 9 - 0
src/main/java/com/style24/admin/biz/dao/TsaReviewDao.java

@@ -15,6 +15,15 @@ import com.style24.persistence.domain.ReviewAttach;
 @ShopDs
 public interface TsaReviewDao {
 
+	/**
+	 * 상품평 총건수
+	 * @param review - 상품평 정보
+	 * @return
+	 * @author gagamel
+	 * @since 2021. 7. 24
+	 */
+	int getReviewTotalCount(Review review);
+
 	/**
 	 * 상품평 목록
 	 * @param review - 상품평 정보

+ 4 - 0
src/main/java/com/style24/admin/biz/service/TsaEnvsetService.java

@@ -79,6 +79,10 @@ public class TsaEnvsetService {
 	 * @since 2021. 1. 7
 	 */
 	public void createCustomerGradePolicy(CustGradePolicy policy) {
+		if (policy.getMode().equals("N") && envsetDao.getCustomerGradePolicyPrimaryKeyCount(policy) > 0) {
+			throw new IllegalStateException("이미 등록된 정책이 있습니다.(사이트: " + policy.getSiteCd() + ", 회원등급: " + policy.getGradeCd() + ")");
+		}
+
 		policy.setRegNo(TsaSession.getInfo().getUserNo());
 		policy.setUpdNo(TsaSession.getInfo().getUserNo());
 		envsetDao.createCustomerGradePolicy(policy);

+ 42 - 31
src/main/java/com/style24/admin/biz/service/TsaGoodsService.java

@@ -1116,7 +1116,7 @@ public class TsaGoodsService {
 			goodsSafeNo.setCertType(goods.getCertType());
 			goodsSafeNo.setCertNum(goods.getCertNum());
 			log.info("goodsSafeNo ==>{}", goodsSafeNo);
-			this.saveGoodsDetailCertNum(goodsSafeNo);	
+			this.saveGoodsDetailCertNum(goodsSafeNo);
 		}
 
 		// 상품 구매등급 적용
@@ -2774,7 +2774,7 @@ public class TsaGoodsService {
 			freeGoods.setUpdNo(TsaSession.getInfo().getUserNo());
 			freeGoods.setRegNo(TsaSession.getInfo().getUserNo());
 			goodsDao.saveFreeGoods(freeGoods);
-		
+
 		}
 	}
 
@@ -4071,38 +4071,37 @@ public class TsaGoodsService {
 		goodsContents.setUpdNo(TsaSession.getInfo().getUserNo());
 
 		//신규이미지가 있을 경우
-		if(!StringUtils.isEmpty(goodsContents.getNewImgPath())){
-            String displayUploadPath = env.getProperty("upload.default.target.path");
-            displayUploadPath = GagaFileUtil.getConcatenationPath(displayUploadPath, "goodscontents");
-            File file = new File(GagaFileUtil.getConcatenationPath(displayUploadPath, goodsContents.getNewImgPath()));
-
-            String yearMonth = GagaDateUtil.getToday().substring(0, 6);
-            displayUploadPath = GagaFileUtil.getConcatenationPath(displayUploadPath, yearMonth); 
-            log.info("displayUploadPath {}", displayUploadPath);
-            
-            File contentsPath = new File(displayUploadPath);
+		if (!StringUtils.isEmpty(goodsContents.getNewImgPath())) {
+			String displayUploadPath = env.getProperty("upload.default.target.path");
+			displayUploadPath = GagaFileUtil.getConcatenationPath(displayUploadPath, "goodscontents");
+			File file = new File(GagaFileUtil.getConcatenationPath(displayUploadPath, goodsContents.getNewImgPath()));
+
+			String yearMonth = GagaDateUtil.getToday().substring(0, 6);
+			displayUploadPath = GagaFileUtil.getConcatenationPath(displayUploadPath, yearMonth);
+			log.info("displayUploadPath {}", displayUploadPath);
+
+			File contentsPath = new File(displayUploadPath);
 			if (!contentsPath.exists()) {
 				contentsPath.mkdir();
 			}
-			
-            String newFilename = "GOODSCONTENTS_" + GagaDateUtil.getTodayDateTime() + "." + org.springframework.util.StringUtils.getFilenameExtension(goodsContents.getNewImgPath());
-            File uniqueFile = GagaFileUtil.getUniqueFile(new File(GagaFileUtil.getConcatenationPath(displayUploadPath, newFilename)));
-            
-
-            // 기존이미지 삭제
-            try{
-                GagaFileUtil.deleteFile(GagaFileUtil.getConcatenationPath(displayUploadPath, goodsContents.getImgPath()));
-            }catch (IOException e){
-                //  nothing
-                log.info("[saveGoodsContent 기존 이미지 삭제중 error]");
-                //e.printStackTrace();
-            }
-           
-            // Rename a file
-            file.renameTo(uniqueFile);
-
-            goodsContents.setImgPath("/goodscontents/"+ yearMonth +'/'+ newFilename);
-        }
+
+			String newFilename = "GOODSCONTENTS_" + GagaDateUtil.getTodayDateTime() + "." + org.springframework.util.StringUtils.getFilenameExtension(goodsContents.getNewImgPath());
+			File uniqueFile = GagaFileUtil.getUniqueFile(new File(GagaFileUtil.getConcatenationPath(displayUploadPath, newFilename)));
+
+			// 기존이미지 삭제
+			try {
+				GagaFileUtil.deleteFile(GagaFileUtil.getConcatenationPath(displayUploadPath, goodsContents.getImgPath()));
+			} catch (IOException e) {
+				//  nothing
+				log.info("[saveGoodsContent 기존 이미지 삭제중 error]");
+				//e.printStackTrace();
+			}
+
+			// Rename a file
+			file.renameTo(uniqueFile);
+
+			goodsContents.setImgPath("/goodscontents/" + yearMonth + '/' + newFilename);
+		}
 
 		log.info("saveGoodsContent  =={}", goodsContents);
 		// 신규 일때
@@ -4167,4 +4166,16 @@ public class TsaGoodsService {
 
 	}
 
+	/**
+	 * 상품기본이미지명 조회
+	 *
+	 * @param notice
+	 * @return
+	 * @author eskim
+	 * @since 2021. 07. 25
+	 */
+	public String getGoodsDefaultImageName(GoodsImg goodsImg) {
+		return goodsDao.getGoodsDefaultImageName(goodsImg);
+	}
+
 }

+ 11 - 0
src/main/java/com/style24/admin/biz/service/TsaReviewService.java

@@ -30,6 +30,17 @@ public class TsaReviewService {
 	@Autowired
 	private TscEnvsetService envsetService;
 
+	/**
+	 * 상품평 총건수
+	 * @param review - 상품평 정보
+	 * @return
+	 * @author gagamel
+	 * @since 2021. 7. 24
+	 */
+	public int getReviewTotalCount(Review review) {
+		return reviewDao.getReviewTotalCount(review);
+	}
+
 	/**
 	 * 상품평 목록
 	 * @param review - 상품평 정보

+ 79 - 56
src/main/java/com/style24/admin/biz/web/TsaGoodsController.java

@@ -152,7 +152,7 @@ public class TsaGoodsController extends TsaBaseController {
 	@PostMapping("/itemkind/base/list")
 	@ResponseBody
 	public Collection<Itemkind> getItemkindList(@RequestBody Itemkind itemkind) {
-		
+
 		// multi row 검색관련 처리
 		if (!StringUtils.isBlank(itemkind.getSearchItemkindCd())) {
 			itemkind.setMultiItemkindCd(itemkind.getSearchItemkindCd().replaceAll("\r", "").trim().split("\n"));
@@ -160,7 +160,7 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(itemkind.getSearchItemkindNm())) {
 			itemkind.setMultiItemkindNm(itemkind.getSearchItemkindNm().replaceAll("\r", "").trim().split("\n"));
 		}
-		
+
 		return goodsService.getItemkindList(itemkind);
 	}
 
@@ -533,12 +533,6 @@ public class TsaGoodsController extends TsaBaseController {
 		// multi row 검색관련 처리
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
-
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
-			}
 		}
 		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
 			try {
@@ -559,7 +553,7 @@ public class TsaGoodsController extends TsaBaseController {
 				throw new IllegalStateException("업체코드 검색중 오류로 인해 조회되지 않았습니다.");
 			}
 		}
-		
+
 		if (!StringUtils.isBlank(goodsSearch.getItemkindList())) {
 			try {
 				String[] arrItemkind = mapper.readValue(goodsSearch.getItemkindList(), String[].class);
@@ -609,11 +603,6 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
-			}
 		}
 
 		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
@@ -1591,7 +1580,7 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSupplyPrice.getCondition())) {
 			goodsSupplyPrice.setConditionList(goodsSupplyPrice.getCondition().replaceAll("\r", "").trim().split("\n"));
 		}
-		
+
 		if (!StringUtils.isBlank(goodsSupplyPrice.getBrandList())) {
 			try {
 				String[] arrBrandCd = mapper.readValue(goodsSupplyPrice.getBrandList(), String[].class);
@@ -1611,8 +1600,7 @@ public class TsaGoodsController extends TsaBaseController {
 				throw new IllegalStateException("업체코드 검색중 오류로 인해 조회되지 않았습니다.");
 			}
 		}
-		
-		
+
 		return goodsService.getGoodsSupplyPriceList(goodsSupplyPrice);
 	}
 
@@ -1786,7 +1774,7 @@ public class TsaGoodsController extends TsaBaseController {
 	@PostMapping("/video/list")
 	@ResponseBody
 	public Collection<GoodsVideo> getGoodsVideoList(@RequestBody GoodsVideo goodsVideo) {
-		
+
 		// multi row 검색관련 처리
 		if (!StringUtils.isBlank(goodsVideo.getCondition())) {
 			goodsVideo.setConditionList(goodsVideo.getCondition().replaceAll("\r", "").trim().split("\n"));
@@ -1802,7 +1790,7 @@ public class TsaGoodsController extends TsaBaseController {
 				throw new IllegalStateException("브랜드코드 검색중 오류로 인해 조회되지 않았습니다.");
 			}
 		}
-		
+
 		return goodsService.getGoodsVideoList(goodsVideo);
 	}
 
@@ -2038,11 +2026,6 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
-			}
 		}
 		goodsSearch.setPageable(new TscPageRequest(goodsSearch.getPageNo() - 1, goodsSearch.getPageSize()));
 		goodsSearch.getPageable().setTotalCount(goodsService.getReinboundInformCount(goodsSearch));
@@ -2177,11 +2160,6 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
-			}
 		}
 
 		goodsSearch.setRegNo(TsaSession.getInfo().getUserNo()); // 엑셀조회시 로그인 사용자의 엑셀 상품조회시 사용
@@ -2281,6 +2259,25 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 		}
+		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
+			try {
+				String[] arrBrandCd = mapper.readValue(goodsSearch.getBrandList(), String[].class);
+				goodsSearch.setMultiBrand(arrBrandCd);
+			} catch (Exception e) {
+				e.printStackTrace();
+				throw new IllegalStateException("브랜드코드 검색중 오류로 인해 조회되지 않았습니다.");
+			}
+		}
+
+		if (!StringUtils.isBlank(goodsSearch.getSupplyCompList())) {
+			try {
+				String[] arrSupplyComp = mapper.readValue(goodsSearch.getSupplyCompList(), String[].class);
+				goodsSearch.setMultiSupplyCompCd(arrSupplyComp);
+			} catch (Exception e) {
+				e.printStackTrace();
+				throw new IllegalStateException("업체코드 검색중 오류로 인해 조회되지 않았습니다.");
+			}
+		}
 
 		return goodsService.getNoticeList(goodsSearch);
 	}
@@ -2404,11 +2401,6 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
-			}
 		}
 		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
 			try {
@@ -2429,7 +2421,7 @@ public class TsaGoodsController extends TsaBaseController {
 				throw new IllegalStateException("업체코드 검색중 오류로 인해 조회되지 않았습니다.");
 			}
 		}
-		
+
 		if (!StringUtils.isBlank(goodsSearch.getItemkindList())) {
 			try {
 				String[] arrItemkind = mapper.readValue(goodsSearch.getItemkindList(), String[].class);
@@ -2439,7 +2431,7 @@ public class TsaGoodsController extends TsaBaseController {
 				throw new IllegalStateException("품목 검색중 오류로 인해 조회되지 않았습니다.");
 			}
 		}
-		
+
 		//log.info("[getPopupGoodsList] goodsSearch=>{}", goodsSearch);
 		goodsSearch.setRegNo(TsaSession.getInfo().getUserNo()); // 엑셀조회시 로그인 사용자의 엑셀 상품조회시 사용
 		goodsSearch.setPageable(new TscPageRequest(goodsSearch.getPageNo() - 1, goodsSearch.getPageSize()));
@@ -2510,12 +2502,6 @@ public class TsaGoodsController extends TsaBaseController {
 		// multi row 검색관련 처리
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
-
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
-			}
 		}
 
 		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
@@ -2680,10 +2666,25 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
+		}
+
+		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
+			try {
+				String[] arrBrandCd = mapper.readValue(goodsSearch.getBrandList(), String[].class);
+				goodsSearch.setMultiBrand(arrBrandCd);
+			} catch (Exception e) {
+				e.printStackTrace();
+				throw new IllegalStateException("브랜드코드 검색중 오류로 인해 조회되지 않았습니다.");
+			}
+		}
+
+		if (!StringUtils.isBlank(goodsSearch.getSupplyCompList())) {
+			try {
+				String[] arrSupplyComp = mapper.readValue(goodsSearch.getSupplyCompList(), String[].class);
+				goodsSearch.setMultiSupplyCompCd(arrSupplyComp);
+			} catch (Exception e) {
+				e.printStackTrace();
+				throw new IllegalStateException("업체코드 검색중 오류로 인해 조회되지 않았습니다.");
 			}
 		}
 
@@ -2732,11 +2733,6 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 
-			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("EXTEND");
-			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
-				goodsSearch.setSearchGb("MASTER");
-			}
 		}
 
 		log.info("[goodsSearch] ={}", goodsSearch);
@@ -2778,6 +2774,13 @@ public class TsaGoodsController extends TsaBaseController {
 	@PostMapping("/ad/keyword/list")
 	@ResponseBody
 	public Collection<AdKeyword> getAdKeywordList(@RequestBody AdKeyword adKeyword) {
+
+		// multi row 검색관련 처리
+		if (!StringUtils.isBlank(adKeyword.getCondition())) {
+			adKeyword.setConditionList(adKeyword.getCondition().replaceAll("\r", "").trim().split("\n"));
+
+		}
+
 		return goodsService.getAdKeywordList(adKeyword);
 	}
 
@@ -3327,7 +3330,7 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(ifIncomelot.getCondition())) {
 			ifIncomelot.setConditionList(ifIncomelot.getCondition().replaceAll("\r", "").trim().split("\n"));
 		}
-		
+
 		ifIncomelot.setPageable(new TscPageRequest(ifIncomelot.getPageNo() - 1, ifIncomelot.getPageSize()));
 		ifIncomelot.getPageable().setTotalCount(goodsService.getGoodsWmsIncomelotSkuListCount(ifIncomelot));
 
@@ -3435,7 +3438,7 @@ public class TsaGoodsController extends TsaBaseController {
 		return result;
 
 	}
-	
+
 	/**
 	 * 상품 상세 컨텐츠 화면
 	 *
@@ -3446,10 +3449,10 @@ public class TsaGoodsController extends TsaBaseController {
 	@GetMapping("/contents/form")
 	public ModelAndView detailContentsForm() {
 		ModelAndView mav = new ModelAndView();
-		
+
 		// 상품상세노출컨텐츠유형
 		mav.addObject("goodsContentsTypeList", rendererService.getAvailCommonCodeList("G086"));
-		
+
 		mav.setViewName("goods/GoodsContentsForm");
 
 		return mav;
@@ -3476,7 +3479,7 @@ public class TsaGoodsController extends TsaBaseController {
 		if (!StringUtils.isBlank(goodsSearch.getCondition())) {
 			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").trim().split("\n"));
 		}
-		
+
 		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
 			try {
 				String[] arrBrandCd = mapper.readValue(goodsSearch.getBrandList(), String[].class);
@@ -3561,4 +3564,24 @@ public class TsaGoodsController extends TsaBaseController {
 		return mav;
 	}
 
+	/**
+	 * 상품기본이미지URL 조회
+	 * @param
+	 * @return
+	 * @author eskim
+	 * @since 2021. 07. 25
+	 */
+	@GetMapping("/default/image/url")
+	@ResponseBody
+	public String getGoodsDefaultImageUrl(GoodsImg goodsImg) {
+		// 상품기본이미지명 조회
+		String defaultImgNm = goodsService.getGoodsDefaultImageName(goodsImg);
+
+		if (!StringUtils.isEmpty(defaultImgNm)) {
+			return GagaFileUtil.getConcatenationPath(env.getProperty("upload.goods.view"), defaultImgNm);
+		}
+
+		return "";
+	}
+
 }

+ 14 - 15
src/main/java/com/style24/admin/biz/web/TsaMarketingController.java

@@ -206,12 +206,12 @@ public class TsaMarketingController extends TsaBaseController {
 			review.setGoodsCds(review.getGoodsCd().replaceAll("\r", "").split("\n"));
 		}
 
+		review.setPageable(new TscPageRequest(review.getPageNo() - 1, review.getPageSize()));
+		review.getPageable().setTotalCount(reviewService.getReviewTotalCount(review));
+
 		// 상품평 목록
 		Collection<Review> reviewList = reviewService.getReviewList(review);
 
-		review.setPageable(new TscPageRequest(review.getPageNo() - 1, review.getPageSize()));
-		review.getPageable().setTotalCount(reviewList.size());
-
 		result.set("paging", review);
 		result.set("dataList", reviewList);
 
@@ -832,7 +832,7 @@ public class TsaMarketingController extends TsaBaseController {
 			mav.addObject("tmtbMstInfo", morebetterService.getMorebetterMstInfo(tmtbSeq));
 			mav.addObject("tmtbSupplyCompList", morebetterService.getMorebetterSupplyCompList(tmtbSeq, "G260_13"));
 			mav.addObject("tmtbBrandList", morebetterService.getMorebetterBrandList(tmtbSeq, "G260_12"));
-			mav.addObject("tmtbDefaultGoodsList", morebetterService.getMorebetterApplyGoodsList(tmtbSeq, "G260_10" , "G800_10"));
+			mav.addObject("tmtbDefaultGoodsList", morebetterService.getMorebetterApplyGoodsList(tmtbSeq, "G260_10", "G800_10"));
 			mav.addObject("tmtbApplyGoodsList", morebetterService.getMorebetterApplyGoodsList(tmtbSeq, "G260_10", "G800_20"));
 			mav.addObject("tmtbExceptGoodsList", morebetterService.getMorebetterExceptGoodsList(tmtbSeq, "G260_10"));
 			mav.addObject("tmtbSectionValList", morebetterService.getMorebetterSectionValList(tmtbSeq));
@@ -1455,7 +1455,7 @@ public class TsaMarketingController extends TsaBaseController {
 	@PostMapping("/point/save")
 	@ResponseBody
 	public GagaResponse savePoint(@RequestBody Point point) {
-		if (point.getCustNo() == null || point.getCustNo() <= 0 ) {
+		if (point.getCustNo() == null || point.getCustNo() <= 0) {
 			throw new IllegalStateException("고객정보가 없습니다.");
 		}
 		Integer userNo = TsaSession.getInfo().getUserNo();
@@ -1752,7 +1752,6 @@ public class TsaMarketingController extends TsaBaseController {
 
 			// 상위제휴채널 조회
 			mav.addObject("upperAfLinkCdList", rendererService.getAvailCommonCodeList("G053"));
-			
 
 		} else if (param.getMode().equals("U")) { // 상세 일 때
 			mav.addObject("planInfo", planService.getPlanDetailInfo(param));
@@ -1776,7 +1775,7 @@ public class TsaMarketingController extends TsaBaseController {
 
 			// 상위제휴채널 조회
 			mav.addObject("upperAfLinkCdList", rendererService.getAvailCommonCodeList("G053"));
-			
+
 			// 선택한 회원유형
 			mav.addObject("gbList", planService.getPlanCustGbList(param));
 
@@ -1786,7 +1785,7 @@ public class TsaMarketingController extends TsaBaseController {
 
 		// 사이트 목록
 		mav.addObject("siteList", rendererService.getAvailCommonCodeList("G000"));
-		
+
 		// 카테고리 리스트
 		mav.addObject("cateList", planService.getPlanningCategoryList(param));
 
@@ -2577,7 +2576,7 @@ public class TsaMarketingController extends TsaBaseController {
 		socialService.deleteSocialGoods(paramList);
 		return super.ok(message.getMessage("SUCC_0003"));
 	}
-	
+
 	/**
 	 * 출석체크 쿠폰 유효 확인
 	 *
@@ -2654,7 +2653,7 @@ public class TsaMarketingController extends TsaBaseController {
 		}
 		return super.ok(message.getMessage("SUCC_0001"));
 	}
-	
+
 	/**
 	 * 소셜쇼핑관리 화면
 	 *
@@ -2664,16 +2663,16 @@ public class TsaMarketingController extends TsaBaseController {
 	@GetMapping("/shot/delivery/form")
 	public ModelAndView shotDeliveryForm() {
 		ModelAndView mav = new ModelAndView();
-		
+
 		// 코너유형목록
 		mav.addObject("cornerDispTypeList", rendererService.getCommonCodeList("G045", "Y"));
 		// 상품상태
 		mav.addObject("goodsStatList", rendererService.getCommonCodeList("G008", "Y"));
-		
+
 		mav.setViewName("marketing/ShotDeliveryForm");
 		return mav;
 	}
-	
+
 	/**
 	 * 총알배송 브랜드 그룹 목록
 	 *
@@ -2721,7 +2720,7 @@ public class TsaMarketingController extends TsaBaseController {
 		result.set("brandGoodsList", planService.getShotBrandGoodsList(plan));
 		return result;
 	}
-	
+
 	/**
 	 * 총알배송 브랜드 상품추가
 	 *
@@ -2735,7 +2734,7 @@ public class TsaMarketingController extends TsaBaseController {
 		planService.saveShotBrandGoods(paramList);
 		return super.ok(message.getMessage("SUCC_0001"));
 	}
-	
+
 	/**
 	 * 총알배송 브랜드 상품 삭제
 	 *

+ 22 - 12
src/main/java/com/style24/admin/biz/web/TsaStockController.java

@@ -63,7 +63,7 @@ public class TsaStockController extends TsaBaseController {
 
 	@Autowired
 	private ObjectMapper mapper;
-	
+
 	private static final int EXCEL_ROW_COUNT = 500;
 
 	/**
@@ -94,7 +94,7 @@ public class TsaStockController extends TsaBaseController {
 		mav.addObject("seasonList", rendererService.getAvailCommonCodeList("G006"));
 		// 년도
 		int toYear = Integer.parseInt(GagaDateUtil.getToday("yyyy")) - 4;
-		mav.addObject("styleYearList", rendererService.getYearList(toYear,0,5));
+		mav.addObject("styleYearList", rendererService.getYearList(toYear, 0, 5));
 		// 사용여부
 		mav.addObject("useYnList", rendererService.getAvailCommonCodeList("G002"));
 		// 품목
@@ -135,7 +135,7 @@ public class TsaStockController extends TsaBaseController {
 		// multi row 검색관련 처리
 		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
 			try {
-				String [] arrBrandCd = mapper.readValue(goodsSearch.getBrandList(), String[].class);
+				String[] arrBrandCd = mapper.readValue(goodsSearch.getBrandList(), String[].class);
 				goodsSearch.setMultiBrand(arrBrandCd);
 			} catch (Exception e) {
 				e.printStackTrace();
@@ -145,14 +145,24 @@ public class TsaStockController extends TsaBaseController {
 
 		if (!StringUtils.isBlank(goodsSearch.getSupplyCompList())) {
 			try {
-				String [] arrSupplyComp = mapper.readValue(goodsSearch.getSupplyCompList(), String[].class);
+				String[] arrSupplyComp = mapper.readValue(goodsSearch.getSupplyCompList(), String[].class);
 				goodsSearch.setMultiSupplyCompCd(arrSupplyComp);
 			} catch (Exception e) {
 				e.printStackTrace();
 				throw new IllegalStateException(message.getMessage("업체코드 검색중 오류로 인해 조회되지 않았습니다."));
 			}
 		}
-		
+
+		if (!StringUtils.isBlank(goodsSearch.getItemkindList())) {
+			try {
+				String[] arrItemkind = mapper.readValue(goodsSearch.getItemkindList(), String[].class);
+				goodsSearch.setMultiItemkindCd(arrItemkind);
+			} catch (Exception e) {
+				e.printStackTrace();
+				throw new IllegalStateException("품목 검색중 오류로 인해 조회되지 않았습니다.");
+			}
+		}
+
 		//log.info("[goodsSearch] goodsSearch =>{}", goodsSearch);
 		goodsSearch.setRegNo(TsaSession.getInfo().getUserNo());	//엑셀조회시 로그인 사용자의 엑셀 상품조회시 사용
 		goodsSearch.setPageable(new TscPageRequest(goodsSearch.getPageNo() - 1, goodsSearch.getPageSize()));
@@ -190,7 +200,7 @@ public class TsaStockController extends TsaBaseController {
 		// multi row 검색관련 처리
 		if (!StringUtils.isBlank(goodsSearch.getBrandList())) {
 			try {
-				String [] arrBrandCd = mapper.readValue(goodsSearch.getBrandList(), String[].class);
+				String[] arrBrandCd = mapper.readValue(goodsSearch.getBrandList(), String[].class);
 				goodsSearch.setMultiBrand(arrBrandCd);
 			} catch (Exception e) {
 				e.printStackTrace();
@@ -200,7 +210,7 @@ public class TsaStockController extends TsaBaseController {
 
 		if (!StringUtils.isBlank(goodsSearch.getSupplyCompList())) {
 			try {
-				String [] arrSupplyComp = mapper.readValue(goodsSearch.getSupplyCompList(), String[].class);
+				String[] arrSupplyComp = mapper.readValue(goodsSearch.getSupplyCompList(), String[].class);
 				goodsSearch.setMultiSupplyCompCd(arrSupplyComp);
 			} catch (Exception e) {
 				e.printStackTrace();
@@ -210,7 +220,7 @@ public class TsaStockController extends TsaBaseController {
 		goodsSearch.setRegNo(TsaSession.getInfo().getUserNo());	//엑셀조회시 로그인 사용자의 엑셀 상품조회시 사용
 		goodsSearch.setPageable(new TscPageRequest(goodsSearch.getPageNo() - 1, goodsSearch.getPageSize()));
 		goodsSearch.getPageable().setTotalCount(stockService.getGoodsSizeStockCount(goodsSearch));
-		
+
 		// 대용량엑셀파일다운로드는 이런 식으로 ...
 		stockService.getGoodsSizeStockExcelList(goodsSearch, excelFilenameWithPath);
 
@@ -234,17 +244,17 @@ public class TsaStockController extends TsaBaseController {
 
 		String targetPath = GagaFileUtil.getConcatenationPath(env.getProperty("upload.excel.target.path"), "excel");
 		// DB 처리 시 사용되는 파라미터명(셀명) 설정
-		String[] cellName = { "brandEnm", "goodsNm", "itemkindCd","goodsStat","goodsCd", "optCd", "optCd1", "optCd2",  "soldoutYn",
-								"currStockQty", "baseStockQty","saleStockQty", "ableStockQty"};
+		String[] cellName = {"brandEnm", "goodsNm", "itemkindCd", "goodsStat", "goodsCd", "optCd", "optCd1", "optCd2", "soldoutYn",
+			"currStockQty", "baseStockQty", "saleStockQty", "ableStockQty"};
 		//log.info("[saveGoodsSizeSoldoutExcelupload]targetPath = >{}", targetPath);
 		//log.info("[saveGoodsSizeSoldoutExcelupload]getExcelFileNm = >{}", GagaFileUtil.getConcatenationPath(targetPath, goods.getExcelFileNm()));
 		Collection<GagaMap> ecxelGoodsList = GagaExcelUtil.getList(GagaFileUtil.getConcatenationPath(targetPath, goods.getExcelFileNm()), 0, cellName, 0);
 
 		//건수
 		if (ecxelGoodsList != null && ecxelGoodsList.size() > EXCEL_ROW_COUNT) {
-			throw new IllegalStateException("엑셀 파일의 건수를 " +EXCEL_ROW_COUNT + "건 이하로 사용하세요.");
+			throw new IllegalStateException("엑셀 파일의 건수를 " + EXCEL_ROW_COUNT + "건 이하로 사용하세요.");
 		}
-		
+
 		Collection<Option> goodsSizeList = new ArrayList<>();
 		for (GagaMap map : ecxelGoodsList) {
 			Option tmpGoods = mapper.convertValue(map, Option.class);

+ 5 - 0
src/main/java/com/style24/persistence/domain/AdKeyword.java

@@ -2,6 +2,7 @@ package com.style24.persistence.domain;
 
 import java.util.Collection;
 
+import com.fasterxml.jackson.annotation.JsonFormat;
 import com.style24.persistence.TscBaseDomain;
 
 import lombok.Data;
@@ -26,6 +27,10 @@ public class AdKeyword extends TscBaseDomain {
 	private String stDate;
 	private String edDate;
 
+	private String condition; // 키워드 종류별 값
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] conditionList;
+
 	private String goodsList;
 	private Collection<AdKeywordGoods> goodsListNew;
 }

+ 9 - 0
src/main/java/com/style24/persistence/mybatis/shop/TsaEnvset.xml

@@ -61,6 +61,15 @@
 		ORDER  BY ENVSET_SQ DESC
 	</select>
 
+	<!-- 회원등급정책PK 건수 -->
+	<select id="getCustomerGradePolicyPrimaryKeyCount" parameterType="CustGradePolicy" resultType="int">
+		/* TsaSystem.getCustomerGradePolicyPrimaryKeyCount */
+		SELECT COUNT(*) AS CNT
+		FROM   TB_CUST_GRADE_POLICY
+		WHERE  SITE_CD = #{siteCd}
+		AND    GRADE_CD = #{gradeCd}
+	</select>
+	
 	<!-- 회원등급정책 생성 -->
 	<insert id="createCustomerGradePolicy" parameterType="CustGradePolicy">
 		/* TsaEnvset.createCustomerGradePolicy */

+ 45 - 19
src/main/java/com/style24/persistence/mybatis/shop/TsaGoods.xml

@@ -2636,18 +2636,35 @@
 		                                            )
 		                                      )
 		                   )
+		                   
 		</if>
-		<if test="supplyCompCd != null and supplyCompCd  != ''">
+		<if test="multiSupplyCompCd != null and multiSupplyCompCd != ''">
 		AND A.NOTICE_SQ IN (
 		                    SELECT NOTICE_SQ
 		                    FROM TB_NOTICE_GOODS
 		                    WHERE GOODS_CD IN (
 		                                       SELECT GOODS_CD 
 		                                       FROM TB_GOODS 
-		                                       WHERE SUPPLY_COMP_CD = #{supplyCompCd}
-		                                       <if test="brandCd != null and brandCd  != ''">
-		                                       AND BRAND_CD = #{brandCd} 
-		                                       </if>
+		                                       WHERE 1 = 1
+		                                       AND SUPPLY_COMP_CD IN
+		                                       <foreach collection="multiSupplyCompCd" item="item" index="index"  open="(" close=")" separator=",">
+		                                       #{item}
+		                                       </foreach>
+		                                      )
+		                   )
+		</if>
+		<if test="multiBrand != null and multiBrand != ''">
+		AND A.NOTICE_SQ IN (
+		                    SELECT NOTICE_SQ
+		                    FROM TB_NOTICE_GOODS
+		                    WHERE GOODS_CD IN (
+		                                       SELECT GOODS_CD 
+		                                       FROM TB_GOODS 
+		                                       WHERE 1 = 1
+		                                       AND BRAND_CD IN
+		                                       <foreach collection="multiBrand" item="item" index="index"  open="(" close=")" separator=",">
+		                                       #{item}
+		                                       </foreach>
 		                                      )
 		                   )
 		</if>
@@ -3324,13 +3341,6 @@
 		                   )
 		        </if>
 		        WHERE 1=1
-		        <if test="mdNo != null and mdNo != ''">
-		        AND G.BRAND_CD IN (
-		                           SELECT DISTINCT BRAND_CD
-		                           FROM TB_BRAND_MD
-		                           WHERE MD_NO = CAST(#{mdNo} AS UNSIGNED)
-		                          )
-		        </if>
 		        <if test="searchGb == null or searchGb =='BASIC' " >
 		        <include refid="getGoodsListCondition_sql"/>
 		        ORDER BY GE.REQ_YMD, G.GOODS_CD
@@ -3542,12 +3552,15 @@
 		<if test="adKeyword != null and adKeyword !=''">
 		AND LOWER(A.AD_KEYWORD) LIKE CONCAT(LOWER(#{adKeyword}),'%')
 		</if>
-		<if test='goodsCd != null and goodsCd != "" '>
+		<if test='conditionList != null and conditionList.length>0'>
 		AND A.AD_KEYWORD_SQ IN (
-		                    SELECT AD_KEYWORD_SQ
-		                    FROM TB_AD_KEYWORD_GOODS
-		                    WHERE GOODS_CD = #{goodsCd}
-		                        )
+		                        SELECT AD_KEYWORD_SQ
+		                        FROM TB_AD_KEYWORD_GOODS
+		                        WHERE GOODS_CD IN
+		                           <foreach collection="conditionList" item="item" index="index"  open="(" close=")" separator=",">
+		                       #{item}
+		                           </foreach>
+		                       )
 		</if>
 		ORDER  BY A.AD_KEYWORD_SQ DESC
 	</select>
@@ -3871,6 +3884,18 @@
 		)
 	</insert>
 	
+	<!-- 상품기본이미지명 조회 -->
+	<select id="getGoodsDefaultImageName" parameterType="GoodsImg" resultType="String">
+		/* AdmGoods.getGoodsDefaultImageName */
+		SELECT SYS_IMG_NM
+		FROM   TB_GOODS_IMG
+		WHERE  GOODS_CD = #{goodsCd}
+		AND    COLOR_CD = #{colorCd}
+		AND    DEFAULT_IMG_YN = 'Y'
+		AND    EXTMALL_IMG_YN = 'N'
+		LIMIT 1
+	</select>
+	
 	<!-- 사은품 목록 -->
 	<select id="getFreeGoodsList" parameterType="GoodsSearch" resultType="FreeGoods">
 		/* TsaGoods.getFreeGoodsList */
@@ -3887,6 +3912,7 @@
 		     , DATE_FORMAT(G.UPD_DT,'%Y%m%d%H%i%S') AS UPD_DT
 		FROM TB_FREE_GOODS G
 		INNER JOIN TB_BRAND B ON G.BRAND_CD = B.BRAND_CD 
+		INNER JOIN TB_BRAND_SUPPLY BS ON G.BRAND_CD = BS.BRAND_CD
 		WHERE 1 = 1
 		<if test='conditionList != null and conditionList.length>0'>
 		    <choose>
@@ -3909,8 +3935,8 @@
 		      </otherwise>
 		    </choose>
 		</if>
-		<if test="brandCd != null and brandCd != ''">
-		AND B.BRAND_CD = #{brandCd}
+		<if test="supplyCompCd != null and supplyCompCd != ''">
+		AND BS.SUPPLY_COMP_CD = #{supplyCompCd}
 		</if>
 		<if test="multiBrand != null and multiBrand != ''">
 		AND B.BRAND_CD IN

+ 59 - 1
src/main/java/com/style24/persistence/mybatis/shop/TsaReview.xml

@@ -2,6 +2,48 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.style24.admin.biz.dao.TsaReviewDao">
 
+	<!--상품평 총건수  -->
+	<select id="getReviewTotalCount" parameterType="Review" resultType="int">
+		/* TsaReview.getReviewTotalCount */
+		SELECT COUNT(*) AS CNT
+		FROM   TB_REVIEW R
+		     , TB_CUSTOMER C
+		     , TB_GOODS G
+		WHERE  R.CUST_NO = C.CUST_NO
+		AND    R.GOODS_CD = G.GOODS_CD
+		AND    R.DEL_YN = 'N'
+		<if test="goodsCds != null and goodsCds != ''">
+		AND    (
+		        <foreach collection="goodsCds" item="item" index="index" separator="or">
+		        R.GOODS_CD LIKE CONCAT(UPPER(#{item}),'%') 
+		        </foreach>
+		       )
+		</if>
+		<if test="startDt != null and startDt != ''">
+		AND    R.REG_DT <![CDATA[>=]]> STR_TO_DATE(#{startDt},'%Y-%m-%d')
+		</if>
+		<if test="endDt != null and endDt != ''">
+		AND    R.REG_DT <![CDATA[<]]> DATE_ADD(STR_TO_DATE(#{endDt},'%Y-%m-%d'),INTERVAL 1 DAY)
+		</if>
+		<if test="reviewGb != null and reviewGb != ''">
+		AND    R.REVIEW_GB = #{reviewGb}
+		</if>
+		<if test="pntGiveStat != null and pntGiveStat != ''">
+		AND    R.PNT_GIVE_STAT = #{pntGiveStat}
+		</if>
+		<if test="dispYn != null and dispYn != ''">
+		AND    R.DISP_YN = #{dispYn}
+		</if>
+		<if test="searchTxt != null and searchTxt != ''">
+		    <if test="searchGb == 'memNm'">
+		AND    UPPER(C.CUST_NM) LIKE CONCAT(UPPER(#{searchTxt}),'%')
+		    </if>
+		    <if test="searchGb == 'email'">
+		AND    UPPER(C.EMAIL) LIKE CONCAT(UPPER(#{searchTxt}),'%')
+		    </if>
+		</if>
+	</select>
+	
 	<!--상품평 목록  -->
 	<select id="getReviewList" parameterType="Review" resultType="Review">
 		/* TsaReview.getReviewList */
@@ -15,7 +57,22 @@
 		        AND    DEFAULT_IMG_YN = 'Y' /*디폴트이미지*/
 		        LIMIT 1
 		       )                                        AS GOODS_IMG      /*상품이미지*/
-		     , R.REVIEW_GB                                                /*상품평구분*/
+		     , CASE WHEN R.REVIEW_GB = 'P' THEN
+		                (SELECT CASE WHEN MOVIE_CNT > 0 AND IMG_CNT = 0 THEN 'M' /*영상*/
+		                             WHEN MOVIE_CNT = 0 AND IMG_CNT > 0 THEN 'I' /*포토*/
+		                             ELSE 'P' /*포토+영상*/
+		                        END
+		                 FROM   (
+		                         SELECT SUM(CASE WHEN FILE_GB = 'M' THEN 1 ELSE 0 END) AS MOVIE_CNT
+		                              , SUM(CASE WHEN FILE_GB = 'I' THEN 1 ELSE 0 END) AS IMG_CNT
+		                         FROM   TB_REVIEW_ATTACH
+		                         WHERE  REVIEW_SQ = R.REVIEW_SQ
+		                         AND    DEL_YN = 'N'
+		                        ) Z
+		                )
+		            ELSE
+		                R.REVIEW_GB
+		       END                                      AS REVIEW_GB      /*상품평구분*/
 		     , R.CUST_NO                                                  /*고객번호*/
 		     , C.CUST_NM                                                  /*고객명*/
 		     , R.ORD_NO                                                   /*주문번호*/
@@ -81,6 +138,7 @@
 		    </if>
 		</if>
 		ORDER  BY R.REG_DT DESC
+		LIMIT #{pageable.limitStartRow}, #{pageable.pageSize}
 	</select>
 	
 	<!--상품평 정보 -->

+ 26 - 1
src/main/webapp/WEB-INF/views/display/MainGnbContentsPopupForm.html

@@ -23,7 +23,7 @@
 			<div class="panelContent">
 				<ul class="panelBar">
 					<li class="aL">
-						<span class="cBlue">* 상단으로 드래그&amp;드랍하여 순서 변경 가능합니다.d</span>
+						<span class="cBlue">* 상단으로 드래그&amp;드랍하여 순서 변경 가능합니다.</span>
 					</li>
 					<li class="aR">
 						<button type="button" class="btn btn btn-base btn-sm" onclick="fnAddTab(this);">TAB 컨텐츠 추가</button>
@@ -373,6 +373,27 @@
 
 	}
 
+	// 대카테고리 유형일 때 카테고리 선택값 체크
+	var cateDataValidation = function (){
+		let dupCnt = 0;
+		$("#gnbTabList .tabTable").each(function (i){
+			var thisIdx = $(this).find("input[name=tableIdx]").val();
+			// 대카테고리 유형일 때 카테고리 선택값 체크
+			if($(this).find("input:radio[name=cateType"+thisIdx+"]:checked").val()=='C'){
+				if(gagajf.isNull($(this).find("select[name=cate1List]").val())){
+					mcxDialog.alert((i+1)+'번째 카테고리를 선택해주세요.');
+					dupCnt++;
+					return false;
+				}
+
+			}
+		});
+
+		if(dupCnt==0){
+			return true;
+		}
+	}
+
 	// 유형선택 체크
 	var dataTypeValidation = function (){
 		var dataBool = true;
@@ -422,6 +443,10 @@
 			if(!dataTypeValidation()){
 				return false;
 			}
+
+			if(!cateDataValidation()){
+				return false;
+			}
 		}
 
 		dataArr = [];

+ 4 - 0
src/main/webapp/WEB-INF/views/envset/CustomerGradePolicyForm.html

@@ -60,6 +60,8 @@
 		<!-- 등록/수정 -->
 		<div class="panelStyle">
 			<form id="detailForm" name="detailForm" action="#" th:action="@{'/envset/customer/grade/policy/create'}">
+				<input type="hidden" name="mode" value="N"/>
+				
 				<table class="frmStyle" aria-describedby="등록/상세폼">
 					<colgroup>
 						<col style="width:10%;"/>
@@ -223,6 +225,7 @@
 		if (event.colDef.field != 'gradeCd')
 			return;
 		
+		$('#detailForm input[name=mode]').val('U');
 		$('#detailForm select[name=siteCd]').val(event.data.siteCd);
 		$('#detailForm select[name=gradeCd]').val(event.data.gradeCd);
 		$('#detailForm input[name=iconNm]').val(event.data.iconNm);
@@ -264,6 +267,7 @@
 	// 신규
 	$('#btnNew').on('click', function() {
 		$('#detailForm')[0].reset();
+		$('#detailForm input[name=mode]').val('N');
 		$('#iconPrefix').html('');
 		$('#detailForm select[name=siteCd]').focus();
 	});

+ 20 - 13
src/main/webapp/WEB-INF/views/goods/GoodsAdKeywordForm.html

@@ -34,13 +34,14 @@
 			<!-- //TITLE -->
 			<form id="searchForm" name="searchForm" action="#" th:action="@{'/goods/ad/keyword/list'}" >
 				<input type="hidden" id="searchGb" name="searchGb" />
+				<input type="hidden" id="search" name="search" value="searchGoodsCd"/>
 			<div class="panelContent">	
 				<table class="frmStyle" aria-describedby="검색조건">
 					<colgroup>
 						<col width="10%"/>
 						<col width="30%"/>
 						<col width="10%"/>
-						<col width="20%"/>
+						<col width="30%"/>
 						<col width="10%"/>
 						<col/>
 					</colgroup>
@@ -49,10 +50,6 @@
 						<td>
 							<input type="text" class="w200" name="adKeyword" id="adKeyword" maxlength="20"/>
 						</td>
-						<th>상품코드</th>
-						<td>
-							<input type="text" class="w200" name="goodsCd" id="goodsCd" maxlength="20"/>
-						</td>
 						<th>사용여부</th>
 						<td>
 							<select name="useYn">
@@ -61,10 +58,14 @@
 								<option value="N">[N] No</option>
 							</select>
 						</td>
+						<th rowspan="2">상품코드</th>
+						<td rowspan="2">
+							<textarea class="textareaR2 w150" name="condition" id="condition"></textarea>
+						</td>
 					</tr>
 					<tr>
 						<th>기간</th>
-						<td colspan="5" id="sellTerms">
+						<td colspan="3" id="sellTerms">
 						</td>
 					</tr>
 				</table>
@@ -244,16 +245,22 @@
 		var searchFlag = false;
 		var cnt = 0;
 
-		for (i = 0; i < form.elements.length; i++ ) {
-			var el = form.elements[i];
-
-			if ($(el).prop("type") == "text" || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
-				if (!(el.value == null || el.value == "")) {
-					cnt++;
+		if( !gagajf.isNull($("#searchForm textarea[name=condition]").val())
+			|| (!gagajf.isNull($("#searchForm input[name=stDate]").val()) && !gagajf.isNull($("#searchForm input[name=edDate]").val()))
+			){
+			searchFlag = true;
+		}else{
+			for (i = 0; i < form.elements.length; i++ ) {
+				var el = form.elements[i];
+	
+				if ($(el).prop("type") == "text" || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
+					if (!(el.value == null || el.value == "")) {
+						cnt++;
+					}
 				}
 			}
 		}
-			
+		
 		if(cnt > 0) searchFlag = true;
 
 		if(searchFlag == false){

+ 2 - 2
src/main/webapp/WEB-INF/views/goods/GoodsDetailSizeStockForm.html

@@ -37,7 +37,7 @@
 			<td class="aC" th:text="${sizeStatus.count}">1</td>
 			<td class="aC"><label class="rdoBtn"><input type="radio" name="basicColor" th:value="${goodsColor.optCd1}"  th:checked="${goodsColor.mainColorYn =='Y'}" /></label></td>
 			<td class="aC">
-				<img width="60" th:src="${uploadGoodsUrl+'/'+goodsColor.sysImgNm+'?RS=60'}" th:onerror="'this.src=\''+@{${uxImgUrl}+ '/image/no.png'}+'\';'" alt="">
+				<img width="60" id="defaultImg" th:src="${uploadGoodsUrl+'/'+goodsColor.sysImgNm+'?RS=60'}" th:onerror="'this.src=\''+@{${uxImgUrl}+ '/image/no.png'}+'\';'" alt="">
 				<input type="hidden" name="sysImgNmOrg" id="sysImgNmOrg" th:value="${goodsColor.sysImgNm}"/>
 			</td>	
 			<td class="aC" ><th:block th:text="${goodsColor.optCd1}">BK</th:block> 
@@ -46,7 +46,7 @@
 			<td class="aC" ><th:block th:text="${goodsColor.colorEnm}">BLACK</th:block>  
 				<input type="hidden" name="colorNm" id="colorNm" th:value="${goodsColor.colorEnm}"/>
 			</td>
-			<td><button type="button" class="btn btn-base btn-lg" onclick="fnGoodsDetailImg(this)" th:text="${#strings.isEmpty(goodsColor.sysImgNm) ?'등록':'수정'}">등록</button></td>
+			<td><button type="button" id="btnDefaultImg" class="btn btn-base btn-lg" onclick="fnGoodsDetailImg(this)" th:text="${#strings.isEmpty(goodsColor.sysImgNm) ?'등록':'수정'}">등록</button></td>
 		</tr>
 		</th:block>
 		</tbody>

+ 13 - 12
src/main/webapp/WEB-INF/views/goods/GoodsEpSkipForm.html

@@ -34,13 +34,11 @@
 			<div class="panelContent">
 				<table class="frmStyle">
 					<colgroup>
-						<col width="8%"/>
-						<col width="17%"/>
-						<col width="8%"/>
-						<col width="17%"/>
-						<col width="8%"/>
-						<col width="17%"/>
-						<col width="8%"/>
+						<col width="10%"/>
+						<col width="23%"/>
+						<col width="10%"/>
+						<col width="23%"/>
+						<col width="10%"/>
 						<col />
 					</colgroup>
 					<tr>
@@ -59,18 +57,20 @@
 							<span id="brandText"></span>
 							<input type="hidden" name="brandList"/>
 						</td>
-						<th>키워드</th>
-						<td>
+						<th rowspan="2">키워드</th>
+						<td rowspan="2">
 							<select name="search" id="search">
 								<option value="searchGoodsCd">상품코드</option>
 								<option value="searchGoodsNm">상품명</option>
 								<option value="searchGoodsNum">품번</option>
 								<option value="searchSupplyGoodsCd">업체상품코드</option>
 							</select>
-							<input type="text" class="w50p" name="condition" id="condition" maxlength="50"/>
+							<textarea class="textareaR2 w50p" name="condition" id="condition"></textarea>
 						</td>
+					</tr>
+					<tr>	
 						<th>시즌/년도</th>
-						<td>
+						<td colspan="3">
 							<select  name="styleYear" id="styleYear">
 								<option value="">[전체]</option>
 								<option th:if="${styleYearList}" th:each="oneData, status : ${styleYearList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
@@ -83,7 +83,7 @@
 					</tr>
 					<tr>
 						<th>비노출예약일</th>
-						<td colspan="7" id="sellTerms"></td>
+						<td colspan="5" id="sellTerms"></td>
 					</tr>
 				</table>
 				<ul class="panelBar">
@@ -256,6 +256,7 @@
 
 		if( !gagajf.isNull($("#goodsEpSkipListForm input[name=supplyCompList]").val())
 				|| !gagajf.isNull($("#goodsEpSkipListForm input[name=brandList]").val())
+				|| !gagajf.isNull($("#goodsEpSkipListForm textarea[name=condition]").val())
 			){
 			searchFlag = true;
 		}else{

+ 17 - 11
src/main/webapp/WEB-INF/views/goods/GoodsImageForm.html

@@ -101,7 +101,6 @@
 						<button type="button" class="btn btn-default btn-sm" onclick="gagaDx5.deleteAllFiles();">전체 삭제</button>
 						<button type="button" class="btn btn-info btn-sm" onclick="gagaDx5.moveFile(true);">위로 이동</button>
 						<button type="button" class="btn btn-info btn-sm" onclick="gagaDx5.moveFile(false);">아래로 이동</button>
-						<!-- <button type="button" class="btn btn-base btn-sm" onclick="gagaDx5.previewImage();">이미지 보기</button> -->
 						<button type="button" class="btn btn-base btn-sm" onclick="gagaDx5.uploadFiles();">업로드/수정</button>
 					</li>
 				</ul>
@@ -208,17 +207,24 @@
 	// 콜백함수
 	var fnUploadCallback = function(result) {
 		// 기본이미지명 조회
-		//var actionUrl = '/goods/default/image/url'
-		//		+ '?goodsCd=' + $('#goodsImgForm input[name=goodsCd]').val()
-		//		+ '&colorCd=' + $('#goodsImgForm input[name=colorCd]').val();
+		var actionUrl = '/goods/default/image/url'
+				+ '?goodsCd=' + $('#goodsImgForm input[name=goodsCd]').val()
+				+ '&colorCd=' + $('#goodsImgForm input[name=colorCd]').val();
 
-		//$.get(actionUrl
-		//	, function(url) {
-		//		console.log(url);
-		//		//opener.setImg($('#goodsImgForm input[name=defaultImgOrd]').val(), result.defaultImgNm);
-		//		fnGoodsImgFormClose();
-		//	});
-		fnGoodsImgFormClose();
+		$.get(actionUrl
+			, function(url) {
+				//console.log(url);
+				// 상세메인
+				$("#goodsDetailForm").find("#goodsImgUrl").attr('src', url+"?RS=130");
+				// 상세옵션
+				$("#goodsDetailForm").find("#defaultImg").attr('src', url+"?RS=60");
+				if (gagajf.isNull(url)){
+					$("#goodsDetailForm").find("#btnDefaultImg").text("등록");	
+				}else{
+					$("#goodsDetailForm").find("#btnDefaultImg").text("수정");
+				}
+				fnGoodsImgFormClose();
+			});
 	}
 
 	// 더블클릭시 썸네일 지정 후 첫번째로 이동

+ 101 - 25
src/main/webapp/WEB-INF/views/goods/GoodsNaverPriceForm.html

@@ -30,7 +30,7 @@
 		<div class="panelStyle" >
 			<!-- TITLE -->
 			<div class="panelTitle">
-				<h3><i class="fa fa-info-circle"></i>아래 검색조건 중 하나를 꼭 입력해 주세요.</h3>
+				<!-- <h3><i class="fa fa-info-circle"></i>아래 검색조건 중 하나를 꼭 입력해 주세요.</h3> -->
 				<span class="panelControl">
 					<i class="fa fa-chevron-up"></i>
 				</span>
@@ -40,32 +40,35 @@
 				<table class="frmStyle">
 					<colgroup>
 						<col width="10%"/>
-						<col width="40%"/>
+						<col width="23%"/>
+						<col width="10%"/>
+						<col width="23%"/>
 						<col width="10%"/>
 						<col/>
 					</colgroup>
 					<tr>
+						<th>업체</th>
+						<td>
+							<input type="text" class="w100" name="supplyCompSearchTxt" id="supplyCompSearchTxt" maxlength="20" />
+							<button type="button" class="btn icn" id="btnSearchSupplyComp"><i class="fa fa-search"></i></button>
+							<span id="supplyCompText"></span>
+							<input type="hidden" name="supplyCompList"/>
+						</td>
 						<th>브랜드</th>
 						<td>
-							<select name="supplyCompCd" id="supplyCompCd">
-								<option value="" th:if="${sessionInfo.roleCd} != 'G001_B000'">[전체]</option>
-								<option th:if="${supplyCompList}" th:each="oneData, status : ${supplyCompList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
-							</select>
-							<select name="brandCd" id="brandCd">
-								<option value="">[전체]</option>
-							</select>
+							<input type="text" class="w100" name="searchTxt" id="searchTxt" maxlength="20" />
+							<button type="button" class="btn icn" id="btnSearchBrand"><i class="fa fa-search"></i></button>
+							<span id="brandText"></span>
+							<input type="hidden" name="brandList"/>
 						</td>
-						<th rowspan="3">키워드</th>
-						<td rowspan="3">
-							<!-- <select name="search" id="search">
-								<option value="searchGoodsCd">상품코드</option>
-							</select> -->
-							<textarea class="textareaR3 w150" name="condition" id="condition"></textarea>
+						<th rowspan="2">상품코드</th>
+						<td rowspan="2">
+							<textarea class="textareaR2 w150" name="condition" id="condition"></textarea>
 						</td>
 					</tr>
 					<tr>
-						<th rowspan="2">년도/시즌</th>
-						<td rowspan="2">
+						<th>년도/시즌</th>
+						<td colspan="3">
 							<div class="multiCheckBox" style="width:140px;">
 							<button type="button" class="sltBtn" data-name="[전체]">[전체]</button>
 								<ul style="overflow:auto; height:140px" id="grpStyle">
@@ -197,7 +200,7 @@
 	// Row Click
 	gridOptions.onCellClicked = function(event) {
 		var goodsCd = event.data.goodsCd;
-		if (event.colDef.field == "goodsCd"){
+		if (event.colDef.field == "goodsNm"){
 			cfnOpenGoodsDetailPopup('U',goodsCd);
 			//cfnOpenFrontGoodsPopup(goodsCd, event.data.siteCd);
 		}else if (event.colDef.field == "mallLink"){
@@ -216,6 +219,11 @@
 		$("#searchForm input[type=checkbox]").parent("label").removeClass("checked");
 		$("#searchForm input[type=radio][checked]").parent("label").addClass("checked");
 		
+		$('#searchForm input[name=brandList]').val('');
+		$('#searchForm').find('#brandText').html('');
+		$('#searchForm input[name=supplyCompList]').val('');
+		$('#searchForm').find('#supplyCompText').html('');
+		
 		$(document).find('#searchForm').find(".multiCheckBox").each(function(i, e){
 			let btnNm = $(this).find(".sltBtn").attr("data-name");
 			$(this).find(".sltBtn").text(btnNm);
@@ -254,15 +262,23 @@
 		var searchFlag = false;
 		var cnt = 0;
 
-		for (i = 0; i < form.elements.length; i++ ) {
-			var el = form.elements[i];
-
-			if ($(el).prop("type") == "text"  || $(el).prop("type") == "textarea"  || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
-				if (!(el.value == null || el.value == "")) {
-					cnt++;
+		if( !gagajf.isNull($("#searchForm input[name=supplyCompList]").val()) 
+				|| !gagajf.isNull($("#searchForm textarea[name=condition]").val())
+				|| (!gagajf.isNull($("#searchForm input[name=stDate]").val()) && !gagajf.isNull($("#searchForm input[name=edDate]").val()))
+				|| !gagajf.isNull($("#searchForm input[name=brandList]").val())
+			){
+			searchFlag = true;
+		}else{
+			for (i = 0; i < form.elements.length; i++ ) {
+				var el = form.elements[i];
+	
+				if ($(el).prop("type") == "text"  || $(el).prop("type") == "textarea"  || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
+					if (!(el.value == null || el.value == "")) {
+						cnt++;
+					}
 				}
 			}
-		}
+		}	
 		
 		var mulYearSize = $('input:checkbox[name="multiStyleYear"]:checked').length;
 		var mulSeasonSize = $('input:checkbox[name="multiSeasonCd"]:checked').length;
@@ -281,6 +297,66 @@
 		return true;
 	}
 
+	// 업체 조회 선택시
+	$('#btnSearchSupplyComp').on('click', function() {
+		cfnOpenCompanyListPopup('fnSetSupplyCompInfo', 'M');
+	});
+	
+	// 업체 조회 팝업에서 호출
+	var fnSetSupplyCompInfo = function(result) {
+		var arrSupplyComp = [];
+		var supplyCompText = "";
+		var sIndex = 0;
+		$('#searchForm').find('#supplyCompText').html('');
+		$('#searchForm input[name=supplyCompSearchTxt]').val('');
+		result.forEach(function(supplyComp){
+			sIndex++; 
+			arrSupplyComp.push(supplyComp.supplyCompCd);
+		});
+
+		// 조회값이 하나일 경우 화면에 코드 노출 그외는 갯수 처리 
+		if (sIndex == 1) {
+			$('#searchForm input[name=supplyCompSearchTxt]').val(arrSupplyComp[0]);
+		}else{
+			supplyCompText = sIndex + " 개";
+			$('#searchForm').find('#supplyCompText').html(supplyCompText);	
+		}
+		var jsonData = JSON.stringify(arrSupplyComp);
+		$("#searchForm input[name=supplyCompList]").val(jsonData);
+	}
+	
+	// 브랜드 조회 팝업에서 호출
+	var fnSetBrandInfo = function(result) {
+		var arrbrandCd = [];
+		var brandText = "";
+		var bIndex = 0;
+		$('#searchForm').find('#brandText').html('');
+		$('#searchForm input[name=searchTxt]').val('');
+		result.forEach(function(brand){
+			bIndex++; 
+			arrbrandCd.push(brand.brandCd);
+		});
+
+		// 조회값이 하나일 경우 화면에 코드 노출 그외는 갯수 처리 
+		if (bIndex == 1) {
+			$('#searchForm input[name=searchTxt]').val(arrbrandCd[0]);
+		}else{
+			brandText = bIndex + " 개";
+			$('#searchForm').find('#brandText').html(brandText);	
+		}
+		var jsonData = JSON.stringify(arrbrandCd);
+		$("#searchForm input[name=brandList]").val(jsonData);
+	}
+	
+	// 브랜드 조회 선택시
+	$('#btnSearchBrand').on('click', function() {
+		/* if (gagajf.isNull($("#searchForm input[name=searchTxt]").val())){
+			mcxDialog.alert('브랜드 검색어를 입력하세요.');
+			return false;
+		} */
+		cfnOpenBrandListPopup('fnSetBrandInfo', 'M');
+	});
+	
 	//엑셀다운로드
 	var fnGoodsExcelDownLoad = function(flag){
 		var formId = '#searchForm';

+ 112 - 30
src/main/webapp/WEB-INF/views/goods/GoodsNoticeForm.html

@@ -39,30 +39,36 @@
 				<table class="frmStyle" aria-describedby="검색조건">
 					<colgroup>
 						<col width="10%"/>
-						<col width="40%"/>
+						<col width="23%"/>
+						<col width="10%"/>
+						<col width="23%"/>
 						<col width="10%"/>
 						<col/>
 					</colgroup>
 					<tr>
-						<th>업체/브랜드</th>
+						<th>업체</th>
 						<td>
-							<select name="supplyCompCd" id="supplyCompCd">
-								<option value="" th:if="${sessionInfo.roleCd} != 'B000'">[전체]</option>
-								<option th:if="${supplyCompList}" th:each="oneData, status : ${supplyCompList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
-							</select>
-							<select name="brandCd" id="brandCd">
-								<option value="">[전체]</option>
-							</select>
+							<input type="text" class="w100" name="supplyCompSearchTxt" id="supplyCompSearchTxt" maxlength="20" />
+							<button type="button" class="btn icn" id="btnSearchSupplyComp"><i class="fa fa-search"></i></button>
+							<span id="supplyCompText"></span>
+							<input type="hidden" name="supplyCompList"/>
 						</td>
-						<th>키워드</th>
+						<th>브랜드</th>
 						<td>
+							<input type="text" class="w100" name="searchTxt" id="searchTxt" maxlength="20" />
+							<button type="button" class="btn icn" id="btnSearchBrand"><i class="fa fa-search"></i></button>
+							<span id="brandText"></span>
+							<input type="hidden" name="brandList"/>
+						</td>
+						<th rowspan="2">키워드</th>
+						<td rowspan="2">
 							<select name="search" id="search">
 								<option value="searchGoodsCd">상품코드</option>
 								<option value="searchGoodsNm">상품명</option>
 								<option value="searchGoodsNum">품번</option>
 								<option value="searchSupplyGoodsCd">업체상품코드</option>
 							</select>
-							<input type="text" class="w50p" name="condition" id="condition" maxlength="50"/>
+							<textarea class="textareaR2 w50p" name="condition" id="condition"></textarea>
 						</td>
 					</tr>
 					<tr>
@@ -81,13 +87,13 @@
 					</tr>
 					<tr>
 						<th>공지기간</th>
-						<td colspan="3" id="sellTerms">
+						<td colspan="5" id="sellTerms">
 						</td>
 					</tr>
 				</table>
 				<ul class="panelBar">
 					<li class="center">
-						<button type="button" class="btn btn-gray btn-lg" onclick="$('#searchForm')[0].reset();">초기화</button>
+						<button type="button" class="btn btn-gray btn-lg" id="btnInit">초기화</button>
 						<button type="button" class="btn btn-base btn-lg" id="btnSearch">조회</button>
 					</li>
 				</ul>
@@ -251,6 +257,28 @@
 		fnGetNoticeGoodsList(event.data.noticeSq);
 	}
 
+	// 초기화 클릭시
+	$('#btnInit').on('click', function() {
+
+		$('#searchForm')[0].reset();
+		//$("#searchForm input[type=radio]").removeClass("checked");
+		$("#searchForm input[type=checkbox]").removeClass("checked");
+		//$("#searchForm input[type=radio]").parent("label").removeClass("checked");
+		$("#searchForm input[type=checkbox]").parent("label").removeClass("checked");
+		$("#searchForm input[type=radio][checked]").parent("label").addClass("checked");
+		$("#multiBrand").empty();
+		$('#searchForm input[name=brandList]').val('');
+		$('#searchForm').find('#brandText').html('');
+		$('#searchForm input[name=supplyCompList]').val('');
+		$('#searchForm').find('#supplyCompText').html('');
+		
+		$(document).find('#searchForm').find(".multiCheckBox").each(function(i, e){
+			let btnNm = $(this).find(".sltBtn").attr("data-name");
+			$(this).find(".sltBtn").text(btnNm);
+		});
+		
+	});
+	
 	// 검색
 	$('#btnSearch').on('click', function() {
 		if(!fnConditionCheck()) return;
@@ -264,17 +292,23 @@
 
 		var searchFlag = false;
 		var cnt = 0;
-
-		for (i = 0; i < form.elements.length; i++ ) {
-			var el = form.elements[i];
-
-			if ($(el).prop("type") == "text" || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
-				if (!(el.value == null || el.value == "")) {
-					cnt++;
+		if( !gagajf.isNull($("#searchForm input[name=supplyCompList]").val()) 
+				|| !gagajf.isNull($("#searchForm textarea[name=condition]").val())
+				|| (!gagajf.isNull($("#searchForm input[name=stDate]").val()) && !gagajf.isNull($("#searchForm input[name=edDate]").val()))
+				|| !gagajf.isNull($("#searchForm input[name=brandList]").val())
+			){
+			searchFlag = true;
+		}else{
+			for (i = 0; i < form.elements.length; i++ ) {
+				var el = form.elements[i];
+	
+				if ($(el).prop("type") == "text" || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
+					if (!(el.value == null || el.value == "")) {
+						cnt++;
+					}
 				}
 			}
-		}
-			
+		}	
 		if(cnt > 0) searchFlag = true;
 
 		if(searchFlag == false){
@@ -317,17 +351,65 @@
 		gagaAgGrid.fetch(actionUrl, gridNoticeGoodsOptions);
 	}
 	
-	//업체변경시
-	$('#searchForm select[name=supplyCompCd]').on('change', function() {
-		var actionUrl = '/renderer/supplyCompany/brand/list/' + $(this).val();
+	// 업체 조회 선택시
+	$('#btnSearchSupplyComp').on('click', function() {
+		cfnOpenCompanyListPopup('fnSetSupplyCompInfo', 'M');
+	});
+	
+	// 업체 조회 팝업에서 호출
+	var fnSetSupplyCompInfo = function(result) {
+		var arrSupplyComp = [];
+		var supplyCompText = "";
+		var sIndex = 0;
+		$('#searchForm').find('#supplyCompText').html('');
+		$('#searchForm input[name=supplyCompSearchTxt]').val('');
+		result.forEach(function(supplyComp){
+			sIndex++; 
+			arrSupplyComp.push(supplyComp.supplyCompCd);
+		});
 
-		if(sessRoleCd == "G001_B000"){
-			actionUrl = '/renderer/brand/AuthBrandlist';
+		// 조회값이 하나일 경우 화면에 코드 노출 그외는 갯수 처리 
+		if (sIndex == 1) {
+			$('#searchForm input[name=supplyCompSearchTxt]').val(arrSupplyComp[0]);
+		}else{
+			supplyCompText = sIndex + " 개";
+			$('#searchForm').find('#supplyCompText').html(supplyCompText);	
 		}
-		$("#searchForm select[name=brandCd] option:gt(0)").remove();
+		var jsonData = JSON.stringify(arrSupplyComp);
+		$("#searchForm input[name=supplyCompList]").val(jsonData);
+	}
+	
+	// 브랜드 조회 팝업에서 호출
+	var fnSetBrandInfo = function(result) {
+		var arrbrandCd = [];
+		var brandText = "";
+		var bIndex = 0;
+		$('#searchForm').find('#brandText').html('');
+		$('#searchForm input[name=searchTxt]').val('');
+		result.forEach(function(brand){
+			bIndex++; 
+			arrbrandCd.push(brand.brandCd);
+		});
 
-		cfnCreateCombo(actionUrl, $('#searchForm select[name=brandCd]'), "[전체]", "");
-	});	
+		// 조회값이 하나일 경우 화면에 코드 노출 그외는 갯수 처리 
+		if (bIndex == 1) {
+			$('#searchForm input[name=searchTxt]').val(arrbrandCd[0]);
+		}else{
+			brandText = bIndex + " 개";
+			$('#searchForm').find('#brandText').html(brandText);	
+		}
+		var jsonData = JSON.stringify(arrbrandCd);
+		$("#searchForm input[name=brandList]").val(jsonData);
+	}
+	
+	// 브랜드 조회 선택시
+	$('#btnSearchBrand').on('click', function() {
+		/* if (gagajf.isNull($("#searchForm input[name=searchTxt]").val())){
+			mcxDialog.alert('브랜드 검색어를 입력하세요.');
+			return false;
+		} */
+		cfnOpenBrandListPopup('fnSetBrandInfo', 'M');
+	});
 	
 	//엑셀 상품 조회
 	$('#btnSearchExcel').on('click', function() {

+ 18 - 11
src/main/webapp/WEB-INF/views/goods/GoodsReserveSellForm.html

@@ -32,9 +32,9 @@
 			<div class="panelContent">
 				<table class="frmStyle">
 					<colgroup>
-						<col width="8%"/>
-						<col width="25%"/>
-						<col width="8%"/>
+						<col width="10%"/>
+						<col width="40%"/>
+						<col width="10%"/>
 						<col/>
 					</colgroup>
 					<tr>
@@ -56,7 +56,7 @@
 								<option value="searchGoodsNum">품번</option>
 								<option value="searchSupplyGoodsCd">업체상품코드</option>
 							</select>
-							<input type="text" class="w50p" name="condition" id="condition" maxlength="50"/>
+							<textarea class="textareaR2 w50p" name="condition" id="condition"></textarea>
 						</td>
 					</tr>
 					<tr>
@@ -228,16 +228,23 @@
 		var searchFlag = false;
 		var cnt = 0;
 
-		for (i = 0; i < form.elements.length; i++ ) {
-			var el = form.elements[i];
-
-			if ($(el).prop("type") == "text" || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
-				if (!(el.value == null || el.value == "")) {
-					cnt++;
+		if( !gagajf.isNull($("#goodsResSellListForm input[name=supplyCompList]").val())
+				|| !gagajf.isNull($("#goodsResSellListForm input[name=brandList]").val())
+				|| !gagajf.isNull($("#goodsResSellListForm textarea[name=condition]").val())
+			){
+			searchFlag = true;
+		}else{
+			for (i = 0; i < form.elements.length; i++ ) {
+				var el = form.elements[i];
+	
+				if ($(el).prop("type") == "text" || ($(el).prop("type") == "select-one" && el.name != "search" && el.name != "pageSize")) {
+					if (!(el.value == null || el.value == "")) {
+						cnt++;
+					}
 				}
 			}
 		}
-			
+		
 		if(cnt > 0) searchFlag = true;
 
 		if(searchFlag == false){

+ 16 - 0
src/main/webapp/WEB-INF/views/marketing/CouponPopupForm.html

@@ -780,6 +780,22 @@
 	limitedTimeCpnGridOptions.defaultColDef.editable = true;
 	limitedTimeCpnGridOptions.rowSelection = "multiple";
 
+	// 선착순 쿠폰 종료시간 초 59로 변경
+	limitedTimeCpnGridOptions.onCellValueChanged = function (event){
+		if (event.colDef.field == "downEdTime"){
+			var temp = event.data.downEdTime.replaceAll(":","");
+			var hh = temp.substr(0,2);
+			var mm = temp.substr(2,2);
+			// var ss = temp.substr(4,2);
+
+			event.data.downEdTime = hh+':'+mm+':'+'59';
+			// console.log('event.data.downEdTime:::'+event.data.downEdTime);
+
+			limitedTimeCpnGridOptions.api.updateRowData({update: [event.data]});
+			return;
+		}
+	}
+
 	// 삭제버튼 클릭시
 	// 1.공급업체
 	$('#btnSupplyDel').on('click', function() {

+ 1 - 1
src/main/webapp/WEB-INF/views/marketing/ReviewDetailForm.html

@@ -141,7 +141,7 @@
 
 <!-- 사용자 레이어팝업 : 등록 파일 출력 -->
 <div class="uPopupWrap off" id="layer_review_pic">
-	<div class="area reviewPic" style="width:500px; height:500px;">
+	<div class="area reviewPic" style="width: 700px; height: 700px;">
 		<ul class="picList" th:object="${reviewInfo}">
 			<th:block th:if="*{attachList != null}" th:each="oneData, status : *{attachList}">
 				<li th:if="${oneData.fileGb == 'M'}"><iframe class="player" th:src="${kollusMediaUrl + '/' + oneData.kmcKey + '?enable_initialize_focus=false&mute'}"></iframe></li>

+ 5 - 1
src/main/webapp/WEB-INF/views/marketing/ReviewForm.html

@@ -153,7 +153,11 @@
 		{
 			headerName: "상품평유형", field: "reviewGb", width: 90, cellClass: 'text-center',
 			cellRenderer: function(params) {
-				return params.value == 'R' ? '일반' : '포토/영상';
+				let reviewGbNm = '일반';
+				if (params.value == 'P') reviewGbNm = '포토/영상';
+				if (params.value == 'I') reviewGbNm = '포토';
+				if (params.value == 'M') reviewGbNm = '영상';
+				return reviewGbNm;
 			}
 		},
 		{

+ 65 - 51
src/main/webapp/WEB-INF/views/stock/GoodsSizeStockForm.html

@@ -38,9 +38,11 @@
 				<table class="frmStyle">
 					<colgroup>
 						<col width="10%"/>
-						<col width="23%"/>
+						<col width="15%"/>
 						<col width="10%"/>
-						<col width="23%"/>
+						<col width="15%"/>
+						<col width="10%"/>
+						<col width="15%"/>
 						<col width="10%"/>
 						<col/>
 					</colgroup>
@@ -51,42 +53,39 @@
 							<button type="button" class="btn icn" id="btnSearchSupplyComp"><i class="fa fa-search"></i></button>
 							<span id="supplyCompText"></span>
 							<input type="hidden" name="supplyCompList"/>
-							<!-- <label class="rdoBtn"><input type="radio" name="selfYn" id="selfYnY" value="Y"  checked/>자사</label>
-							<label class="rdoBtn"><input type="radio" name="selfYn" id="selfYnN" value="N"/>입점</label>
-							<select name="supplyCompCd" id="supplyCompCd">
-								<option value="" th:if="${sessionInfo.roleCd} != 'G001_B000'">[전체]</option>
-								<option th:if="${supplyCompList}" th:each="oneData, status : ${supplyCompList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
-							</select>
-							<select name="brandCd" id="brandCd">
-								<option value="">[전체]</option>
-							</select> -->
 						</td>
 						<th>브랜드<em class="required" title="필수"></em></th>
 						<td>
 							<input type="text" class="w100" name="searchTxt" id="searchTxt" maxlength="20" />
 							<button type="button" class="btn icn" id="btnSearchBrand"><i class="fa fa-search"></i></button>
-							<!-- <input type="text" class="w100" name="brandCd" readonly="readonly"/> -->
 							<span id="brandText"></span>
 							<input type="hidden" name="brandList"/>
 						</td>
-						<th>키워드<em class="required" title="필수"></em></th>
-						<td colspan="3">
+						<th>정상/이월 구분</th>
+						<td>
+							<select  name="formalGb" id="formalGb">
+								<option value="">[전체]</option>
+								<option th:if="${formalGbList}" th:each="oneData, status : ${formalGbList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
+							</select>
+						</td>
+						<th rowspan="3">키워드<em class="required" title="필수"></em></th>
+						<td rowspan="3">
 							<select name="search" id="search">
 								<option value="searchGoodsCd">상품코드</option>
 								<option value="searchGoodsNm">상품명</option>
 								<option value="searchGoodsNum">품번</option>
 								<option value="searchSupplyGoodsCd">업체상품코드</option>
 							</select>
-							<input type="text" class="w100" name="condition" id="condition" maxlength="50"/>
+							<textarea class="textareaR3 w150" name="condition" id="condition"></textarea>
 						</td>
 					</tr>
 					<tr>
-						<th>정상/이월 구분</th>
+						<th>품목</th>
 						<td>
-							<select  name="formalGb" id="formalGb">
-								<option value="">[전체]</option>
-								<option th:if="${formalGbList}" th:each="oneData, status : ${formalGbList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
-							</select>
+							<input type="text" class="w100" name="itemkindSearchTxt" id="itemkindSearchTxt" maxlength="20" />
+							<button type="button" class="btn icn" id="btnSearchItemkind"><i class="fa fa-search"></i></button>
+							<span id="itemkindText"></span>
+							<input type="hidden" name="itemkindList"/>
 						</td>
 						<th>상품상태</th>
 						<td>
@@ -95,15 +94,6 @@
 								<option th:if="${goodsStatList}" th:each="oneData, status : ${goodsStatList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
 							</select>
 						</td>
-						<th>품목</th>
-						<td colspan="3">
-							<select name="itemkindCd" id="itemkindCd">
-								<option value="">[전체]</option>
-								<option th:if="${itemkindList}" th:each="oneData, status : ${itemkindList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
-							</select>
-						</td>
-					</tr>
-					<tr>
 						<th>품절여부</th>
 						<td>
 							<select  name="soldOutYn" id="soldOutYn">
@@ -111,13 +101,8 @@
 								<option th:if="${useYnList}" th:each="oneData, status : ${useYnList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
 							</select>
 						</td>
-						<th>색상</th>
-						<td>
-							<select name="optCd1" id="optCd1">
-								<option value="">[전체]</option>
-								<option th:if="${colorList}" th:each="oneData, status : ${colorList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
-							</select>
-						</td>
+					</tr>
+					<tr>
 						<th>년도/시즌</th>
 						<td colspan="3">
 							<select  name="styleYear" id="styleYear">
@@ -129,21 +114,21 @@
 								<option th:if="${seasonList}" th:each="oneData, status : ${seasonList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
 							</select>
 						</td>
-					</tr>
-					<tr>
-						<th>담당MD</th>
+						<th>색상</th>
 						<td>
-							<select  name="mdNo" id="mdNo">
+							<select name="optCd1" id="optCd1">
 								<option value="">[전체]</option>
-								<option th:if="${brandMdList}" th:each="oneData, status : ${brandMdList}" th:value="${oneData.cd}" th:text="${oneData.cdNm}"></option>
+								<option th:if="${colorList}" th:each="oneData, status : ${colorList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
 							</select>
 						</td>
+					</tr>
+					<tr>
 						<th>사이즈</th>
 						<td>
 							<input type="text" class="w80" name="optCd2" id="optCd2" maxlength="50"/>
 						</td>
 						<th>재고수량</th>
-						<td colspan="3">
+						<td colspan="6">
 							<input type="text" class="w70" name="stockQtySt" id="stockQtySt" maxlength="5" data-valid-type="numeric"/> ~ <input type="text" class="w70" name="stockQtyEd" id="stockQtyEd" maxlength="5" data-valid-type="numeric"/>
 						</td>
 					</tr>
@@ -154,8 +139,7 @@
 						<button type="button" class="btn btn-info btn-lg" id="btnSearch" >조회</button>
 					</li>
 				</ul>
-
-			</div>
+x			</div>
 			<!-- //검색조건 영역 -->
 		</div>
 		<!-- 패널 영역1 -->
@@ -313,6 +297,13 @@
 		$('#goodsSizeStockForm input[name=supplyCompList]').val('');
 		$('#goodsSizeStockForm').find('#brandText').html('');
 		$('#goodsSizeStockForm').find('#supplyCompText').html('');
+		$('#goodsSizeStockForm input[name=itemkindList]').val('');
+		$('#goodsSizeStockForm').find('#itemkindText').html('');
+		
+		$(document).find('#goodsSizeStockForm').find(".multiCheckBox").each(function(i, e){
+			let btnNm = $(this).find(".sltBtn").attr("data-name");
+			$(this).find(".sltBtn").text(btnNm);
+		});
 		
 	}
 	
@@ -352,7 +343,7 @@
 		var cnt = 0;
 
 		if( !gagajf.isNull($("#goodsSizeStockForm input[name=supplyCompList]").val())
-				|| !gagajf.isNull($("#goodsSizeStockForm input[name=condition]").val())
+				|| !gagajf.isNull($("#goodsSizeStockForm textarea[name=condition]").val())
 				|| (!gagajf.isNull($("#goodsSizeStockForm input[name=stDate]").val()) && !gagajf.isNull($("#goodsSizeStockForm input[name=edDate]").val()))
 				|| !gagajf.isNull($("#goodsSizeStockForm input[name=brandList]").val())
 				
@@ -611,6 +602,34 @@
 		$("#goodsSizeStockForm input[name=brandList]").val(jsonData);
 	}
 	
+	// 품목 조회 선택시
+	$('#btnSearchItemkind').on('click', function() {
+		cfnOpenItemkindListPopup('fnSetItemkindInfo', 'M');
+	});
+	
+	// 품목 조회 팝업에서 호출
+	var fnSetItemkindInfo = function(result) {
+		var arrItemkind = [];
+		var itemkindText = "";
+		var sIndex = 0;
+		$('#goodsSizeStockForm').find('#itemkindText').html('');
+		$('#goodsSizeStockForm input[name=itemkindSearchTxt]').val('');
+		result.forEach(function(itemkind){
+			sIndex++; 
+			arrItemkind.push(itemkind.itemkindCd);
+		});
+
+		// 조회값이 하나일 경우 화면에 코드 노출 그외는 갯수 처리 
+		if (sIndex == 1) {
+			$('#goodsSizeStockForm input[name=itemkindSearchTxt]').val(arrItemkind[0]);
+		}else{
+			itemkindText = sIndex + " 개";
+			$('#goodsSizeStockForm').find('#itemkindText').html(itemkindText);	
+		}
+		var jsonData = JSON.stringify(arrItemkind);
+		$("#goodsSizeStockForm input[name=itemkindList]").val(jsonData);
+	}
+	
 	$(document).ready(function() {
 		
 		// Create a agGrid
@@ -618,12 +637,7 @@
 		//$('.ag-header-group-cell').each(function(item){$(this).css('text-align', 'center')});
 		//$('.ag-header-group-cell-label').each(function(item){$(this).css('display', 'inline-block')});
 
-		// 입점 사용자 브랜드 조회 처리
-		if(sessRoleCd == "G001_B000"){
-			actionUrl = '/renderer/brand/AuthBrandlist';
-			cfnCreateCombo(actionUrl, $('#goodsSizeStockForm select[name=brandCd]'), "[전체]", "");
-		}
-
+		
 	});
 
 /*]]>*/

+ 1 - 1
src/main/webapp/WEB-INF/views/system/MenuForm.html

@@ -360,7 +360,7 @@
 		// 다중Select에 권한 표시
 		cfnShowMultiSelectedValue($('#detailForm select[name=roleCd]'), rowData.roleCds);
 		
-		$('#detailForm textarea[name=menuDesc]').val(rowData.menuDesc);
+		$('#detailForm textarea[name=menuDesc]').val(rowData.menuDesc.replaceAll('&lt;','<').replaceAll('&gt;','>'));
 		$('#detailForm input[name=menuUrl]').val(rowData.menuUrl);
 		$('#detailForm input[name=dispOrd]').val(rowData.dispOrd);
 		

+ 1 - 1
src/main/webapp/dx5/dextuploadx5-configuration.js

@@ -6,7 +6,7 @@
 
     var gAuthkey = '';
     if (location.host.indexOf("ld") > -1) {
-    	gAuthkey = "tUOR2fkfazRRQLaqhQxfq5y/4k4Ev0q6qgnp/agZPB4Rih2VuGbntr5tMUPEPjw3t5wilWvIo0RVYGyQ1BtJYGoaFfkFEo725J6GjCWSJFvGG2rhZkyqYd9P7sXU0gI7OSoMWa6IzyKfkbptvMOZLSwUDJ5xkZ/N8ig01dN4QeY=";
+    	gAuthkey = "QpN67O58p2mPJIVSLSyIp3lidy8y/C1tEozgp85UuGSlkWuQSq01FPNohuhISdVLyLYJfEfbWeLDlSFhiYap5W31XN5T0ihwzJdAsmcEslm61ChGk9sJrtvgvjdlWsLsDvuxtXFtKlJY5iOXmewF2Zsj2tSiKdwSMfW3MJ13qeI=";
     } else if (location.host.indexOf("lp") > -1) {
     	gAuthkey = "gx9EHEhXzTpbdxWjty/oHh9cfVi5WA5X4BV71AHaC/ORN/1fcs8nTTd4oUUvC5WhHqEa6Wt8cfmCBJ9w/pJpRhDd+tVu6kPDt9bxZL9n0bvaUn2rrbmJMA+HC9gzahwdEOcjr6ZOmNSEd6N0xN2BDBk55hvfPw02R77XjVuZrQU=";
     } else if (location.host.indexOf("td") > -1) {