Created
June 23, 2025 07:18
-
-
Save hiraarif12/9e76e26e09b76cb4eb80354737d07330 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- phpMyAdmin SQL Dump | |
-- version 5.2.1 | |
-- https://www.phpmyadmin.net/ | |
-- | |
-- Host: localhost:3306 | |
-- Generation Time: Jun 23, 2025 at 06:11 AM | |
-- Server version: 8.0.30 | |
-- PHP Version: 8.1.10 | |
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; | |
START TRANSACTION; | |
SET time_zone = "+00:00"; | |
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; | |
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; | |
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; | |
/*!40101 SET NAMES utf8mb4 */; | |
-- | |
-- Database: `berich_ecommerce` | |
-- | |
-- -------------------------------------------------------- | |
-- | |
-- Table structure for table `cart` | |
-- | |
CREATE TABLE `cart` ( | |
`id` int NOT NULL, | |
`name` varchar(255) DEFAULT NULL, | |
`price` double DEFAULT NULL, | |
`quantity` int DEFAULT NULL, | |
`totalPrice` double DEFAULT NULL, | |
`image` longtext | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; | |
-- -------------------------------------------------------- | |
-- | |
-- Table structure for table `contacts` | |
-- | |
CREATE TABLE `contacts` ( | |
`id` int NOT NULL, | |
`name` varchar(100) DEFAULT NULL, | |
`email` varchar(150) DEFAULT NULL, | |
`message` longtext, | |
`submittedAt` datetime(3) DEFAULT CURRENT_TIMESTAMP(3) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; | |
-- | |
-- Dumping data for table `contacts` | |
-- | |
INSERT INTO `contacts` (`id`, `name`, `email`, `message`, `submittedAt`) VALUES | |
(1, 'hira arif', 'hiraariftrader@gmail.com', 'i want printed bag', '2025-06-11 13:07:25.630'), | |
(2, 'Mahnoor Shahid', 'hiraariftrader@gmail.com', 'testing', '2025-06-11 13:19:42.287'), | |
(3, 'Mahnoor Shahid', 'hiraariftrader@gmail.com', 'eqeaea', '2025-06-12 10:32:27.680'); | |
-- -------------------------------------------------------- | |
-- | |
-- Table structure for table `navbar_links` | |
-- | |
CREATE TABLE `navbar_links` ( | |
`id` int NOT NULL, | |
`title` varchar(100) DEFAULT NULL, | |
`url` varchar(200) DEFAULT NULL, | |
`role` varchar(20) DEFAULT NULL | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; | |
-- | |
-- Dumping data for table `navbar_links` | |
-- | |
INSERT INTO `navbar_links` (`id`, `title`, `url`, `role`) VALUES | |
(1, 'Home', '/', 'both'), | |
(2, 'Shop', '/shop', 'both'), | |
(3, 'Contact', '/contact', 'both'), | |
(4, 'Reviews', '/reviews', 'both'), | |
(5, 'Orders', '/admin/orders', 'admin'), | |
(6, 'Add Product', '/admin/add-product', 'admin'), | |
(7, 'View Contacts', '/admin/contacts', 'admin'); | |
-- -------------------------------------------------------- | |
-- | |
-- Table structure for table `orders` | |
-- | |
CREATE TABLE `orders` ( | |
`id` int NOT NULL, | |
`firstName` varchar(100) DEFAULT NULL, | |
`lastName` varchar(100) DEFAULT NULL, | |
`contactNo` varchar(20) DEFAULT NULL, | |
`address` longtext, | |
`paymentMethod` varchar(50) DEFAULT NULL, | |
`productName` varchar(200) DEFAULT NULL, | |
`productPrice` decimal(10,2) DEFAULT NULL, | |
`productImage` longtext, | |
`quantity` int DEFAULT NULL, | |
`totalPrice` decimal(10,2) DEFAULT NULL, | |
`orderDate` datetime(3) DEFAULT CURRENT_TIMESTAMP(3), | |
`isCompleted` tinyint DEFAULT '0' | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; | |
-- | |
-- Dumping data for table `orders` | |
-- | |
-- -------------------------------------------------------- | |
-- | |
-- Table structure for table `products` | |
-- | |
CREATE TABLE `products` ( | |
`id` int NOT NULL, | |
`name` varchar(255) NOT NULL, | |
`description` longtext, | |
`price` decimal(10,2) NOT NULL, | |
`image` longtext, | |
`created_at` datetime(3) DEFAULT CURRENT_TIMESTAMP(3) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; | |
-- | |
-- Dumping data for table `products` | |
-- | |
-- -------------------------------------------------------- | |
-- | |
-- Table structure for table `reviews` | |
-- | |
CREATE TABLE `reviews` ( | |
`id` int NOT NULL, | |
`name` varchar(100) DEFAULT NULL, | |
`review` longtext, | |
`image` longtext | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; | |
-- | |
-- Dumping data for table `reviews` | |
-- | |
-- -------------------------------------------------------- | |
-- | |
-- Table structure for table `users` | |
-- | |
CREATE TABLE `users` ( | |
`id` int NOT NULL, | |
`username` varchar(100) NOT NULL, | |
`password` varchar(100) NOT NULL, | |
`role` varchar(50) NOT NULL | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; | |
-- | |
-- Dumping data for table `users` | |
-- | |
INSERT INTO `users` (`id`, `username`, `password`, `role`) VALUES | |
(1, 'admin', 'admin123', 'admin'); | |
-- | |
-- Indexes for dumped tables | |
-- | |
-- | |
-- Indexes for table `cart` | |
-- | |
ALTER TABLE `cart` | |
ADD PRIMARY KEY (`id`); | |
-- | |
-- Indexes for table `contacts` | |
-- | |
ALTER TABLE `contacts` | |
ADD PRIMARY KEY (`id`); | |
-- | |
-- Indexes for table `navbar_links` | |
-- | |
ALTER TABLE `navbar_links` | |
ADD PRIMARY KEY (`id`); | |
-- | |
-- Indexes for table `orders` | |
-- | |
ALTER TABLE `orders` | |
ADD PRIMARY KEY (`id`); | |
-- | |
-- Indexes for table `products` | |
-- | |
ALTER TABLE `products` | |
ADD PRIMARY KEY (`id`); | |
-- | |
-- Indexes for table `reviews` | |
-- | |
ALTER TABLE `reviews` | |
ADD PRIMARY KEY (`id`); | |
-- | |
-- Indexes for table `users` | |
-- | |
ALTER TABLE `users` | |
ADD PRIMARY KEY (`id`), | |
ADD UNIQUE KEY `username` (`username`); | |
-- | |
-- AUTO_INCREMENT for dumped tables | |
-- | |
-- | |
-- AUTO_INCREMENT for table `cart` | |
-- | |
ALTER TABLE `cart` | |
MODIFY `id` int NOT NULL AUTO_INCREMENT; | |
-- | |
-- AUTO_INCREMENT for table `contacts` | |
-- | |
ALTER TABLE `contacts` | |
MODIFY `id` int NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; | |
-- | |
-- AUTO_INCREMENT for table `navbar_links` | |
-- | |
ALTER TABLE `navbar_links` | |
MODIFY `id` int NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; | |
-- | |
-- AUTO_INCREMENT for table `orders` | |
-- | |
ALTER TABLE `orders` | |
MODIFY `id` int NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; | |
-- | |
-- AUTO_INCREMENT for table `products` | |
-- | |
ALTER TABLE `products` | |
MODIFY `id` int NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; | |
-- | |
-- AUTO_INCREMENT for table `reviews` | |
-- | |
ALTER TABLE `reviews` | |
MODIFY `id` int NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; | |
-- | |
-- AUTO_INCREMENT for table `users` | |
-- | |
ALTER TABLE `users` | |
MODIFY `id` int NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; | |
COMMIT; | |
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; | |
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; | |
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment