Skip to content

Commit

Permalink
Convert to php
Browse files Browse the repository at this point in the history
  • Loading branch information
flack committed Jun 26, 2024
1 parent e6fae13 commit 69958c1
Show file tree
Hide file tree
Showing 117 changed files with 5,183 additions and 5,049 deletions.
2 changes: 1 addition & 1 deletion lib/midcom/admin/folder/config/config.inc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'schemadb' => 'file:/midcom/config/metadata_dm2_default.inc',
'schemadbs_folder' => [
'default' => 'file:/midcom/admin/folder/config/schemadb_folder.inc',
'default' => 'file:/midcom/admin/folder/config/schemadb_folder.php',
],

//false means the parent topic's component will be suggested by default,
Expand Down
74 changes: 0 additions & 74 deletions lib/midcom/admin/folder/config/schemadb_folder.inc

This file was deleted.

77 changes: 77 additions & 0 deletions lib/midcom/admin/folder/config/schemadb_folder.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
<?php
return [
'default' => [
'description' => 'topic',
'l10n_db' => 'midcom.admin.folder',
'fields' => [
'name' => [
'title' => 'url name',
'storage' => 'name',
'type' => 'urlname',
'widget' => 'text',
],
'title' => [
'title' => 'title',
'storage' => 'extra',
'type' => 'text',
'widget' => 'text',
'required' => true,
],
'component' => [
'title' => 'component',
'storage' => 'component',
'type' => 'select',
'type_config' => [
'options' => midcom_admin_folder_management::list_components(midcom_core_context::get()->get_key(MIDCOM_CONTEXT_COMPONENT)),
],
'widget' => 'select',
],
'style' => [
'title' => 'style template',
'storage' => 'style',
'type' => 'select',
'type_config' => [
'options' => midcom_admin_folder_management::list_styles(),
],
'widget' => 'select',
],
'style_inherit' => [
'title' => 'inherit style',
'storage' => 'styleInherit',
'type' => 'boolean',
'widget' => 'checkbox',
],
'nav_order' => [
'title' => 'nav order',
'storage' => [
'location' => 'configuration',
'domain' => 'midcom.helper.nav',
'name' => 'navorder',
],
'type' => 'select',
'type_config' => [
'options' => [
MIDCOM_NAVORDER_DEFAULT => 'default sort order',
MIDCOM_NAVORDER_TOPICSFIRST => 'folders first',
MIDCOM_NAVORDER_ARTICLESFIRST => 'pages first',
MIDCOM_NAVORDER_SCORE => 'by score',
],
],
'widget' => 'select',
],
'page_class' => [
'title' => 'folder page class',
'storage' => [
'location' => 'configuration',
'domain' => 'midcom.services.metadata',
'name' => 'page_class',
],
'type' => 'text',
'widget' => 'text',
'write_privilege' => [
'privilege' => 'midcom.admin.folder:template_management',
],
],
],
]
];
2 changes: 1 addition & 1 deletion lib/midcom/core/nullcomponent/config/config.inc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
'enable_folder_code_execution' => false,
'schemadb_wizard' => 'file:/midcom/core/nullcomponent/config/schemadb_wizard.inc',
'schemadb_wizard' => 'file:/midcom/core/nullcomponent/config/schemadb_wizard.php',
72 changes: 0 additions & 72 deletions lib/midcom/core/nullcomponent/config/schemadb_wizard.inc

This file was deleted.

75 changes: 75 additions & 0 deletions lib/midcom/core/nullcomponent/config/schemadb_wizard.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
<?php
return [
'default' => [
'description' => 'wizard',
'fields' => [
'existing' => [
'title' => 'topic',
'type' => 'select',
'type_config' => [
'options' => [],
'allow_other' => true,
'require_corresponding_option' => false,
],
'widget' => 'autocomplete',
'widget_config' => [
'class' => 'midcom_db_topic',
'titlefield' => 'extra',
'id_field' => 'guid',
'searchfields' => [
'title',
'extra',
'component',
'name',
],
'constraints' => [
[
'field' => 'up',
'op' => '=',
'value' => 0,
],
],
'result_headers' => [
[
'name' => 'name',
], [
'name' => 'component',
],
],
'orders' => [
[
'title' => 'ASC',
], [
'extra' => 'ASC',
], [
'name' => 'ASC',
],
],
],
'start_fieldset' => [
'title' => 'select existing folder'
],
'end_fieldset' => 1
],
'title' => [
'title' => 'title',
'storage' => 'extra',
'type' => 'text',
'widget' => 'text',
'start_fieldset' => [
'title' => 'create new folder'
],
],
'component' => [
'title' => 'component',
'storage' => 'component',
'type' => 'select',
'type_config' => [
'options' => midcom_admin_folder_management::list_components(midcom_core_context::get()->get_key(MIDCOM_CONTEXT_COMPONENT)),
],
'widget' => 'select',
'end_fieldset' => 1
],
],
]
];
2 changes: 1 addition & 1 deletion lib/midcom/helper/imagepopup/config/config.inc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
'schemadb' => 'file:/midcom/helper/imagepopup/config/schemadb.inc',
'schemadb' => 'file:/midcom/helper/imagepopup/config/schemadb.php',
22 changes: 0 additions & 22 deletions lib/midcom/helper/imagepopup/config/schemadb.inc

This file was deleted.

25 changes: 25 additions & 0 deletions lib/midcom/helper/imagepopup/config/schemadb.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
<?php
return [
'default' => [
'description' => 'image popup schema',
'l10n_db' => 'midcom.helper.imagepopup',
'fields' => [
'midcom_helper_imagepopup_images' => [
'title' => 'images',
'storage' => null,
'type' => 'images',
'widget' => 'images',
'widget_config' => [
'set_name_and_title_on_upload' => false
],
],

'midcom_helper_imagepopup_files' => [
'title' => 'files',
'storage' => null,
'type' => 'blobs',
'widget' => 'downloads',
]
]
]
];
6 changes: 3 additions & 3 deletions lib/midgard/admin/asgard/config/config.inc
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,11 @@
'bearing',
'accuracy',
],
'schemadb_permissions' => 'file:/midgard/admin/asgard/config/schemadb_permissions.inc',
'schemadb_shell' => 'file:/midgard/admin/asgard/config/schemadb_shell.inc',
'schemadb_permissions' => 'file:/midgard/admin/asgard/config/schemadb_permissions.php',
'schemadb_shell' => 'file:/midgard/admin/asgard/config/schemadb_shell.php',

// User preferences
'schemadb_preferences' => 'file:/midgard/admin/asgard/config/schemadb_preferences.inc',
'schemadb_preferences' => 'file:/midgard/admin/asgard/config/schemadb_preferences.php',

// User interface
'tinymce_enabled' => true,
Expand Down
Loading

0 comments on commit 69958c1

Please sign in to comment.