You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
1.2 KiB
42 lines
1.2 KiB
9 years ago
|
<?php
|
||
|
|
||
|
/**
|
||
|
* AVE.cms - Модуль Архив новостей
|
||
|
*
|
||
|
* @package AVE.cms
|
||
|
* @subpackage module_Newsarchive
|
||
|
* @filesource
|
||
|
*/
|
||
|
|
||
|
/**
|
||
|
* mySQL-запросы для установки, обновления и удаления модуля
|
||
|
*/
|
||
|
|
||
|
$module_sql_install = array();
|
||
|
$module_sql_deinstall = array();
|
||
|
$module_sql_update = array();
|
||
|
|
||
|
$module_sql_deinstall[] = "DROP TABLE IF EXISTS CPPREFIX_module_newsarchive;";
|
||
|
|
||
|
$module_sql_install[] = "CREATE TABLE CPPREFIX_module_newsarchive (
|
||
|
`id` mediumint(5) unsigned NOT NULL auto_increment,
|
||
|
`newsarchive_name` char(255) NOT NULL default '',
|
||
|
`newsarchive_rubrics` char(255) NOT NULL default '',
|
||
|
`newsarchive_show_days` enum('1','0') NOT NULL default '1',
|
||
|
`newsarchive_show_empty` enum('1','0') NOT NULL default '1',
|
||
|
PRIMARY KEY (`id`)
|
||
|
) ENGINE=MyISAM DEFAULT CHARSET=utf8;";
|
||
|
|
||
|
// Обновление модуля
|
||
|
$module_sql_update[] = "
|
||
|
UPDATE
|
||
|
`CPPREFIX_module`
|
||
|
SET
|
||
|
ModuleAveTag = '" . $modul['ModuleAveTag'] . "',
|
||
|
ModulePHPTag = '" . $modul['ModulePHPTag'] . "',
|
||
|
ModuleVersion = '" . $modul['ModuleVersion'] . "'
|
||
|
WHERE
|
||
|
ModuleSysName = '" . $modul['ModuleSysName'] . "'
|
||
|
LIMIT 1;
|
||
|
";
|
||
|
?>
|