Version 4.1.19

This commit is contained in:
Neo committed 2025-12-19 05:38:56 -08:00
1 parent 28bd025b35
commit 2bd5025018
2674 files changed
+233518 -77766

No files matched your search

@@ -2,9 +2,10 @@
/**
* @brief Fields Model
* @author <a href='http://www.invisionpower.com'>Invision Power Services, Inc.</a>
* @copyright (c) 2001 - SVN_YYYY Invision Power Services, Inc.
* @copyright (c) 2001 - 2016 Invision Power Services, Inc.
* @license http://www.invisionpower.com/legal/standards/
* @package IPS Social Suite
* @package IPS Community Suite
* @subpackage Content
* @since 31 March 2014
* @version SVN_VERSION_NUMBER
*/
@@ -39,7 +40,7 @@ class _fields extends \IPS\Node\Controller
$this->nodeClass = '\IPS\cms\Fields' . \IPS\Request::i()->database_id;
\IPS\Dispatcher::i()->checkAcpPermission( 'fields_manage' );
\IPS\Dispatcher::i()->checkAcpPermission( 'cms_fields_manage' );
parent::execute();
}
@@ -50,6 +51,12 @@ class _fields extends \IPS\Node\Controller
*/
protected function manage()
{
/* If we lose the database id because of a log in, do something more useful than an uncaught exception */
if ( ! isset( \IPS\Request::i()->database_id ) )
{
\IPS\Output::i()->redirect( \IPS\Http\Url::internal( "app=cms&module=databases" ) );
}
parent::manage();
$url = \IPS\Http\Url::internal( "app=cms&module=databases&controller=fields&database_id=" . \IPS\Request::i()->database_id );
@@ -66,9 +73,10 @@ class _fields extends \IPS\Node\Controller
function() use ( $fixed, $url )
{
$rows = array();
foreach( $fixed as $field => $data )
{
$description = ( $field === 'record_publish_date' ) ? \IPS\Member::loggedIn()->language()->addToStack( 'content_fields_fixed_record_publish_date_desc' ) : NULL;
$rows[ $field ] = \IPS\Theme::i()->getTemplate( 'trees', 'core' )->row( $url, $field, \IPS\Member::loggedIn()->language()->addToStack( 'content_fields_fixed_'. $field ), FALSE, array(
'permission' => array(
'icon' => 'lock',
@@ -76,7 +84,7 @@ class _fields extends \IPS\Node\Controller
'link' => $url->setQueryString( array( 'field' => $field, 'do' => 'fixedPermissions' ) ),
'data' => array( 'ipsDialog' => '', 'ipsDialog-title' => \IPS\Member::loggedIn()->language()->addToStack( 'content_fields_fixed_'. $field ) )
)
), NULL, NULL, NULL, NULL, ( empty( $data['visible'] ) ? FALSE : TRUE ) );
), $description, NULL, NULL, NULL, ( empty( $data['visible'] ) ? FALSE : TRUE ) );
}
return $rows;