-- phpMyAdmin SQL Dump
-- version 4.5.1
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: Nov 02, 2017 at 09:46 AM
-- Server version: 10.1.16-MariaDB
-- PHP Version: 7.0.9

SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";


/*!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 utf8mb4 */;

--
-- Database: `eternity`
--

-- --------------------------------------------------------

--
-- Table structure for table `category`
--

CREATE TABLE `category` (
  `id` int(11) NOT NULL,
  `name` varchar(500) NOT NULL,
  `createdAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updatedAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `category`
--

INSERT INTO `category` (`id`, `name`, `createdAt`, `updatedAt`) VALUES
(1, 'health', '2017-10-30 10:26:57', '2017-10-30 10:26:57'),
(2, 'fitness', '2017-10-30 10:26:57', '2017-10-30 10:26:57'),
(3, 'nutrition', '2017-10-30 10:27:17', '2017-10-30 10:27:17'),
(4, 'products', '2017-10-30 10:27:17', '2017-10-30 10:27:17'),
(5, 'health info', '2017-10-30 10:27:29', '2017-10-30 10:27:29');

-- --------------------------------------------------------

--
-- Table structure for table `documentsandvideos`
--

CREATE TABLE `documentsandvideos` (
  `id` int(11) NOT NULL,
  `category_id` int(11) NOT NULL,
  `subcategory_id` int(11) NOT NULL,
  `type_category_id` int(11) DEFAULT NULL,
  `name` varchar(500) NOT NULL,
  `videourl` varchar(500) NOT NULL,
  `pdffile` varchar(500) NOT NULL,
  `createdAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updatedAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `documentsandvideos`
--

INSERT INTO `documentsandvideos` (`id`, `category_id`, `subcategory_id`, `type_category_id`, `name`, `videourl`, `pdffile`, `createdAt`, `updatedAt`) VALUES
(8, 1, 1, 1, 'myfile2', '', 'user2-160x160.jpg', '2017-11-01 09:39:04', '2017-11-01 09:39:04'),
(9, 2, 3, 14, 'my videos', 'https://www.youtube.com/watch?v=2dFcYWpWfS8', '', '2017-11-02 07:05:24', '2017-11-02 07:05:24'),
(10, 2, 4, NULL, 'youga image', '', 'ManDoingYoga_0.jpg', '2017-11-02 07:11:48', '2017-11-02 07:11:48'),
(11, 3, 7, NULL, 'Breakfast', '', 'breakfast.jpg', '2017-11-02 07:42:21', '2017-11-02 07:42:21');

-- --------------------------------------------------------

--
-- Table structure for table `sub_category`
--

CREATE TABLE `sub_category` (
  `id` int(11) NOT NULL,
  `category_id` int(11) NOT NULL,
  `name` varchar(500) NOT NULL,
  `createdAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updatedAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `sub_category`
--

INSERT INTO `sub_category` (`id`, `category_id`, `name`, `createdAt`, `updatedAt`) VALUES
(1, 1, 'health reports', '2017-10-30 11:17:09', '2017-10-30 11:17:09'),
(2, 1, 'health graphs', '2017-10-30 11:17:09', '2017-10-30 11:17:09'),
(3, 2, 'workout videos', '2017-10-30 11:17:39', '2017-10-30 11:17:39'),
(4, 2, 'yoga videos', '2017-10-30 11:17:39', '2017-10-30 11:17:39'),
(5, 2, 'zumba videos', '2017-10-30 11:18:03', '2017-10-30 11:18:03'),
(6, 2, 'your activity', '2017-10-30 11:18:03', '2017-10-30 11:18:03'),
(7, 3, 'breakfast', '2017-10-30 11:19:37', '2017-10-30 11:19:37'),
(8, 3, 'morning snacks', '2017-10-30 11:19:37', '2017-10-30 11:19:37'),
(9, 3, 'lunch', '2017-10-30 11:20:00', '2017-10-30 11:20:00'),
(10, 3, 'lunch snacks', '2017-10-30 11:20:00', '2017-10-30 11:20:00'),
(11, 3, 'dinner', '2017-10-30 11:20:07', '2017-10-30 11:20:07');

-- --------------------------------------------------------

--
-- Table structure for table `type_category`
--

CREATE TABLE `type_category` (
  `id` int(11) NOT NULL,
  `category_id` int(11) NOT NULL,
  `subcategory_id` int(11) NOT NULL,
  `name` varchar(500) NOT NULL,
  `createdAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updatedAt` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `type_category`
--

INSERT INTO `type_category` (`id`, `category_id`, `subcategory_id`, `name`, `createdAt`, `updatedAt`) VALUES
(1, 1, 1, 'Eternity Report', '2017-10-30 12:30:37', '2017-10-30 13:06:02'),
(2, 1, 1, 'Bioclid', '2017-10-30 12:30:37', '2017-10-30 12:30:37'),
(3, 1, 1, 'BloodReport', '2017-10-30 12:31:09', '2017-10-30 12:31:09'),
(4, 1, 1, 'Inbody520', '2017-10-30 12:31:09', '2017-10-30 12:31:09'),
(5, 1, 1, 'Oligoscan', '2017-10-30 12:31:44', '2017-10-30 12:31:44'),
(6, 1, 1, 'Thyroflex', '2017-10-30 12:31:44', '2017-10-30 12:31:44'),
(7, 1, 2, 'General Health', '2017-10-30 12:32:44', '2017-10-30 12:32:44'),
(8, 1, 2, 'Heart', '2017-10-30 12:32:44', '2017-10-30 12:32:44'),
(9, 1, 2, 'Nutrition', '2017-10-30 12:33:24', '2017-10-30 12:33:24'),
(10, 1, 2, 'Hormones', '2017-10-30 12:33:24', '2017-10-30 12:33:24'),
(11, 1, 2, 'Fitness', '2017-10-30 12:33:52', '2017-10-30 12:33:52'),
(12, 1, 2, 'Toxins', '2017-10-30 12:33:52', '2017-10-30 12:33:52'),
(13, 1, 2, 'Cancer', '2017-10-30 12:34:02', '2017-10-30 12:34:02'),
(14, 2, 3, 'Abs', '2017-10-30 12:35:28', '2017-10-30 12:35:28'),
(15, 2, 3, 'Lower body', '2017-10-30 12:35:28', '2017-10-30 12:35:28'),
(16, 2, 3, 'upper body', '2017-10-30 12:35:55', '2017-10-30 12:35:55'),
(17, 2, 3, 'total body', '2017-10-30 12:35:55', '2017-10-30 12:35:55'),
(18, 2, 3, 'cardio', '2017-10-30 12:36:05', '2017-10-30 12:36:05'),
(19, 2, 6, 'day', '2017-10-30 12:37:16', '2017-10-30 12:37:16'),
(20, 2, 6, 'week', '2017-10-30 12:37:16', '2017-10-30 12:37:16'),
(21, 2, 6, 'month', '2017-10-30 12:37:31', '2017-10-30 12:37:31'),
(22, 2, 6, 'year', '2017-10-30 12:37:31', '2017-10-30 12:37:31');

--
-- Indexes for dumped tables
--

--
-- Indexes for table `category`
--
ALTER TABLE `category`
  ADD PRIMARY KEY (`id`);

--
-- Indexes for table `documentsandvideos`
--
ALTER TABLE `documentsandvideos`
  ADD PRIMARY KEY (`id`);

--
-- Indexes for table `sub_category`
--
ALTER TABLE `sub_category`
  ADD PRIMARY KEY (`id`);

--
-- Indexes for table `type_category`
--
ALTER TABLE `type_category`
  ADD PRIMARY KEY (`id`);

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `category`
--
ALTER TABLE `category`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;
--
-- AUTO_INCREMENT for table `documentsandvideos`
--
ALTER TABLE `documentsandvideos`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=12;
--
-- AUTO_INCREMENT for table `sub_category`
--
ALTER TABLE `sub_category`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=12;
--
-- AUTO_INCREMENT for table `type_category`
--
ALTER TABLE `type_category`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=23;
/*!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 */;
