fix(csv): fix the name of the csv file to match :
period year, period num, company, type of rows, period start and period end dates
This commit is contained in:
parent
d4cbb90819
commit
0d84cc8272
|
|
@ -43,7 +43,7 @@ const onClickedDownload = async () => {
|
|||
const types = Object.entries(report_filter_options.value)
|
||||
.filter(([key, value]) => value && ['shifts', 'expenses', 'holiday', 'vacation'].includes(key)).map(([key]) => key).join('-');
|
||||
|
||||
const file_name = `${companies}_${types}_${timesheet_store.pay_period?.pay_period_no}-${timesheet_store.pay_period?.pay_year}_${timesheet_store.pay_period?.period_start}-${timesheet_store.pay_period?.period_end}.csv`;
|
||||
const file_name = `${timesheet_store.pay_period?.pay_year}-${timesheet_store.pay_period?.pay_period_no}_${companies}_${types}_${timesheet_store.pay_period?.period_start}-${timesheet_store.pay_period?.period_end}.csv`;
|
||||
|
||||
const blob = new Blob([data], { type: 'text/csv;charset=utf-8;' });
|
||||
const url = window.URL.createObjectURL(blob);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user