Index: branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit_block.tpl
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit_block.tpl (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit_block.tpl (revision 1402)
@@ -0,0 +1,96 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+
+
+
\ No newline at end of file
Index: branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit_base.tpl
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit_base.tpl (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit_base.tpl (revision 1402)
@@ -0,0 +1,96 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+
+
+
\ No newline at end of file
Index: branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit.tpl
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit.tpl (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_edit.tpl (revision 1402)
@@ -0,0 +1,70 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
Index: branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_tabs.tpl
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_tabs.tpl (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_tabs.tpl (revision 1402)
@@ -0,0 +1,13 @@
+
\ No newline at end of file
Index: branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_list.tpl
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_list.tpl (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/admin_templates/stylesheets/stylesheets_list.tpl (revision 1402)
@@ -0,0 +1,68 @@
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+
+
+
\ No newline at end of file
Index: branches/unlabeled/unlabeled-1.1.2/core/units/stylesheets/stylesheets_config.php
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/units/stylesheets/stylesheets_config.php (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/units/stylesheets/stylesheets_config.php (revision 1402)
@@ -0,0 +1,87 @@
+ 'css',
+ 'ItemClass' => Array('class'=>'kDBItem','file'=>'','build_event'=>'OnItemBuild'),
+ 'ListClass' => Array('class'=>'kDBList','file'=>'','build_event'=>'OnListBuild'),
+ 'EventHandlerClass' => Array('class'=>'InpDBEventHandler','file'=>'','build_event'=>'OnBuild'),
+ 'TagProcessorClass' => Array('class'=>'kDBTagProcessor','file'=>'','build_event'=>'OnBuild'),
+ 'AutoLoad' => true,
+ 'Hooks' => Array(),
+ 'QueryString' => Array(
+ 1 => 'id',
+ 2 => 'page',
+ 3 => 'event',
+ 4 => 'mode',
+ ),
+ 'IDField' => 'StylesheetId',
+
+ 'StatusField' => Array('Enabled'),
+
+ 'TitleField' => 'Name',
+
+ 'TitlePresets' => Array(
+ 'default' => Array( 'new_status_labels' => Array('css'=>'!la_title_Adding_Stylesheet!'),
+ 'edit_status_labels' => Array('css'=>'!la_title_Editing_Stylesheet!'),
+ 'new_titlefield' => Array('css'=>'!la_title_New_Stylesheet!'),
+ ),
+
+ 'styles_list' => Array('prefixes' => Array('css_List'), 'format' => "!la_title_Stylesheets! (#css_recordcount#)"),
+
+ 'stylesheets_edit' => Array('prefixes' => Array('css'), 'format' => "#css_status# '#css_titlefield#' - !la_title_General!"),
+
+ 'base_styles' => Array('prefixes' => Array('css','selectors.base_List'), 'format' => "#css_status# '#css_titlefield#' - !la_title_BaseStyles! (#selectors.base_recordcount#)"),
+
+ 'block_styles' => Array('prefixes' => Array('css','selectors.block_List'), 'format' => "#css_status# '#css_titlefield#' - !la_title_BlockStyles! (#selectors.block_recordcount#)"),
+ ),
+
+ 'TableName' => TABLE_PREFIX.'Stylesheets',
+ 'SubItems' => Array('selectors'),
+
+ 'FilterMenu' => Array(
+ 'Groups' => Array(
+ Array('mode' => 'AND', 'filters' => Array(0,1), 'type' => WHERE_FILTER),
+ ),
+
+ 'Filters' => Array(
+ 0 => Array('label' =>'la_Enabled', 'on_sql' => '', 'off_sql' => '%1$s.Enabled != 1' ),
+ 1 => Array('label' => 'la_Disabled', 'on_sql' => '', 'off_sql' => '%1$s.Enabled != 0' ),
+ )
+ ),
+
+ 'AutoDelete' => true,
+ 'AutoClone' => true,
+
+ 'ListSQLs' => Array( ''=>'SELECT * FROM %s',
+ ), // key - special, value - list select sql
+ 'ItemSQLs' => Array( ''=>'SELECT * FROM %s',
+ ),
+ 'ListSortings' => Array(
+ '' => Array(
+ 'Sorting' => Array('Name' => 'asc'),
+ )
+ ),
+ 'Fields' => Array(
+ 'StylesheetId' => Array(),
+ 'Name' => Array('type' => 'string','not_null' => '1','default' => ''),
+ 'Description' => Array('type' => 'string','not_null' => '1','default' => ''),
+ 'AdvancedCSS' => Array('type' => 'string','not_null' => '1','default' => ''),
+ 'Enabled' => Array('type' => 'int', 'formatter'=>'kOptionsFormatter', 'options'=>Array(0 => 'la_Disabled', 1 => 'la_Enabled'), 'use_phrases' => 1, 'not_null' => '1','default' => 0),
+ ),
+
+ 'VirtualFields' => Array(),
+
+ 'Grids' => Array(
+ 'Default' => Array(
+ 'Icons' => Array('default'=>'icon16_custom.gif',0=>'icon16_style_disabled.gif',1=>'icon16_style.gif'),
+ 'Fields' => Array(
+ 'Name' => Array( 'title'=>'la_col_Name', 'data_block' => 'grid_checkbox_td'),
+ 'Description' => Array( 'title'=>'la_col_Description', 'data_block' => 'grid_description_td' ),
+ 'Enabled' => Array( 'title'=>'la_col_Status' ),
+ ),
+
+ ),
+ ),
+ );
+
+?>
\ No newline at end of file
Index: branches/unlabeled/unlabeled-1.1.2/core/units/selectors/selectors_event_handler.php
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/units/selectors/selectors_event_handler.php (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/units/selectors/selectors_event_handler.php (revision 1402)
@@ -0,0 +1,37 @@
+getObject();
+ switch ($event->Special)
+ {
+ case 'base':
+ $object->addFilter('type_filter', '%1$s.Type = 1');
+ break;
+
+ case 'block':
+ $object->addFilter('type_filter', '%1$s.Type = 2');
+ break;
+ }
+ }
+
+ /**
+ * Get's special of main item for linking with subitem
+ *
+ * @param kEvent $event
+ * @return string
+ */
+ function getMainSpecial(&$event)
+ {
+ return '';
+ }
+ }
+
+?>
\ No newline at end of file
Index: branches/unlabeled/unlabeled-1.1.2/core/units/selectors/selectors_config.php
===================================================================
diff -u
--- branches/unlabeled/unlabeled-1.1.2/core/units/selectors/selectors_config.php (revision 0)
+++ branches/unlabeled/unlabeled-1.1.2/core/units/selectors/selectors_config.php (revision 1402)
@@ -0,0 +1,70 @@
+ 'selectors',
+ 'ItemClass' => Array('class'=>'kDBItem','file'=>'','build_event'=>'OnItemBuild'),
+ 'ListClass' => Array('class'=>'kDBList','file'=>'','build_event'=>'OnListBuild'),
+ 'EventHandlerClass' => Array('class'=>'SelectorsEventHandler','file'=>'selectors_event_handler.php','build_event'=>'OnBuild'),
+ 'TagProcessorClass' => Array('class'=>'kDBTagProcessor','file'=>'','build_event'=>'OnBuild'),
+ 'AutoLoad' => true,
+ 'Hooks' => Array(),
+ 'QueryString' => Array(
+ 1 => 'id',
+ 2 => 'page',
+ 3 => 'event',
+ ),
+ 'IDField' => 'SelectorId',
+
+ 'TitleField' => 'Name',
+
+ 'TableName' => TABLE_PREFIX.'StylesheetSelectors',
+
+ 'ForeignKey' => 'StylesheetId',
+ 'ParentTableKey' => 'StylesheetId',
+ 'ParentPrefix' => 'css',
+ 'AutoDelete' => true,
+ 'AutoClone' => true,
+
+ 'ListSQLs' => Array( ''=>'SELECT * FROM %s',
+ ), // key - special, value - list select sql
+ 'ItemSQLs' => Array( ''=>'SELECT * FROM %s',
+ ),
+ 'ListSortings' => Array(
+ '' => Array(
+ 'Sorting' => Array('Name' => 'asc'),
+ )
+ ),
+ 'Fields' => Array(
+ 'SelectorId' => Array(),
+ 'StylesheetId' => Array('type' => 'int','not_null' => '1','default' => '0'),
+ 'Name' => Array('type' => 'string','not_null' => '1','default' => ''),
+ 'SelectorName' => Array('type' => 'string','not_null' => '1','default' => ''),
+ 'SelectorData' => Array('type' => 'string','not_null' => '1','default' => ''),
+ 'Description' => Array('type' => 'string','not_null' => '1','default' => ''),
+ 'Type' => Array('type' => 'int', 'formatter'=>'kOptionsFormatter', 'options'=>Array( 1 => 'la_BaseSelectors', 2 => 'la_BlockSelectors'), 'use_phrases' => 1, 'not_null' => '1','default' => '0'),
+ 'ParentId' => Array('type' => 'int','not_null' => '1','default' => '0'),
+ ),
+
+ 'VirtualFields' => Array(),
+
+ 'Grids' => Array(
+ 'Default' => Array(
+ 'Icons' => Array('default'=>'icon16_selector.gif'),
+ 'Fields' => Array(
+ 'Name' => Array( 'title'=>'la_col_Name', 'data_block' => 'grid_checkbox_td'),
+ 'Description' => Array( 'title'=>'la_col_Description', 'data_block' => 'grid_description_td' ),
+ ),
+ ),
+
+ 'BlockStyles' => Array(
+ 'Icons' => Array('default'=>'icon16_selector.gif'),
+ 'Fields' => Array(
+ 'Name' => Array( 'title'=>'la_col_Name', 'data_block' => 'grid_checkbox_td'),
+ 'SelectorName' => Array( 'title'=>'la_col_SelectorName'),
+ 'Description' => Array( 'title'=>'la_col_Description', 'data_block' => 'grid_description_td' ),
+ ),
+ ),
+ ),
+ );
+
+?>
\ No newline at end of file