eskim преди 5 години
родител
ревизия
516772b6b0
променени са 27 файла, в които са добавени 5633 реда и са изтрити 70 реда
  1. 25 64
      style24.scm/src/main/java/com/style24/persistence/domain/Brand.java
  2. 168 0
      style24.scm/src/main/java/com/style24/persistence/domain/Goods.java
  3. 46 0
      style24.scm/src/main/java/com/style24/persistence/domain/GoodsCompose.java
  4. 20 0
      style24.scm/src/main/java/com/style24/persistence/domain/GoodsDesc.java
  5. 68 0
      style24.scm/src/main/java/com/style24/persistence/domain/GoodsHst.java
  6. 47 0
      style24.scm/src/main/java/com/style24/persistence/domain/GoodsImg.java
  7. 28 0
      style24.scm/src/main/java/com/style24/persistence/domain/GoodsNotiInfo.java
  8. 113 0
      style24.scm/src/main/java/com/style24/persistence/domain/GoodsSearch.java
  9. 25 0
      style24.scm/src/main/java/com/style24/persistence/domain/Itemkind.java
  10. 36 0
      style24.scm/src/main/java/com/style24/persistence/domain/NotiInfo.java
  11. 45 0
      style24.scm/src/main/java/com/style24/persistence/domain/Option.java
  12. 24 0
      style24.scm/src/main/java/com/style24/persistence/domain/SearchData.java
  13. 810 0
      style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssBusiness.xml
  14. 74 0
      style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssCommon.xml
  15. 1348 0
      style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssGoods.xml
  16. 315 3
      style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssRenderer.xml
  17. 227 0
      style24.scm/src/main/java/com/style24/scm/biz/dao/TssBusinessDao.java
  18. 60 0
      style24.scm/src/main/java/com/style24/scm/biz/dao/TssCommonDao.java
  19. 221 0
      style24.scm/src/main/java/com/style24/scm/biz/dao/TssGoodsDao.java
  20. 182 1
      style24.scm/src/main/java/com/style24/scm/biz/dao/TssRendererDao.java
  21. 317 0
      style24.scm/src/main/java/com/style24/scm/biz/service/TssBusinessService.java
  22. 84 0
      style24.scm/src/main/java/com/style24/scm/biz/service/TssCommonService.java
  23. 706 0
      style24.scm/src/main/java/com/style24/scm/biz/service/TssGoodsService.java
  24. 304 0
      style24.scm/src/main/java/com/style24/scm/biz/service/TssRendererService.java
  25. 144 0
      style24.scm/src/main/java/com/style24/scm/biz/web/TssGoodsController.java
  26. 192 0
      style24.scm/src/main/java/com/style24/scm/biz/web/TssRendererController.java
  27. 4 2
      style24.scm/src/main/java/com/style24/scm/support/env/TssConstants.java

+ 25 - 64
style24.scm/src/main/java/com/style24/persistence/domain/Brand.java

@@ -6,76 +6,37 @@ import lombok.Data;
 
 /**
  * 브랜드 Domain
- * 
+ *
  * @author gagamel
- * @since 2020. 10. 20
+ * @since 2020. 10. 7
  */
 @SuppressWarnings("serial")
 @Data
 public class Brand extends TscBaseDomain {
 
-//	//HTML
-//	private String cpnId;		//쿠폰ID
-//	private String cpnType;		//쿠폰유형
-//	private String cpnApplyYn;	//쿠폰적용여부
-//	private String refVal;		//관련값(쿠폰유형이 "10:상품쿠폰"일 때는 상품코드, "11:브랜드쿠폰"일 때는 브랜드코드, "12:카테고리쿠폰"일 때는 카테고리코드)
-//	private String delYn;		//삭제여부
+	private String brandGb;			// 브랜드구분
+	private String brandCd;			// 브랜드코드
+	private String brandEnm;		// 브랜드영문명
+	private String brandKnm;		// 브랜드한글명
+	private String brandGrpNm;		// 브랜드그룹명
+	private String supplyCompCd;	// 공급업체코드
+	private String supplyCompNm;	// 공급업체명
+	private String delvLocCd;		// 출고처코드(출고처)
+	private String delvLocNm;		// 출고처명
+	private String erpBrandCd;		// ERP브랜드코드
+	private String selfYn;			// 자사여부(Y:자사, N:입점)
+	private int delvFee;			// 기본배송비
+	private int minOrdAmt;			// 무료배송비최소주문금액
+	private float sellFeeRate;		// 판매수수료율
+	private float pntPrate10;		// 포인트적립율(PC정상)
+	private float pntMrate10;		// 포인트적립율(모바일정상)
+	private float pntPrate20;		// 포인트적립율(PC이월)
+	private float pntMrate20;		// 포인트적립율(모바일이월)
+	private String distributionGb;	// 유통구분(공통코드 G065)
+	private int dispOrd;			// 표시순서
+	private String useYn;			// 사용여부(Y:사용)
 
-	private String brandGb;		// 브랜드구분(자사(S) 입점(E))
-	private String brandCd;		// 브랜드코드
-	private String brandEnm;	// 브랜드영문명
-	private String brandKnm;	// 브랜드한글명
-	private String brandGrpNm;	// 브랜드그룹명
-//	private String erpBrandCd;	// ERP브랜드코드
-	private int minOrdAmt;		// 무료배송비최소주문금액
-	private int delvFee;		// 배송비
-	private String delvLocCd;	// 출고처코드
-	private String delvLocNm;	// 출고처명
-	private float sellFeeRate;	// 판매수수료율
-	private String brandImg;	// 브랜드이미지
-	private float pntPrate10;	// 포인트적립율(PC정상)
-	private float pntMrate10;	// 포인트적립율(모바일정상)
-	private float pntPrate20;	// 포인트적립율(PC이월)
-	private float pntMrate20;	// 포인트적립율(모바일이월)
-	private float dispOrd;		// 표시순서
-
-//	//TB_SUPPLY_COMPANY
-//	private String supplyCompCd; /*공급업체코드*/
-//	private String supplyCompNm; /*공급업체명*/
-//	private String bizGb; /*사업자구분(C:법인, P:개인)*/
-//	private String bizNo; /*사업자등록번호*/
-//	private String bizKind; /*업종*/
-//	private String bizType; /*업태*/
-//	private String ownerNm; /*대표자명*/
-//	private String bizZipcode; /*사업장우편번호*/
-//	private String bizBaseAddr; /*사업장기본주소*/
-//	private String bizDtlAddr; /*사업장상세주소*/
-//	private String mainTelno; /*대표전화번호*/
-//	private String mainFaxno; /*대표팩스번호*/
-//	private String homepageUrl; /*홈페이지URL*/
-//	private String selfYn; /*자사여부(Y:자사, N:입점)*/
-//	private String supplyStat; /*입점상태(공통코드G010)*/
-//	private String settleDay; /*정산일(매월)*/
-//	private String bankNm; /*은행명*/
-//	private String accountNo; /*계좌번호*/
-//	private String depositorNm; /*예금주명*/
-//	private String remarks; /*비고*/
-//	private String useYn; /*사용여부(Y:사용)*/
-//
-//	//TB_DELIVERY_LOC
-//	private String delvLocClsf; /*출고처분류(공통코드G024)*/
-//	private String delvAssignOrd; /*출고지정순서(출고처유형이 "21:직송매장"일 때만 사용)*/
-//	private String delvAssignGrade; /*출고지정등급(출고처유형이 "21:직송매장"일 때만 사용)*/
-//	private String delvPossibQty; /*출고가능수량(출고처유형이 "21:직송매장"일 때만 사용)*/
-//	private String delvFeeRate; /*출고수수료율*/
-//	private String delvLocPostNo; /*출고처우편번호*/
-//	private String delvLocBaseAddr; /*출고처기본주소*/
-//	private String delvLocDtlAddr; /*출고처상세주소*/
-//	private String rtnLocPostNo; /*반품처우편번호*/
-//	private String rtnLocBaseAddr; /*반품처기본주소*/
-//	private String rtnLocDtlAddr; /*반품처상세주소*/
-//	private String rtnLocTelno; /*반품처전화번호*/
-//	private String rtnLocNm; /*반품처명*/
-//	private String invoicePrintType; /*송장출력형태(공통코드G025)*/
+	// 검색조건
+	private String searchTxt;		// 검색어
 
 }

+ 168 - 0
style24.scm/src/main/java/com/style24/persistence/domain/Goods.java

@@ -0,0 +1,168 @@
+package com.style24.persistence.domain;
+
+import java.util.Collection;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.style24.persistence.TscBaseDomain;
+import com.style24.persistence.TssPageRequest;
+
+import lombok.Data;
+
+/**
+ * 상품 Domain
+ *
+ * @author eskim
+ * @since 2020. 10. 20
+ */
+@SuppressWarnings("serial")
+@Data
+public class Goods extends TscBaseDomain {
+
+	private String goodsCd;		//상품코드
+	private String brandCd;		//브랜드코드
+	private String itemkindCd;		//품목코드
+	private String goodsNm;		//상품명
+	private String goodsTnm;		//상품타이틀명
+	private String goodsSnm;		//상품검색명
+	private String goodsSnm1;		//상품검색명1(사용자등록용)
+	private String mainColorCd;		//대표색상코드
+	private String styleYear;		//스타일연도
+	private String seasonCd;		//시즌코드(공통코드G006)
+	private String sexGb;		//성별구분(공통코드G007)
+	private String goodsNum;		//품번(자사상품만 사용)
+	private String goodsType;		//상품타입(공통코드G056)
+	private int listPrice;		//정상가(최초판매가)
+	private int currPrice;		//현재판매가
+	private int currBprice;		//변경전현재판매가
+	private String priceUpdDt;		//가격변경일시
+	private float dcRate;		//할인율
+
+	private String goodsStat;		//상품상태(공통코드G008)
+	private String selfMallYn;		//자사몰노출여부
+	private String goodsGb;		//해외구매대행/병행수입 상품일 경우 주문 시 통관부호 입력 란이 추가되어야 한다
+	private String distributionGb;		//유통구분(공콩코드 G065)
+	private String selfGoodsYn;		//자사상품여부
+	private String supplyCompCd;		//공급업체코드
+	private String supplyGoodsCd;		//공급업체상품코드(원코드)
+	private String ageGrpCd;		//상품연령대(공통코드 G023)
+	private int delvFee;		//배송비
+	private int minOrdAmt;		//무료배송비최소구매금액
+	private float pntPrate;		//포인트적립율(PC)
+	private float pntMrate;		//포인트적립율(모바일)
+	private float sellFeeRate;		//판매수수료율
+	private String formalGb;		//정상이월구분(공통코드G009)
+	private String changeableYn;		//교환가능여부
+	private String returnableYn;		//반품가능여부
+	private String changeFeeFreeYn;		//교환배송비무료여부
+	private String returnFeeFreeYn;		//반품배송비무료여부
+	private String prePpntUsableYn;		//선포인트사용가능여부(PC)
+	private String preMpntUsableYn;		//선포인트사용가능여부(모바일)
+	private int minOrdQty;		//최소주문수량
+	private int maxOrdQty;		//최대주문수량
+	private int dayMaxOrdQty;		//ID당1일최대구매수량
+	private String giftPackYn;		//선물포장여부
+	private String frstCfrmDt;		//최초승인일시
+	private String originCd;		//제조국(원산지)
+	private String makeYmd;		//제조연월일
+	private String taxGb;		//과세구분(10:과세, 20:비과세)
+	private String erpPriceLinkYn;		//ERP가격연계여부(자사상품만 사용. Y:연계)
+	private String erpStockLinkYn;		//ERP재고연계여부(자사상품만 사용. Y:연계)
+
+	private String brandEnm;		//브랜드영문명
+	private String brandGrpNm;		//브랜드그룹명
+
+	private String goodsDesc;
+	private String goodsPcTopDesc;
+	private String goodsPcDownDesc;
+	private String goodsMobileTopDesc;
+	private String goodsMobileDownDesc;
+	private String chkDescKeep = "N";
+//
+	private String chDataYn = "N";
+	private String chImgYn = "N";
+	private String chNotiYn = "N";
+	private String chStockDataYn = "N";
+	private String chGoodsStatYn = "N";
+	private int stockQtySum;
+	private String goodsImageYn;
+	private String itemkindNm;
+	private String niClsfCd;
+	private String makeNm;
+
+	private int currPriceOrg;
+	private String goodsStatOrg;
+	private String formalGbOrg;
+
+	private String imgType;
+	private String imgPath1;
+	private String imgPath6;
+	private String niClsfNm;
+	private String goodsTypeNm;
+	private String goodTnmInit;
+//
+//	private String goodsRegMsg;
+	private String procJob;
+	private String excelFileNm;
+//	private String searchGb;
+
+	private String blankFlag;
+//
+//	private Integer sizeCurrStockQty;
+//	private Integer sizeBaseStockQty;
+//	private Integer sizeSaleStockQty;
+//	private Integer sizeStockQty;
+//	private String goodsSizeCd;
+//	private String sizeSoldoutYn;
+	private String siteCd;
+	private int sellDay15Qty;
+
+	private int goodsSq;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] arrGoodsCd;
+
+	// 상품옵션/재고
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] compsGoodsCd; // 상품 사이즈
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] optCd; // 상품 사이즈
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] optCd1; // 상품 옵션1
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] optCd2; // 상품 옵션2
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] baseStockQty; // 안전재고
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] currStockQty; // erp가용재고
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] editCurrStockQty; // 수정가용재고
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] soldoutYn; // 품절여부
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] dispOrd; // 우선순위
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] dispYn; // 전시여부
+
+	private Collection<GoodsNotiInfo> notiListNew; // 고시항목
+
+	private String notiList; // 고시항목
+//	private String delvLocCd;
+
+	private Collection<GoodsCompose> goodsComposeListNew; // 상품 구성상품
+	private String goodsComposeList; // 상품 구성상품
+
+	// Pagination
+	private TssPageRequest pageable;
+	private int pageNo = 1;
+	private int pageSize = 50;
+	private int pageUnit = 10;
+}

+ 46 - 0
style24.scm/src/main/java/com/style24/persistence/domain/GoodsCompose.java

@@ -0,0 +1,46 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 상품 세트/딜 구성상품
+ *
+ * @author eskim
+ * @since 2020. 06. 11
+ */
+@SuppressWarnings("serial")
+@Data
+public class GoodsCompose extends TscBaseDomain {
+
+	private String goodsCd;
+	private String goodsType;
+	private String goodsTypeNm;
+	private String compsGoodsCd;
+	private int dispOrd;
+	private int qty;
+	private int compsCurrPrice;
+	private String compsGoodsOptNm;
+	private String baseYn;
+	private String useYn;
+
+	private int compsCurrPriceOrg;
+	private int currPrice;
+	private String goodsStat;
+	private String imgPath1;
+	private String imgPath6;
+	private String imgType;
+	private String crud;
+	private String compsGoodsNm;
+
+//	private String optionTitle;
+//	private String optionNm;
+//	private String optionInfo;
+//	private String setDetail;
+//	private int level;
+
+	private String selfGoodsYn;
+	private String supplyCompCd;
+
+}

+ 20 - 0
style24.scm/src/main/java/com/style24/persistence/domain/GoodsDesc.java

@@ -0,0 +1,20 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 상품 상세 설명 Domain
+ * @author eskim
+ * @since 2020. 10. 22
+ */
+@SuppressWarnings("serial")
+@Data
+public class GoodsDesc extends TscBaseDomain {
+
+	private String goodsCd;
+	private String descGb;
+	private int seq;
+	private String goodsDesc;
+}

+ 68 - 0
style24.scm/src/main/java/com/style24/persistence/domain/GoodsHst.java

@@ -0,0 +1,68 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 상품 이력 Domain
+ *
+ * @author eskim
+ * @since 2020. 10. 23
+ */
+@SuppressWarnings("serial")
+@Data
+public class GoodsHst extends TscBaseDomain {
+
+	private Integer goodsHstSq;		//상품이력일련번호
+	private String goodsCd;		//상품이력. 상품 수정에 의한 발생
+	private String brandCd;		//브랜드코드
+	private String itemkindCd;		//품목코드
+	private String goodsNm;		//상품명
+	private String goodsTnm;		//상품타이틀명
+	private String goodsSnm;		//상품검색명
+	private String goodsSnm1;		//상품검색명1(사용자등록용)
+	private String mainColorCd;		//대표색상코드
+	private String styleYear;		//스타일연도
+	private String seasonCd;		//시즌코드(공통코드G006)
+	private String sexGb;		//성별구분(공통코드G007)
+	private String goodsNum;		//품번(자사상품만 사용)
+	private String shapeCd;		//스타일모양코드(없으면 X)
+	private String goodsType;		//상품타입(공통코드G056)
+	private int listPrice;		//정상가(최초판매가)
+	private int currPrice;		//현재판매가
+	private int currBprice;		//변경전현재판매가
+	private String priceUpdDt;		//가격변경일시
+	private float dcRate;		//할인율
+	private String goodsStat;		//상품상태(공통코드G008)
+	private String dispYn;		//노출여부
+	private String goodsGb;		//해외구매대행/병행수입 상품일 경우 주문 시 통관부호 입력 란이 추가되어야 한다
+	private String distributionGb;		//유통구분(공콩코드 G065)
+	private String selfGoodsYn;		//자사상품여부
+	private String supplyCompCd;		//공급업체코드
+	private String supplyGoodsCd;		//공급업체상품코드(원코드)
+	private String ageGrpCd;		//상품연령대(공통코드 G023)
+	private int delvFee;		//배송비
+	private int minOrdAmt;		//무료배송비최소구매금액
+	private float pntPrate;		//포인트적립율(PC)
+	private float pntMrate;		//포인트적립율(모바일)
+	private float sellFeeRate;		//판매수수료율
+	private String formalGb;		//정상이월구분(공통코드G009)
+	private String changeableYn;		//교환가능여부
+	private String returnableYn;		//반품가능여부
+	private String changeFeeFreeYn;		//교환배송비무료여부
+	private String returnFeeFreeYn;		//반품배송비무료여부
+	private String prePpntUsableYn;		//선포인트사용가능여부(PC)
+	private String preMpntUsableYn;		//선포인트사용가능여부(모바일)
+	private int minOrdQty;		//최소주문수량
+	private int maxOrdQty;		//최대주문수량
+	private int dayMaxOrdQty;		//ID당1일최대구매수량
+	private String giftPackYn;		//선물포장여부
+	private String frstCfrmDt;		//최초승인일시
+	private String originCd;		//제조국(원산지)
+	private String makeYmd;		//제조연월일
+	private String taxGb;		//과세구분(10:과세, 20:비과세)
+	private String erpPriceLinkYn;		//ERP가격연계여부(자사상품만 사용. Y:연계)
+	private String erpStockLinkYn;		//ERP재고연계여부(자사상품만 사용. Y:연계)
+
+}

+ 47 - 0
style24.scm/src/main/java/com/style24/persistence/domain/GoodsImg.java

@@ -0,0 +1,47 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 상품 이미지 Domain
+ * @author eskim
+ * @since 2020. 10. 20
+ */
+@SuppressWarnings("serial")
+@Data
+public class GoodsImg extends TscBaseDomain {
+
+	private String goodsCd;
+	private String colorCd;
+	private String imgType;
+	private String imgPath1;
+	private String imgPath2;
+	private String imgPath3;
+	private String imgPath4;
+	private String imgPath5;
+	private String imgPath6;
+	private String imgPath7;
+	private String imgPath8;
+	private String imgPath9;
+	private String imgPath10;
+	private String imgPath11;
+	private String imgPath12;
+	private String imgPath13;
+	private String imgPath14;
+	private String imgPath15;
+	private String imgPath16;
+	private String imgPath17;
+	private String imgPath18;
+	private String imgPath19;
+	private String imgPath20;
+
+	private String goodsImgPath;
+	private String col;
+	private String mainColorCd;
+	private String mainColorYn;
+	private String colorEnm;
+	private String optCd1;
+
+}

+ 28 - 0
style24.scm/src/main/java/com/style24/persistence/domain/GoodsNotiInfo.java

@@ -0,0 +1,28 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 상품 고시 Domain
+ *
+ * @author eskim
+ * @since 2020. 10. 20
+ */
+@SuppressWarnings("serial")
+@Data
+public class GoodsNotiInfo extends TscBaseDomain {
+
+	private String goodsCd;
+	private String niClsfCd;
+	private String niItemCd;
+	private String niContent;
+	private int dispOrd;
+	private String dispYn;
+	private String reqYn;
+
+	private String niItemNm;
+	private String supplyCompCd;
+
+}

+ 113 - 0
style24.scm/src/main/java/com/style24/persistence/domain/GoodsSearch.java

@@ -0,0 +1,113 @@
+package com.style24.persistence.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.style24.persistence.TscBaseDomain;
+import com.style24.persistence.TssPageRequest;
+
+import lombok.Data;
+
+/**
+ * 상품 검색 Domain
+ *
+ * @author eskim
+ * @since 2019. 12. 10
+ */
+@SuppressWarnings("serial")
+@Data
+public class GoodsSearch extends TscBaseDomain {
+
+	private int startRow;
+	private int endRow;
+	private String search; // 키워드 종류
+	private String condition; // 키워드 종류별 값
+	private String supplyCompCd;
+	private String brandGrpNm;
+	private String brandCd;
+	private String itemkindCd;
+	private String goodsStat;
+	private String styleYear;
+	private String seasonCd;
+	private String sexGb;
+	private String changeableYn;
+	private String returnableYn;
+	private String returnFeeFreeYn;
+	private String changeFeeFreeYn;
+	private String formalGb;
+	private String soldOutYn;
+	private String erpStockLinkYn;
+	private String erpPriceLinkYn;
+	private String mdNo;
+	private String currPrice;
+	private String currPriceSt;
+	private String currPriceEd;
+	private String dcRate;
+	private String dcRateSt;
+	private String dcRateEd;
+	private String pntRateSt;
+	private String pntRateEd;
+	private String stDate;
+	private String edDate;
+	private String stockQtySt;
+	private String stockQtyEd;
+	private String cateCd;
+	private String ageGrpCd;
+
+	private String regSuccYn;
+	private String searchGb;
+	private String callBackFun;
+	private String applyStdt;
+	private String applyEddt;
+	private String optCd1;	//옵션1
+	private String optCd2;	//옵션2
+	private String beforSkipFlag;
+	private String goodsTnm;
+	private String imageViewYn;
+	private String goodsCd;
+	private String goodsNum;
+	private String goodsNm;
+	private String inoutGb;
+	private String applyFlag;
+	private String barcode;
+	private String dateGbn;
+	private String goodsTnmRes;
+	private int goodsPriceResSt;
+	private int goodsPriceResEd;
+	private String selfGoodsYn;
+
+	private String goodsType;
+	private String selfMallYn;
+
+	private String useYn;
+	private String noticeTitle;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] siteCd;
+
+	/* 상품목록 Multi CheckBox 항목*/
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] multiBrand;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] multiItemkindCd;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] multiGoodsStat;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] multiStyleYear;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] multiSeasonCd;
+	/* 상품목록 Multi CheckBox 항목*/
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] conditionList;
+
+	// Pagination
+	private TssPageRequest pageable;
+	private int pageNo = 1;
+	private int pageSize = 50;
+	private int pageUnit = 10;
+
+
+}

+ 25 - 0
style24.scm/src/main/java/com/style24/persistence/domain/Itemkind.java

@@ -0,0 +1,25 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 품목 Domain
+ *
+ * @author gagamel
+ * @since 2020. 10. 7
+ */
+@SuppressWarnings("serial")
+@Data
+public class Itemkind extends TscBaseDomain {
+
+	private String itemkindCd;		// 품목코드
+	private String itemkindNm;		// 품목명
+	//private String itemkindEnm;		// 품목영문명
+	private String niClsfCd;		// 고시분류코드
+	private String useYn;			// 사용여부
+
+//	private String index;
+
+}

+ 36 - 0
style24.scm/src/main/java/com/style24/persistence/domain/NotiInfo.java

@@ -0,0 +1,36 @@
+package com.style24.persistence.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 색상 Domain
+ *
+ * @author gagamel
+ * @since 2020. 10. 7
+ */
+@SuppressWarnings("serial")
+@Data
+public class NotiInfo extends TscBaseDomain {
+
+	private String supplyCompCd;
+	private String niClsfCd;
+	private String niClsfNm;
+	private String niItemCd;
+	private String niItemNm;
+	private String niContent;
+	private Integer dispOrd;
+	private String reqYn;
+	private String dispYn;
+
+	private String crud;
+	private String goodsCd;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] arrNiClsfCd;
+
+	@JsonFormat(with = JsonFormat.Feature.ACCEPT_SINGLE_VALUE_AS_ARRAY)
+	private String[] arrNiItemCd;
+}

+ 45 - 0
style24.scm/src/main/java/com/style24/persistence/domain/Option.java

@@ -0,0 +1,45 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 상품 재고 Domain
+ *
+ * @author eskim
+ * @since 2020. 10. 26
+ */
+@SuppressWarnings("serial")
+@Data
+public class Option extends TscBaseDomain {
+
+	private String goodsCd;
+	private String optCd;
+	private String optNm;
+	private String optCd1;
+	private String optCd2;
+	private int baseStockQty;
+	private int currStockQty;
+	private int addPrice;
+	private String soldoutYn;
+	private String dispOrd;
+	private String dispYn;
+
+	private int rnum;
+	private int rcount;
+	private int saleStockQty;
+	private int ableStockQty;
+	private String goodsNm;
+	private String goodsStat;
+	private String goodsStatNm;
+	private String compsGoodsCd;
+	private String selfGoodsYn;
+	private String itemkindNm;
+	private String brandEnm;
+	private String brandCd;
+	private String itemkindCd;
+	private String supplyCompCd;
+	private String supplyGoodsCd;
+
+}

+ 24 - 0
style24.scm/src/main/java/com/style24/persistence/domain/SearchData.java

@@ -0,0 +1,24 @@
+package com.style24.persistence.domain;
+
+import com.style24.persistence.TscBaseDomain;
+
+import lombok.Data;
+
+/**
+ * 엑셀조회를 위한 SEARCH_DATA Domain
+ *
+ * @author eskim
+ * @since 2020. 10. 22
+ */
+@SuppressWarnings("serial")
+@Data
+public class SearchData extends TscBaseDomain {
+
+	private String searchCd;
+	private int dispOrd;
+	private String procJob;
+	private String dummy1;
+	private String dummy2;
+	private String dummy3;
+
+}

+ 810 - 0
style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssBusiness.xml

@@ -0,0 +1,810 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!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.TsaBusinessDao">
+
+	<!-- 공급업체 목록 -->
+	<select id="getSupplyCompanyList" parameterType="SupplyCompany" resultType="SupplyCompany">
+		/* TsaBusiness.getSupplyCompanyList */
+		SELECT SUPPLY_COMP_CD       /*공급업체코드*/
+		     , SUPPLY_COMP_NM       /*공급업체명*/
+		     , BIZ_GB               /*사업자구분*/
+		     , BIZ_NO               /*사업자등록번호*/
+		     , BIZ_KIND             /*업종*/
+		     , BIZ_TYPE             /*업태*/
+		     , OWNER_NM             /*대표자명*/
+		     , BIZ_ZIPCODE          /*사업장우편번호*/
+		     , BIZ_BASE_ADDR        /*사업장기본주소*/
+		     , BIZ_DTL_ADDR         /*사업장상세주소*/
+		     , MAIN_TELNO           /*대표전화번호*/
+		     , MAIN_FAXNO           /*대표팩스번호*/
+		     , HOMEPAGE_URL         /*홈페이지URL*/
+		     , DISTRIBUTION_GB      /*유통구분*/
+		     , SHOT_DELV_YN         /*총알배송여부*/
+		     , SUPPLY_STAT          /*입점상태*/
+		     , MIN_ORD_AMT          /*무료배송비최소주문금액*/
+		     , DELV_FEE             /*배송비*/
+		     , SELL_FEE_RATE        /*판매수수료율*/
+		     , SETTLE_DAY           /*정산일*/
+		     , BANK_CD              /*은행코드*/
+		     , ACCOUNT_NO           /*계좌번호*/
+		     , DEPOSITOR_NM         /*예금주명*/
+		     , CS_CHARGE_NM         /*CS담당자명*/
+		     , CS_CHARGE_TELNO      /*CS담당자전화번호*/
+		     , SETTLE_CHARGE_NM     /*정산담당자명*/
+		     , SETTLE_CHARGE_TELNO  /*정산담당자전화번호*/
+		     , SETTLE_CHARGE_EMAIL  /*정산담당자이메일*/
+		     , BILL_EMAIL           /*계산서이메일*/
+		     , ECONTRACT_YN         /*전자계약여부*/
+		     , REMARKS              /*비고*/
+		     , USE_YN               /*사용여부*/
+		FROM   TB_SUPPLY_COMPANY
+		WHERE  1 = 1
+		<if test="supplyStat != null and supplyStat != ''">
+		AND    SUPPLY_STAT = #{supplyStat}
+		</if>
+		<if test="searchTxt != null and searchTxt != ''">
+		    <if test='searchGb == "NAME"'>
+		AND    UPPER(SUPPLY_COMP_NM) LIKE CONCAT('%',UPPER(#{searchTxt}),'%')
+		    </if>
+		    <if test='searchGb == "OWNER"'>
+		AND    UPPER(OWNER_NM) LIKE CONCAT('%',UPPER(#{searchTxt}),'%')
+		    </if>
+		</if>
+		<if test="econtractYn != null and econtractYn != ''">
+		AND    ECONTRACT_YN = #{econtractYn}
+		</if>
+		<if test="supplyCompCd != null and supplyCompCd != ''"> <!-- 브랜드관리 화면에서 사용 -->
+		AND    SUPPLY_COMP_CD = #{supplyCompCd}
+		</if>
+	</select>
+	
+	<!-- 공급업체 생성 -->
+	<insert id="createSupplyCompany" parameterType="SupplyCompany">
+		/* TsaBusiness.createSupplyCompany */
+		INSERT INTO TB_SUPPLY_COMPANY (
+		       SUPPLY_COMP_CD
+		     , SUPPLY_COMP_NM
+		     , BIZ_GB
+		     , BIZ_NO
+		     , BIZ_KIND
+		     , BIZ_TYPE
+		     , OWNER_NM
+		     , BIZ_ZIPCODE
+		     , BIZ_BASE_ADDR
+		     , BIZ_DTL_ADDR
+		     , MAIN_TELNO
+		     , MAIN_FAXNO
+		     , HOMEPAGE_URL
+		     , DISTRIBUTION_GB
+		     , SHOT_DELV_YN
+		     , SUPPLY_STAT
+		     , MIN_ORD_AMT
+		     , DELV_FEE
+		     , SELL_FEE_RATE
+		     , SETTLE_DAY
+		     , BANK_CD
+		     , ACCOUNT_NO
+		     , DEPOSITOR_NM
+		     , CS_CHARGE_NM
+		     , CS_CHARGE_TELNO
+		     , SETTLE_CHARGE_NM
+		     , SETTLE_CHARGE_TELNO
+		     , SETTLE_CHARGE_EMAIL
+		     , BILL_EMAIL
+		     , ECONTRACT_YN
+		     , REMARKS
+		     , USE_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       (SELECT CONCAT('S',IFNULL(LPAD(SUBSTRING(MAX(SUPPLY_COMP_CD),2) + 1,4,'0'),'0000'))
+		        FROM   TB_SUPPLY_COMPANY Z
+		        WHERE  SUPPLY_COMP_CD LIKE 'S%'
+		       )
+		     , #{supplyCompNm}
+		     , #{bizGb}
+		     , #{bizNo}
+		     , #{bizKind}
+		     , #{bizType}
+		     , #{ownerNm}
+		     , #{bizZipcode}
+		     , #{bizBaseAddr}
+		     , #{bizDtlAddr}
+		     , #{mainTelno}
+		     , #{mainFaxno}
+		     , #{homepageUrl}
+		     , #{distributionGb}
+		     , #{shotDelvYn}
+		     , #{supplyStat}
+		     , IFNULL(#{minOrdAmt},0)
+		     , IFNULL(#{delvFee},0)
+		     , IFNULL(#{sellFeeRate},0.0)
+		     , #{settleDay}
+		     , #{bankCd}
+		     , #{accountNo}
+		     , #{depositorNm}
+		     , #{csChargeNm}
+		     , #{csChargeTelno}
+		     , #{settleChargeNm}
+		     , #{settleChargeTelno}
+		     , #{settleChargeEmail}
+		     , #{billEmail}
+		     , #{econtractYn}
+		     , #{remarks}
+		     , #{useYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+	</insert>
+	
+	<!-- 공급업체 수정 -->
+	<update id="updateSupplyCompany" parameterType="SupplyCompany">
+		/* TsaBusiness.updateSupplyCompany */
+		UPDATE TB_SUPPLY_COMPANY
+		SET    SUPPLY_COMP_NM = #{supplyCompNm}
+		     , BIZ_GB = #{bizGb}
+		     , BIZ_NO = #{bizNo}
+		     , BIZ_KIND = #{bizKind}
+		     , BIZ_TYPE = #{bizType}
+		     , OWNER_NM = #{ownerNm}
+		     , BIZ_ZIPCODE = #{bizZipcode}
+		     , BIZ_BASE_ADDR = #{bizBaseAddr}
+		     , BIZ_DTL_ADDR = #{bizDtlAddr}
+		     , MAIN_TELNO = #{mainTelno}
+		     , MAIN_FAXNO = #{mainFaxno}
+		     , HOMEPAGE_URL = #{homepageUrl}
+		     , DISTRIBUTION_GB = #{distributionGb}
+		     , SHOT_DELV_YN = #{shotDelvYn}
+		     , SUPPLY_STAT = #{supplyStat}
+		     , MIN_ORD_AMT = IFNULL(#{minOrdAmt},0)
+		     , DELV_FEE = IFNULL(#{delvFee},0)
+		     , SELL_FEE_RATE = IFNULL(#{sellFeeRate},0.0)
+		     , SETTLE_DAY = #{settleDay}
+		     , BANK_CD = #{bankCd}
+		     , ACCOUNT_NO = #{accountNo}
+		     , DEPOSITOR_NM = #{depositorNm}
+		     , CS_CHARGE_NM = #{csChargeNm}
+		     , CS_CHARGE_TELNO = #{csChargeTelno}
+		     , SETTLE_CHARGE_NM = #{settleChargeNm}
+		     , SETTLE_CHARGE_TELNO = #{settleChargeTelno}
+		     , SETTLE_CHARGE_EMAIL = #{settleChargeEmail}
+		     , BILL_EMAIL = #{billEmail}
+		     , ECONTRACT_YN = #{econtractYn}
+		     , REMARKS = #{remarks}
+		     , USE_YN = #{useYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+		WHERE  SUPPLY_COMP_CD = #{supplyCompCd}
+	</update>
+	
+	<!-- 출고처 목록 -->
+	<select id="getDeliveryLocList" parameterType="DeliveryLoc" resultType="DeliveryLoc">
+		/* TsaBusiness.getDeliveryLocList */
+		SELECT DELV_LOC_CD        /*출고처코드*/
+		     , DELV_LOC_NM        /*출고처명*/
+		     , SUPPLY_COMP_CD     /*공급업체코드*/
+		     , DELV_LOC_CLSF      /*출고처분류*/
+		     , DELV_ASSIGN_ORD    /*출고지정순서*/
+		     , DELV_ASSIGN_GRADE  /*출고지정등급*/
+		     , STOCK_APPL_RATE    /*재고적용율*/
+		     , DELV_FEE_RATE      /*출고수수료율*/
+		     , DELV_LOC_ZIPCODE   /*출고처우편번호*/
+		     , DELV_LOC_BASE_ADDR /*출고처기본주소*/
+		     , DELV_LOC_DTL_ADDR  /*출고처상세주소*/
+		     , RTN_LOC_ZIPCODE    /*반품처우편번호*/
+		     , RTN_LOC_BASE_ADDR  /*반품처기본주소*/
+		     , RTN_LOC_DTL_ADDR   /*반품처상세주소*/
+		     , RTN_LOC_NM         /*반품처명*/
+		     , INVOICE_PRINT_TYPE /*송장출력형태*/
+		     , USE_YN             /*사용여부*/
+		FROM   TB_DELIVERY_LOC
+		WHERE  1 = 1
+		<if test="supplyCompCd != null and supplyCompCd != ''">
+		AND    LOWER(SUPPLY_COMP_CD) LIKE CONCAT('%',LOWER(#{supplyCompCd}),'%')
+		</if>
+		<if test="delvLocNm != null and delvLocNm !=''">
+		AND    LOWER(DELV_LOC_NM) LIKE CONCAT('%',LOWER(#{delvLocNm}),'%')
+		</if>
+		<if test="delvLocClsf != null and delvLocClsf != ''">
+		AND    DELV_LOC_CLSF = #{delvLocClsf}
+		</if>
+		<if test="useYn != null and useYn != ''">
+		AND    USE_YN = #{useYn}
+		</if>
+		ORDER  BY DELV_LOC_CD
+	</select>
+
+	<!-- 출고처 저장 -->
+	<insert id="saveDeliveryLoc" parameterType="DeliveryLoc">
+		/*  TsaBusiness.saveDeliveryInfo */
+		INSERT INTO TB_DELIVERY_LOC (
+		       DELV_LOC_CD
+		     , DELV_LOC_NM
+		     , SUPPLY_COMP_CD
+		     , DELV_LOC_CLSF
+		     , DELV_ASSIGN_ORD
+		     , DELV_ASSIGN_GRADE
+		     , STOCK_APPL_RATE
+		     , DELV_FEE_RATE
+		     , DELV_LOC_ZIPCODE
+		     , DELV_LOC_BASE_ADDR
+		     , DELV_LOC_DTL_ADDR
+		     , RTN_LOC_ZIPCODE
+		     , RTN_LOC_BASE_ADDR
+		     , RTN_LOC_DTL_ADDR
+		     , RTN_LOC_NM
+		     , INVOICE_PRINT_TYPE
+		     , USE_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{delvLocCd}
+		     , #{delvLocNm}
+		     , #{supplyCompCd}
+		     , #{delvLocClsf}
+		     , CASE WHEN #{delvLocClsf} IN ('G024_10','G024_21') THEN /*물류창고,직송매장*/
+		                IFNULL(#{delvAssignOrd},100)
+		            ELSE
+		                #{delvAssignOrd}
+		       END
+		     , #{delvAssignGrade}
+		     , CASE WHEN #{delvLocClsf} IN ('G024_10','G024_21') AND #{stockApplRate} = 0.0 THEN /*물류창고,직송매장*/
+		                IFNULL(#{stockApplRate},100.0)
+		            ELSE
+		                #{stockApplRate}
+		       END
+		     , CASE WHEN #{delvLocClsf} = 'G024_21' THEN /*직송매장*/
+		                IFNULL(#{delvFeeRate},0.0)
+		            ELSE
+		                #{delvFeeRate}
+		       END
+		     , #{delvLocZipcode}
+		     , #{delvLocBaseAddr}
+		     , #{delvLocDtlAddr}
+		     , #{rtnLocZipcode}
+		     , #{rtnLocBaseAddr}
+		     , #{rtnLocDtlAddr}
+		     , #{rtnLocNm}
+		     , #{invoicePrintType}
+		     , #{useYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE
+		       DELV_LOC_NM = #{delvLocNm}
+		     , DELV_LOC_CLSF = #{delvLocClsf}
+		     , DELV_ASSIGN_ORD = CASE WHEN #{delvLocClsf} IN ('G024_10','G024_21') THEN /*물류창고,직송매장*/
+		                                  IFNULL(#{delvAssignOrd},100)
+		                              ELSE
+		                                  #{delvAssignOrd}
+		                         END
+		     , DELV_ASSIGN_GRADE = #{delvAssignGrade}
+		     , STOCK_APPL_RATE = CASE WHEN #{delvLocClsf} IN ('G024_10','G024_21') AND #{stockApplRate} = 0.0 THEN /*물류창고,직송매장*/
+		                                  100
+		                              ELSE
+		                                  #{stockApplRate}
+		                         END
+		     , DELV_FEE_RATE = CASE WHEN #{delvLocClsf} = 'G024_21' THEN /*직송매장*/
+		                                IFNULL(#{delvFeeRate},0.0)
+		                            ELSE
+		                                #{delvFeeRate}
+		                       END
+		     , DELV_LOC_ZIPCODE = #{delvLocZipcode}
+		     , DELV_LOC_BASE_ADDR = #{delvLocBaseAddr}
+		     , DELV_LOC_DTL_ADDR = #{delvLocDtlAddr}
+		     , RTN_LOC_ZIPCODE = #{rtnLocZipcode}
+		     , RTN_LOC_BASE_ADDR = #{rtnLocBaseAddr}
+		     , RTN_LOC_DTL_ADDR = #{rtnLocDtlAddr}
+		     , RTN_LOC_NM = #{rtnLocNm}
+		     , INVOICE_PRINT_TYPE = #{invoicePrintType}
+		     , USE_YN = #{useYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+	</insert>
+	
+	<!-- 브랜드 목록 -->
+	<select id="getBrandList" parameterType="Brand" resultType="Brand">
+		/* TsaBusiness.getBrandList */
+		SELECT CASE WHEN A.SELF_YN = 'Y' THEN 'S'
+		            ELSE 'E'
+		       END               AS BRAND_GB /*브랜드구분*/
+		     , A.BRAND_CD                    /*브랜드코드*/
+		     , A.BRAND_ENM                   /*브랜드영문명*/
+		     , A.BRAND_KNM                   /*브랜드한글명*/
+		     , A.BRAND_GRP_NM                /*브랜드그룹명*/
+		     , A.DISTRIBUTION_GB             /*유통구분*/
+		     , A.SUPPLY_COMP_CD              /*업체코드*/
+		     , B.SUPPLY_COMP_NM              /*업체명*/
+		     , A.DELV_LOC_CD                 /*출고처코드*/
+		     , C.DELV_LOC_NM                 /*출고처명*/
+		     , A.ERP_BRAND_CD                /*ERP브랜드코드*/
+		     , A.SELF_YN                     /*자사여부*/
+		     , A.DELV_FEE                    /*기본배송비*/
+		     , A.MIN_ORD_AMT                 /*무료배송비기준*/
+		     , A.SELL_FEE_RATE               /*판매수수료율*/
+		     , A.USE_YN                      /*사용여부*/
+		     , A.PNT_PRATE10                 /*포인트적립율(PC)*/
+		     , A.PNT_MRATE10                 /*포인트적립율(모바일)*/
+		     , A.PNT_PRATE20                 /*포인트적립율(PC)*/
+		     , A.PNT_MRATE20                 /*포인트적립율(모바일)*/
+		     , A.DISP_ORD                    /*표시순서*/
+		FROM   TB_BRAND A
+		INNER JOIN TB_SUPPLY_COMPANY B ON A.SUPPLY_COMP_CD = B.SUPPLY_COMP_CD
+		LEFT OUTER JOIN TB_DELIVERY_LOC C ON A.DELV_LOC_CD = C.DELV_LOC_CD
+		WHERE  1 = 1
+		<if test='supplyCompCd != null and supplyCompCd != ""'>
+		AND    A.SUPPLY_COMP_CD = #{supplyCompCd}
+		</if>
+		<if test='distributionGb != null and distributionGb != ""'>
+		AND    A.DISTRIBUTION_GB = #{distributionGb}
+		</if>
+		<if test='erpBrandCd != null and erpBrandCd != ""'>
+		AND    A.ERP_BRAND_CD =  #{erpBrandCd}
+		</if>
+		<if test='brandCd != null and brandCd != ""'>
+		AND    A.BRAND_CD = #{brandCd}
+		</if>
+		<if test='searchTxt != null and searchTxt != ""'>
+		AND    (
+		        A.BRAND_CD LIKE CONCAT('%',#{searchTxt},'%')
+		        OR
+		        A.BRAND_ENM LIKE CONCAT('%',#{searchTxt},'%')
+		        OR
+		        A.BRAND_KNM LIKE CONCAT('%',#{searchTxt},'%')
+		        OR
+		        A.BRAND_GRP_NM LIKE CONCAT('%',#{searchTxt},'%')
+		       )
+		</if>
+		<if test='useYn != null and useYn != ""'>
+		AND    A.USE_YN = #{useYn}
+		</if>
+		ORDER  BY A.SELF_YN DESC, A.SUPPLY_COMP_CD, A.DISP_ORD
+	</select>
+	
+	<!-- 담당MD 목록 -->
+	<select id="getMdList" parameterType="String" resultType="BrandMd">
+		/* TsaBusiness.getMdList */
+		SELECT USER_NO AS MD_NO
+		     , USER_NM AS MD_NM
+		FROM   TB_USER
+		WHERE  ROLE_CD = 'G001_A101' /*MD권한*/
+		<if test="mdNm != null and mdNm != ''">
+		AND    LOWER(USER_NM) LIKE CONCAT('%',LOWER(#{mdNm}),'%')
+		</if>
+		AND    USE_YN  = 'Y'
+		ORDER  BY USER_NM
+	</select>
+	
+	<!-- 브랜드담당MD 목록 -->
+	<select id="getBrandMdList" parameterType="String" resultType="BrandMd">
+		/* TsaBusiness.getBrandMdList */
+		SELECT A.FORMAL_GB           /*정상이월구분*/
+		     , A.MD_NO               /*담당MD번호*/
+		     , B.USER_NM    AS MD_NM /*담당MD명*/
+		FROM   TB_BRAND_MD A
+		     , TB_USER B
+		WHERE  A.MD_NO = B.USER_NO
+		AND    A.BRAND_CD = #{brandCd}
+	</select>
+	
+	<!-- 브랜드담당MD 삭제 -->
+	<delete id="deleteBrandMd" parameterType="String">
+		/* TsaBusiness.deleteBrandMd */
+		DELETE
+		FROM   TB_BRAND_MD
+		WHERE  BRAND_CD = #{brandCd}
+	</delete>
+
+	<!-- 브랜드담당MD 등록 -->
+	<insert id="createBrandMd" parameterType="BrandMd">
+		/* TsaBusiness.createBrandMd */
+		INSERT INTO TB_BRAND_MD (
+		       BRAND_CD
+		     , FORMAL_GB
+		     , MD_NO
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		SELECT #{brandCd}  AS BRAND_CD
+		     , CD          AS FORMAL_GB
+		     , #{mdNo}     AS MD_NO
+		     , #{regNo}    AS REG_NO
+		     , NOW()       AS REG_DT
+		     , #{updNo}    AS UPD_NO
+		     , NOW()       AS UPD_DT
+		FROM   TB_COMMON_CODE
+		WHERE  CD_GB = 'G009' /*정상이월구분*/
+		AND    CD IN ('G009_10','G009_20') /*정상,이월*/
+		AND    USE_YN = 'Y'
+	</insert>
+	
+	<!-- 브랜드 노출사이트 목록 -->
+	<select id="getBrandSiteList" parameterType="String" resultType="SiteBrand">
+		/* TsaBusiness.getBrandSiteList */
+		SELECT BRAND_CD
+		     , SITE_CD
+		     , DISP_ORD
+		     , USE_YN
+		     , CATE1_NO
+		FROM   TB_SITE_BRAND
+		WHERE  BRAND_CD = #{brandCd}
+		AND    USE_YN ='Y'
+	</select>
+	
+	<!-- 브랜드 노출사이트 등록/수정 -->
+	<insert id="saveBrandSite" parameterType="SiteBrand">
+		/* TsaBusiness.saveBrandSite */
+		INSERT INTO TB_SITE_BRAND (
+		       SITE_CD
+		     , BRAND_CD
+		     , DISP_ORD
+		     , USE_YN
+		     , CATE1_NO
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{siteCd}
+		     , #{brandCd}
+		     , #{dispOrd}
+		     , #{useYn}
+		     , #{cate1No}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE
+		       USE_YN = #{useYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+	</insert>
+	
+	<!-- 브랜드 등록 -->
+	<insert id="createBrand" parameterType="Brand">
+		/* TsaBusiness.createBrand */
+		INSERT INTO TB_BRAND (
+		       BRAND_CD
+		     , BRAND_ENM
+		     , BRAND_KNM
+		     , BRAND_GRP_NM
+		     , SUPPLY_COMP_CD
+		     , DISTRIBUTION_GB
+		     , SELF_YN
+		     , ERP_BRAND_CD
+		     , MIN_ORD_AMT
+		     , DELV_FEE
+		     , DELV_LOC_CD
+		     , SELL_FEE_RATE
+		     , PNT_PRATE10
+		     , PNT_MRATE10
+		     , PNT_PRATE20
+		     , PNT_MRATE20
+		     , DISP_ORD
+		     , USE_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       (SELECT CONCAT(#{brandGb},IFNULL(LPAD(CAST(SUBSTRING(MAX(BRAND_CD),2) AS UNSIGNED) + 1,3,'0'),'000'))
+		        FROM   TB_BRAND Z
+		        WHERE  BRAND_CD LIKE CONCAT(#{brandGb},'%')
+		       )
+		     , #{brandEnm}
+		     , #{brandKnm}
+		     , #{brandGrpNm}
+		     , #{supplyCompCd}
+		     , #{distributionGb}
+		     , CASE WHEN #{distributionGb} IN ('G065_10','G065_11','G065_12') THEN 'Y'
+		            ELSE 'N'
+		       END
+		     , #{erpBrandCd}
+		     , IFNULL(#{minOrdAmt},0)
+		     , IFNULL(#{delvFee},0)
+		     , #{delvLocCd}
+		     , IFNULL(#{sellFeeRate},0)
+		     , IFNULL(#{pntPrate10},0)
+		     , IFNULL(#{pntMrate10},0)
+		     , IFNULL(#{pntPrate20},0)
+		     , IFNULL(#{pntMrate20},0)
+		     , #{dispOrd}
+		     , #{useYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+	</insert>
+	
+	<!-- 브랜드 수정 -->
+	<insert id="updateBrand" parameterType="Brand">
+		/* TsaBusiness.updateBrand */
+		UPDATE TB_BRAND
+		SET    BRAND_ENM = #{brandEnm}
+		     , BRAND_KNM = #{brandKnm}
+		     , BRAND_GRP_NM = #{brandGrpNm}
+		     , SUPPLY_COMP_CD = #{supplyCompCd}
+		     , DISTRIBUTION_GB = #{distributionGb}
+		     , SELF_YN = CASE WHEN #{distributionGb} IN ('G065_10','G065_11','G065_12') THEN 'Y'
+		                      ELSE 'N'
+		                 END
+		     , ERP_BRAND_CD = #{erpBrandCd}
+		     , MIN_ORD_AMT = IFNULL(#{minOrdAmt},0)
+		     , DELV_FEE = IFNULL(#{delvFee},0)
+		     , DELV_LOC_CD = #{delvLocCd}
+		     , SELL_FEE_RATE = IFNULL(#{sellFeeRate},0)
+		     , PNT_PRATE10 = IFNULL(#{pntPrate10},0)
+		     , PNT_MRATE10 = IFNULL(#{pntMrate10},0)
+		     , PNT_PRATE20 = IFNULL(#{pntPrate20},0)
+		     , PNT_MRATE20 = IFNULL(#{pntMrate20},0)
+		     , DISP_ORD = #{dispOrd}
+		     , USE_YN = #{useYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+		WHERE  BRAND_CD = #{brandCd}
+	</insert>
+	
+	<!-- 재고연계관리 - 출고처 목록 -->
+	<select id="getStockSyncDeliveryLocList" parameterType="DeliveryLoc" resultType="DeliveryLoc">
+		/* TsaBusiness.getStockSyncDeliveryLocList */
+		SELECT SUPPLY_COMP_CD
+		     , DELV_LOC_CD
+		     , DELV_LOC_NM
+		     , DELV_LOC_CLSF
+		     , FN_GET_CODE_NM('G024',DELV_LOC_CLSF) AS DELV_LOC_CLSF_NM
+		FROM   TB_DELIVERY_LOC
+		WHERE  SUPPLY_COMP_CD = #{supplyCompCd}
+		AND    DELV_LOC_CLSF IN ('G024_10','G024_21') /*물류창고,직송매장*/
+		<if test="delvLocClsf != null and delvLocClsf != ''">
+		AND    DELV_LOC_CLSF = #{delvLocClsf}
+		</if>
+		<if test="searchTxt != null and searchTxt != ''">
+		    <if test="searchGb == 'CODE'">
+		AND    DELV_LOC_CD = #{delvLocCd}
+		    </if>
+		    <if test="searchGb == 'NAME'">
+		AND    DELV_LOC_NM like CONCAT('%',#{delvLocNm},'%')
+		    </if>
+		</if>
+		AND    USE_YN = 'Y'
+		ORDER  BY DELV_LOC_NM
+	</select>
+
+	<!-- 재고연계관리 - 재고연계기준 목록 -->
+	<select id="getStockSyncBaseList" parameterType="StockSyncBase" resultType="StockSyncBase">
+		/* TsaBusiness.getStockSyncBaseList */
+		SELECT X.DELV_LOC_CD
+		     , X.BRAND_CD
+		     , X.ERP_BRAND_CD
+		     , X.BRAND_KNM
+		     , X.BRAND_ENM
+		     , IFNULL(Y.STOCK_SYNC_YN,'N') AS PREV_STOCK_SYNC_YN /*이전재고연계여부*/
+		     , IFNULL(Y.STOCK_SYNC_YN,'N') AS STOCK_SYNC_YN      /*재고연계여부*/
+		     , IFNULL(Y.DELV_SYNC_YN,'N')  AS PREV_DELV_SYNC_YN  /*이전출고연계여부*/
+		     , IFNULL(Y.DELV_SYNC_YN,'N')  AS DELV_SYNC_YN       /*출고연계여부*/
+		FROM   (
+		        SELECT A.DELV_LOC_CD
+		             , B.BRAND_CD
+		             , B.ERP_BRAND_CD
+		             , B.BRAND_KNM
+		             , B.BRAND_ENM
+		        FROM   TB_DELIVERY_LOC A
+		             , TB_BRAND B
+		        WHERE  A.SUPPLY_COMP_CD = B.SUPPLY_COMP_CD
+		        AND    A.SUPPLY_COMP_CD = #{supplyCompCd}
+		        AND    A.DELV_LOC_CD = #{delvLocCd}
+		        AND    A.USE_YN = 'Y'
+		       ) X
+		LEFT OUTER JOIN TB_STOCK_SYNC_BASE Y ON X.DELV_LOC_CD = Y.DELV_LOC_CD
+		                                    AND X.BRAND_CD = Y.BRAND_CD
+		ORDER BY X.DELV_LOC_CD, X.BRAND_CD
+	</select>
+
+	<!-- 재고연계관리 - 재고연계기준 저장 -->
+	<insert id="saveStockSyncBase" parameterType="StockSyncBase">
+		/* TsaBusiness.saveStockSyncBase */
+		INSERT INTO TB_STOCK_SYNC_BASE (
+		       DELV_LOC_CD
+		     , BRAND_CD
+		     , FORMAL_GB
+		     , STOCK_SYNC_YN
+		     , DELV_SYNC_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{delvLocCd}
+		     , #{brandCd}
+		     , IFNULL(#{formalGb},'G009_10')
+		     , #{stockSyncYn}
+		     , #{delvSyncYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE
+		       STOCK_SYNC_YN = #{stockSyncYn}
+		     , DELV_SYNC_YN = #{delvSyncYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+	</insert>
+
+	<!-- 판매매장 목록  -->
+	<select id="getSellStoreList" parameterType="SellStore" resultType="SellStore">
+		/* TsaBusiness.getSellStoreList */
+		SELECT SELL_STORE_CD
+		     , SELL_STORE_NM
+		     , USE_YN
+		FROM   TB_SELL_STORE
+		WHERE  1 = 1
+		<if test="sellStoreNm != null and sellStoreNm != ''">
+		AND    LOWER(SELL_STORE_NM) LIKE CONCAT('%',LOWER(#{sellStoreNm}),'%')
+		</if>
+		<if test="useYn != null and useYn != ''">
+		AND    USE_YN = #{useYn}
+		</if>
+		ORDER  BY SELL_STORE_NM
+	</select>
+
+	<!-- 판매매장 등록/수정 -->
+	<insert id="saveSellStore" parameterType="SellStore">
+		/* TsaBusiness.saveSellStore */
+		INSERT INTO TB_SELL_STORE (
+		       SUPPLY_COMP_CD
+		     , SELL_STORE_CD
+		     , SELL_STORE_NM
+		     , USE_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{supplyCompCd}
+		     , #{sellStoreCd}
+		     , #{sellStoreNm}
+		     , #{useYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE
+		       SELL_STORE_CD = #{sellStoreCd}
+		     , SELL_STORE_NM = #{sellStoreNm}
+		     , USE_YN = #{useYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+	</insert>
+	
+	<!-- 제휴링크 목록 -->
+	<select id="getAflinkList" parameterType="Aflink" resultType="Aflink">
+		/*  TsaBusiness.getAflinkList */
+		SELECT AF_LINK_CD
+		     , AF_LINK_NM
+		     , AF_CHANNEL
+		     , DISP_ORD
+		     , USE_YN
+		FROM   TB_AF_LINK
+		WHERE  1 = 1
+		<if test="afChannel != null and afChannel != ''">
+		AND    AF_CHANNEL = #{afChannel}
+		</if>
+	</select>
+
+	<!-- 제휴링크 저장 -->
+	<insert id="saveAflink" parameterType="Aflink">
+		/* TsaBusiness.saveAflink */
+		INSERT INTO TB_AF_LINK (
+		       AF_LINK_CD
+		     , AF_LINK_NM
+		     , AF_CHANNEL
+		     , DISP_ORD
+		     , USE_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{afLinkCd}
+		     , #{afLinkNm}
+		     , #{afChannel}
+		     , #{dispOrd}
+		     , #{useYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE
+		       AF_LINK_NM = #{afLinkNm}
+		     , AF_CHANNEL = #{afChannel}
+		     , DISP_ORD = #{dispOrd}
+		     , USE_YN = #{useYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+	</insert>
+
+	<!-- 제휴링크 삭제 -->
+	<update id="deleteAflink" parameterType="Aflink">
+		/* TsaBusiness.deleteAflink */
+		UPDATE TB_AF_LINK
+		SET    USE_YN = 'N'
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+		WHERE  AF_LINK_CD = #{afLinkCd}
+	</update>
+	
+	<!-- 배송업체관리 목록 -->
+	<select id="getShipCompanyList" resultType="ShipCompany">
+		/* TsaBusiness.getShipCompanyList */
+		SELECT SHIP_COMP_CD
+		     , SHIP_COMP_NM
+		     , TRACKING_URL
+		     , USE_YN
+		FROM   TB_SHIP_COMPANY
+		ORDER  BY SHIP_COMP_CD
+	</select>
+
+	<!-- 배송업체관리 저장 -->
+	<insert id="saveShipCompany" parameterType="ShipCompany">
+		/* TsaBusiness.saveShipCompany */
+		INSERT INTO TB_SHIP_COMPANY (
+		       SHIP_COMP_CD
+		     , SHIP_COMP_NM
+		     , TRACKING_URL
+		     , USE_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{shipCompCd}
+		     , #{shipCompNm}
+		     , #{trackingUrl}
+		     , #{useYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE
+		       SHIP_COMP_NM = #{shipCompNm}
+		     , TRACKING_URL = #{trackingUrl}
+		     , USE_YN = #{useYn}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+	</insert>
+	
+	<!-- 배송업체관리 삭제 -->
+	<update id="deleteShipCompany" parameterType="ShipCompany">
+		/* TsaBusiness.updateShipCompany */
+		UPDATE TB_SHIP_COMPANY
+		SET    USE_YN = 'N'
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+		WHERE  SHIP_COMP_CD=  #{shipCompCd}
+	</update>
+	
+</mapper>

+ 74 - 0
style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssCommon.xml

@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!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.TssCommonDao">
+
+	<!-- 엑셀조회를 위한 SEARCH 테이블 삭제  -->
+	<delete id="deleteExceluploadSearCh" parameterType="SearchData">
+		/* TsaCommon.deleteExceluploadSearCh */
+		DELETE
+		FROM   TB_SEARCH_DATA
+		WHERE  REG_NO = #{regNo}
+	</delete>
+
+	<!-- 엑셀조회를 위한 SEARCH 테이블  생성 -->
+	<insert id="createExceluploadSearch" parameterType="SearchData">
+		/* TsaCommon.createExceluploadSearch */
+		INSERT INTO TB_SEARCH_DATA (
+		        REG_NO
+		      , SEARCH_CD
+		      , DISP_ORD
+		 )
+		 SELECT #{regNo}
+		      , #{searchCd}
+		      , (SELECT COUNT(*) + 100
+		         FROM   TB_SEARCH_DATA
+		         WHERE  REG_NO = #{regNo})
+		 FROM   DUAL
+		 WHERE  (SELECT COUNT(*) FROM TB_SEARCH_DATA WHERE SEARCH_CD = #{searchCd} AND REG_NO = #{regNo}) = 0
+	</insert>
+	
+	<!-- 엑셀조회를 위한 SEARCH 테이블  생성 - dummy 컬럼 포함 -->
+	<insert id="createExceluploadSearchByAll" parameterType="SearchData">
+		/* TsaCommon.createExceluploadSearchByAll */
+		INSERT INTO TB_SEARCH_DATA (
+		        REG_NO
+		      , SEARCH_CD
+		      , DISP_ORD
+		      , DUMMY1
+		      , DUMMY2
+		      , DUMMY3
+		 )
+		 SELECT #{regNo}
+		      , #{searchCd}
+		      , (SELECT COUNT(*) + 100
+		         FROM   TB_SEARCH_DATA
+		         WHERE  REG_NO = #{regNo})
+		      , #{dummy1}
+		      , #{dummy2}
+		      , #{dummy3}
+		 FROM   DUAL
+		 WHERE  (SELECT COUNT(*) FROM TB_SEARCH_DATA
+		         WHERE SEARCH_CD = #{searchCd}
+		         AND DUMMY1 = #{dummy1}
+		         AND DUMMY2 = #{dummy2}
+		         AND DUMMY3 = #{dummy3}
+		         AND REG_NO = #{regNo}) = 0
+	</insert>
+	
+	<!-- 샘플파일 시스템파일명 조회 -->
+	<select id="getSampleFileSystemFilename" parameterType="String" resultType="String">
+		/* TsaCommon.getSampleFileSystemFilename */
+		SELECT SYS_FILE_NM
+		FROM   TB_SAMPLE_FILE
+		WHERE  SAMPLE_FILE_ID = #{sampleFileId}
+	</select>
+	
+	<!-- ERP 연동 여부 -->
+	<select id="getErpSyncYn" resultType="String">
+		/* TsaSystem.getErpSyncYn */
+		SELECT UPPER(NVL(USE_YN,'N')) AS ERP_SYNC_YN
+		FROM TB_COMMON_CODE
+		WHERE CD_GB = 'G077'
+		AND CD = 'ERPSYNCYN'
+	</select>
+</mapper>

+ 1348 - 0
style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssGoods.xml

@@ -2,4 +2,1352 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.style24.scm.biz.dao.TssGoodsDao">
 
+	<!-- 상품 목록 건수 -->
+	<select id="getGoodsListCount" parameterType="GoodsSearch" resultType="int">
+		/* TsaGoods.getGoodsListCount */
+		        SELECT COUNT(*) AS TOTCNT
+		        FROM TB_GOODS G
+		        INNER JOIN TB_BRAND B ON G.BRAND_CD = B.BRAND_CD
+		        INNER JOIN TB_SUPPLY_COMPANY S ON G.SUPPLY_COMP_CD = S.SUPPLY_COMP_CD
+		        INNER JOIN TB_GOODS_SUMMARY GS ON G.GOODS_CD = GS.GOODS_CD
+		        <if test="searchGb != null and searchGb =='EXTEND'">
+		        INNER JOIN TB_GOODS_EXTEND GE ON G.GOODS_CD =  GE.EXTEND_GOODS_CD
+		                                      AND GE.GOODS_CD IN
+		            <foreach collection="conditionList" item="item" index="index"  open="(" close=")" separator=",">
+		                                          UPPER(#{item})
+		            </foreach>
+		        </if>
+		        <if test="searchGb != null and searchGb =='MASTER'">
+		        INNER JOIN TB_GOODS_EXTEND GE ON G.GOODS_CD =  GE.GOODS_CD
+		                                      AND GE.EXTEND_GOODS_CD IN
+		            <foreach collection="conditionList" item="item" index="index"  open="(" close=")" separator=",">
+		                                          UPPER(#{item})
+		            </foreach>
+		        </if>
+		        <if test="searchGb != null and searchGb =='EXCEL'">
+		        INNER JOIN (
+		                     SELECT SEARCH_CD
+		                          , TMP_DISP_ORD
+		                     FROM (
+		                           SELECT SEARCH_CD
+		                                , MIN(DISP_ORD) AS TMP_DISP_ORD
+		                           FROM TB_SEARCH_DATA
+		                           WHERE REG_NO = #{regNo}
+		                           GROUP BY SEARCH_CD) T
+		                   ) SD
+		                   ON ( (G.GOODS_CD LIKE CONCAT(SD.SEARCH_CD,'%')
+		                        OR G.SUPPLY_GOODS_CD LIKE CONCAT(SD.SEARCH_CD,'%')) 
+		                        <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>
+		        LEFT OUTER JOIN TB_GOODS_IMG GI ON G.GOODS_CD = GI.GOODS_CD
+		                                        AND G.MAIN_COLOR_CD = GI.COLOR_CD
+		        WHERE 1=1
+		        <if test="searchGb == null or searchGb =='BASIC' or searchGb =='EXTEND' or searchGb =='MASTER'" >
+		        <include refid="getGoodsListCondition_sql"/>
+		        </if>
+	</select>
+
+	<!-- 상품 목록 -->
+	<select id="getGoodsList" parameterType="GoodsSearch" resultType="Goods">
+		/* TsaGoods.getGoodsList */
+		SELECT Z.*
+		    , (CASE WHEN Z.GOODS_TYPE = 'G056_N' THEN (SELECT NVL(SUM(CURR_STOCK_QTY - BASE_STOCK_QTY),0) FROM VW_STOCK WHERE GOODS_CD = Z.GOODS_CD) 
+		            ELSE (SELECT NVL(SUM(CURR_STOCK_QTY - BASE_STOCK_QTY),0) FROM VW_STOCK_COMPOSE WHERE GOODS_CD = Z.GOODS_CD) 
+		            END) AS STOCK_QTY_SUM
+		    , 0 AS STOCK_QTY_SUM
+		    , (SELECT ITEMKIND_NM FROM TB_ITEMKIND WHERE ITEMKIND_CD = Z.ITEMKIND_CD ) AS ITEMKIND_NM
+		    , FN_GET_USER_NM(REG_NO) AS REG_NM
+		    , FN_GET_USER_NM(UPD_NO) AS UPD_NM
+		FROM (
+		    SELECT A.*, @rownum := @rownum + 1 AS RNUM FROM (
+		        SELECT
+		                G.GOODS_CD
+		              , G.GOODS_TYPE
+		              , B.BRAND_ENM
+		              , B.BRAND_GRP_NM
+		              , G.BRAND_CD
+		              , G.ITEMKIND_CD
+		              , G.SUPPLY_COMP_CD
+		              , G.SUPPLY_GOODS_CD
+		              , G.GOODS_NUM
+		              , G.GOODS_NM
+		              , G.GOODS_STAT
+		              , G.LIST_PRICE
+		              , G.CURR_PRICE
+		              , G.DC_RATE
+		              , G.SELF_GOODS_YN
+		              , G.SELF_MALL_YN
+		              , G.FORMAL_GB
+		              , G.STYLE_YEAR
+		              , G.SEASON_CD
+		              , G.ERP_STOCK_LINK_YN
+		              , G.ERP_PRICE_LINK_YN
+		              , G.CHANGEABLE_YN
+		              , G.RETURNABLE_YN
+		              , G.GIFT_PACK_YN
+		              , DATE_FORMAT(G.FRST_CFRM_DT, '%Y%m%d%H%i%S') AS FRST_CFRM_DT
+		              , G.SELL_FEE_RATE
+		              , DATE_FORMAT(G.PRICE_UPD_DT,'%Y%m%d%H%i%S') AS PRICE_UPD_DT
+		              , CASE WHEN IMG_PATH1 IS NULL THEN
+		                     'N'
+		                ELSE
+		                     'Y'
+		                END AS GOODS_IMAGE_YN
+		              , GI.IMG_PATH1
+		              , GI.IMG_PATH6
+		              , GI.IMG_TYPE
+		              , G.REG_NO
+		              , DATE_FORMAT(G.REG_DT,'%Y%m%d%H%i%S') AS REG_DT
+		              , G.UPD_NO
+		              , DATE_FORMAT(G.UPD_DT,'%Y%m%d%H%i%S') AS UPD_DT
+		              , GS.SELL_DAY15_QTY
+		              <choose>
+		                  <when test="searchGb != null and searchGb =='EXCEL'">
+		              , SD.TMP_DISP_ORD
+		                  </when>
+		                  <otherwise>
+		              , 0 AS TMP_DISP_ORD
+		                  </otherwise>
+		              </choose>
+		        FROM TB_GOODS G
+		        JOIN ( SELECT @rownum := 0) R
+		        INNER JOIN TB_BRAND B ON G.BRAND_CD = B.BRAND_CD
+		        INNER JOIN TB_SUPPLY_COMPANY S ON G.SUPPLY_COMP_CD = S.SUPPLY_COMP_CD
+		        INNER JOIN TB_GOODS_SUMMARY GS ON G.GOODS_CD = GS.GOODS_CD
+		        <if test="searchGb != null and searchGb =='EXTEND'">
+		        INNER JOIN TB_GOODS_EXTEND GE ON G.GOODS_CD =  GE.EXTEND_GOODS_CD
+		                                      AND GE.GOODS_CD IN
+		            <foreach collection="conditionList" item="item" index="index"  open="(" close=")" separator=",">
+		                                          UPPER(#{item})
+		            </foreach>
+		        </if>
+		        <if test="searchGb != null and searchGb =='MASTER'">
+		        INNER JOIN TB_GOODS_EXTEND GE ON G.GOODS_CD =  GE.GOODS_CD
+		                                      AND GE.EXTEND_GOODS_CD IN
+		            <foreach collection="conditionList" item="item" index="index"  open="(" close=")" separator=",">
+		                                          UPPER(#{item})
+		            </foreach>
+		        </if>
+		        <if test="searchGb != null and searchGb =='EXCEL'">
+		        INNER JOIN (
+		                     SELECT SEARCH_CD
+		                          , TMP_DISP_ORD
+		                     FROM (
+		                           SELECT SEARCH_CD
+		                                , MIN(DISP_ORD) AS TMP_DISP_ORD
+		                           FROM TB_SEARCH_DATA
+		                           WHERE REG_NO = #{regNo}
+		                           GROUP BY SEARCH_CD) T
+		                   ) SD
+		                   ON ( (G.GOODS_CD LIKE CONCAT(SD.SEARCH_CD,'%')
+		                        OR G.SUPPLY_GOODS_CD LIKE CONCAT(SD.SEARCH_CD,'%')) 
+		                        <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>
+		        LEFT OUTER JOIN TB_GOODS_IMG GI ON G.GOODS_CD = GI.GOODS_CD
+		                                        AND G.MAIN_COLOR_CD = GI.COLOR_CD
+		        WHERE 1=1
+		        <if test="searchGb == null or searchGb =='BASIC' or searchGb =='EXTEND' or searchGb =='MASTER'" >
+		        <include refid="getGoodsListCondition_sql"/>
+		        ORDER BY G.REG_DT DESC, G.GOODS_CD
+		        </if>
+		        <if test="searchGb != null and searchGb =='EXCEL'">
+		        ORDER BY SD.TMP_DISP_ORD
+		        </if>
+		<include refid="getListPagingCondition_sql"/>
+	</select>
+	
+	<!-- 상품 목록 조건 정보 -->
+	<sql id="getGoodsListCondition_sql">
+		        <if test='conditionList != null and conditionList.length>0'>
+		            <choose>
+		              <when test='search != null and search == "searchGoodsCd"'>
+		        AND (
+		              <foreach collection="conditionList" item="item" index="index" separator="or">
+		               UPPER(G.GOODS_CD) LIKE CONCAT('%',UPPER(#{item}),'%') 
+		              </foreach>
+		             )
+		              </when>
+		              <when test='search != null and search == "searchGoodsNum"'>
+		        AND (
+		              <foreach collection="conditionList" item="item" index="index" separator="or">
+		               UPPER(G.GOODS_NUM) LIKE CONCAT('%',UPPER(#{item}),'%')
+		              </foreach>
+		             )
+		              </when>
+		              <when test='search != null and search == "searchSupplyGoodsCd"'>
+		        AND (
+		              <foreach collection="conditionList" item="item" index="index" separator="or">
+		               UPPER(G.SUPPLY_GOODS_CD) LIKE CONCAT('%',UPPER(#{item}),'%')
+		              </foreach>
+		             )
+		              </when>
+		              <when test='search != null and search == "searchExtendGoodsCd"'>
+		        AND 1 = 1
+		              </when>
+		              <when test='search != null and search == "searchMasterGoodsCd"'>
+		        AND 1 = 1
+		              </when>
+		              <otherwise>
+		        AND UPPER(G.REG_ID) LIKE CONCAT('%',UPPER(#{item}),'%')
+		              </otherwise>
+		            </choose>
+		        </if>
+		        <if test="goodsCd != null and goodsCd != ''">
+		        AND UPPER(G.GOODS_CD) LIKE CONCAT('%',UPPER(#{goodsCd}),'%')
+		        </if>
+		         <if test="goodsNm != null and goodsNm != ''">
+		        AND UPPER(G.GOODS_NM) LIKE CONCAT('%',UPPER(#{goodsNm}),'%')
+		        </if>
+		        <if test="goodsType != null and goodsType != ''">
+		        AND G.GOODS_TYPE = #{goodsType}
+		        </if>
+		        <if test="supplyCompCd != null and supplyCompCd != ''">
+		        AND G.SUPPLY_COMP_CD = #{supplyCompCd}
+		        </if>
+		        <if test="brandCd != null and brandCd != ''">
+		        AND G.BRAND_CD = #{brandCd}
+		        </if>
+		        <if test="multiBrand != null and multiBrand != ''">
+		        AND G.BRAND_CD IN
+		            <foreach collection="multiBrand" item="item" index="index"  open="(" close=")" separator=",">
+		        #{item}
+		            </foreach>
+		        </if>
+		        <if test="selfMallYn != null and selfMallYn != ''">
+		        AND G.SELF_MALL_YN = #{selfMallYn}
+		        </if>
+		        <if test="itemkindCd != null and itemkindCd != ''">
+		        AND G.ITEMKIND_CD = #{itemkindCd}
+		        </if>
+		        <if test="multiItemkindCd != null and multiItemkindCd != ''">
+		        AND G.ITEMKIND_CD IN
+		            <foreach collection="multiItemkindCd" item="item" index="index"  open="(" close=")" separator=",">
+		        #{item}
+		            </foreach>
+		        </if>
+		        <if test="goodsStat != null and goodsStat != ''">
+		        AND G.GOODS_STAT = #{goodsStat}
+		        </if>
+		        <if test="multiGoodsStat != null and multiGoodsStat != ''">
+		        AND G.GOODS_STAT IN
+		            <foreach collection="multiGoodsStat" item="item" index="index"  open="(" close=")" separator=",">
+		        #{item}
+		            </foreach>
+		        </if>
+		        <if test="styleYear != null and styleYear != ''">
+		        AND G.STYLE_YEAR = (SELECT CD_NM FROM TB_COMMON_CODE WHERE CD = #{styleYear} AND CD_GB='G023')
+		        </if>
+		        <if test="multiStyleYear != null and multiStyleYear != ''">
+		        AND G.STYLE_YEAR IN (SELECT CD_NM 
+		                             FROM TB_COMMON_CODE 
+		                             WHERE CD_GB='G023' 
+		                             AND CD IN 
+		                             <foreach collection="multiStyleYear" item="item" index="index"  open="(" close=")" separator=",">
+		                             #{item}
+		                             </foreach>
+		                             )
+		        </if>
+		        <if test="seasonCd != null and seasonCd != ''">
+		        AND G.SEASON_CD = #{seasonCd}
+		        </if>
+		        <if test="multiSeasonCd != null and multiSeasonCd != ''">
+		        AND G.SEASON_CD IN
+		            <foreach collection="multiSeasonCd" item="item" index="index"  open="(" close=")" separator=",">
+		        #{item}
+		            </foreach>
+		        </if>
+		        <if test="sexGb != null and sexGb != ''">
+		        AND G.SEX_GB = #{sexGb}
+		        </if>
+		        <if test="changeableYn != null and changeableYn != ''">
+		        AND G.CHANGEABLE_YN = #{changeableYn}
+		        </if>
+		        <if test="returnableYn != null and returnableYn != ''">
+		        AND G.RETURNABLE_YN = #{returnableYn}
+		        </if>
+		        <if test="returnFeeFreeYn != null and returnFeeFreeYn != ''">
+		        AND G.RETURN_FEE_FREE_YN = #{returnFeeFreeYn}
+		        </if>
+		        <if test="changeFeeFreeYn != null and changeFeeFreeYn != ''">
+		        AND G.CHANGE_FEE_FREE_YN = #{changeFeeFreeYn}
+		        </if>
+		        <if test="formalGb != null and formalGb != ''">
+		        AND G.FORMAL_GB = #{formalGb}
+		        </if>
+		        <if test='soldOutYn != null and soldOutYn == "Y"'>
+		        AND EXISTS (
+		                    SELECT GOODS_CD 
+		                    FROM VW_STOCK
+		                    WHERE SOLDOUT_YN = 'Y'
+		                    AND GOODS_CD = G.GOODS_CD
+		                   )
+		        </if>
+		        <if test='soldOutYn != null and soldOutYn == "N"'>
+		        AND NOT EXISTS (
+		                    SELECT GOODS_CD 
+		                    FROM VW_STOCK
+		                    WHERE SOLDOUT_YN = 'Y'
+		                    AND GOODS_CD = G.GOODS_CD
+		                   )
+		        </if>
+		        <if test="erpStockLinkYn != null and erpStockLinkYn != ''">
+		        AND G.ERP_STOCK_LINK_YN = #{erpStockLinkYn}
+		        </if>
+		        <if test="erpPriceLinkYn != null and erpPriceLinkYn != ''">
+		        AND G.ERP_PRICE_LINK_YN = #{erpPriceLinkYn}
+		        </if>
+		        <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="currPriceSt != null and currPriceSt != ''">
+		        AND G.CURR_PRICE >= #{currPriceSt}
+		        </if>
+		        <if test="currPriceEd != null and currPriceEd != ''">
+		        <![CDATA[
+		        AND G.CURR_PRICE <= #{currPriceEd}
+		         ]]>
+		        </if>
+		        <if test="dcRateSt != null and dcRateSt != ''">
+		        AND G.DC_RATE >= #{dcRateSt}
+		        </if>
+		        <if test="dcRateEd != null and dcRateEd != ''">
+		        <![CDATA[
+		        AND G.DC_RATE <= #{dcRateEd}
+		        ]]>
+		        </if>
+		        <if test='dateGbn != null and dateGbn == "P"'>
+		            <if test="stDate != null and stDate != ''">
+		        AND G.PRICE_UPD_DT >= DATE_FORMAT(#{stDate}, '%Y-%m-%d %H:%i:%S')
+		            </if>
+		            <if test="edDate != null and edDate != ''">
+		            <![CDATA[
+		        AND G.PRICE_UPD_DT < DATE_FORMAT(DATE_ADD(#{edDate}, INTERVAL 1 DAY), '%Y-%m-%d %H:%i:%S')
+		            ]]>
+		            </if>
+		        </if>
+		        <if test='dateGbn != null and dateGbn == "R"'>
+		            <if test="stDate != null and stDate != ''">
+		        AND G.REG_DT >= DATE_FORMAT(#{stDate}, '%Y-%m-%d %H:%i:%S')
+		            </if>
+		            <if test="edDate != null and edDate != ''">
+		            <![CDATA[
+		        AND G.REG_DT < DATE_FORMAT(DATE_ADD(#{edDate}, INTERVAL 1 DAY), '%Y-%m-%d %H:%i:%S')
+		            ]]>
+		            </if>
+		        </if>
+		        <if test='dateGbn != null and dateGbn == "S"'>
+		            <if test="stDate != null and stDate != ''">
+		        AND G.FRST_CFRM_DT >= DATE_FORMAT(#{stDate}, '%Y-%m-%d %H:%i:%S')
+		            </if>
+		            <if test="edDate != null and edDate != ''">
+		            <![CDATA[
+		        AND G.FRST_CFRM_DT < DATE_FORMAT(DATE_ADD(#{edDate}, INTERVAL 1 DAY), '%Y-%m-%d %H:%i:%S')
+		            ]]>
+		            </if>
+		        </if>
+		        <if test="stockQtySt != null and stockQtySt != ''">
+		        AND ST.CURR_STOCK_QTY >= #{stockQtySt}
+		        </if>
+		        <if test="stockQtyEd != null and stockQtyEd != ''">
+		        <![CDATA[
+		        AND ST.CURR_STOCK_QTY <= #{stockQtyEd}
+		        ]]>
+		        </if>
+		        <if test="ageGrpCd != null and ageGrpCd != ''">
+		        AND G.AGE_GRP_CD = #{ageGrpCd}
+		        </if>
+		        <if test="cateCd != null and cateCd != ''">
+		        AND G.GOODS_CD IN (
+		            SELECT GOODS_CD
+		            FROM   TB_CATEGORY_GOODS
+		            WHERE  CATE_CD = #{cateCd}
+		        )
+		        </if>
+	</sql>
+	
+	<!-- 목록 페이징 정보 -->
+	<sql id="getListPagingCondition_sql">
+		<choose>
+		<when test="pageable != null">
+		    ) A
+		)Z WHERE RNUM BETWEEN  #{pageable.startRow} AND #{pageable.endRow}
+		</when>
+		<otherwise>
+		    ) A
+		)Z
+		</otherwise>
+		</choose>
+	</sql>
+	
+	<!-- 상품 목록 기본정보 엑셀  -->
+	<select id="getGoodsInfoExcelList" parameterType="GoodsSearch" resultType="paramMap">
+		/* TsaGoods.getGoodsInfoExcelList */
+		SELECT G.GOODS_CD
+		     , B.BRAND_ENM
+		     , B.BRAND_GRP_NM
+		     , G.BRAND_CD
+		     , G.ITEMKIND_CD
+		     , (SELECT SUPPLY_COMP_NM FROM TB_SUPPLY_COMPANY WHERE SUPPLY_COMP_CD = G.SUPPLY_COMP_CD) AS SUPPLY_COMP_CD
+		     , G.SUPPLY_GOODS_CD
+		     , G.GOODS_NUM
+		     , G.GOODS_NM
+		     , G.GOODS_TYPE
+		     , FN_GET_CODE_NM('G008', G.GOODS_STAT) AS GOODS_STAT
+		     , G.LIST_PRICE
+		     , G.CURR_PRICE
+		     , G.DC_RATE
+		     , G.SELF_GOODS_YN
+		     , FN_GET_CODE_NM('G009', G.FORMAL_GB) AS FORMAL_GB
+		     , G.STYLE_YEAR
+		     , FN_GET_CODE_NM('G006', G.SEASON_CD) AS SEASON_CD
+		     , G.ERP_STOCK_LINK_YN
+		     , G.CHANGEABLE_YN
+		     , G.RETURNABLE_YN
+		     , G.SELL_FEE_RATE
+		     , DATE_FORMAT(G.PRICE_UPD_DT, '%Y-%m-%d %H:%i:%S') AS PRICE_UPD_DT
+		     , DATE_FORMAT(G.FRST_CFRM_DT, '%Y-%m-%d %H:%i:%S') AS FRST_CFRM_DT
+		     , CASE WHEN IMG_PATH1 IS NULL THEN
+		           'N'
+		       ELSE
+		           'Y'
+		       END AS GOODS_IMAGE_YN
+		     /*, (CASE WHEN G.GOODS_TYPE = 'N' THEN (SELECT NVL(SUM(CURR_STOCK_QTY - BASE_STOCK_QTY),0) FROM VW_STOCK WHERE GOODS_CD = G.GOODS_CD) 
+		             ELSE (SELECT NVL(SUM(CURR_STOCK_QTY - BASE_STOCK_QTY),0) FROM VW_STOCK_EXTEND WHERE GOODS_CD = G.GOODS_CD) 
+		             END) AS STOCK_QTY_SUM*/
+		     , (SELECT ITEMKIND_NM FROM TB_ITEMKIND WHERE ITEMKIND_CD = G.ITEMKIND_CD) AS ITEMKIND_NM
+		     , GI.IMG_PATH1
+		     , GI.IMG_PATH6
+		     , GI.IMG_TYPE
+		     , G.REG_NO
+		     , DATE_FORMAT(G.REG_DT, '%Y-%m-%d %H:%i:%S') AS REG_DT
+		     , G.UPD_NO
+		     , DATE_FORMAT(G.UPD_DT, '%Y-%m-%d %H:%i:%S') AS UPD_DT
+		FROM TB_GOODS G
+		INNER JOIN TB_BRAND B ON G.BRAND_CD = B.BRAND_CD
+		INNER JOIN TB_SUPPLY_COMPANY S ON G.SUPPLY_COMP_CD = S.SUPPLY_COMP_CD
+		INNER JOIN TB_GOODS_SUMMARY GS ON G.GOODS_CD = GS.GOODS_CD
+		<if test="searchGb != null and searchGb =='EXTEND'">
+		INNER JOIN TB_GOODS_EXTEND GE ON G.GOODS_CD =  GE.EXTEND_GOODS_CD
+		                              AND GE.GOODS_CD IN
+		    <foreach collection="conditionList" item="item" index="index"  open="(" close=")" separator=",">
+		                              UPPER(#{item})
+		    </foreach>
+		</if>
+		<if test="searchGb != null and searchGb =='MASTER'">
+		INNER JOIN TB_GOODS_EXTEND GE ON G.GOODS_CD =  GE.GOODS_CD
+		                              AND GE.EXTEND_GOODS_CD IN
+		    <foreach collection="conditionList" item="item" index="index"  open="(" close=")" separator=",">
+		                          UPPER(#{item})
+		    </foreach>
+		</if>
+		<if test="searchGb != null and searchGb =='EXCEL'">
+		INNER JOIN (
+		             SELECT SEARCH_CD
+		                  , TMP_DISP_ORD
+		             FROM (
+		                   SELECT SEARCH_CD
+		                        , MIN(DISP_ORD) AS TMP_DISP_ORD
+		                   FROM TB_SEARCH_DATA
+		                   WHERE REG_NO = #{regNo}
+		                   GROUP BY SEARCH_CD) T
+		          ) SD
+		           ON ( (G.GOODS_CD LIKE CONCAT(SD.SEARCH_CD,'%')
+		                 OR G.SUPPLY_GOODS_CD LIKE CONCAT(SD.SEARCH_CD,'%')) 
+		                <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>
+		LEFT OUTER JOIN TB_GOODS_IMG GI ON G.GOODS_CD = GI.GOODS_CD
+		                                AND G.MAIN_COLOR_CD = GI.COLOR_CD
+		WHERE 1=1
+		<if test="searchGb == null or searchGb =='BASIC' or searchGb =='EXTEND' or searchGb =='MASTER'" >
+		<include refid="getGoodsListCondition_sql"/>
+		ORDER BY G.REG_DT DESC
+		</if>
+		<if test="searchGb == null or searchGb =='EXCEL'">
+		ORDER BY SD.TMP_DISP_ORD
+		</if>
+	</select>
+	
+	<!-- 상품 정보 -->
+	<select id="getGoods" parameterType="Goods" resultType="Goods">
+		/* TsaGoods.getGoods */
+		SELECT G.GOODS_CD
+		     , G.GOODS_NM
+		     , G.GOODS_TNM
+		     , G.GOODS_SNM
+		     , G.GOODS_SNM1
+		     , G.BRAND_CD
+		     , B.BRAND_GRP_NM
+		     , G.ITEMKIND_CD
+		     , G.STYLE_YEAR
+		     , G.SEASON_CD
+		     , G.SEX_GB
+		     , G.GOODS_NUM
+		     , G.MAIN_COLOR_CD
+		     , G.GOODS_TYPE
+		     , G.LIST_PRICE
+		     , G.CURR_PRICE
+		     , G.CURR_BPRICE
+		     , DATE_FORMAT(G.PRICE_UPD_DT, '%Y%m%d%H%i%S') AS PRICE_UPD_DT
+		     , G.DC_RATE
+		     , G.GOODS_STAT
+		     , G.SELF_GOODS_YN
+		     , G.SELF_MALL_YN
+		     , G.GOODS_GB
+		     , G.DISTRIBUTION_GB
+		     , G.SUPPLY_COMP_CD
+		     , G.SUPPLY_GOODS_CD
+		     , G.AGE_GRP_CD
+		     , G.DELV_FEE
+		     , G.MIN_ORD_AMT
+		     , G.PNT_PRATE
+		     , G.PNT_MRATE
+		     , G.SELL_FEE_RATE
+		     , G.FORMAL_GB
+		     , G.RETURNABLE_YN
+		     , G.PRE_PPNT_USABLE_YN
+		     , G.PRE_MPNT_USABLE_YN
+		     , G.MIN_ORD_QTY
+		     , G.MAX_ORD_QTY
+		     , G.DAY_MAX_ORD_QTY
+		     , G.GIFT_PACK_YN
+		     , G.ERP_STOCK_LINK_YN
+		     , G.ERP_PRICE_LINK_YN
+		     , FN_GET_CODE_NM('G076', G.ORIGIN_CD) AS MAKE_NM
+		     , G.ORIGIN_CD
+		     , G.MAKE_YMD
+		     , G.TAX_GB
+		     , G.GOODS_TYPE
+		     , FN_GET_CODE_NM('G056', G.GOODS_TYPE) AS GOODS_TYPE_NM
+		     , DATE_FORMAT(G.FRST_CFRM_DT, '%Y%m%d%H%i%S') AS FRST_CFRM_DT
+		     , (SELECT I.NI_CLSF_CD FROM TB_ITEMKIND I WHERE I.ITEMKIND_CD = G.ITEMKIND_CD) AS NI_CLSF_CD
+		     , GI.IMG_TYPE
+		     , GI.IMG_PATH1
+		     , GI.IMG_PATH6
+		     , CASE WHEN IMG_PATH1 IS NULL THEN
+		           'N'
+		       ELSE
+		           'Y'
+		       END AS GOODS_IMAGE_YN
+		     , (SELECT B.CD_NM 
+		       FROM TB_ITEMKIND A
+		          , TB_COMMON_CODE B 
+		       WHERE A.ITEMKIND_CD = G.ITEMKIND_CD 
+		       AND A.NI_CLSF_CD = B.CD 
+		       AND B.CD_GB = 'G004') AS  NI_CLSF_NM
+		     , FN_GET_USER_NM(G.UPD_NO) AS UPD_NM  
+		FROM TB_GOODS G
+		INNER JOIN TB_BRAND B ON G.BRAND_CD = B.BRAND_CD
+		LEFT OUTER JOIN TB_GOODS_IMG GI ON G.GOODS_CD = GI.GOODS_CD
+		                                AND G.MAIN_COLOR_CD = GI.COLOR_CD
+		WHERE 1 = 1 
+		<choose>
+		<when test="goodsCd != null and goodsCd != ''">
+		AND G.GOODS_CD = #{goodsCd}
+		</when>
+		<otherwise>
+		AND G.SUPPLY_COMP_CD = #{supplyCompCd}
+		AND G.SUPPLY_GOODS_CD = #{supplyGoodsCd}
+		</otherwise>
+		</choose>
+	</select>
+	
+	<!-- 상품 상세 정보 조회 -->
+	<select id="getGoodsDescList" parameterType="GoodsDesc" resultType="GoodsDesc">
+		/* TsaGoods.getGoodsDescList */
+		SELECT GOODS_CD
+		     , DESC_GB
+		     , SEQ
+		     , GOODS_DESC
+		FROM TB_GOODS_DESC
+		WHERE GOODS_CD = #{goodsCd}
+		AND DESC_GB = #{descGb}
+		ORDER BY SEQ
+	</select>
+	
+	<!-- 상품 고시정보 조회 -->
+	<select id="getGoodsNotiInfoList" parameterType="GoodsNotiInfo" resultType="GoodsNotiInfo">
+		/* TsaGoods.getGoodsNotiInfoList */
+		SELECT C.GOODS_CD
+		     , C.NI_CLSF_CD
+		     , FN_GET_CODE_NM('G005', C.NI_ITEM_CD) AS NI_ITEM_NM
+		     , C.NI_ITEM_CD
+		     , C.NI_CONTENT
+		     , C.DISP_ORD
+		     , A.DISP_YN
+		     , A.REQ_YN
+		FROM TB_GOODS_NOTI_INFO C
+		INNER JOIN TB_NOTI_INFO A ON C.NI_CLSF_CD = A.NI_CLSF_CD
+		                          AND C.NI_ITEM_CD = A.NI_ITEM_CD
+		                          AND A.SUPPLY_COMP_CD = CASE #{supplyCompCd} 
+		                                                 WHEN 'S0001' THEN 'S0001'
+		                                                 WHEN 'S0002' THEN 'S0002'
+		                                                 ELSE 'E' END
+		WHERE C.GOODS_CD = #{goodsCd}
+		AND C.NI_CLSF_CD = #{niClsfCd}
+		ORDER BY C.DISP_ORD
+	</select>
+	
+	<!-- 상품의 정보고시 항목 목록 -->
+	<select id="getNotiGoodsInfoList" parameterType="NotiInfo" resultType="NotiInfo">
+		/* TsaGoods.getNotiGoodsInfoList */
+		SELECT  N.SUPPLY_COMP_CD
+		      , N.NI_CLSF_CD
+		      , N.NI_ITEM_CD
+		      , FN_GET_CODE_NM('G005', N.NI_ITEM_CD) AS NI_ITEM_NM
+		      , CASE WHEN NI_ITEM_CD = 'G005_003' THEN NVL(G.COLOR_NM,N.NI_CONTENT)
+		             WHEN NI_ITEM_CD = 'G005_004' THEN NVL(G.SIZE_NAME,N.NI_CONTENT)
+		             WHEN NI_ITEM_CD = 'G005_006' THEN NVL(FN_GET_CODE_NM('G076', G.ORIGIN_CD),N.NI_CONTENT)
+		             WHEN NI_ITEM_CD = 'G005_097' AND FN_GET_CODE_NM('G076', G.ORIGIN_CD) IN ('대한민국', '한국', 'KOREA') THEN 'N'
+		             WHEN NI_ITEM_CD = 'G005_097' AND FN_GET_CODE_NM('G076', G.ORIGIN_CD) NOT IN ('대한민국', '한국', 'KOREA') THEN 'Y'
+		             WHEN NI_ITEM_CD = 'G005_005' AND G.BRAND_CD= 'T007' THEN G.SUPPLY_COMP_NM
+		             WHEN NI_ITEM_CD = 'G005_009' THEN NVL(G.MAKE_YMD, N.NI_CONTENT)
+		        ELSE N.NI_CONTENT
+		        END
+		        AS  NI_CONTENT
+		      , N.DISP_ORD
+		      , N.REQ_YN
+		      , N.DISP_YN
+		 FROM (
+		     SELECT G.GOODS_CD
+		         , G.ITEMKIND_CD
+		         , G.SUPPLY_COMP_CD
+		         , G.ORIGIN_CD
+		         , G.MAKE_YMD
+		         , (SELECT GROUP_CONCAT(DISTINCT T.OPT_CD1) FROM TB_OPTION T WHERE T.GOODS_CD = G.GOODS_CD)  AS COLOR_NM
+		         , (SELECT GROUP_CONCAT(DISTINCT T.OPT_CD2) FROM TB_OPTION T WHERE T.GOODS_CD = G.GOODS_CD)  AS SIZE_NAME
+		         , G.BRAND_CD
+		         , (SELECT SUPPLY_COMP_NM FROM tb_supply_company SC WHERE SC.SUPPLY_COMP_CD = G.SUPPLY_COMP_CD) AS SUPPLY_COMP_NM 
+		     FROM TB_GOODS G
+		     WHERE 1=1
+		     AND G.GOODS_CD = #{goodsCd}
+		   ) G
+		  , TB_NOTI_INFO N
+		 WHERE 1 = 1
+		 AND N.NI_CLSF_CD = #{niClsfCd}
+		 AND N.SUPPLY_COMP_CD =  CASE G.SUPPLY_COMP_CD
+		                              WHEN 'S0001' THEN 'S0001'
+		                              WHEN 'S0002' THEN 'S0002'
+		                         ELSE 'E' END 
+		 ORDER BY  G.GOODS_CD , N.NI_CLSF_CD, N.DISP_ORD
+	</select>
+	
+	<!-- 상품 기본정보 이력 생성 -->
+	<insert id="createGoodsHst" parameterType="Goods">
+		/* TsaGoods.createGoodsHst */
+		INSERT INTO TB_GOODS_HST 
+		(       GOODS_CD
+		      , BRAND_CD
+		      , ITEMKIND_CD
+		      , GOODS_NM
+		      , GOODS_TNM
+		      , GOODS_SNM
+		      , GOODS_SNM1
+		      , MAIN_COLOR_CD
+		      , STYLE_YEAR
+		      , SEASON_CD
+		      , SEX_GB
+		      , GOODS_NUM
+		      , GOODS_TYPE
+		      , LIST_PRICE
+		      , CURR_PRICE
+		      , CURR_BPRICE
+		      , PRICE_UPD_DT
+		      , DC_RATE
+		      , GOODS_STAT
+		      , SELF_MALL_YN
+		      , GOODS_GB
+		      , DISTRIBUTION_GB
+		      , SELF_GOODS_YN
+		      , SUPPLY_COMP_CD
+		      , SUPPLY_GOODS_CD
+		      , AGE_GRP_CD
+		      , DELV_FEE
+		      , MIN_ORD_AMT
+		      , PNT_PRATE
+		      , PNT_MRATE
+		      , SELL_FEE_RATE
+		      , FORMAL_GB
+		      , CHANGEABLE_YN
+		      , RETURNABLE_YN
+		      , CHANGE_FEE_FREE_YN
+		      , RETURN_FEE_FREE_YN
+		      , PRE_PPNT_USABLE_YN
+		      , PRE_MPNT_USABLE_YN
+		      , MIN_ORD_QTY
+		      , MAX_ORD_QTY
+		      , DAY_MAX_ORD_QTY
+		      , GIFT_PACK_YN
+		      , FRST_CFRM_DT
+		      , ORIGIN_CD
+		      , MAKE_YMD
+		      , TAX_GB
+		      , ERP_PRICE_LINK_YN
+		      , ERP_STOCK_LINK_YN
+		      , REG_NO
+		      , REG_DT
+		      , UPD_NO
+		      , UPD_DT
+		)
+		SELECT GOODS_CD            
+		     , BRAND_CD            
+		     , ITEMKIND_CD         
+		     , GOODS_NM            
+		     , GOODS_TNM           
+		     , GOODS_SNM           
+		     , GOODS_SNM1          
+		     , MAIN_COLOR_CD
+		     , STYLE_YEAR          
+		     , SEASON_CD           
+		     , SEX_GB              
+		     , GOODS_NUM           
+		     , GOODS_TYPE          
+		     , LIST_PRICE          
+		     , CURR_PRICE          
+		     , CURR_BPRICE         
+		     , PRICE_UPD_DT        
+		     , DC_RATE             
+		     , GOODS_STAT          
+		     , SELF_MALL_YN             
+		     , GOODS_GB            
+		     , DISTRIBUTION_GB     
+		     , SELF_GOODS_YN       
+		     , SUPPLY_COMP_CD      
+		     , SUPPLY_GOODS_CD     
+		     , AGE_GRP_CD          
+		     , DELV_FEE            
+		     , MIN_ORD_AMT         
+		     , PNT_PRATE           
+		     , PNT_MRATE           
+		     , SELL_FEE_RATE       
+		     , FORMAL_GB           
+		     , CHANGEABLE_YN       
+		     , RETURNABLE_YN       
+		     , CHANGE_FEE_FREE_YN  
+		     , RETURN_FEE_FREE_YN  
+		     , PRE_PPNT_USABLE_YN  
+		     , PRE_MPNT_USABLE_YN  
+		     , MIN_ORD_QTY         
+		     , MAX_ORD_QTY         
+		     , DAY_MAX_ORD_QTY     
+		     , GIFT_PACK_YN
+		     , FRST_CFRM_DT        
+		     , ORIGIN_CD             
+		     , MAKE_YMD            
+		     , TAX_GB              
+		     , ERP_PRICE_LINK_YN   
+		     , ERP_STOCK_LINK_YN   
+		     , #{regNo}              
+		     , NOW()              
+		     , UPD_NO              
+		     , UPD_DT              
+		FROM TB_GOODS
+		WHERE GOODS_CD = #{goodsCd}
+	</insert>
+	
+	<!-- 상품  수정 항목 일괄변경 -->
+	<update id="updateGoodsState" parameterType="Goods">
+		/* TsaGoods.updateGoodsState */
+		UPDATE TB_GOODS SET
+		      UPD_NO = #{updNo}
+		    , UPD_DT = NOW()
+		<if test="goodsStat != null and goodsStat != ''" >
+		    , GOODS_STAT = #{goodsStat}
+		    , FRST_CFRM_DT = IF(#{chGoodsStatYn} = 'Y', COALESCE(FRST_CFRM_DT, NOW()) , FRST_CFRM_DT)
+		</if>
+		<if test="erpStockLinkYn != null and erpStockLinkYn != ''" >
+		    , ERP_STOCK_LINK_YN = #{erpStockLinkYn}
+		</if>
+		<if test="erpPriceLinkYn != null and erpPriceLinkYn != ''" >
+		    , ERP_PRICE_LINK_YN = #{erpPriceLinkYn}
+		</if>
+		<if test="formalGb != null and formalGb != ''" >
+		    , FORMAL_GB = #{formalGb}
+		    , PNT_PRATE = IFNULL(#{pntPrate}, PNT_PRATE)
+		    , PNT_MRATE = IFNULL(#{pntMrate}, PNT_MRATE)
+		</if>
+		<if test='procJob == "pntPrate" and pntPrate != null' >
+		    , PNT_PRATE = #{pntPrate}
+		</if>
+		<if test='procJob == "pntMrate"  and pntMrate != null' >
+		    , PNT_MRATE = #{pntMrate}
+		</if>
+		<if test="returnableYn != null and returnableYn != ''" >
+		    , RETURNABLE_YN = #{returnableYn}
+		</if>
+		<if test="changeableYn != null and changeableYn != ''" >
+		    , CHANGEABLE_YN = #{changeableYn}
+		</if>
+		<if test="prePpntUsableYn != null and prePpntUsableYn != ''" >
+		    , PRE_PPNT_USABLE_YN = #{prePpntUsableYn}
+		</if>
+		<if test="preMpntUsableYn != null and preMpntUsableYn != ''" >
+		    , PRE_MPNT_USABLE_YN = #{preMpntUsableYn}
+		</if>
+		<if test='procJob == "minOrdAmt"  and minOrdAmt != null and minOrdAmt != ""' >
+		    , MIN_ORD_AMT = #{minOrdAmt}
+		</if>
+		<if test='blankFlag != null and blankFlag == "Y"'>
+		    , GOODS_TNM = ''
+		</if>
+		<if test="goodsTnm != null and goodsTnm != ''" >
+		    , GOODS_TNM = #{goodsTnm}
+		</if>
+		<if test="minOrdQty != null and minOrdQty > 0" >
+		    , MIN_ORD_QTY = #{minOrdQty}
+		</if>
+		<if test="maxOrdQty != null and maxOrdQty > 0" >
+		    , MAX_ORD_QTY = #{maxOrdQty}
+		</if>
+		<if test="dayMaxOrdQty != null and dayMaxOrdQty > 0" >
+		    , DAY_MAX_ORD_QTY = #{dayMaxOrdQty}
+		</if>
+		<if test="giftPackYn != null and giftPackYn != ''" >
+		    , GIFT_PACK_YN = #{giftPackYn}
+		</if>
+		WHERE GOODS_CD = #{goodsCd}
+	</update>
+	
+	<!-- 상품 이미지 필수  항목 입력 여부  조회 -->
+	<select id="getGoodsImgsYn" parameterType="Goods" resultType="Goods">
+		/* TsaGoods.getGoodsImgsYn */
+		SELECT A.GOODS_CD
+		     , A.SUPPLY_COMP_CD
+		     , (SELECT I.NI_CLSF_CD FROM TB_ITEMKIND I WHERE I.ITEMKIND_CD = A.ITEMKIND_CD) AS NI_CLSF_CD
+		     , CASE WHEN B.IMG_PATH1 IS NULL THEN
+		            'N'
+		       ELSE
+		            'Y'
+		       END AS GOODS_IMAGE_YN
+		FROM TB_GOODS A
+		LEFT OUTER JOIN TB_GOODS_IMG B ON A.GOODS_CD = B.GOODS_CD
+		                               AND A.MAIN_COLOR_CD = B.COLOR_CD
+		WHERE 1 = 1
+		<choose>
+		<when test="goodsCd != null and goodsCd != ''">
+		AND A.GOODS_CD  = #{goodsCd}
+		</when>
+		<otherwise>
+		AND A.GOODS_CD IN
+		    <foreach collection="arrGoodsCd" item="item" index="index"  open="(" close=")" separator=",">
+		#{item}
+		    </foreach>
+		</otherwise>
+		</choose>
+	</select>
+	
+	<!-- 상품 정보 이력 -->
+	<select id="getGoodsHstList" parameterType="Goods" resultType="GoodsHst">
+		/*TsaGoods.getGoodsHstList*/
+		SELECT CURR_PRICE
+		     , CURR_BPRICE
+		     , GOODS_NM
+		     , GOODS_TNM
+		     , GOODS_SNM
+		     , FORMAL_GB
+		     , GOODS_STAT
+		     , SELL_FEE_RATE
+		     , ERP_STOCK_LINK_YN
+		     , CHANGEABLE_YN
+		     , PRE_PPNT_USABLE_YN
+		     , PRE_MPNT_USABLE_YN
+		     , GOODS_SNM1
+		     , ITEMKIND_CD
+		     , SELF_MALL_YN
+		     , GIFT_PACK_YN
+		     , DATE_FORMAT(FRST_CFRM_DT, '%Y%m%d%H%i%S') AS FRST_CFRM_DT
+		     , UPD_NO
+		     , FN_GET_USER_NM(UPD_NO) AS UPD_NM
+		     , DATE_FORMAT(UPD_DT, '%Y%m%d%H%i%S') AS UPD_DT
+		     , REG_NO
+		     , FN_GET_USER_NM(REG_NO) AS REG_NM
+		     , DATE_FORMAT(REG_DT, '%Y%m%d%H%i%S') AS REG_DT
+		FROM TB_GOODS_HST
+		WHERE GOODS_CD = #{goodsCd}
+		ORDER BY REG_DT DESC
+	</select>
+	
+	<!-- 상품 품목 변경 -->
+	<update id="updateGoodItemKindCd" parameterType="Goods">
+		/* TsaGoods.updateGoodItemKindCd */
+		UPDATE TB_GOODS
+		SET ITEMKIND_CD = #{itemkindCd}
+		  , UPD_NO = #{updNo}
+		  , UPD_DT = NOW()
+		WHERE GOODS_CD = #{goodsCd}
+	</update >
+	
+	<!-- 상품 자동 검색어 조회-->
+	<select id="getGoodsSnm" parameterType="String" resultType="String">
+		/* TsaGoods.getGoodsSnm */
+		SELECT UPPER(CONCAT(
+		       G.GOODS_CD,';',
+		       REPLACE(G.GOODS_NM,' ',''),';',
+		       B.BRAND_ENM,';',
+		       B.BRAND_KNM,';',
+		       B.BRAND_GRP_NM,';',
+		       G.STYLE_YEAR,';',
+		       FN_GET_CODE_NM('G006',G.SEASON_CD),';',
+		       FN_GET_CODE_NM('G007',G.SEX_GB),';',
+		      /* G.COLOR_CD,';',
+		       C.COLOR_ENM,';',
+		       C.COLOR_KNM,';',*/
+		       REPLACE(I.ITEMKIND_NM,'>',';')
+		       )) AS GOODS_SNM
+		FROM TB_GOODS G
+		INNER JOIN TB_BRAND B ON G.BRAND_CD = B.BRAND_CD
+		LEFT OUTER JOIN TB_ITEMKIND I ON G.ITEMKIND_CD = I.ITEMKIND_CD
+		/*LEFT OUTER JOIN TB_COLOR C ON G.COLOR_CD = C.COLOR_CD*/
+		WHERE G.GOODS_CD = #{goodsCd}
+	</select>
+	
+	<!-- 상품검색어 수정 -->
+	<update id="updateGoodsSnm" parameterType="Goods">
+		/* TsaGoods.updateGoodsSnm */
+		UPDATE TB_GOODS A
+		SET UPD_NO = #{updNo}
+		  , UPD_DT = NOW()
+		  , GOODS_SNM = #{goodsSnm} 
+		WHERE GOODS_CD = #{goodsCd}
+	</update>
+	
+	<!-- 상품 품목변경 고시정보 조회  -->
+	<select id="getNewNotiInfo" parameterType="Goods" resultType="GoodsNotiInfo">
+		/* TsaGoods.getNewNotiInfo */
+		SELECT D.NI_CLSF_CD
+		     , NVL(C.NI_ITEM_CD, D.NI_ITEM_CD) AS NI_ITEM_CD
+		     , NVL(C.NI_CONTENT, D.NI_CONTENT) AS NI_CONTENT
+		     , D.DISP_ORD
+		FROM (
+		       SELECT A.NI_CLSF_CD
+		          , A.NI_ITEM_CD
+		          , A.NI_CONTENT
+		          , A.DISP_ORD
+		       FROM TB_NOTI_INFO A
+		          , TB_ITEMKIND B
+		       WHERE A.NI_CLSF_CD = B.NI_CLSF_CD
+		       AND A.SUPPLY_COMP_CD = #{supplyCompCd}
+		       AND B.ITEMKIND_CD = #{itemkindCd}
+		     ) D
+		    LEFT OUTER JOIN (
+		       SELECT NI_ITEM_CD
+		            , NI_CONTENT 
+		       FROM TB_GOODS_NOTI_INFO
+		       WHERE GOODS_CD = #{goodsCd}
+		     ) C
+		     ON (
+		       C.NI_ITEM_CD = D.NI_ITEM_CD
+		     )
+		ORDER BY D.DISP_ORD
+	</select>
+	
+	<!-- 상품 품목변경 고시정보 삭제  -->
+	<delete id="deleteGoodsNotiInfo" parameterType="Goods">
+		/* TsaGoods.deleteGoodsNotiInfo */
+		DELETE FROM TB_GOODS_NOTI_INFO
+		WHERE GOODS_CD = #{goodsCd}
+	</delete>
+	
+	<!-- 상품 고시 정보  저장 -->
+	<update id="saveGoodsNotiInfo" parameterType="GoodsNotiInfo">
+		/* TsaGoods.saveGoodsNotiInfo */
+		INSERT INTO TB_GOODS_NOTI_INFO(
+		       GOODS_CD
+		     , NI_CLSF_CD
+		     , NI_ITEM_CD
+		     , NI_CONTENT
+		     , DISP_ORD
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{goodsCd}
+		     , #{niClsfCd}
+		     , #{niItemCd}
+		     , #{niContent}
+		     , #{dispOrd}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE
+		       NI_CONTENT = #{niContent}
+		     , UPD_NO = #{updNo}
+		     , UPD_DT = NOW()
+	</update>
+	
+	<!-- 상품 사이즈 조회 -->
+	<select id="getGoodsSizeList" parameterType="Goods" resultType="Option">
+		/* TsaGoods.getGoodsSizeList */
+		WITH RECURSIVE TMP_GOODS AS (
+		    SELECT A.GOODS_CD 
+		         , A.GOODS_TYPE 
+		         , IFNULL(B.COMPS_GOODS_CD, A.GOODS_CD) AS COMPS_GOODS_CD
+		         , IFNULL(B.DISP_ORD,1) AS DISP_ORD
+		         , A.SELF_GOODS_YN
+		    FROM TB_GOODS A 
+		    LEFT OUTER JOIN TB_GOODS_COMPOSE B ON A.GOODS_CD = B.GOODS_CD
+		    WHERE A.GOODS_CD = #{goodsCd}
+		    )
+		SELECT #{goodsCd} AS GOODS_CD
+		     , A.GOODS_CD AS COMPS_GOODS_CD
+		     , A.OPT_CD
+		     , CONCAT(A.OPT_CD1,  NVL2(A.OPT_CD2, '', CONCAT('/', A.OPT_CD2))) AS OPT_NM 
+		     , A.OPT_CD1
+		     , A.OPT_CD2
+		     , A.ADD_PRICE
+		     , A.BASE_STOCK_QTY
+		     , A.CURR_STOCK_QTY
+		     , IFNULL(B.STOCK_QTY,0) AS SALE_STOCK_QTY
+		     , GREATEST(GREATEST(A.CURR_STOCK_QTY - A.BASE_STOCK_QTY, 0) - IFNULL(B.STOCK_QTY, 0), 0) AS ABLE_STOCK_QTY
+		     , A.SOLDOUT_YN
+		     , A.DISP_ORD
+		     , A.DISP_YN
+		     , COUNT(*) OVER(PARTITION BY A.GOODS_CD ) AS RCOUNT
+		     , ROW_NUMBER() OVER(PARTITION BY A.GOODS_CD ORDER BY A.DISP_ORD) AS RNUM
+		FROM  TMP_GOODS C 
+		INNER JOIN TB_OPTION A ON C.COMPS_GOODS_CD = A.GOODS_CD 
+		LEFT OUTER JOIN (
+		                 SELECT Z.GOODS_CD
+		                      , Z.OPT_CD
+		                      , SUM((CASE Z.SELL_GB WHEN '10' THEN 1
+		                                            WHEN '20' THEN 1
+		                                            ELSE -1 END) * Z.SELL_QTY) AS STOCK_QTY
+		                 FROM TB_SELL_QTY Z
+		                 INNER JOIN TMP_GOODS Y ON Z.GOODS_CD = Y.COMPS_GOODS_CD
+		                 GROUP BY Z.GOODS_CD, Z.OPT_CD
+		                ) B
+		           ON (  A.GOODS_CD = B.GOODS_CD
+		             AND A.OPT_CD = B.OPT_CD)
+		WHERE 1 = 1
+		AND C.GOODS_CD = #{goodsCd}
+		ORDER BY C.DISP_ORD, A.DISP_ORD
+	</select>
+	
+	<!-- 상품 색상목록 조회 -->
+	<select id="getGoodsColorList" parameterType="Goods" resultType="GoodsImg">
+		/* TsaGoods.getGoodsColorList */
+		SELECT A.GOODS_CD 
+		     , NVL(A.OPT_CD1, A.MAIN_COLOR_CD) AS OPT_CD1
+		     , A.MAIN_COLOR_CD
+		     , IF(A.MAIN_COLOR_CD = NVL(A.OPT_CD1, A.MAIN_COLOR_CD), 'Y','N') AS  MAIN_COLOR_YN 
+		     , GI.IMG_PATH1
+		     , GI.IMG_PATH6
+		     , NVL(GI.IMG_TYPE,'G030_A') AS IMG_TYPE
+		     , C.COLOR_ENM 
+		FROM (
+		      SELECT A.GOODS_CD 
+		           , A.MAIN_COLOR_CD 
+		           , B.OPT_CD1 
+		      FROM TB_GOODS A
+		      LEFT OUTER JOIN TB_OPTION B ON A.GOODS_CD = B.GOODS_CD
+		      WHERE A.GOODS_CD  = #{goodsCd}
+		      GROUP BY A.GOODS_CD , B.OPT_CD1
+		     ) A 
+		LEFT OUTER JOIN TB_COLOR C ON A.OPT_CD1 = C.COLOR_CD 
+		LEFT OUTER JOIN TB_GOODS_IMG GI ON A.GOODS_CD  = GI.GOODS_CD 
+		                                AND A.OPT_CD1 = GI.COLOR_CD
+	</select>
+	
+	<!-- 상품 기본 정보 등록 -->
+	<insert id="createGoods" parameterType="Goods">
+		/* TsaGoods.createGoods */
+		INSERT INTO TB_GOODS (
+		    GOODS_CD
+		  , BRAND_CD
+		  , ITEMKIND_CD
+		  , GOODS_NM
+		  , GOODS_TNM
+		  , GOODS_SNM
+		  , GOODS_SNM1
+		  , MAIN_COLOR_CD
+		  , STYLE_YEAR
+		  , SEASON_CD
+		  , SEX_GB
+		  , GOODS_NUM
+		  , GOODS_TYPE
+		  , LIST_PRICE
+		  , CURR_PRICE
+		  , DC_RATE
+		  , GOODS_STAT
+		  , SELF_MALL_YN
+		  , GOODS_GB
+		  , DISTRIBUTION_GB
+		  , SELF_GOODS_YN
+		  , SUPPLY_COMP_CD
+		  , SUPPLY_GOODS_CD
+		  , AGE_GRP_CD
+		  , DELV_FEE
+		  , MIN_ORD_AMT
+		  , PNT_PRATE
+		  , PNT_MRATE
+		  , SELL_FEE_RATE
+		  , FORMAL_GB
+		  , GIFT_PACK_YN
+		  , ORIGIN_CD
+		  , MAKE_YMD
+		  , TAX_GB
+		  , ERP_STOCK_LINK_YN
+		  , REG_NO
+		  , REG_DT
+		  , UPD_NO
+		  , UPD_DT
+		)
+		VALUES(
+		    #{goodsCd}
+		  , #{brandCd}
+		  , #{itemkindCd}
+		  , NVL(#{goodsNm},'상품명없음')
+		  , #{goodsTnm}
+		  , #{goodsSnm}
+		  , #{goodsSnm1}
+		  , #{mainColorCd}
+		  , #{styleYear}
+		  , #{seasonCd}
+		  , #{sexGb}
+		  , #{goodsNum}
+		  , NVL(#{goodsType},'N')
+		  , #{listPrice}
+		  , #{currPrice}
+		  , #{dcRate}
+		  , #{goodsStat}
+		  , NVL(#{selfMallYn},'Y') 
+		  , #{goodsGb}
+		  , #{distributionGb}
+		  , #{selfGoodsYn}
+		  , #{supplyCompCd}
+		  , #{supplyGoodsCd}
+		  , #{ageGrpCd}
+		  , #{delvFee}
+		  , #{minOrdAmt}
+		  , #{pntPrate}
+		  , #{pntMrate}
+		  , #{sellFeeRate}
+		  , #{formalGb}
+		  , NVL(#{giftPackYn},'N')
+		  , #{mriginCd}
+		  , #{makeYmd}
+		  , #{taxGb}
+		  , NVL(#{erpStockLinkYn},'N')
+		  , #{regNo}
+		  , NOW()
+		  , #{updNo}
+		  , NOW()
+		)
+	</insert>
+	
+	<!-- 상품 기본 정보 등록 -->
+	<insert id="createGoodsSmmary" parameterType="Goods">
+		/* TsaGoods.createGoodsSmmary */
+		INSERT INTO TB_GOODS_SUMMARY (
+		    GOODS_CD
+		  , REG_NO
+		  , REG_DT
+		  , UPD_NO
+		  , UPD_DT
+		)
+		VALUES(
+		    #{goodsCd}
+		  , #{regNo}
+		  , NOW()
+		  , #{updNo}
+		  , NOW()
+		)
+	</insert>
+	
+	<!-- 상품 기본 정보 수정 -->
+	<update id="updateGoods" parameterType="Goods">
+		/* TsaGoods.updateGoods */
+		UPDATE TB_GOODS
+		SET GOODS_TNM = #{goodsTnm}
+		  , GOODS_NM = #{goodsNm}
+		  , SEASON_CD = #{seasonCd}
+		  , SEX_GB = #{sexGb}
+		  , CURR_PRICE = #{currPrice}
+		  <if test="currBprice != null and currBprice != ''">
+		  , CURR_BPRICE = #{currBprice}
+		  , PRICE_UPD_DT = NOW()
+		  </if>
+		  , DC_RATE = #{dcRate}
+		  , GOODS_STAT = #{goodsStat}
+		  , GOODS_GB = #{goodsGb}
+		  , MIN_ORD_AMT = #{minOrdAmt}
+		  , PNT_PRATE = #{pntPrate}
+		  , PNT_MRATE = #{pntMrate}
+		  , FORMAL_GB = #{formalGb}
+		  , MIN_ORD_QTY = #{minOrdQty}
+		  , MAX_ORD_QTY = #{maxOrdQty}
+		  , DAY_MAX_ORD_QTY = #{dayMaxOrdQty}
+		  , ERP_STOCK_LINK_YN = #{erpStockLinkYn}
+		  , GOODS_SNM1 = #{goodsSnm1}
+		  , SELF_MALL_YN = #{selfMallYn}
+		  , GOODS_SNM = #{goodsSnm}
+		  , FRST_CFRM_DT = (CASE #{chGoodsStatYn} WHEN 'Y' THEN NVL2(FRST_CFRM_DT, NOW(), FRST_CFRM_DT)
+		                                          ELSE FRST_CFRM_DT END)
+		  , PRE_PPNT_USABLE_YN = #{prePpntUsableYn}
+		  , PRE_MPNT_USABLE_YN = #{preMpntUsableYn}
+		  , DISTRIBUTION_GB = #{distributionGb}
+		  , AGE_GRP_CD = #{ageGrpCd}
+		  , SELL_FEE_RATE = #{sellFeeRate}
+		  , GIFT_PACK_YN = #{giftPackYn}
+		  , MAIN_COLOR_CD = #{mainColorCd}
+		  , UPD_NO = #{updNo}
+		  , UPD_DT = NOW()
+		WHERE GOODS_CD = #{goodsCd}
+	</update>
+	
+	<!-- 상품 상세정보 삭제 -->
+	<delete id="deleteGoodsDesc" parameterType="GoodsDesc">
+		/* TsaGoods.deleteGoodsDesc */
+		DELETE FROM TB_GOODS_DESC
+		WHERE GOODS_CD = #{goodsCd}
+		AND DESC_GB = #{descGb}
+	</delete>
+	
+	<!-- 상품 상세정보 등록 -->
+	<insert id="createGoodsDesc" parameterType="GoodsDesc">
+		/* TsaGoods.createGoodsDesc */
+		INSERT INTO TB_GOODS_DESC (
+		    GOODS_CD
+		  , DESC_GB
+		  , SEQ
+		  , GOODS_DESC
+		  , REG_NO
+		  , REG_DT
+		)
+		VALUES(
+		    #{goodsCd}
+		  , #{descGb}
+		  , #{seq}
+		  , REPLACE(#{goodsDesc},char(13), CONCAT(char(13),char(10)))
+		  , #{regNo}
+		  , NOW()
+		)
+	</insert>
+	
+	<!-- 상품 옵션/재고 정보 이력생성 -->
+	<insert id="createStockHst" parameterType="Option">
+	/* TsaGoods.createStockHst */
+		INSERT INTO TB_OPTION_HST 
+		(     OPTION_HST_SQ
+		    , GOODS_CD
+		    , OPT_CD
+		    , OPT_CD1
+		    , OPT_CD2
+		    , BASE_STOCK_QTY
+		    , CURR_STOCK_QTY
+		    , ADD_PRICE
+		    , SOLDOUT_YN
+		    , DISP_ORD
+		    , DISP_YN
+		    , REG_NO
+		    , REG_DT
+		    , UPD_NO
+		    , UPD_DT
+		)
+		SELECT NULL
+		     , GOODS_CD
+		     , OPT_CD
+		     , OPT_CD1
+		     , OPT_CD2
+		     , BASE_STOCK_QTY
+		     , CURR_STOCK_QTY
+		     , ADD_PRICE
+		     , SOLDOUT_YN
+		     , DISP_ORD
+		     , DISP_YN
+		     , #{regNo}
+		     , NOW()
+		     , UPD_NO
+		     , UPD_DT
+		FROM TB_OPTION
+		WHERE GOODS_CD = #{goodsCd}
+		<if test='optCd != null and optCd != ""'>
+		AND OPT_CD = #{optCd}
+		</if>
+	</insert>
+	
+	<!-- 상품 옵션/재고 정보 저장 -->
+	<update id="saveStock" parameterType="Option">
+		/* TsaGoods.saveStock */
+		INSERT INTO TB_OPTION(
+		       GOODS_CD
+		     , OPT_CD
+		     , OPT_CD1
+		     , OPT_CD2
+		     , BASE_STOCK_QTY
+		     , CURR_STOCK_QTY
+		     , ADD_PRICE
+		     , SOLDOUT_YN
+		     , DISP_ORD
+		     , DISP_YN
+		     , REG_NO
+		     , REG_DT
+		     , UPD_NO
+		     , UPD_DT
+		)
+		VALUES (
+		       #{goodsCd}
+		     , #{optCd}
+		     , #{optCd1}
+		     , #{optCd2}
+		     , #{baseStockQty}
+		     , #{currStockQty}
+		     , #{addPrice}
+		     , #{soldoutYn}
+		     , #{dispOrd}
+		     , #{dispYn}
+		     , #{regNo}
+		     , NOW()
+		     , #{updNo}
+		     , NOW()
+		)
+		ON DUPLICATE KEY UPDATE 
+		        BASE_STOCK_QTY = #{baseStockQty}
+		      , ADD_PRICE = #{addPrice}
+		      , SOLDOUT_YN = #{soldoutYn}
+		      , DISP_ORD = #{dispOrd}
+		      , DISP_YN = #{dispYn}
+		      , UPD_NO = #{updNo}
+		      , UPD_DT = NOW()
+		      <if test='selfGoodsYn != null and selfGoodsYn == "N"'>
+		      , CURR_STOCK_QTY = #{currStockQty}
+		      </if>
+	</update>
+	
+	<!-- 상품코드 생성 -->
+	<insert id="createGoodsSequence" parameterType="Goods">
+		/* 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>
 </mapper>

+ 315 - 3
style24.scm/src/main/java/com/style24/persistence/mybatis/shop/TssRenderer.xml

@@ -2,11 +2,11 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.style24.scm.biz.dao.TssRendererDao">
 
-	<!-- 공급업체 목록 -->
+<!-- 공급업체 목록 -->
 	<select id="getSupplyCompanyList" parameterType="SupplyCompany" resultType="CommonCode">
 		/* TsaRenderer.getSupplyCompanyList */
-		SELECT SUPPLY_COMP_CD AS CD
-		     , SUPPLY_COMP_NM AS CD_NM
+		SELECT SUPPLY_COMP_CD  AS CD
+		     , SUPPLY_COMP_NM  AS CD_NM
 		FROM   TB_SUPPLY_COMPANY
 		WHERE  USE_YN = 'Y'
 		<if test='supplyCompCd != null and supplyCompCd != ""'>
@@ -49,5 +49,317 @@
 		</if>
 		ORDER  BY CD_GB, DISP_ORD
 	</select>
+	
+	<!-- 최상위메뉴 목록 -->
+	<select id="getTopMenuList" parameterType="String" resultType="CommonCode">
+		/* TsaRenderer.getTopMenuList */
+		WITH RECURSIVE CONNECTBY AS (
+		    SELECT 1                                    AS LVL
+		         , MENU_ID
+		         , MENU_NM
+		         , CONCAT(MENU_ID,LPAD(DISP_ORD,4,'0')) AS ORDBY
+		    FROM   TB_MENU
+		    WHERE  USE_YN = 'Y'
+		    <choose>
+		        <when test="pmenuId != null and pmenuId != ''">
+		    AND    PMENU_ID = #{pmenuId}
+		        </when>
+		        <otherwise>
+		    AND    PMENU_ID = 'ROOT'
+		        </otherwise>
+		    </choose>
+		    
+		    UNION ALL
+		    
+		    SELECT A.LVL + 1                              AS LVL
+		         , B.MENU_ID
+		         , B.MENU_NM
+		         , CONCAT(A.ORDBY,LPAD(B.DISP_ORD,4,'0')) AS ORDBY
+		    FROM   CONNECTBY A
+		    INNER JOIN TB_MENU B ON A.MENU_ID = B.PMENU_ID
+		    WHERE  B.USE_YN = 'Y'
+		)
+		SELECT MENU_ID AS CD
+		     , MENU_NM AS CD_NM
+		FROM   CONNECTBY
+		WHERE  LVL = 1
+		ORDER  BY ORDBY
+	</select>
+
+	<!-- 전체메뉴 목록 -->
+	<select id="getAllMenuList" resultType="CommonCode">
+		/* TsaRenderer.getAllMenuList */
+		WITH RECURSIVE CONNECTBY AS (
+		    SELECT 1                                    AS LVL
+		         , MENU_ID
+		         , MENU_NM
+		         , MENU_GB
+		         , CONCAT(MENU_ID,LPAD(DISP_ORD,4,'0')) AS ORDBY
+		    FROM   TB_MENU
+		    WHERE  USE_YN = 'Y'
+		    AND    PMENU_ID = 'ROOT'
+		    
+		    UNION ALL
+		    
+		    SELECT A.LVL + 1                              AS LVL
+		         , B.MENU_ID
+		         , B.MENU_NM
+		         , B.MENU_GB
+		         , CONCAT(A.ORDBY,LPAD(B.DISP_ORD,4,'0')) AS ORDBY
+		    FROM   CONNECTBY A
+		           INNER JOIN TB_MENU B ON A.MENU_ID = B.PMENU_ID
+		    WHERE  B.USE_YN = 'Y'
+		)
+		SELECT MENU_ID                                                 AS CD
+		     , CONCAT(REPEAT('--',(LVL - 1)),'[',MENU_ID,'] ',MENU_NM) AS CD_NM
+		FROM   CONNECTBY
+		WHERE  MENU_GB = 'M'
+		ORDER  BY ORDBY
+	</select>
+
+	<!-- 벤더별 외부몰 목록 -->
+	<select id="getVendorExtmallList" parameterType="String" resultType="CommonCode">
+		/* TsaRenderer.getVendorExtmallList */
+		SELECT DISTINCT
+		       EXTMALL_ID AS CD
+		     , EXTMALL_NM AS CD_NM
+		FROM   TB_EXTMALL
+		WHERE  VENDOR_ID = #{vendorId}
+		AND    USE_YN = 'Y'
+		ORDER  BY EXTMALL_ID
+	</select>
+
+	<!-- 벤더별 외부몰판매매장 목록 -->
+	<select id="getVendorExtmallSellStoreList" parameterType="String" resultType="CommonCode">
+		/* TsaRenderer.getVendorExtmallSellStoreList */
+		SELECT A.SELL_STORE_CD AS CD
+		     , B.SELL_STORE_NM AS CD_NM
+		FROM   TB_EXTMALL A
+		     , TB_SELL_STORE B
+		WHERE  A.SELL_STORE_CD = B.SELL_STORE_CD
+		AND    A.VENDOR_ID = #{vendorId}
+		AND    A.USE_YN = 'Y'
+		AND    B.USE_YN = 'Y'
+		GROUP  BY A.SELL_STORE_CD, B.SELL_STORE_NM
+		ORDER  BY B.SELL_STORE_NM
+	</select>
+
+	<!-- 브랜드 목록 -->
+	<select id="getBrandList" parameterType="Brand" resultType="CommonCode">
+		/* TsaRenderer.getBrandList */
+		SELECT BRAND_CD  AS CD
+		     , BRAND_ENM AS CD_NM
+		FROM   TB_BRAND
+		WHERE  1 = 1
+		<if test='supplyCompCd != null and supplyCompCd != ""'>
+		AND    SUPPLY_COMP_CD = #{supplyCompCd}
+		</if>
+		<if test='brandGrpNm != null and brandGrpNm != ""'>
+		AND    BRAND_GRP_NM = #{brandGrpNm}
+		</if>
+		<if test='useYn != null and useYn != ""'>
+		AND    USE_YN = #{useYn}
+		</if>
+		ORDER  BY SUPPLY_COMP_CD, DISP_ORD
+	</select>
+
+	<!-- 권한별 브랜드 목록 -->
+	<select id="getAuthBrandList" parameterType="int" resultType="CommonCode">
+		/* TsaRenderer.getAuthBrandList */
+		SELECT A.BRAND_CD  AS CD
+		     , A.BRAND_ENM AS CD_NM
+		FROM   TB_BRAND A
+		INNER JOIN TB_BRAND_MD B ON A.BRAND_CD = B.BRAND_CD
+		WHERE  A.USE_YN = 'Y'
+		AND    B.MD_NO = #{userNo}
+		GROUP  BY A.BRAND_CD, A.BRAND_ENM
+		ORDER  BY A.BRAND_CD
+	</select>
+
+	<!-- 출고처 목록 -->
+	<select id="getDeliveryLocList" parameterType="DeliveryLoc" resultType="CommonCode">
+		/* TsaRenderer.getDeliveryLocList */
+		SELECT DELV_LOC_CD AS CD
+		     , DELV_LOC_NM AS CD_NM
+		FROM   TB_DELIVERY_LOC
+		WHERE  USE_YN = 'Y'
+		<if test='supplyCompCd != null and supplyCompCd != ""'>
+		AND    SUPPLY_COMP_CD = #{supplyCompCd}
+		</if>
+		<if test='delvLocClsf != null and delvLocClsf != ""'>
+		AND    DELV_LOC_CLSF = #{delvLocClsf}
+		</if>
+		ORDER  BY DELV_LOC_NM
+	</select>
+
+	<!-- 정보고시 목록 -->
+	<select id="getCateInfoList" parameterType="String" resultType="CommonCode">
+		/* TsaRenderer.getCateInfoList */
+		SELECT NI_CLSF_CD AS CD
+		     , B.CD_NM
+		FROM   TB_NOTI_INFO A
+		INNER JOIN TB_GOODS G ON G.SUPPLY_COMP_CD = A.SUPPLY_COMP_CD
+		INNER JOIN TB_COMMON_CODE B ON A.NI_CLSF_CD = B.CD
+		WHERE  G.GOODS_CD = #{goodsCd}
+		AND    B.CD_GB = 'G004'
+		AND    B.USE_YN = 'Y'
+		GROUP  BY NI_CLSF_CD, B.CD_NM
+		ORDER  BY NI_CLSF_CD
+	</select>
+
+	<!-- 품목 목록 -->
+	<select id="getItemkindList" parameterType="Itemkind" resultType="CommonCode">
+		/* TsaRenderer.getItemkindList */
+		SELECT ITEMKIND_CD AS CD
+		     , ITEMKIND_NM AS CD_NM
+		FROM   TB_ITEMKIND
+		WHERE  USE_YN = 'Y'
+		<if test='itemkindCd != null and itemkindCd != ""'>
+		AND    ITEMKIND_CD = #{itemkindCd}
+		</if>
+		ORDER  BY ITEMKIND_CD
+	</select>
+
+	<!-- 브랜드그룹 목록 -->
+	<select id="getBrandGroupList" resultType="CommonCode">
+		/* TsaRenderer.getBrandGroupList */
+		SELECT BRAND_GRP_NM AS CD
+		     , BRAND_GRP_NM AS CD_NM
+		FROM   TB_BRAND
+		WHERE  USE_YN = 'Y'
+		AND    BRAND_GRP_NM IS NOT NULL
+		GROUP  BY BRAND_GRP_NM
+		ORDER  BY BRAND_GRP_NM
+	</select>
+
+	<!-- 컬러 목록 -->
+	<select id="getColorList" parameterType="Color" resultType="CommonCode">
+		/* TsaRenderer.getColorList */
+		SELECT COLOR_CD  AS CD
+		     , COLOR_ENM AS CD_NM
+		     , COLOR_KNM AS CD_DESC
+		     , USE_YN
+		FROM   TB_COLOR
+		WHERE  USE_YN = 'Y'
+		<if test='colorCd != null and colorCd != ""'>
+		AND    COLOR_CD = #{colorCd}
+		</if>
+		ORDER  BY COLOR_CD
+	</select>
+
+	<!-- 사용중 대카테고리 목록 -->
+	<select id="getTCategoryList" parameterType="String" resultType="CommonCode">
+		/* TsaRenderer.getTCategoryList */
+		SELECT TCATE_CD AS CD
+		     , TCATE_NM AS CD_NM
+		FROM   TB_CATEGORY_4SRCH
+		WHERE  1 = 1
+		<if test='cateGb != null and cateGb != ""'>
+		AND    CATE_GB = #{cateGb}
+		</if>
+		GROUP  BY TCATE_CD, TCATE_NM
+		ORDER  BY TCATE_CD
+	</select>
+
+	<!-- 브랜드에 등록된 MD 목록 -->
+	<select id="getBrandMdList" resultType="CommonCode">
+		/* TsaRenderer.getBrandMdList */
+		SELECT DISTINCT
+		       A.MD_NO   AS CD
+		     , C.USER_NM AS CD_NM
+		FROM   TB_BRAND_MD A
+		INNER JOIN TB_BRAND B ON A.BRAND_CD = B.BRAND_CD
+		INNER JOIN TB_USER C ON A.MD_NO = C.USER_NO
+		ORDER  BY C.USER_NM
+	</select>
+
+	<!-- 택배사명 목록 조회 -->
+	<select id="getShipCompanyList" resultType="CommonCode">
+		/* TsaDelivery.getShipCompanyList */
+		SELECT SHIP_COMP_CD  AS CD
+		     , SHIP_COMP_NM  AS CD_NM
+		FROM   TB_SHIP_COMPANY
+		WHERE  1 = 1
+		<if test='useYn != null and useYn != ""'>
+		AND    USE_YN = #{useYn}
+		</if>
+	</select>
+
+	<!-- MD별 브랜드 목록 조회 -->
+	<select id="getMdBrandList" resultType="CommonCode">
+		/* TsaRenderer.getMdBrandList*/
+		SELECT DISTINCT
+		       A.BRAND_CD AS CD
+		     , B.BRAND_ENM AS CD_NM
+		FROM   TB_BRAND_MD A
+		     , TB_BRAND B
+		WHERE  A.BRAND_CD = B.BRAND_CD
+		<if test='mdNo != null and mdNo != "" and mdNo != "all"'>
+		AND    A.MD_NO = #{mdNo}
+		</if>
+	</select>
+
+	<!-- MD별 브랜드그룹조회 -->
+	<select id="getMdBrandGrpList" resultType="CommonCode">
+		/* TsaRenderer.getMdBrandGrpList*/
+		SELECT DISTINCT
+		       B.BRAND_GRP_NM AS CD
+		     , B.BRAND_GRP_NM AS CD_NM
+		FROM   TB_BRAND_MD A
+		      ,TB_BRAND B
+		WHERE  A.BRAND_CD = B.BRAND_CD
+		<if test='mdNo != null and mdNo != "" and mdNo != "all"'>
+		AND    A.MD_NO = #{mdNo}
+		</if>
+		GROUP  BY BRAND_GRP_NM
+	</select>
+
+	<select id="getInstaAccount" resultType="CommonCode">
+		/* TsaRenderer.getInstaAccount*/
+		SELECT DISTINCT
+		       IT.INSTA_ACCOUNT AS CD
+		     , IT.INSTA_ACCOUNT AS CD_NM
+		FROM   TB_INSTAGRAM_TOKEN IT
+	</select>
+
+	<!-- 판매몰조회 -->
+	<select id="getSellStoreList" resultType="CommonCode">
+		/* TsaRenderer.getSellStoreList*/
+		SELECT DISTINCT
+		       SELL_STORE_CD AS CD
+		     , SELL_STORE_NM AS CD_NM
+		FROM   TB_SELL_STORE
+	</select>
+
+	<!-- 기본답변문구 제목 목록 -->
+	<select id="getBasicAnsTitleList" parameterType="String" resultType="CommonCode">
+		/* TsaRenderer.getBasicAnsTitleList */
+		SELECT ANS_SQ     AS CD
+		     , ANS_TITLE  AS CD_NM
+		FROM   TB_BASIC_ANS
+		WHERE  ANS_CLSF = #{ansClsf}
+		AND    USE_YN = 'Y'
+	</select>
+
+	<!-- 제휴링크 목록 -->
+	<select id="getAflinkList" parameterType="String" resultType="CommonCode">
+		/* TsaRenderer.getAflinkList */
+		SELECT AF_LINK_CD AS CD
+		     , AF_LINK_NM AS CD_NM
+		FROM   TB_AF_LINK
+		WHERE  AF_CHANNEL = #{afChannel}
+		AND    USE_YN = 'Y'
+	</select>
+	
+	<!-- 색상그룹코드 RGB 목록 -->
+	<select id="getColorGrpCdRgbList" resultType="CommonCode">
+		/* TsaRenderer.getColorGrpCdRgbList */
+		SELECT CD
+			 , CD_DESC AS CD_NM
+		FROM TB_COMMON_CODE
+		WHERE 1=1
+		AND CD_GB = 'G072'
+		AND USE_YN = 'Y'
+	</select>
 
 </mapper>

+ 227 - 0
style24.scm/src/main/java/com/style24/scm/biz/dao/TssBusinessDao.java

@@ -0,0 +1,227 @@
+package com.style24.scm.biz.dao;
+
+import java.util.Collection;
+
+import com.style24.core.support.annotation.ShopDs;
+import com.style24.persistence.domain.Brand;
+import com.style24.persistence.domain.SupplyCompany;
+
+/**
+ * 영업관리 Dao
+ *
+ * @author gagamel
+ * @since 2020. 10. 14
+ */
+@ShopDs
+public interface TssBusinessDao {
+
+	/**
+	 * 공급업체 목록
+	 * @param supplyComp - 공급업체 정보
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 10. 14
+	 */
+	Collection<SupplyCompany> getSupplyCompanyList(SupplyCompany supplyComp);
+
+	/**
+	 * 공급업체 생성
+	 * @param supplyComp - 공급업체 정보
+	 * @author gagamel
+	 * @since 2020. 10. 14
+	 */
+	void createSupplyCompany(SupplyCompany supplyComp);
+
+	/**
+	 * 공급업체 수정
+	 * @param supplyComp - 공급업체 정보
+	 * @author gagamel
+	 * @since 2020. 10. 14
+	 */
+	void updateSupplyCompany(SupplyCompany supplyComp);
+
+//	/**
+//	 * 출고처관리 목록
+//	 * @param delvLoc - 출고처 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 16
+//	 */
+//	Collection<DeliveryLoc> getDeliveryLocList(DeliveryLoc delvLoc);
+
+	/**
+	 * 브랜드 목록
+	 * @param brand - 브랜드 정보
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	Collection<Brand> getBrandList(Brand brand);
+
+//	/**
+//	 * 담당MD 목록
+//	 * @param brandMd - 담당MD 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	Collection<BrandMd> getMdList(BrandMd brandMd);
+//
+//	/**
+//	 * 브랜드담당MD 목록
+//	 * @param brandCd - 브랜드코드
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	Collection<BrandMd> getBrandMdList(String brandCd);
+
+//	/**
+//	 * 브랜드담당MD 삭제
+//	 * @param brandCd - 브랜드코드
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	void deleteBrandMd(String brandCd);
+//
+//	/**
+//	 * 브랜드담당MD 등록
+//	 * @param brandMd - 브랜드담당MD 정보
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	void createBrandMd(BrandMd brandMd);
+//
+//	/**
+//	 * 브랜드 노출사이트 목록
+//	 * @param brandCd - 브랜드코드
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	Collection<SiteBrand> getBrandSiteList(String brandCd);
+//
+//	/**
+//	 * 브랜드 노출사이트 등록/수정
+//	 * @param siteBrand - 사이트브랜드 정보
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	void saveBrandSite(SiteBrand siteBrand);
+
+	/**
+	 * 브랜드 등록
+	 * @param brand - 브랜드 정보
+	 * @author gagamel
+	 * @since 2020. 11. 5
+	 */
+	void createBrand(Brand brand);
+
+	/**
+	 * 브랜드 수정
+	 * @param brand - 브랜드 정보
+	 * @author gagamel
+	 * @since 2020. 11. 5
+	 */
+	void updateBrand(Brand brand);
+
+//	/**
+//	 * 출고처관리 저장
+//	 * @param delvLoc - 출고처 정보
+//	 * @author gagamel
+//	 * @since 2020. 10. 16
+//	 */
+//	void saveDeliveryLoc(DeliveryLoc delvLoc);
+//
+//	/**
+//	 * 재고연계관리 - 출고처 목록
+//	 * @param delvLoc - 출고처 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 7
+//	 */
+//	Collection<DeliveryLoc> getStockSyncDeliveryLocList(DeliveryLoc delvLoc);
+//
+//	/**
+//	 * 재고연계관리 - 재고연계기준 목록
+//	 * @param stockSyncBase - 재고연계기준 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 7
+//	 */
+//	Collection<StockSyncBase> getStockSyncBaseList(StockSyncBase stockSyncBase);
+//
+//	/**
+//	 * 재고연계관리 - 재고연계기준 저장
+//	 * @param stockSyncBase - 재고연계기준 정보
+//	 * @author gagamel
+//	 * @since 2020. 11. 7
+//	 */
+//	void saveStockSyncBase(StockSyncBase stockSyncBase);
+//
+//	/**
+//	 * 판매매장 목록
+//	 * @param sellStore - 판매매장 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	Collection<SellStore> getSellStoreList(SellStore sellStore);
+//
+//	/**
+//	 * 판매매장 정보 수정
+//	 * @param sellStore - 판매매장 정보
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	void saveSellStore(SellStore sellStore);
+//
+//	/**
+//	 * 제휴링크 목록
+//	 * @param aflink - 제휴링크 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	Collection<Aflink> getAflinkList(Aflink aflink);
+//
+//	/**
+//	 * 제휴링크 저장
+//	 * @param aflink - 제휴링크 정보
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	void saveAflink(Aflink aflink);
+//
+//	/**
+//	 * 제휴링크 삭제
+//	 * @param aflink - 제휴링크 정보
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	void deleteAflink(Aflink aflink);
+//
+//	/**
+//	 * 배송업체 목록
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	Collection<ShipCompany> getShipCompanyList();
+//
+//	/**
+//	 * 배송업체 저장
+//	 * @param shipComp - 배송업체 정보
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	void saveShipCompany(ShipCompany shipComp);
+//
+//	/**
+//	 * 배송업체 삭제
+//	 * @param shipComp - 배송업체 정보
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	void deleteShipCompany(ShipCompany shipComp);
+
+}

+ 60 - 0
style24.scm/src/main/java/com/style24/scm/biz/dao/TssCommonDao.java

@@ -0,0 +1,60 @@
+package com.style24.scm.biz.dao;
+
+import com.style24.core.support.annotation.ShopDs;
+import com.style24.persistence.domain.SearchData;
+
+/**
+ * 공용 Dao
+ *
+ * @author eskim
+ * @since 2020. 10. 22
+ */
+@ShopDs
+public interface TssCommonDao {
+
+	/**
+	 * 엑셀조회를 위한 SEARCH 테이블 삭제
+	 *
+	 * @param searchData
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	void deleteExceluploadSearCh(SearchData searchData);
+
+	/**
+	 * 엑셀조회를 위한 SEARCH 테이블 생성
+	 *
+	 * @param searchData
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	void createExceluploadSearch(SearchData searchData);
+
+	/**
+	 * 엑셀조회를 위한 SEARCH 테이블 생성 - dummy 컬럼 포함
+	 *
+	 * @param searchData
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	void createExceluploadSearchByAll(SearchData searchData);
+
+	/**
+	 * 샘플파일 시스템파일명 조회
+	 * @param sampleFileId - 샘플파일ID
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 11. 3
+	 */
+	String getSampleFileSystemFilename(String sampleFileId);
+
+	/**
+	 * ERP 연동 여부
+	 *
+	 * @return
+	 * @author eskim
+	 * @since 2020. 01. 16
+	 */
+	String getErpSyncYn();
+
+}

+ 221 - 0
style24.scm/src/main/java/com/style24/scm/biz/dao/TssGoodsDao.java

@@ -1,6 +1,18 @@
 package com.style24.scm.biz.dao;
 
+import java.util.Collection;
+
 import com.style24.core.support.annotation.ShopDs;
+import com.style24.persistence.domain.Goods;
+import com.style24.persistence.domain.GoodsDesc;
+import com.style24.persistence.domain.GoodsHst;
+import com.style24.persistence.domain.GoodsImg;
+import com.style24.persistence.domain.GoodsNotiInfo;
+import com.style24.persistence.domain.GoodsSearch;
+import com.style24.persistence.domain.NotiInfo;
+import com.style24.persistence.domain.Option;
+
+import com.gagaframework.web.parameter.GagaMap;
 
 /**
  * 상품 Dao
@@ -11,4 +23,213 @@ import com.style24.core.support.annotation.ShopDs;
 @ShopDs
 public interface TssGoodsDao {
 
+	/**
+	 * 상품 목록 건수
+	 *
+	 * @param goodsSearch
+	 * @return
+	 * @author eskim
+	 * @since 2010. 10. 20
+	 */
+	int getGoodsListCount(GoodsSearch goodsSearch);
+
+	/**
+	 * 상품 목록
+	 *
+	 * @param goodsSearch
+	 * @return
+	 * @author eskim
+	 * @since 2010. 10. 20
+	 */
+	Collection<Goods> getGoodsList(GoodsSearch goodsSearch);
+
+	/**
+	 * 상품 목록 기본정보 엑셀다운로드
+	 *
+	 * @param goodsSearch
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	Collection<GagaMap> getGoodsInfoExcelList(GoodsSearch goodsSearch);
+
+	/**
+	 * 상품 이미지 필수 항목 입력 여부 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	Collection<Goods> getGoodsImgsYn(Goods goods);
+
+	/**
+	 * 상품 상세
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	Goods getGoods(Goods goods);
+
+	/**
+	 * 상품 상세 정보 조회
+	 *
+	 * @param goodsVideo
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	Collection<GoodsDesc> getGoodsDescList(GoodsDesc goodsDesc);
+
+	/**
+	 * 상품 정보 이력
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2019. 08. 12
+	 */
+	Collection<GoodsHst> getGoodsHstList(Goods goods);
+
+	/**
+	 * 상품 옵션 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 26
+	 */
+	Collection<Option> getGoodsSizeList(Goods goods);
+
+	/**
+	 * 상품 색상목록 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 11. 18
+	 */
+	Collection<GoodsImg> getGoodsColorList(Goods goods);
+
+	/**
+	 * 상품 고시 조회
+	 *
+	 * @param goodsNotiInfo
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 12
+	 */
+	Collection<GoodsNotiInfo> getGoodsNotiInfoList(GoodsNotiInfo goodsNotiInfo);
+
+	/**
+	 * 상품의 정보고시 항목 목록
+	 *
+	 * @param notiInfo
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 18
+	 */
+	Collection<NotiInfo> getNotiGoodsInfoList(NotiInfo notiInfo);
+
+	/**
+	 * 상품 기본 정보 이력 생성
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	void createGoodsHst(Goods goods);
+
+	/**
+	 * 상품 자동 검색어 조회
+	 *
+	 * @param goodsCd
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 23
+	 */
+	String getGoodsSnm(String goodsCd);
+
+	/**
+	 * 상품검색어 수정
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 10. 23
+	 */
+	void updateGoodsSnm(Goods goods);
+
+	/**
+	 * 상품 기본 정보 수정
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	void updateGoods(Goods goods);
+
+	/**
+	 * 상품 상세정보 삭제
+	 *
+	 * @param godsDesc
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	void deleteGoodsDesc(GoodsDesc godsDesc);
+
+	/**
+	 * 상품 상세정보 등록
+	 *
+	 * @param godsDesc
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	void createGoodsDesc(GoodsDesc godsDesc);
+
+	/**
+	 * 상품 옵션/재고 정보 이력생성
+	 *
+	 * @param option
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	void createStockHst(Option option);
+
+	/**
+	 * 상품 옵션/재고 정보 수정
+	 *
+	 * @param stock
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	void saveStock(Option option);
+
+	/**
+	 * 상품 기본 정보 등록
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 10. 30
+	 */
+	void createGoods(Goods goods);
+
+	/**
+	 * 상품 품목변경 고시정보 삭제
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 10. 23
+	 */
+	void deleteGoodsNotiInfo(Goods goods);
+
+	/**
+	 * 상품 고시 정보 수정
+	 *
+	 * @param goodsNotiInfo
+	 * @author eskim
+	 * @since 2020. 10. 23
+	 */
+	void saveGoodsNotiInfo(GoodsNotiInfo goodsNotiInfo);
 }

+ 182 - 1
style24.scm/src/main/java/com/style24/scm/biz/dao/TssRendererDao.java

@@ -3,12 +3,15 @@ package com.style24.scm.biz.dao;
 import java.util.Collection;
 
 import com.style24.core.support.annotation.ShopDs;
+import com.style24.persistence.domain.Brand;
+import com.style24.persistence.domain.Color;
 import com.style24.persistence.domain.CommonCode;
+import com.style24.persistence.domain.Itemkind;
 import com.style24.persistence.domain.SupplyCompany;
 
 /**
  * 콤보박스, 체크박스, 라디오버튼 구성 시 필요한 Renderer Dao
- * 
+ *
  * @author gagamel
  * @since 2020. 10. 19
  */
@@ -33,4 +36,182 @@ public interface TssRendererDao {
 	 */
 	Collection<CommonCode> getCommonCodeList(CommonCode commoncode);
 
+	/**
+	 * 최상위메뉴 목록
+	 * @param pmenuId - 상위메뉴ID
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 10. 7
+	 */
+	Collection<CommonCode> getTopMenuList(String pmenuId);
+
+	/**
+	 * 전체 메뉴 목록
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 10. 7
+	 */
+	Collection<CommonCode> getAllMenuList();
+
+//	/**
+//	 * 벤더외부몰 목록
+//	 * @param vendorId - 벤더ID
+//	 * @return 벤더외부몰 목록
+//	 * @author gagamel
+//	 * @since 2019. 12. 6
+//	 */
+//	Collection<CommonCode> getVendorExtmallList(String vendorId);
+//
+//	/**
+//	 * 벤더외부몰판매매장 목록
+//	 * @param vendorId - 벤더ID
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 4. 28
+//	 */
+//	Collection<CommonCode> getVendorExtmallSellStoreList(String vendorId);
+//
+	/**
+	 * 브랜드 목록
+	 * @param brand --브랜드 정보
+	 * @return 브랜드 목록
+	 * @author eskim
+	 * @since 2020. 10. 20
+	 */
+	Collection<CommonCode> getBrandList(Brand brand);
+
+	/**
+	 * 권한별 브랜드 목록
+	 * @param userId - 사용자ID
+	 * @return
+	 * @author eskim
+	 * @since 2019. 6.17
+	 */
+	Collection<CommonCode> getAuthBrandList(int userNo);
+
+//	/**
+//	 * 정보고시 목록
+//	 * @param goodsCd
+//	 * @return
+//	 * @author jaewonHo
+//	 * @param goodsCd
+//	 * @since 2019. 12. 6
+//	 */
+//	Collection<CommonCode> getCateInfoList(String goodsCd);
+//
+	/**
+	 * 품목 목록
+	 * @param itemkind
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 19
+	 */
+	Collection<CommonCode> getItemkindList(Itemkind itemkind);
+
+//	/**
+//	 * 브랜드그룹 목록
+//	 * @return
+//	 * @author eskim
+//	 * @since 2019. 12. 10
+//	 */
+//	Collection<CommonCode> getBrandGroupList();
+//
+	/**
+	 * 컬러 목록
+	 * @param color
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 16
+	 */
+	Collection<CommonCode> getColorList(Color color);
+
+//
+//	/**
+//	 * 사용중 대카테고리 목록
+//	 * @param cateGb
+//	 * @return
+//	 * @author sasa004
+//	 * @since 2020. 01. 02
+//	 */
+//	Collection<CommonCode> getTCategoryList(String cateGb);
+//
+	/**
+	 * 브랜드에 등록된 MD 목록
+	 * @return MD 목록
+	 * @author eskim
+	 * @since 2020. 10. 19
+	 */
+	Collection<CommonCode> getBrandMdList();
+
+	/**
+	 * 택배사명 목록 조회
+	 * @return CommonCode
+	 * @author moon
+	 * @since 2020. 11. 05
+	 */
+	Collection<CommonCode> getShipCompanyList();
+//
+//	/**
+//	 * MD별 브랜드 목록 조회
+//	 * @param mdId
+//	 * @return CommonCode
+//	 * @author jaewonHo
+//	 * @since 2020. 02. 04
+//	 */
+//	Collection<CommonCode> getMdBrandList(String mdId);
+//
+//	/**
+//	 * MD별 브랜드 목록 조회
+//	 * @param mdId
+//	 * @return CommonCode
+//	 * @author jaewonHo
+//	 * @since 2020. 02. 04
+//	 */
+//	Collection<CommonCode> getMdBrandGrpList(String mdId);
+//
+//	/**
+//	 * 인스타그램 계정리스트 조회
+//	 * @return Collection<CommonCode>
+//	 * @author 이명철
+//	 * @since 2020. 3. 18.
+//	 */
+//	Collection<CommonCode> getInstaAccount();
+//
+//	/**
+//	 * 판매몰조회
+//	 * @return
+//	 * @author swkim
+//	 * @since 2020. 03. 19
+//	 */
+//	Collection<CommonCode> getSellStoreList();
+//
+//	/**
+//	 * 기본답변문구 제목 조회
+//	 * @param ansClsf
+//	 * @return
+//	 * @author yujung
+//	 * @since 2020. 04. 02
+//	 */
+//	Collection<CommonCode> getBasicAnsTitleList(String ansClsf);
+//
+//	/**
+//	 * 제휴링크 목록
+//	 * @param afChannel - 제휴채널
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 5. 4
+//	 */
+//	Collection<CommonCode> getAflinkList(String afChannel);
+
+	/**
+	 * 색상그룹코드 RGB 목록
+	 *
+	 * @param
+	 * @return 코드설명 목록
+	 * @author eskim
+	 * @since 2020. 10. 16
+	 */
+	Collection<CommonCode> getColorGrpCdRgbList();
+
+
 }

+ 317 - 0
style24.scm/src/main/java/com/style24/scm/biz/service/TssBusinessService.java

@@ -0,0 +1,317 @@
+package com.style24.scm.biz.service;
+
+import java.util.Collection;
+
+import org.apache.commons.lang3.StringUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import com.style24.core.support.message.TscMessageByLocale;
+import com.style24.persistence.domain.Brand;
+import com.style24.persistence.domain.SupplyCompany;
+import com.style24.scm.biz.dao.TssBusinessDao;
+
+import lombok.extern.slf4j.Slf4j;
+
+/**
+ * 영업관리 Service
+ *
+ * @author gagamel
+ * @since 2020. 10. 14
+ */
+@Service
+@Slf4j
+public class TssBusinessService {
+
+	@Autowired
+	private TscMessageByLocale message;
+
+	@Autowired
+	private TssBusinessDao businessDao;
+
+	/**
+	 * 공급업체 목록
+	 * @param supplyComp - 공급업체 정보
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 10. 14
+	 */
+	public Collection<SupplyCompany> getSupplyCompanyList(SupplyCompany supplyComp) {
+		return businessDao.getSupplyCompanyList(supplyComp);
+	}
+
+	/**
+	 * 공급업체 저장 처리
+	 * @param supplyComp - 공급업체 정보
+	 * @author gagamel
+	 * @since 2020. 10. 14
+	 */
+	public void saveSupplyCompany(SupplyCompany supplyComp) {
+		if (StringUtils.isNotBlank(supplyComp.getSupplyCompCd())) {
+			businessDao.updateSupplyCompany(supplyComp);
+		} else {
+			businessDao.createSupplyCompany(supplyComp);
+		}
+	}
+
+//	/**
+//	 * 출고처 목록
+//	 * @param delvLoc - 출고처 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 16
+//	 **/
+//	public Collection<DeliveryLoc> getDeliveryLocList(DeliveryLoc delvLoc) {
+//		return businessDao.getDeliveryLocList(delvLoc);
+//	}
+
+//	/**
+//	 * 출고처 저장
+//	 * @param delvLoc - 출고처 정보
+//	 * @author gagamel
+//	 * @since 2020. 10. 16
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void saveDeliveryLoc(DeliveryLoc delvLoc) {
+//		if (StringUtils.isEmpty(delvLoc.getUseYn())) {
+//			delvLoc.setUseYn("N");
+//		}
+//
+//		businessDao.saveDeliveryLoc(delvLoc);
+//	}
+
+	/**
+	 * 브랜드 목록
+	 * @param brand - 브랜드 정보
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	public Collection<Brand> getBrandList(Brand brand) {
+		return businessDao.getBrandList(brand);
+	}
+
+//	/**
+//	 * 담당MD 목록
+//	 * @param brandMd - 담당MD 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	public Collection<BrandMd> getMdList(BrandMd brandMd) {
+//		return businessDao.getMdList(brandMd);
+//	}
+
+//	/**
+//	 * 브랜드담당MD 목록
+//	 * @param brandCd - 브랜드코드
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	public Collection<BrandMd> getBrandMdList(String brandCd) {
+//		return businessDao.getBrandMdList(brandCd);
+//	}
+//
+//	/**
+//	 * 브랜드담당MD 목록 등록/수정 처리
+//	 * @param brandMdList - 브랜드담당MD 목록
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void saveBrandMdList(Collection<BrandMd> brandMdList) {
+//		businessDao.deleteBrandMd(brandMdList.iterator().next().getBrandCd());
+//
+//		for (BrandMd brandMd : brandMdList) {
+//			brandMd.setRegNo(TsaSession.getInfo().getUserNo());
+//			brandMd.setUpdNo(TsaSession.getInfo().getUserNo());
+//			businessDao.createBrandMd(brandMd);
+//		}
+//	}
+//
+//	/**
+//	 * 브랜드 노출사이트 목록
+//	 * @param brandCd - 브랜드코드
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	public Collection<SiteBrand> getBrandSiteList(String brandCd) {
+//		return businessDao.getBrandSiteList(brandCd);
+//	}
+//
+//	/**
+//	 * 브랜드 노출사이트 등록/수정 처리
+//	 * @param siteBrandList - 브랜드사이트 목록
+//	 * @author gagamel
+//	 * @since 2020. 11. 4
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void saveBrandSiteList(Collection<SiteBrand> siteBrandList) {
+//		for (SiteBrand siteBrand : siteBrandList) {
+//			siteBrand.setRegNo(TsaSession.getInfo().getUserNo());
+//			siteBrand.setUpdNo(TsaSession.getInfo().getUserNo());
+////			siteBrand.setTcateCd(businessDao.getTcateCdByBrand(siteBrand));
+//			businessDao.saveBrandSite(siteBrand);
+//		}
+//	}
+//
+//	/**
+//	 * 브랜드 등록/수정
+//	 * @param brand - 브랜드 정보
+//	 * @author gagamel
+//	 * @since 2020. 11. 5
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void saveBrand(Brand brand) {
+//		if (brand.getMode().equals("N")) { // 신규
+//			businessDao.createBrand(brand);
+//		} else { // 수정
+//			businessDao.updateBrand(brand);
+//		}
+//	}
+//
+//	/**
+//	 * 재고연계관리 - 출고처 목록
+//	 * @param delvLoc - 출고처 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 7
+//	 */
+//	public Collection<DeliveryLoc> getStockSyncDeliveryLocList(DeliveryLoc delvLoc) {
+//		return businessDao.getStockSyncDeliveryLocList(delvLoc);
+//	}
+//
+//	/**
+//	 * 재고연계관리 - 재고연계기준 목록
+//	 * @param stockSyncBase - 재고연계기준 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 11. 7
+//	 */
+//	public Collection<StockSyncBase> getStockSyncBaseList(StockSyncBase stockSyncBase) {
+//		return businessDao.getStockSyncBaseList(stockSyncBase);
+//	}
+//
+//	/**
+//	 * 재고연계관리 - 재고연계기준 저장
+//	 * @param stockSyncBase - 재고연계기준 정보
+//	 * @author gagamel
+//	 * @since 2020. 11. 7
+//	 */
+//	public void saveStockSyncBaseList(Collection<StockSyncBase> stockSyncBaseList) {
+//		for (StockSyncBase stockSyncBase : stockSyncBaseList) {
+//			stockSyncBase.setRegNo(TsaSession.getInfo().getUserNo());
+//			stockSyncBase.setUpdNo(TsaSession.getInfo().getUserNo());
+//			businessDao.saveStockSyncBase(stockSyncBase);
+//		}
+//	}
+//
+//	/**
+//	 * 판매매장 목록
+//	 * @param sellStore - 판매매장 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	public Collection<SellStore> getSellStoreList(SellStore sellStore) {
+//		return businessDao.getSellStoreList(sellStore);
+//	}
+//
+//	/**
+//	 * 판매매장 목록 저장 처리
+//	 * @param sellStoreList - 판매매장 목록
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void saveSellStoreList(Collection<SellStore> sellStoreList) {
+//		for (SellStore sellStore : sellStoreList) {
+//			sellStore.setRegNo(TsaSession.getInfo().getUserNo());
+//			sellStore.setUpdNo(TsaSession.getInfo().getUserNo());
+//			businessDao.saveSellStore(sellStore);
+//		}
+//	}
+//
+//	/**
+//	 * 제휴링크 목록
+//	 * @param aflink - 제휴링크 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	public Collection<Aflink> getAflinkList(Aflink aflink) {
+//		return businessDao.getAflinkList(aflink);
+//	}
+//
+//	/**
+//	 * 제휴링크 등록/수정
+//	 * @param aflink - 제휴링크 정보
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void saveAflink(Aflink aflink) {
+//		aflink.setRegNo(TsaSession.getInfo().getUserNo());
+//		aflink.setUpdNo(TsaSession.getInfo().getUserNo());
+//		businessDao.saveAflink(aflink);
+//	}
+//
+//	/**
+//	 * 제휴링크 목록 삭제 처리
+//	 * @param aflinkList - 제휴링크 목록
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void deleteAflinkList(Collection<Aflink> aflinkList) {
+//		for (Aflink aflink : aflinkList) {
+//			aflink.setUpdNo(TsaSession.getInfo().getUserNo());
+//			businessDao.deleteAflink(aflink);
+//		}
+//	}
+//
+//	/**
+//	 * 배송업체 목록
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	public Collection<ShipCompany> getShipCompanyList() {
+//		return businessDao.getShipCompanyList();
+//	}
+//
+//	/**
+//	 * 배송업체 목록 저장
+//	 * @param shipCompList - 배송업체 목록
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void saveShipCompanyList(Collection<ShipCompany> shipCompList) {
+//		for (ShipCompany shipComp : shipCompList) {
+//			shipComp.setRegNo(TsaSession.getInfo().getUserNo());
+//			shipComp.setUpdNo(TsaSession.getInfo().getUserNo());
+//			businessDao.saveShipCompany(shipComp);
+//		}
+//	}
+//
+//	/**
+//	 * 배송업체 목록 삭제
+//	 * @param shipCompList - 배송업체 목록
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 10. 20
+//	 */
+//	@Transactional("shopTxnManager")
+//	public void deleteShipCompanyList(Collection<ShipCompany> shipCompList) {
+//		for (ShipCompany shipComp : shipCompList) {
+//			shipComp.setUpdNo(TsaSession.getInfo().getUserNo());
+//			businessDao.deleteShipCompany(shipComp);
+//		}
+//	}
+
+}

+ 84 - 0
style24.scm/src/main/java/com/style24/scm/biz/service/TssCommonService.java

@@ -0,0 +1,84 @@
+package com.style24.scm.biz.service;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import com.style24.persistence.domain.SearchData;
+import com.style24.scm.biz.dao.TssCommonDao;
+
+import lombok.extern.slf4j.Slf4j;
+
+/**
+ * 공용 Service
+ *
+ * @author eskim
+ * @since 2020. 10. 20
+ */
+@Service
+@Slf4j
+public class TssCommonService {
+
+	@Autowired
+	private TssCommonDao commonDao;
+
+	/**
+	 * 엑셀조회를 위한 SEARCH 테이블 삭제
+	 *
+	 * @param searchData
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	public void deleteExceluploadSearCh(SearchData searchData) {
+		commonDao.deleteExceluploadSearCh(searchData);
+	}
+
+	/**
+	 * 엑셀조회를 위한 SEARCH 테이블 생성
+	 *
+	 * @param searchData
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	public void createExceluploadSearch(SearchData searchData) {
+		commonDao.createExceluploadSearch(searchData);
+	}
+
+	/**
+	 * 엑셀조회를 위한 SEARCH 테이블 생성 - dummy 컬럼 포함
+	 *
+	 * @param searchData
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	public void createExceluploadSearchByAll(SearchData searchData) {
+		commonDao.createExceluploadSearchByAll(searchData);
+	}
+
+	/**
+	 * 샘플파일 시스템파일명 조회
+	 * @param sampleFileId - 샘플파일ID
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 11. 3
+	 */
+	public String getSampleFileSystemFilename(String sampleFileId) {
+		return commonDao.getSampleFileSystemFilename(sampleFileId);
+	}
+
+	/**
+	 * ERP 연동 여부
+	 *
+	 * @param
+	 * @return
+	 * @author eskim
+	 * @since 2020. 01. 16
+	 */
+	public String getErpSyncYn() {
+		return commonDao.getErpSyncYn();
+	}
+
+
+}

+ 706 - 0
style24.scm/src/main/java/com/style24/scm/biz/service/TssGoodsService.java

@@ -1,13 +1,38 @@
 package com.style24.scm.biz.service;
 
+import java.io.IOException;
+import java.util.Collection;
+
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.core.env.Environment;
 import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+import org.springframework.util.StringUtils;
 
 import com.style24.core.support.message.TscMessageByLocale;
+import com.style24.persistence.domain.Brand;
+import com.style24.persistence.domain.Goods;
+import com.style24.persistence.domain.GoodsCompose;
+import com.style24.persistence.domain.GoodsDesc;
+import com.style24.persistence.domain.GoodsHst;
+import com.style24.persistence.domain.GoodsImg;
+import com.style24.persistence.domain.GoodsNotiInfo;
+import com.style24.persistence.domain.GoodsSearch;
+import com.style24.persistence.domain.NotiInfo;
+import com.style24.persistence.domain.Option;
+import com.style24.persistence.domain.SearchData;
 import com.style24.scm.biz.dao.TssGoodsDao;
+import com.style24.scm.support.env.TssConstants;
+import com.style24.scm.support.security.session.TssSession;
 
 import lombok.extern.slf4j.Slf4j;
 
+import com.gagaframework.excel.GagaExcelUtil;
+import com.gagaframework.excel.env.GagaExcelConstants;
+import com.gagaframework.web.parameter.GagaMap;
+import com.gagaframework.web.util.GagaFileUtil;
+import com.gagaframework.web.util.GagaStringUtil;
+
 /**
  *상품 Service
  *
@@ -21,7 +46,688 @@ public class TssGoodsService {
 	@Autowired
 	private TscMessageByLocale message;
 
+	@Autowired
+	private Environment env;
+
 	@Autowired
 	private TssGoodsDao goodsDao;
 
+	@Autowired
+	private TssCommonService commonService;
+
+	@Autowired
+	private TssBusinessService businessService;
+
+	/**
+	 * 상품 목록 건수
+	 *
+	 * @param goodsSearch
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 20
+	 */
+	public int getGoodsListCount(GoodsSearch goodsSearch) {
+		return goodsDao.getGoodsListCount(goodsSearch);
+	}
+
+	/**
+	 * 상품 목록
+	 *
+	 * @param goodsSearch
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 20
+	 */
+	public Collection<Goods> getGoodsList(GoodsSearch goodsSearch) {
+		return goodsDao.getGoodsList(goodsSearch);
+	}
+
+	/**
+	 * 상품목록 - 기본정보 엑셀다운로드
+	 *
+	 * @param goodsSearch
+	 * @param excelFilenameWithPath - 경로를 포함한 엑셀파일명
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 21
+	 */
+	public void getGoodsInfoExcelList(GoodsSearch goodsSearch, String excelFilenameWithPath) {
+
+		if ("Y".equals(goodsSearch.getImageViewYn())) {
+			// 헤더 title 설정
+			String[] listTitles = {"이미지", "상품코드", "업체명", "브랜드명", "상품명", "품목", "재고", "상품상태", "스타일년도", "시즌",
+				"정상가", "판매가", "할인율", "가격변경일", "ERP재고연동여부", "정상이월구분", "반품가능 여부","승인일시"};
+
+			// DB 처리 시 사용되는 파라미터명(셀명) 설정
+			String[] cellNames = {"IMG_PATH1", "GOODS_CD", "SUPPLY_COMP_CD", "BRAND_GRP_NM", "GOODS_NM", "ITEMKIND_NM",
+				"STOCK_QTY_SUM", "GOODS_STAT", "STYLE_YEAR", "SEASON_CD",  "LIST_PRICE", "CURR_PRICE",
+				"DC_RATE", "PRICE_UPD_DT", "ERP_STOCK_LINK_YN", "FORMAL_GB", "RETURNABLE_YN", "FRST_CFRM_DT"};
+
+			String[] cellTypes = {GagaExcelConstants.CellType.IMAGE.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_RIGHT.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_RIGHT.name(),
+				GagaExcelConstants.CellType.CHAR_RIGHT.name(), GagaExcelConstants.CellType.CHAR_RIGHT.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(),
+				GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name()};
+
+			String targetPath = env.getProperty("upload.goods.view");
+			Collection<GagaMap> dataList = goodsDao.getGoodsInfoExcelList(goodsSearch); // map형식으로 조회
+			if (dataList != null && !dataList.isEmpty()) {
+				for (GagaMap gagaMap : dataList) {
+					if ("A".equals(gagaMap.get("IMG_TYPE").toString())) {
+						gagaMap.set("IMG_PATH1", gagaMap.get("IMG_PATH1").toString());
+					} else {
+
+						if (!StringUtils.isEmpty(gagaMap.get("IMG_PATH6"))) {
+							gagaMap.set("IMG_PATH1", targetPath + gagaMap.get("IMG_PATH6").toString());
+
+						} else {
+							gagaMap.set("IMG_PATH1", targetPath + gagaMap.get("IMG_PATH1").toString());
+						}
+					}
+				}
+			}
+
+			try {
+				GagaExcelUtil.createExcel(excelFilenameWithPath, dataList, "상품 정보", listTitles, cellNames, cellTypes, TssConstants.EXCEL_FOOTER_TITLE);
+			} catch (Exception e) {
+				throw new IllegalStateException(e);
+			}
+
+		} else {
+			// 헤더 title 설정
+			String[] listTitles = {"상품코드", "업체명", "브랜드명", "상품명", "품목", "재고", "상품상태", "스타일년도",
+				"시즌",  "정상가", "판매가", "할인율", "가격변경일", "ERP재고연동여부", "정상이월구분", "반품가능 여부", "승인일시"};
+
+			// DB 처리 시 사용되는 파라미터명(셀명) 설정
+			String[] cellNames = {"GOODS_CD", "SUPPLY_COMP_CD", "BRAND_GRP_NM", "GOODS_NM", "ITEMKIND_NM", "STOCK_QTY_SUM", "GOODS_STAT", "STYLE_YEAR",
+				"SEASON_CD",  "LIST_PRICE", "CURR_PRICE", "DC_RATE", "PRICE_UPD_DT", "ERP_STOCK_LINK_YN", "FORMAL_GB", "RETURNABLE_YN", "FRST_CFRM_DT"};
+
+			String[] cellTypes = {
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_RIGHT.name(),
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_RIGHT.name(),
+			GagaExcelConstants.CellType.CHAR_RIGHT.name(), GagaExcelConstants.CellType.CHAR_RIGHT.name(),
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name(),
+			GagaExcelConstants.CellType.CHAR_CENTER.name(), GagaExcelConstants.CellType.CHAR_CENTER.name()};
+
+			Collection<GagaMap> dataList = goodsDao.getGoodsInfoExcelList(goodsSearch);
+
+			try {
+				GagaExcelUtil.createExcel(excelFilenameWithPath, dataList, "상품 정보", listTitles, cellNames, cellTypes, TssConstants.EXCEL_FOOTER_TITLE);
+			} catch (Exception e) {
+				throw new IllegalStateException(e);
+			}
+		}
+	}
+
+	/**
+	 * 상품 이미지 등록여부 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 21
+	 */
+	public Collection<Goods> getGoodsImgsYn(Goods goods) {
+		return goodsDao.getGoodsImgsYn(goods);
+	}
+
+	/**
+	 * 상품 상세
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	public Goods getGoods(Goods goods) {
+		// 상품기본정보
+		Goods resultGoods = goodsDao.getGoods(goods);
+
+		// 상품 상세
+		this.getGoodsDesc(resultGoods);
+		return resultGoods;
+	}
+
+	/**
+	 * 상품 상세 조회
+	 *
+	 * @param resultGoods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	private Goods getGoodsDesc(Goods resultGoods) {
+
+		GoodsDesc goods = new GoodsDesc();
+		goods.setGoodsCd(resultGoods.getGoodsCd());
+
+		//		goods.setDescGb("10");
+		//		String goodsDesc = this.getGoodsDescList(goods);
+		//		resultGoods.setGoodsDesc(goodsDesc);
+
+		// 상품 상세 pc 상단
+		goods.setDescGb("20");
+		String goodsPcTopDesc = this.getGoodsDescList(goods);
+		resultGoods.setGoodsPcTopDesc(goodsPcTopDesc);
+
+		// 상품 상세  pc 하단
+		goods.setDescGb("30");
+		String goodsPcDownDesc = this.getGoodsDescList(goods);
+		resultGoods.setGoodsPcDownDesc(goodsPcDownDesc);
+
+		// 상품 상세 mobile 상단
+		goods.setDescGb("40");
+		String goodsMobileTopDesc = this.getGoodsDescList(goods);
+		resultGoods.setGoodsMobileTopDesc(goodsMobileTopDesc);
+
+		// 상품 상세 mpbile 하단
+		goods.setDescGb("50");
+		String goodsMobileDownDesc = this.getGoodsDescList(goods);
+		resultGoods.setGoodsMobileDownDesc(goodsMobileDownDesc);
+
+		return resultGoods;
+	}
+
+	/**
+	 * 상품 상세구분별 컨텐츠 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	private String getGoodsDescList(GoodsDesc goodsDesc) {
+		Collection<GoodsDesc> goodsDescList = goodsDao.getGoodsDescList(goodsDesc);
+		StringBuilder goodsDescSb = new StringBuilder();
+		if (goodsDescList != null && !goodsDescList.isEmpty()) {
+			for (GoodsDesc tmpGoodsDesc : goodsDescList) {
+				goodsDescSb.append(tmpGoodsDesc.getGoodsDesc());
+			}
+		}
+		return goodsDescSb.toString();
+	}
+
+	/**
+	 * 상품 정보 이력 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2019. 12. 12
+	 */
+	public Collection<GoodsHst> getGoodsHstList(Goods goods) {
+		return goodsDao.getGoodsHstList(goods);
+	}
+
+	/**
+	 * 상품 옵션 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 26
+	 */
+	public Collection<Option> getGoodsSizeList(Goods goods) {
+		return goodsDao.getGoodsSizeList(goods);
+	}
+
+	/**
+	 * 상품 색상목록 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 11. 18
+	 */
+	public Collection<GoodsImg> getGoodsColorList(Goods goods) {
+		return goodsDao.getGoodsColorList(goods);
+	}
+
+	/**
+	 * 상품 정보고시 조회
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	public Collection<GoodsNotiInfo> getGoodsNotiInfoList(GoodsNotiInfo goodsNotiInfo) {
+		return goodsDao.getGoodsNotiInfoList(goodsNotiInfo);
+	}
+
+	/**
+	 * 상품의 정보고시 항목 목록
+	 *
+	 * @param notiInfo
+	 * @return
+	 * @author eskim
+	 * @since 2020. 11. 18
+	 */
+	public Collection<NotiInfo> getNotiGoodsInfoList(NotiInfo notiInfo) {
+		return goodsDao.getNotiGoodsInfoList(notiInfo);
+	}
+
+	/**
+	 * 엑셀조회용 상품 저장
+	 *
+	 * @param procJob : goodsExcelUpload
+	 * @param goodsList
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	@Transactional("shopTxnManager")
+	public void saveExceluploadGoods(Collection<Goods> goodsList, String excelFilename) {
+
+		String targetPath = GagaFileUtil.getConcatenationPath(env.getProperty("upload.excel.target.path"), "excel");
+		if (goodsList == null || goodsList.isEmpty()) {
+			this.deleteExceluploadFile(targetPath, excelFilename);
+			throw new IllegalStateException(message.getMessage("FAIL_1001"));
+		}
+
+		int index = 0;
+		String goodsCdFlag = "";
+		String goodsNumFlag = "";
+		for (Goods goods : goodsList) {
+
+			if (!StringUtils.isEmpty(goodsCdFlag) && !StringUtils.isEmpty(goodsNumFlag)) {
+				throw new IllegalStateException("상품코드와 원코드 중 한 개의 셀에만 값을 입력해서 조회하세요.");
+			}
+
+			if (!StringUtils.isEmpty(goods.getSupplyCompCd())) {
+				goods.setGoodsCd(goods.getSupplyCompCd());
+			}
+
+			SearchData searchData = new SearchData();
+			searchData.setRegNo(goods.getRegNo());
+			searchData.setSearchCd(goods.getGoodsCd());
+			if (index == 0) {
+				commonService.deleteExceluploadSearCh(searchData);
+			}
+
+			commonService.createExceluploadSearch(searchData);
+			index++;
+		}
+	}
+
+	/**
+	 * 파일 삭제
+	 *
+	 * @param targetPath
+	 * @param excelFilename
+	 * @author eskim
+	 * @since 2020. 10. 22
+	 */
+	private void deleteExceluploadFile(String targetPath, String excelFilename) {
+		// 파일 삭제
+		try {
+			GagaFileUtil.deleteFile(GagaFileUtil.getConcatenationPath(targetPath, excelFilename));
+		} catch (IOException e) {
+			// Nothing Do
+		}
+	}
+
+	/**
+	 * 상품 저장
+	 *
+	 * @param goods
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	@Transactional("shopTxnManager")
+	public void saveGoodsDetail(Goods goods) {
+
+		// <,> replace 처리
+		goods.setRegNo(TssSession.getInfo().getUserNo());
+		goods.setUpdNo(TssSession.getInfo().getUserNo());
+
+		goods.setGoodsPcTopDesc(GagaStringUtil.replace(GagaStringUtil.replace(goods.getGoodsPcTopDesc(), "&lt;", "<"), "&gt;", ">"));
+		goods.setGoodsMobileTopDesc(GagaStringUtil.replace(GagaStringUtil.replace(goods.getGoodsMobileTopDesc(), "&lt;", "<"), "&gt;", ">"));
+		goods.setGoodsPcDownDesc(GagaStringUtil.replace(GagaStringUtil.replace(goods.getGoodsPcDownDesc(), "&lt;", "<"), "&gt;", ">"));
+		goods.setGoodsMobileDownDesc(GagaStringUtil.replace(GagaStringUtil.replace(goods.getGoodsMobileDownDesc(), "&lt;", "<"), "&gt;", ">"));
+
+		goods.setGoodsNm(GagaStringUtil.replace(GagaStringUtil.replace(goods.getGoodsNm(), "&lt;", "<"), "&gt;", ">"));
+		goods.setGoodsTnm(GagaStringUtil.replace(GagaStringUtil.replace(goods.getGoodsTnm(), "&lt;", "<"), "&gt;", ">"));
+		goods.setGoodsSnm1(GagaStringUtil.replace(GagaStringUtil.replace(goods.getGoodsSnm1(), "&lt;", "<"), "&gt;", ">"));
+
+		// 세트일 경우 상품 가격 확인
+		if ("G056_S".equals(goods.getGoodsType())) {
+
+			Collection<GoodsCompose> goodsExtendList = goods.getGoodsComposeListNew();
+			int currPriceSum = 0;
+			for (GoodsCompose regGoodsExtend : goodsExtendList) {
+				currPriceSum  = currPriceSum + regGoodsExtend.getCompsCurrPrice();
+			}
+
+			if (currPriceSum != goods.getCurrPriceOrg()) {
+				goods.setCurrBprice(goods.getCurrPriceOrg());
+				goods.setCurrPrice(currPriceSum);
+				goods.setDcRate((int)(this.getDcRate(goods.getListPrice() , currPriceSum)));
+			}
+		}else {
+			// 가격변경일
+			if (goods.getCurrPrice() != goods.getCurrPriceOrg()) {
+				goods.setCurrBprice(goods.getCurrPriceOrg());
+			} else {
+				goods.setCurrPrice(goods.getCurrPriceOrg());
+			}
+		}
+
+		// 승인일
+		if (!goods.getGoodsStat().equals(goods.getGoodsStatOrg()) && "G008_90".equals(goods.getGoodsStat())) {
+			goods.setChGoodsStatYn("Y");
+		}
+		// 사용자 검색어를 검색어에 적용
+		String goodsSnm = goodsDao.getGoodsSnm(goods.getGoodsCd());
+		if (!StringUtils.isEmpty(goods.getGoodsSnm1())) {
+			goods.setGoodsSnm1(GagaStringUtil.replace(goods.getGoodsSnm1(), " ", "")); // 빈값 삭제
+			String[] arrGoodsSnm = goods.getGoodsSnm1().split(";");
+			StringBuilder tempGoodsSnm = new StringBuilder();
+			for (String loopGoodsSnm : arrGoodsSnm) {
+				if (goodsSnm.toUpperCase().indexOf(loopGoodsSnm.toUpperCase()) <= -1) {
+					tempGoodsSnm.append(loopGoodsSnm).append(";");
+				}
+			}
+			goods.setGoodsSnm(tempGoodsSnm.toString() + goodsSnm);
+
+		} else if (!goodsSnm.equals(goods.getGoodsSnm())) {
+			goods.setGoodsSnm(goodsSnm);
+		}
+
+		goods.setFormalGb(goods.getFormalGb());
+		// 브랜드 확인
+		if (!"G056_N".equals(goods.getGoodsType())) {
+			if (!goods.getFormalGb().equals(goods.getFormalGbOrg())) {
+				Brand brand = new Brand();
+				brand.setBrandCd(goods.getBrandCd());
+				Collection<Brand> brandList = businessService.getBrandList(brand);
+				if (brandList != null && !brandList.isEmpty()) {
+					float pntPrate = 0.0f;
+					float pntMrate = 0.0f;
+					for (Brand tmpBrand : brandList) {
+						if ("G009_10".equals(goods.getFormalGb())) {
+							pntPrate = tmpBrand.getPntPrate10();
+							pntMrate = tmpBrand.getPntMrate10();
+						} else {
+							pntPrate = tmpBrand.getPntPrate20();
+							pntMrate = tmpBrand.getPntMrate20();
+						}
+					}
+					goods.setPntPrate(pntPrate); // 포인트적립율(PC)
+					goods.setPntMrate(pntMrate); // 포인트적립율(MOBILE)
+				}
+			}
+		}
+
+		// 기본정보 변경
+		if ("Y".equals(goods.getChDataYn())) {
+			goodsDao.createGoodsHst(goods);
+			goodsDao.updateGoods(goods);
+		}
+
+		// 상품상세정보 변경
+		if (!"Y".equals(goods.getChkDescKeep())) {
+			this.saveGoodsDetailDesc(goods);
+		}
+
+//		int idx = 1;
+//		// 구성상품 변경
+//		if (!"G056_N".equals(goods.getGoodsType())) {
+//
+//			Collection<GoodsCompose> goodsExtendList = goods.getGoodsComposeListNew();
+//			for (GoodsCompose regGoodsExtend : goodsExtendList) {
+//				regGoodsExtend.setDispOrd(idx);
+//				regGoodsExtend.setRegNo(TssSession.getInfo().getUserNo());
+//				regGoodsExtend.setUpdNo(TssSession.getInfo().getUserNo());
+//				goodsDao.saveGoodsCompose(regGoodsExtend); // 구성상품기본 저장
+//
+//				idx++;
+//			}
+//		}
+
+		// 옵션/재고 변경
+		if (goods.getOptCd() != null && goods.getOptCd().length > 0 && "Y".equals(goods.getChStockDataYn())) {
+			this.saveStock(goods);
+		}
+
+		// 상품 정보고시 변경
+		this.saveGoodsNotiInfo(goods);
+
+	}
+
+	/**
+	 * 상품상세정보 변경 - 상품상세
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 10. 27.
+	 */
+	private void saveGoodsDetailDesc(Goods goods) {
+		// 상품상세 구분(10:상품설명, 20:상위컨텐츠, 30:하위컨텐츠, 40:하위컨텐츠-모바일, 50:상위컨텐츠-모바일)
+		GoodsDesc goodsDesc = new GoodsDesc();
+		goodsDesc.setGoodsCd(goods.getGoodsCd());
+		goodsDesc.setRegNo(goods.getRegNo());
+		goodsDesc.setUpdNo(goods.getUpdNo());
+
+		// PC 상단
+		goodsDesc.setDescGb("10");
+		goodsDesc.setGoodsDesc(goods.getGoodsPcTopDesc());
+		this.saveGoodsDesc(goodsDesc);
+
+		// PC 하단
+		goodsDesc.setDescGb("20");
+		goodsDesc.setGoodsDesc(goods.getGoodsPcTopDesc());
+		this.saveGoodsDesc(goodsDesc);
+
+		// 공용 하단
+		goodsDesc.setDescGb("30");
+		goodsDesc.setGoodsDesc(goods.getGoodsPcDownDesc());
+		this.saveGoodsDesc(goodsDesc);
+
+		// MO 상단
+		goodsDesc.setDescGb("40");
+		goodsDesc.setGoodsDesc(goods.getGoodsMobileTopDesc());
+		this.saveGoodsDesc(goodsDesc);
+
+		//		// 상품상세 저장
+
+		//
+		//		// 세트상품의 구서상품으로 있을경우 처리
+		//		this.saveGoodsSetDesc(goodsDesc);
+
+		// MO 하단
+		goodsDesc.setDescGb("50");
+		goodsDesc.setGoodsDesc(goods.getGoodsMobileDownDesc());
+		this.saveGoodsDesc(goodsDesc);
+	}
+
+	/**
+	 * 상품 상세 저장
+	 *
+	 * @param goodsDesc
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	private void saveGoodsDesc(GoodsDesc goodsDesc) {
+
+		goodsDao.deleteGoodsDesc(goodsDesc);
+
+		String[] arrProdHtml = null;
+		arrProdHtml = makeArrayToString(goodsDesc.getGoodsDesc(), 3900);
+		if (arrProdHtml.length > 0) {
+			for (int i = 0; i < arrProdHtml.length; i++) {
+				if (!arrProdHtml[i].isEmpty()) {
+					goodsDesc.setSeq(i + 1);
+					goodsDesc.setGoodsDesc(arrProdHtml[i]);
+					goodsDao.createGoodsDesc(goodsDesc);
+				}
+			}
+		}
+	}
+
+	/**
+	 * String => byte array
+	 *
+	 * @param raw
+	 * @param len
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	public static String[] makeArrayToString(String raw, int len) {
+
+		String[] ary = null;
+
+		if (raw == null) {
+			return ary;
+		}
+
+		try {
+
+			// raw 의 byte
+			byte[] rawBytes = raw.getBytes("UTF-8"); // MS949
+			int rawLength = rawBytes.length;
+
+			if (rawLength > len) {
+				int aryLength = (rawLength / len) + (rawLength % len != 0 ? 1 : 0);
+				ary = new String[aryLength];
+
+				int endCharIndex = 0; // 문자열이 끝나는 위치
+				String tmp;
+				for (int i = 0; i < aryLength; i++) {
+
+					if (i == (aryLength - 1)) {
+						tmp = raw.substring(endCharIndex);
+					} else {
+
+						int useByteLength = 0;
+						int rSize = 0;
+						for (; endCharIndex < raw.length(); endCharIndex++) {
+
+							if (raw.charAt(endCharIndex) > 0x007F) {
+								useByteLength += 3;
+							} else {
+								useByteLength++;
+							}
+							if (useByteLength > len) {
+								break;
+							}
+							rSize++;
+						}
+						tmp = raw.substring((endCharIndex - rSize), endCharIndex);
+					}
+
+					ary[i] = tmp;
+				}
+
+			} else {
+				ary = new String[] {raw};
+			}
+
+		} catch (java.io.UnsupportedEncodingException e) {
+		}
+
+		return ary;
+	}
+
+	/**
+	 * 옵션/재고 변경 - 상품상세
+	 *
+	 * @param goods
+	 * @param index
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	private void saveStock(Goods goods) {
+		int index = 0;
+		Option stock = new Option();
+		stock.setGoodsCd(goods.getGoodsCd());
+		stock.setUpdNo(goods.getUpdNo());
+		stock.setRegNo(goods.getRegNo());
+		goodsDao.createStockHst(stock);
+		log.info("saveStock goods={}", goods);
+		for (String optCd : goods.getOptCd()) {
+			log.info("saveStock index={}", index);
+			log.info("saveStock optCd={}", optCd);
+			Option goodsStock = new Option();
+			goodsStock.setGoodsCd(goods.getCompsGoodsCd()[index]); // 구성상품 코드
+			goodsStock.setOptCd(optCd);
+			goodsStock.setOptCd1(goods.getOptCd1()[index]);
+			goodsStock.setOptCd2(goods.getOptCd2()[index]);
+			goodsStock.setBaseStockQty(Integer.parseInt(goods.getBaseStockQty()[index]));
+			goodsStock.setSoldoutYn(goods.getSoldoutYn()[index]);
+			goodsStock.setDispOrd(goods.getDispOrd()[index]);
+			goodsStock.setDispYn(goods.getDispYn()[index]);
+			goodsStock.setRegNo(goods.getRegNo());
+			goodsStock.setUpdNo(goods.getUpdNo());
+
+			if ("N".equals(goods.getSelfGoodsYn())) {
+				goodsStock.setSelfGoodsYn(goods.getSelfGoodsYn());
+				goodsStock.setCurrStockQty(Integer.parseInt(goods.getEditCurrStockQty()[index]));
+			}
+			goodsDao.saveStock(goodsStock);
+			index++;
+		}
+	}
+
+
+	/**
+	 * 상품 사이즈 옵션정보 이력 생성
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 11. 17
+	 */
+	@Transactional("shopTxnManager")
+	public void createStockHst(Option option) {
+		goodsDao.createStockHst(option);
+	}
+
+	/**
+	 * 상품 정보고시 변경 - 상품상세
+	 *
+	 * @param goods
+	 * @author eskim
+	 * @since 2020. 10. 27
+	 */
+	private void saveGoodsNotiInfo(Goods goods) {
+		int index;
+		if (goods.getNotiListNew() != null && !goods.getNotiListNew().isEmpty()) {
+			index = 0;
+			for (GoodsNotiInfo goodsNotiInfo : goods.getNotiListNew()) {
+				if (index == 0) {
+					goodsDao.deleteGoodsNotiInfo(goods);
+				}
+				goodsNotiInfo.setNiContent(GagaStringUtil.replace(GagaStringUtil.replace(goodsNotiInfo.getNiContent(), "&lt;", "<"), "&gt;", ">"));
+				goodsNotiInfo.setRegNo(goods.getRegNo());
+				goodsNotiInfo.setUpdNo(goods.getUpdNo());
+				goodsDao.saveGoodsNotiInfo(goodsNotiInfo);
+				index++;
+			}
+		}
+	}
+
+	/**
+	 * 상품 할인율 계산
+	 *
+	 * @param value
+	 * @param len
+	 * @param pad
+	 * @return
+	 */
+	private long getDcRate(int listPrice, int currPrice) {
+		double rate = (double)(currPrice) / (double)(listPrice);
+		return 100 - (long)((Math.round(rate * 100) / 100.0) * 100);
+	}
 }

+ 304 - 0
style24.scm/src/main/java/com/style24/scm/biz/service/TssRendererService.java

@@ -1,11 +1,15 @@
 package com.style24.scm.biz.service;
 
+import java.util.ArrayList;
 import java.util.Collection;
 
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
+import com.style24.persistence.domain.Brand;
+import com.style24.persistence.domain.Color;
 import com.style24.persistence.domain.CommonCode;
+import com.style24.persistence.domain.Itemkind;
 import com.style24.persistence.domain.SupplyCompany;
 import com.style24.scm.biz.dao.TssRendererDao;
 
@@ -24,6 +28,33 @@ public class TssRendererService {
 	@Autowired
 	private TssRendererDao rendererDao;
 
+	/**
+	 * 연도 목록
+	 * @param startYear - 시작연도
+	 * @param startOffset - Start offset. 시작연도
+	 * @param endOffset - End offset. 종료연도
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 10. 22.
+	 */
+	public Collection<CommonCode> getYearList(int startYear, int startOffset, int endOffset) {
+		Collection<CommonCode> yearList = new ArrayList<>();
+
+		int start = startYear + startOffset;
+		int end = startYear + endOffset;
+
+		for (int year = start; year <= end; year++) {
+			CommonCode commonCode = new CommonCode();
+
+			commonCode.setCd(String.valueOf(year));
+			commonCode.setCdNm(String.valueOf(year));
+
+			yearList.add(commonCode);
+		}
+
+		return yearList;
+	}
+
 	/**
 	 * 공급업체 목록
 	 * @param supplyCompany - 공급업체 정보
@@ -85,6 +116,18 @@ public class TssRendererService {
 		return this.getSupplyCompanyList(supplyCompany);
 	}
 
+	/**
+	 * 입점공급업체 목록
+	 * @return 입점공급업체 목록
+	 * @author gagamel
+	 * @since 2020. 11. 4
+	 */
+	public Collection<CommonCode> getEntrSupplyCompanyList() {
+		SupplyCompany supplyCompany = new SupplyCompany();
+		supplyCompany.setSelfYn("N");
+		return this.getSupplyCompanyList(supplyCompany);
+	}
+
 	/**
 	 * 공통코드 목록 - 어드민 공통코드 캐시 미적용 - 상품등록시 시즌년도 캐쉬로 인한 정보 오류로 수정 2020.06.02
 	 * @param commoncode - 공통코드 정보
@@ -170,4 +213,265 @@ public class TssRendererService {
 		return this.getCommonCodeList(commoncode);
 	}
 
+	/**
+	 * 최상위메뉴 목록
+	 * @param menuId - 메뉴ID
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 10. 7
+	 */
+	public Collection<CommonCode> getTopMenuList(String menuId) {
+		return rendererDao.getTopMenuList(menuId);
+	}
+
+	/**
+	 * 전체 메뉴 목록
+	 * @return
+	 * @author gagamel
+	 * @since 2020. 10. 7
+	 */
+	public Collection<CommonCode> getAllMenuList() {
+		return rendererDao.getAllMenuList();
+	}
+
+//	/**
+//	 * 벤더외부몰 목록
+//	 * @param vendorId - 벤더ID
+//	 * @return 벤더외부몰 목록
+//	 * @author gagamel
+//	 * @since 2019. 8. 11
+//	 */
+//	public Collection<CommonCode> getVendorExtmallList(String vendorId) {
+//		return rendererDao.getVendorExtmallList(vendorId);
+//	}
+//
+//	/**
+//	 * 벤더외부몰판매매장 목록
+//	 * @param vendorId - 벤더ID
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 4. 28
+//	 */
+//	public Collection<CommonCode> getVendorExtmallSellStoreList(String vendorId) {
+//		return rendererDao.getVendorExtmallSellStoreList(vendorId);
+//	}
+//
+//	//
+//	//	/**
+//	//	 * 유효한 브랜드 목록
+//	//	 * @param
+//	//	 * @return
+//	//	 * @author qkwlstktma
+//	//	 * @since 2019. 8. 25
+//	//	 */
+//	//	public Collection<CommonCode> getAvailableBrandList() {
+//	//		AdmBrand brand = new AdmBrand();
+//	//		brand.setUseYn("Y");
+//	//		return rendererDao.getBrandList(brand);
+//	//	}
+//	//
+	/**
+	 * 공급업체 브랜드 목록
+	 * @param supplyCompCd - 공급업체코드
+	 * @return
+	 * @author gagamel
+	 * @since 2019. 10. 20
+	 */
+	public Collection<CommonCode> getSupplyCompanyBrandList(String supplyCompCd) {
+		Brand brand = new Brand();
+		brand.setSupplyCompCd(supplyCompCd);
+		return rendererDao.getBrandList(brand);
+	}
+
+//
+//	/**
+//	 * 브랜드그룹별 브랜드 목록
+//	 * @param brandGrpNm - 브랜드그룹명
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 1. 10
+//	 */
+//	public Collection<CommonCode> getGroupBrandList(String brandGrpNm) {
+//		AdmBrand brand = new AdmBrand();
+//		brand.setBrandGrpNm(brandGrpNm);
+//		return rendererDao.getBrandList(brand);
+//	}
+//
+	/**
+	 * 권한별 브랜드 목록
+	 * @param adminId - 사용자ID
+	 * @return
+	 * @author eskim
+	 * @since 2019. 6. 17
+	 */
+	public Collection<CommonCode> getAuthBrandList(int userNo) {
+		return rendererDao.getAuthBrandList(userNo);
+	}
+
+
+//
+//	//	/**
+//	//	 * 정보고시 목록
+//	//	 * @param goodsCd - 상품코드
+//	//	 * @return
+//	//	 * @author jaewonHo
+//	//	 * @param supplyCompCd
+//	//	 * @since 2019. 10. 24
+//	//	 */
+//	//	public Collection<CommonCode> getCateInfoList(String goodsCd) {
+//	//		return rendererDao.getCateInfoList(goodsCd);
+//	//	}
+//
+	/**
+	 * 품목 목록
+	 * @return 품목 목록
+	 * @author eskim
+	 * @since 2020. 10. 19
+	 */
+	public Collection<CommonCode> getAllItemkindList() {
+		Itemkind itemkind = new Itemkind();
+		return this.getItemkindList(itemkind);
+	}
+
+	/**
+	 * 품목 목록
+	 * @param itemkind - 품목 정보
+	 * @return 품목 목록
+	 * @author eskim
+	 * @since 2020. 10. 19
+	 */
+	public Collection<CommonCode> getItemkindList(Itemkind itemkind) {
+		return rendererDao.getItemkindList(itemkind);
+	}
+
+//	/**
+//	 * 브랜드그룹 목록
+//	 * @return 브랜드그룹 목록
+//	 * @author eskim
+//	 * @since 2019. 12. 10
+//	 */
+//	public Collection<CommonCode> getBrandGroupList() {
+//		return rendererDao.getBrandGroupList();
+//	}
+//
+	/**
+	 * 컬러 목록
+	 * @param color - 색상 정보
+	 * @return 컬러 목록
+	 * @author eskim
+	 * @since 2020. 10. 16
+	 */
+	public Collection<CommonCode> getColorList(Color color) {
+		return rendererDao.getColorList(color);
+	}
+
+//
+//	/**
+//	 * 사용중 대카테고리 목록
+//	 * @param cateGb - 카테고리구분
+//	 * @return 대카테고리 목록
+//	 * @author sasa004
+//	 * @since 2020. 01. 02
+//	 */
+//	public Collection<CommonCode> getTCategoryList(String cateGb) {
+//		return rendererDao.getTCategoryList(cateGb);
+//	}
+//
+	/**
+	 * 브랜드에 등록된 MD 목록
+	 * @return MD 목록
+	 * @author eskim
+	 * @since 2020. 10. 19
+	 */
+	public Collection<CommonCode> getBrandMdList() {
+		return rendererDao.getBrandMdList();
+	}
+
+	/**
+	 * 택배사명 목록 조회
+	 * @return CommonCode
+	 * @author moon
+	 * @since 2020. 11. 05
+	 */
+	public Collection<CommonCode> getShipCompanyList() {
+		return rendererDao.getShipCompanyList();
+	}
+//
+//	/**
+//	 * MD 별 브랜드 목록 조회
+//	 * @param mdId - 담당MD아이디
+//	 * @return CommonCode
+//	 * @author jaewonHo
+//	 * @since 2020. 02. 11
+//	 */
+//	public Collection<CommonCode> getMdBrandList(String mdId) {
+//		return rendererDao.getMdBrandList(mdId);
+//	}
+//
+//	/**
+//	 * MD 별 브랜드 목록 조회
+//	 * @param mdId - 담당MD아이디
+//	 * @return CommonCode
+//	 * @author jaewonHo
+//	 * @since 2020. 02. 11
+//	 */
+//	public Collection<CommonCode> getMdBrandGrpList(String mdId) {
+//		return rendererDao.getMdBrandGrpList(mdId);
+//	}
+//
+//	/**
+//	 * 인스타그램 계정리스트 조회
+//	 * @return
+//	 * @since : 2020. 3. 18.
+//	 * @authur 이명철
+//	 */
+//	public Collection<CommonCode> getInstaAccount() {
+//		return rendererDao.getInstaAccount();
+//	}
+//
+//	/**
+//	 * 판매몰조회
+//	 * @param
+//	 * @return CommonCode
+//	 * @author swkim
+//	 * @since 2020. 03. 19
+//	 */
+//	public Collection<CommonCode> getSellStoreList() {
+//		return rendererDao.getSellStoreList();
+//	}
+//
+//	/**
+//	 * 기본답변문구 제목 조회
+//	 * @param
+//	 * @return CommonCode
+//	 * @author yujing
+//	 * @since 2020. 04. 02
+//	 */
+//	public Collection<CommonCode> getBasicAnsTitleList(String ansClsf) {
+//		return rendererDao.getBasicAnsTitleList(ansClsf);
+//	}
+//
+//	/**
+//	 * 제휴링크 목록
+//	 * @param afChannel - 제휴채널
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 5. 4
+//	 */
+//	public Collection<CommonCode> getAflinkList(String afChannel) {
+//		return rendererDao.getAflinkList(afChannel);
+//	}
+
+	/**
+	 * 색상그룹코드 RGB 목록
+	 *
+	 * @param
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 16
+	 */
+	public Collection<CommonCode> getColorGrpCdRgbList() {
+		return rendererDao.getColorGrpCdRgbList();
+	}
+
 }

+ 144 - 0
style24.scm/src/main/java/com/style24/scm/biz/web/TssGoodsController.java

@@ -1,16 +1,34 @@
 package com.style24.scm.biz.web;
 
+import javax.servlet.http.HttpServletRequest;
+
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.core.env.Environment;
+import org.springframework.core.io.InputStreamResource;
+import org.springframework.http.ResponseEntity;
 import org.springframework.stereotype.Controller;
+import org.springframework.util.StringUtils;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.ResponseBody;
+import org.springframework.web.servlet.ModelAndView;
 
 import com.style24.core.support.message.TscMessageByLocale;
+import com.style24.persistence.TssPageRequest;
+import com.style24.persistence.domain.GoodsSearch;
 import com.style24.scm.biz.service.TssGoodsService;
 import com.style24.scm.biz.service.TssRendererService;
 import com.style24.scm.support.controller.TssBaseController;
+import com.style24.scm.support.security.session.TssSession;
 
 import lombok.extern.slf4j.Slf4j;
 
+import com.gagaframework.web.parameter.GagaMap;
+import com.gagaframework.web.util.GagaDateUtil;
+import com.gagaframework.web.util.GagaFileUtil;
+
 /**
  * 상품관리 Controller
  *
@@ -25,10 +43,136 @@ public class TssGoodsController extends TssBaseController {
 	@Autowired
 	private TscMessageByLocale message;
 
+	@Autowired
+	private Environment env;
+
 	@Autowired
 	private TssGoodsService goodsService;
 
 	@Autowired
 	private TssRendererService rendererService;
 
+	/**
+	 * 상품목록 화면
+	 *
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 16
+	 */
+	@GetMapping("/list/form")
+	public ModelAndView listForm() {
+		ModelAndView mav = new ModelAndView();
+
+		// 공급업체
+		String supplyCompCd = "";
+		String selfYn = "Y";
+		if ("G001_B000".equals(TssSession.getInfo().getRoleCd())) {
+			supplyCompCd = TssSession.getInfo().getSupplyCompCd();
+			selfYn = "N";
+		}
+		mav.addObject("supplyCompList", rendererService.getSupplyCompanyList(supplyCompCd, selfYn));
+		// 상품상태
+		String[] exceptCds = {"G008_00"};
+		mav.addObject("goodsStatList", rendererService.getCommonCodeList("G008", "Y", exceptCds));
+		// 정상이월
+		mav.addObject("formalGbList", rendererService.getAvailCommonCodeList("G009"));
+		// 성별
+		mav.addObject("sexGbList", rendererService.getAvailCommonCodeList("G007"));
+		// 시즌
+		mav.addObject("seasonList", rendererService.getAvailCommonCodeList("G006"));
+		// 년도
+		int toYear = Integer.parseInt(GagaDateUtil.getToday("yyyy")) - 4;
+		mav.addObject("styleYearList", rendererService.getYearList(toYear,0,5));
+		// 연령대
+		mav.addObject("ageGrpCdList", rendererService.getAvailCommonCodeList("G023"));
+		// 사용여부
+		mav.addObject("useYnList", rendererService.getAvailCommonCodeList("G002"));
+		// 품목
+		mav.addObject("itemkindList", rendererService.getAllItemkindList());
+		// 상품유형
+		mav.addObject("goodsTypeList", rendererService.getAvailCommonCodeList("G056"));
+		// MD
+		mav.addObject("brandMdList", rendererService.getBrandMdList());
+
+		mav.setViewName("goods/GoodsListForm");
+
+		return mav;
+	}
+
+	/**
+	 * 상품목록 조회
+	 *
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 20
+	 */
+	@PostMapping("/list")
+	@ResponseBody
+	public GagaMap getGoodsList(@RequestBody GoodsSearch goodsSearch) {
+
+		GagaMap result = new GagaMap();
+
+		// 입점업체담당자는 업체코드 설정
+		if ("G001_B000".equals(TssSession.getInfo().getRoleCd())) {
+			goodsSearch.setSupplyCompCd(TssSession.getInfo().getSupplyCompCd());
+			goodsSearch.setMdNo(TssSession.getInfo().getUserNo().toString());
+		}
+
+		// multi row 검색관련 처리
+		if (!StringUtils.isEmpty(goodsSearch.getCondition())) {
+			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").split("\n"));
+
+			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
+				goodsSearch.setSearchGb("EXTEND");
+			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
+				goodsSearch.setSearchGb("MASTER");
+			}
+		}
+
+		goodsSearch.setRegNo(TssSession.getInfo().getUserNo()); // 엑셀조회시 로그인 사용자의 엑셀 상품조회시 사용
+		goodsSearch.setPageable(new TssPageRequest(goodsSearch.getPageNo() - 1, goodsSearch.getPageSize()));
+		goodsSearch.getPageable().setTotalCount(goodsService.getGoodsListCount(goodsSearch));
+
+		result.set("pageing", goodsSearch);
+		result.set("goodsList", goodsService.getGoodsList(goodsSearch));
+
+		return result;
+	}
+
+	/**
+	 * 상품목록 - 기본정보 엑셀다운로드
+	 *
+	 * @param goodsSearch
+	 * @return
+	 * @author eskim
+	 * @since 2020. 10. 21
+	 */
+	@GetMapping("/info/excel/list")
+	public ResponseEntity<InputStreamResource> downloadGoodsInfoExcelList(HttpServletRequest request, GoodsSearch goodsSearch) throws Exception {
+		String excelfileName = "상품_기본정보_" + GagaDateUtil.getTodayDateTime() + ".xlsx";
+		String excelFilenameWithPath = GagaFileUtil.getConcatenationPath(env.getProperty("download.path"), "excel", excelfileName);
+
+		// 입점업체담당자는 업체코드 설정
+		if ("G001_B000".equals(TssSession.getInfo().getRoleCd())) {
+			goodsSearch.setSupplyCompCd(TssSession.getInfo().getSupplyCompCd());
+			goodsSearch.setMdNo(TssSession.getInfo().getUserNo().toString());
+		}
+		goodsSearch.setRegNo(TssSession.getInfo().getUserNo()); // 엑셀조회시 로그인 사용자의 엑셀 상품조회시 사용
+
+		// multi row 검색관련 처리
+		if (!StringUtils.isEmpty(goodsSearch.getCondition())) {
+			goodsSearch.setConditionList(goodsSearch.getCondition().replaceAll("\r", "").split("\n"));
+
+			if ("searchExtendGoodsCd".equals(goodsSearch.getSearch())) {
+				goodsSearch.setSearchGb("EXTEND");
+			} else if ("searchMasterGoodsCd".equals(goodsSearch.getSearch())) {
+				goodsSearch.setSearchGb("MASTER");
+			}
+		}
+
+		// 대용량엑셀파일다운로드는 이런 식으로 ...
+		goodsService.getGoodsInfoExcelList(goodsSearch, excelFilenameWithPath);
+
+		return GagaFileUtil.writeFile(request, excelFilenameWithPath);
+	}
 }

+ 192 - 0
style24.scm/src/main/java/com/style24/scm/biz/web/TssRendererController.java

@@ -0,0 +1,192 @@
+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.PathVariable;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.ResponseBody;
+
+import com.style24.persistence.domain.Color;
+import com.style24.persistence.domain.CommonCode;
+import com.style24.scm.biz.service.TssRendererService;
+import com.style24.scm.support.controller.TssBaseController;
+
+import lombok.extern.slf4j.Slf4j;
+
+/**
+ * 콤보박스, 체크박스, 라디오버튼 구성 시 필요한 Renderer Controller
+ *
+ * @author renderer
+ * @since 2020. 10. 20
+ */
+@Controller
+@RequestMapping("/renderer")
+@Slf4j
+public class TssRendererController extends TssBaseController {
+
+	@Autowired
+	private TssRendererService rendererService;
+
+	/**
+	 * 공급업체 목록
+	 * @param brandGb - 브랜드구분(S:자사브랜드, E:입점브랜드)
+	 * @return
+	 * @author gagamel
+	 * @since 2019. 11. 4
+	 */
+	@GetMapping("/supply/company/list/{brandGb}")
+	@ResponseBody
+	public Collection<CommonCode> getSupplyCompanyList(@PathVariable String brandGb) {
+		return brandGb.equals("S") ? rendererService.getSelfSupplyCompanyList() : rendererService.getEntrSupplyCompanyList();
+	}
+
+	/**
+	 * 입점업체브랜드 목록
+	 * @param supplyCompCd - 입점업체관리일련번호
+	 * @return
+	 * @author gagamel
+	 * @since 2019. 6. 7
+	 */
+	@GetMapping("/supplyCompany/brand/list/{supplyCompCd}")
+	@ResponseBody
+	public Collection<CommonCode> getSupplyCompanyBrandList(@PathVariable String supplyCompCd) {
+		return rendererService.getSupplyCompanyBrandList(supplyCompCd);
+	}
+
+//
+//	/**
+//	 * 브랜드그룹별 브랜드 목록
+//	 * @param brandGrpNm - 브랜드그룹명
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 1. 10
+//	 */
+//	@GetMapping("/group/brand/list/{brandGrpNm}")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getGroupBrandList(@PathVariable String brandGrpNm) {
+//		return rendererService.getGroupBrandList(brandGrpNm);
+//	}
+//
+//	/**
+//	 * 권한별 브랜드 목록
+//	 * @return
+//	 * @author eskim
+//	 * @since 2019. 6.17
+//	 */
+//	@GetMapping("/brand/AuthBrandlist")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getAuthBrandList() {
+//		return rendererService.getAuthBrandList(AdmSession.getInfo().getUserId());
+//	}
+
+
+
+//	/**
+//	 * 벤더외부몰 목록
+//	 * @param vendorId - 벤더ID
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2019. 8. 11
+//	 */
+//	@GetMapping("/vendor/extmall/list/{vendorId}")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getVendorExtmallList(@PathVariable String vendorId) {
+//		return rendererService.getVendorExtmallList(vendorId);
+//	}
+//
+//	/**
+//	 * 벤더외부몰판매매장 목록
+//	 * @param vendorId - 벤더ID
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 4. 28
+//	 */
+//	@GetMapping("/vendor/extmall/sellStore/list/{vendorId}")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getVendorExtmallSellStoreList(@PathVariable String vendorId) {
+//		return rendererService.getVendorExtmallSellStoreList(vendorId);
+//	}
+//
+//	/**
+//	 * 현재 유효한 공통코드 목록
+//	 * @param cdGb - 공통그룹코드
+//	 * @return
+//	 * @author eskim
+//	 * @since 2020. 01. 22
+//	 */
+//	@GetMapping("/avail/commonCode/list/{cdGb}")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getAvailCommonCodeList(@PathVariable String cdGb) {
+//		return rendererService.getAvailCommonCodeList(cdGb);
+//	}
+//
+	/**
+	 * 업체별 색상 목록
+	 * @param cdGb - 공통그룹코드
+	 * @return
+	 * @author eskim
+	 * @since 2020. 01. 22
+	 */
+	@GetMapping("/avail/color/list")
+	@ResponseBody
+	public Collection<CommonCode> getColorList() {
+		Color color = new Color();
+		return rendererService.getColorList(color);
+	}
+//
+//	/**
+//	 * MD별 브랜드 목록
+//	 * @param mdId - 엠디아이디
+//	 * @return
+//	 * @author jaewonho
+//	 * @since 2020. 02. 11
+//	 */
+//	@GetMapping("/md/brand/list/{mdId}")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getMdBrandList(@PathVariable String mdId) {
+//		return rendererService.getMdBrandList(mdId);
+//	}
+//
+//	/**
+//	 * MD별 브랜드그룹 목록
+//	 * @param mdId - 엠디아이디
+//	 * @return
+//	 * @author jaewonho
+//	 * @since 2020. 02. 11
+//	 */
+//	@GetMapping("/md/brand/grp/list/{mdId}")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getMdBrandGrpList(@PathVariable String mdId) {
+//		return rendererService.getMdBrandGrpList(mdId);
+//	}
+//
+//	/**
+//	 * 판매몰 목록
+//	 * @param
+//	 * @return
+//	 * @author swkim
+//	 * @since 2020. 03. 19
+//	 */
+//	@GetMapping("/sellStore/list")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getSellStoreList() {
+//		return rendererService.getSellStoreList();
+//	}
+//
+//	/**
+//	 * 제휴링크 목록
+//	 * @param afChannel - 제휴채널
+//	 * @return
+//	 * @author gagamel
+//	 * @since 2020. 5. 4
+//	 */
+//	@GetMapping("/aflink/list/{afChannel}")
+//	@ResponseBody
+//	public Collection<AdmCommonCode> getAflinkList(@PathVariable String afChannel) {
+//		return rendererService.getAflinkList(afChannel);
+//	}
+
+}

+ 4 - 2
style24.scm/src/main/java/com/style24/scm/support/env/TssConstants.java

@@ -2,13 +2,15 @@ package com.style24.scm.support.env;
 
 /**
  * 변경될 소지가 있는 변수 값을 정의
- * 
+ *
  * @author gagamel
  * @since 2020. 10. 19
  */
 public class TssConstants {
 
+	public static final String EXCEL_FOOTER_TITLE = "Copyright(c) 2020 STYLE24, All rights reserved.";
+
 	// 사이트코드
-	public static final String SITE_CD = "10";
+	public static final String SITE_CD = "G047_10";
 
 }