mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-08 19:21:40 +09:00
parent
b068dfe4ba
commit
3b7d0da0f6
2 changed files with 18 additions and 24 deletions
|
|
@ -600,23 +600,20 @@ class commentItem extends Object
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Get thumbnai_type information from document module's configuration
|
// Get thumbnail type information from document module's configuration
|
||||||
if(!in_array($thumbnail_type, array('crop', 'ratio', 'none')))
|
|
||||||
{
|
|
||||||
$config = $GLOBALS['__document_config__'];
|
$config = $GLOBALS['__document_config__'];
|
||||||
if(!$config)
|
if(!$config)
|
||||||
{
|
{
|
||||||
$oDocumentModel = getModel('document');
|
$config = $GLOBALS['__document_config__'] = getModel('document')->getDocumentConfig();
|
||||||
$config = $oDocumentModel->getDocumentConfig();
|
|
||||||
$GLOBALS['__document_config__'] = $config;
|
|
||||||
}
|
}
|
||||||
$thumbnail_type = $config->thumbnail_type ?: 'crop';
|
if ($config->thumbnail_type === 'none')
|
||||||
}
|
|
||||||
|
|
||||||
if ($thumbnail_type === 'none')
|
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if(!in_array($thumbnail_type, array('crop', 'ratio', 'none')))
|
||||||
|
{
|
||||||
|
$thumbnail_type = $config->thumbnail_type ?: 'crop';
|
||||||
|
}
|
||||||
|
|
||||||
if($this->isSecret() && !$this->isGranted())
|
if($this->isSecret() && !$this->isGranted())
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -879,23 +879,20 @@ class documentItem extends Object
|
||||||
// Return false if the document doesn't exist
|
// Return false if the document doesn't exist
|
||||||
if(!$this->document_srl) return;
|
if(!$this->document_srl) return;
|
||||||
|
|
||||||
// Get thumbnai_type information from document module's configuration
|
// Get thumbnail type information from document module's configuration
|
||||||
if(!in_array($thumbnail_type, array('crop', 'ratio', 'none')))
|
|
||||||
{
|
|
||||||
$config = $GLOBALS['__document_config__'];
|
$config = $GLOBALS['__document_config__'];
|
||||||
if(!$config)
|
if(!$config)
|
||||||
{
|
{
|
||||||
$oDocumentModel = getModel('document');
|
$config = $GLOBALS['__document_config__'] = getModel('document')->getDocumentConfig();
|
||||||
$config = $oDocumentModel->getDocumentConfig();
|
|
||||||
$GLOBALS['__document_config__'] = $config;
|
|
||||||
}
|
}
|
||||||
$thumbnail_type = $config->thumbnail_type ?: 'crop';
|
if ($config->thumbnail_type === 'none')
|
||||||
}
|
|
||||||
|
|
||||||
if ($thumbnail_type === 'none')
|
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if(!in_array($thumbnail_type, array('crop', 'ratio', 'none')))
|
||||||
|
{
|
||||||
|
$thumbnail_type = $config->thumbnail_type ?: 'crop';
|
||||||
|
}
|
||||||
|
|
||||||
if($this->isSecret() && !$this->isGranted())
|
if($this->isSecret() && !$this->isGranted())
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue