text: -- MySQL dump 10.13  Distrib 5.5.28, for Win32 (x86)
  --
  -- Host: localhost    Database: yii2advanced
  -- ------------------------------------------------------
  -- Server version	5.5.28
  
  /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
  /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
  /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
  /*!40101 SET NAMES utf8 */;
  /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
  /*!40103 SET TIME_ZONE='+00:00' */;
  /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
  /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
  /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
  /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
  
  --
  -- Table structure for table `article`
  --
  
  DROP TABLE IF EXISTS `article`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!40101 SET character_set_client = utf8 */;
  CREATE TABLE `article` (
    `id` int(11) NOT NULL AUTO_INCREMENT,
    `category_id` int(11) NOT NULL DEFAULT '0',
    `user_id` int(11) NOT NULL,
    `title` varchar(255) NOT NULL,
    `slug` varchar(255) NOT NULL,
    `content` text NOT NULL,
    `comments_count` int(11) NOT NULL DEFAULT '0',
    `meta_title` varchar(255) DEFAULT NULL,
    `meta_description` varchar(255) DEFAULT NULL,
    `meta_keywords` varchar(255) DEFAULT NULL,
    `created_at` datetime NOT NULL,
    `updated_at` datetime NOT NULL,
    `file` varchar(255) DEFAULT NULL,
    `miaoshu` text,
    PRIMARY KEY (`id`),
    UNIQUE KEY `article_title_unique` (`title`),
    UNIQUE KEY `article_slug_unique` (`slug`),
    KEY `article_category_id_index` (`category_id`),
    CONSTRAINT `article_category_f` FOREIGN KEY (`category_id`) REFERENCES `category` (`id`) ON DELETE CASCADE
  ) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `article`
  --
  
  LOCK TABLES `article` WRITE;
  /*!40000 ALTER TABLE `article` DISABLE KEYS */;
  INSERT INTO `article` VALUES (1,1,1,'文章1','122','3344',0,'','','','2015-03-11 17:25:38','2015-03-11 17:25:38','/uploads/images/73CC5B88789C.jpg','<p>2222</p>'),(2,1,1,'4556','6677','77888',0,'','','','2015-03-13 06:55:19','2015-03-13 06:55:19',NULL,NULL),(3,1,1,'334','5566','5777',0,'','','','2015-03-13 17:57:53','2015-03-13 17:57:53',NULL,'<p>dfgyy<img src=\"/ueditor/php/upload/image/20150313/1426246008271917.jpg\" title=\"1426246008271917.jpg\" alt=\"Penguins.jpg\"/></p>'),(4,1,1,'阿萨德的','344','677889',0,'','','','2015-03-14 19:30:30','2015-03-14 19:30:30','/uploads/images/Hydrangeas.jpg','<p>反复各环节<img src=\"/ueditor/php/upload/image/20150314/1426332627502482.jpg\" title=\"1426332627502482.jpg\" alt=\"Penguins.jpg\"/></p>'),(5,1,1,'123','444','rrrtt',0,'','','','2015-03-15 09:59:14','2015-03-15 09:59:14','/uploads/images/Koala.jpg','<p>ffgg</p>'),(6,1,1,'asd','ffgg','ghhh',0,'','','','2015-03-15 10:02:13','2015-03-15 10:02:13','/uploads/images/Chrysanthemum.jpg','<p>hhhj</p>'),(7,1,1,'123666','556','3344',0,'','','','2015-03-15 10:34:38','2015-03-15 10:34:38','/uploads/images/Hardware003.jpg','<p>666</p>'),(8,1,1,'adrr','tyyuu','yyyy',0,'','','','2015-03-15 10:38:49','2015-03-15 10:38:49','/uploads/images/Chrysanthemum.jpg','<p>yuuyt</p>'),(9,1,1,'asd334','fgg','ertt',0,'','','','2015-03-15 12:12:29','2015-03-15 12:12:29','/uploads/images/png-1009.png','<p>rty</p>'),(10,1,1,'美女1','1223444','为二人',0,'','','','2015-03-16 12:05:47','2015-03-16 12:05:47','/uploads/images/7CA8FE0BFA0A(1).jpg','<p>2334</p>');
  /*!40000 ALTER TABLE `article` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `category`
  --
  
  DROP TABLE IF EXISTS `category`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!40101 SET character_set_client = utf8 */;
  CREATE TABLE `category` (
    `id` int(11) NOT NULL AUTO_INCREMENT,
    `parentid` int(11) NOT NULL,
    `cname` varchar(32) NOT NULL,
    `status` smallint(6) NOT NULL DEFAULT '10',
    `created_at` int(11) NOT NULL,
    `updated_at` int(11) NOT NULL,
    PRIMARY KEY (`id`)
  ) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `category`
  --
  
  LOCK TABLES `category` WRITE;
  /*!40000 ALTER TABLE `category` DISABLE KEYS */;
  INSERT INTO `category` VALUES (1,0,'分类1',10,122,334),(4,0,'分类2',10,1426063868,1426063868),(5,1,'分类1-1',10,1426063902,1426063902),(6,4,'分类2-1',10,1426063917,1426063917),(7,0,'分类3',10,1426064131,1426064131);
  /*!40000 ALTER TABLE `category` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `image`
  --
  
  DROP TABLE IF EXISTS `image`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!40101 SET character_set_client = utf8 */;
  CREATE TABLE `image` (
    `id` int(11) NOT NULL AUTO_INCREMENT,
    `filePath` varchar(400) NOT NULL,
    `itemId` int(20) NOT NULL,
    `isMain` int(1) DEFAULT NULL,
    `modelName` varchar(150) NOT NULL,
    `urlAlias` varchar(400) NOT NULL,
    PRIMARY KEY (`id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `image`
  --
  
  LOCK TABLES `image` WRITE;
  /*!40000 ALTER TABLE `image` DISABLE KEYS */;
  /*!40000 ALTER TABLE `image` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `migration`
  --
  
  DROP TABLE IF EXISTS `migration`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!40101 SET character_set_client = utf8 */;
  CREATE TABLE `migration` (
    `version` varchar(180) NOT NULL,
    `apply_time` int(11) DEFAULT NULL,
    PRIMARY KEY (`version`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `migration`
  --
  
  LOCK TABLES `migration` WRITE;
  /*!40000 ALTER TABLE `migration` DISABLE KEYS */;
  INSERT INTO `migration` VALUES ('m000000_000000_base',1426062076),('m130524_201442_init',1426062079),('m140622_111540_create_image_table',1426248613),('m150216_075514_create_news_table',1426062079),('m150307_071228_test',1426062079),('m150307_080300_add_classname_col_to_testtable',1426062080),('m150307_084149_create_category_table',1426062080),('m150307_085438_create_article_table',1426062082);
  /*!40000 ALTER TABLE `migration` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `news`
  --
  
  DROP TABLE IF EXISTS `news`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!40101 SET character_set_client = utf8 */;
  CREATE TABLE `news` (
    `id` int(11) NOT NULL AUTO_INCREMENT,
    `username` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `auth_key` varchar(32) COLLATE utf8_unicode_ci NOT NULL,
    `password_hash` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `password_reset_token` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
    `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `status` smallint(6) NOT NULL DEFAULT '10',
    `created_at` int(11) NOT NULL,
    `updated_at` int(11) NOT NULL,
    PRIMARY KEY (`id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `news`
  --
  
  LOCK TABLES `news` WRITE;
  /*!40000 ALTER TABLE `news` DISABLE KEYS */;
  /*!40000 ALTER TABLE `news` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `test`
  --
  
  DROP TABLE IF EXISTS `test`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!40101 SET character_set_client = utf8 */;
  CREATE TABLE `test` (
    `id` int(11) NOT NULL AUTO_INCREMENT,
    `username` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `auth_key` varchar(32) COLLATE utf8_unicode_ci NOT NULL,
    `password_hash` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `password_reset_token` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
    `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `status` smallint(6) NOT NULL DEFAULT '10',
    `created_at` int(11) NOT NULL,
    `updated_at` int(11) NOT NULL,
    `classname` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
    PRIMARY KEY (`id`)
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `test`
  --
  
  LOCK TABLES `test` WRITE;
  /*!40000 ALTER TABLE `test` DISABLE KEYS */;
  /*!40000 ALTER TABLE `test` ENABLE KEYS */;
  UNLOCK TABLES;
  
  --
  -- Table structure for table `user`
  --
  
  DROP TABLE IF EXISTS `user`;
  /*!40101 SET @saved_cs_client     = @@character_set_client */;
  /*!40101 SET character_set_client = utf8 */;
  CREATE TABLE `user` (
    `id` int(11) NOT NULL AUTO_INCREMENT,
    `username` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `auth_key` varchar(32) COLLATE utf8_unicode_ci NOT NULL,
    `password_hash` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `password_reset_token` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
    `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
    `status` smallint(6) NOT NULL DEFAULT '10',
    `created_at` int(11) NOT NULL,
    `updated_at` int(11) NOT NULL,
    PRIMARY KEY (`id`)
  ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
  /*!40101 SET character_set_client = @saved_cs_client */;
  
  --
  -- Dumping data for table `user`
  --
  
  LOCK TABLES `user` WRITE;
  /*!40000 ALTER TABLE `user` DISABLE KEYS */;
  INSERT INTO `user` VALUES (1,'admin','_XlvIAqRwx7SXcfQ4oiMpGQj-u3835-N','$2y$13$AGVL.yQRJZajqtTaeuHP/.sWsRzfiGbUiwnjh8w8BUwuaC.7frRju',NULL,'admin@qq.com',10,1426062672,1426062672);
  /*!40000 ALTER TABLE `user` ENABLE KEYS */;
  UNLOCK TABLES;
  /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
  
  /*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
  /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
  /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
  /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
  /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
  /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
  /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
  
  -- Dump completed on 2015-03-16 21:45:40
  