fast-excel icon indicating copy to clipboard operation
fast-excel copied to clipboard

Allow users to export both strings and numbers

Open rap2hpoutre opened this issue 3 years ago • 1 comments

(this issue is a work in progress)

There are several issues where users ask for numbers to be considered as strings and, on other hand, users asking for numbers to be preserved. This should be easily configurable and understandable.

Source:

  • https://github.com/rap2hpoutre/fast-excel/pull/166
  • https://github.com/rap2hpoutre/fast-excel/issues/188
  • https://github.com/rap2hpoutre/fast-excel/issues/183
  • https://github.com/rap2hpoutre/fast-excel/issues/176

rap2hpoutre avatar Oct 27 '20 05:10 rap2hpoutre

Although, it seems working for most of the column except for the price column. I have code like:

if($impact != ''){
    $formatter = new \NumberFormatter('en_US', \NumberFormatter::CURRENCY);
    $impact =  $formatter->formatCurrency((double)$impact, 'USD');
}

Or, am I missing something here?

inquisitive-stha avatar Nov 15 '20 14:11 inquisitive-stha