CC-5038: Silan error: list index out of range
-fixed
This commit is contained in:
parent
afb55c7b51
commit
d1f655d79d
3 changed files with 12 additions and 9 deletions
|
@ -971,14 +971,14 @@ class ApiController extends Zend_Controller_Action
|
|||
$this->_helper->viewRenderer->setNoRender(true);
|
||||
|
||||
$request = $this->getRequest();
|
||||
$data = json_decode($request->getParam('data'));
|
||||
$data = json_decode($request->getParam('data'), $assoc = true);
|
||||
|
||||
foreach ($data as $pair) {
|
||||
list($id, $info) = $pair;
|
||||
// TODO : move this code into model -- RG
|
||||
$cuein = $info->cuein;
|
||||
$cueout = $info->cueout;
|
||||
$file = Application_Model_StoredFile::Recall($p_id = $id)->getPropelOrm();
|
||||
$cuein = isset($info['cuein']) ? $info['cuein'] : 0;
|
||||
$cueout = isset($info['cueout']) ? $info['cueout'] : $file->getDbLength();
|
||||
$file->setDbCuein($cuein);
|
||||
$file->setDbCueout($cueout);
|
||||
$file->setDbSilanCheck(true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue