# Feature SPAR-85 - % Complete totals using simple averages (without Work)

Project: Stream Planning and Reporting
Status: closed
URL: https://community.openproject.org/work_packages/SPAR-85

## Planning

| Attribute | Value |
| --- | --- |
| Date |  |
| Priority | Medium |
| Target versions | 14.6.0 |
| Votes |  |
| List | cProject |
| Roadmap |  |
| Relevance |  |

## OPEN POINTS / FEEDBACK

_No work packages_

## Use cases

_No work packages_

## Features and Chunks

| ID | Subject | Type | Status | Assignee | Target versions | Spent time |
| --- | --- | --- | --- | --- | --- | --- |
| SPAR-91 | Dedicated admin section for progress tracking | Implementation | closed |  | 14.6.0 |  |
| SPAR-92 | Options for total calculation sum mode | Implementation | closed |  | 14.6.0 |  |
| SPAR-93 | Options for changing % complete when closing work package | Implementation | closed |  | 14.6.0 |  |

## Bugs and other work packages

| ID | Type | Subject | Status | Assignee | Target versions | Spent time | Module |
| --- | --- | --- | --- | --- | --- | --- | --- |
| SPAR-99 | Bug | Remove mention of 'current behaviour' in work package progress tracking settings | closed |  | 14.6.0 |  |  |

## Technical Details

| Attribute | Value |
| --- | --- |
| Module |  |
| Feature Flag |  |
| Requires doc change | Yes |
| Enterprise plan |  |

## Details

| Attribute | Value |
| --- | --- |
| Pull preview |  |
| Mockups | https://www.figma.com/design/oHC3NTL9zTkcS6WkpBeJR0/Work-packages-%2F-Progress?node-id=0-1 |
| Build Number |  |
| Found in mobile app version |  |
| Follow-up feedback e-mail |  |
| Accessibility | No |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable | Christophe Bliard |
| Product manager |  |
| Feature Lead |  |
| Developers | Christophe Bliard, Aaron Contreras |
| Designer | Parimal Satyal |
| Ordered by |  |
| Signed off by |  |
| Interest by |  |

## Estimates and progress

| Attribute | Value |
| --- | --- |
| PD (min) |  |
| PD (max) |  |
| Work |  |
| Labor costs |  |

## Description

#### **Context**

With feature <mention class="mention" data-id="52233" data-type="work_package" data-text="###52233">###52233</mention>, we are now making it possible to input and % Complete manually again without requiring Work or Remaining work values to be entered. This will be a net positive for users who were dissatisfied with the breaking changes in 14.0 (feedback: <mention class="mention" data-id="55370" data-type="work_package" data-text="###55370">###55370</mention>).

However, it is still not possible to hierarchy totals for *% Complete* without also entering *Work* for each child. A lot of our users don't use Work but still want totals. This feature will make this possible.

