diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardFavorable/mapper/xml/CardFavorableRecordMapper.xml b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardFavorable/mapper/xml/CardFavorableRecordMapper.xml index a48f0f07a..eb676e16b 100644 --- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardFavorable/mapper/xml/CardFavorableRecordMapper.xml +++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardFavorable/mapper/xml/CardFavorableRecordMapper.xml @@ -7,12 +7,15 @@ count( id ) tatol, ( SELECT count( id ) FROM card_favorable_record WHERE store_id = #{storeId} + and card_favorable_id = #{id} and status = "0" ) unTatal, ( SELECT count( id ) FROM card_favorable_record WHERE store_id = #{storeId} + and card_favorable_id = #{id} and status = "1" ) usedTatal, ( SELECT count( id ) FROM card_favorable_record WHERE store_id = #{storeId} + and card_favorable_id = #{id} and status = "2" ) outTatal FROM card_favorable_record