-- https://www.phpmyadmin.net/
--

START TRANSACTION;



--
-- Database: `toundra`
--

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

--
-- Table structure for table `cameras`
--

CREATE TABLE `cameras` (
  `id` int(11) NOT NULL,
  `user_id` int(11) NOT NULL,
  `name` varchar(255) NOT NULL,
  `intrinsic` text NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `cameras`
--

INSERT INTO `cameras` (`id`, `user_id`, `name`, `intrinsic`, `created_at`, `updated_at`) VALUES
(1, 1, 'Camera de daniel', 'This is some info about camera 1', '2019-04-16 21:35:02', '2019-04-24 20:03:42'),
(5, 1, 'Camera 2b', 'Some info about camera b', '2019-04-25 15:16:00', '2019-04-28 01:13:01'),
(9, 1, 'Camera 3', 'Some info about camera 3', '2019-04-28 01:13:15', '2019-04-28 01:13:15');

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

--
-- Table structure for table `scenarios`
--

CREATE TABLE `scenarios` (
  `id` int(11) NOT NULL,
  `user_id` int(11) NOT NULL,
  `protocol_id` int(11) NOT NULL,
  `three_d_id` int(11) NOT NULL,
  `name` varchar(255) NOT NULL,
  `description` text NOT NULL,
  `json_data` text NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `scenarios`
--

INSERT INTO `scenarios` (`id`, `user_id`, `protocol_id`, `three_d_id`, `name`, `description`, `json_data`, `created_at`, `updated_at`) VALUES
(1, 3, 1, 4, 'Admin', 'Foobar', '{}', '2019-04-25 20:09:56', '2019-04-25 20:09:56'),
(2, 1, 1, 11, 'Foo api', 'foobar api', '{}', '2019-04-28 01:38:11', '2019-04-28 01:38:11'),
(4, 1, 1, 1, 'Bar', 'Bar description', '{ \"foo\" : \"bar\" }', '2019-04-25 15:20:52', '2019-04-25 15:18:24'),
(11, 3, 1, 3, 'Admin Create', 'Foo', '{}', '2019-04-25 20:11:53', '2019-04-25 20:11:53'),
(15, 1, 1, 11, 'new Foo api', 'new foobar api', '{}', '2019-04-28 01:38:18', '2019-04-28 01:38:18');

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

--
-- Table structure for table `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;

--
-- Dumping data for table `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);

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

--
-- Table structure for table `protocols`
--

CREATE TABLE `protocols` (
  `id` int(11) NOT NULL,
  `name` varchar(255) NOT NULL,
  `description` text NOT NULL,
  `json_data` text NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `protocols`
--

INSERT INTO `protocols` (`id`, `name`, `description`, `json_data`, `created_at`, `updated_at`) VALUES
(1, 'TCP', 'bla bla23', '{\"string\": \"Hello World2\"}', '2019-04-17 02:06:17', '2019-04-27 00:34:08');

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

--
-- Table structure for table `reports`
--

CREATE TABLE `reports` (
  `id` int(11) NOT NULL,
  `scenario_id` int(11) NOT NULL,
  `instance_id` varchar(255) NOT NULL,
  `json_data` text NOT NULL,
  `active` tinyint(4) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `reports`
--

INSERT INTO `reports` (`id`, `scenario_id`, `instance_id`, `json_data`, `active`, `created_at`, `updated_at`) VALUES
(5, 1, 'Another admin report', '', 0, '2019-04-26 20:37:55', '2019-04-26 20:37:55'),
(8, 4, 'API foo created', '{}', 0, '2019-04-28 01:43:02', '2019-04-30 19:43:05');

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

--
-- Table structure for table `scenes`
--

CREATE TABLE `scenes` (
  `id` int(11) NOT NULL,
  `user_id` int(11) NOT NULL,
  `camera_id` int(11) NOT NULL,
  `name` varchar(255) NOT NULL,
  `transforms` text NOT NULL,
  `active` tinyint(1) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `scenes`
--

INSERT INTO `scenes` (`id`, `user_id`, `camera_id`, `name`, `transforms`, `active`, `created_at`, `updated_at`) VALUES
(3, 1, 9, 'Blood', '{\"string\": \"Hello World\"}', 1, '2019-04-17 01:11:48', '2019-04-28 01:43:46'),
(4, 7, 2, 'Blood admin', '{\"string\": \"Hello World\"}', 1, '2019-04-17 01:12:09', '2019-04-22 20:00:38'),
(8, 1, 5, 'Raz scene', '{}', 0, '2019-04-25 20:27:01', '2019-04-25 20:27:01'),
(9, 1, 9, 'scene 4', '{\"string\": \"Hello World\"}', 1, '2019-04-28 01:43:54', '2019-04-28 01:43:54');

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

--
-- Table structure for table `three_ds`
--

CREATE TABLE `three_ds` (
  `id` int(11) NOT NULL,
  `user_id` int(11) NOT NULL,
  `name` varchar(255) NOT NULL,
  `description` text NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `three_ds`
--

INSERT INTO `three_ds` (`id`, `user_id`, `name`, `description`, `created_at`, `updated_at`) VALUES
(2, 1, 'model5', 'This is a nice description', '2019-04-16 22:14:29', '2019-04-22 18:23:35'),
(3, 4, 'John deere', '{\"string\": \"Hello World\"}', '2019-04-17 03:19:16', '2019-04-22 20:00:10'),
(4, 1, 'model5 old', '{\"string\": \"Hello World\"}', '2019-04-22 18:06:37', '2019-04-22 20:05:10'),
(5, 1, 'model5 new', 'This is a better description', '2019-04-22 18:23:52', '2019-04-22 20:05:03'),
(6, 1, 'asdf', 'asdf', '2019-04-26 23:37:31', '2019-04-26 23:37:31'),
(10, 5, 'Lennys model', 'Some desc', '2019-04-27 00:33:00', '2019-04-27 00:33:00'),
(11, 1, 'model5', 'This is a nice description', '2019-04-27 00:50:54', '2019-04-28 01:45:13'),
(12, 7, 'Rami with file', 'some desc', '2019-04-27 00:51:55', '2019-04-27 00:51:55'),
(15, 8, 'qwer', 'qwer', '2019-04-29 17:13:25', '2019-04-29 17:13:25');

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

--
-- Table structure for table `three_d_files`
--

CREATE TABLE `three_d_files` (
  `id` int(11) NOT NULL,
  `three_d_id` int(11) NOT NULL,
  `filename` varchar(255) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `three_d_files`
--

INSERT INTO `three_d_files` (`id`, `three_d_id`, `filename`, `created_at`) VALUES
(6, 10, 'zzt7meingq.stl', '2019-04-27 00:33:00'),
(8, 12, 'bxyw8x5o0t.stl', '2019-04-27 00:52:03'),
(9, 11, 'senrbm22tf.stl', '2019-04-27 00:53:01');

--
-- Indexes for dumped tables
--

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

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

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

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

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

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

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

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

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `cameras`
--
ALTER TABLE `cameras`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10;

--
-- AUTO_INCREMENT for table `scenarios`
--
ALTER TABLE `scenarios`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=17;

--
-- AUTO_INCREMENT for table `migrations`
--
ALTER TABLE `migrations`
  MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

--
-- AUTO_INCREMENT for table `protocols`
--
ALTER TABLE `protocols`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;

--
-- AUTO_INCREMENT for table `reports`
--
ALTER TABLE `reports`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=9;

--
-- AUTO_INCREMENT for table `scenes`
--
ALTER TABLE `scenes`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;

--
-- AUTO_INCREMENT for table `three_ds`
--
ALTER TABLE `three_ds`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=16;

--
-- AUTO_INCREMENT for table `three_d_files`
--
ALTER TABLE `three_d_files`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;
COMMIT;

