Changes between Version 1 and Version 2 of SumStatsPlugin


Ignore:
Timestamp:
Nov 22, 2011, 10:35:40 PM (3 years ago)
Author:
robguttman
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • SumStatsPlugin

    v1 v2  
    77This is a complement to the [wiki:SumFieldsPlugin Sum Fields plugin] which sums fields in a query or report.  This plugin sums fields for the Roadmap and Milestone views.  These plugins are useful when assessing progress based on "points" or "ideal days" of effort instead of ticket count.
    88
    9 This plugin was inspired by the CustomRoadmapPlugin but overcomes its limitation of requiring a patch.  Additionally, this plugin allows for any fields to be used to define a group, not just the default {{{status}}} field.
     9[[Image(sumstats.png)]]
     10
     11This plugin was inspired by the CustomRoadmapPlugin but overcomes its limitation of requiring a patch.  Additionally, this plugin allows for any fields to be used to define a group, not just the default {{{status}}} field.  Lastly, I designed the plugin to be backwards compatible with the default ticket count behavior so that you can take leverage as much or little of its enhancements as desired.
     12
     13== Configuration ==
     14 1. Install the plugin (after downloading and unzipping):
     15    {{{
     16    cd sumstatsplugin/0.12
     17    sudo python setup.py install
     18    }}}
     19
     20    See [http://trac.edgewall.org/wiki/TracPlugins TracPlugins] for more installation details and options.  You'll likely need to restart Trac's web server after installation.
     21
     22 2. Enable the plugin in {{{trac.ini}}}:
     23    {{{
     24    [components]
     25    sumstats.* = enabled
     26    }}}
     27
     28    You can alternatively use the Trac Web Admin GUI.
     29
     30 3. Replace the {{{DefaultTicketGroupStatsProvider}}} with this plugin's new {{{SumTicketGroupStatsProvider}}} as shown here:
     31    {{{
     32    [roadmap]
     33    stats_provider = SumTicketGroupStatsProvider
     34   
     35    [milestone]
     36    stats_provider = SumTicketGroupStatsProvider
     37    }}}
     38
     39 3. (Optional) Configure the main {{{trac.ini}}} section:
     40    {{{
     41    [sumstats]
     42    field = effort
     43    label = effort
     44    drilldown_label = Ticket effort
     45    query_args = col=summary,col=type,col=effort
     46    }}}
     47
     48The optional {{{field}}} option specifies which field to sum.  The optional {{{drilldown_label}}} and {{{label}}} are used to define the {{{TicketGroupStats}}} object.  The optional {{{query_args}}} is a convenient, comma-delimited list that gets appended to each group's {{{query_args}}}.  See the examples below for more details.
    1049
    1150== Bugs/Feature Requests ==
     
    2766== Example ==
    2867
    29 Here's an example {{{trac.ini}}} config that combines a custom {{{phase}}} field with the default {{{status}}} workflow:
     68Here's an example {{{trac.ini}}} config that combines a custom {{{phase}}} field with a built-in {{{resolution}}} field:
    3069{{{
    31 [roadmap]
    32 stats_provider = SumTicketGroupStatsProvider
    33 
    34 [milestone]
    35 stats_provider = SumTicketGroupStatsProvider
    36 
    3770[milestone-groups]
    3871closed = fixed
     
    4174closed.order = 1
    4275closed.overall_completion = true
     76
    4377readying = *
    4478readying.field = phase
    4579readying.order = 2
    4680readying.color = YellowGreen
     81
    4782implementation = implementation
    4883implementation.field = phase
    4984implementation.order = 3
    5085implementation.color = Yellow
     86
    5187waiting = waiting
    5288waiting.field = phase
    5389waiting.order = 4
    5490waiting.color = White
     91
    5592scoping = sizing,definition
    5693scoping.field = phase
     
    5895scoping.color = Red
    5996}}}
     97
     98In general, the plugin maintains the same syntax and semantics as the {{{DefaultTicketGroupStatsProvider}}} to support backwards compatibility and ease of transition.  If the {{{.field}}} option is omitted, then the {{{status}}} field is presumed.  Note that a {{{.color}}} option is required for each group (except for any default {{{closed}}} or {{{new}}} group you have).  The "catch all" {{{*}}} value is also still supported (although there are currently no checks for duplicate "catch all" or otherwise redundant group definitions).
    6099
    61100== Recent Changes ==