# Bug OP-8000 - Time and costs xls export should use configured date format in the file name

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

## Open points

_No work packages_

## Details

| Attribute | Value |
| --- | --- |
| Date |  |
| Priority | Medium |
| Module | Modules and project features / Costs and budgets, Modules and project features / Export / XLS Export |
| Target versions | 13.0.0 |
| Observed in versions | 10.4.0 |
| Sprint | 13.0.0 |
| Backlog bucket |  |
| Bug found in version (deprecated) | 10.4.x |
| Found in mobile app version |  |
| Follow-up feedback e-mail |  |
| Requires doc change | No |
| Accessibility | No |
| Pull preview |  |
| List |  |
| Labels |  |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable |  |
| Product manager |  |
| Developers |  |
| Designer |  |
| Ordered by |  |
| Signed off by |  |
| Interest by |  |

## Planning

| Attribute | Value |
| --- | --- |
| Relevance |  |

## Costs

| Attribute | Value |
| --- | --- |
| Votes |  |
| Work |  |
| Labor costs |  |

## Description

### **Environment**:

Your OpenProject Version: 11.0.1

Operating System / Browser / OpenProject language: any/ any/ Lithuanian

### **Steps to reproduce:**

1.  Go to Administration \> System settings \> View \> Date format and set 2020-12-04 (as is common in Lithuania)
2.  Open any project with time or costs logged, press "Export to XLS"

**Actual Behavior**

You'll get file with name similar to "export-04-12-2020-T-16-48-38.xls"

### **Expected Behavior**

Expected behavior -- filename similar to "export-2020-12-04-T-16-48-38.xls" . "/" characters often used in dates should not be put into filename, but please keep order of date parts configured in the system.

In parts of the world where we've adopted ISO date and time format we used to relay on the fact that if we sort files with dates using simple ascii sort rules, we'll get them sorted by time too.

Format currently is hardcoded in <https://github.com/opf/openproject/blob/e848d44dead48966115b628fd3f6c4f2b444573b/modules/xls\_export/lib/open\_project/xls\_export/patches/cost\_reports\_controller\_patch.rb#L23>
