Version 4.1.2

This commit is contained in:
Neo committed 2025-12-19 05:32:19 -08:00
1 parent 3ba79295ee
commit 28bd025b35
1131 files changed
+63658 -20579

No files matched your search

@@ -138,17 +138,22 @@ class _blocks extends \IPS\Node\Controller
}
catch ( \OutOfRangeException $e ) { }
}
$disabled = array();
foreach( \IPS\cms\Databases::databases() as $db )
{
if ( $db->page_id )
{
$plugins[ \IPS\Member::loggedIn()->language()->addToStack( 'cms_db_feed_title' ) ][ 'db_feed_' . $db->id ] = \IPS\Member::loggedIn()->language()->addToStack( 'cms_db_feed_block_with_name', NULL, array( 'sprintf' => array( $db->_title ) ) );
}
else
{
$disabled[] = 'db_feed_' . $db->id;
$plugins[ \IPS\Member::loggedIn()->language()->addToStack( 'cms_db_feed_title' ) ][ 'db_feed_' . $db->id ] = \IPS\Member::loggedIn()->language()->addToStack( 'cms_db_feed_block_with_name_disabled', NULL, array( 'sprintf' => array( $db->_title ) ) );
}
}
$form->add( new \IPS\Helpers\Form\Select( 'content_block_add_type_plugin', null, false, array( 'options' => $plugins ), NULL, NULL, NULL, 'content_block_add_type_plugin' ) );
$form->add( new \IPS\Helpers\Form\Select( 'content_block_add_type_plugin', null, false, array( 'options' => $plugins, 'disabled' => $disabled ), NULL, NULL, NULL, 'content_block_add_type_plugin' ) );
$form->add( new \IPS\Helpers\Form\Radio( 'content_block_add_custom_type', 'editor', TRUE, array(
'options' => array( 'editor' => 'content_block_add_custom_type_wysiwyg',
@@ -180,4 +185,18 @@ class _blocks extends \IPS\Node\Controller
\IPS\Output::i()->output .= \IPS\Theme::i()->getTemplate( 'global', 'core', 'admin' )->block( \IPS\Member::loggedIn()->language()->addToStack('content_block_block_add'), $form, FALSE );
\IPS\Output::i()->title = \IPS\Member::loggedIn()->language()->addToStack('content_block_block_add');
}
/**
* View external embed options
*
* @return void
*/
public function embedOptions()
{
$block = \IPS\cms\Blocks\Block::load( \IPS\Request::i()->id );
$embedKey = md5( $block->key . time() );
/* Output */
\IPS\Output::i()->title = "External Embed"; // @todo
\IPS\Output::i()->output = \IPS\Theme::i()->getTemplate( 'global', 'core', 'admin' )->block( '', \IPS\Theme::i()->getTemplate( 'blocks', 'cms', 'admin' )->embedCode( $block, $embedKey ) );;
}
}