瀏覽代碼

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

jsh77b 5 年之前
父節點
當前提交
1a764cd704

+ 1 - 4
style24.admin/src/main/java/com/style24/persistence/mybatis/shop/TsaGoods.xml

@@ -1810,11 +1810,8 @@
 	</update>
 	
 	<!-- 상품코드 생성 -->
-	<insert id="createGoodsSequence" parameterType="Goods">
+	<insert id="createGoodsSequence" parameterType="Goods"  keyProperty="goodsSq">
 		/* TsaGoods.createGoodsSequence */
-		<selectKey keyProperty="goodsSq" resultType="int" order="AFTER">
-		SELECT MAX(GOODS_SQ) FROM TB_GOODS_SEQUENCE
-		</selectKey>
 		INSERT INTO TB_GOODS_SEQUENCE (GOODS_SQ) VALUES (NULL)
 	</insert>
 

+ 1 - 1
style24.admin/src/main/webapp/WEB-INF/views/goods/GoodsDetailSizeStockForm.html

@@ -67,7 +67,7 @@
 			<col width="7%"/>
 		</colgroup>
 		<tr th:if="${goods.selfGoodsYn == 'Y' and goods.goodsType == 'G056_N'}">
-			<th colspan="2">ERP재고연동여부<i class="star"></i></th>
+			<th colspan="2">WMS재고연동여부<i class="star"></i></th>
 			<td colspan="2">
 				<label class="rdoBtn"><input type="radio" name="erpStockLinkYn" id="erpStockLinkYnY" value="Y" th:checked="${goods.erpStockLinkYn == 'Y'}"/>Y</label>
 				<label class="rdoBtn"><input type="radio" name="erpStockLinkYn" id="erpStockLinkYnN" value="N" th:checked="${goods.erpStockLinkYn == 'N'}"/>N</label>

+ 9 - 19
style24.admin/src/main/webapp/WEB-INF/views/goods/GoodsMassRegisterForm.html

@@ -28,11 +28,11 @@
 			<ul class="notice">
 				<li>상품을 대량으로 등록하는 페이지입니다.</li>
 				<li>상품을 등록 할 경우 [승인대기] 상태이며, STYLE 관리자의 [승인완료] 상태 변경 후 FRONT애 노출이 가능합니다.</li>
-				<li><th:block th:if="${erpSyncYn == 'N'}"><em><b>ERP연동여부가 [N]입니다. 관리자에게 문의하세요.</b></em></th:block></li>
+				<li><th:block th:if="${erpSyncYn == 'N'}"><em><b>WMS연동여부가 [N]입니다. 관리자에게 문의하세요.</b></em></th:block></li>
 			</ul>
 			<ul class="panelBar">
 				<li class="center">
-					<th:block th:if="${sessionInfo.roleCd == 'G001_0000' 
+					<!-- <th:block th:if="${sessionInfo.roleCd == 'G001_0000' 
 									or sessionInfo.roleCd == 'G001_A000' 
 									or sessionInfo.roleCd == 'G001_A001' 
 									or sessionInfo.roleCd == 'G001_A100' 
@@ -48,7 +48,7 @@
 									or sessionInfo.roleCd == 'G001_A101'
 									}">
 						<button type="button" class="btn btn-default btn-lg" id="btnInit" onclick="cfnDownloadSampleFile('SF005');">입점상품 등록양식 다운로드</button>
-						<button th:if="${erpSyncYn == 'Y'}" type="button" class="btn btn-primary btn-lg" id="btnGoodsCreate" >입점상품 등록</button>
+						<button th:if="${erpSyncYn == 'Y'}" type="button" class="btn btn-primary btn-lg" id="btnGoodsCreate" >입점상품 등록</button> -->
 					</th:block>
 					<label class="off"><a href="javascript:void(0);" id="excelList" style="display: none;">엑셀다운로드</a></label>
 					<!--  추후 대량 수정 권한-->
@@ -60,7 +60,7 @@
 								}" 
 							th:style="'padding-left:80px;'">
 						<button type="button" class="btn btn-default btn-lg" id="btnInit" onclick="cfnDownloadSampleFile('SF014');">상품대량수정 등록양식 다운로드</button>
-						<button th:if="${erpSyncYn == 'Y'}" type="button" class="btn btn-primary btn-lg" id="btnGoodsUpdate" >입점상품 등록</button>
+						<button th:if="${erpSyncYn == 'Y'}" type="button" class="btn btn-primary btn-lg" id="btnGoodsUpdate" >상품 수정</button>
 					</span>
 				</li>
 			</ul>
@@ -95,7 +95,7 @@
 					</tr>
 				</table>
 				<ul class="panelBar">
-					<li>
+					<li class="center">
 						<button type="button" class="btn btn-gray btn-lg" id="btnInit" >초기화</button>
 						<button type="button" class="btn btn-info btn-lg" id="btnSearch" >조회</button>
 					</li>
@@ -114,31 +114,21 @@
 						<span class="left aL" style="width:580px;">
 						<!-- class="left" 또는 class="right" -->
 							<em>상품미등록</em><br/>
-							- 상품코드 오류 : 빈값, 길이 11이 아닐경우, '_'가 미존재<br/>
-							- 업체 오류 : 빈값, 'W'나 'F' 가 아닌경우<br/>
+							- 상품코드 오류 : 빈값, 온라인상품코드 미존재<br/>
+							- 업체 오류 : 빈값, 'S0001'나 'S0002' 가 아닌경우<br/>
 							- 상품명 오류 : 빈값<br/>
-							- 제조국 오류 : 빈값<br/>
-							- 제조년월일 오류 : 빈값, 날짜형식이 맞는지<br/>
-							- ERP 미존재 상품코드 : ERP에 상품코드가 존재하는지<br/>
 							- 스타일 연도 오류 : 온라인에서 관리되지 않는 스타일 연도<br/>
 							- 성별 오류 : 온라인에서 관리되지 않는 성별<br/>
 							- 컬러 오류 : 온라인에서 관리되지 않는 컬러<br/>
-							- 상품코드 중복등록요청 : 등록된 상품코드 등록요청<br/>
 							- 품목 오류 : 온라인에서 관리되지 않는 품목<br/>
-							- ERP 브랜드 오류 : 온라인에서 관리되지 않는 ERP 브랜드<br/>
-							- 이미지 유형 오류 : 온라인에서 관리되지 않는 이미지유형<br/>
-							- 상품이미지 필수 오류 : IMG_PATH1
 							- 품목의 고시정보 없음 : 품목의 고시분류 매핑이 안되어 있는 경우<br/>
-							- 고시분류 오류 : 등록요청 고시분류 와 온라인에서 품목과 매핑된 고시분류가 다른 경우<br/>
-							<em>상품등록</em><br/>
-							- ERP 상품 사이즈 정보 없음 : ERP에 상품코드의 사이즈가 없을 경우<br/>
 						</span>
 					</div>
 					<!-- //아이콘 툴팁 -->
 				</li>
-				<!-- <li class="right">
+				<li class="right">
 					<button type="button" class="btn btn-default btn-lg" id="btnGoodsRegExcelDownLoad">엑셀다운로드</button>
-				</li> -->
+				</li>
 			</ul>
 			<!-- //상단버튼 영역  -->
 			<div id="gridList" style="width: 100%; height: 500px;" class="ag-theme-balham"></div>

+ 6 - 1
style24.admin/src/main/webapp/WEB-INF/views/goods/GoodsWmsInstockForm.html

@@ -70,6 +70,11 @@
 		</div>
 		<!-- 패널 영역1 -->
 		<div class="panelStyle">
+			<ul class="panelBar">
+				<li class="right">
+					<button type="button" class="btn btn-primary btn-lg"  id="btnGoodsSetMake">사은품 등록</button>
+				</li>
+			</ul>
 			<!-- 검색결과 영역 -->
 			<div id="gridList" style="width: 100%; height: 500px;" class="ag-theme-balham"></div>
 			<ul class="panelBar">
