Custom Aggregate Function

1 posts, 0 answers
  1. Siddhant
    Siddhant avatar
    22 posts
    Member since:
    Jan 2013

    Posted 15 Jan 2013 Link to this post

    I am trying to create and aggregate function


    var aggregate = new AggregateFunction<ResourceAllocationBE, double>
    {
    AggregationExpression = models => models.Sum(model => model.period[0].allocation),
    Caption = ""
    };

    The ResourceAllocationBE contains a period property which is another list that contains allocation and the date. Currently it is taking the first elemnt of the list but i want it to automatically select based on the date alone.
    i need to sum up the allocation and that also for a particular date. which might be null some of the times.

Back to Top