Quellcode durchsuchen

Merge branch 'develop' of http://112.172.147.34:4936/style24/style24.admin into develop

card007 vor 5 Jahren
Ursprung
Commit
2ec13ed910
22 geänderte Dateien mit 562 neuen und 292 gelöschten Zeilen
  1. 10 0
      src/main/java/com/style24/admin/biz/dao/TsaCustomerDao.java
  2. 10 0
      src/main/java/com/style24/admin/biz/dao/TsaGoodsDao.java
  3. 2 0
      src/main/java/com/style24/admin/biz/service/TsaCustomerService.java
  4. 3 0
      src/main/java/com/style24/admin/biz/service/TsaDisplayService.java
  5. 38 10
      src/main/java/com/style24/admin/biz/service/TsaGoodsService.java
  6. 1 1
      src/main/java/com/style24/admin/biz/web/TsaBusinessController.java
  7. 23 2
      src/main/java/com/style24/admin/biz/web/TsaGoodsController.java
  8. 0 34
      src/main/java/com/style24/persistence/domain/MailTemplate.java
  9. 24 0
      src/main/java/com/style24/persistence/mybatis/shop/TsaCustomer.xml
  10. 149 120
      src/main/java/com/style24/persistence/mybatis/shop/TsaDsiplay.xml
  11. 29 3
      src/main/java/com/style24/persistence/mybatis/shop/TsaGoods.xml
  12. 0 4
      src/main/java/com/style24/persistence/mybatis/shop/TsaPoll.xml
  13. 17 23
      src/main/resources/config/application-run.yml
  14. 13 13
      src/main/resources/config/application-style.yml
  15. 11 11
      src/main/webapp/WEB-INF/views/display/MainContentsPopupForm.html
  16. 59 22
      src/main/webapp/WEB-INF/views/display/MainGnbContentsPopupForm.html
  17. 17 4
      src/main/webapp/WEB-INF/views/display/MainListForm.html
  18. 3 3
      src/main/webapp/WEB-INF/views/display/MainMultiContentsPopupForm.html
  19. 141 40
      src/main/webapp/WEB-INF/views/goods/GoodsDetailForm.html
  20. 10 0
      src/main/webapp/WEB-INF/views/marketing/PlanDetailPopupForm.html
  21. 1 1
      src/main/webapp/dx5/dextuploadx5-configuration.js
  22. 1 1
      src/main/webapp/ux/plugins/gaga/gaga.summernote.js

+ 10 - 0
src/main/java/com/style24/admin/biz/dao/TsaCustomerDao.java

@@ -206,5 +206,15 @@ public interface TsaCustomerDao {
 	 */
 	int getCustomerFindByCellPhone(CustomerSearch customerSearch);
 
+	/**
+	 * 고객 생년월일 저장
+	 *
+	 * @param customer - 고객번호, 생년월일
+	 * @return int - 결과
+	 * @author jsshin
+	 * @since 2021. 05. 10
+	 */
+	int saveBatchBirth(Customer customer);
+
 
 }

+ 10 - 0
src/main/java/com/style24/admin/biz/dao/TsaGoodsDao.java

@@ -886,6 +886,16 @@ public interface TsaGoodsDao {
 	 */
 	Collection<Goods> getGoodsDetailOrderGradeList(Goods goods);
 
+	/**
+	 * 상품 안전인증 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2021. 05. 10
+	 */
+	GoodsSafeNo getGoodsDetailSafe(Goods goods);
+	
 	/**
 	 * 상품 구매등급 삭제
 	 *

+ 2 - 0
src/main/java/com/style24/admin/biz/service/TsaCustomerService.java

@@ -122,6 +122,8 @@ public class TsaCustomerService {
 
 		// 3.고객정보 수정
 		customerDao.updateCustomerInfo(customer);
+		// 4.생년월일 수정
+		customerDao.saveBatchBirth(customer);
 
 	}
 

+ 3 - 0
src/main/java/com/style24/admin/biz/service/TsaDisplayService.java

@@ -689,6 +689,9 @@ public class TsaDisplayService {
 
 		for (Contents contents1 : contentsList){
 			if(contents1 != null && contents1.getGoodsCdArr() != null){
+				if(contents1.getContentsLoc().equals("SMM012")){
+					contents1.setCateNo(1700);
+				}
 				contents1.setContentsSq(contents1.getDispOrd());
 				contents1.setRegNo(TsaSession.getInfo().getUserNo());
 				displayDao.deleteContentsGoodsTemp(contents1);

+ 38 - 10
src/main/java/com/style24/admin/biz/service/TsaGoodsService.java

@@ -630,6 +630,20 @@ public class TsaGoodsService {
 	public Collection<Goods> getGoodsDetailOrderGradeList(Goods goods) {
 		return goodsDao.getGoodsDetailOrderGradeList(goods);
 	}
+	
+	/**
+	 * 상품 안전인증 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2021. 05. 10
+	 */
+	public GoodsSafeNo getGoodsDetailSafe(Goods goods) {
+		return goodsDao.getGoodsDetailSafe(goods);
+	}
+	
+	
 
 	/**
 	 * 구성상품 목록
@@ -665,32 +679,46 @@ public class TsaGoodsService {
 	 * @since 2020. 12. 07
 	 */
 	@Transactional("shopTxnManager")
-	public void saveGoodsDetailCertNum(Goods goods) {
+	public void saveGoodsDetailCertNum(GoodsSafeNo goodsSafeNo) {
 		try {
-			if (StringUtils.isNotBlank(goods.getCertNum())) {
-				if ("해당없음".equals(goods.getCertNum())) {
-					GoodsSafeNo goodsSafeNo = new GoodsSafeNo();
-					goodsSafeNo.setGoodsCd(goods.getGoodsCd());
-					goodsSafeNo.setCertNum(goods.getCertNum());
+			//인증대상
+			if ("G083_1".equals(goodsSafeNo.getCertTargetGb())) {
+				
+				//인증형태 (방송통신, 위해) or 인증타입 - 공급자적합성
+				if ("G084_4".equals(goodsSafeNo.getCertFormGb()) || "G084_5".equals(goodsSafeNo.getCertFormGb()) || "G081_3".equals(goodsSafeNo.getCertType())) {
+					goodsSafeNo.setCertDt("");
+//					goodsSafeNo.setCertNum("");
+					goodsSafeNo.setCertState("");
+					goodsSafeNo.setCertDiv("");
+					goodsSafeNo.setCertOrganName("");
 					goodsSafeNo.setRegNo(TsaSession.getInfo().getUserNo());
 					goodsSafeNo.setUpdNo(TsaSession.getInfo().getUserNo());
 					goodsDao.saveGoodsSafeNo(goodsSafeNo);
 				}else {
-					GagaMap result = safetyKoreaApi.getKoreaCertifyDetail(goods.getCertNum());
+					GagaMap result = safetyKoreaApi.getKoreaCertifyDetail(goodsSafeNo.getCertNum());
 					if (result != null || !StringUtil.isNullOrEmpty(result.get("certNum").toString())) {
-						GoodsSafeNo goodsSafeNo = new GoodsSafeNo();
-						goodsSafeNo.setGoodsCd(goods.getGoodsCd());
 						goodsSafeNo.setCertDt(result.get("certDt").toString());
-						goodsSafeNo.setCertNum(result.get("certNum").toString());
 						goodsSafeNo.setCertState(result.get("certState").toString());
 						goodsSafeNo.setCertDiv(result.get("certDiv").toString());
 						goodsSafeNo.setCertOrganName(result.get("certOrganName").toString());
 						goodsSafeNo.setRegNo(TsaSession.getInfo().getUserNo());
 						goodsSafeNo.setUpdNo(TsaSession.getInfo().getUserNo());
 						goodsDao.saveGoodsSafeNo(goodsSafeNo);
+					}else {
+						throw new IllegalStateException(message.getMessage("FAIL_1001"));
 					}
 				}
+			}else {	//인증대상 그외 - 인증처리 안해도 됨
+				goodsSafeNo.setCertDt("");
+//				goodsSafeNo.setCertNum("");
+				goodsSafeNo.setCertState("");
+				goodsSafeNo.setCertDiv("");
+				goodsSafeNo.setCertOrganName("");
+				goodsSafeNo.setRegNo(TsaSession.getInfo().getUserNo());
+				goodsSafeNo.setUpdNo(TsaSession.getInfo().getUserNo());
+				goodsDao.saveGoodsSafeNo(goodsSafeNo);
 			}
+			
 		} catch (Exception e) {
 			e.printStackTrace();
 		}

+ 1 - 1
src/main/java/com/style24/admin/biz/web/TsaBusinessController.java

@@ -301,7 +301,7 @@ public class TsaBusinessController extends TsaBaseController {
 		mav.addObject("siteList", rendererService.getAvailCommonCodeList("G000"));
 
 		// 구매적립포인트율
-		mav.addObject("pntInfo", cenvsetService.getEnvset(TscConstants.Site.STYLE24.value(), "C15"));
+		mav.addObject("pntInfo", cenvsetService.getEnvset(TscConstants.Site.STYLE24.value(), "C14"));
 
 		mav.setViewName("business/BrandForm");
 

+ 23 - 2
src/main/java/com/style24/admin/biz/web/TsaGoodsController.java

@@ -47,6 +47,7 @@ import com.style24.persistence.domain.GoodsNaverLowestPrice;
 import com.style24.persistence.domain.GoodsNotiInfo;
 import com.style24.persistence.domain.GoodsPriceRes;
 import com.style24.persistence.domain.GoodsResSell;
+import com.style24.persistence.domain.GoodsSafeNo;
 import com.style24.persistence.domain.GoodsSearch;
 import com.style24.persistence.domain.GoodsTnmRes;
 import com.style24.persistence.domain.GoodsVideo;
@@ -798,6 +799,12 @@ public class TsaGoodsController extends TsaBaseController {
 		mav.addObject("distributionGbList", rendererService.getCommonCodeList("G065", "Y"));
 		// 상품연령대
 		mav.addObject("ageGrpCdList", rendererService.getAvailCommonCodeList("G023"));
+		// kc인증타입
+		mav.addObject("certTypeList", rendererService.getAvailCommonCodeList("G081"));
+		// kc인증대상구분
+		mav.addObject("certTargetGbList", rendererService.getAvailCommonCodeList("G083"));
+		// kc인증형태구분
+		mav.addObject("certFormGbList", rendererService.getAvailCommonCodeList("G084"));
 		// 년도
 		int toYear = Integer.parseInt(GagaDateUtil.getToday("yyyy")) - 4;
 		mav.addObject("styleYearList", rendererService.getYearList(toYear, 0, 5));
@@ -908,6 +915,20 @@ public class TsaGoodsController extends TsaBaseController {
 	public Collection<Goods> getGoodsDetailOrderGradeList(Goods goods) {
 		return goodsService.getGoodsDetailOrderGradeList(goods);
 	}
+	
+	/**
+	 * 상품 안전인증 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2021. 05. 10
+	 */
+	@PostMapping("/detail/safe")
+	@ResponseBody
+	public GoodsSafeNo getGoodsDetailSafe(Goods goods) {
+		return goodsService.getGoodsDetailSafe(goods);
+	}
 
 	/**
 	 * 구성상품 목록
@@ -933,8 +954,8 @@ public class TsaGoodsController extends TsaBaseController {
 	 */
 	@PostMapping("/detail/certNum/save")
 	@ResponseBody
-	public GagaResponse saveGoodsDetailCertNum(@RequestBody Goods goods) {
-		goodsService.saveGoodsDetailCertNum(goods);
+	public GagaResponse saveGoodsDetailCertNum(@RequestBody GoodsSafeNo goodsSafeNo) {
+		goodsService.saveGoodsDetailCertNum(goodsSafeNo);
 		return super.ok(message.getMessage("SUCC_0001"));
 	}
 

+ 0 - 34
src/main/java/com/style24/persistence/domain/MailTemplate.java

@@ -1,34 +0,0 @@
-package com.style24.persistence.domain;
-
-import com.style24.persistence.TscBaseDomain;
-
-import lombok.Data;
-
-/**
- * 색상 Domain
- *
- * @author csh9191
- * @since 2021. 01. 29.
- */
-
-@SuppressWarnings("serial")
-@Data
-public class MailTemplate extends TscBaseDomain{
-
-	//메일템플릿
-	private Integer mailtSq;		// 메일템플릿 일련번호
-	private Integer mailhfSq;		// 메일헤더푸터 일련번호
-	private String mailhfNm;		// 메일헤더푸터 타이틀명
-	private String mailhfGb;		// 메일헤더푸터 구분 H:헤더 F:푸터
-	private String mode;
-	private String mailhfContent;	// 메일헤더푸터 내용
-	private String useYn;			// 사용여부
-	private String regDt;			// 등록일시
-	private String updDt;			// 수정일시
-	
-	private String searchTxt;		//등로자 검색
-
-
-	}
-
-

+ 24 - 0
src/main/java/com/style24/persistence/mybatis/shop/TsaCustomer.xml

@@ -887,4 +887,28 @@
 		WHERE NUMB = 1
 	</select>
 
+	<!--배치 생년월일 -->
+	<insert id="saveBatchBirth" parameterType="Customer">
+		/*TsaCustomer.saveBatchBirth*/
+		INSERT INTO TB_BATCH_BIRTH (
+		       CUST_NO
+		     , BIRTH_YMD
+		     , REG_DT
+		     , REG_NO
+		     , UPD_DT
+		     , UPD_NO
+		) VALUES (
+		       #{custNo}
+		     , #{birthYmd}
+		     , NOW()
+		     , #{custNo}
+		     , NOW()
+		     , #{custNo}
+		)
+		ON DUPLICATE KEY UPDATE
+		       BIRTH_YMD = #{birthYmd}
+		    ,  UPD_DT = NOW()
+		    ,  UPD_NO = #{updNo}
+	</insert>
+
 </mapper>

+ 149 - 120
src/main/java/com/style24/persistence/mybatis/shop/TsaDsiplay.xml

@@ -1313,80 +1313,94 @@
 	<select id="getContentsPreviewList" parameterType="Contents" resultType="Contents">
 		/* TsaDisplay.getContentsPreviewList */
 		SELECT A.PRE_CONTENTS_SQ
-			 , A.CATE_NO
-			 , A.CONTENTS_LOC
-			 , A.CONTENTS_TYPE
-			 , A.DISP_STDT
-			 , A.DISP_EDDT
-			 , A.DISP_ORD
-			 , A.IMG_PATH1
-			 , A.IMG_PATH2
-			 , A.IMG_PATH3
-			 , A.IMG_PATH4
-			 , A.IMG_PATH5
-			 , A.IMG_PATH6
-			 , A.IMG_PATH7
-			 , A.IMG_PATH8
-			 , A.STR_VAR1
-			 , A.STR_VAR2
-			 , A.STR_VAR3
-			 , A.STR_VAR4
-			 , A.STR_VAR5
-			 , A.STR_VAR6
-			 , A.STR_VAR7
-			 , A.STR_VAR8
-			 , A.STR_TITLE1
-			 , A.STR_TITLE2
-			 , A.STR_TITLE3
-			 , A.STR_TITLE4
+		     , A.CATE_NO
+		     , A.CONTENTS_LOC
+		     , A.CONTENTS_TYPE
+		     , A.DISP_STDT
+		     , A.DISP_EDDT
+		     , A.DISP_ORD
+		     , A.IMG_PATH1
+		     , A.IMG_PATH2
+		     , A.IMG_PATH3
+		     , A.IMG_PATH4
+		     , A.IMG_PATH5
+		     , A.IMG_PATH6
+		     , A.IMG_PATH7
+		     , A.IMG_PATH8
+		     , A.STR_VAR1
+		     , A.STR_VAR2
+		     , A.STR_VAR3
+		     , A.STR_VAR4
+		     , A.STR_VAR5
+		     , A.STR_VAR6
+		     , A.STR_VAR7
+		     , A.STR_VAR8
+		     , A.STR_TITLE1
+		     , A.STR_TITLE2
+		     , A.STR_TITLE3
+		     , A.STR_TITLE4
 		     , A.SUB_TEXT1
-			 , A.SUB_TEXT2
-			 , A.SUB_TEXT3
-			 , A.SUB_TEXT4
+		     , A.SUB_TEXT2
+		     , A.SUB_TEXT3
+		     , A.SUB_TEXT4
 		     , A.HTML
-			 , A.BRAND_GROUP_NO
-			 , A.BRAND_GROUP_IMG
-			 , A.MD_TITLE
-			 ,(SELECT 	GROUP_CONCAT(B.GOODS_CD ORDER BY B.DISP_ORD SEPARATOR ',')
-			    FROM	TMP_CONTENTS_GOODS B
-			   WHERE	B.CATE_NO = A.CATE_NO
-				 AND	B.CONTENTS_LOC = A.CONTENTS_LOC
-				 AND	B.CONTENTS_SQ = A.DISP_ORD
-				 AND	B.CATE_NO = #{cateNo}
-				 AND	B.CONTENTS_LOC = #{contentsLoc}) AS GOODS_CD_LIST
-			 ,(SELECT 	GROUP_CONCAT(B.GOODS_NM ORDER BY B.DISP_ORD SEPARATOR ',')
-			   FROM	TMP_CONTENTS_GOODS B
-			   WHERE	B.CATE_NO = A.CATE_NO
-				 AND	B.CONTENTS_LOC = A.CONTENTS_LOC
-				 AND	B.CONTENTS_SQ = A.DISP_ORD
-				 AND	B.CATE_NO = #{cateNo}
-				 AND	B.CONTENTS_LOC = #{contentsLoc}) AS GOODS_NM_LIST
-			 ,(SELECT 	GROUP_CONCAT(GI.SYS_IMG_NM ORDER BY B.DISP_ORD SEPARATOR ',')
-			   FROM	TMP_CONTENTS_GOODS B
+		     , A.BRAND_GROUP_NO
+		     , A.BRAND_GROUP_IMG
+		     , A.MD_TITLE
+		     ,(SELECT GROUP_CONCAT(B.GOODS_CD ORDER BY B.DISP_ORD SEPARATOR ',')
+		        FROM  TMP_CONTENTS_GOODS B
+		       WHERE  1=1
+		       <if test="contentsLoc != 'SMM012'">
+		         AND  B.CATE_NO = A.CATE_NO
+		       </if>
+		         AND  B.CONTENTS_LOC = A.CONTENTS_LOC
+		         AND  B.CONTENTS_SQ = A.DISP_ORD
+		       <if test="contentsLoc != 'SMM012'">
+		         AND  B.CATE_NO = #{cateNo}
+		       </if>
+		         AND  B.CONTENTS_LOC = #{contentsLoc}) AS GOODS_CD_LIST
+		     ,(SELECT 	GROUP_CONCAT(B.GOODS_NM ORDER BY B.DISP_ORD SEPARATOR ',')
+		       FROM	TMP_CONTENTS_GOODS B
+		       WHERE 1=1
+		       <if test="contentsLoc != 'SMM012'">
+		         AND B.CATE_NO = A.CATE_NO
+		       </if>
+		         AND B.CONTENTS_LOC = A.CONTENTS_LOC
+		         AND B.CONTENTS_SQ = A.DISP_ORD
+		       <if test="contentsLoc != 'SMM012'">
+		         AND  B.CATE_NO = #{cateNo}
+		       </if>
+		         AND B.CONTENTS_LOC = #{contentsLoc}) AS GOODS_NM_LIST
+		     ,(SELECT GROUP_CONCAT(GI.SYS_IMG_NM ORDER BY B.DISP_ORD SEPARATOR ',')
+		       FROM TMP_CONTENTS_GOODS B
 		       JOIN TB_GOODS G ON B.GOODS_CD = G.GOODS_CD
 		       JOIN TB_GOODS_IMG GI ON G.GOODS_CD = GI.GOODS_CD AND G.MAIN_COLOR_CD = COLOR_CD AND GI.DEFAULT_IMG_YN = 'Y'
-			   WHERE	1=1
-			     AND 	B.CATE_NO = A.CATE_NO
-				 AND	B.CONTENTS_LOC = A.CONTENTS_LOC
-				 AND	B.CONTENTS_SQ = A.DISP_ORD
-				 AND	B.CATE_NO = #{cateNo}
-				 AND	B.CONTENTS_LOC = #{contentsLoc}) AS GOODS_IMG_LIST
-			 , A.USE_YN
-			 , A.REG_NO
-			 , A.REG_DT
-			 , A.UPD_NO
-			 , A.UPD_DT
+		       WHERE 1=1
+		       <if test="contentsLoc != 'SMM012'">
+		         AND B.CATE_NO = A.CATE_NO
+		       </if>
+		        AND B.CONTENTS_LOC = A.CONTENTS_LOC
+		        AND B.CONTENTS_SQ = A.DISP_ORD
+		       <if test="contentsLoc != 'SMM012'">
+		        AND  B.CATE_NO = #{cateNo}
+		       </if>
+		        AND B.CONTENTS_LOC = #{contentsLoc}) AS GOODS_IMG_LIST
+		     , A.USE_YN
+		     , A.REG_NO
+		     , A.REG_DT
+		     , A.UPD_NO
+		     , A.UPD_DT
 		FROM TB_CONTENTS_PREVIEW A
 		WHERE A.CATE_NO = #{cateNo}
 		  AND A.CONTENTS_LOC = #{contentsLoc}
 		<if test='cateNo == "1711" or cateNo == "1721"'>
-			<if test='brandGroupNo != null and brandGroupNo != ""'>
-				AND A.BRAND_GROUP_NO = #{brandGroupNo}
-		  	</if>
+		    <if test='brandGroupNo != null and brandGroupNo != ""'>
+		  AND A.BRAND_GROUP_NO = #{brandGroupNo}
+		    </if>
 		</if>
 		<if test='contentsLoc != null and contentsLoc != ""'>
 		  <if test='contentsLoc != "SCM002" and contentsLoc != "SCM003"'>
-			  AND A.USE_YN = 'Y'
+		  AND A.USE_YN = 'Y'
 		  </if>
 		</if>
 		ORDER BY A.DISP_ORD
@@ -1640,51 +1654,60 @@
 
 	<delete id="deleteContentsGoodsTemp" parameterType="Contents">
 		/* TsaDisplay.deleteContentsGoodsTemp */
-		DELETE	FROM TMP_CONTENTS_GOODS
-		WHERE	CATE_NO = #{cateNo}
-		AND 	CONTENTS_LOC = #{contentsLoc}
-		AND 	CONTENTS_SQ = #{contentsSq}
+		DELETE FROM TMP_CONTENTS_GOODS
+		WHERE 1=1
+		<if test="cateNo != null and cateNo != ''">
+		AND CATE_NO = #{cateNo}
+		</if>
+		AND CONTENTS_LOC = #{contentsLoc}
+		AND CONTENTS_SQ = #{contentsSq}
 	</delete>
 
 	<insert id="saveContentsGoodsTemp" parameterType="Contents">
 		/* TsaDisplay.saveContentsGoodsTemp */
 		INSERT INTO TMP_CONTENTS_GOODS
 		(
-			BRAND_GROUP_NO
-		 	,CATE_NO
-			,LEAF_CATE_NO
-			,CONTENTS_LOC
-			,PRE_CONTENTS_SQ
-			,CONTENTS_SQ
-			,GOODS_CD
-			,GOODS_NM
-			,IMG_PATH1
-			,DISP_ORD
-			,REG_NO
-			,REG_DT
+		    BRAND_GROUP_NO
+		    ,CATE_NO
+		    ,LEAF_CATE_NO
+		    ,CONTENTS_LOC
+		    ,PRE_CONTENTS_SQ
+		    ,CONTENTS_SQ
+		    ,GOODS_CD
+		    ,GOODS_NM
+		    ,IMG_PATH1
+		    ,DISP_ORD
+		    ,REG_NO
+		    ,REG_DT
 		)
 		VALUES
 		(
-			 IFNULL(NULLIF(#{brandGroupNo},''),0)
-		 	,#{cateNo}
-		 	,(SELECT LEAF_CATE_NO FROM (SELECT	LEAF_CATE_NO
-					   					FROM	TB_CATE_4SRCH
-					   					WHERE	CATE1_NO = #{cateNo}
-						 				AND		CONTENTS_LOC = #{contentsLoc}) TMP)
-			,#{contentsLoc}
-		 	,#{preContentsSq}
-		 	,#{contentsSq}
-		 	,#{goodsCd}
-		 	,#{goodsNm}
-		 	,#{imgPath1}
-		 	,(SELECT DISP_ORD FROM (SELECT IFNULL((MAX(DISP_ORD) + 1), 1) AS DISP_ORD
-		 							FROM	TMP_CONTENTS_GOODS
-		 							WHERE CATE_NO = #{cateNo}
-		 							  AND CONTENTS_LOC = #{contentsLoc}
-		 	    					  AND CONTENTS_SQ = #{contentsSq}
-		 	    					) TMP)
-		 	,#{regNo}
-		 	,NOW()
+		     IFNULL(NULLIF(#{brandGroupNo},''),0)
+		    ,#{cateNo}
+		    ,(SELECT LEAF_CATE_NO FROM (SELECT	LEAF_CATE_NO
+		                                FROM	TB_CATE_4SRCH
+		                                WHERE	1=1
+		                                <if test="cateNo != null and cateNo != ''">
+		                                AND     CATE1_NO = #{cateNo}
+		                                </if>
+		                                AND		CONTENTS_LOC = #{contentsLoc}) TMP)
+		    ,#{contentsLoc}
+		    ,#{preContentsSq}
+		    ,#{contentsSq}
+		    ,#{goodsCd}
+		    ,#{goodsNm}
+		    ,#{imgPath1}
+		    ,(SELECT DISP_ORD FROM (SELECT IFNULL((MAX(DISP_ORD) + 1), 1) AS DISP_ORD
+		                            FROM	TMP_CONTENTS_GOODS
+		                            WHERE 1=1
+		                            <if test="cateNo != null and cateNo != ''">
+		                            AND CATE_NO = #{cateNo}
+		                            </if>
+		                            AND CONTENTS_LOC = #{contentsLoc}
+		                            AND CONTENTS_SQ = #{contentsSq}
+		                        ) TMP)
+		    ,#{regNo}
+		    ,NOW()
 		)
 	</insert>
 
@@ -1692,10 +1715,13 @@
 	<delete id="deleteContentsGoods" parameterType="Contents">
 		/* TsaDisplay.deleteContentsGoods */
 		DELETE	FROM TB_CATE_GOODS
-		WHERE	CATE_NO = (SELECT LEAF_CATE_NO FROM (SELECT	LEAF_CATE_NO
-													  FROM	TB_CATE_4SRCH
-													  WHERE	CATE1_NO = #{cateNo}
-														AND		CONTENTS_LOC = #{contentsLoc}) TMP)
+		WHERE	CATE_NO = (SELECT LEAF_CATE_NO FROM (SELECT LEAF_CATE_NO
+		                                               FROM TB_CATE_4SRCH
+		                                              WHERE 1=1
+		                                              <if test="cateNo != null and cateNo != ''">
+		                                              AND CATE1_NO = #{cateNo}
+		                                              </if>
+		                                              AND CONTENTS_LOC = #{contentsLoc}) TMP)
 	</delete>
 
 	<!-- 메인전시 컨텐츠 상품 저장 -->
@@ -1708,24 +1734,27 @@
 		, DISP_ORD
 		, REG_NO
 		, REG_DT)
-			(
-				SELECT *
-				FROM (SELECT BRAND_GROUP_NO
-						   , LEAF_CATE_NO
-						   , GOODS_CD
-						   , DISP_ORD
-						   , #{regNo} AS REG_NO
-						   , NOW()
-					  FROM TMP_CONTENTS_GOODS
-					  WHERE CATE_NO = #{cateNo}
-						AND CONTENTS_LOC = #{contentsLoc}
-					 ) B
-			) ON DUPLICATE KEY
+		    (
+		        SELECT *
+		        FROM (SELECT BRAND_GROUP_NO
+		                   , LEAF_CATE_NO
+		                   , GOODS_CD
+		                   , DISP_ORD
+		                   , #{regNo} AS REG_NO
+		                   , NOW()
+		              FROM TMP_CONTENTS_GOODS
+		              WHERE 1=1
+		              <if test="cateNo != null and cateNo != ''">
+		              AND CATE_NO = #{cateNo}
+		              </if>
+		              AND CONTENTS_LOC = #{contentsLoc}
+		            ) B
+		    ) ON DUPLICATE KEY
 		UPDATE
-			GOODS_CD = B.GOODS_CD
-			, DISP_ORD = B.DISP_ORD
-			, REG_NO = B.REG_NO
-			, REG_DT = NOW()
+		    GOODS_CD = B.GOODS_CD
+		    , DISP_ORD = B.DISP_ORD
+		    , REG_NO = B.REG_NO
+		    , REG_DT = NOW()
 	</insert>
 
 	<!-- 메인전시 컨텐츠 탭영역 미리보기 리스트 -->

+ 29 - 3
src/main/java/com/style24/persistence/mybatis/shop/TsaGoods.xml

@@ -3107,10 +3107,13 @@
 		/* TsbGoods.saveGoodsSafeNo */
 		INSERT INTO TB_GOODS_SAFE_NO (
 		    GOODS_CD
+		  , CERT_TARGET_GB
+		  , CERT_FORM_GB
+		  , CERT_TYPE
 		  , CERT_NUM
+		  , CERT_STATE
 		  , CERT_DIV
 		  , CERT_ORGAN_NAME
-		  , CERT_STATE
 		  , CERT_DT
 		  , REG_NO
 		  , REG_DT
@@ -3119,10 +3122,13 @@
 		)
 		VALUES (
 		    #{goodsCd}
+		  , #{certTargetGb}
+		  , #{certFormGb}
+		  , #{certType}
 		  , #{certNum}
+		  , #{certState}
 		  , #{certDiv}
 		  , #{certOrganName}
-		  , #{certState}
 		  , #{certDt}
 		  , #{regNo}
 		  , NOW()
@@ -3130,7 +3136,10 @@
 		  , NOW()
 		)
 		ON DUPLICATE KEY UPDATE
-		       CERT_NUM = #{certNum}
+		       CERT_TARGET_GB = #{certTargetGb}
+		     , CERT_FORM_GB = #{certFormGb}
+		     , CERT_TYPE = #{certType}
+		     , CERT_NUM = #{certNum}
 		     , CERT_DIV = #{certDiv}
 		     , CERT_ORGAN_NAME = #{certOrganName}
 		     , CERT_STATE = #{certState}
@@ -3292,6 +3301,23 @@
 		)
 	</insert>
 	
+	<!-- 상품 안전인증 목록 -->
+	<select id="getGoodsDetailSafe" parameterType="Goods" resultType="GoodsSafeNo">
+		/* TsaGoods.getGoodsDetailSafe */
+		SELECT  GOODS_CD
+		      , CERT_TARGET_GB
+		      , CERT_FORM_GB
+		      , CERT_TYPE
+		      , CERT_NUM
+		      , CERT_STATE
+		      , CERT_DIV
+		      , CERT_ORGAN_NAME
+		      , CERT_DT
+		FROM TB_GOODS_SAFE_NO 
+		WHERE GOODS_CD = #{goodsCd}
+		ORDER BY GOODS_CD
+	</select>
+	
 	<!-- 광고 키워드 목록 -->
 	<select id="getAdKeywordList" parameterType="AdKeyword" resultType="AdKeyword">
 		/* TsaGoods.getAdKeywordList */

+ 0 - 4
src/main/java/com/style24/persistence/mybatis/shop/TsaPoll.xml

@@ -162,7 +162,6 @@
 		        , M.POLL_QVAL9                                                                                                 
 		        , M.POLL_QVAL10    
 		        , M.POLL_QTYPE_NM
-		        , M.PLAN_SQ
 		 FROM
 		 (		      
 		   SELECT A.POLL_SQ
@@ -188,9 +187,7 @@
 		        , B.POLL_QVAL9
 		        , B.POLL_QVAL10
 		        , B.POLL_QTYPE
-		        , P.PLAN_SQ
 		  FROM   TB_POLL A LEFT JOIN TB_POLL_QUESTION B ON A.POLL_SQ = B.POLL_SQ 
-		                   LEFT JOIN TB_PLAN P ON A.POLL_SQ = P.POLL_SQ
 		  WHERE 1=1
 		     AND A.DEL_YN = 'N'
 		     AND B.DEL_YN = 'N'
@@ -227,7 +224,6 @@
 	              , B.POLL_QVAL8
 	              , B.POLL_QVAL9
 	              , B.POLL_QVAL10
-	              , P.PLAN_SQ
          )M
          ORDER BY M.REG_DT DESC
 	

+ 17 - 23
src/main/resources/config/application-run.yml

@@ -27,46 +27,40 @@ spring:
 logging.config: classpath:log/logback-run.xml
 
 domain:
-    admin: //admin.wivismall.com
-    wivis: //www.wivismall.com
-    image: //image.wivismall.com/speedy_image-wivismall
-    uximage: //www.wivismall.com
+    admin: //bos.style24.com
+    style24: //www.style24.com
+    image: //image.istyle24.com/Upload
+    uximage: //bos.style24.com
 
 upload:
-    dext.target.path: /app/was/deploy/admin/data/dext
+    dext.target.path: /files/data/style24/dext
     default:
-        target.path: /app/was/deploy/admin/data
+        target.path: /files/data/style24
         max.size: 10
         allow.extension: jpg|gif|jpeg|png|bmp|txt|doc|docx|ppt|pptx|xls|xlsx|hwp|pdf
-        view: //image.wivismall.com/speedy_image-wivismall
+        view: //image.istyle24.com/Upload
     goods:
-        target.path: /app/was/deploy/admin/data
+        target.path: /files/data/style24/ProductImage
         max.size: 10
         allow.extension: jpg|gif|jpeg|png
-        view: //image.wivismall.com/speedy_image-wivismall/goods
+        view: //image.istyle24.com/Upload/ProductImage
     image:
-        target.path: /app/was/deploy/admin/data
+        target.path: /files/data/style24
         max.size: 10
         allow.extension: jpg|gif|jpeg|png
-        view: //image.wivismall.com/speedy_image-wivismall
+        view: //image.istyle24.com/Upload
     excel:
-        target.path: /app/was/deploy/admin/data
+        target.path: /files/data/style24/excel
         max.size: 10
         allow.extension: xls|xlsx
-        view: //admin.wivismall.com/data/excel
+        view: //image.istyle24.com/Upload/excel
     sample:
-        target.path: /app/was/deploy/admin/data
+        target.path: /files/data/style24/sample
         max.size: 10
         allow.extension: txt|doc|docx|ppt|pptx|xls|xlsx|hwp|pdf
-        view: //admin.wivismall.com/data/sample
+        view: //image.style24.com/Upload/sample
 
-download.path: /app/was/deploy/admin/data
-
-# 사방넷 API
-sabangnet:
-    xml:
-        path: /app/was/deploy/api/data/sabangnet
-        url: http://api.wivismall.com/data/sabangnet
+download.path: /files/data/style24
 
 # SMTP
 mail:
@@ -85,7 +79,7 @@ mail:
 # PG
 pg:
     kcp:
-        log.dir: E:/Run/Payplus
+        log.dir: /logs/style24/kcpLogs/admin
         gw:
             url: paygw.kcp.co.kr
             port: 8090

+ 13 - 13
src/main/resources/config/application-style.yml

@@ -19,40 +19,40 @@ domain:
     admin: //bos.style24.com
     style24: //www.style24.com
     front: //www.style24.com
-    image: //image.istyle24.com
-    cdnimage: //image.istyle24.com
+    image: //image.istyle24.com/Upload
+    cdnimage: //image.istyle24.com/Upload
     uximage: //bos.style24.com
 
 upload:
-    dext.target.path: /usr/local/data/style24/dext
+    dext.target.path: /files/data/style24/dext
 
     default:
-        target.path: /usr/local/data/style24
+        target.path: /files/data/style24
         max.size: 10
         allow.extension: jpg|gif|jpeg|png|bmp|txt|doc|docx|ppt|pptx|xls|xlsx|hwp|pdf
-        view: //image.istyle24.com
+        view: //image.istyle24.com/Upload
     goods:
-        target.path: /usr/local/data/style24/productimage
+        target.path: /files/data/style24/ProductImage
         max.size: 10
         allow.extension: jpg|gif|jpeg|png
         view: //image.istyle24.com/Upload/ProductImage
     image:
-        target.path: /usr/local/data/style24
+        target.path: /files/data/style24
         max.size: 10
         allow.extension: jpg|gif|jpeg|png
-        view: //image.istyle24.com
+        view: //image.istyle24.com/Upload
     excel:
-        target.path: /usr/local/data/style24/excel
+        target.path: /files/data/style24/excel
         max.size: 10
         allow.extension: xls|xlsx
-        view: //image.istyle24.com/excel
+        view: //image.istyle24.com/Upload/excel
     sample:
-        target.path: /usr/local/data/style24/sample
+        target.path: /files/data/style24/sample
         max.size: 10
         allow.extension: txt|doc|docx|ppt|pptx|xls|xlsx|hwp|pdf
-        view: //image.style24.com/sample
+        view: //image.style24.com/Upload/sample
 
-download.path: /usr/local/data
+download.path: /files/data/style24
 
 # PG
 pg:

+ 11 - 11
src/main/webapp/WEB-INF/views/display/MainContentsPopupForm.html

@@ -100,7 +100,7 @@
 			html += '</td>';
 			if(contentsLoc!='SCM002' && contentsLoc!='SCM003'){
 				html += '<td class="aL">';
-				if(contentsLoc!='SMM005'  && contentsLoc!='SMM011' && contentsLoc!='SBM012'){
+				if(contentsLoc!='SMM005'  && contentsLoc!='SMM011' && contentsLoc!='SBM012' && contentsLoc!='SBMM012'){
 					html += '<button type="button" class="btn btn-base btn-lg" onclick="fnAddTitlePopRow(this);">타이틀추가</button>';
 				}
 				if(contentsLoc=='SMM001' || contentsLoc=='SMM002' || contentsLoc=='SBM004' || contentsLoc=='SBMM004' || contentsLoc=='SCM001' || contentsLoc=='SOM001'){
@@ -109,16 +109,16 @@
 				if(contentsLoc=='SBM005' || contentsLoc=='SBMM005'){
 					html += '<button type="button" class="btn btn-base btn-lg" onclick="fnAddBrandDescRow(this);">브랜드소개추가</button>';
 				}
-				if(contentsLoc!='SMM005' && contentsLoc!='SBM005' && contentsLoc!='SBMM005' && contentsLoc!='SGNB001'  && contentsLoc!='SMM011' && contentsLoc!='SBM012'){
+				if(contentsLoc!='SMM005' && contentsLoc!='SBM005' && contentsLoc!='SBMM005' && contentsLoc!='SGNB001'  && contentsLoc!='SMM011' && contentsLoc!='SBM012' && contentsLoc!='SBMM012'){
 					html += '<button type="button" class="btn btn-base btn-lg" onclick="fnAddImgPopRow(this);">이미지추가</button>';
 				}
-				if(contentsLoc!='SMM011' && contentsLoc!='SBM012'){
+				if(contentsLoc!='SMM011' && contentsLoc!='SBM012' && contentsLoc!='SBMM012'){
 					html += '<button type="button" class="btn btn-base btn-lg" onclick="fnAddLinkPopRow(this);">링크추가</button>';
 				}
 				html += '<button type="button" class="btn btn-danger btn-lg" onclick="fnDeleteContentsRow(this);">삭제</button></td>';
 			}
 			html += '</tr>';
-			if(contentsLoc=='SBM004' || contentsLoc=='SBM005'){
+			if(contentsLoc=='SBM004' || contentsLoc=='SBM005' || contentsLoc=='SBMM004'){
 				html += '<tr class="cateTypeTr">';
 				html += '	<th>클릭시<br>페이지창</th>';
 				html += '	<td colspan="3">';
@@ -132,7 +132,7 @@
 				html += '	</td>';
 				html += '</tr>';
 			}
-			if(contentsLoc=='SMM011' || contentsLoc=='SBM012'){
+			if(contentsLoc=='SMM011' || contentsLoc=='SBM012' || contentsLoc=='SBMM012'){
 				html += '<tr class="cateTypeTr">';
 				html += '	<th>동영상구분</th>';
 				html += '	<td colspan="3">';
@@ -376,7 +376,7 @@
 					html += '</tr>';
 			}
 			html += '</thead><tbody>';
-			if(contentsLoc!='SCM002' && contentsLoc!='SCM003' && contentsLoc!='SMM011' && contentsLoc!='SBM012'){
+			if(contentsLoc!='SCM002' && contentsLoc!='SCM003' && contentsLoc!='SMM011' && contentsLoc!='SBM012' && contentsLoc!='SBMM012'){
 				for(var j=1; j<5; j++){
 					var strTitle = eval("result["+i+"].strTitle" + j);
 					var imgPath = eval("result["+i+"].imgPath" + j);
@@ -550,7 +550,7 @@
 		html += '<input name="dispOrd" type="text" class="w80"placeholder="전시순서" style="margin-left:5px; text-align:center"/>';
 		html += '</td>';
 		html += '<td class="aL">';
-		if(contentsLoc!='SCM002' && contentsLoc!='SCM003' && contentsLoc!='SMM011' && contentsLoc!='SBM012'){
+		if(contentsLoc!='SCM002' && contentsLoc!='SCM003' && contentsLoc!='SMM011' && contentsLoc!='SBM012' && contentsLoc!='SBMM012'){
 			if(contentsLoc!='SMM005'){
 				html += '<button type="button" class="btn btn-base btn-lg" id="addTitle'+dataIdx+'" onclick="fnAddTitlePopRow(this);">타이틀추가</button>';
 			}
@@ -567,7 +567,7 @@
 		}
 		html += '<button type="button" class="btn btn-danger btn-lg" onclick="fnDeleteContentsRow(this);">삭제</button></td>';
 		html += '</tr>';
-		if(contentsLoc=='SBM004' || contentsLoc=='SBM005'){
+		if(contentsLoc=='SBM004' || contentsLoc=='SBM005' || contentsLoc=='SBMM004'){
 			html += '<tr class="cateTypeTr">';
 			html += '	<th>클릭시<br>페이지창</th>';
 			html += '	<td colspan="3">';
@@ -576,7 +576,7 @@
 			html += '	</td>';
 			html += '</tr>';
 		}
-		if(contentsLoc=='SMM011' || contentsLoc=='SBM012'){
+		if(contentsLoc=='SMM011' || contentsLoc=='SBM012' || contentsLoc=='SBMM012'){
 			html += '<tr class="cateTypeTr">';
 			html += '	<th>동영상구분</th>';
 			html += '	<td colspan="3">';
@@ -924,7 +924,7 @@
 				i++;
 			});
 
-			if(contentsLoc=='SMM011' || contentsLoc=='SBM012'){
+			if(contentsLoc=='SMM011' || contentsLoc=='SBM012' || contentsLoc=='SBMM012'){
 				var thisIdx = $(this).find("input[name=tableIdx]").val();
 				strVar1 = $(this).find("input:radio[name=tvPlayer"+thisIdx+"]:checked").val();
 				strVar2 = $(this).find("input[name=tvMediaKey"+thisIdx+"]").val();
@@ -936,7 +936,7 @@
 
 			var dispOrd = $(this).find("[name=dispOrd]").val();
 
-			if(contentsLoc=='SBM004' || contentsLoc=='SBM005'){
+			if(contentsLoc=='SBM004' || contentsLoc=='SBM005' || contentsLoc=='SBMM004'){
 				var thisIdx = $(this).find("input[name=tableIdx]").val();
 				contentsType = $(this).find("input:radio[name=pageTarget"+thisIdx+"]:checked").val();
 			}

+ 59 - 22
src/main/webapp/WEB-INF/views/display/MainGnbContentsPopupForm.html

@@ -99,11 +99,13 @@
 			html += '		<label class="rdoBtn"><input type="radio" name="cateType'+addIdx+'" value="L" onclick="fnChangeCateType(this,'+addIdx+');"/>이벤트링크</label>';
 			html += '	</td>';
 			html += '</tr>';
-		}else if(contentsLoc=='SBM002'){
+		}else if(contentsLoc=='SBM002' || contentsLoc=='SBMM002'){
 			html += '<tr class="cateTypeTr">';
 			html += '	<th>유형선택</th>';
 			html += '	<td colspan="3">';
-			html += '		<label class="rdoBtn"><input type="radio" name="cateType'+addIdx+'" value="L" checked="checked"/>이벤트링크</label>';
+			html += '		<label class="rdoBtn"><input type="radio" name="cateType'+addIdx+'" value="L" onclick="fnChangeGnbType(this,'+addIdx+');" checked="checked"/>이벤트링크</label>';
+			html += '		<label class="rdoBtn"><input type="radio" name="cateType'+addIdx+'" value="B" onclick="fnChangeGnbType(this,'+addIdx+');" />룩북</label>';
+			html += '		<label class="rdoBtn"><input type="radio" name="cateType'+addIdx+'" value="P" onclick="fnChangeGnbType(this,'+addIdx+');" />기획전</label>';
 			html += '	</td>';
 			html += '</tr>';
 		}
@@ -144,7 +146,7 @@
 				html += '		</td>';
 				html += '	</tr>';
 			}
-		}else if(contentsLoc=='SBM002'){
+		}else if(contentsLoc=='SBM002'||contentsLoc=='SBMM002'){
 			html += '	<tr name="tabLinkTitleRow">';
 			html += '		<th>타이틀</th>';
 			html += '		<td><input name="title" type="text" maxlength="200" data-valid-name="타이틀" value=""/></td>';
@@ -371,7 +373,7 @@
 					gtabNm = "아울렛";
 				}
 
-				if(radioValue=='L'){
+				if(radioValue=='L' || radioValue=='B' || radioValue=='P'){
 					gtabNm = $(this).find("input[name=title]").val();
 					linkUrl = $(this).find("input[name=link]").val();
 				}
@@ -604,9 +606,21 @@
 			html += '			<th>유형선택</th>';
 			html += '			<td colspan="3">';
 			if(result[i].brandGroupNo!='' && result[i].brandGroupNo!=null){
+				html += '<label class="rdoBtn"><input type="radio" name="cateType'+i+'" value="L" onclick="fnChangeGnbType(this,'+i+');"';
 				if(result[i].contentsType=='L'){
-					html += '<label class="rdoBtn"><input type="radio" name="cateType'+i+'" value="L" checked="checked"/>이벤트링크</label>';
+					html += ' checked="checked" ';
 				}
+				html += '/>이벤트링크</label>';
+				html += '<label class="rdoBtn"><input type="radio" name="cateType'+i+'" value="B" onclick="fnChangeGnbType(this,'+i+');"';
+				if(result[i].contentsType=='B'){
+					html += ' checked="checked" ';
+				}
+				html += ' />룩북</label>';
+				html += '<label class="rdoBtn"><input type="radio" name="cateType'+i+'" value="P" onclick="fnChangeGnbType(this,'+i+');"';
+				if(result[i].contentsType=='P'){
+					html += ' checked="checked" ';
+				}
+				html += ' />기획전</label>';
 			}else{
 				if(result[i].contentsType=='C'){
 					html += '<label class="rdoBtn"><input type="radio" name="cateType'+i+'" value="C" onclick="fnChangeCateType(this,'+i+');" checked="checked"/>대카테고리</label>';
@@ -650,23 +664,7 @@
 			html += '		</tr>';
 			html += '	</thead>';
 			html += '<tbody>';
-			if(result[i].contentsType=='C'){
-				html += '	<tr name="tabCateRow">';
-				html += '		<th>카테고리</th>';
-				html += '		<td colspan="3">카테고리선택';
-				html += '			<select name="cate1List">';
-				html += '				<option value="">[선택]</option>';
-				for(let i=0; i<cate1List.length; i++){
-					if(cateNo == cate1List[i].cd){
-						html += '<option value="'+cate1List[i].cd+'" selected="selected">['+cate1List[i].cd+'] '+cate1List[i].cdNm+'</option>';
-					}else{
-						html += '<option value="'+cate1List[i].cd+'">['+cate1List[i].cd+'] '+cate1List[i].cdNm+'</option>';
-					}
-				}
-				html += '			</select>';
-				html += '		</td>';
-				html += '	</tr>';
-			}else if(result[i].contentsType=='L'){
+			if(result[i].brandGroupNo!='' && result[i].brandGroupNo!=null){
 				html += '	<tr name="tabLinkTitleRow">';
 				html += '		<th>타이틀</th>';
 				html += '		<td><input name="title" type="text" maxlength="200" data-valid-name="타이틀" value="'+result[i].gtabNm+'"/></td>';
@@ -675,7 +673,35 @@
 				html += '		<th>링크 (없으면 #)</th>';
 				html += '		<td><input name="link" type="text" maxlength="200" data-valid-name="링크" value="'+result[i].linkUrl+'"/></td>';
 				html += '	</tr>';
+			}else{
+				if(result[i].contentsType=='C'){
+					html += '	<tr name="tabCateRow">';
+					html += '		<th>카테고리</th>';
+					html += '		<td colspan="3">카테고리선택';
+					html += '			<select name="cate1List">';
+					html += '				<option value="">[선택]</option>';
+					for(let i=0; i<cate1List.length; i++){
+						if(cateNo == cate1List[i].cd){
+							html += '<option value="'+cate1List[i].cd+'" selected="selected">['+cate1List[i].cd+'] '+cate1List[i].cdNm+'</option>';
+						}else{
+							html += '<option value="'+cate1List[i].cd+'">['+cate1List[i].cd+'] '+cate1List[i].cdNm+'</option>';
+						}
+					}
+					html += '			</select>';
+					html += '		</td>';
+					html += '	</tr>';
+				}else if(result[i].contentsType=='L'){
+					html += '	<tr name="tabLinkTitleRow">';
+					html += '		<th>타이틀</th>';
+					html += '		<td><input name="title" type="text" maxlength="200" data-valid-name="타이틀" value="'+result[i].gtabNm+'"/></td>';
+					html += '	</tr>';
+					html += '	<tr name="tabLinkRow">';
+					html += '		<th>링크 (없으면 #)</th>';
+					html += '		<td><input name="link" type="text" maxlength="200" data-valid-name="링크" value="'+result[i].linkUrl+'"/></td>';
+					html += '	</tr>';
+				}
 			}
+
 			html += '</tbody>';
 			html += '</table>';
 			tableIdx = i;
@@ -691,6 +717,17 @@
 		tableIdx = tableIdx+1;
 	}
 
+	var fnChangeGnbType = function (obj, idx){
+		let chkType = $("#tabTable"+idx).find("input:radio[name=cateType"+idx+"]:checked").val();
+		if(chkType=='L'){
+			$("#tabTable"+idx).find("input[name=link]").val('');
+		}else if(chkType=='B'){
+			$("#tabTable"+idx).find("input[name=link]").val('/display/lookbook/main/form?brandGroupNo='+brandGroupNo);
+		}else{
+			$("#tabTable"+idx).find("input[name=link]").val('/planning/main/form?brandGroupNo='+brandGroupNo);
+		}
+	}
+
 	$(document).ready(function() {
 		$("#gnbTabList").disableSelection();
 		$("#gnbTabList").sortable({

+ 17 - 4
src/main/webapp/WEB-INF/views/display/MainListForm.html

@@ -421,7 +421,17 @@
 			var contentsLocCd = contentsLocList[i].cd;
 			contentsLocCd = contentsLocCd.replace(/[0-9]/g, "");
 			if(contentsLocCd==clocPrefix){
-				contentsLocHtml += '<option value="'+contentsLocList[i].cd+'">['+contentsLocList[i].cd+'] '+contentsLocList[i].cdNm+'</option>';
+				if(cate1No=='1700'){
+					if(contentsLocList[i].cd != 'SMM012'){
+						contentsLocHtml += '<option value="'+contentsLocList[i].cd+'">['+contentsLocList[i].cd+'] '+contentsLocList[i].cdNm+'</option>';
+					}
+				}else if(cate1No=='1720'){
+					if(contentsLocList[i].cd != 'SMM009'){
+						contentsLocHtml += '<option value="'+contentsLocList[i].cd+'">['+contentsLocList[i].cd+'] '+contentsLocList[i].cdNm+'</option>';
+					}
+				}else{
+					contentsLocHtml += '<option value="'+contentsLocList[i].cd+'">['+contentsLocList[i].cd+'] '+contentsLocList[i].cdNm+'</option>';
+				}
 			}
 		}
 
@@ -647,9 +657,9 @@
 		var contentsLoc = $(obj).closest("td").find('input:hidden[name="contentsLoc"]').val();
 
 		// 브랜드픽, MD추천 다른 팝업 사용
-		if(contentsLoc=='SMM007'||contentsLoc=='SMM009'){
+		if(contentsLoc=='SMM007'||contentsLoc=='SMM009'||contentsLoc=='SMM012'){
 			cfnOpenMainMultiContentsPopup(cateNo, contentsLoc, brandGroupNo);
-		}else if(contentsLoc=='STAB001' || contentsLoc=='STAB002' || contentsLoc=='SBM002'){
+		}else if(contentsLoc=='STAB001' || contentsLoc=='STAB002' || contentsLoc=='SBM002' || contentsLoc=='SBMM002'){
 			cfnOpenMainGnbContentsPopup(cateNo, contentsLoc, brandGroupNo);
 		}else{
 			cfnOpenMainContentsPopup(cateNo, contentsLoc, brandGroupNo);
@@ -774,7 +784,7 @@
 		var val = $("#searchForm select[name=cate1No]").val();
 		var cate1No = '';
 
-		if(val.split(',')[1]=='Y'){
+		/*if(val.split(',')[1]=='Y'){
 			if(val.split(',')[0]=='1711' || val.split(',')[0]=='1721'){
 				cate1No = '2100';
 			}else if(val.split(',')[0]=='1713' || val.split(',')[0]=='1723'){
@@ -784,6 +794,9 @@
 			}
 		}else{
 			cate1No = $("#searchForm select[name=cate2No]").val().split(',')[0];
+		}*/
+		if(val.split(',')[1]!='Y'){
+			cate1No = $("#searchForm select[name=cate2No]").val().split(',')[0];
 		}
 
 		var data = {

+ 3 - 3
src/main/webapp/WEB-INF/views/display/MainMultiContentsPopupForm.html

@@ -27,7 +27,7 @@
 					</li>
 					<li class="aR">
 						<button type="button" class="btn btn btn-base btn-sm" th:if="${contentsLoc == 'SMM007'}" onclick="fnAddBrand(this);">브랜드 추가</button> <!--id="btnBrandAddRow"-->
-						<button type="button" class="btn btn btn-base btn-sm" th:if="${contentsLoc == 'SMM009'}" onclick="fnAddBrand(this);">MD 탭 추가</button>
+						<button type="button" class="btn btn btn-base btn-sm" th:if="${contentsLoc == 'SMM009' or contentsLoc == 'SMM012'}" onclick="fnAddBrand(this);">MD 탭 추가</button>
 						<button type="button" class="btn btn btn-dark btn-sm" id="btnMultiPopSave">임시저장</button>
 						<input type="hidden" name="uploadDefaultUrlMultiPop" id="uploadDefaultUrlMultiPop" th:value="${@environment.getProperty('upload.image.view') + '/contents/'}"/>
 						<input type="hidden" name="uploadDefaultBrandUrlPop" id="uploadDefaultBrandUrlPop" th:value="${@environment.getProperty('upload.image.view') + '/contents/brand/'}"/>
@@ -102,7 +102,7 @@
 			html += '<button type="button" class="btn btn-base btn-lg" onclick="fnAddGoodsRow(this,this,this);">상품추가</button>';
 			html += '<button type="button" class="btn btn-danger btn-lg" onclick="fnDeleteBrandRow(this);">삭제</button></td>';
 			html += '</tr>';
-			if(contentsLoc=='SMM009'){
+			if(contentsLoc=='SMM009' || contentsLoc=='SMM012'){
 				html += '<tr>';
 				html += '<th>MD탭문구</th>';
 				html += '<td colspan="3"><input type="text" name="mdTitle" id="mdTitle" style="width:30%;" value="' + result[i].mdTitle + '"></td>';
@@ -229,7 +229,7 @@
 		html += '<button type="button" class="btn btn-base btn-lg" onclick="fnAddGoodsRow(this,this,this);">상품추가</button>';
 		html += '<button type="button" class="btn btn-danger btn-lg" onclick="fnDeleteBrandRow(this);">삭제</button></td>';
 		html += '</tr>';
-		if(contentsLoc=='SMM009'){
+		if(contentsLoc=='SMM009' || contentsLoc=='SMM012'){
 			html += '<tr>';
 			html += '<th>MD탭문구</th>';
 			html += '<td colspan="3"><input type="text" name="mdTitle" id="mdTitle" style="width:30%;"></td>';

+ 141 - 40
src/main/webapp/WEB-INF/views/goods/GoodsDetailForm.html

@@ -78,7 +78,7 @@
 							<li><a href="#goodstab3">상품상세정보</a></li>
 							<li id="goodsNotiTab"><a href="#goodstab4">고시정보</a></li>
 							<li id="goodsComposeTab" style="display:none;"><a href="#goodstab5">구성상품</a></li>
-							<!-- <li><a href="#goodstab6">안전인증</a></li> -->
+							<li id="goodsSafeTab"><a href="#goodstab6">안전인증</a></li>
 							<li><a href="#goodstab7">변경이력</a></li>
 						</ul>
 					</div>
@@ -369,12 +369,6 @@
 										</td>
 									</tr>
 									<tr>
-										<!-- <th>안전인증번호</th>
-										<td>
-											<input type="text" class="w150" id="certNum" name="certNum"  maxlength="20"/>
-											<input type="hidden" id="certNumOrg" name="certNumOrg"/>
-											<button type="button" class="btn btn-success btn-lg" id="btnGoodsSafetyCertNum">안전인증</button>
-										</td> -->
 										<th>판매기간<em class="required" title="필수"></em></th>
 										<td colspan="3">
 											<input name="sellStYMD" id="sellStYMD" type="text" class="w80 schDate" maxlength="10" required="required" data-valid-name="판매시작일" />
@@ -570,49 +564,71 @@
 							</div>
 							<!-- //TAB6 CONTENTS AREA -->
 						</li>
-						<!-- TAB6 : 이력정보 -->
-						<!-- <li class="tab" id="goodstab6">
-							TAB8 CONTENTS AREA
+						<!-- TAB6 : 안전인증 -->
+						<li class="tab" id="goodstab6">
 							<div class="panelStyle">
-								<table class="frmStyle" th:with="uploadGoodsUrl=${@environment.getProperty('upload.goods.view')},uxImgUrl=${@environment.getProperty('domain.uximage')}">
+								<table class="frmStyle">
 									<colgroup>
-										<col width="10%"/>
-										<col width="40%"/>
-										<col width="10%"/>
+										<col width="11%"/>
+										<col width="22%"/>
+										<col width="11%"/>
+										<col width="22%"/>
+										<col width="11%"/>
 										<col/>
 									</colgroup>
 									<tr>
 										<th>인증대상</th>
-										<td colspan="3"></td>
+										<td colspan="5">
+											<label class="rdoBtn" th:if="${certTargetGbList}" th:each="oneData, status : ${certTargetGbList}">
+												<input type="radio" name="certTargetGb" th:value="${oneData.cd}" th:text="${oneData.cdNm}"/>
+											</label>
+											<input type="hidden" id="orgCertTargetGb" name="orgCertTargetGb"/>
+										</td>
 									</tr>
 									<tr>	
 										<th>인증형태</th>
-										<td colspan="3"></td>
-									</tr>
-									<tr>	
+										<td>
+											<select  name="certFormGb" id="certFormGb" >
+												<option value="">[선택]</option>
+												<option th:if="${certFormGbList}" th:each="oneData, status : ${certFormGbList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
+											</select>
+											<input type="hidden" id="orgCertformGb" name="orgCertformGb"/>
+										</td>
 										<th>인증타입</th>
-										<td colspan="3"></td>
-									</tr>
-									<tr>	
+										<td>
+											<select  name="certType" id="certType" >
+												<option value="">[선택]</option>
+												<option th:if="${certTypeList}" th:each="oneData, status : ${certTypeList}" th:value="${oneData.cd}" th:text="${'[' + oneData.cd + '] ' + oneData.cdNm}"></option>
+											</select>
+											<input type="hidden" id="orgCertType" name="orgCertType"/>
+										</td>
 										<th>인증번호</th>
-										<td  colspan="3"></td>
+										<td>
+											<input type="text" class="w200" id="certNum" name="certNum"  maxlength="20"/>
+											<input type="hidden" id="certNumOrg" name="certNumOrg"/>
+											
+										</td>
 									</tr>
 									<tr>	
 										<th>인증상태</th>
-										<td></td>
-										<th>인증구분</th>
-										<td></td>
-									</tr>
-									<tr>	
+										<td><span id="certStateTxt"></span></td>
 										<th>인증기관</th>
-										<td></td>
+										<td><span id="certOrganNameTxt"></span></td>
 										<th>인증일</th>
-										<td></td>
+										<td><span id="certDtTxt"></span></td>
+									</tr>
+									<tr>
+										<th>인증구분</th>
+										<td colspan="5"><span id="certDivTxt"></span></td>
 									</tr>
 								</table>
+								<ul class="panelBar marT10">
+								<li class="right">
+								<button type="button" class="btn  btn-success btn-lg" id="btnGoodsSafetyCertNum">안전인증</button>
+								</li>
+								</ul>
 							</div>
-							//TAB5 CONTENTS AREA
-						</li> -->
+						</li>
 						<!-- //TAB7 : 이력정보 -->
 						<li class="tab" id="goodstab7">
 							<!-- TAB8 CONTENTS AREA -->
@@ -1110,12 +1126,14 @@
 			if ("G056_S" == result.goodsType){
 				if (result.selfGoodsYn == "Y") $('#goodsDetailForm #goodsComposeTab').css('display','block');
 				$('#goodsDetailForm #goodsNotiTab').css('display','none');
+				$('#goodsDetailForm #goodsSafeTab').css('display','none');
 				$('#goodsDetailForm input[name=sellFeeRate]').attr('readonly', true);
 				$('#goodsDetailForm input[name=listPrice]').attr('readonly', true);
 				$('#goodsDetailForm input[name=currPrice]').attr('readonly', true);
 			}else if ("G056_D" == result.goodsType){
 				if (result.selfGoodsYn == "Y") $('#goodsDetailForm #goodsComposeTab').css('display','block');
 				$('#goodsDetailForm #goodsNotiTab').css('display','none');
+				$('#goodsDetailForm #goodsSafeTab').css('display','none');
 				$('#goodsDetailForm input[name=sellFeeRate]').attr('readonly', true);
 			}
 			
@@ -1136,7 +1154,8 @@
 			fnGoodsDetailNotiInfoSearch(params);
 			//구매등급
 			fnGoodsDetailOrderGradeSearch(params);
-			
+			//안전인증
+			fnGoodsDetailSafeNoSearch();
 			//구성상품
 			if ("G056_S" == result.goodsType || "G056_D" == result.goodsType){
 				fnGoodsComposeListSearch(params);
@@ -1167,6 +1186,13 @@
 		cfnAjaxSubmit("/goods/detail/order/grade/list", "json", fnGoodsDetailOrderGradeSearchCallback, params);
 	}
 	
+	//안전인증
+	var fnGoodsDetailSafeNoSearch = function() {
+		var params = new Object();
+		params.goodsCd = $('#goodsDetailForm input[name=goodsCd]').val();
+		cfnAjaxSubmit("/goods/detail/safe", "json", fnGoodsDetailSafeNoSearchCallback, params);
+	}
+	
 	//구성상품
 	var fnGoodsComposeListSearch = function(params) {
 		if ("G056_S" == params.goodsType){	//세트
@@ -1229,6 +1255,33 @@
 		});
 	}
 
+	//안전인증 콜백
+	var fnGoodsDetailSafeNoSearchCallback = function(result){
+		if (result == null) return;
+			
+		if (result.certTargetGb == "G083_1"){
+			$("#goodsDetailForm input:radio[name=certTargetGb]:input[value='G083_1']").trigger('click');
+		}else if (result.certTargetGb == "G083_2"){
+			$("#goodsDetailForm input:radio[name=certTargetGb]:input[value='G083_2']").trigger('click');
+		}else if (result.certTargetGb == "G083_3"){
+			$("#goodsDetailForm input:radio[name=certTargetGb]:input[value='G083_3']").trigger('click');
+		}
+		$("#goodsDetailForm input[name=orgCertTargetGb]").val(result.certTargetGb);
+		$("#goodsDetailForm select[name=certFormGb]").val(result.certFormGb);
+		$("#goodsDetailForm input[name=orgCertFormGb]").val(result.certFormGb);
+		$("#goodsDetailForm select[name=certType]").val(result.certType);
+		$("#goodsDetailForm input[name=orgCertType]").val(result.certType);
+		$("#goodsDetailForm input[name=certNum]").val(result.certNum);
+		$("#goodsDetailForm input[name=orgCertNum]").val(result.certNum);
+		$('#goodsDetailForm').find('#certStateTxt').html(result.certState);
+		$('#goodsDetailForm').find('#certTargetGbTxt').html(result.certTargetGb);
+		
+		$('#goodsDetailForm').find('#certOrganNameTxt').html(result.certOrganName);
+		$('#goodsDetailForm').find('#certDivTxt').html(result.certDiv);
+		$('#goodsDetailForm').find('#certDtTxt').html(!gagajf.isNull(result.certDt) ? result.certDt.toDate("YYYYMMDD").format("YYYY-MM-DD") : '');
+
+	}
+	
 	//상품명 길이표시
 	$("#goodsDetailForm input[name=goodsNm]").bind('focus focusout input keyup keydown paste change', function () {
 		fnDataLengthCheck('goodsNm',200);
@@ -2302,25 +2355,73 @@
 	
 	// 안전인증
 	$("#btnGoodsSafetyCertNum").on("click", function(){
-/*
-		if($("#goodsDetailForm  input[name=certNum]").val() == $("#goodsDetailForm  input[name=certNumOrg]").val()){
-			mcxDialog.alert("안전인증번호가 변경되지 않았습니다.");
-			return false;
-		}
-*/
-		mcxDialog.confirm('안전인증번호를 변경 하시겠습니까?', {
+		
+		if (!fnGoodsSafetyCertNumCheck()) return false;
+
+		mcxDialog.confirm('안전인증정보(API)를 변경 하시겠습니까?', {
 			cancelBtnText: "취소",
 			sureBtnText: "확인",
 			sureBtnClick: function(){
 				var data = {  goodsCd : $('#goodsDetailForm input[name=goodsCd]').val()
+							, certTargetGb : $("#goodsDetailForm input[name=certTargetGb]:checked").val()
+							, certFormGb : $("#goodsDetailForm select[name=certFormGb]").val()
+							, certType : $("#goodsDetailForm select[name=certType]").val()
 							, certNum : $("#goodsDetailForm input[name=certNum]").val()
 							};
 				var jsonData = JSON.stringify(data);
-				gagajf.ajaxJsonSubmit('/goods/detail/certNum/save', jsonData );  //, fnGoodsDeailSearch
+				 gagajf.ajaxJsonSubmit('/goods/detail/certNum/save', jsonData, fnGoodsDetailSafeNoSearch);
 			}
 		});
 	});
 	
+	var fnGoodsSafetyCertNumCheck = function(){
+		
+		if(gagajf.isNull($("#goodsDetailForm input[name=certTargetGb]:checked").val())){
+			mcxDialog.alert("인증대상을 선택해 주세요.");
+			return false;
+		}
+		
+		// 인증대상이 아니면 스킵
+		if ("G083_1" != $("#goodsDetailForm input[name=selCertTargetGb]:checked").val()){
+			return true;
+		}
+		
+		if(gagajf.isNull($("#goodsDetailForm select[name=certFormGb]").val())){
+			mcxDialog.alertC("인증형태를 선택해 주세요.", {
+				sureBtnText: "확인",
+				sureBtnClick: function() {
+					$("#goodsDetailForm select[name=certFormGb]").focus();
+				}
+			});
+			return false;
+		}
+		
+		if(gagajf.isNull($("#goodsDetailForm select[name=certType]").val())){
+			mcxDialog.alertC("인증타입를 선택해 주세요.", {
+				sureBtnText: "확인",
+				sureBtnClick: function() {
+					$("#goodsDetailForm select[name=certType]").focus();
+				}
+			});
+			return false;
+		}
+		
+		//인증타입이 공급자적합성일 경우 인증번호 미입력
+		if( "G081_3" != $("#goodsDetailForm select[name=certType]").val()){
+			if(gagajf.isNull($("#goodsDetailForm input[name=certNum]").val())){
+				mcxDialog.alertC("인증번호를 선택해 주세요.", {
+					sureBtnText: "확인",
+					sureBtnClick: function() {
+						$("#goodsDetailForm input[name=certNum]").focus();
+					}
+				});
+				return false;
+			}
+		}
+		
+		return true;
+	}
+	
 	// 상품구매등급 
 	var fnGoodsOrderGrade = function(){
 		

+ 10 - 0
src/main/webapp/WEB-INF/views/marketing/PlanDetailPopupForm.html

@@ -1723,6 +1723,16 @@
 				$("#attendTd").css('display','none');
 			}
 			 
+			 if (planInfo.planGb =='E') {
+				 $("#pollTr").show();
+				
+			}else{
+				 $("#pollTr").hide();
+			}
+			 
+			 
+			
+			 
 			 
 			gridOptionsFGBrandList.api.setRowData(planBrandList);
 			gridOptionsFGCateList.api.setRowData(planCateList);

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

@@ -18,7 +18,7 @@
     } else if (location.host.indexOf("qas") > -1) {
     	gAuthkey = "gx9EHEhXzTpbdxWjty/oHh9cfVi5WA5X4BV71AHaC/ORN/1fcs8nTTd4oUUvC5WhHqEa6Wt8cfmCBJ9w/pJpRhDd+tVu6kPDt9bxZL9n0bvaUn2rrbmJMA+HC9gzahwdEOcjr6ZOmNSEd6N0xN2BDBk55hvfPw02R77XjVuZrQU=";
     } else {
-    	gAuthkey = "YOUQYUILPZSEXURW";
+    	gAuthkey = "DUAYCUDVOFWITARW";
     }
 
     win.dextuploadx5Configuration = {

+ 1 - 1
src/main/webapp/ux/plugins/gaga/gaga.summernote.js

@@ -126,7 +126,7 @@ var gagaSn = {
 		$.ajax({
 			data : formData,
 			type : 'POST',
-			url : '/common/file/upload?subDir=/Upload/editor',
+			url : '/common/file/upload?subDir=/editor',
 			cache : false,
 			contentType : false,
 			enctype : 'multipart/form-data',