Преглед изворни кода

기획전, 이벤트 접근제한 수정

sowon4187 пре 5 година
родитељ
комит
be70770356

+ 20 - 0
src/main/java/com/style24/front/biz/dao/TsfPlanningDao.java

@@ -422,4 +422,24 @@ public interface TsfPlanningDao {
 	 */
 	void deleteEntryReplyAttach(Plan plan);
 	
+	/**
+	 * 기획전/이벤트 접근 고객 리스트
+	 *
+	 * @param Plan
+	 * @return Collection<Plan>
+	 * @author sowon
+	 * @date 2021. 4. 22
+	 */
+	Plan getCustomerGubunAccessibleList(Plan plan);
+	
+	/**
+	 * 기획전/이벤트 접근 고객 리스트
+	 *
+	 * @param Plan
+	 * @return Collection<Plan>
+	 * @author sowon
+	 * @date 2021. 4. 22
+	 */
+	Collection<Plan> getCustomerGradeAccessibleList(Plan plan);
+	
 }

+ 10 - 4
src/main/java/com/style24/front/biz/service/TsfPlanningService.java

@@ -140,18 +140,23 @@ public class TsfPlanningService {
 		if ("N".equals(planningDao.getNewCustomerAccessibleYn(plan))) {
 			msg = "신규회원만 접근 가능합니다.";
 		}
-
+		
 		if (TsfSession.isLogin()) {
 			// 고객구분접근가능여부 조회
 			plan.setCustGb(TsfSession.getCustGb());
 			if ("N".equals(planningDao.getCustomerGubunAccessibleYn(plan))) {
-				msg = TsfSession.getInfo().getCustGbNm() + "만 접근이 가능합니다.";
+				msg = planningDao.getCustomerGubunAccessibleList(plan).getCustGb() + "만 접근이 가능합니다.";
 			}
 
+			String custGrade = "";
 			// 고객등급접근가능여부 조회
 			plan.setCustGrade(TsfSession.getInfo().getCustGrade());
 			if ("N".equals(planningDao.getCustomerGradeAccessibleYn(plan))) {
-				msg = TsfSession.getInfo().getCustGradeNm() + " 회원만 접근 가능합니다.";
+				Iterator<Plan> iter = planningDao.getCustomerGradeAccessibleList(plan).iterator();
+				while (iter.hasNext()) {
+					custGrade += iter.next().getCustGrade()+ " ";
+				}
+				msg = custGrade+ " 회원만 접근 가능합니다.";
 			}
 		}
 
@@ -159,7 +164,8 @@ public class TsfPlanningService {
 			// 웹제휴채널접근가능여부 조회
 			plan.setAfLinkCd(TsfSession.getAttribute("afLinkCd"));
 			if ("N".equals(planningDao.getAfLinkAccessibleYn(plan))) {
-				msg = commonDao.getAfLinkName(TsfSession.getAttribute("afLinkCd")) + " 채널만 접근 가능합니다.";
+				//msg = commonDao.getAfLinkName(TsfSession.getAttribute("afLinkCd")) + " 채널만 접근 가능합니다.";
+				msg = "제휴 채널을 통해서만 접근 가능합니다. ";
 			}
 		}
 

+ 1 - 0
src/main/java/com/style24/front/biz/web/TsfPlanningController.java

@@ -335,6 +335,7 @@ public class TsfPlanningController extends TsfBaseController {
 		ModelAndView mav = new ModelAndView();
 
 		// 쿠폰 - 기본정보
+		coupon.setPlanCouponStat("Y");
 		mav.addObject("couponDetailInfo", couponService.getCouponDetailInfo(coupon));
 		mav.setViewName(super.getDeviceViewName("planning/PlanningCouponDetailForm"));
 		return mav;

+ 2 - 0
src/main/java/com/style24/persistence/mybatis/shop/TsfCoupon.xml

@@ -813,7 +813,9 @@
 		                       END)                              AS EXPIRE_YN /*만료여부*/
 		            FROM   TB_CUST_COUPON CC
 		            WHERE  1 = 1
+		            <if test="planCouponStat == null and planCouponStat == ''">
 		            AND    CC.CUST_NO = #{custNo}
+		            </if>
 		            AND    CC.USED_DT IS NULL /*사용하지않은쿠폰만*/
 		            AND    CC.AVAIL_EDDT >= DATE_ADD(NOW(), INTERVAL -3 MONTH) /*최근3개월쿠폰만*/
 		            GROUP  BY CC.CPN_ID, DATE_FORMAT(CC.AVAIL_STDT,'%Y.%m.%d %H:%i'), DATE_FORMAT(CC.AVAIL_EDDT,'%Y.%m.%d %H:%i')

+ 28 - 6
src/main/java/com/style24/persistence/mybatis/shop/TsfPlanning.xml

@@ -92,9 +92,9 @@
 		        FROM   TB_PLAN P
 		        WHERE  P.PLAN_GB = 'P' /*기획전*/
 		        AND    P.SITE_CD = #{siteCd}
-		        <if test="frontGb != null and frontGb != ''">
+		       <!--  <if test="frontGb != null and frontGb != ''">
 		        AND    P.FRONT_GB LIKE CONCAT('%',#{frontGb},'%')
-		        </if>
+		        </if> -->
 		        AND    NOW() BETWEEN P.DISP_STDT AND P.DISP_EDDT
 		        AND    P.DEL_YN = 'N' /*삭제안된 기획전*/
 		        AND    P.OPEN_YN = 'Y' /*오픈된 기획전*/
@@ -160,9 +160,9 @@
 		    AND    P.PLAN_SQ = #{planSq}
 		    AND    P.PLAN_GB = 'P' /*기획전*/
 		    AND    P.SITE_CD = #{siteCd}
-		    <if test="frontGb != null and frontGb != ''">
+		  <!--   <if test="frontGb != null and frontGb != ''">
 		    AND    P.FRONT_GB LIKE CONCAT('%',#{frontGb},'%')
-		    </if>
+		    </if> -->
 		    AND    NOW() BETWEEN P.DISP_STDT AND P.DISP_EDDT
 		    AND    P.DEL_YN = 'N' /*삭제안된 기획전*/
 		    AND    P.OPEN_YN = 'Y' /*오픈된 기획전*/
@@ -377,6 +377,28 @@
 		AND    CUST_GB = #{custGb}
 	</select>
 	
+	<!-- 고객구분접근가능리스트 -->
+	<select id="getCustomerGubunAccessibleList" parameterType="Plan" resultType="Plan">
+		/* TsfPlanning.getCustomerGubunAccessibleList */
+		SELECT CASE CUST_GB WHEN 'G100_10' THEN '일반회원'
+		                    WHEN 'G100_20' THEN '임직원' END AS CUST_GB 
+		FROM TB_PLAN_CUST_DIVISION 
+		WHERE PLAN_SQ = #{planSq}
+	</select>
+	
+	<!-- 고객등급접근가능리스트 -->
+	<select id="getCustomerGradeAccessibleList" parameterType="Plan" resultType="Plan">
+		/* TsfPlanning.getCustomerGradeAccessibleList */
+		SELECT CASE CUST_GRADE WHEN 'G110_10' THEN 'VIP'
+		                       WHEN 'G110_20' THEN 'GOLD'
+		                       WHEN 'G110_30' THEN 'SILVER'
+		                       WHEN 'G110_40' THEN 'BRONZE'
+		                       WHEN 'G110_50' THEN 'WELCOME'
+		                       END AS CUST_GRADE
+		FROM TB_PLAN_CUST_GRADE 
+		WHERE PLAN_SQ = #{planSq}
+	</select>
+	
 	<!-- 고객등급접근가능여부 조회 -->
 	<select id="getCustomerGradeAccessibleYn" parameterType="Plan" resultType="String">
 		/* TsfPlanning.getCustomerGradeAccessibleYn */
@@ -498,9 +520,9 @@
 		        FROM   TB_PLAN P
 		        WHERE  P.PLAN_GB IN ('E','C') /*이벤트,출석체크*/
 		        AND    P.SITE_CD = #{siteCd}
-		        <if test="frontGb != null and frontGb != ''">
+		       <!--  <if test="frontGb != null and frontGb != ''">
 		        AND    P.FRONT_GB LIKE CONCAT('%',#{frontGb},'%')
-		        </if>
+		        </if> -->
 		        AND    NOW() BETWEEN P.DISP_STDT AND P.DISP_EDDT
 		        AND    P.DEL_YN = 'N' /*삭제안된 기획전*/
 		        AND    P.OPEN_YN = 'Y' /*오픈된 기획전*/

+ 3 - 2
src/main/webapp/WEB-INF/views/web/error/InaccessWeb.html

@@ -50,10 +50,11 @@
 		<div class="wrap notfind system inspect"><!--  페이지 특정 클래스 -->
 			<div class="contGrp">
 				<h2>접근 불가</h2>
-				<p th:text="${inaccessibleMsg}">모바일웹에서만 접근이 가능합니다.</p>
+				<p th:text="${inaccessibleMsg}"></p>
 			</div>
 			<div class="btn_group">
-				<button class="btn btn_dark" onclick="fnGoToHome();"><span>홈으로 이동</span></button>
+				<button class="btn btn_dark" onclick="javascript:history.back(-1);"><span>목록으로 이동</span></button>
+				<button class="btn btn_default" onclick="fnGoToHome();"><span>홈으로 이동</span></button>
 			</div>
 		</div>
 	</div>

+ 7 - 0
src/main/webapp/ux/pc/css/common.css

@@ -802,6 +802,13 @@ content: "〉";font-size: 12px;padding-left: 8px;
 .itemPic .pd_mov {z-index: 3;height: 100%;}
 .itemPic .pd_img {z-index: 2;transition: 0.5s;}
 /* .itemPic .pd_img {position: absolute;width: 100%;width: auto; height: auto;max-height: 500px;top: 50%;left: 50%;transform: translate(-50%,-50%);} */
+.itemOpt{z-index:10;position: absolute;bottom: -120px; left: 0; right: 0; width: 100%; height:111px;padding: 32px 0; text-align:center; color: #fff; background: rgb(0 0 0 / 0.8); }
+.itemOpt p{font-size: 12px;line-height: 1.2;padding-bottom: 15px;}
+.itemOpt ul{display: block;margin: 0 auto;width: auto;}
+.itemOpt ul li{font-size: 14px;line-height: 1.2;display: inline-block;margin-left: 10px;}
+.itemOpt ul .none{opacity: 0.5;text-decoration: line-through;}
+.itemOpt ul li:first-child{margin-left: 0px;}
+.itemOpt .exc{font-size: 14px;line-height: 1.2;display: inline-block;margin-left: 10px;}
 .itemBrand {margin: 0px 5px 12px;line-height: 12px;font-size: 12px;font-weight: 300;color: rgb(137, 137, 137);height:12px;}
 .itemComment{margin:20px 5px 0px;line-height: 1; font-size: 14px;font-weight: 300;color: #fd4802;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;}
 .itemName {	margin: 0px 5px 15px;line-height:20px;font-size: 14px;font-weight: 200;color:#222; height:40px;}

+ 9 - 5
src/main/webapp/ux/pc/css/layout.css

@@ -580,13 +580,14 @@ ul.maintabs li [class^='box_depth'] {display:none; position:absolute; left:100%;
 .filter_content .sort.tap02 {padding-left:0; padding-right:0;}
 .filter_content .sort.tap02 ul::after {content:''; display: block; clear:both;}
 .filter_content .sort.tap02 ul li {float:left; padding-left:40px; padding-right:40px; margin-bottom:20px;}
-.filter_content .sort.tap03 ul li {border-bottom: 1px solid #ccc;}
+.filter_content .sort.tap03 ul li {position: relative; border-bottom: 1px solid #ccc; padding-left: 100px;}
 .filter_content .sort.tap03 ul li::after {content: ''; display: block; clear: both;}
 .filter_content .sort.tap03 ul li:first-child {padding-bottom: 30px;}
+.filter_content .sort.tap03 ul li:first-child strong {top: 2px;}
 .filter_content .sort.tap03 ul li:nth-child(2) {padding-top: 30px;padding-bottom: 30px;}
 .filter_content .sort.tap03 ul li:last-child {padding-top: 30px; border: none;}
-.filter_content .sort.tap03 ul li strong {/*margin-right:40px;*/width:100px;color:#222; font-weight:300; height: 21px;float: left;}
-.filter_content .sort.tap03 ul li label {color:#666; margin-right:40px; line-height: 1.4; display: inline-block; word-break:keep-all;position:relative;}
+.filter_content .sort.tap03 ul li strong {/*margin-right:40px;*/width:100px;color:#222; font-weight:300; height: 21px;float: left; position: absolute; top: 32px; left: 0;}
+.filter_content .sort.tap03 ul li label {color:#666; margin-right:40px; margin-bottom: 3px; line-height: 1.4; display: inline-block; word-break:keep-all;position:relative;}
 .filter_content .sort.tap03 ul li label:last-child {margin-right:0}
 .filter_content .sort.tap03 ul li label span {}
 .filter_content .sort.tap03 ul li .size_btn,
@@ -1905,7 +1906,7 @@ ul.maintabs li [class^='box_depth'] {display:none; position:absolute; left:100%;
 	.cmt_wrap .pics .picsThumbs {max-width: 100%; max-height: 100%;}
 	.cmt_wrap .cmt_write .cmt_tarea {margin-bottom: 20px;}
 	.cmt_wrap .cmt_write .cmt_tarea textarea {background: #fff; padding: 20px; resize: none; width: 100%; height: 140px; font-size: 14px; line-height: 1.3;}
-	.cmt_wrap .cmt_write .cmt_thumb + .btn {display:block; margin-top:40px; margin-left:auto; margin-right:auto; width:220px; height:60px; font-size:13px; font-weight:300;}
+	.cmt_wrap .cmt_write .cmt_thumb + .btn {display:block; margin-top:40px; margin-left:auto; margin-right:auto; width:220px; height:60px; font-size:18px; font-weight:300;}
 	.cmt_wrap .cmt_group {margin-top:90px}
 	.cmt_wrap .cmt_group .cmt_list_tit {padding-bottom:30px; border-bottom:1px solid #ddd;}
 	.cmt_wrap .cmt_group .cmt_list_tit strong {margin-right: 10px; font-size: 26px; font-weight: 500;}
@@ -4253,7 +4254,10 @@ ul.maintabs li [class^='box_depth'] {display:none; position:absolute; left:100%;
 	.survey .survey_wrap .survey_con .survey_row .answer textarea {height:220px; padding:20px;}
 	.survey .survey_wrap .survey_con .survey_row .answer ul {/*margin-top:-30px;*/ margin-right:-60px}
 	.survey .survey_wrap .survey_con .survey_row .answer ul li {float:left; position:relative; margin-bottom:42px; margin-right:48px;}
-	.survey .survey_wrap .survey_con .survey_row .answer input[type='text'].etc_input {visibility:hidden;margin-left:20px; width:300px !important; max-width:300px !important; height:52px;}
+	.survey .survey_wrap .survey_con .survey_row .answer ul li:last-child {} 
+	
+	.survey .survey_wrap .survey_con .survey_row .answer input[type='text'].etc_input {visibility:hidden;margin-left:20px; width:300px !important; max-width:300px !important; height:52px; margin-top: -33px;}
+	.survey .survey_wrap .survey_con .survey_row .answer ul li .etc_radio:checked + label + .etc_input {margin-top: 0;}
 	.survey .survey_wrap .survey_con .btn_wrap {margin-top:20px} 
 
 	/* ev_rank 회원등급 혜택 */

+ 15 - 1
src/main/webapp/ux/pc/css/main.css

@@ -582,7 +582,21 @@ header.minify .common_header.br_header::after {bottom:-565px;}
 .brand_main .post-visual .swiper-slide .txtWrap {opacity:0; position:absolute; padding-left:0px; top:110px; bottom:auto; left:0px; right:auto; z-index:1;}
 .brand_main .post-visual .txtWrap dt {font-size:0; padding-bottom:0;}
 .brand_main .post-visual .swiper-slide-active {opacity:1;}
-.brand_main .post-visual .swiper-slide-active .txtWrap {opacity:1;}
+.brand_main .post-visual .swiper-slide-active .txtWrap {animation-name: fade-in;animation-duration: 1.5s;animation-delay: 1s;animation-fill-mode: both;}
+
+@keyframes fade-in {
+	from {
+	  opacity: 0;
+	  left:0;
+	  transform: translateY(100px);
+	}
+	to {
+	  opacity: 1;
+	  left:0;
+	  transform: translateY(0);
+	}
+}
+
 .brand_main .post-visual .swiper-slide-prev {opacity:0;}
 .brand_main .post-visual .swiper-slide-next {padding-left:0px; padding-right:440px;}
 .brand_main .post-visual .swiper-controls {position:absolute; width:auto; bottom:100px; left:190px; padding-right:15px; z-index:10;}