Compare commits

..

No commits in common. "fb5a4ef34eab98cf3f5abf1907bd4846aacd3b79" and "73f0005f86fe2edcf82e04b16ea7066b92d5c25f" have entirely different histories.

2 changed files with 17 additions and 6 deletions

View File

@ -3199,6 +3199,10 @@ public class EstimateService {
SimulationEstimateListResponse response = new SimulationEstimateListResponse();
if (!"T01".equals(objectRequest.getSaleStoreId())) {
objectRequest.setSchSelSaleStoreId("");
}
// 견적서 목록 조회
List<ObjectResponse> objectList = estimateMapper.selectSimulationEstimateList(objectRequest);

View File

@ -1549,7 +1549,7 @@
<select id="selectSimulationEstimateList" parameterType="com.interplug.qcast.biz.object.dto.ObjectRequest" resultType="com.interplug.qcast.biz.object.dto.ObjectResponse">
/* sqlid : com.interplug.qcast.biz.estimate.selectSimulationEstimateList */
<if test='saleStoreId != null and saleStoreId != "T01"'>
<if test='(saleStoreId != null and saleStoreId != "T01") or (schSelSaleStoreId != null and schSelSaleStoreId != "")'>
/* 계층형 구조에 맞는 SALE_STORE_ID 축출 - 재귀함수 */
WITH SALES_STORE_CTE AS (
SELECT
@ -1559,7 +1559,14 @@
FROM M_SALES_STORE WITH(NOLOCK)
WHERE APPROVE_FLG = '2'
AND DEL_FLG = '0'
AND SALE_STORE_ID = #{saleStoreId}
<choose>
<when test='schSelSaleStoreId != null and schSelSaleStoreId != ""'>
AND SALE_STORE_ID = #{schSelSaleStoreId}
</when>
<otherwise>
AND SALE_STORE_ID = #{saleStoreId}
</otherwise>
</choose>
UNION ALL
SELECT
@ -1595,7 +1602,7 @@
ON O.SALE_STORE_ID = S.SALE_STORE_ID
INNER JOIN T_PLAN P WITH (NOLOCK)
ON O.OBJECT_NO = P.OBJECT_NO
<if test='saleStoreId != null and saleStoreId != "T01"'>
<if test='(saleStoreId != null and saleStoreId != "T01") or (schSelSaleStoreId != null and schSelSaleStoreId != "")'>
INNER JOIN SALES_STORE_CTE T
ON S.SALE_STORE_ID = T.SALE_STORE_ID
</if>
@ -1607,9 +1614,9 @@
<if test='schObjectNo != null and schObjectNo != ""'>
AND O.OBJECT_NO LIKE '%' + #{schObjectNo} + '%'
</if>
<if test='schSelSaleStoreId != null and schSelSaleStoreId != ""'>
/* 판매점 아이디 선택 */
AND O.SALE_STORE_ID = #{schSelSaleStoreId}
<if test='schOtherSelSaleStoreId != null and schOtherSelSaleStoreId != ""'>
/* 2차점까지 고름 */
AND O.SALE_STORE_ID = #{schOtherSelSaleStoreId}
</if>
<if test='schObjectName != null and schObjectName != ""'>
AND O.OBJECT_NAME LIKE '%' + #{schObjectName} + '%'