// Update Accounting for the return display html

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@10145 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
vSchoener
2011-11-15 17:11:53 +00:00
parent 3689276b37
commit adae213cec
4 changed files with 19 additions and 13 deletions
@@ -138,9 +138,9 @@ class AdminAccountingExportControllerCore extends AdminController
private function checkRights()
{
if (!is_writeable($this->downloadDir))
$this->prevent['errors'][] = $this->l('The download folder doesn\'t have the sufficient right…');
$this->_errors[] = $this->l('The download folder doesn\'t have the sufficient right…');
if (!($this->fd = fopen($this->downloadFile, 'w+')))
$this->prevent['errors'][] = $this->l('The file can\'t be opened or created, please check the right');
$this->_errors[] = $this->l('The file can\'t be opened or created, please check the right');
@chmod($this->downloadFile, 0777);
}
@@ -222,7 +222,7 @@ class AdminAccountingExportControllerCore extends AdminController
{
$this->checkRights();
if (!count($this->prevent['errors']) && $this->fd !== NULL)
if (!count($this->_errors) && $this->fd !== NULL)
{
$buffer = '';
foreach($this->exportTypeList[$this->exportSelected]['fields'] as $key => $translation)
@@ -238,6 +238,7 @@ class AdminAccountingExportControllerCore extends AdminController
$buffer .= $val.';';
fwrite($this->fd, rtrim($buffer, ';')."\r\n");
}
$this->confirmations[] = $this->l('Export has been successfully done');
}
}