@@ -89,7 +94,7 @@
 	var goodsStatList = gagajf.convertToArray([[${goodsStatList}]]);
 	var itemkindList = gagajf.convertToArray([[${itemkindList}]]);
 	var columnDefs = [
-		/* {width: 40, minWidth: 40, cellClass: 'text-right', headerCheckboxSelection: true, checkboxSelection: true, filter: false}, */
+		{width: 40, minWidth: 40, cellClass: 'text-right', headerCheckboxSelection: true, checkboxSelection: true, filter: false}, 
 		{headerName: 'No', width: 60, cellClass: 'text-center', valueGetter: function(params) { return params.node.rowIndex + 1 }},
 		{headerName: "브랜드", field: "brandCd", width: 100, cellClass: 'text-center'},
 		{headerName: "브랜드명", field: "brandEnm", width: 130, cellClass: 'text-center'},

+ 1 - 1
style24.admin/src/main/webapp/WEB-INF/views/system/CommoncodeForm.html

@@ -183,8 +183,8 @@
 		$('#detailForm input[name=cdGb]').val(rowData.cdGb);
 		$('#detailForm input[name=cd]').val(rowData.cd);
 		$('#detailForm input[name=cdNm]').val(rowData.cdNm);
-		$('#detailForm input[name=cdDesc]').val(rowData.cdDesc);
 		$('#detailForm input[name=dispOrd]').val(rowData.dispOrd);
+		$('#detailForm textarea[name=cdDesc]').val(rowData.cdDesc);
 		
 		$("#detailForm input[name=useYn]").val(rowData.useYn);
 		if (rowData.useYn == 'Y') {

+ 0 - 13
style24.batch/.classpath

@@ -28,18 +28,5 @@
 			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/classes"/>
 		</attributes>
 	</classpathentry>
-	<classpathentry kind="src" output="target/test-classes" path="src/test/java">
-		<attributes>
-			<attribute name="optional" value="true"/>
-			<attribute name="maven.pomderived" value="true"/>
-			<attribute name="test" value="true"/>
-		</attributes>
-	</classpathentry>
-	<classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources">
-		<attributes>
-			<attribute name="maven.pomderived" value="true"/>
-			<attribute name="test" value="true"/>
-		</attributes>
-	</classpathentry>
 	<classpathentry kind="output" path="target/classes"/>
 </classpath>

+ 0 - 13
style24.front/.classpath

@@ -28,18 +28,5 @@
 			<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/classes"/>
 		</attributes>
 	</classpathentry>
-	<classpathentry kind="src" output="target/test-classes" path="src/test/java">
-		<attributes>
-			<attribute name="optional" value="true"/>
-			<attribute name="maven.pomderived" value="true"/>
-			<attribute name="test" value="true"/>
-		</attributes>
-	</classpathentry>
-	<classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources">
-		<attributes>
-			<attribute name="maven.pomderived" value="true"/>
-			<attribute name="test" value="true"/>
-		</attributes>
-	</classpathentry>
 	<classpathentry kind="output" path="target/classes"/>
 </classpath>

二進制
style24.front/target/classes/com/style24/front/biz/web/TsfCustomerController.class


+ 2 - 4
style24.scm/src/main/java/com/style24/persistence/domain/Notice.java

@@ -40,10 +40,6 @@ public class Notice extends TscBaseDomain {
 //	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
 //	private String[] receiverIds;
 
-	// 공지사항 첨부파일
-	private Integer seq;
-	private String orgFileNm;
-	private String sysFileNm;
 //	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
 //	private String[] orgFileNms;
 //	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
@@ -52,4 +48,6 @@ public class Notice extends TscBaseDomain {
 	private String goodsList;
 	private Collection<NoticeGoods> goodsListNew;
 
+	private Collection<NoticeFileList> fileList;
+
 }

+ 22 - 0
style24.scm/src/main/java/com/style24/persistence/domain/NoticeFileList.java

@@ -0,0 +1,22 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 공지사항파일 Domain
+ *
+ * @author gagamel
+ * @since 2020. 10. 30
+ */
+@SuppressWarnings("serial")
+@Data
+public class NoticeFileList extends TscBaseDomain {
+
+	private Integer noticeSq;
+	private Integer seq;
+	private String orgFileNm;
+	private String sysFileNm;
+
+}

+ 2 - 5
style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssGoods.xml

@@ -1380,11 +1380,8 @@
 	</update>
 	
 	<!-- 상품코드 생성 -->
-	<insert id="createGoodsSequence" parameterType="Goods">
-		/* TssGoods.createGoodsSequence */
-		<selectKey keyProperty="goodsSq" resultType="int" order="AFTER">
-		SELECT MAX(GOODS_SQ) FROM TB_GOODS_SEQUENCE
-		</selectKey>
+	<insert id="createGoodsSequence" parameterType="Goods" keyProperty="goodsSq">
+		/* TssGoods.createGoodsSequence */ 
 		INSERT INTO TB_GOODS_SEQUENCE (GOODS_SQ) VALUES (NULL)
 	</insert>
 	

+ 23 - 17
style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssNotice.xml

@@ -52,6 +52,21 @@
 		WHERE  NOTICE_SQ = #{noticeSq}
 	</update>
 	
+	<!-- 공지사항 팝업 총건수 -->
+	<select id="getNoticePopupTotalCount" resultType="int">
+		/* TssNotice.getNoticePopupTotalCount */
+		SELECT COUNT(*) AS CNT
+		FROM   TB_NOTICE A
+		WHERE  A.NOTICE_TYPE = 'G047_20' /*내부공지*/
+		AND    A.NOTICE_SQ IN (SELECT NOTICE_SQ
+		                       FROM   TB_NOTICE_RECEIVER
+		                       WHERE  RECEIVER_ID = 'G048_60' /*입점업체*/
+		                      )
+		AND    A.USE_YN = 'Y'
+		AND    A.POPUP_YN = 'Y' /*팝업*/
+		AND    CURRENT_DATE() BETWEEN A.POPUP_DISP_STDT AND A.POPUP_DISP_EDDT
+	</select>
+	
 	<!-- 공지사항 팝업 목록 -->
 	<select id="getNoticePopupList" resultType="Notice">
 		/* TssNotice.getNoticePopupList */
@@ -76,24 +91,15 @@
 	</select>
 	
 	<!-- 공지사항 팝업 파일 목록 -->
-	<select id="getNoticePopupFileList" resultType="Notice">
+	<select id="getNoticePopupFileList" parameterType="Integer" resultType="NoticeFileList">
 		/* TsaNotice.getNoticePopupFileList */
-		SELECT A.NOTICE_SQ
-		     , B.SEQ
-		     , B.ORG_FILE_NM
-		     , B.SYS_FILE_NM
-		FROM   TB_NOTICE A
-		     , TB_NOTICE_FILE B
-		WHERE  A.NOTICE_SQ = B.NOTICE_SQ
-		AND    A.NOTICE_TYPE = 'G047_20' /*내부공지*/
-		AND    A.NOTICE_SQ IN (SELECT NOTICE_SQ
-		                       FROM   TB_NOTICE_RECEIVER
-		                       WHERE  RECEIVER_ID = 'G048_60' /*입점업체*/
-		                      )
-		AND    A.USE_YN = 'Y'
-		AND    A.POPUP_YN = 'Y' /*팝업*/
-		AND    CURRENT_DATE() BETWEEN A.POPUP_DISP_STDT AND A.POPUP_DISP_EDDT
-		ORDER  BY A.NOTICE_SQ, B.SEQ
+		SELECT NOTICE_SQ
+		     , SEQ
+		     , ORG_FILE_NM
+		     , SYS_FILE_NM
+		FROM   TB_NOTICE_FILE
+		WHERE  NOTICE_SQ = #{noticeSq}
+		ORDER  BY SEQ
 	</select>
 
 </mapper>

+ 11 - 1
style24.scm/src/main/java/com/style24/scm/biz/dao/TssNoticeDao.java

@@ -4,6 +4,7 @@ import java.util.Collection;
 
 import com.style24.core.support.annotation.ShopDs;
 import com.style24.persistence.domain.Notice;
+import com.style24.persistence.domain.NoticeFileList;
 
 /**
  * 공지사항 Dao
@@ -30,6 +31,14 @@ public interface TssNoticeDao {
 	 */
 	void updateNotice(Notice notice);
 
+	/**
+	 * 공지사항 팝업 총건수
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 12. 30
+	 */
+	int getNoticePopupTotalCount();
+
 	/**
 	 * 공지사항 팝업 목록
 	 * @return
@@ -40,10 +49,11 @@ public interface TssNoticeDao {
 
 	/**
 	 * 공지사항 팝업 파일 목록
+	 * @param noticeSq - 공지사항번호
 	 * @return
 	 * @author gagamel
 	 * @since 2020. 12. 29
 	 */
-	Collection<Notice> getNoticePopupFileList();
+	Collection<NoticeFileList> getNoticePopupFileList(Integer noticeSq);
 
 }

+ 15 - 7
style24.scm/src/main/java/com/style24/scm/biz/service/TssNoticeService.java

@@ -49,23 +49,31 @@ public class TssNoticeService {
 	}
 
 	/**
-	 * 공지사항 팝업 목록
+	 * 공지사항 팝업 총건수
 	 * @return
 	 * @author gagamel
-	 * @since 2020. 12. 29
+	 * @since 2020. 12. 30
 	 */
-	public Collection<Notice> getNoticePopupList() {
-		return noticeDao.getNoticePopupList();
+	public int getNoticePopupTotalCount() {
+		return noticeDao.getNoticePopupTotalCount();
 	}
 
 	/**
-	 * 공지사항 팝업 파일 목록
+	 * 공지사항 팝업 목록
 	 * @return
 	 * @author gagamel
 	 * @since 2020. 12. 29
 	 */
-	public Collection<Notice> getNoticePopupFileList() {
-		return noticeDao.getNoticePopupFileList();
+	public Collection<Notice> getNoticePopupList() {
+		Collection<Notice> noticeList = noticeDao.getNoticePopupList();
+
+		if (noticeList != null && !noticeList.isEmpty()) {
+			for (Notice notice : noticeList) {
+				notice.setFileList(noticeDao.getNoticePopupFileList(notice.getNoticeSq()));
+			}
+		}
+
+		return noticeList;
 	}
 
 }

+ 6 - 4
style24.scm/src/main/java/com/style24/scm/biz/web/TssBoardController.java

@@ -1,11 +1,14 @@
 package com.style24.scm.biz.web;
 
+import java.util.Collection;
+
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Controller;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.servlet.ModelAndView;
 
+import com.style24.persistence.domain.Notice;
 import com.style24.scm.biz.service.TssNoticeService;
 import com.style24.scm.support.controller.TssBaseController;
 
@@ -37,10 +40,9 @@ public class TssBoardController extends TssBaseController {
 		ModelAndView mav = new ModelAndView();
 
 		// 공지사항 목록
-		mav.addObject("noticeList", noticeService.getNoticePopupList());
-
-		// 공지사항 파일 목록
-		mav.addObject("noticeFileList", noticeService.getNoticePopupFileList());
+		Collection<Notice> noticeList = noticeService.getNoticePopupList();
+		mav.addObject("noticeCnt", noticeList.size());
+		mav.addObject("noticeList", noticeList);
 
 		mav.setViewName("board/NoticePopupForm");
 

+ 7 - 0
style24.scm/src/main/java/com/style24/scm/biz/web/TssIndexController.java

@@ -15,6 +15,7 @@ import org.springframework.web.servlet.ModelAndView;
 import com.style24.core.support.message.TscMessageByLocale;
 import com.style24.persistence.domain.User;
 import com.style24.scm.biz.service.TssLoginService;
+import com.style24.scm.biz.service.TssNoticeService;
 import com.style24.scm.support.controller.TssBaseController;
 import com.style24.scm.support.security.session.TssSession;
 
@@ -42,6 +43,9 @@ public class TssIndexController extends TssBaseController {
 	@Autowired
 	private GagaPasswordEncoder passwordEncoder;
 
+	@Autowired
+	private TssNoticeService noticeService;
+
 	/**
 	 * 첫 페이지
 	 * 		로그인 하고
@@ -60,6 +64,9 @@ public class TssIndexController extends TssBaseController {
 
 		if (TssSession.isLogin()) {
 			if (TssSession.isTwoFactorCertify()) { // 2factor인증이 되었으면
+				// 공지사항 팝업 총건수
+				mav.addObject("noticeCnt", noticeService.getNoticePopupTotalCount());
+
 				// 대쉬보드 페이지로
 				mav.setViewName("dashboard");
 			} else {

+ 20 - 16
style24.scm/src/main/webapp/WEB-INF/views/board/NoticePopupForm.html

@@ -33,9 +33,9 @@
 						12월 21일(금) 오후 5시까지 결제완료(입금/결제완료) 주문 건에 한해 명절 연휴 전 발송이 가능하며, 그 이후 주문 건은 12월 26일(수)부터 순차적으로 발송됩니다.<br/><br/>
 						<img src="/image/@notice_popup01.jpg"/>
 					</div>
-					<ul class="download">
-						<li>
-							<i class="fa fa-download" aria-hidden="true"></i><a href="">파일첨부1.pdf</a>
+					<ul class="download" th:if="${oneData.fileList}">
+						<li th:each="oneData2, status2 : ${oneData.fileList}">
+							<i class="fa fa-download" aria-hidden="true"></i><a href="#" th:href="@{@environment.getProperty('upload.default.view') + '/notice' + oneData2.sysFileNm}" th:text="${oneData2.orgFIleNm}"></a>
 						</li>
 					</ul>
 				</div>
@@ -68,19 +68,23 @@
 <script type="text/javascript" src="/ux/plugins/swiper/swiper.min.js"></script>
 <script th:inline="javascript">
 /*<![CDATA[*/
-	// 공지팝업 : SWIPE(공지가 한장일 경우 해당 객체 선언 금지)
-	let swiper = new Swiper('#popupNotice .swiper-container', {
-		loop: true,
-		paginationClickable :true,
-		pagination: {
-			el: '.swiper-pagination',
-			type: 'fraction', /* 201125 */
-		},
-		navigation: {
-			nextEl: '.swiper-button-next',
-			prevEl: '.swiper-button-prev',
-		},
-	});
+	let noticeCnt = [[${noticeCnt}]];
+	
+	if (noticeCnt > 1) {
+		// 공지팝업 : SWIPE(공지가 한장일 경우 해당 객체 선언 금지)
+		let swiper = new Swiper('#popupNotice .swiper-container', {
+			loop: true,
+			paginationClickable :true,
+			pagination: {
+				el: '.swiper-pagination',
+				type: 'fraction', /* 201125 */
+			},
+			navigation: {
+				nextEl: '.swiper-button-next',
+				prevEl: '.swiper-button-prev',
+			},
+		});
+	}
 	
 	$('#btnCloseNotice').on('click', function() {
 		gagajf.setCookie("CK_NOTICE_CLOSE", "Y", 1);

+ 2 - 1
style24.scm/src/main/webapp/WEB-INF/views/dashboard.html

@@ -341,7 +341,8 @@
 	}
 
 	$(document).ready(function() {
-		if (gagajf.getCookie('CK_NOTICE_CLOSE') != 'Y') {
+		let noticeCnt = [[${noticeCnt}]];
+		if (noticeCnt > 0 && gagajf.getCookie('CK_NOTICE_CLOSE') != 'Y') {
 			// 공지사항 팝업
 			cfnOpenModalPopup('/board/notice/popup/form', 'popupNotice');
 		}