Rock.Model.FinancialTransactionDetailService.GetGivingAnalyticsParameters C# (CSharp) Method

GetGivingAnalyticsParameters() private static method

private static GetGivingAnalyticsParameters ( System.DateTime start, System.DateTime end, decimal minAmount, decimal maxAmount, List accountIds, List currencyTypeIds, List sourceTypeIds ) : object>.Dictionary
start System.DateTime
end System.DateTime
minAmount decimal
maxAmount decimal
accountIds List
currencyTypeIds List
sourceTypeIds List
return object>.Dictionary
        private static Dictionary<string, object> GetGivingAnalyticsParameters( DateTime? start, DateTime? end, decimal? minAmount, decimal? maxAmount,
            List<int> accountIds, List<int> currencyTypeIds, List<int> sourceTypeIds )
        {
            Dictionary<string, object> parameters = new Dictionary<string, object>();

            if ( start.HasValue )
            {
                parameters.Add( "StartDate", start.Value );
            }

            if ( end.HasValue )
            {
                parameters.Add( "EndDate", end.Value );
            }

            if ( minAmount.HasValue )
            {
                parameters.Add( "MinAmount", minAmount.Value );
            }

            if ( maxAmount.HasValue )
            {
                parameters.Add( "MaxAmount", maxAmount.Value );
            }

            if ( accountIds != null && accountIds.Any() )
            {
                parameters.Add( "AccountIds", accountIds.AsDelimited(",") );
            }

            if ( currencyTypeIds != null && currencyTypeIds.Any() )
            {
                parameters.Add( "CurrencyTypeIds", currencyTypeIds.AsDelimited(",") );
            }

            if ( sourceTypeIds != null && sourceTypeIds.Any() )
            {
                parameters.Add( "SourceTypeIds", sourceTypeIds.AsDelimited(",") );
            }

            return parameters;
        }