2017 © Pedro Peláez
 

library builder

A wrapper for the PHP Excel library to help you quickly build reports

image

iter8/builder

A wrapper for the PHP Excel library to help you quickly build reports

  • Friday, July 27, 2018
  • by yesdevnull
  • Repository
  • 3 Watchers
  • 0 Stars
  • 15 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 5 Open issues
  • 11 Versions
  • 0 % Grown

The README.md

Builder

A wrapper for the PHPExcel and Spout libraries to help you quickly build Excel reports., (*1)

Requirements

  • Silex ~2.x

Example Usage

$app['builder.default']   = 'spout'; // or 'phpexcel'
$app['builder.cache_dir'] = '/var/cache';

$app->register(new BuilderServiceProvider());
// --- OR ---
$app->register(
    new BuilderServiceProvider(),
    [
        'builder.default'   => 'phpexcel',
        'builder.cache_dir' => '/var/cache',
    ]
);
$builder = $app['builder'];

$reportArray = [
    [
        'Column 1' => 'Some Data',
        'Column B' => 'Some Other Data',
    ],
    [
        'Column 1' => 'Some Data 2',
        'Column B' => 'Some Other Data 2',
    ],
];

$builder->setSheets($reportArray);

$builder->setCreator('Workflow');
$builder->setTitle('Day Report');
$builder->setSheetTitles(['Data']);
$builder->setDescription('The Workflow Day Report');
$builder->setFilename('Workflow-Day_Report_' . $startDate->format('d_m_Y'));

// use generate() to output headers and force file download.
$builder->generate();

// use generateExcel() to create the file.
$builder->generateExcel();

Both Builders are available under the $app['builders'] key, but $app['builder'] will be the default builder you specify., (*2)

PHPExcel

Accessible via $app['builders']['phpexcel']., (*3)

Spout

Accessible via $app['builders']['spout']., (*4)

Feature Parity

Feature PHPExcel Spout
Cell Alignment Yes No
Auto-sizing Columns Yes No
Custom Column Widths Yes No
Document Properties Yes No
Header Styling Yes Yes
Multiple Sheets Yes Yes

Development

Todo

  • Allow both caching when building a report as well as short term or perm-caching to a configured location.

Testing

Minimal tests can be performed with PHPUnit., (*5)

Unit Tests

composer test or ./vendor/bin/phpunit, (*6)

Code Coverage

composer coverage, (*7)

These will be available in ./builder_coverage., (*8)

The Versions

27/07 2018

3.x-dev

3.9999999.9999999.9999999-dev https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

MIT

The Requires

 

The Development Requires

silex excel phpexcel reports spout

27/07 2018

3.0.3

3.0.3.0 https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

MIT

The Requires

 

The Development Requires

silex excel phpexcel reports spout

27/07 2018

3.0.2

3.0.2.0 https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

silex excel phpexcel reports spout

18/07 2018

dev-master

9999999-dev https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

silex excel phpexcel reports spout

18/07 2018

3.0.1

3.0.1.0 https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

silex excel phpexcel reports spout

19/10 2017

2.0.0

2.0.0.0 https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

silex excel phpexcel reports spout

19/10 2017

2.x-dev

2.9999999.9999999.9999999-dev https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

silex excel phpexcel reports spout

15/08 2017

1.0.0

1.0.0.0 https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

excel phpexcel reports spout

21/06 2017

1.x-dev

1.9999999.9999999.9999999-dev https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

excel phpexcel reports spout

21/06 2017

dev-develop

dev-develop https://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

proprietary

The Requires

 

The Development Requires

excel phpexcel reports spout

05/07 2016

0.0.7

0.0.7.0 http://github.com/iter8-au/builder

A wrapper for the PHP Excel library to help you quickly build reports

  Sources   Download

The Requires

 

phpexcel reports