|  | @@ -382,6 +382,7 @@
 | 
	
		
			
				|  |  |  		WHERE
 | 
	
		
			
				|  |  |  			mg.del_flag_ = 0
 | 
	
		
			
				|  |  |  			AND mg.organ_id_ IS NOT NULL
 | 
	
		
			
				|  |  | +		  	AND mg.status_ = 'PROGRESS'
 | 
	
		
			
				|  |  |  			AND DATE_FORMAT( spr.create_time_, '%Y-%m' ) <= #{month}
 | 
	
		
			
				|  |  |  		GROUP BY
 | 
	
		
			
				|  |  |  			mg.organ_id_
 | 
	
	
		
			
				|  | @@ -404,8 +405,11 @@
 | 
	
		
			
				|  |  |  			mg.del_flag_ = 0
 | 
	
		
			
				|  |  |  			AND mg.organ_id_ IS NOT NULL
 | 
	
		
			
				|  |  |  			AND mg.status_ = 'PROGRESS'
 | 
	
		
			
				|  |  | +			<if test="paymentStatus==null">
 | 
	
		
			
				|  |  | +				AND sr.music_group_status_ IN ('APPLY', 'NORMAL')
 | 
	
		
			
				|  |  | +			</if>
 | 
	
		
			
				|  |  |  		  	<if test="paymentStatus!=null">
 | 
	
		
			
				|  |  | -				AND sr.music_group_status_ IN ('NORMAL', 'QUIT')
 | 
	
		
			
				|  |  | +				AND sr.music_group_status_ IN ('NORMAL')
 | 
	
		
			
				|  |  |  				AND sr.payment_status_ = #{paymentStatus,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}
 | 
	
		
			
				|  |  |  			</if>
 | 
	
		
			
				|  |  |  			AND DATE_FORMAT( sr.create_time_, '%Y-%m' ) <= #{month}
 |