Commit 13cd796d authored by Chenu Denis's avatar Chenu Denis

[fix] Put the good name for the attched report file

parent ace96382
......@@ -8,7 +8,7 @@
* @copyright 2017 Réseau en scène Languedoc-Roussillon <https://www.reseauenscene.fr/>
* @copyright 2015 Ingeus <http://www.ingeus.fr/>
* @license AGPL v3
* @version 1.6.1
* @version 1.6.2
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
......@@ -670,7 +670,7 @@ class pdfReport extends PluginBase {
);
$oResponse=Response::model($this->_iSurveyId)->find('id=:id',array(':id'=>$this->_iResponseId));
$oResponse->$sAnswerColumn=ls_json_encode($aAnswer);
//~ $oResponse->$sAnswerCountColumn=1;
$oResponse->$sAnswerCountColumn=1;
if(!$oResponse->save()){
Yii::log($oResponse->getErrors(),'error','application.plugins.pdfReport');
}
......@@ -702,7 +702,10 @@ class pdfReport extends PluginBase {
$oSurvey=Survey::model()->findByPk($this->_iSurveyId);
$aMessage=$this->_getEmailContent($aQuestionsAttributes['pdfReportSendByEmailContent']);
$sFile=$this->_getPdfFileName($oQuestion->title);
$aAttachments = array($this->_getPdfFileName($oQuestion->title));
$aAttachments = array(array(
$this->_getPdfFileName($oQuestion->title),
$this->_getPdfSavedFileName($oQuestion),
));
/* Add LS attachments */
if($aQuestionsAttributes['pdfReportSendByEmailAttachment']) {
$aAttachments = array_merge($this->_getEmailAttachements($aQuestionsAttributes['pdfReportSendByEmailContent']),$aAttachments);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment