partner/application/controllers/ReportController.php

34 lines
624 B
PHP
Raw Normal View History

2013-10-15 17:30:21 +02:00
<?php
class ReportController extends Zend_Controller_Action
{
public function indexAction()
{
$request = $this->getRequest();
//Get parameters
$siren = $request->getParam('siren');
//Control the prestation with the database - inject additionnaly parameters
//Launch report
$report = new Scores_Partner_Report('indiscore3', '552144503', 'mricois', 'ju2loh6o');
$html = $report->getContent();
file_put_contents('test.html', $html);
//Write links to get the HTML and/or PDF
}
public function pdfAction()
{
//Unlink the file
//if HTML exist, make a pdf
//Distribute it to the output
}
}