#### Acceptance criteria

  - Under Administration → Work packages,
    
      - The *Work package settings* page is renamed to '**General*****'***
    
      - There is a new page called '**Progress tracking**' listed right under 'Status'

  - The new Progress tracking page is Primerised:

  - The **Progress calculation** setting is moved here and renamed **"Progress calculation mode**"
    
      - Option 1: **Work-based** (default)
        
          - Guideline text when selected: "**In work-based mode**, *% Complete* can be freely be set to any value. If you optionally enter a value for *Work,* *Remaining work* will automatically be derived."
    
      - Option 2: **Status-based**
        
          - Guideline text when selected: "**In status-based mode**, each status has a *% Complete* value associated with it. Changing status will change *% Complete.*"
    
      - These two options will continue to work as they do right now; the only change is that the setting is now in a separate page.

  - There is a new setting called "**Calculation of % Complete hierarchy totals**" with two options:
    
      - Option 1: **Simple average**
        
          - Guideline text when selected: "*Work* is ignored and the *total % Complete* will be a simple average of *% Complete* values of work packages in the hierarchy."
    
      - Option 2: **Weighted by work** (default)
        
          - Guideline text when selected: "The *total* *% Complete* will be weighted against the *Work* of each work package in the hierarchy. Work packages without *Work* will be ignored."
    
      - Weighted by work will continue to work as it does today:
        
          - The total of *% Complete* will be weighted with the value of *Work* (as a cofficient of each work package's *% Complete* value).
        
          - If a work package does not have a value for *Work*, it is ignored in the calculation of *% Complete* totals for that hierarchy.
        
          - When changing modes, appropriate work packages (typically parents) will have a journal entry visible in the Activity tab:
            
              - **From** ***Simple average*** **to** ***Weighted by work*****:**
                
                  - **Calculation of % Complete totals** now weighted by Work. Child work packages without Work are ignored.
            
              - **From** ***Weighted by work*** **to** ***Simple average:***
                
                  - **Calculation of % Complete totals** now based on a simple average of only % Complete values. Work values of child work packages are ignored.
    
      - Simple average will work in a more straightforward manner; it will ignore the values of *Work* (which becomes an optional field that does not affect *% Complete* totals).
    
      - The total of a parent includes values of direct children *and* its own value (in both modes).
        
          - In Work-based mode
            
              - the parent's own value is only taken into account if *Work* also exists.
        
          - In Simple average mode
            
              - the parent's own value is included as if it were another line in the calculation of the total, but only if that value is set.
            
              - the value considered for a direct child is its total % complete value if it has one (if this child also has children), or its % complete value if it has one, or 0%.
    
      - Because Weighted by work is default, nothing will automatically change when upgrading to a new version. The admin will simply now have an additional choice to select Simple average.

  - There is a new setting called "**% Complete when status is closed"** with two options:
    
      - Option 1: **Automatically set to 100%**
        
          - Guideline text when selected: "A closed work package is considered complete.*"*
    
      - Option 2: **No change** (default)
        
          - Guideline text when selected: "The value of % Complete will not change even when a work package is closed.*"*

  - When "Status-based" mode is selected:
    
      - The last field ("**% Complete when status is closed**") should be disabled.

#### Example of simple average

Here is an example of valid values when using simple average:

<img class="op-uc-image op-uc-image_inline" src="/api/v3/attachments/198012/content">

So:

  - work packages which should have a total % complete are parent, special child 3, and gifted child 4, because they have children.

  - gifted child 4 has its own value at 40%, and a direct child at 100%. The average is then (40 + 100) / 2 = 70%

  - special child 3 does not have a value of its own, so it will no be counted. Then it has two children. One has 100%, the other has no value. No value for a child is considered 0%. The average is then (100 + 0) / 2 = 50%

  - parent has a value of its own and 4 children. For special child 3 and gifted child 4, total % complete will be used for the computation as it is available. Total is then (70 + 40 + 100 + 50 + 70) / 5 = 66%

#### Out of scope

  - Type-level settings

  - Project-level settings

#### Archived open point

##### ~~**Problem**~~

~~Currently, as is implemented and specified today, the totals for % Complete (in a hierarchy)~~ *~~only~~* ~~take into account work packages with Work. This is because the total is a weighted average, weighted by Work. This makes it easier to have a more accurate % Complete, but does not work when:~~

  - ~~Users only have Work estimates for~~ *~~some~~* ~~of the work packages in the hierarchy~~

  - ~~Users don't have Work estimates at all and are manually reporting progress~~

~~Some users are already communicating to us that they rely on % Complete totals and would like this without work.~~

~~Christophe and I think this is important too. The lack of flexibility will continue to cause frustration to our users.~~

##### ~~**Potential Solutions**~~

~~We have identified three main ways to solve the issue:~~

<figure class="table op-uc-figure_align-center op-uc-figure"><table class="op-uc-table"><tbody><tr class="op-uc-table--row"><td class="op-uc-table--cell" style="width:140px;"><p class="op-uc-p"></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s><strong>Solution</strong></s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s><strong>Advantages</strong></s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s><strong>Disadvantages</strong></s></p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell" style="width:140px;"><p class="op-uc-p"><s><strong>A: Simple average</strong></s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>Make % Complete a simple average of all child work packages, regardless of Work</s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>Easy to understand, consistent behaviour. Works even if Work/Remaining work are not set.</s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>% Complete no longer scales to different effort levels. A task that takes 40 hours has the same weight as one that takes 40 days.</s></p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell" style="width:140px;"><p class="op-uc-p"><s><strong>B: User setting</strong></s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>Keep % Complete a weighted average but use a "default" work value for those work packages that don't have it.</s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>Works also in cases where Work is set in some but not other children work packages. If </s><i><s>none</s></i><s> have work, then becomes a simple average (?)</s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>What should the "default" Work be for those children where Work is not set. An average? Difficult to understand, calculation less transparent.</s></p></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell" style="width:140px;"><p class="op-uc-p"><s><strong>C: Manual mode</strong></s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>Let users choose between "Simple" and "Weighted" mode. Essentially, introduce a third mode called "Manual progress", in which the % Complete is simply completely independent of Work and Remaining work.</s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>Users have full control and can chose between pre-14.0 behaviour and current behaviour. The setting only has to be set by the admin once.&nbsp;</s></p></td><td class="op-uc-table--cell"><p class="op-uc-p"><s>More work. Need to create a new mode and, in that new mode, undo the display of the pop-over (since the % Complete field would be independent and no longer tied to Work and Remaining work).&nbsp;</s></p></td></tr></tbody></table></figure>

~~**Question**~~

~~Which approach should we take?~~
