Fix latest merge

This commit is contained in:
Nicolas Le Goff
2014-03-23 23:04:59 +01:00
parent 5e07b68780
commit e45d7edbc3
3 changed files with 37 additions and 37 deletions

View File

@@ -68,7 +68,7 @@ class Root implements ControllerProviderInterface
*/ */
public function getDashboard(Application $app, Request $request) public function getDashboard(Application $app, Request $request)
{ {
if ('json' !== $request->getRequestFormat()) { if ('json' === $request->getRequestFormat()) {
\Session_Logger::updateClientInfos($app, 4); \Session_Logger::updateClientInfos($app, 4);
$dashboard = new \module_report_dashboard($app, $app['authentication']->getUser()); $dashboard = new \module_report_dashboard($app, $app['authentication']->getUser());
@@ -108,11 +108,11 @@ class Root implements ControllerProviderInterface
'ajax_dash' => true, 'ajax_dash' => true,
'dashboard' => null, 'dashboard' => null,
'granted_bases' => $granted, 'granted_bases' => $granted,
'home_title' => $app['phraseanet.registry']->get('GV_homeTitle'), 'home_title' => $app['conf']->get(['registry', 'general', 'title']),
'module' => 'report', 'module' => 'report',
'module_name' => 'Report', 'module_name' => 'Report',
'anonymous' => $app['phraseanet.registry']->get('GV_anonymousReport'), 'anonymous' => $app['conf']->get(['registry', 'modules', 'anonymous-report']),
'g_anal' => $app['phraseanet.registry']->get('GV_googleAnalytics'), 'g_anal' => $app['conf']->get(['registry', 'general', 'analytics']),
'ajax' => false, 'ajax' => false,
'ajax_chart' => false 'ajax_chart' => false
)); ));

View File

