Version 4.7.13

This commit is contained in:
Neo committed 2025-12-19 16:14:56 -08:00
1 parent fd22d99e69
commit 7124a02564
954 files changed
+29277 -59308

No files matched your search

+27 -5
View File
@@ -23,6 +23,8 @@ if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
*/
class _Page extends \IPS\Node\Model implements \IPS\Node\Permissions
{
use \IPS\Content\ViewUpdates;
/**
* @brief [ActiveRecord] Multiton Store
*/
@@ -593,7 +595,7 @@ class _Page extends \IPS\Node\Model implements \IPS\Node\Permissions
try
{
$testFolder = \IPS\cms\Pages\Folder::load( $val, 'folder_name' );
/* Ok, we have a folder, but is it on the same tree as us ?*/
if ( \intval( \IPS\Request::i()->page_folder_id ) == $testFolder->parent_id )
{
@@ -603,11 +605,10 @@ class _Page extends \IPS\Node\Model implements \IPS\Node\Permissions
}
catch ( \OutOfRangeException $e )
{
/* Nothing with the same name, so that's proper good that is */
}
/* If we hit here, we don't have an existing name so that's good */
if ( ! \IPS\Request::i()->page_folder_id and \IPS\cms\Pages\Page::isFurlCollision( $val ) )
if ( \IPS\cms\Pages\Page::isFurlCollision( $val ) )
{
throw new \InvalidArgumentException('content_folder_name_furl_collision_pages_app');
}
@@ -848,7 +849,28 @@ class _Page extends \IPS\Node\Model implements \IPS\Node\Permissions
{
return TRUE;
}
/* What about system folders? */
try
{
$folder = \IPS\cms\Pages\Folder::load( \IPS\Request::i()->page_folder_id );
$base = \IPS\ROOT_PATH . '/' . $folder->path . '/';
}
catch ( \OutOfRangeException $e )
{
$base = \IPS\ROOT_PATH . '/';
}
if( is_dir( $base . $path ) )
{
return TRUE;
}
if( \IPS\Request::i()->page_folder_id )
{
return FALSE;
}
$defaultApplication = \IPS\Db::i()->select( 'app_directory', 'core_applications', 'app_default=1' )->first();
foreach( \IPS\Application::applications() as $key => $app )