Commit e8c9523c by Tobin

sql commit

parent 16c7e692
-- phpMyAdmin SQL Dump
-- version 4.7.9
-- version 4.8.3
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1:3306
-- Generation Time: Dec 30, 2018 at 07:28 PM
-- Server version: 5.7.21
-- PHP Version: 5.6.35
-- Host: db
-- Generation Time: Jan 04, 2019 at 12:37 PM
-- Server version: 5.6.41
-- PHP Version: 7.2.8
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
......@@ -28,17 +28,15 @@ SET time_zone = "+00:00";
-- Table structure for table `admin_users`
--
DROP TABLE IF EXISTS `admin_users`;
CREATE TABLE IF NOT EXISTS `admin_users` (
`id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `admin_users` (
`id` int(11) NOT NULL,
`username` varchar(100) NOT NULL,
`password` varchar(100) NOT NULL,
`user_type` tinyint(3) NOT NULL COMMENT '1 => Super Admin, 2 => Mechanic',
`display_name` varchar(200) NOT NULL,
`profile_image` varchar(500) NOT NULL,
`status` tinyint(4) NOT NULL DEFAULT '1',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=latin1;
`status` tinyint(4) NOT NULL DEFAULT '1'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
--
-- Dumping data for table `admin_users`
......@@ -56,9 +54,8 @@ INSERT INTO `admin_users` (`id`, `username`, `password`, `user_type`, `display_n
-- Table structure for table `customers`
--
DROP TABLE IF EXISTS `customers`;
CREATE TABLE IF NOT EXISTS `customers` (
`customer_id` int(20) NOT NULL AUTO_INCREMENT,
CREATE TABLE `customers` (
`customer_id` int(20) NOT NULL,
`first_name` varchar(50) NOT NULL,
`last_name` varchar(50) NOT NULL,
`phone` varchar(20) DEFAULT NULL,
......@@ -67,9 +64,8 @@ CREATE TABLE IF NOT EXISTS `customers` (
`profile_image` varchar(500) DEFAULT NULL,
`password` varchar(50) DEFAULT NULL,
`date_of_birth` varchar(200) DEFAULT NULL,
`status` tinyint(3) NOT NULL DEFAULT '1',
PRIMARY KEY (`customer_id`)
) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=latin1;
`status` tinyint(3) NOT NULL DEFAULT '1'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
--
-- Dumping data for table `customers`
......@@ -79,7 +75,9 @@ INSERT INTO `customers` (`customer_id`, `first_name`, `last_name`, `phone`, `ema
(1, 'Tobin', 'Thomas', '9995559194', '[email protected]', 'Techware', 'assets/uploads/services/1544417044_sniper.jpg', NULL, '05/05/1994', 1),
(2, 'Tobin', 'Thomas', '99955752194', '[email protected]', 'Techware', 'assets/uploads/services/1545036793_car1.jpg', NULL, '12/20/2018', 1),
(3, 'Tobin', 'Thomas', '9993242394', '[email protected]', 'Techware', 'assets/uploads/services/1545037023_images.jpg', 'e10adc3949ba59abbe56e057f20f883e', '12/11/2018', 1),
(7, 'tobin', 'thomas', '9995559194', '[email protected]', NULL, NULL, 'e10adc3949ba59abbe56e057f20f883e', NULL, 1);
(7, 'tobin', 'thomas', '9995559194', '[email protected]', NULL, 'assets/uploads/services/1545036793_car1.jpg', 'e10adc3949ba59abbe56e057f20f883e', NULL, 1),
(8, 'tobin', 'thomas', '8956235896', '[email protected]', NULL, 'assets/uploads/services/1545036793_car1.jpg', 'e10adc3949ba59abbe56e057f20f883e', NULL, 1),
(9, 'tobin', 'thomas test', NULL, '[email protected]', NULL, NULL, 'e10adc3949ba59abbe56e057f20f883e', NULL, 1);
-- --------------------------------------------------------
......@@ -87,9 +85,8 @@ INSERT INTO `customers` (`customer_id`, `first_name`, `last_name`, `phone`, `ema
-- Table structure for table `customer_vehicle`
--
DROP TABLE IF EXISTS `customer_vehicle`;
CREATE TABLE IF NOT EXISTS `customer_vehicle` (
`customer_veh_id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `customer_vehicle` (
`customer_veh_id` int(11) NOT NULL,
`customer_id` int(11) DEFAULT NULL,
`car_name` varchar(250) DEFAULT NULL,
`car_model` varchar(150) DEFAULT NULL,
......@@ -101,9 +98,8 @@ CREATE TABLE IF NOT EXISTS `customer_vehicle` (
`car_loc_lat` varchar(150) DEFAULT NULL,
`car_loc_lng` varchar(150) DEFAULT NULL,
`created_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`status` tinyint(3) NOT NULL DEFAULT '3',
PRIMARY KEY (`customer_veh_id`)
) ENGINE=MyISAM AUTO_INCREMENT=22 DEFAULT CHARSET=latin1;
`status` tinyint(3) NOT NULL DEFAULT '3'
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
--
-- Dumping data for table `customer_vehicle`
......@@ -129,16 +125,14 @@ INSERT INTO `customer_vehicle` (`customer_veh_id`, `customer_id`, `car_name`, `c
-- Table structure for table `forgot_password_link`
--
DROP TABLE IF EXISTS `forgot_password_link`;
CREATE TABLE IF NOT EXISTS `forgot_password_link` (
`id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `forgot_password_link` (
`id` int(11) NOT NULL,
`user_type` tinyint(3) DEFAULT NULL COMMENT '1=>Customer 2=>Mechanic',
`user_id` int(11) DEFAULT NULL,
`token` varchar(500) DEFAULT NULL,
`created_date` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
`status` tinyint(3) NOT NULL DEFAULT '1',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=latin1;
`status` tinyint(3) NOT NULL DEFAULT '1'
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
--
-- Dumping data for table `forgot_password_link`
......@@ -147,7 +141,8 @@ CREATE TABLE IF NOT EXISTS `forgot_password_link` (
INSERT INTO `forgot_password_link` (`id`, `user_type`, `user_id`, `token`, `created_date`, `status`) VALUES
(1, 1, NULL, '7e07594058e29d84ce3ff26e4b283fc3', '2018-12-30 13:12:20', 1),
(2, 1, 3, '747e195179012d145766f9ea9ee1f4aa', '2018-12-30 13:12:49', 1),
(3, 1, 3, '08be0c60b807ba994ca520d4c4f2d083', '2018-12-30 14:55:25', 1);
(3, 1, 3, '08be0c60b807ba994ca520d4c4f2d083', '2018-12-30 14:55:25', 1),
(4, 1, 3, '460fce2846e4bb57241d44745ede1482', '2018-12-31 08:56:06', 1);
-- --------------------------------------------------------
......@@ -155,22 +150,20 @@ INSERT INTO `forgot_password_link` (`id`, `user_type`, `user_id`, `token`, `crea
-- Table structure for table `issues`
--
DROP TABLE IF EXISTS `issues`;
CREATE TABLE IF NOT EXISTS `issues` (
`issue_id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `issues` (
`issue_id` int(11) NOT NULL,
`issue` varchar(500) NOT NULL,
`issue_image` varchar(500) DEFAULT NULL,
`status` tinyint(3) NOT NULL DEFAULT '1',
PRIMARY KEY (`issue_id`)
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=latin1;
`status` tinyint(3) NOT NULL DEFAULT '1'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
--
-- Dumping data for table `issues`
--
INSERT INTO `issues` (`issue_id`, `issue`, `issue_image`, `status`) VALUES
(9, 'Wheel Maintenance', 'assets/uploads/services/images8.jpg', 1),
(10, 'AC Maintenance', 'assets/uploads/services/car_ac.jpg', 1),
(9, 'Wheel Maintenance', 'assets/uploads/services/images8.jpg', 2),
(10, 'AC Maintenance', 'assets/uploads/services/car_ac.jpg', 2),
(11, 'Oil Change and General Service', 'assets/uploads/services/images9.jpg', 1),
(12, 'General Service', 'assets/uploads/services/Twitch_KingpinSkin_old2_HD1.jpg', 1);
......@@ -180,17 +173,15 @@ INSERT INTO `issues` (`issue_id`, `issue`, `issue_image`, `status`) VALUES
-- Table structure for table `issues_category`
--
DROP TABLE IF EXISTS `issues_category`;
CREATE TABLE IF NOT EXISTS `issues_category` (
`issue_cat_id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `issues_category` (
`issue_cat_id` int(11) NOT NULL,
`issue_id` int(11) DEFAULT NULL,
`issue_category` varchar(500) DEFAULT NULL,
`issue_cat_image` varchar(500) DEFAULT NULL,
`default_service_fee` double DEFAULT NULL,
`default_description` longtext,
`status` tinyint(3) NOT NULL DEFAULT '1',
PRIMARY KEY (`issue_cat_id`)
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=latin1;
`status` tinyint(3) NOT NULL DEFAULT '1'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
--
-- Dumping data for table `issues_category`
......@@ -208,9 +199,8 @@ INSERT INTO `issues_category` (`issue_cat_id`, `issue_id`, `issue_category`, `is
-- Table structure for table `mechanic`
--
DROP TABLE IF EXISTS `mechanic`;
CREATE TABLE IF NOT EXISTS `mechanic` (
`id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `mechanic` (
`id` int(11) NOT NULL,
`mechanic_id` int(11) NOT NULL,
`shop_id` int(11) NOT NULL DEFAULT '0',
`first_name` varchar(50) NOT NULL,
......@@ -224,9 +214,8 @@ CREATE TABLE IF NOT EXISTS `mechanic` (
`licence_number` varchar(250) DEFAULT NULL,
`licence_exp_date` varchar(250) DEFAULT NULL,
`location_lat` varchar(30) DEFAULT NULL,
`location_lng` varchar(30) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=latin1;
`location_lng` varchar(30) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
--
-- Dumping data for table `mechanic`
......@@ -243,17 +232,15 @@ INSERT INTO `mechanic` (`id`, `mechanic_id`, `shop_id`, `first_name`, `last_name
-- Table structure for table `mechanic_issues`
--
DROP TABLE IF EXISTS `mechanic_issues`;
CREATE TABLE IF NOT EXISTS `mechanic_issues` (
`id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `mechanic_issues` (
`id` int(11) NOT NULL,
`issue_id` int(11) DEFAULT NULL,
`issue_cat_id` int(11) DEFAULT NULL,
`mechanic_id` int(11) DEFAULT NULL,
`custom_description` longtext,
`custom_service_fee` double NOT NULL DEFAULT '0',
`status` tinyint(3) NOT NULL DEFAULT '1',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=27 DEFAULT CHARSET=latin1;
`status` tinyint(3) NOT NULL DEFAULT '1'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
--
-- Dumping data for table `mechanic_issues`
......@@ -274,16 +261,14 @@ INSERT INTO `mechanic_issues` (`id`, `issue_id`, `issue_cat_id`, `mechanic_id`,
-- Table structure for table `mechanic_shop`
--
DROP TABLE IF EXISTS `mechanic_shop`;
CREATE TABLE IF NOT EXISTS `mechanic_shop` (
`shop_id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `mechanic_shop` (
`shop_id` int(11) NOT NULL,
`shop_name` varchar(250) NOT NULL,
`address` varchar(500) NOT NULL,
`phone` varchar(15) NOT NULL,
`email_id` varchar(150) NOT NULL,
`status` tinyint(3) NOT NULL DEFAULT '1',
PRIMARY KEY (`shop_id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1;
`status` tinyint(3) NOT NULL DEFAULT '1'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
--
-- Dumping data for table `mechanic_shop`
......@@ -299,9 +284,8 @@ INSERT INTO `mechanic_shop` (`shop_id`, `shop_name`, `address`, `phone`, `email_
-- Table structure for table `setting`
--
DROP TABLE IF EXISTS `setting`;
CREATE TABLE IF NOT EXISTS `setting` (
`id` int(11) NOT NULL AUTO_INCREMENT,
CREATE TABLE `setting` (
`id` int(11) NOT NULL,
`title` varchar(250) NOT NULL,
`title_short` varchar(250) NOT NULL,
`site_logo` varchar(150) NOT NULL,
......@@ -313,9 +297,8 @@ CREATE TABLE IF NOT EXISTS `setting` (
`smtp_password` varchar(150) NOT NULL,
`google_api_key` varchar(500) DEFAULT NULL,
`vin_audit_url` varchar(500) DEFAULT NULL,
`vin_audit_api` varchar(500) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=latin1;
`vin_audit_api` varchar(500) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
--
-- Dumping data for table `setting`
......@@ -323,6 +306,134 @@ CREATE TABLE IF NOT EXISTS `setting` (
INSERT INTO `setting` (`id`, `title`, `title_short`, `site_logo`, `fav_icon`, `country_flag`, `currency`, `smtp_host`, `smtp_username`, `smtp_password`, `google_api_key`, `vin_audit_url`, `vin_audit_api`) VALUES
(1, 'd-Car Fixers', 'd-CarFixers', 'assets/uploads/services/1539680946_1523012036_hj.jpg', 'assets/uploads/services/1539680946_1523540473_guenstig_reifen.png', 'US', 'USD', '[email protected]', 'AIzaSyC9JX3BZZfx2S6GQieC_PqjuJdUbZ7_wyM1', 'Golden_1234', 'AIzaSyCcc-YDSJyDpehNE6qfntfWpEQ4uS4aq6A', 'https://specifications.vinaudit.com/getspecifications.php', 'VA_DEMO_KEY');
--
-- Indexes for dumped tables
--
--
-- Indexes for table `admin_users`
--
ALTER TABLE `admin_users`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `customers`
--
ALTER TABLE `customers`
ADD PRIMARY KEY (`customer_id`);
--
-- Indexes for table `customer_vehicle`
--
ALTER TABLE `customer_vehicle`
ADD PRIMARY KEY (`customer_veh_id`);
--
-- Indexes for table `forgot_password_link`
--
ALTER TABLE `forgot_password_link`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `issues`
--
ALTER TABLE `issues`
ADD PRIMARY KEY (`issue_id`);
--
-- Indexes for table `issues_category`
--
ALTER TABLE `issues_category`
ADD PRIMARY KEY (`issue_cat_id`);
--
-- Indexes for table `mechanic`
--
ALTER TABLE `mechanic`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `mechanic_issues`
--
ALTER TABLE `mechanic_issues`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `mechanic_shop`
--
ALTER TABLE `mechanic_shop`
ADD PRIMARY KEY (`shop_id`);
--
-- Indexes for table `setting`
--
ALTER TABLE `setting`
ADD PRIMARY KEY (`id`);
--
-- AUTO_INCREMENT for dumped tables
--
--
-- AUTO_INCREMENT for table `admin_users`
--
ALTER TABLE `admin_users`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=13;
--
-- AUTO_INCREMENT for table `customers`
--
ALTER TABLE `customers`
MODIFY `customer_id` int(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10;
--
-- AUTO_INCREMENT for table `customer_vehicle`
--
ALTER TABLE `customer_vehicle`
MODIFY `customer_veh_id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=22;
--
-- AUTO_INCREMENT for table `forgot_password_link`
--
ALTER TABLE `forgot_password_link`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;
--
-- AUTO_INCREMENT for table `issues`
--
ALTER TABLE `issues`
MODIFY `issue_id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=13;
--
-- AUTO_INCREMENT for table `issues_category`
--
ALTER TABLE `issues_category`
MODIFY `issue_cat_id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;
--
-- AUTO_INCREMENT for table `mechanic`
--
ALTER TABLE `mechanic`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7;
--
-- AUTO_INCREMENT for table `mechanic_issues`
--
ALTER TABLE `mechanic_issues`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=27;
--
-- AUTO_INCREMENT for table `mechanic_shop`
--
ALTER TABLE `mechanic_shop`
MODIFY `shop_id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;
--
-- AUTO_INCREMENT for table `setting`
--
ALTER TABLE `setting`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
COMMIT;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment