Selaa lähdekoodia

메인전시 우선순위 수정

bin2107 4 vuotta sitten
vanhempi
commit
415f873a35

+ 13 - 6
src/main/java/com/style24/persistence/mybatis/shop/TsaDsiplay.xml

@@ -1564,13 +1564,20 @@
 			,#{contentsType}
 			,DATE_FORMAT(#{dispStdt}, '%Y-%m-%d %H:%i:%S')
 			,DATE_FORMAT(#{dispEddt}, '%Y-%m-%d %H:%i:%S')
+			<choose>
+				<when test="dispOrd != null and dispOrd != ''">
+			,#{dispOrd}
+				</when>
+				<otherwise>
 			,(SELECT DISP_ORD FROM (SELECT IFNULL((MAX(DISP_ORD) + 1), 1) AS DISP_ORD FROM	TB_CONTENTS_PREVIEW	WHERE CATE_NO = #{cateNo} AND CONTENTS_LOC = #{contentsLoc}
-			        <if test="contentsLoc != null and contentsLoc != '' and contentsLoc != 'SMM007'">
-			            <if test="brandGroupNo != null and brandGroupNo !=''">
-			                AND BRAND_GROUP_NO = #{brandGroupNo}
-			            </if>
-			        </if>
-			    ) TMP)
+			<if test="contentsLoc != null and contentsLoc != '' and contentsLoc != 'SMM007'">
+				<if test="brandGroupNo != null and brandGroupNo !=''">
+					AND BRAND_GROUP_NO = #{brandGroupNo}
+				</if>
+			</if>
+			) TMP)
+				</otherwise>
+			</choose>
 			,#{imgPath1}
 			,#{imgPath2}
 			,#{imgPath3}