core/set/install/main_sqlite3.php

114 lines
2.6 KiB
PHP
Raw Normal View History

2023-08-14 09:15:58 +05:00
<?php
/*
\DB::set("CREATE TABLE IF NOT EXISTS `tovar_category` (
`id` INTEGER PRIMARY KEY NOT NULL,
`title` TEXT,
`status` INTEGER,
`category` INTEGER,
`keywords` TEXT,
`description` TEXT,
`hide` INTEGER,
`img` TEXT,
`show_mnu` INTEGER,
`banner` TEXT,
`file_img` TEXT,
`code` TEXT,
`code_p` TEXT,
`partner` TEXT,
`kolvo` INTEGER
)");
\DB::set("CREATE TABLE IF NOT EXISTS `tovar` (
`id` INTEGER PRIMARY KEY NOT NULL,
`title` TEXT,
`txt` TEXT,
`keywords` TEXT,
`artikul` TEXT,
`description` TEXT,
`tovar_id_1c` TEXT,
`tovar_cat_1c` TEXT,
`status` INTEGER,
`category` INTEGER,
`countImg` INTEGER,
`partner` TEXT,
`json` TEXT,
`brand_id` INTEGER,
`check_img` INTEGER,
`code` TEXT,
`linkimg` TEXT,
`zakazEnable` INTEGER,
`donor` TEXT,
`cena` INTEGER,
`cena_d` INTEGER,
`multicat` TEXT
)");
CREATE TABLE IF NOT EXISTS `tasks` (
`id` INTEGER PRIMARY KEY NOT NULL,
`user_id` INTEGER,
`isp_id` INTEGER,
`mod` TEXT,
`task` TEXT,
`t` TEXT,
`srok` TEXT,
`status` INTEGER,
FOREIGN KEY (`user_id`) REFERENCES `users` (`id`), FOREIGN KEY (`isp_id`) REFERENCES `users` (`id`) )
CREATE TABLE IF NOT EXISTS `tasks` (
`id` INTEGER PRIMARY KEY NOT NULL,
`user_id` INTEGER,
`isp_id` INTEGER,
`mod` TEXT,
`task` TEXT,
`t` TEXT,
`srok` TEXT,
`status` INTEGER,
FOREIGN KEY (`user_id`) REFERENCES `users` (`id`), FOREIGN KEY (`isp_id`) REFERENCES `users` (`id`) )
DROP TABLE IF EXISTS `tovar`;
CREATE TABLE `tovar` (
`id` int(10) NOT NULL AUTO_INCREMENT,
`title` varchar(300) DEFAULT NULL,
`txt` longtext DEFAULT NULL,
`keywords` longtext DEFAULT NULL,
`artikul` varchar(50) DEFAULT NULL,
`description` longtext DEFAULT NULL,
`tovar_id_1c` varchar(100) DEFAULT NULL,
`tovar_cat_1c` varchar(100) DEFAULT NULL,
`status` int(1) DEFAULT NULL,
`category` varchar(200) DEFAULT NULL,
`countImg` int(2) DEFAULT NULL,
`partner` varchar(100) DEFAULT NULL,
`json` longtext DEFAULT NULL,
`brand_id` int(10) DEFAULT NULL,
`check_img` int(1) DEFAULT NULL,
`code` varchar(30) DEFAULT NULL,
`linkimg` longtext DEFAULT NULL,
`zakazEnable` int(1) DEFAULT 1,
`donor` text DEFAULT NULL,
`cena` float DEFAULT NULL,
`cena_d` varchar(50) DEFAULT NULL,
`multicat` varchar(200) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci
FOREIGN KEY (`user_id`) REFERENCES `users` (`id`), FOREIGN KEY (`isp_id`) REFERENCES `users` (`id`) );
*/
?>