@@ -12,15 +12,15 @@
{% block javascript %} {% block javascript %}
<script type="text/javascript" > <script type="text/javascript" >
var usrId = '{{ app['authentication'].user.get_id }}' ; var usrId = '{{ app['authentication'].user.getId }}' ;
var language = { var language = {
valider : '{% trans "boutton::valider" %}', valider : '{{ "boutton::valider" | trans }}',
choix_collection : '{% trans "veuillez choisir au minimum une collection" %}', choix_collection : '{{ "veuillez choisir au minimum une collection" | trans }}',
annuler : '{% trans "boutton::annuler" %}', annuler : '{{ "boutton::annuler" | trans }}',
fermer : '{% trans "boutton::fermer" %}', fermer : '{{ "boutton::fermer" | trans }}',
connexion : '{% trans "report:: Connexion" %}', connexion : '{{ "report:: Connexion" | trans }}',
heure : '{% trans "report::Heures" %}' heure : '{{ "report::Heures" | trans }}'
}; };
var dashboard ={ var dashboard ={

View File

@@ -49,7 +49,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportConnexions() public function testDoReportConnexions()
{ {
self::$DI['client']->request('POST', '/report/connexions', array( self::$DI['client']->request('POST', '/report/connexions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -67,7 +67,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportConnexionsPrintCSV() public function testDoReportConnexionsPrintCSV()
{ {
self::$DI['client']->request('POST', '/report/connexions', array( self::$DI['client']->request('POST', '/report/connexions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -82,7 +82,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportConnexionsFilterColumns() public function testDoReportConnexionsFilterColumns()
{ {
self::$DI['client']->request('POST', '/report/connexions', array( self::$DI['client']->request('POST', '/report/connexions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -97,7 +97,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportConnexionsFilterResultOnOneColumn() public function testDoReportConnexionsFilterResultOnOneColumn()
{ {
self::$DI['client']->request('POST', '/report/connexions', array( self::$DI['client']->request('POST', '/report/connexions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -114,7 +114,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportConnexionsFilterConf() public function testDoReportConnexionsFilterConf()
{ {
self::$DI['client']->request('POST', '/report/connexions', array( self::$DI['client']->request('POST', '/report/connexions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -129,7 +129,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportConnexionsGroupBy() public function testDoReportConnexionsGroupBy()
{ {
self::$DI['client']->request('POST', '/report/connexions', array( self::$DI['client']->request('POST', '/report/connexions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -144,7 +144,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportQuestions() public function testDoReportQuestions()
{ {
self::$DI['client']->request('POST', '/report/questions', array( self::$DI['client']->request('POST', '/report/questions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -162,7 +162,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportQuestionsPrintCSV() public function testDoReportQuestionsPrintCSV()
{ {
self::$DI['client']->request('POST', '/report/questions', array( self::$DI['client']->request('POST', '/report/questions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -177,7 +177,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportQuestionsFilterColumns() public function testDoReportQuestionsFilterColumns()
{ {
self::$DI['client']->request('POST', '/report/questions', array( self::$DI['client']->request('POST', '/report/questions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -192,7 +192,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportQuestionsFilterResultOnOneColumn() public function testDoReportQuestionsFilterResultOnOneColumn()
{ {
self::$DI['client']->request('POST', '/report/questions', array( self::$DI['client']->request('POST', '/report/questions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -209,7 +209,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportQuestionsFilterConf() public function testDoReportQuestionsFilterConf()
{ {
self::$DI['client']->request('POST', '/report/questions', array( self::$DI['client']->request('POST', '/report/questions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -224,7 +224,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportQuestionsGroupBy() public function testDoReportQuestionsGroupBy()
{ {
self::$DI['client']->request('POST', '/report/questions', array( self::$DI['client']->request('POST', '/report/questions', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -239,7 +239,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDownloads() public function testDoReportDownloads()
{ {
self::$DI['client']->request('POST', '/report/downloads', array( self::$DI['client']->request('POST', '/report/downloads', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -257,7 +257,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDownloadsPrintCSV() public function testDoReportDownloadsPrintCSV()
{ {
self::$DI['client']->request('POST', '/report/downloads', array( self::$DI['client']->request('POST', '/report/downloads', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -272,7 +272,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDownloadsFilterColumns() public function testDoReportDownloadsFilterColumns()
{ {
self::$DI['client']->request('POST', '/report/downloads', array( self::$DI['client']->request('POST', '/report/downloads', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -287,7 +287,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDownloadsFilterResultOnOneColumn() public function testDoReportDownloadsFilterResultOnOneColumn()
{ {
self::$DI['client']->request('POST', '/report/downloads', array( self::$DI['client']->request('POST', '/report/downloads', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -304,7 +304,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDownloadsFilterConf() public function testDoReportDownloadsFilterConf()
{ {
self::$DI['client']->request('POST', '/report/downloads', array( self::$DI['client']->request('POST', '/report/downloads', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -319,7 +319,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDownloadsGroupBy() public function testDoReportDownloadsGroupBy()
{ {
self::$DI['client']->request('POST', '/report/downloads', array( self::$DI['client']->request('POST', '/report/downloads', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -334,7 +334,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDocuments() public function testDoReportDocuments()
{ {
self::$DI['client']->request('POST', '/report/documents', array( self::$DI['client']->request('POST', '/report/documents', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -353,7 +353,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDocumentsPrintCSV() public function testDoReportDocumentsPrintCSV()
{ {
self::$DI['client']->request('POST', '/report/documents', array( self::$DI['client']->request('POST', '/report/documents', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -368,7 +368,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDocumentsFilterColumns() public function testDoReportDocumentsFilterColumns()
{ {
self::$DI['client']->request('POST', '/report/documents', array( self::$DI['client']->request('POST', '/report/documents', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -383,7 +383,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDocumentsFilterResultOnOneColumn() public function testDoReportDocumentsFilterResultOnOneColumn()
{ {
self::$DI['client']->request('POST', '/report/documents', array( self::$DI['client']->request('POST', '/report/documents', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -400,7 +400,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDocumentsFilterConf() public function testDoReportDocumentsFilterConf()
{ {
self::$DI['client']->request('POST', '/report/documents', array( self::$DI['client']->request('POST', '/report/documents', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -415,7 +415,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportDocumentsGroupBy() public function testDoReportDocumentsGroupBy()
{ {
self::$DI['client']->request('POST', '/report/documents', array( self::$DI['client']->request('POST', '/report/documents', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -430,7 +430,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportClients() public function testDoReportClients()
{ {
self::$DI['client']->request('POST', '/report/clients', array( self::$DI['client']->request('POST', '/report/clients', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),
@@ -444,7 +444,7 @@ class RootTest extends \PhraseanetAuthenticatedWebTestCase
public function testDoReportClientPrintCSV() public function testDoReportClientPrintCSV()
{ {
self::$DI['client']->request('POST', '/report/clients', array( self::$DI['client']->request('POST', '/report/clients', [
'dmin' => $this->dmin->format('Y-m-d'), 'dmin' => $this->dmin->format('Y-m-d'),
'dmax' => $this->dmax->format('Y-m-d'), 'dmax' => $this->dmax->format('Y-m-d'),
'sbasid' => self::$DI['collection']->get_sbas_id(), 'sbasid' => self::$DI['collection']->get_sbas_id(),