Changeset 1571


Ignore:
Timestamp:
Nov 15, 2006, 6:19:12 PM (17 years ago)
Author:
Russ Tyndall
Message:

TimingAndEstimationPlugin:

Updated reports in an effort to make sum work on postegre and fix rollups showing at the top rather than the bottom of the ticket

Location:
timingandestimationplugin/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • timingandestimationplugin/trunk/setup.py

    r1554 r1571  
    88      description='Plugin to make Trac support time estimation and tracking',
    99      keywords='trac plugin estimation timetracking',
    10       version='0.2.4',
     10      version='0.2.5',
    1111      url='',
    1212      license='http://www.opensource.org/licenses/mit-license.php',
  • timingandestimationplugin/trunk/timingandestimationplugin/reports.py

    r1496 r1571  
    99    "title":"Ticket Work Summary",
    1010    "reportnumber":None,
    11     "version":7,
     11    "version":9,
    1212    "sql":"""
    1313SELECT ticket as __group__, __style__, ticket,
     
    3636UNION
    3737
    38 SELECT 'background-color:#DFE;' as __style__, 'Ticket Work Summary for the selected time period ' as author, t.id as ticket, sum(newvalue) as newvalue, NULL as time,
     38SELECT 'background-color:#DFE;' as __style__, 'Ticket Work Summary for the selected time period ' as author, t.id as ticket,
     39sum( CAST(newvalue as real) ) as newvalue,
     40NULL as time,
    3941
    4042-- 'Ticket Work Summary for the selected time period '
     
    5557GROUP By t.id
    5658)  as tbl
    57 ORDER BY ticket,  _ord , time
     59ORDER BY ticket,  _ord ASC , time ASC
    5860
    5961    """
     
    6264    "title":"Milestone Work Summary",
    6365    "reportnumber":None,
    64     "version":7,
     66    "version":9,
    6567    "sql":"""
    6668
     
    7577 _ord
    7678FROM(
    77 SELECT '' as __style__, t.id as ticket, SUM(newvalue) as newvalue,t.summary as summary,
     79SELECT '' as __style__, t.id as ticket, SUM(CAST(newvalue as real)) as newvalue,t.summary as summary,
    7880 MAX(ticket_change.time) as time,
    7981
     
    9698
    9799SELECT 'background-color:#DFE;' as __style__,
    98  NULL as ticket, sum(newvalue)  as newvalue,
     100 NULL as ticket, sum(CAST(newvalue as real))  as newvalue,
    99101'' as summary,
    100102NULL as time,
     
    117119GROUP By t.milestone
    118120)  as tbl
    119 ORDER BY milestone, ticket, time,  _ord
     121ORDER BY milestone,  _ord ASC, ticket, time
    120122
    121123
     
    127129    "title":"Developer Work Summary",
    128130    "reportnumber":None,
    129     "version":6,
     131    "version":9,
    130132    "sql":"""
    131133SELECT author as __group__,__style__, ticket,
     
    154156
    155157SELECT 'background-color:#DFE;' as __style__, author,
    156 NULL as ticket, sum(newvalue) as newvalue, NULL as time,
     158NULL as ticket, sum(CAST(newvalue as real)) as newvalue, NULL as time,
    157159
    158160-- 'Developer Work Summary for '||
     
    172174GROUP By author
    173175)  as tbl
    174 ORDER BY author, time,  _ord
     176ORDER BY author,  _ord ASC, time
    175177   
    176178    """
     
    181183    "title": "Ticket Hours",
    182184    "reportnumber": None,
    183     "version":4,
     185    "version":6,
    184186    "sql": """
    185187SELECT __color__,  __style__,  ticket, summary_, component ,version, severity,
     
    227229       NULL as ticket, 'Time Summary' AS summary_,             
    228230       NULL as component,NULL as version, NULL as severity, NULL as  milestone, NULL as status, NULL as owner,
    229        SUM(EstimatedHours.value) as Estimated_hours,
    230        SUM(totalhours.value) as total_hours,
     231       SUM(CAST(EstimatedHours.value as real)) as Estimated_hours,
     232       SUM(CAST(totalhours.value as real)) as total_hours,
    231233       NULL as billable,
    232234       NULL as created, NULL as modified,         -- ## Dates are formatted
     
    251253    AND billable.value in ($BILLABLE, $UNBILLABLE)
    252254)  as tbl
    253 ORDER BY ticket, _ord   
     255ORDER BY  _ord ASC, ticket
    254256    """
    255257    },
     
    258260    "title": "Ticket Hours with Description",
    259261    "reportnumber": None,
    260     "version":4,
     262    "version":7,
    261263    "sql": """
    262264SELECT __color__,  __style__,  ticket, summary_, component ,version, severity,
     
    304306       NULL as ticket, 'Time Summary' AS summary_,             
    305307       NULL as component,NULL as version, NULL as severity, NULL as  milestone, NULL as status, NULL as owner,
    306        SUM(EstimatedHours.value) as Estimated_hours,
    307        SUM(totalhours.value) as total_hours,
     308       SUM(CAST(EstimatedHours.value as real)) as Estimated_hours,
     309       SUM(CAST(totalhours.value as real)) as total_hours,
    308310       NULL as billable,
    309311       NULL as created, NULL as modified,         -- ## Dates are formatted
     
    328330    AND billable.value in ($BILLABLE, $UNBILLABLE)
    329331)  as tbl
    330 ORDER BY ticket, _ord   
     332ORDER BY _ord ASC, ticket
    331333    """
    332334    },
     
    336338    "title":"Ticket Hours Grouped By Component",
    337339    "reportnumber":None,
    338     "version":4,
     340    "version":6,
    339341    "sql": """
    340342SELECT __color__, __group__, __style__,  ticket, summary_, component ,version, severity,
     
    385387       t.component as component,NULL as version, NULL as severity, NULL as  milestone, NULL as status,
    386388       NULL as owner,
    387        SUM(EstimatedHours.value) as Estimated_hours,
    388        SUM(totalhours.value) as total_hours,
     389       SUM(CAST(EstimatedHours.value as real)) as Estimated_hours,
     390       SUM(CAST(totalhours.value as real)) as total_hours,
    389391       NULL as billable,
    390392       NULL as created,
     
    411413  GROUP BY t.component
    412414)  as tbl
    413 ORDER BY component,ticket, _ord   
     415ORDER BY component, _ord ASC,ticket
    414416    """
    415417    },
     
    419421    "title":"Ticket Hours Grouped By Component with Description",
    420422    "reportnumber":None,
    421     "version":4,
     423    "version":6,
    422424    "sql": """
    423425SELECT __color__, __group__, __style__,  ticket, summary_, component ,version, severity,
     
    467469       NULL as ticket, 'Time Summary' AS summary_,             
    468470       t.component as component,NULL as version, NULL as severity, NULL as  milestone, NULL as status, NULL as owner,
    469        SUM(EstimatedHours.value) as Estimated_hours,
    470        SUM(totalhours.value) as total_hours,
     471       SUM(CAST(EstimatedHours.value as real)) as Estimated_hours,
     472       SUM(CAST(totalhours.value as real)) as total_hours,
    471473       NULL as billable,
    472474       NULL as created, NULL as modified,         -- ## Dates are formatted
     
    492494  GROUP BY t.component
    493495)  as tbl
    494 ORDER BY component,ticket, _ord   
     496ORDER BY component,_ord ASC, ticket
    495497    """
    496498    },
     
    499501    "title":"Ticket Hours Grouped By Milestone",
    500502    "reportnumber":None,
    501     "version":4,
     503    "version":6,
    502504    "sql": """
    503505SELECT __color__, __group__, __style__,  ticket, summary_, component ,version, severity,
     
    548550       NULL as component,NULL as version, NULL as severity, t.milestone as  milestone,
    549551       NULL as status, NULL as owner,
    550        SUM(EstimatedHours.value) as Estimated_hours,
    551        SUM(totalhours.value) as total_hours,
     552       SUM(CAST(EstimatedHours.value as real)) as Estimated_hours,
     553       SUM(CAST(totalhours.value as real)) as total_hours,
    552554       NULL as billable,
    553555       NULL as created, NULL as modified,         -- ## Dates are formatted
     
    573575  GROUP BY t.milestone
    574576)  as tbl
    575 ORDER BY milestone,ticket, _ord   
     577ORDER BY milestone,_ord ASC, ticket
    576578    """
    577579    },
     
    580582    "title":"Ticket Hours Grouped By MileStone with Description",
    581583    "reportnumber":None,
    582     "version":4,
     584    "version":6,
    583585    "sql": """
    584586SELECT __color__, __group__, __style__,  ticket, summary_, component ,version, severity,
     
    629631       NULL as component,NULL as version, NULL as severity, t.milestone as  milestone,
    630632       NULL as status, NULL as owner,
    631        SUM(EstimatedHours.value) as Estimated_hours,
    632        SUM(totalhours.value) as total_hours,
     633       SUM(CAST(EstimatedHours.value as real)) as Estimated_hours,
     634       SUM(CAST(totalhours.value as real)) as total_hours,
    633635       NULL as billable,
    634636       NULL as created, NULL as modified,         -- ## Dates are formatted
     
    654656  GROUP BY t.milestone
    655657)  as tbl
    656 ORDER BY milestone,ticket, _ord   
     658ORDER BY milestone, _ord ASC, ticket
    657659    """
    658660    }
Note: See TracChangeset for help on using the changeset viewer.