# Feature OP-16430 - Consolidate "Download PDF" feature with the "Generate PDF" feature in one export modal

Project: OpenProject
Status: closed
URL: https://community.openproject.org/work_packages/OP-16430

## Planning

| Attribute | Value |
| --- | --- |
| Date |  |
| Priority | Medium |
| Target versions | 15.4.0 |
| Sprint | 15.4.0 |
| Backlog bucket |  |
| Votes |  |
| List |  |
| Roadmap |  |
| Relevance |  |

## OPEN POINTS / FEEDBACK

_No work packages_

## Features and Chunks

_No work packages_

## Bugs and other work packages

_No work packages_

## Technical Details

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

## Details

| Attribute | Value |
| --- | --- |
| Pull preview |  |
| Mockups | https://www.figma.com/design/E8rnFXuNGRJ4qrFOmbsr0J/Generate-PDF?node-id=0-1 |
| Accessibility | No |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable | Andrej Sandorf |
| Product manager |  |
| Feature Lead |  |
| Developers | Andrej Sandorf |
| Designer | Parimal Satyal |
| Ordered by |  |
| Signed off by |  |
| Interest by |  |

## Estimates and progress

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

## Description

**Current situation**

  - Currently, we have two menu items:
    
      - Generate PDF
    
      - Download PDF

  - The difference between both features is challenging to explain and to understand.

**Acceptance criteria** 

  - Feature flag for "Generate PDF" is removed.

  - The "Download PDF" menu item is removed.

  - We support multiple templates to generate PDF, e.g. contract, [business letter](https://community.openproject.org/wp/60437).

  - The Generate PDF option is retained. It triggers a modal with different export options.
    
      - The footer of the modal has two options:
        
          - Download (primary)
        
          - Cancel (secondary)

  - The first option is a dropdown with the label "Template".
    
      - The list of options depends on which templates have been enabled for the present type in the admin settings.
    
      - The first option is selected by default.
    
      - Possible template options (for the moment) are:
        
          - Attributes and description `attributes` (the template which is currently used by the "Download PDF" action)
        
          - Contract `contract`
    
      - Each of these options also has an associated description to help users understand what they mean. These appear as the caption to the dropdown, depending on the selection.

  - Additional options have changes in layout, name and guideline text compared to the current dialog (see [mockup](https://www.figma.com/design/E8rnFXuNGRJ4qrFOmbsr0J/Generate-PDF?node-id=0-1)):
    
      - Hyphenation
    
      - Language and hyphenation
    
      - Footer text, depending on the template selection
        
          - `attributes` proposes project name (center footer)
        
          - `contract` proposes the work package subject (right footer)

  - Each template brings default for the above-mentioned options.

  - In Administration → Work packages → Types → *{Type}*
    
      - There is a new tab called "Generate PDF"
    
      - In this tab, there is a list of all available templates (in a draggable box component)
    
      - Each template has an enable/disable toggle to enable or disable that template for the present type
    
      - The order can be rearranged by dragging the items up or down
    
      - The first one is considered the default selection in the 'Generate PDF' dialog for that type
        
          - This is explained in a short text at the top of the page

**Out of scope**

  - Templates are defined as YAML files manually uploaded by administrators.

  - [business letter](https://community.openproject.org/wp/60437) template
