Duan_xu 2 년 전
부모
커밋
6c8f417ed3
1개의 변경된 파일317개의 추가작업 그리고 320개의 파일을 삭제
  1. 317 320
      src/main/resources/mappings/modules/product/ProductMapper.xml

+ 317 - 320
src/main/resources/mappings/modules/product/ProductMapper.xml

@@ -1496,326 +1496,323 @@
         WHERE productID = #{productID}
     </update>
 
-    <update id="updateProductByBrandId">
-        UPDATE product
-        set brandID = null
-        WHERE brandID = #{brandId}
-    </update>
-    <select id="getProductIdByBrandId" resultType="java.lang.Integer">
-        SELECT productID
-        FROM product
-        WHERE brandID = #{brandId}
-    </select>
-    <update id="updateTinyType">
-        UPDATE product
-        set tinyTypeID = #{tinyTypeID}
-        WHERE productID = #{productID}
-    </update>
-    <update id="updateByPrimaryKeySelective" parameterType="com.caimei.modules.product.entity.Product">
-        update product
-        <set>
-            <if test="productDescribe != null and productDescribe != ''">
-                productDescribe = #{productDescribe},
-            </if>
-            <if test="productDetail != null and productDetail != ''">
-                productDetail = #{productDetail},
-            </if>
-            <if test="brandID != null and brandID != ''">
-                brandID = #{brandID},
-            </if>
-            <if test="bigTypeID != null and bigTypeID !=''">
-                bigTypeID = #{bigTypeID},
-                smallTypeID = #{smallTypeID},
-                tinyTypeID = #{tinyTypeID},
-            </if>
-            <if test="preferredFlag != null and preferredFlag !=''">
-                preferredFlag = #{preferredFlag},
-            </if>
-            <if test="shopID != null and shopID !=''">
-                shopID = #{shopID},
-            </if>
-            <if test="name != null and name !=''">
-                `name` = #{name},
-            </if>
-            <if test="aliasName != null and aliasName !=''">
-                aliasName = #{aliasName},
-            </if>
-            <if test="searchKey != null and searchKey !=''">
-                searchKey = #{searchKey},
-            </if>
-            <if test="productRemarks != null and productRemarks !=''">
-                productRemarks = #{productRemarks},
-            </if>
-            <if test="combinationID != null and combinationID !=''">
-                combinationID = #{combinationID},
-            </if>
-            <if test="normalPrice != null and normalPrice !=''">
-                normalPrice = #{normalPrice},
-            </if>
-            <if test="price != null and price !=''">
-                price = #{price},
-            </if>
-            <if test="priceFlag != null and priceFlag !=''">
-                priceFlag = #{priceFlag},
-            </if>
-            <if test="beautyActFlag != null and beautyActFlag !=''">
-                beautyActFlag = #{beautyActFlag},
-            </if>
-            <if test="ladderPriceFlag != null and ladderPriceFlag !=''">
-                ladderPriceFlag = #{ladderPriceFlag},
-            </if>
-            <if test="stock != null and stock !=''">
-                stock = #{stock},
-            </if>
-            <if test="hasSkuFlag != null and hasSkuFlag !=''">
-                hasSkuFlag = #{hasSkuFlag},
-            </if>
-            <if test="mainImage != null and mainImage !=''">
-                mainImage = #{mainImage},
-            </if>
-            <if test="propertiesInfo != null and propertiesInfo !=''">
-                propertiesInfo = #{propertiesInfo},
-            </if>
-            <if test="addTime != null and addTime !=''">
-                addTime = #{addTime},
-            </if>
-            <if test="updateTime != null and updateTime !=''">
-                updateTime = #{updateTime},
-            </if>
-            <if test="weekSellNumber != null and weekSellNumber !=''">
-                weekSellNumber = #{weekSellNumber},
-            </if>
-            <if test="beforeValidFlag != null and beforeValidFlag !=''">
-                beforeValidFlag = #{beforeValidFlag},
-            </if>
-            <if test="validFlag != null and validFlag !=''">
-                validFlag = #{validFlag},
-            </if>
-            <if test="favoriteTimes != null and favoriteTimes !=''">
-                favoriteTimes = #{favoriteTimes},
-            </if>
-            <if test="commentScore != null and commentScore !=''">
-                commentScore = #{commentScore},
-            </if>
-            <if test="commentTimes != null and commentTimes !=''">
-                commentTimes = #{commentTimes},
-            </if>
-            <if test="selfRecommendFlag != null and selfRecommendFlag !=''">
-                selfRecommendFlag = #{selfRecommendFlag},
-            </if>
-            <if test="sysRecommendFlag != null and sysRecommendFlag !=''">
-                sysRecommendFlag = #{sysRecommendFlag},
-            </if>
-            <if test="sortIndex != null and sortIndex != ''">
-                sortIndex = #{sortIndex},
-            </if>
-            <if test="featuredFlag != null and featuredFlag !=''">
-                featuredFlag = #{featuredFlag},
-            </if>
-            <if test="featuredSortIndex != null and featuredSortIndex !=''">
-                featuredSortIndex = #{featuredSortIndex},
-            </if>
-            <if test="productCode != null and productCode !=''">
-                productCode = #{productCode},
-            </if>
-            <if test="unit != null and unit !=''">
-                unit = #{unit},
-            </if>
-            <if test="synToERPFlag != null and synToERPFlag !=''">
-                synToERPFlag = #{synToERPFlag},
-            </if>
-            <if test="allAreaFlag != null and allAreaFlag !=''">
-                allAreaFlag = #{allAreaFlag},
-            </if>
-            <if test="provinceIDs != null and provinceIDs !=''">
-                provinceIDs = #{provinceIDs},
-            </if>
-            <if test="serviceNumber != null and serviceNumber !=''">
-                serviceNumber = #{serviceNumber},
-            </if>
-            <if test="maxBuyNumber != null and maxBuyNumber !=''">
-                maxBuyNumber = #{maxBuyNumber},
-            </if>
-            <if test="minBuyNumber != null and minBuyNumber !=''">
-                minBuyNumber = #{minBuyNumber},
-            </if>
-            <if test="packageCount != null and packageCount !=''">
-                packageCount = #{packageCount},
-            </if>
-            <if test="byFlag != null and byFlag !=''">
-                byFlag = #{byFlag},
-            </if>
-            <if test="normalProductFlag != null and normalProductFlag !=''">
-                normalProductFlag = #{normalProductFlag},
-            </if>
-            <if test="wholeSaleProductFlag != null and wholeSaleProductFlag !=''">
-                wholeSaleProductFlag = #{wholeSaleProductFlag},
-            </if>
-            <if test="promotionProductFlag != null and promotionProductFlag !=''">
-                promotionProductFlag = #{promotionProductFlag},
-            </if>
-            <if test="groupBuyProductFlag != null and groupBuyProductFlag !=''">
-                groupBuyProductFlag = #{groupBuyProductFlag},
-            </if>
-            <if test="step != null and step !=''">
-                step = #{step},
-            </if>
-            <if test="actFlag != null and actFlag !=''">
-                actFlag = #{actFlag},
-            </if>
-            <if test="actSort != null and actSort !=''">
-                actSort = #{actSort},
-            </if>
-            <if test="actType != null and actType !=''">
-                actType = #{actType},
-            </if>
-            <if test="onlineTime != null and onlineTime !=''">
-                onlineTime = #{onlineTime},
-            </if>
-            <if test="downlineTime != null and downlineTime !=''">
-                downlineTime = #{downlineTime},
-            </if>
-            <if test="freePostFlag != null and freePostFlag !=''">
-                freePostFlag = #{freePostFlag},
-            </if>
-            <if test="costPrice != null and costPrice != ''">
-                costPrice = #{costPrice},
-            </if>
-            <if test="costProportional != null and costProportional !=''">
-                costProportional = #{costProportional},
-            </if>
-            <if test="costCheckFlag != null and costCheckFlag !=''">
-                costCheckFlag = #{costCheckFlag},
-            </if>
-            <if test="precisehKey != null and precisehKey !=''">
-                precisehKey = #{precisehKey},
-            </if>
-            <if test="visibility != null and visibility !=''">
-                visibility = #{visibility},
-            </if>
-            <if test="productType != null and productType !=''">
-                productType = #{productType},
-            </if>
-            <if test="qualificationImg != null and qualificationImg !=''">
-                qualificationImg = #{qualificationImg},
-            </if>
-            <if test="qualificationImg != null and qualificationImg !=''">
-                qualificationImg = #{qualificationImg},
-            </if>
-            <if test="invoiceType != null and invoiceType !=''">
-                invoiceType = #{invoiceType},
-            </if>
-            <if test="taxPoint != null and taxPoint !=''">
-                taxPoint = #{taxPoint},
-            </if>
-            <if test="supplierTaxPoint != null and supplierTaxPoint !=''">
-                supplierTaxPoint = #{supplierTaxPoint},
-            </if>
-            <if test="endTimeStr != null and endTimeStr !=''">
-                endTimeStr = #{endTimeStr},
-            </if>
-            <if test="tags != null and tags !=''">
-                tags = #{tags},
-            </if>
-            <if test="recommendType != null and recommendType !=''">
-                recommendType = #{recommendType},
-            </if>
-            <if test="machineType != null and machineType !=''">
-                machineType = #{machineType},
-            </if>
-            <if test="includedTax != null and includedTax !=''">
-                includedTax = #{includedTax},
-            </if>
-            <if test="invoiceType != null and invoiceType !=''">
-                invoiceType = #{invoiceType},
-            </if>
-            <if test="commodityType != null and commodityType != ''">
-                commodityType = #{commodityType},
-            </if>
-            <if test="trainingMethod != null">
-                trainingMethod = #{trainingMethod},
-            </if>
-            <if test="trainingType != null">
-                trainingType = #{trainingType},
-            </if>
-            <if test="trainingFee != null">
-                trainingFee = #{trainingFee},
-            </if>
-
-            <if test="newProductType ==2">
-                newvalidFlag=null,
-            </if>
-            <if test="qualificationNo != null and qualificationNo != ''">
-                qualificationNo = #{qualificationNo},
-            </if>
-            <if test="productName != null and productName != ''">
-                productName = #{productName},
-            </if>
-            <if test="qualificationTime != null and qualificationTime != ''">
-                qualificationTime = #{qualificationTime},
-            </if>
-            <if test="qualificationLink != null and qualificationLink != ''">
-                qualificationLink = #{qualificationLink},
-            </if>
-            newProductType=#{newProductType},
-            showFlag=#{showFlag},
-            announType=#{announType},
-            splitCode = #{splitCode}
-        </set>
-        where productID = #{productID}
-    </update>
-    <update id="updateproductDetailInfo" parameterType="com.caimei.modules.product.entity.ProductDetailInfo">
-        update productdetailinfo
-        <set>
-            <if test="propValueAlias != null and propValueAlias != ''">
-                propValueAlias = #{propValueAlias},
-            </if>
-            <if test="propValueImages != null and propValueImages !=''">
-                propValueImages = #{propValueImages},
-            </if>
-            <if test="detailInfo != null">
-                detailInfo = #{detailInfo},
-            </if>
-            <if test="commonDetailInfo != null">
-                commonDetailInfo = #{commonDetailInfo},
-            </if>
-            <if test="detailInfoTxt != null">
-                detailInfoTxt = #{detailInfoTxt},
-            </if>
-            <if test="seoTitle != null and seoTitle !=''">
-                seoTitle = #{seoTitle},
-            </if>
-            <if test="seoKeyword != null and seoKeyword !=''">
-                seoKeyword = #{seoKeyword},
-            </if>
-            <if test="seoDes != null and seoDes !=''">
-                seoDes = #{seoDes},
-            </if>
-            <if test="serviceInfo != null ">
-                serviceInfo = #{serviceInfo},
-            </if>
-            <if test="orderInfo != null ">
-                orderInfo = #{orderInfo},
-            </if>
-        </set>
-        where productID = #{productID}
-    </update>
-    <update id="updateLadderPrice">
-        update product_ladder_price
-        set productId  = #{productId},
-            ladderNum  = #{ladderNum},
-            buyNum     = #{buyNum},
-            buyPrice   = #{buyPrice},
-            updateBy   = #{updateBy},
-            updateDate = #{updateDate},
-            delFlag    = #{delFlag}
-        where id = #{id}
-    </update>
-    <update id="updateMainImage">
-        update product
-        set mainImage =#{mainImage}
-        where productID = #{productID}
-    </update>
+	<update id="updateProductByBrandId">
+		UPDATE product
+		set  brandID = null
+		WHERE brandID = #{brandId}
+	</update>
+	<select id="getProductIdByBrandId" resultType="java.lang.Integer">
+		SELECT productID FROM product WHERE brandID = #{brandId}
+	</select>
+	<update id="updateTinyType">
+		UPDATE product
+		set tinyTypeID = #{tinyTypeID}
+		WHERE productID = #{productID}
+	</update>
+	<update id="updateByPrimaryKeySelective" parameterType="com.caimei.modules.product.entity.Product">
+		update product
+		<set>
+			<if test="productDescribe != null and productDescribe != ''">
+				productDescribe = #{productDescribe},
+			</if>
+			<if test="productDetail != null and productDetail != ''">
+				productDetail = #{productDetail},
+			</if>
+			<if test="brandID != null and brandID != ''">
+				brandID = #{brandID},
+			</if>
+			<if test="bigTypeID != null and bigTypeID !=''">
+				bigTypeID = #{bigTypeID},
+				smallTypeID = #{smallTypeID},
+				tinyTypeID = #{tinyTypeID},
+			</if>
+			<if test="preferredFlag != null and preferredFlag !=''">
+				preferredFlag = #{preferredFlag},
+			</if>
+			<if test="shopID != null and shopID !=''">
+				shopID = #{shopID},
+			</if>
+			<if test="name != null and name !=''">
+				`name` = #{name},
+			</if>
+			<if test="aliasName != null and aliasName !=''">
+				aliasName = #{aliasName},
+			</if>
+			<if test="searchKey != null and searchKey !=''">
+				searchKey = #{searchKey},
+			</if>
+			<if test="productRemarks != null and productRemarks !=''">
+				productRemarks = #{productRemarks},
+			</if>
+			<if test="combinationID != null and combinationID !=''">
+				combinationID = #{combinationID},
+			</if>
+			<if test="normalPrice != null and normalPrice !=''">
+				normalPrice = #{normalPrice},
+			</if>
+			<if test="price != null and price !=''">
+				price = #{price},
+			</if>
+			<if test="priceFlag != null and priceFlag !=''">
+				priceFlag = #{priceFlag},
+			</if>
+			<if test="beautyActFlag != null and beautyActFlag !=''">
+				beautyActFlag = #{beautyActFlag},
+			</if>
+			<if test="ladderPriceFlag != null and ladderPriceFlag !=''">
+				ladderPriceFlag = #{ladderPriceFlag},
+			</if>
+			<if test="stock != null and stock !=''">
+				stock = #{stock},
+			</if>
+			<if test="hasSkuFlag != null and hasSkuFlag !=''">
+				hasSkuFlag = #{hasSkuFlag},
+			</if>
+			<if test="mainImage != null and mainImage !=''">
+				mainImage = #{mainImage},
+			</if>
+			<if test="propertiesInfo != null and propertiesInfo !=''">
+				propertiesInfo = #{propertiesInfo},
+			</if>
+			<if test="addTime != null and addTime !=''">
+				addTime = #{addTime},
+			</if>
+			<if test="updateTime != null and updateTime !=''">
+				updateTime = #{updateTime},
+			</if>
+			<if test="weekSellNumber != null and weekSellNumber !=''">
+				weekSellNumber = #{weekSellNumber},
+			</if>
+			<if test="beforeValidFlag != null and beforeValidFlag !=''">
+				beforeValidFlag = #{beforeValidFlag},
+			</if>
+			<if test="validFlag != null and validFlag !=''">
+				validFlag = #{validFlag},
+			</if>
+			<if test="favoriteTimes != null and favoriteTimes !=''">
+				favoriteTimes = #{favoriteTimes},
+			</if>
+			<if test="commentScore != null and commentScore !=''">
+				commentScore = #{commentScore},
+			</if>
+			<if test="commentTimes != null and commentTimes !=''">
+				commentTimes = #{commentTimes},
+			</if>
+			<if test="selfRecommendFlag != null and selfRecommendFlag !=''">
+				selfRecommendFlag = #{selfRecommendFlag},
+			</if>
+			<if test="sysRecommendFlag != null and sysRecommendFlag !=''">
+				sysRecommendFlag = #{sysRecommendFlag},
+			</if>
+			<if test="sortIndex != null and sortIndex != ''">
+				sortIndex = #{sortIndex},
+			</if>
+			<if test="featuredFlag != null and featuredFlag !=''">
+				featuredFlag = #{featuredFlag},
+			</if>
+			<if test="featuredSortIndex != null and featuredSortIndex !=''">
+				featuredSortIndex = #{featuredSortIndex},
+			</if>
+			<if test="productCode != null and productCode !=''">
+				productCode = #{productCode},
+			</if>
+			<if test="unit != null and unit !=''">
+				unit = #{unit},
+			</if>
+			<if test="synToERPFlag != null and synToERPFlag !=''">
+				synToERPFlag = #{synToERPFlag},
+			</if>
+			<if test="allAreaFlag != null and allAreaFlag !=''">
+				allAreaFlag = #{allAreaFlag},
+			</if>
+			<if test="provinceIDs != null and provinceIDs !=''">
+				provinceIDs = #{provinceIDs},
+			</if>
+			<if test="serviceNumber != null and serviceNumber !=''">
+				serviceNumber = #{serviceNumber},
+			</if>
+			<if test="maxBuyNumber != null and maxBuyNumber !=''">
+				maxBuyNumber = #{maxBuyNumber},
+			</if>
+			<if test="minBuyNumber != null and minBuyNumber !=''">
+				minBuyNumber = #{minBuyNumber},
+			</if>
+			<if test="packageCount != null and packageCount !=''">
+				packageCount = #{packageCount},
+			</if>
+			<if test="byFlag != null and byFlag !=''">
+				byFlag = #{byFlag},
+			</if>
+			<if test="normalProductFlag != null and normalProductFlag !=''">
+				normalProductFlag = #{normalProductFlag},
+			</if>
+			<if test="wholeSaleProductFlag != null and wholeSaleProductFlag !=''">
+				wholeSaleProductFlag = #{wholeSaleProductFlag},
+			</if>
+			<if test="promotionProductFlag != null and promotionProductFlag !=''">
+				promotionProductFlag = #{promotionProductFlag},
+			</if>
+			<if test="groupBuyProductFlag != null and groupBuyProductFlag !=''">
+				groupBuyProductFlag = #{groupBuyProductFlag},
+			</if>
+			<if test="step != null and step !=''">
+				step = #{step},
+			</if>
+			<if test="actFlag != null and actFlag !=''">
+				actFlag = #{actFlag},
+			</if>
+			<if test="actSort != null and actSort !=''">
+				actSort = #{actSort},
+			</if>
+			<if test="actType != null and actType !=''">
+				actType = #{actType},
+			</if>
+			<if test="onlineTime != null and onlineTime !=''">
+				onlineTime = #{onlineTime},
+			</if>
+			<if test="downlineTime != null and downlineTime !=''">
+				downlineTime = #{downlineTime},
+			</if>
+			<if test="freePostFlag != null and freePostFlag !=''">
+				freePostFlag = #{freePostFlag},
+			</if>
+			<if test="costPrice != null and costPrice != ''">
+				costPrice = #{costPrice},
+			</if>
+			<if test="costProportional != null and costProportional !=''">
+				costProportional = #{costProportional},
+			</if>
+			<if test="costCheckFlag != null and costCheckFlag !=''">
+				costCheckFlag = #{costCheckFlag},
+			</if>
+			<if test="precisehKey != null and precisehKey !=''">
+				precisehKey = #{precisehKey},
+			</if>
+			<if test="visibility != null and visibility !=''">
+				visibility = #{visibility},
+			</if>
+			<if test="productType != null and productType !=''">
+				productType = #{productType},
+			</if>
+			<if test="qualificationImg != null and qualificationImg !=''">
+				qualificationImg = #{qualificationImg},
+			</if>
+			<if test="qualificationImg != null and qualificationImg !=''">
+				qualificationImg = #{qualificationImg},
+			</if>
+			<if test="invoiceType != null and invoiceType !=''">
+				invoiceType = #{invoiceType},
+			</if>
+			<if test="taxPoint != null and taxPoint !=''">
+				taxPoint = #{taxPoint},
+			</if>
+			<if test="supplierTaxPoint != null and supplierTaxPoint !=''">
+				supplierTaxPoint = #{supplierTaxPoint},
+			</if>
+			<if test="endTimeStr != null and endTimeStr !=''">
+				endTimeStr = #{endTimeStr},
+			</if>
+			<if test="tags != null and tags !=''">
+				tags = #{tags},
+			</if>
+			<if test="recommendType != null and recommendType !=''">
+				recommendType = #{recommendType},
+			</if>
+			<if test="machineType != null and machineType !=''">
+				machineType = #{machineType},
+			</if>
+			<if test="includedTax != null and includedTax !=''">
+				includedTax = #{includedTax},
+			</if>
+			<if test="invoiceType != null and invoiceType !=''">
+				invoiceType = #{invoiceType},
+			</if>
+			<if test="commodityType != null and commodityType != ''">
+				commodityType = #{commodityType},
+			</if>
+			<if test="trainingMethod != null">
+				trainingMethod = #{trainingMethod},
+			</if>
+			<if test="trainingType != null">
+				trainingType = #{trainingType},
+			</if>
+			<if test="trainingFee != null">
+				trainingFee = #{trainingFee},
+			</if>
+			<if test="newProductType ==2">
+				newvalidFlag=null,
+			</if>
+			<if test="qualificationNo != null and qualificationNo != ''">
+				qualificationNo = #{qualificationNo},
+			</if>
+			<if test="productName != null and productName != ''">
+				productName = #{productName},
+			</if>
+			<if test="qualificationTime != null and qualificationTime != ''">
+				qualificationTime = #{qualificationTime},
+			</if>
+			<if test="qualificationLink != null and qualificationLink != ''">
+				qualificationLink = #{qualificationLink},
+			</if>
+		    newProductType=#{newProductType},
+			showFlag=#{showFlag},
+			announType=#{announType},
+			splitCode = #{splitCode}
+		</set>
+		where productID = #{productID}
+	</update>
+	<update id="updateproductDetailInfo" parameterType="com.caimei.modules.product.entity.ProductDetailInfo">
+		update productdetailinfo
+		<set>
+			<if test="propValueAlias != null and propValueAlias != ''">
+				propValueAlias = #{propValueAlias},
+			</if>
+			<if test="propValueImages != null and propValueImages !=''">
+				propValueImages = #{propValueImages},
+			</if>
+			<if test="detailInfo != null">
+				detailInfo = #{detailInfo},
+			</if>
+			<if test="commonDetailInfo != null">
+				commonDetailInfo = #{commonDetailInfo},
+			</if>
+			<if test="detailInfoTxt != null">
+				detailInfoTxt = #{detailInfoTxt},
+			</if>
+			<if test="seoTitle != null and seoTitle !=''">
+				seoTitle = #{seoTitle},
+			</if>
+			<if test="seoKeyword != null and seoKeyword !=''">
+				seoKeyword = #{seoKeyword},
+			</if>
+			<if test="seoDes != null and seoDes !=''">
+				seoDes = #{seoDes},
+			</if>
+			<if test="serviceInfo != null ">
+				serviceInfo = #{serviceInfo},
+			</if>
+			<if test="orderInfo != null ">
+				orderInfo = #{orderInfo},
+			</if>
+		</set>
+		where productID = #{productID}
+	</update>
+	<update id="updateLadderPrice">
+		update product_ladder_price
+		set productId = #{productId},
+			ladderNum = #{ladderNum},
+			buyNum = #{buyNum},
+			buyPrice = #{buyPrice},
+			updateBy = #{updateBy},
+			updateDate = #{updateDate},
+			delFlag = #{delFlag}
+		where id = #{id}
+	</update>
+	<update id="updateMainImage">
+		update product
+		set mainImage =#{mainImage}
+		where productID=#{productID}
+	</update>
 
     <select id="getProductByTypeName" resultType="com.caimei.modules.brand.entity.BrandAndProductType">
         select b.name   AS "bigTypeName",