mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-06 18:21:39 +09:00
Merge branch 'rhymix:master' into master
This commit is contained in:
commit
b894362419
48 changed files with 664 additions and 379 deletions
|
|
@ -3307,16 +3307,23 @@ class DocumentController extends Document
|
|||
}
|
||||
|
||||
// Get document_srl
|
||||
$srls = explode(',',Context::get('srls'));
|
||||
for($i = 0; $i < count($srls); $i++)
|
||||
$srls = Context::get('srls');
|
||||
if (is_array($srls))
|
||||
{
|
||||
$srl = trim($srls[$i]);
|
||||
|
||||
if(!$srl) continue;
|
||||
|
||||
$document_srls[] = $srl;
|
||||
$document_srls = array_map('intval', $srls);
|
||||
}
|
||||
else
|
||||
{
|
||||
$document_srls = array_map('intval', explode(',', $srls));
|
||||
}
|
||||
|
||||
$document_srls = array_unique(array_filter($document_srls, function($srl) {
|
||||
return $srl > 0;
|
||||
}));
|
||||
if (!count($document_srls))
|
||||
{
|
||||
return;
|
||||
}
|
||||
if(!count($document_srls)) return;
|
||||
|
||||
// Get module_srl of the documents
|
||||
$args = new stdClass;
|
||||
|
|
@ -3787,7 +3794,17 @@ Content;
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* A typo of updateUploadedCount, maintained for backward compatibility.
|
||||
*
|
||||
* @deprecated
|
||||
*/
|
||||
public function updateUploaedCount($document_srl_list)
|
||||
{
|
||||
return $this->updateUploadedCount($document_srl_list);
|
||||
}
|
||||
|
||||
public function updateUploadedCount($document_srl_list)
|
||||
{
|
||||
if(!is_array($document_srl_list))
|
||||
{
|
||||
|
|
@ -3803,7 +3820,8 @@ Content;
|
|||
|
||||
foreach($document_srl_list as $document_srl)
|
||||
{
|
||||
if(!$document_srl = (int) $document_srl)
|
||||
$document_srl = (int)$document_srl;
|
||||
if ($document_srl <= 0)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
|
@ -3823,7 +3841,7 @@ Content;
|
|||
return;
|
||||
}
|
||||
|
||||
$this->updateUploaedCount($file->upload_target_srl);
|
||||
$this->updateUploadedCount($file->upload_target_srl);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue