Version 4.6.0
This commit is contained in:
1 parent
f79dcf067a
commit
517a5e1f70
2036 files changed
+110041
-26162
No files matched your search
@@ -1412,7 +1412,6 @@ class _Cms extends Core
|
||||
|
||||
switch( $data['type'] )
|
||||
{
|
||||
case 'CheckboxSet':
|
||||
case 'Member':
|
||||
if ( $data['multiple'] )
|
||||
{
|
||||
@@ -1440,6 +1439,7 @@ class _Cms extends Core
|
||||
case 'Address':
|
||||
case 'Codemirror':
|
||||
case 'Select':
|
||||
case 'CheckboxSet':
|
||||
case 'Youtube':
|
||||
case 'Spotify':
|
||||
case 'Soundcloud':
|
||||
@@ -1469,7 +1469,19 @@ class _Cms extends Core
|
||||
|
||||
if ( isset( $data['max_length'] ) AND $data['max_length'] )
|
||||
{
|
||||
$columnDefinition['length'] = $data['max_length'];
|
||||
if( $data['max_length'] > 255 )
|
||||
{
|
||||
$columnDefinition['type'] = 'MEDIUMTEXT';
|
||||
|
||||
if( isset( $columnDefinition['length'] ) )
|
||||
{
|
||||
unset( $columnDefinition['length'] );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$columnDefinition['length'] = $data['max_length'];
|
||||
}
|
||||
}
|
||||
|
||||
\IPS\Db::i()->addColumn( "cms_custom_database_{$inserted_id}", $columnDefinition );
|
||||
@@ -1819,7 +1831,7 @@ class _Cms extends Core
|
||||
$this->software->app->addLink( $inserted_id, $id, 'cms_database_categories' );
|
||||
|
||||
\IPS\Db::i()->update( 'cms_database_categories', array( "category_parent_id" => $inserted_id ), array( "category_conv_parent=?", $id ) );
|
||||
\IPS\Db::i()->insert( 'core_permission_index', array( 'app' => 'cms', 'perm_type' => 'categories', 'perm_type_id' => $inserted_id, 'perm_view' => '' ) );
|
||||
\IPS\Db::i()->insert( 'core_permission_index', array( 'app' => 'cms', 'perm_type' => 'categories_' . $info['category_database_id'], 'perm_type_id' => $inserted_id, 'perm_view' => '' ) );
|
||||
|
||||
\IPS\Lang::saveCustom( 'cms', "content_cat_name_{$inserted_id}", $info['category_name'] );
|
||||
\IPS\Lang::saveCustom( 'cms', "content_cat_name_{$inserted_id}_desc", $desc );
|
||||
|
||||
Reference in new issue
Block a user