4.5
-- NetCat 4.5 Standard [0] component file, generated 2011-10-19 19:43:44
INSERT INTO `Class` SET `Class_Name` = 'Реклама: Баннер', `Class_Group` = 'Реклама', `DaysToHold` = '0', `AllowTags` = '0', `FormPrefix` = '$f_AdminCommon\n
', `FormSuffix` = '
', `RecordTemplate` = '$f_AdminButtons\n".($f_Img ? "
" : null)."\n".($f_Swf ? "\n\n\n\n" : null)."', `RecordsPerPage` = '0', `SortBy` = '', `RecordTemplateFull` = '', `TitleTemplate` = '', `AddTemplate` = '', `EditTemplate` = '', `AddActionTemplate` = '', `EditActionTemplate` = '', `SearchTemplate` = '', `FullSearchTemplate` = '', `SubscribeTemplate` = '', `System_Table_ID` = '0', `Settings` = 'if ($cc_settings[rand]) {$query_order = "RAND()";}\nif (!$admin_mode) {\nglobal $parent_sub_tree;\n$parentSections = array();\n\nfor ($i = 0, $n = count($parent_sub_tree) - 1; $i < $n; $i++) {\n $parentSections[] = $parent_sub_tree[$i][\'Subdivision_ID\'];\n}\n\n$where = "\n (\n (\n a.Site = 0\n AND a.Section = 0\n AND a.Component = 0\n ) \n OR \n (\n (\n (\n a.Site = " . ($current_catalogue[\'Catalogue_ID\'] ? $current_catalogue[\'Catalogue_ID\'] : -1) . "\n AND a.Section = 0 \n AND a.Component = 0\n )\n OR\n (\n";\nif (count($parentSections) > 1) {\n$where .="\n a.Section IN (".implode(\', \', $parentSections).", 9999999999)";\n} else {\n$where .="\n a.Section IN (".implode(\', \', $parentSections).")";\n}\n$where .="\n AND a.Component = 0\n )\n OR\n (\n a.Component = " . ($current_cc[\'Sub_Class_ID\'] ? $current_cc[\'Sub_Class_ID\'] : -1) . "\n )\n )\n AND\n a.Inheritance = 1\n )\n OR\n (\n (\n a.Site = " . ($current_catalogue[\'Catalogue_ID\'] ? $current_catalogue[\'Catalogue_ID\'] : -1) . "\n AND a.Section = 0 \n AND a.Component = 0\n )\n OR\n (\n a.Section = " . ($current_sub[\'Subdivision_ID\'] ? $current_sub[\'Subdivision_ID\'] : -1) . "\n AND a.Component = 0\n )\n OR\n (\n a.Component = " . ($current_cc[\'Sub_Class_ID\'] ? $current_cc[\'Sub_Class_ID\'] : -1) . "\n )\n )\n )";\n$query_where = $where;\n}', `AddCond` = 'if ($_FILES[f_Swf][error] != \'4\') {\nif (!$f_width || !$f_height) {\n$posting = null;\n$warnText = "Если вы загружаете Flash баннер, необходимо обязательно указать его ширину и высоту
";\n}\n}', `EditCond` = '', `SubscribeCond` = '', `DeleteCond` = '', `NL2BR` = '1', `UseCaptcha` = '0', `CheckActionTemplate` = '', `DeleteActionTemplate` = '', `CustomSettingsTemplate` = '$settings_array = array(\n \'rand\' => array(\n \'type\' => \'checkbox\',\n \'subtype\' => \'\',\n \'caption\' => \'Выводить баннеры в случайном порядке\'));', `ClassDescription` = '', `DeleteTemplate` = '', `ClassTemplate` = '0', `Type` = 'useful', `CacheForUser` = '0', `TitleList` = '', `UseAltTitle` = '0';
INSERT INTO `Class` SET `Class_Name` = 'Режим администрирования', `Class_Group` = 'Шаблоны компонентов', `DaysToHold` = '0', `AllowTags` = '0', `FormPrefix` = '$f_AdminCommon', `FormSuffix` = '', `RecordTemplate` = '$f_AdminButtons\n".($f_Img ? "
" : null)."\n".($f_Swf ? "\n\n\n\n" : null)."', `RecordsPerPage` = '20', `SortBy` = '', `RecordTemplateFull` = '', `TitleTemplate` = '', `AddTemplate` = '', `EditTemplate` = '', `AddActionTemplate` = '', `EditActionTemplate` = '', `SearchTemplate` = '', `FullSearchTemplate` = '', `SubscribeTemplate` = '', `System_Table_ID` = '0', `Settings` = '', `AddCond` = 'if ($_FILES[f_Swf][error] != \'4\') {\nif (!$f_width || !$f_height) {\n$posting = null;\n$warnText = "Если вы загружаете Flash баннер, необходимо обязательно указать его ширину и высоту
";\n}\n}', `EditCond` = '', `SubscribeCond` = '', `DeleteCond` = '', `NL2BR` = '1', `UseCaptcha` = '0', `CheckActionTemplate` = '', `DeleteActionTemplate` = '', `CustomSettingsTemplate` = '', `ClassDescription` = '', `DeleteTemplate` = '', `ClassTemplate` = '%INSERT_ID%', `Type` = 'inside_admin', `CacheForUser` = '0', `TitleList` = '', `UseAltTitle` = '0';
CREATE TABLE `Message%INSERT_ID%` ( `Message_ID` int(11) NOT NULL AUTO_INCREMENT, `User_ID` int(11) NOT NULL, `Subdivision_ID` int(11) NOT NULL, `Sub_Class_ID` int(11) NOT NULL, `Priority` int(11) NOT NULL DEFAULT '0', `Keyword` char(255) NOT NULL, `ncTitle` varchar(255) DEFAULT NULL, `ncKeywords` varchar(255) DEFAULT NULL, `ncDescription` text, `Checked` tinyint(4) NOT NULL DEFAULT '1', `TimeToDelete` date DEFAULT NULL, `TimeToUncheck` date DEFAULT NULL, `IP` char(15) DEFAULT NULL, `UserAgent` char(255) DEFAULT NULL, `Parent_Message_ID` int(11) NOT NULL DEFAULT '0', `Created` datetime NOT NULL, `LastUpdated` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, `LastUser_ID` int(11) NOT NULL, `LastIP` char(15) DEFAULT NULL, `LastUserAgent` char(255) DEFAULT NULL, `Img` char(255) DEFAULT NULL, `Swf` char(255) DEFAULT NULL, `Site` int(11) DEFAULT NULL, `Component` int(11) DEFAULT NULL, `Section` int(11) DEFAULT NULL, `Inheritance` tinyint(4) NOT NULL, `Link` char(255) DEFAULT NULL, `FlashVar` char(255) DEFAULT NULL, `width` int(11) DEFAULT NULL, `height` int(11) DEFAULT NULL, PRIMARY KEY (`Message_ID`), UNIQUE KEY `Sub_Class_ID` (`Sub_Class_ID`,`Message_ID`,`Keyword`), KEY `User_ID` (`User_ID`), KEY `LastUser_ID` (`LastUser_ID`), KEY `Subdivision_ID` (`Subdivision_ID`), KEY `Parent_Message_ID` (`Parent_Message_ID`)) ENGINE=MyISAM;
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'Img', 'Изображение', 6, 'image:fs2:inline', 0, 0, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'Swf', 'SWF файл Flash баннера', 6, 'fs2:inline', 0, 1, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'Site', 'Сайт', 9, 'Catalogue:Catalogue_Name', 0, 5, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'Component', 'Компонент', 9, 'Sub_Class:Sub_Class_Name', 0, 7, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'Section', 'Раздел', 9, 'Subdivision:Subdivision_Name', 0, 6, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'Inheritance', 'Наследовать в дочерних разделах', 5, '', 1, 8, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'Link', 'Ссылка', 1, '', 0, 9, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'FlashVar', 'Имя переменной flashvars для ссылки (если таковая имеется)', 1, '', 0, 2, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'width', 'Ширина Flash-баннера', 2, '', 0, 3, 0, '', 1);
INSERT INTO Field (`Class_ID`, `Field_Name`, `Description`, `TypeOfData_ID`, `Format`, `NotNull`, `Priority`, `DoSearch`, `DefaultState`, `TypeOfEdit_ID`) VALUES (%INSERT_ID%, 'height', 'Высота Flash-баннера', 2, '', 0, 4, 0, '', 1);