OswardJr / Zogan_Systems

App
0 stars 0 forks source link

bd #9

Closed OswardJr closed 7 years ago

OswardJr commented 7 years ago

-- phpMyAdmin SQL Dump -- version 4.6.4 -- https://www.phpmyadmin.net/

-- Servidor: localhost -- Tiempo de generación: 12-07-2017 a las 01:05:24 -- Versión del servidor: 5.7.15-log -- Versión de PHP: 5.6.26

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 /;

-- -- Base de datos: a


-- -- Estructura de tabla para la tabla almacenes

CREATE TABLE almacenes ( id int(10) UNSIGNED NOT NULL, seccion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, cubiculo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla almac_repues

CREATE TABLE almac_repues ( almacen_id int(10) UNSIGNED NOT NULL, repuesto_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla analistas

CREATE TABLE analistas ( id int(10) UNSIGNED NOT NULL, rif varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre text COLLATE utf8mb4_unicode_ci NOT NULL, apellido text COLLATE utf8mb4_unicode_ci NOT NULL, celular varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 analistas

INSERT INTO analistas (id, rif, nombre, apellido, celular, telefono, email, status, created_at, updated_at) VALUES (1, 'J-24924739-0', 'LEONCIO', 'REQUENA', '0414-4549840', '0212-3840364', 'LEOREQUENA_14@HOTMAIL.COM', 'activo', '2017-07-03 00:46:43', '2017-07-10 21:35:51'), (2, 'J-25893478-5', 'Victor José', 'Pacheco', '0414-4549840', '0212-3840333', 'ojpr15@gmail.com', 'inactivo', '2017-07-10 17:39:28', '2017-07-10 17:50:35');


-- -- Estructura de tabla para la tabla analis_asegu

CREATE TABLE analis_asegu ( analista_id int(10) UNSIGNED NOT NULL, aseguradora_id int(10) 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 analis_asegu

INSERT INTO analis_asegu (analista_id, aseguradora_id, created_at, updated_at) VALUES (1, 1, '2017-07-03 00:46:43', '2017-07-03 00:46:43'), (2, 2, '2017-07-10 17:39:28', '2017-07-10 17:39:28');


-- -- Estructura de tabla para la tabla aseguradoras

CREATE TABLE aseguradoras ( id int(10) UNSIGNED NOT NULL, rif varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, denominacion text COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 aseguradoras

INSERT INTO aseguradoras (id, rif, denominacion, telefono, email, status, created_at, updated_at) VALUES (1, 'J-20989357-2', 'Seguros Universitas C.A', '0212-3840364', 'SEGUROSUNI@gmail.com', 'activo', '2017-07-03 00:46:13', '2017-07-03 00:46:13'), (2, 'J-25893478-5', 'Seguros Altamira C.A', '0212-3840363', 'SEGUROSALTAMIRA@gmail.com', 'activo', '2017-07-06 21:43:46', '2017-07-06 21:43:46');


-- -- Estructura de tabla para la tabla citas

CREATE TABLE citas ( id int(10) UNSIGNED NOT NULL, reparacion_id int(10) UNSIGNED NOT NULL, selec_dia date NOT NULL, hora varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla corredores

CREATE TABLE corredores ( id int(10) UNSIGNED NOT NULL, cedula varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre text COLLATE utf8mb4_unicode_ci NOT NULL, apellido text COLLATE utf8mb4_unicode_ci NOT NULL, celular varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 corredores

INSERT INTO corredores (id, cedula, nombre, apellido, celular, telefono, email, status, created_at, updated_at) VALUES (1, 'J-20989357-0', 'OSWARD', 'PACHECO', '0414-5435737', '0212-3840364', 'DFDIFH@GMAIL.COM', 'activo', '2017-07-06 06:06:21', '2017-07-06 06:06:21'), (2, 'J-20989357-9', 'PEDRO', 'PEREZ', '0416-4264859', '0212-3840333', 'PEDRO@GMAIL.COM', 'activo', '2017-07-10 19:26:30', '2017-07-10 19:26:30');


-- -- Estructura de tabla para la tabla corre_asegu

CREATE TABLE corre_asegu ( corredor_id int(10) UNSIGNED NOT NULL, aseguradora_id int(10) 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 corre_asegu

INSERT INTO corre_asegu (corredor_id, aseguradora_id, created_at, updated_at) VALUES (1, 1, '2017-07-06 06:06:21', '2017-07-06 06:06:21'), (2, 1, '2017-07-10 19:26:30', '2017-07-10 19:26:30');


-- -- Estructura de tabla para la tabla facturaciones

CREATE TABLE facturaciones ( id int(10) UNSIGNED NOT NULL, reparacion_id int(10) UNSIGNED NOT NULL, descripcion text COLLATE utf8mb4_unicode_ci NOT NULL, forma_pago enum('efectivo','deposito / transferencia') COLLATE utf8mb4_unicode_ci NOT NULL, nro_cuenta varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, nro_comprobante varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, impuesto varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, subtot varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla imagenes

CREATE TABLE imagenes ( id int(10) UNSIGNED NOT NULL, nombre varchar(191) COLLATE utf8mb4_unicode_ci 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 imagenes

INSERT INTO imagenes (id, nombre, created_at, updated_at) VALUES (1, 'LycGm.jpg', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (2, 'p3XS3.jpg', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (3, 'dTKlx.jpg', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (4, '0Csxt.jpg', '2017-07-03 00:55:47', '2017-07-03 00:55:47'), (5, '6sqm5.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (6, 'qDHIo.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (7, 'teKkj.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (8, 'YfgFt.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (9, 'U0IiS.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (10, 'nnz8B.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (11, 'mE21R.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (12, 'WpBRi.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (13, 'SWcAj.jpg', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (14, 'xWuvl.jpg', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (15, 'wG4Po.jpg', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (16, 'WZhs9.jpg', '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (17, '2e2WB.jpg', '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (18, 'EhZvI.jpg', '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (19, 'jnvNI.jpg', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (20, 'F4Cv0.jpg', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (21, 'pt4zB.jpg', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (22, 'blY6I.jpg', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (23, 'FYkQW.jpg', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (24, 'DEJP5.jpg', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (25, 'hwCzY.jpg', '2017-07-10 18:04:59', '2017-07-10 18:04:59'), (26, 'ZXvOG.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (27, 'loU2l.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (28, 'ppuLs.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (29, 'eqUYG.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (30, 'cQKD0.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (31, 'ssIst.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (32, 'DtqlZ.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (33, 'I36Ej.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (34, 'b5Nm7.jpg', '2017-07-10 20:36:23', '2017-07-10 20:36:23'), (35, 'nc4os.jpg', '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (36, 'hPfcs.jpg', '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (37, 'Rum1N.jpg', '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (38, 'evjlE.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (39, 'Hi2dU.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (40, 'fSA2t.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (41, '0fl4t.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (42, 'tGuw1.jpg', '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (43, 'EKQ3l.jpg', '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (44, 'IPhQU.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (45, 'O2iNU.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (46, 'y6kI9.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (47, '4IZDn.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (48, 'ZpOjO.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (49, 'mr8ro.jpg', '2017-07-11 22:18:02', '2017-07-11 22:18:02');


-- -- Estructura de tabla para la tabla image_receps

CREATE TABLE image_receps ( imagen_id int(10) UNSIGNED NOT NULL, recepcion_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla image_reps

CREATE TABLE image_reps ( imagen_id int(10) UNSIGNED NOT NULL, repuesto_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla image_revs

CREATE TABLE image_revs ( imagen_id int(10) UNSIGNED NOT NULL, revision_id int(10) 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 image_revs

INSERT INTO image_revs (imagen_id, revision_id, created_at, updated_at) VALUES (1, 1, '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (2, 1, '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (3, 1, '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (4, 1, '2017-07-03 00:55:47', '2017-07-03 00:55:47'), (5, 2, '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (6, 2, '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (7, 2, '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (8, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (9, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (10, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (11, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (12, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (13, 3, '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (14, 3, '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (15, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (16, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (17, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (18, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (19, 4, '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (20, 4, '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (21, 4, '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (22, 5, '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (23, 5, '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (24, 5, '2017-07-10 18:04:59', '2017-07-10 18:04:59'), (25, 5, '2017-07-10 18:04:59', '2017-07-10 18:04:59'), (26, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (27, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (28, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (29, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (30, 7, '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (31, 7, '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (32, 7, '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (33, 7, '2017-07-10 18:11:20', '2017-07-10 18:11:20'), (34, 8, '2017-07-10 20:36:23', '2017-07-10 20:36:23'), (35, 8, '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (36, 8, '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (37, 8, '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (38, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (39, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (40, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (41, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (42, 10, '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (43, 10, '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (44, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (45, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (46, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (47, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (48, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (49, 10, '2017-07-11 22:18:02', '2017-07-11 22:18:02');


-- -- Estructura de tabla para la tabla materiales

CREATE TABLE materiales ( id int(10) UNSIGNED NOT NULL, descripcion text COLLATE utf8mb4_unicode_ci NOT NULL, cantidad varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, marca varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, modelo varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, costo varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, categoria enum('pintura','latoneria') COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla mater_almac

CREATE TABLE mater_almac ( material_id int(10) UNSIGNED NOT NULL, almacen_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) 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(191) 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, '2017_05_08_121909_create_propietarios_table', 1), (4, '2017_05_08_121955_create_vehiculos_table', 1), (5, '2017_05_08_122044_create_repuestos_table', 1), (6, '2017_05_08_122108_create_aseguradoras_table', 1), (7, '2017_05_08_122136_create_corredores_table', 1), (8, '2017_05_08_123130_create_operarios_table', 1), (9, '2017_05_14_010822_create_analistas_table', 1), (10, '2017_05_14_060415_create_polizas_table', 1), (11, '2017_05_14_154409_create_reparaciones_table', 1), (12, '2017_05_14_154536_create_citas_table', 1), (13, '2017_05_14_154911_create_revisiones_table', 1), (14, '2017_05_14_154947_create_imagenes_table', 1), (15, '2017_05_14_155158_create_image_revs_table', 1), (16, '2017_05_14_214600_create_almacenes_table', 1), (17, '2017_05_16_132914_create_recepciones_table', 1), (18, '2017_05_16_133850_create_image_receps_table', 1), (19, '2017_05_19_005953_create_image_reps_table', 1), (20, '2017_05_19_012622_create_materiales_table', 1), (21, '2017_05_23_050024_create_corre_asegu_table', 1), (22, '2017_05_23_052606_create_facturaciones_table', 1), (23, '2017_05_23_054831_create_almac_repues_table', 1), (24, '2017_05_23_060310_create_mater_almac_table', 1), (25, '2017_06_20_011033_create_analis_asegu_table', 1), (26, '2017_07_01_163148_create_repue_repar_table', 1);


-- -- Estructura de tabla para la tabla operarios

CREATE TABLE operarios ( id int(10) UNSIGNED NOT NULL, cedula varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre text COLLATE utf8mb4_unicode_ci NOT NULL, apellido text COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, tipo enum('latonero','pintor') COLLATE utf8mb4_unicode_ci NOT NULL, direccion text COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 operarios

INSERT INTO operarios (id, cedula, nombre, apellido, telefono, email, tipo, direccion, status, created_at, updated_at) VALUES (1, 'V-10457682', 'JOSÉ', 'REQUENA', '0414-4911227', 'jose@hotmail.com', 'latonero', 'CAGUA', 'activo', '2017-07-03 00:47:14', '2017-07-06 05:20:33'), (2, 'V-20989357', 'OSWARD', 'PACHECO', '0414-5435737', 'ojpr15@gmail.com', 'pintor', 'CAGUA', 'activo', '2017-07-03 00:47:44', '2017-07-06 06:29:42'), (3, 'V-54637382', 'JJJ', 'RVRVR', '0414-4549840', 'RAMIR@GMAIL.COM', 'latonero', 'RVRVVRVV', 'inactivo', '2017-07-11 07:11:18', '2017-07-11 07:11:18'), (4, 'V-20989357', 'ODED', 'DEDED', '0212-3792687', 'OJPR15@GMAIL.COM', 'latonero', 'RRFRF', 'inactivo', '2017-07-11 07:52:23', '2017-07-11 07:52:23'), (5, 'V-20989357', 'FFF', 'FF', '0414-4911227', 'OJPR15@GMAIL.COM', 'latonero', 'FFF', 'inactivo', '2017-07-11 09:48:27', '2017-07-11 09:48:27');


-- -- Estructura de tabla para la tabla password_resets

CREATE TABLE password_resets ( email varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, token varchar(191) 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 polizas

CREATE TABLE polizas ( id int(10) UNSIGNED NOT NULL, numero varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, aseguradora_id int(10) 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 polizas

INSERT INTO polizas (id, numero, aseguradora_id, created_at, updated_at) VALUES (1, '23-23-232323', 1, '2017-07-03 00:49:34', '2017-07-03 00:49:34'), (2, '45-45-232323', 2, '2017-07-07 08:34:13', '2017-07-07 08:34:13'), (3, '32-23-4534545', 1, '2017-07-10 18:53:38', '2017-07-10 18:53:38'), (4, '33-34-5454555', 1, '2017-07-10 19:14:10', '2017-07-10 19:14:10'), (5, '34-34-43435636', 1, '2017-07-10 21:20:05', '2017-07-10 21:20:05');


-- -- Estructura de tabla para la tabla propietarios

CREATE TABLE propietarios ( id int(10) UNSIGNED NOT NULL, rif varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre_completo text COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci 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 propietarios

INSERT INTO propietarios (id, rif, nombre_completo, telefono, email, created_at, updated_at) VALUES (1, 'J-20989357-2', 'PACHECO REQUENA OSWARD JOSÉ', '0414-5435737', 'ojpr15@gmail.com', '2017-07-03 00:49:34', '2017-07-03 00:49:34'), (2, 'J-10759226-0', 'REQUENA BLANCO ZULEIMA JOSEFINA', '0426-2349730', 'ZULEIMA@GMAIL.COM', '2017-07-07 08:34:13', '2017-07-07 08:34:13'), (3, 'J-24924739-0', 'ARANA NIEVES JHONNY JOSÉ', '0426-2349730', 'jhonny@gmail.com', '2017-07-10 18:53:38', '2017-07-10 18:53:38'), (4, 'J-10459682-2', 'GONZALEZ DE REQUENA OMAIRA JOSEFINA', '0416-2415105', 'OMAIRA@GMAIL.COM', '2017-07-10 19:14:10', '2017-07-10 19:14:10'), (5, 'J-10459682-7', 'REQUENA BLANCO JOSÉ NICOLAS', '0414-4911227', 'jose@hotmail.com', '2017-07-10 21:20:05', '2017-07-10 21:20:05');


-- -- Estructura de tabla para la tabla recepciones

CREATE TABLE recepciones ( id int(10) UNSIGNED NOT NULL, cita_id int(10) UNSIGNED NOT NULL, tipo enum('aseguradora','particular') COLLATE utf8mb4_unicode_ci NOT NULL, chofer varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, tlf_chofer varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, productor varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, recibe varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, fecha date NOT NULL, kilometraje varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, combustible varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, detalles varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, observacion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla reparaciones

CREATE TABLE reparaciones ( id int(10) UNSIGNED NOT NULL, propietario_id int(10) UNSIGNED NOT NULL, vehiculo_id int(10) UNSIGNED NOT NULL, analista_id int(10) UNSIGNED NOT NULL, latonero_id int(10) UNSIGNED NOT NULL, pintor_id int(10) UNSIGNED NOT NULL, fecha_ocu varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, num_certificado varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, nro_siniestro varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, notas varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, mano_obra varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depreciacion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, mecanica_otros varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, subtotal_mo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, otros_gastos varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, tot_manobra varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depre_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total_accesorios varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depre_acce varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, repues_taller varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, manejo_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, deduccion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, desc_prepago varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, monto varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, iva varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, deducible_p varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, subtotal varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, islr varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, ordenes_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, repues_otros varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depreciacion_two varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, accesorios varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depreciacion_nega varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total_ordenes_acc varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, monto_asegu varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, monto_final varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, descripcion_daños text COLLATE utf8mb4_unicode_ci NOT NULL, tipos_daños text COLLATE utf8mb4_unicode_ci NOT NULL, selec_repues text COLLATE utf8mb4_unicode_ci NOT NULL, no_dispo text COLLATE utf8mb4_unicode_ci NOT NULL, status varchar(191) COLLATE utf8mb4_unicode_ci 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 reparaciones

INSERT INTO reparaciones (id, propietario_id, vehiculo_id, analista_id, latonero_id, pintor_id, fecha_ocu, num_certificado, nro_siniestro, notas, mano_obra, depreciacion, mecanica_otros, subtotal_mo, otros_gastos, tot_manobra, total_repues, depre_repues, total_accesorios, depre_acce, repues_taller, manejo_repues, deduccion, desc_prepago, monto, iva, deducible_p, subtotal, islr, ordenes_repues, repues_otros, depreciacion_two, accesorios, depreciacion_nega, total_ordenes_acc, monto_asegu, monto_final, descripcion_daños, tipos_daños, selec_repues, no_dispo, status, created_at, updated_at) VALUES (1, 1, 1, 1, 1, 2, '25-01-2015', '232324543', '32-324434343', 'NINGUNA', '243', '324324', '342344', '234324', '343434', '23423', '2323', '3424', '32432423', '43243', '343242', '23424', '3244', '4324', '4324', '4234', '342434', '34324', '3442', '4234', '2344', '324324', '32434', '4324', '34434', '342', '3243243', '3FFDVREVREV', 'VRVRVRR', 'RVVVREVERVE', 'RRVREVREVV', 'LIMPIEZA', '2017-07-03 00:49:35', '2017-07-11 22:17:59'), (2, 2, 2, 1, 1, 2, '25-10-2016', '0/5235423', '34-3255245', 'NINGUNA', '453', '45', '345', '45', '3454', '454', '4354', '453', '4543', '435', '4543', '454', '54', '454', '45', '4354', '45', '45', '435', '45', '454', '4354', '435', '453', '4543', '4543', '454', 'PUERTA DERECHA E IZQUIERDA\r\nPARABRISAS', 'REPARAR Y PINTAR\r\nINSTALAR', 'TAL', 'TAL Y TAL', 'ENTREGA', '2017-07-07 08:34:13', '2017-07-10 18:11:19'), (3, 3, 3, 2, 1, 2, '25-11-2016', '3/4532', '26-45435335', 'LE FALTO TAL', '4534', '435345', '4543', '454', '43543', '435345', '34545', '3453', '45', '43534', '435', '5343', '43543', '4545', '4554', '4454', '454', '4543', '454', '43543', '4543', '4543', '4543', '43545', '4543', '453', '34534', 'OHFOIHVOHERHOVE', 'VRKVNRNVRN', 'RVRVVRV', 'VRERVERV', 'DESARMADO', '2017-07-10 18:53:39', '2017-07-10 20:36:23'), (4, 4, 4, 1, 2, 1, '27-10-2017', '3/45353445', '53-4553435', 'NINGUNA', '435', '543', '43545', '4534', '4545', '5435', '4543', '55', '4535', '45', '35', '45', '5435', '4543', '45354', '435', '43534', '454', '4355', '543', '453', '5435', '5345', '435', '545', '435', '453', 'SVHUOHDOHIDO', 'EWJIFUOEWHFOI', 'EWFOIUWE9FU', 'FEWEHFOHEFPI', 'DESARMADO', '2017-07-10 19:14:10', '2017-07-10 21:53:46'), (5, 5, 5, 1, 1, 2, '25-03-2016', '4/4543555', '76-43677466', 'NINGUNA', '323', '324', '43', '444', '42', '234', '34', '432424', '4244', '42', '324', '43', '4324', '4324', '343', '434', '24', '44', '2343', '324', '324', '3424', '4324', '34324', '234', '234', '342', 'JGJLGLLG', 'CFIYFIFF', 'OGOGOUGG', 'YIFIYFIYFYFI', 'NINGUNO', '2017-07-10 21:20:05', '2017-07-10 21:20:05');


-- -- Estructura de tabla para la tabla repuestos

CREATE TABLE repuestos ( id int(10) UNSIGNED NOT NULL, codigo varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, descripcion text COLLATE utf8mb4_unicode_ci NOT NULL, cantidad varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, marca varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, modelo varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, costo varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla repue_repar

CREATE TABLE repue_repar ( id int(10) UNSIGNED NOT NULL, reparacion_id int(10) UNSIGNED NOT NULL, repuesto_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla revisiones

CREATE TABLE revisiones ( id int(10) UNSIGNED NOT NULL, vehiculo_id int(10) UNSIGNED NOT NULL, encargado_entrega varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, encargado_recibe varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, avances text COLLATE utf8mb4_unicode_ci NOT NULL, tipo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, fecha date 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 revisiones

INSERT INTO revisiones (id, vehiculo_id, encargado_entrega, encargado_recibe, avances, tipo, fecha, created_at, updated_at) VALUES (1, 1, 'PEDRO MORALES', 'JOSE MARTINEZ', 'SE REPARÓ LO ACORDADO', 'DESARMADO', '2017-07-03', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (2, 1, 'fulano', 'de tar', 'dsdsvd', 'LATONERIA', '2017-07-03', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (3, 1, 'fulano', 'tal', 'jsckbswjcl', 'PREPARACION', '2017-07-08', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (4, 1, 'JOSÉ', 'PEDRO', 'NONE', 'PINTURA', '2017-07-10', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (5, 1, 'MANUEL', 'ARMANDO', 'NINGUNA', 'PULITURA', '2017-07-10', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (6, 2, 'YYY', 'HH', 'FF', 'LIMPIEZA', '2017-07-10', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (7, 2, 'RFRF', 'FRR', 'FRRF', 'ENTREGA', '2017-07-11', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (8, 3, 'MANUEL', 'PEDRO', 'NINGUNA', 'DESARMADO', '2017-07-11', '2017-07-10 20:36:23', '2017-07-10 20:36:23'), (9, 4, 'KGLGLGPI', 'GKGGLOGLO', 'GUKGUOGO', 'DESARMADO', '2017-07-10', '2017-07-10 21:53:46', '2017-07-10 21:53:46'), (10, 1, 'JIRAFA', 'CAMALEON', 'ODVOHOSDVV', 'LIMPIEZA', '2017-07-11', '2017-07-11 22:18:00', '2017-07-11 22:18:00');


-- -- Estructura de tabla para la tabla users

CREATE TABLE users ( id int(10) UNSIGNED NOT NULL, name varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, password varchar(191) 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, password, remember_token, created_at, updated_at) VALUES (1, 'Osward', 'ojpr15@gmail.com', '$2y$10$FRam6p5VTmilxbV0snJFieMCHXz/R0N75GEW6ZuNVOeNXL6NO/01S', 'uIpSPXBuY2PJS2cQiw0ERD9yK0Si4z1v8duobYbuI9rsYUdwYAZJ8s0R7as4', '2017-07-03 00:45:47', '2017-07-03 00:45:47');


-- -- Estructura de tabla para la tabla vehiculos

CREATE TABLE vehiculos ( id int(10) UNSIGNED NOT NULL, placa varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, marca varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, modelo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, anio int(11) NOT NULL, serial_motor varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, serial_carro varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, color varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, tipo varchar(191) COLLATE utf8mb4_unicode_ci 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 vehiculos

INSERT INTO vehiculos (id, placa, marca, modelo, anio, serial_motor, serial_carro, color, tipo, created_at, updated_at) VALUES (1, 'DIO5VEN', 'CHEVROLET', 'AVEO', 2015, 'G4G4545G5', 'G543G5G', 'AZUL', 'LIGERO', '2017-07-03 00:49:35', '2017-07-03 00:49:35'), (2, 'A8JXU5', 'NISSAN', 'STR', 2014, '45432534254', '34IOPQEWDF3', 'BLANCO', 'LIGERO', '2017-07-07 08:34:13', '2017-07-07 08:34:13'), (3, 'ABC49K2', 'FORD', 'FIESTA', 2016, '453454545453', 'N24PU49RTU294T', 'ANARANJADO', 'LIGERO', '2017-07-10 18:53:39', '2017-07-10 18:53:39'), (4, 'FEFFE43', 'CHEVROLET', 'OPTRA', 2015, '4534543543', '7C8497985743H7C4', 'NEGRO', 'LIGERO', '2017-07-10 19:14:10', '2017-07-10 19:14:10'), (5, 'CN3839R', 'NISSAN', 'HTHT', 2015, '453GC4VC54', '97C4N73798423NXY', 'BLANCO', 'LIGERO', '2017-07-10 21:20:05', '2017-07-10 21:20:05');

-- -- Índices para tablas volcadas

-- -- Indices de la tabla almacenes

ALTER TABLE almacenes ADD PRIMARY KEY (id);

-- -- Indices de la tabla almac_repues

ALTER TABLE almac_repues ADD KEY almac_repues_almacen_id_foreign (almacen_id), ADD KEY almac_repues_repuesto_id_foreign (repuesto_id);

-- -- Indices de la tabla analistas

ALTER TABLE analistas ADD PRIMARY KEY (id);

-- -- Indices de la tabla analis_asegu

ALTER TABLE analis_asegu ADD KEY analis_asegu_analista_id_foreign (analista_id), ADD KEY analis_asegu_aseguradora_id_foreign (aseguradora_id);

-- -- Indices de la tabla aseguradoras

ALTER TABLE aseguradoras ADD PRIMARY KEY (id);

-- -- Indices de la tabla citas

ALTER TABLE citas ADD PRIMARY KEY (id), ADD KEY citas_reparacion_id_foreign (reparacion_id);

-- -- Indices de la tabla corredores

ALTER TABLE corredores ADD PRIMARY KEY (id);

-- -- Indices de la tabla corre_asegu

ALTER TABLE corre_asegu ADD KEY corre_asegu_corredor_id_foreign (corredor_id), ADD KEY corre_asegu_aseguradora_id_foreign (aseguradora_id);

-- -- Indices de la tabla facturaciones

ALTER TABLE facturaciones ADD PRIMARY KEY (id), ADD KEY facturaciones_reparacion_id_foreign (reparacion_id);

-- -- Indices de la tabla imagenes

ALTER TABLE imagenes ADD PRIMARY KEY (id);

-- -- Indices de la tabla image_receps

ALTER TABLE image_receps ADD KEY image_receps_imagen_id_foreign (imagen_id), ADD KEY image_receps_recepcion_id_foreign (recepcion_id);

-- -- Indices de la tabla image_reps

ALTER TABLE image_reps ADD KEY image_reps_imagen_id_foreign (imagen_id), ADD KEY image_reps_repuesto_id_foreign (repuesto_id);

-- -- Indices de la tabla image_revs

ALTER TABLE image_revs ADD KEY image_revs_imagen_id_foreign (imagen_id), ADD KEY image_revs_revision_id_foreign (revision_id);

-- -- Indices de la tabla materiales

ALTER TABLE materiales ADD PRIMARY KEY (id);

-- -- Indices de la tabla mater_almac

ALTER TABLE mater_almac ADD KEY mater_almac_material_id_foreign (material_id), ADD KEY mater_almac_almacen_id_foreign (almacen_id);

-- -- Indices de la tabla migrations

ALTER TABLE migrations ADD PRIMARY KEY (id);

-- -- Indices de la tabla operarios

ALTER TABLE operarios 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 polizas

ALTER TABLE polizas ADD PRIMARY KEY (id), ADD KEY polizas_aseguradora_id_foreign (aseguradora_id);

-- -- Indices de la tabla propietarios

ALTER TABLE propietarios ADD PRIMARY KEY (id);

-- -- Indices de la tabla recepciones

ALTER TABLE recepciones ADD PRIMARY KEY (id), ADD KEY recepciones_cita_id_foreign (cita_id);

-- -- Indices de la tabla reparaciones

ALTER TABLE reparaciones ADD PRIMARY KEY (id), ADD KEY reparaciones_propietario_id_foreign (propietario_id), ADD KEY reparaciones_vehiculo_id_foreign (vehiculo_id), ADD KEY reparaciones_analista_id_foreign (analista_id), ADD KEY reparaciones_latonero_id_foreign (latonero_id), ADD KEY reparaciones_pintor_id_foreign (pintor_id);

-- -- Indices de la tabla repuestos

ALTER TABLE repuestos ADD PRIMARY KEY (id);

-- -- Indices de la tabla repue_repar

ALTER TABLE repue_repar ADD PRIMARY KEY (id), ADD KEY repue_repar_reparacion_id_foreign (reparacion_id), ADD KEY repue_repar_repuesto_id_foreign (repuesto_id);

-- -- Indices de la tabla revisiones

ALTER TABLE revisiones ADD PRIMARY KEY (id), ADD KEY revisiones_vehiculo_id_foreign (vehiculo_id);

-- -- Indices de la tabla users

ALTER TABLE users ADD PRIMARY KEY (id), ADD UNIQUE KEY users_email_unique (email);

-- -- Indices de la tabla vehiculos

ALTER TABLE vehiculos ADD PRIMARY KEY (id), ADD UNIQUE KEY vehiculos_placa_unique (placa);

-- -- AUTO_INCREMENT de las tablas volcadas

-- -- AUTO_INCREMENT de la tabla almacenes

ALTER TABLE almacenes MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla analistas

ALTER TABLE analistas MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

-- AUTO_INCREMENT de la tabla aseguradoras

ALTER TABLE aseguradoras MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

-- AUTO_INCREMENT de la tabla citas

ALTER TABLE citas MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla corredores

ALTER TABLE corredores MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

-- AUTO_INCREMENT de la tabla facturaciones

ALTER TABLE facturaciones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla imagenes

ALTER TABLE imagenes MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=50;

-- AUTO_INCREMENT de la tabla materiales

ALTER TABLE materiales MODIFY id int(10) 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=27;

-- AUTO_INCREMENT de la tabla operarios

ALTER TABLE operarios MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla polizas

ALTER TABLE polizas MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla propietarios

ALTER TABLE propietarios MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla recepciones

ALTER TABLE recepciones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla reparaciones

ALTER TABLE reparaciones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla repuestos

ALTER TABLE repuestos MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla repue_repar

ALTER TABLE repue_repar MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla revisiones

ALTER TABLE revisiones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;

-- AUTO_INCREMENT de la tabla users

ALTER TABLE users MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;

-- AUTO_INCREMENT de la tabla vehiculos

ALTER TABLE vehiculos MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- Restricciones para tablas volcadas

-- -- Filtros para la tabla almac_repues

ALTER TABLE almac_repues ADD CONSTRAINT almac_repues_almacen_id_foreign FOREIGN KEY (almacen_id) REFERENCES almacenes (id) ON DELETE CASCADE, ADD CONSTRAINT almac_repues_repuesto_id_foreign FOREIGN KEY (repuesto_id) REFERENCES repuestos (id) ON DELETE CASCADE;

-- -- Filtros para la tabla analis_asegu

ALTER TABLE analis_asegu ADD CONSTRAINT analis_asegu_analista_id_foreign FOREIGN KEY (analista_id) REFERENCES analistas (id) ON DELETE CASCADE, ADD CONSTRAINT analis_asegu_aseguradora_id_foreign FOREIGN KEY (aseguradora_id) REFERENCES aseguradoras (id) ON DELETE CASCADE;

-- -- Filtros para la tabla citas

ALTER TABLE citas ADD CONSTRAINT citas_reparacion_id_foreign FOREIGN KEY (reparacion_id) REFERENCES reparaciones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla corre_asegu

ALTER TABLE corre_asegu ADD CONSTRAINT corre_asegu_aseguradora_id_foreign FOREIGN KEY (aseguradora_id) REFERENCES aseguradoras (id) ON DELETE CASCADE, ADD CONSTRAINT corre_asegu_corredor_id_foreign FOREIGN KEY (corredor_id) REFERENCES corredores (id) ON DELETE CASCADE;

-- -- Filtros para la tabla facturaciones

ALTER TABLE facturaciones ADD CONSTRAINT facturaciones_reparacion_id_foreign FOREIGN KEY (reparacion_id) REFERENCES reparaciones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla image_receps

ALTER TABLE image_receps ADD CONSTRAINT image_receps_imagen_id_foreign FOREIGN KEY (imagen_id) REFERENCES imagenes (id) ON DELETE CASCADE, ADD CONSTRAINT image_receps_recepcion_id_foreign FOREIGN KEY (recepcion_id) REFERENCES recepciones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla image_reps

ALTER TABLE image_reps ADD CONSTRAINT image_reps_imagen_id_foreign FOREIGN KEY (imagen_id) REFERENCES imagenes (id) ON DELETE CASCADE, ADD CONSTRAINT image_reps_repuesto_id_foreign FOREIGN KEY (repuesto_id) REFERENCES repuestos (id) ON DELETE CASCADE;

-- -- Filtros para la tabla image_revs

ALTER TABLE image_revs ADD CONSTRAINT image_revs_imagen_id_foreign FOREIGN KEY (imagen_id) REFERENCES imagenes (id) ON DELETE CASCADE, ADD CONSTRAINT image_revs_revision_id_foreign FOREIGN KEY (revision_id) REFERENCES revisiones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla mater_almac

ALTER TABLE mater_almac ADD CONSTRAINT mater_almac_almacen_id_foreign FOREIGN KEY (almacen_id) REFERENCES almacenes (id) ON DELETE CASCADE, ADD CONSTRAINT mater_almac_material_id_foreign FOREIGN KEY (material_id) REFERENCES materiales (id) ON DELETE CASCADE;

-- -- Filtros para la tabla polizas

ALTER TABLE polizas ADD CONSTRAINT polizas_aseguradora_id_foreign FOREIGN KEY (aseguradora_id) REFERENCES aseguradoras (id) ON DELETE CASCADE;

-- -- Filtros para la tabla recepciones

ALTER TABLE recepciones ADD CONSTRAINT recepciones_cita_id_foreign FOREIGN KEY (cita_id) REFERENCES citas (id) ON DELETE CASCADE;

-- -- Filtros para la tabla reparaciones

ALTER TABLE reparaciones ADD CONSTRAINT reparaciones_analista_id_foreign FOREIGN KEY (analista_id) REFERENCES analistas (id), ADD CONSTRAINT reparaciones_latonero_id_foreign FOREIGN KEY (latonero_id) REFERENCES operarios (id), ADD CONSTRAINT reparaciones_pintor_id_foreign FOREIGN KEY (pintor_id) REFERENCES operarios (id), ADD CONSTRAINT reparaciones_propietario_id_foreign FOREIGN KEY (propietario_id) REFERENCES propietarios (id), ADD CONSTRAINT reparaciones_vehiculo_id_foreign FOREIGN KEY (vehiculo_id) REFERENCES vehiculos (id);

-- -- Filtros para la tabla repue_repar

ALTER TABLE repue_repar ADD CONSTRAINT repue_repar_reparacion_id_foreign FOREIGN KEY (reparacion_id) REFERENCES reparaciones (id) ON DELETE CASCADE, ADD CONSTRAINT repue_repar_repuesto_id_foreign FOREIGN KEY (repuesto_id) REFERENCES repuestos (id) ON DELETE CASCADE;

-- -- Filtros para la tabla revisiones

ALTER TABLE revisiones ADD CONSTRAINT revisiones_vehiculo_id_foreign FOREIGN KEY (vehiculo_id) REFERENCES vehiculos (id) ON DELETE CASCADE;

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

OswardJr commented 7 years ago

`-- phpMyAdmin SQL Dump -- version 4.6.4 -- https://www.phpmyadmin.net/

-- Servidor: localhost -- Tiempo de generación: 12-07-2017 a las 01:05:24 -- Versión del servidor: 5.7.15-log -- Versión de PHP: 5.6.26

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 /;

-- -- Base de datos: a


-- -- Estructura de tabla para la tabla almacenes

CREATE TABLE almacenes ( id int(10) UNSIGNED NOT NULL, seccion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, cubiculo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla almac_repues

CREATE TABLE almac_repues ( almacen_id int(10) UNSIGNED NOT NULL, repuesto_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla analistas

CREATE TABLE analistas ( id int(10) UNSIGNED NOT NULL, rif varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre text COLLATE utf8mb4_unicode_ci NOT NULL, apellido text COLLATE utf8mb4_unicode_ci NOT NULL, celular varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 analistas

INSERT INTO analistas (id, rif, nombre, apellido, celular, telefono, email, status, created_at, updated_at) VALUES (1, 'J-24924739-0', 'LEONCIO', 'REQUENA', '0414-4549840', '0212-3840364', 'LEOREQUENA_14@HOTMAIL.COM', 'activo', '2017-07-03 00:46:43', '2017-07-10 21:35:51'), (2, 'J-25893478-5', 'Victor José', 'Pacheco', '0414-4549840', '0212-3840333', 'ojpr15@gmail.com', 'inactivo', '2017-07-10 17:39:28', '2017-07-10 17:50:35');


-- -- Estructura de tabla para la tabla analis_asegu

CREATE TABLE analis_asegu ( analista_id int(10) UNSIGNED NOT NULL, aseguradora_id int(10) 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 analis_asegu

INSERT INTO analis_asegu (analista_id, aseguradora_id, created_at, updated_at) VALUES (1, 1, '2017-07-03 00:46:43', '2017-07-03 00:46:43'), (2, 2, '2017-07-10 17:39:28', '2017-07-10 17:39:28');


-- -- Estructura de tabla para la tabla aseguradoras

CREATE TABLE aseguradoras ( id int(10) UNSIGNED NOT NULL, rif varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, denominacion text COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 aseguradoras

INSERT INTO aseguradoras (id, rif, denominacion, telefono, email, status, created_at, updated_at) VALUES (1, 'J-20989357-2', 'Seguros Universitas C.A', '0212-3840364', 'SEGUROSUNI@gmail.com', 'activo', '2017-07-03 00:46:13', '2017-07-03 00:46:13'), (2, 'J-25893478-5', 'Seguros Altamira C.A', '0212-3840363', 'SEGUROSALTAMIRA@gmail.com', 'activo', '2017-07-06 21:43:46', '2017-07-06 21:43:46');


-- -- Estructura de tabla para la tabla citas

CREATE TABLE citas ( id int(10) UNSIGNED NOT NULL, reparacion_id int(10) UNSIGNED NOT NULL, selec_dia date NOT NULL, hora varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla corredores

CREATE TABLE corredores ( id int(10) UNSIGNED NOT NULL, cedula varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre text COLLATE utf8mb4_unicode_ci NOT NULL, apellido text COLLATE utf8mb4_unicode_ci NOT NULL, celular varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 corredores

INSERT INTO corredores (id, cedula, nombre, apellido, celular, telefono, email, status, created_at, updated_at) VALUES (1, 'J-20989357-0', 'OSWARD', 'PACHECO', '0414-5435737', '0212-3840364', 'DFDIFH@GMAIL.COM', 'activo', '2017-07-06 06:06:21', '2017-07-06 06:06:21'), (2, 'J-20989357-9', 'PEDRO', 'PEREZ', '0416-4264859', '0212-3840333', 'PEDRO@GMAIL.COM', 'activo', '2017-07-10 19:26:30', '2017-07-10 19:26:30');


-- -- Estructura de tabla para la tabla corre_asegu

CREATE TABLE corre_asegu ( corredor_id int(10) UNSIGNED NOT NULL, aseguradora_id int(10) 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 corre_asegu

INSERT INTO corre_asegu (corredor_id, aseguradora_id, created_at, updated_at) VALUES (1, 1, '2017-07-06 06:06:21', '2017-07-06 06:06:21'), (2, 1, '2017-07-10 19:26:30', '2017-07-10 19:26:30');


-- -- Estructura de tabla para la tabla facturaciones

CREATE TABLE facturaciones ( id int(10) UNSIGNED NOT NULL, reparacion_id int(10) UNSIGNED NOT NULL, descripcion text COLLATE utf8mb4_unicode_ci NOT NULL, forma_pago enum('efectivo','deposito / transferencia') COLLATE utf8mb4_unicode_ci NOT NULL, nro_cuenta varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, nro_comprobante varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, impuesto varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, subtot varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla imagenes

CREATE TABLE imagenes ( id int(10) UNSIGNED NOT NULL, nombre varchar(191) COLLATE utf8mb4_unicode_ci 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 imagenes

INSERT INTO imagenes (id, nombre, created_at, updated_at) VALUES (1, 'LycGm.jpg', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (2, 'p3XS3.jpg', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (3, 'dTKlx.jpg', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (4, '0Csxt.jpg', '2017-07-03 00:55:47', '2017-07-03 00:55:47'), (5, '6sqm5.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (6, 'qDHIo.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (7, 'teKkj.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (8, 'YfgFt.jpg', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (9, 'U0IiS.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (10, 'nnz8B.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (11, 'mE21R.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (12, 'WpBRi.jpg', '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (13, 'SWcAj.jpg', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (14, 'xWuvl.jpg', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (15, 'wG4Po.jpg', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (16, 'WZhs9.jpg', '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (17, '2e2WB.jpg', '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (18, 'EhZvI.jpg', '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (19, 'jnvNI.jpg', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (20, 'F4Cv0.jpg', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (21, 'pt4zB.jpg', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (22, 'blY6I.jpg', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (23, 'FYkQW.jpg', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (24, 'DEJP5.jpg', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (25, 'hwCzY.jpg', '2017-07-10 18:04:59', '2017-07-10 18:04:59'), (26, 'ZXvOG.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (27, 'loU2l.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (28, 'ppuLs.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (29, 'eqUYG.jpg', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (30, 'cQKD0.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (31, 'ssIst.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (32, 'DtqlZ.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (33, 'I36Ej.jpg', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (34, 'b5Nm7.jpg', '2017-07-10 20:36:23', '2017-07-10 20:36:23'), (35, 'nc4os.jpg', '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (36, 'hPfcs.jpg', '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (37, 'Rum1N.jpg', '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (38, 'evjlE.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (39, 'Hi2dU.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (40, 'fSA2t.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (41, '0fl4t.jpg', '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (42, 'tGuw1.jpg', '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (43, 'EKQ3l.jpg', '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (44, 'IPhQU.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (45, 'O2iNU.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (46, 'y6kI9.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (47, '4IZDn.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (48, 'ZpOjO.jpg', '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (49, 'mr8ro.jpg', '2017-07-11 22:18:02', '2017-07-11 22:18:02');


-- -- Estructura de tabla para la tabla image_receps

CREATE TABLE image_receps ( imagen_id int(10) UNSIGNED NOT NULL, recepcion_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla image_reps

CREATE TABLE image_reps ( imagen_id int(10) UNSIGNED NOT NULL, repuesto_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla image_revs

CREATE TABLE image_revs ( imagen_id int(10) UNSIGNED NOT NULL, revision_id int(10) 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 image_revs

INSERT INTO image_revs (imagen_id, revision_id, created_at, updated_at) VALUES (1, 1, '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (2, 1, '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (3, 1, '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (4, 1, '2017-07-03 00:55:47', '2017-07-03 00:55:47'), (5, 2, '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (6, 2, '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (7, 2, '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (8, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (9, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (10, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (11, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (12, 2, '2017-07-03 18:21:40', '2017-07-03 18:21:40'), (13, 3, '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (14, 3, '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (15, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (16, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (17, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (18, 3, '2017-07-06 19:27:03', '2017-07-06 19:27:03'), (19, 4, '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (20, 4, '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (21, 4, '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (22, 5, '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (23, 5, '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (24, 5, '2017-07-10 18:04:59', '2017-07-10 18:04:59'), (25, 5, '2017-07-10 18:04:59', '2017-07-10 18:04:59'), (26, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (27, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (28, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (29, 6, '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (30, 7, '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (31, 7, '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (32, 7, '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (33, 7, '2017-07-10 18:11:20', '2017-07-10 18:11:20'), (34, 8, '2017-07-10 20:36:23', '2017-07-10 20:36:23'), (35, 8, '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (36, 8, '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (37, 8, '2017-07-10 20:36:24', '2017-07-10 20:36:24'), (38, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (39, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (40, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (41, 9, '2017-07-10 21:53:47', '2017-07-10 21:53:47'), (42, 10, '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (43, 10, '2017-07-11 22:18:00', '2017-07-11 22:18:00'), (44, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (45, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (46, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (47, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (48, 10, '2017-07-11 22:18:01', '2017-07-11 22:18:01'), (49, 10, '2017-07-11 22:18:02', '2017-07-11 22:18:02');


-- -- Estructura de tabla para la tabla materiales

CREATE TABLE materiales ( id int(10) UNSIGNED NOT NULL, descripcion text COLLATE utf8mb4_unicode_ci NOT NULL, cantidad varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, marca varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, modelo varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, costo varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, categoria enum('pintura','latoneria') COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla mater_almac

CREATE TABLE mater_almac ( material_id int(10) UNSIGNED NOT NULL, almacen_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) 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(191) 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, '2017_05_08_121909_create_propietarios_table', 1), (4, '2017_05_08_121955_create_vehiculos_table', 1), (5, '2017_05_08_122044_create_repuestos_table', 1), (6, '2017_05_08_122108_create_aseguradoras_table', 1), (7, '2017_05_08_122136_create_corredores_table', 1), (8, '2017_05_08_123130_create_operarios_table', 1), (9, '2017_05_14_010822_create_analistas_table', 1), (10, '2017_05_14_060415_create_polizas_table', 1), (11, '2017_05_14_154409_create_reparaciones_table', 1), (12, '2017_05_14_154536_create_citas_table', 1), (13, '2017_05_14_154911_create_revisiones_table', 1), (14, '2017_05_14_154947_create_imagenes_table', 1), (15, '2017_05_14_155158_create_image_revs_table', 1), (16, '2017_05_14_214600_create_almacenes_table', 1), (17, '2017_05_16_132914_create_recepciones_table', 1), (18, '2017_05_16_133850_create_image_receps_table', 1), (19, '2017_05_19_005953_create_image_reps_table', 1), (20, '2017_05_19_012622_create_materiales_table', 1), (21, '2017_05_23_050024_create_corre_asegu_table', 1), (22, '2017_05_23_052606_create_facturaciones_table', 1), (23, '2017_05_23_054831_create_almac_repues_table', 1), (24, '2017_05_23_060310_create_mater_almac_table', 1), (25, '2017_06_20_011033_create_analis_asegu_table', 1), (26, '2017_07_01_163148_create_repue_repar_table', 1);


-- -- Estructura de tabla para la tabla operarios

CREATE TABLE operarios ( id int(10) UNSIGNED NOT NULL, cedula varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre text COLLATE utf8mb4_unicode_ci NOT NULL, apellido text COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, tipo enum('latonero','pintor') COLLATE utf8mb4_unicode_ci NOT NULL, direccion text COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci 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 operarios

INSERT INTO operarios (id, cedula, nombre, apellido, telefono, email, tipo, direccion, status, created_at, updated_at) VALUES (1, 'V-10457682', 'JOSÉ', 'REQUENA', '0414-4911227', 'jose@hotmail.com', 'latonero', 'CAGUA', 'activo', '2017-07-03 00:47:14', '2017-07-06 05:20:33'), (2, 'V-20989357', 'OSWARD', 'PACHECO', '0414-5435737', 'ojpr15@gmail.com', 'pintor', 'CAGUA', 'activo', '2017-07-03 00:47:44', '2017-07-06 06:29:42'), (3, 'V-54637382', 'JJJ', 'RVRVR', '0414-4549840', 'RAMIR@GMAIL.COM', 'latonero', 'RVRVVRVV', 'inactivo', '2017-07-11 07:11:18', '2017-07-11 07:11:18'), (4, 'V-20989357', 'ODED', 'DEDED', '0212-3792687', 'OJPR15@GMAIL.COM', 'latonero', 'RRFRF', 'inactivo', '2017-07-11 07:52:23', '2017-07-11 07:52:23'), (5, 'V-20989357', 'FFF', 'FF', '0414-4911227', 'OJPR15@GMAIL.COM', 'latonero', 'FFF', 'inactivo', '2017-07-11 09:48:27', '2017-07-11 09:48:27');


-- -- Estructura de tabla para la tabla password_resets

CREATE TABLE password_resets ( email varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, token varchar(191) 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 polizas

CREATE TABLE polizas ( id int(10) UNSIGNED NOT NULL, numero varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, aseguradora_id int(10) 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 polizas

INSERT INTO polizas (id, numero, aseguradora_id, created_at, updated_at) VALUES (1, '23-23-232323', 1, '2017-07-03 00:49:34', '2017-07-03 00:49:34'), (2, '45-45-232323', 2, '2017-07-07 08:34:13', '2017-07-07 08:34:13'), (3, '32-23-4534545', 1, '2017-07-10 18:53:38', '2017-07-10 18:53:38'), (4, '33-34-5454555', 1, '2017-07-10 19:14:10', '2017-07-10 19:14:10'), (5, '34-34-43435636', 1, '2017-07-10 21:20:05', '2017-07-10 21:20:05');


-- -- Estructura de tabla para la tabla propietarios

CREATE TABLE propietarios ( id int(10) UNSIGNED NOT NULL, rif varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, nombre_completo text COLLATE utf8mb4_unicode_ci NOT NULL, telefono varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(30) COLLATE utf8mb4_unicode_ci 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 propietarios

INSERT INTO propietarios (id, rif, nombre_completo, telefono, email, created_at, updated_at) VALUES (1, 'J-20989357-2', 'PACHECO REQUENA OSWARD JOSÉ', '0414-5435737', 'ojpr15@gmail.com', '2017-07-03 00:49:34', '2017-07-03 00:49:34'), (2, 'J-10759226-0', 'REQUENA BLANCO ZULEIMA JOSEFINA', '0426-2349730', 'ZULEIMA@GMAIL.COM', '2017-07-07 08:34:13', '2017-07-07 08:34:13'), (3, 'J-24924739-0', 'ARANA NIEVES JHONNY JOSÉ', '0426-2349730', 'jhonny@gmail.com', '2017-07-10 18:53:38', '2017-07-10 18:53:38'), (4, 'J-10459682-2', 'GONZALEZ DE REQUENA OMAIRA JOSEFINA', '0416-2415105', 'OMAIRA@GMAIL.COM', '2017-07-10 19:14:10', '2017-07-10 19:14:10'), (5, 'J-10459682-7', 'REQUENA BLANCO JOSÉ NICOLAS', '0414-4911227', 'jose@hotmail.com', '2017-07-10 21:20:05', '2017-07-10 21:20:05');


-- -- Estructura de tabla para la tabla recepciones

CREATE TABLE recepciones ( id int(10) UNSIGNED NOT NULL, cita_id int(10) UNSIGNED NOT NULL, tipo enum('aseguradora','particular') COLLATE utf8mb4_unicode_ci NOT NULL, chofer varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, tlf_chofer varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, productor varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, recibe varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, fecha date NOT NULL, kilometraje varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, combustible varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, detalles varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, observacion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla reparaciones

CREATE TABLE reparaciones ( id int(10) UNSIGNED NOT NULL, propietario_id int(10) UNSIGNED NOT NULL, vehiculo_id int(10) UNSIGNED NOT NULL, analista_id int(10) UNSIGNED NOT NULL, latonero_id int(10) UNSIGNED NOT NULL, pintor_id int(10) UNSIGNED NOT NULL, fecha_ocu varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, num_certificado varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, nro_siniestro varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, notas varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, mano_obra varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depreciacion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, mecanica_otros varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, subtotal_mo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, otros_gastos varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, tot_manobra varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depre_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total_accesorios varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depre_acce varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, repues_taller varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, manejo_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, deduccion varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, desc_prepago varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, monto varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, iva varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, deducible_p varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, subtotal varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, islr varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, ordenes_repues varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, repues_otros varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depreciacion_two varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, accesorios varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, depreciacion_nega varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, total_ordenes_acc varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, monto_asegu varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, monto_final varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, descripcion_daños text COLLATE utf8mb4_unicode_ci NOT NULL, tipos_daños text COLLATE utf8mb4_unicode_ci NOT NULL, selec_repues text COLLATE utf8mb4_unicode_ci NOT NULL, no_dispo text COLLATE utf8mb4_unicode_ci NOT NULL, status varchar(191) COLLATE utf8mb4_unicode_ci 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 reparaciones

INSERT INTO reparaciones (id, propietario_id, vehiculo_id, analista_id, latonero_id, pintor_id, fecha_ocu, num_certificado, nro_siniestro, notas, mano_obra, depreciacion, mecanica_otros, subtotal_mo, otros_gastos, tot_manobra, total_repues, depre_repues, total_accesorios, depre_acce, repues_taller, manejo_repues, deduccion, desc_prepago, monto, iva, deducible_p, subtotal, islr, ordenes_repues, repues_otros, depreciacion_two, accesorios, depreciacion_nega, total_ordenes_acc, monto_asegu, monto_final, descripcion_daños, tipos_daños, selec_repues, no_dispo, status, created_at, updated_at) VALUES (1, 1, 1, 1, 1, 2, '25-01-2015', '232324543', '32-324434343', 'NINGUNA', '243', '324324', '342344', '234324', '343434', '23423', '2323', '3424', '32432423', '43243', '343242', '23424', '3244', '4324', '4324', '4234', '342434', '34324', '3442', '4234', '2344', '324324', '32434', '4324', '34434', '342', '3243243', '3FFDVREVREV', 'VRVRVRR', 'RVVVREVERVE', 'RRVREVREVV', 'LIMPIEZA', '2017-07-03 00:49:35', '2017-07-11 22:17:59'), (2, 2, 2, 1, 1, 2, '25-10-2016', '0/5235423', '34-3255245', 'NINGUNA', '453', '45', '345', '45', '3454', '454', '4354', '453', '4543', '435', '4543', '454', '54', '454', '45', '4354', '45', '45', '435', '45', '454', '4354', '435', '453', '4543', '4543', '454', 'PUERTA DERECHA E IZQUIERDA\r\nPARABRISAS', 'REPARAR Y PINTAR\r\nINSTALAR', 'TAL', 'TAL Y TAL', 'ENTREGA', '2017-07-07 08:34:13', '2017-07-10 18:11:19'), (3, 3, 3, 2, 1, 2, '25-11-2016', '3/4532', '26-45435335', 'LE FALTO TAL', '4534', '435345', '4543', '454', '43543', '435345', '34545', '3453', '45', '43534', '435', '5343', '43543', '4545', '4554', '4454', '454', '4543', '454', '43543', '4543', '4543', '4543', '43545', '4543', '453', '34534', 'OHFOIHVOHERHOVE', 'VRKVNRNVRN', 'RVRVVRV', 'VRERVERV', 'DESARMADO', '2017-07-10 18:53:39', '2017-07-10 20:36:23'), (4, 4, 4, 1, 2, 1, '27-10-2017', '3/45353445', '53-4553435', 'NINGUNA', '435', '543', '43545', '4534', '4545', '5435', '4543', '55', '4535', '45', '35', '45', '5435', '4543', '45354', '435', '43534', '454', '4355', '543', '453', '5435', '5345', '435', '545', '435', '453', 'SVHUOHDOHIDO', 'EWJIFUOEWHFOI', 'EWFOIUWE9FU', 'FEWEHFOHEFPI', 'DESARMADO', '2017-07-10 19:14:10', '2017-07-10 21:53:46'), (5, 5, 5, 1, 1, 2, '25-03-2016', '4/4543555', '76-43677466', 'NINGUNA', '323', '324', '43', '444', '42', '234', '34', '432424', '4244', '42', '324', '43', '4324', '4324', '343', '434', '24', '44', '2343', '324', '324', '3424', '4324', '34324', '234', '234', '342', 'JGJLGLLG', 'CFIYFIFF', 'OGOGOUGG', 'YIFIYFIYFYFI', 'NINGUNO', '2017-07-10 21:20:05', '2017-07-10 21:20:05');


-- -- Estructura de tabla para la tabla repuestos

CREATE TABLE repuestos ( id int(10) UNSIGNED NOT NULL, codigo varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, descripcion text COLLATE utf8mb4_unicode_ci NOT NULL, cantidad varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, marca varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, modelo varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL, costo varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, status enum('activo','inactivo') COLLATE utf8mb4_unicode_ci NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla repue_repar

CREATE TABLE repue_repar ( id int(10) UNSIGNED NOT NULL, reparacion_id int(10) UNSIGNED NOT NULL, repuesto_id int(10) UNSIGNED NOT NULL, created_at timestamp NULL DEFAULT NULL, updated_at timestamp NULL DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;


-- -- Estructura de tabla para la tabla revisiones

CREATE TABLE revisiones ( id int(10) UNSIGNED NOT NULL, vehiculo_id int(10) UNSIGNED NOT NULL, encargado_entrega varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, encargado_recibe varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, avances text COLLATE utf8mb4_unicode_ci NOT NULL, tipo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, fecha date 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 revisiones

INSERT INTO revisiones (id, vehiculo_id, encargado_entrega, encargado_recibe, avances, tipo, fecha, created_at, updated_at) VALUES (1, 1, 'PEDRO MORALES', 'JOSE MARTINEZ', 'SE REPARÓ LO ACORDADO', 'DESARMADO', '2017-07-03', '2017-07-03 00:55:46', '2017-07-03 00:55:46'), (2, 1, 'fulano', 'de tar', 'dsdsvd', 'LATONERIA', '2017-07-03', '2017-07-03 18:21:39', '2017-07-03 18:21:39'), (3, 1, 'fulano', 'tal', 'jsckbswjcl', 'PREPARACION', '2017-07-08', '2017-07-06 19:27:02', '2017-07-06 19:27:02'), (4, 1, 'JOSÉ', 'PEDRO', 'NONE', 'PINTURA', '2017-07-10', '2017-07-10 17:28:23', '2017-07-10 17:28:23'), (5, 1, 'MANUEL', 'ARMANDO', 'NINGUNA', 'PULITURA', '2017-07-10', '2017-07-10 18:04:58', '2017-07-10 18:04:58'), (6, 2, 'YYY', 'HH', 'FF', 'LIMPIEZA', '2017-07-10', '2017-07-10 18:09:08', '2017-07-10 18:09:08'), (7, 2, 'RFRF', 'FRR', 'FRRF', 'ENTREGA', '2017-07-11', '2017-07-10 18:11:19', '2017-07-10 18:11:19'), (8, 3, 'MANUEL', 'PEDRO', 'NINGUNA', 'DESARMADO', '2017-07-11', '2017-07-10 20:36:23', '2017-07-10 20:36:23'), (9, 4, 'KGLGLGPI', 'GKGGLOGLO', 'GUKGUOGO', 'DESARMADO', '2017-07-10', '2017-07-10 21:53:46', '2017-07-10 21:53:46'), (10, 1, 'JIRAFA', 'CAMALEON', 'ODVOHOSDVV', 'LIMPIEZA', '2017-07-11', '2017-07-11 22:18:00', '2017-07-11 22:18:00');


-- -- Estructura de tabla para la tabla users

CREATE TABLE users ( id int(10) UNSIGNED NOT NULL, name varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, email varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, password varchar(191) 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, password, remember_token, created_at, updated_at) VALUES (1, 'Osward', 'ojpr15@gmail.com', '$2y$10$FRam6p5VTmilxbV0snJFieMCHXz/R0N75GEW6ZuNVOeNXL6NO/01S', 'uIpSPXBuY2PJS2cQiw0ERD9yK0Si4z1v8duobYbuI9rsYUdwYAZJ8s0R7as4', '2017-07-03 00:45:47', '2017-07-03 00:45:47');


-- -- Estructura de tabla para la tabla vehiculos

CREATE TABLE vehiculos ( id int(10) UNSIGNED NOT NULL, placa varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, marca varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, modelo varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, anio int(11) NOT NULL, serial_motor varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, serial_carro varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, color varchar(191) COLLATE utf8mb4_unicode_ci NOT NULL, tipo varchar(191) COLLATE utf8mb4_unicode_ci 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 vehiculos

INSERT INTO vehiculos (id, placa, marca, modelo, anio, serial_motor, serial_carro, color, tipo, created_at, updated_at) VALUES (1, 'DIO5VEN', 'CHEVROLET', 'AVEO', 2015, 'G4G4545G5', 'G543G5G', 'AZUL', 'LIGERO', '2017-07-03 00:49:35', '2017-07-03 00:49:35'), (2, 'A8JXU5', 'NISSAN', 'STR', 2014, '45432534254', '34IOPQEWDF3', 'BLANCO', 'LIGERO', '2017-07-07 08:34:13', '2017-07-07 08:34:13'), (3, 'ABC49K2', 'FORD', 'FIESTA', 2016, '453454545453', 'N24PU49RTU294T', 'ANARANJADO', 'LIGERO', '2017-07-10 18:53:39', '2017-07-10 18:53:39'), (4, 'FEFFE43', 'CHEVROLET', 'OPTRA', 2015, '4534543543', '7C8497985743H7C4', 'NEGRO', 'LIGERO', '2017-07-10 19:14:10', '2017-07-10 19:14:10'), (5, 'CN3839R', 'NISSAN', 'HTHT', 2015, '453GC4VC54', '97C4N73798423NXY', 'BLANCO', 'LIGERO', '2017-07-10 21:20:05', '2017-07-10 21:20:05');

-- -- Índices para tablas volcadas

-- -- Indices de la tabla almacenes

ALTER TABLE almacenes ADD PRIMARY KEY (id);

-- -- Indices de la tabla almac_repues

ALTER TABLE almac_repues ADD KEY almac_repues_almacen_id_foreign (almacen_id), ADD KEY almac_repues_repuesto_id_foreign (repuesto_id);

-- -- Indices de la tabla analistas

ALTER TABLE analistas ADD PRIMARY KEY (id);

-- -- Indices de la tabla analis_asegu

ALTER TABLE analis_asegu ADD KEY analis_asegu_analista_id_foreign (analista_id), ADD KEY analis_asegu_aseguradora_id_foreign (aseguradora_id);

-- -- Indices de la tabla aseguradoras

ALTER TABLE aseguradoras ADD PRIMARY KEY (id);

-- -- Indices de la tabla citas

ALTER TABLE citas ADD PRIMARY KEY (id), ADD KEY citas_reparacion_id_foreign (reparacion_id);

-- -- Indices de la tabla corredores

ALTER TABLE corredores ADD PRIMARY KEY (id);

-- -- Indices de la tabla corre_asegu

ALTER TABLE corre_asegu ADD KEY corre_asegu_corredor_id_foreign (corredor_id), ADD KEY corre_asegu_aseguradora_id_foreign (aseguradora_id);

-- -- Indices de la tabla facturaciones

ALTER TABLE facturaciones ADD PRIMARY KEY (id), ADD KEY facturaciones_reparacion_id_foreign (reparacion_id);

-- -- Indices de la tabla imagenes

ALTER TABLE imagenes ADD PRIMARY KEY (id);

-- -- Indices de la tabla image_receps

ALTER TABLE image_receps ADD KEY image_receps_imagen_id_foreign (imagen_id), ADD KEY image_receps_recepcion_id_foreign (recepcion_id);

-- -- Indices de la tabla image_reps

ALTER TABLE image_reps ADD KEY image_reps_imagen_id_foreign (imagen_id), ADD KEY image_reps_repuesto_id_foreign (repuesto_id);

-- -- Indices de la tabla image_revs

ALTER TABLE image_revs ADD KEY image_revs_imagen_id_foreign (imagen_id), ADD KEY image_revs_revision_id_foreign (revision_id);

-- -- Indices de la tabla materiales

ALTER TABLE materiales ADD PRIMARY KEY (id);

-- -- Indices de la tabla mater_almac

ALTER TABLE mater_almac ADD KEY mater_almac_material_id_foreign (material_id), ADD KEY mater_almac_almacen_id_foreign (almacen_id);

-- -- Indices de la tabla migrations

ALTER TABLE migrations ADD PRIMARY KEY (id);

-- -- Indices de la tabla operarios

ALTER TABLE operarios 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 polizas

ALTER TABLE polizas ADD PRIMARY KEY (id), ADD KEY polizas_aseguradora_id_foreign (aseguradora_id);

-- -- Indices de la tabla propietarios

ALTER TABLE propietarios ADD PRIMARY KEY (id);

-- -- Indices de la tabla recepciones

ALTER TABLE recepciones ADD PRIMARY KEY (id), ADD KEY recepciones_cita_id_foreign (cita_id);

-- -- Indices de la tabla reparaciones

ALTER TABLE reparaciones ADD PRIMARY KEY (id), ADD KEY reparaciones_propietario_id_foreign (propietario_id), ADD KEY reparaciones_vehiculo_id_foreign (vehiculo_id), ADD KEY reparaciones_analista_id_foreign (analista_id), ADD KEY reparaciones_latonero_id_foreign (latonero_id), ADD KEY reparaciones_pintor_id_foreign (pintor_id);

-- -- Indices de la tabla repuestos

ALTER TABLE repuestos ADD PRIMARY KEY (id);

-- -- Indices de la tabla repue_repar

ALTER TABLE repue_repar ADD PRIMARY KEY (id), ADD KEY repue_repar_reparacion_id_foreign (reparacion_id), ADD KEY repue_repar_repuesto_id_foreign (repuesto_id);

-- -- Indices de la tabla revisiones

ALTER TABLE revisiones ADD PRIMARY KEY (id), ADD KEY revisiones_vehiculo_id_foreign (vehiculo_id);

-- -- Indices de la tabla users

ALTER TABLE users ADD PRIMARY KEY (id), ADD UNIQUE KEY users_email_unique (email);

-- -- Indices de la tabla vehiculos

ALTER TABLE vehiculos ADD PRIMARY KEY (id), ADD UNIQUE KEY vehiculos_placa_unique (placa);

-- -- AUTO_INCREMENT de las tablas volcadas

-- -- AUTO_INCREMENT de la tabla almacenes

ALTER TABLE almacenes MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla analistas

ALTER TABLE analistas MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

-- AUTO_INCREMENT de la tabla aseguradoras

ALTER TABLE aseguradoras MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

-- AUTO_INCREMENT de la tabla citas

ALTER TABLE citas MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla corredores

ALTER TABLE corredores MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

-- AUTO_INCREMENT de la tabla facturaciones

ALTER TABLE facturaciones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla imagenes

ALTER TABLE imagenes MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=50;

-- AUTO_INCREMENT de la tabla materiales

ALTER TABLE materiales MODIFY id int(10) 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=27;

-- AUTO_INCREMENT de la tabla operarios

ALTER TABLE operarios MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla polizas

ALTER TABLE polizas MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla propietarios

ALTER TABLE propietarios MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla recepciones

ALTER TABLE recepciones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla reparaciones

ALTER TABLE reparaciones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- AUTO_INCREMENT de la tabla repuestos

ALTER TABLE repuestos MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla repue_repar

ALTER TABLE repue_repar MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT;

-- AUTO_INCREMENT de la tabla revisiones

ALTER TABLE revisiones MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;

-- AUTO_INCREMENT de la tabla users

ALTER TABLE users MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;

-- AUTO_INCREMENT de la tabla vehiculos

ALTER TABLE vehiculos MODIFY id int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

-- Restricciones para tablas volcadas

-- -- Filtros para la tabla almac_repues

ALTER TABLE almac_repues ADD CONSTRAINT almac_repues_almacen_id_foreign FOREIGN KEY (almacen_id) REFERENCES almacenes (id) ON DELETE CASCADE, ADD CONSTRAINT almac_repues_repuesto_id_foreign FOREIGN KEY (repuesto_id) REFERENCES repuestos (id) ON DELETE CASCADE;

-- -- Filtros para la tabla analis_asegu

ALTER TABLE analis_asegu ADD CONSTRAINT analis_asegu_analista_id_foreign FOREIGN KEY (analista_id) REFERENCES analistas (id) ON DELETE CASCADE, ADD CONSTRAINT analis_asegu_aseguradora_id_foreign FOREIGN KEY (aseguradora_id) REFERENCES aseguradoras (id) ON DELETE CASCADE;

-- -- Filtros para la tabla citas

ALTER TABLE citas ADD CONSTRAINT citas_reparacion_id_foreign FOREIGN KEY (reparacion_id) REFERENCES reparaciones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla corre_asegu

ALTER TABLE corre_asegu ADD CONSTRAINT corre_asegu_aseguradora_id_foreign FOREIGN KEY (aseguradora_id) REFERENCES aseguradoras (id) ON DELETE CASCADE, ADD CONSTRAINT corre_asegu_corredor_id_foreign FOREIGN KEY (corredor_id) REFERENCES corredores (id) ON DELETE CASCADE;

-- -- Filtros para la tabla facturaciones

ALTER TABLE facturaciones ADD CONSTRAINT facturaciones_reparacion_id_foreign FOREIGN KEY (reparacion_id) REFERENCES reparaciones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla image_receps

ALTER TABLE image_receps ADD CONSTRAINT image_receps_imagen_id_foreign FOREIGN KEY (imagen_id) REFERENCES imagenes (id) ON DELETE CASCADE, ADD CONSTRAINT image_receps_recepcion_id_foreign FOREIGN KEY (recepcion_id) REFERENCES recepciones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla image_reps

ALTER TABLE image_reps ADD CONSTRAINT image_reps_imagen_id_foreign FOREIGN KEY (imagen_id) REFERENCES imagenes (id) ON DELETE CASCADE, ADD CONSTRAINT image_reps_repuesto_id_foreign FOREIGN KEY (repuesto_id) REFERENCES repuestos (id) ON DELETE CASCADE;

-- -- Filtros para la tabla image_revs

ALTER TABLE image_revs ADD CONSTRAINT image_revs_imagen_id_foreign FOREIGN KEY (imagen_id) REFERENCES imagenes (id) ON DELETE CASCADE, ADD CONSTRAINT image_revs_revision_id_foreign FOREIGN KEY (revision_id) REFERENCES revisiones (id) ON DELETE CASCADE;

-- -- Filtros para la tabla mater_almac

ALTER TABLE mater_almac ADD CONSTRAINT mater_almac_almacen_id_foreign FOREIGN KEY (almacen_id) REFERENCES almacenes (id) ON DELETE CASCADE, ADD CONSTRAINT mater_almac_material_id_foreign FOREIGN KEY (material_id) REFERENCES materiales (id) ON DELETE CASCADE;

-- -- Filtros para la tabla polizas

ALTER TABLE polizas ADD CONSTRAINT polizas_aseguradora_id_foreign FOREIGN KEY (aseguradora_id) REFERENCES aseguradoras (id) ON DELETE CASCADE;

-- -- Filtros para la tabla recepciones

ALTER TABLE recepciones ADD CONSTRAINT recepciones_cita_id_foreign FOREIGN KEY (cita_id) REFERENCES citas (id) ON DELETE CASCADE;

-- -- Filtros para la tabla reparaciones

ALTER TABLE reparaciones ADD CONSTRAINT reparaciones_analista_id_foreign FOREIGN KEY (analista_id) REFERENCES analistas (id), ADD CONSTRAINT reparaciones_latonero_id_foreign FOREIGN KEY (latonero_id) REFERENCES operarios (id), ADD CONSTRAINT reparaciones_pintor_id_foreign FOREIGN KEY (pintor_id) REFERENCES operarios (id), ADD CONSTRAINT reparaciones_propietario_id_foreign FOREIGN KEY (propietario_id) REFERENCES propietarios (id), ADD CONSTRAINT reparaciones_vehiculo_id_foreign FOREIGN KEY (vehiculo_id) REFERENCES vehiculos (id);

-- -- Filtros para la tabla repue_repar

ALTER TABLE repue_repar ADD CONSTRAINT repue_repar_reparacion_id_foreign FOREIGN KEY (reparacion_id) REFERENCES reparaciones (id) ON DELETE CASCADE, ADD CONSTRAINT repue_repar_repuesto_id_foreign FOREIGN KEY (repuesto_id) REFERENCES repuestos (id) ON DELETE CASCADE;

-- -- Filtros para la tabla revisiones

ALTER TABLE revisiones ADD CONSTRAINT revisiones_vehiculo_id_foreign FOREIGN KEY (vehiculo_id) REFERENCES vehiculos (id) ON DELETE CASCADE;

/!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 /; `

OswardJr commented 7 years ago

@aranajhonny por qué lo sube de esa manera?

OswardJr commented 7 years ago

https://mega.nz/#!R1pDQBJa!xELdQmAzS2meKghI4fTwd1gksJSBG7HG7YY3-bjl1X0

aranajhonny commented 7 years ago

tenias que arrastrar el archivo

OswardJr commented 7 years ago

a.zip