Laravel excel Import when header have merged cells

3.4k views Asked by At

It seams that http://www.maatwebsite.nl/laravel-excel/docs can't figure out how to handle simple merged cells.

Importing excel file like this:

Excel::load($tmp_path, function($reader) {
  $reader->dd();
})->get();

See image bellow where is problem:

enter image description here

2

There are 2 answers

0
RomkaLTU On BEST ANSWER

Just checked configuration and we can set 'slugged_with_count' in heading, so results become like picture bellow. Or disable heading and rely on columns order.

enter image description here

0
Nitish Kumar On

You'll have to read this file out differently, you can't use the simple import methods. You have to read it out per coordinate, example of the native PHPExcel methods:

http://docs.typo3.org/typo3cms/extensions/phpexcel_library/1.7.4/manual.html#_Toc237519900

Also you can check the link: https://github.com/Maatwebsite/Laravel-Excel/issues/442

Hope this helps.