text: -- phpMyAdmin SQL Dump
  -- version 5.0.1
  -- https://www.phpmyadmin.net/
  --
  -- Servidor: 127.0.0.1
  -- Tiempo de generación: 28-07-2020 a las 22:52:00
  -- Versión del servidor: 10.4.11-MariaDB
  -- Versión de PHP: 7.4.2
  
  SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
  SET AUTOCOMMIT = 0;
  START TRANSACTION;
  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 */;
  
  --
  -- Base de datos: `pruebatecnica`
  --
  
  -- --------------------------------------------------------
  
  --
  -- Estructura de tabla para la tabla `categorias`
  --
  
  CREATE TABLE `categorias` (
    `id` bigint(20) UNSIGNED NOT NULL,
    `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `label` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
    `created_at` timestamp NULL DEFAULT NULL,
    `updated_at` timestamp NULL DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
  
  --
  -- Volcado de datos para la tabla `categorias`
  --
  
  INSERT INTO `categorias` (`id`, `name`, `label`, `created_at`, `updated_at`) VALUES
  (1, 'frutas', NULL, '2020-07-26 06:41:44', '2020-07-26 06:41:44'),
  (2, 'verduras', NULL, '2020-07-26 06:56:43', '2020-07-26 06:56:43');
  
  -- --------------------------------------------------------
  
  --
  -- Estructura de tabla para la tabla `categorias_productos`
  --
  
  CREATE TABLE `categorias_productos` (
    `productos_id` bigint(20) UNSIGNED NOT NULL,
    `categorias_id` bigint(20) UNSIGNED NOT NULL,
    `created_at` timestamp NULL DEFAULT NULL,
    `updated_at` timestamp NULL DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
  
  --
  -- Volcado de datos para la tabla `categorias_productos`
  --
  
  INSERT INTO `categorias_productos` (`productos_id`, `categorias_id`, `created_at`, `updated_at`) VALUES
  (1, 1, '2020-07-26 06:50:30', '2020-07-28 17:36:55'),
  (2, 1, '2020-07-26 07:08:21', '2020-07-28 17:37:27'),
  (3, 2, '2020-07-26 07:00:24', '2020-07-26 07:00:24'),
  (6, 1, '2020-07-26 08:05:34', '2020-07-28 06:27:43'),
  (7, 1, '2020-07-28 17:38:04', '2020-07-28 17:38:04');
  
  -- --------------------------------------------------------
  
  --
  -- Estructura de tabla para la tabla `failed_jobs`
  --
  
  CREATE TABLE `failed_jobs` (
    `id` bigint(20) UNSIGNED NOT NULL,
    `connection` text COLLATE utf8mb4_unicode_ci NOT NULL,
    `queue` text COLLATE utf8mb4_unicode_ci NOT NULL,
    `payload` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
    `exception` longtext COLLATE utf8mb4_unicode_ci NOT NULL,
    `failed_at` timestamp NOT NULL DEFAULT current_timestamp()
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
  
  -- --------------------------------------------------------
  
  --
  -- Estructura de tabla para la tabla `migrations`
  --
  
  CREATE TABLE `migrations` (
    `id` int(10) UNSIGNED NOT NULL,
    `migration` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `batch` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
  
  --
  -- Volcado de datos para la tabla `migrations`
  --
  
  INSERT INTO `migrations` (`id`, `migration`, `batch`) VALUES
  (1, '2014_10_12_000000_create_users_table', 1),
  (2, '2014_10_12_100000_create_password_resets_table', 1),
  (3, '2019_08_19_000000_create_failed_jobs_table', 1),
  (4, '2020_07_24_144323_add_image_users_table', 1),
  (5, '2020_07_25_153741_create_productos_table', 1),
  (6, '2020_07_25_200612_add_image_productos_table', 1),
  (7, '2020_07_26_080150_create_categorias_tables', 1),
  (8, '2020_07_28_080607_add_date_users_table', 2);
  
  -- --------------------------------------------------------
  
  --
  -- Estructura de tabla para la tabla `password_resets`
  --
  
  CREATE TABLE `password_resets` (
    `email` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `token` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `created_at` timestamp NULL DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
  
  -- --------------------------------------------------------
  
  --
  -- Estructura de tabla para la tabla `productos`
  --
  
  CREATE TABLE `productos` (
    `id` bigint(20) UNSIGNED NOT NULL,
    `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `descripcion` text COLLATE utf8mb4_unicode_ci NOT NULL,
    `inicio` date NOT NULL,
    `fin` date NOT NULL,
    `precio` decimal(8,2) NOT NULL,
    `imagen` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
    `created_at` timestamp NULL DEFAULT NULL,
    `updated_at` timestamp NULL DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
  
  --
  -- Volcado de datos para la tabla `productos`
  --
  
  INSERT INTO `productos` (`id`, `name`, `descripcion`, `inicio`, `fin`, `precio`, `imagen`, `created_at`, `updated_at`) VALUES
  (1, 'Manzana', 'Fruta', '2020-07-26', '2020-07-27', '2.30', '6.jpg', '2020-07-26 06:39:50', '2020-07-28 17:36:55'),
  (2, 'Naranja', 'Fruta', '2020-07-28', '2020-07-29', '5.64', '5.jpg', '2020-07-26 06:58:19', '2020-07-28 17:37:27'),
  (3, 'Lechuga', 'Verdura', '2020-07-26', '2020-07-27', '2.00', '7.jpg', '2020-07-26 06:59:34', '2020-07-26 06:59:34'),
  (6, 'Uva', 'Uva Roja', '2020-07-25', '2020-07-27', '2.00', '9.jpg', '2020-07-26 08:05:34', '2020-07-28 06:27:44'),
  (7, 'Pera', 'Fruta', '2020-07-28', '2020-07-29', '2.30', NULL, '2020-07-28 17:38:04', '2020-07-28 17:38:04');
  
  -- --------------------------------------------------------
  
  --
  -- Estructura de tabla para la tabla `users`
  --
  
  CREATE TABLE `users` (
    `id` bigint(20) UNSIGNED NOT NULL,
    `name` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `email` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `fecha` date DEFAULT NULL,
    `email_verified_at` timestamp NULL DEFAULT NULL,
    `imagen` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
    `password` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
    `remember_token` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
    `created_at` timestamp NULL DEFAULT NULL,
    `updated_at` timestamp NULL DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
  
  --
  -- Volcado de datos para la tabla `users`
  --
  
  INSERT INTO `users` (`id`, `name`, `email`, `fecha`, `email_verified_at`, `imagen`, `password`, `remember_token`, `created_at`, `updated_at`) VALUES
  (1, 'Alejandro Largo', 'prova@prova.com', '1997-05-21', NULL, '0.jpg', '$2y$10$urLAkBLpC7y.eMiKCueNquRppR4AB/KAEC5uv1GwzKcVYTLrrzABa', NULL, '2020-07-26 06:38:52', '2020-07-28 17:30:35'),
  (2, 'daniel', 'daniel@prova.com', '1990-04-30', NULL, '1.jpg', '$2y$10$8ZRpaRqQQiiU/NLHbxDSheCp9/qfqIHthEB2owbpn5KxND5/v/onC', NULL, '2020-07-26 06:52:03', '2020-07-28 17:36:18'),
  (3, 'Estiven', 'estiven@prova.com', '1988-11-28', NULL, '04.png', '$2y$10$h2juE7BKhCi.Cdxx4Fb.HO/eNnUHI9KPBSPAGJCk7fyOthnDlDTne', NULL, '2020-07-28 06:19:53', '2020-07-28 06:24:18');
  
  --
  -- Índices para tablas volcadas
  --
  
  --
  -- Indices de la tabla `categorias`
  --
  ALTER TABLE `categorias`
    ADD PRIMARY KEY (`id`);
  
  --
  -- Indices de la tabla `categorias_productos`
  --
  ALTER TABLE `categorias_productos`
    ADD PRIMARY KEY (`productos_id`),
    ADD KEY `categoria_producto_categoria_id_foreign` (`categorias_id`);
  
  --
  -- Indices de la tabla `failed_jobs`
  --
  ALTER TABLE `failed_jobs`
    ADD PRIMARY KEY (`id`);
  
  --
  -- Indices de la tabla `migrations`
  --
  ALTER TABLE `migrations`
    ADD PRIMARY KEY (`id`);
  
  --
  -- Indices de la tabla `password_resets`
  --
  ALTER TABLE `password_resets`
    ADD KEY `password_resets_email_index` (`email`);
  
  --
  -- Indices de la tabla `productos`
  --
  ALTER TABLE `productos`
    ADD PRIMARY KEY (`id`);
  
  --
  -- Indices de la tabla `users`
  --
  ALTER TABLE `users`
    ADD PRIMARY KEY (`id`),
    ADD UNIQUE KEY `users_email_unique` (`email`);
  
  --
  -- AUTO_INCREMENT de las tablas volcadas
  --
  
  --
  -- AUTO_INCREMENT de la tabla `categorias`
  --
  ALTER TABLE `categorias`
    MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;
  
  --
  -- AUTO_INCREMENT de la tabla `failed_jobs`
  --
  ALTER TABLE `failed_jobs`
    MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT;
  
  --
  -- AUTO_INCREMENT de la tabla `migrations`
  --
  ALTER TABLE `migrations`
    MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=9;
  
  --
  -- AUTO_INCREMENT de la tabla `productos`
  --
  ALTER TABLE `productos`
    MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8;
  
  --
  -- AUTO_INCREMENT de la tabla `users`
  --
  ALTER TABLE `users`
    MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;
  
  --
  -- Restricciones para tablas volcadas
  --
  
  --
  -- Filtros para la tabla `categorias_productos`
  --
  ALTER TABLE `categorias_productos`
    ADD CONSTRAINT `categoria_producto_categoria_id_foreign` FOREIGN KEY (`categorias_id`) REFERENCES `categorias` (`id`) ON DELETE CASCADE,
    ADD CONSTRAINT `categoria_producto_producto_id_foreign` FOREIGN KEY (`productos_id`) REFERENCES `productos` (`id`) ON DELETE CASCADE;
  COMMIT;
  
  /*!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 */;
  