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

START TRANSACTION;



--
-- Database: `resv2`
--

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

--
-- Table structure for table `backup`
--

CREATE TABLE `backup` (
  `id` int(11) NOT NULL,
  `name` text NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `backup`
--

INSERT INTO `backup` (`id`, `name`, `added_on`) VALUES
(1, 'project_stockv2_2022-02-11-12-10-01BB.sql', '2022-02-11 12:10:02'),
(2, 'project_stockv2_2022-02-11-12-10-54BB.sql', '2022-02-11 12:10:55'),
(3, 'project_stockv2_2022-02-11-12-11-21BB.sql', '2022-02-11 12:11:22'),
(4, 'project_stockv2_2022-02-11-12-13-46BB.sql', '2022-02-11 12:13:48');

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

--
-- Table structure for table `branches`
--

CREATE TABLE `branches` (
  `id` int(11) NOT NULL,
  `address` varchar(250) NOT NULL,
  `phone` varchar(50) NOT NULL,
  `address_en` varchar(250) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `name` varchar(250) NOT NULL,
  `name_en` varchar(250) NOT NULL,
  `created_by` int(11) NOT NULL,
  `box` varchar(50) NOT NULL,
  `zip` varchar(50) NOT NULL,
  `website` int(1) NOT NULL DEFAULT 0,
  `price_rate` float NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `branches`
--

INSERT INTO `branches` (`id`, `address`, `phone`, `address_en`, `deleted_01`, `name`, `name_en`, `created_by`, `box`, `zip`, `website`, `price_rate`) VALUES
(1, 'الحمراء', '96222096', 'Hamra', 0, 'الحمراء', 'Hamra', 0, '36', '617', 1, 0),
(2, 'بهلا جامع السلطان قابوس', '', 'Bahla sultan qaboos', 0, 'بهلا', 'bahla', 0, '', '', 1, 10);

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

--
-- Table structure for table `cake`
--

CREATE TABLE `cake` (
  `id` int(11) NOT NULL,
  `customer` varchar(300) NOT NULL,
  `phone` varchar(50) NOT NULL,
  `type` varchar(300) NOT NULL,
  `weight` float NOT NULL,
  `cake_number` int(11) NOT NULL,
  `text` text NOT NULL,
  `files` text NOT NULL,
  `branch` varchar(300) NOT NULL,
  `note` text NOT NULL,
  `ddate` varchar(50) NOT NULL,
  `price` float NOT NULL,
  `paid` float NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `added_by` int(11) NOT NULL,
  `status` varchar(100) NOT NULL DEFAULT 'Active',
  `deleted_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `cake_payment`
--

CREATE TABLE `cake_payment` (
  `id` int(11) NOT NULL,
  `cake_id` int(11) NOT NULL,
  `paid_change` varchar(50) NOT NULL,
  `added_by` int(11) NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `pay_by` varchar(50) NOT NULL DEFAULT 'Cash'
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `cake_settings`
--

CREATE TABLE `cake_settings` (
  `id` int(11) NOT NULL,
  `types` longtext NOT NULL,
  `branches` text NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `cake_settings`
--

INSERT INTO `cake_settings` (`id`, `types`, `branches`) VALUES
(1, '{\"0\":\"Cream Cake \",\"2\":\"Chocolate Cake\",\"3\":\"Sugar past Cake \",\"4\":\"Red Velvet Cake\",\"5\":\"Carrot Cake\",\"6\":\"Cheese Cake\",\"7\":\"Photo Cake\",\"8\":\"Ice Cream Cake\",\"9\":\"Glaze Cake\"}', '[\"1\",\"2\"]');

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

--
-- Table structure for table `cake_update`
--

CREATE TABLE `cake_update` (
  `update_id` int(11) NOT NULL,
  `id` int(11) NOT NULL,
  `customer` varchar(200) NOT NULL,
  `phone` varchar(50) NOT NULL,
  `ddate` varchar(200) NOT NULL,
  `files` text NOT NULL,
  `note` text NOT NULL,
  `price` float NOT NULL,
  `paid` float NOT NULL,
  `type` varchar(150) NOT NULL,
  `branch` varchar(200) NOT NULL,
  `text` text NOT NULL,
  `weight` varchar(50) NOT NULL,
  `cake_number` int(11) NOT NULL,
  `added_on` varchar(100) NOT NULL,
  `added_by` int(11) NOT NULL,
  `updated_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `updated_by` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL,
  `status` varchar(50) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `cake_update`
--

INSERT INTO `cake_update` (`update_id`, `id`, `customer`, `phone`, `ddate`, `files`, `note`, `price`, `paid`, `type`, `branch`, `text`, `weight`, `cake_number`, `added_on`, `added_by`, `updated_on`, `updated_by`, `deleted_01`, `status`) VALUES
(1, 1, 'Alfarouq Nasser Alkhayari', '96222096', '07-07-2020 12:33pm', '', 'Etiam rhoncus. Sed mollis, eros et ultrices tempus, mauris ipsum aliquam libero, non adipiscing dolor urna a orci. Praesent venenatis metus at tortor pulvinar varius. Nunc sed turpis. Vivamus euismod mauris.', 20, 5, 'Chocolate Cake', 'Alhamra', 'Read more', '20', 1, '2020-07-06 12:34:08', 1, '2020-10-28 07:05:20', 1, 0, ''),
(2, 2, 'Alfarouq Nasser Alkhayari', '96222096', '30-10-2020 11:14am', '', '3213213\r\n3213\r\n3232131', 20, 0, 'Red Velvet Cake', 'Alhamra', '1232913\r\n\r\n23213\r\n321321', '0', 1, '2020-10-28 11:10:21', 1, '2020-10-28 07:13:01', 1, 0, ''),
(3, 2, 'Alfarouq Nasser Alkhayari', '96222096', '30-10-2020 12:00pm', '', '3213213\r\n3213\r\n3232131', 20, 20, 'Red Velvet Cake', 'Alhamra', '1232913\r\n\r\n23213\r\n321321', '0', 1, '2020-10-28 11:10:21', 1, '2020-12-17 18:57:15', 1, 0, '');

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

--
-- Table structure for table `cash_d`
--

CREATE TABLE `cash_d` (
  `id` int(11) NOT NULL,
  `amount` float NOT NULL,
  `type` varchar(50) NOT NULL DEFAULT 'stage',
  `created_by` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `cash` text DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `cash_d`
--

INSERT INTO `cash_d` (`id`, `amount`, `type`, `created_by`, `created_at`, `deleted_01`, `cash`) VALUES
(3, 50, 'stage', 1, '2022-06-04 15:47:17', 0, NULL),
(4, 20, 'stage', 1, '2022-06-19 12:36:23', 0, NULL),
(5, 0, 'stage', 1, '2023-08-14 11:44:26', 0, NULL);

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

--
-- Table structure for table `categories`
--

CREATE TABLE `categories` (
  `id` int(11) NOT NULL,
  `name` varchar(100) NOT NULL,
  `file` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL,
  `printer` varchar(50) NOT NULL,
  `print` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `discount` float NOT NULL DEFAULT 0,
  `discount_qty` int(11) NOT NULL DEFAULT 1
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `categories`
--

INSERT INTO `categories` (`id`, `name`, `file`, `created_at`, `created_by`, `printer`, `print`, `deleted_01`, `discount`, `discount_qty`) VALUES
(1, 'Drink', 0, '2022-10-07 11:20:30', 1, '', 0, 0, 0, 1),
(2, 'BBQ', 0, '2022-10-07 11:20:36', 1, '', 0, 0, 0, 1);

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

--
-- Table structure for table `cms`
--

CREATE TABLE `cms` (
  `id` int(11) NOT NULL,
  `title` varchar(150) NOT NULL,
  `subtitle` text NOT NULL,
  `about` text NOT NULL,
  `openhours` text NOT NULL,
  `contacts` text NOT NULL,
  `galley` text NOT NULL,
  `description` text NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `cms`
--

INSERT INTO `cms` (`id`, `title`, `subtitle`, `about`, `openhours`, `contacts`, `galley`, `description`) VALUES
(1, '3123', '321', '3213', '321', '321', '', '321');

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

--
-- Table structure for table `customers`
--

CREATE TABLE `customers` (
  `id` int(11) NOT NULL,
  `name` varchar(100) NOT NULL,
  `car` varchar(50) NOT NULL,
  `phone` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `points` float UNSIGNED NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `delivery`
--

CREATE TABLE `delivery` (
  `id` int(11) NOT NULL,
  `name` varchar(255) NOT NULL,
  `rate` int(11) NOT NULL DEFAULT 0,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `delivery`
--

INSERT INTO `delivery` (`id`, `name`, `rate`, `created_at`, `created_by`) VALUES
(1, 'test', 25, '2023-08-14 10:33:10', 1);

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

--
-- Table structure for table `dishes`
--

CREATE TABLE `dishes` (
  `id` int(11) NOT NULL,
  `name` varchar(200) NOT NULL,
  `category_id` int(11) NOT NULL,
  `description` text NOT NULL,
  `sizes` text NOT NULL,
  `prices` text NOT NULL,
  `addons` text NOT NULL,
  `ingredients` text NOT NULL,
  `file` int(11) NOT NULL,
  `tax_id` int(11) NOT NULL DEFAULT 1,
  `ready_in` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL,
  `updated_at` timestamp NULL DEFAULT NULL ON UPDATE current_timestamp(),
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `aprices` text NOT NULL,
  `updated_by` int(11) DEFAULT NULL,
  `discount` float NOT NULL,
  `website` int(1) NOT NULL DEFAULT 0,
  `favorite` int(1) NOT NULL DEFAULT 0,
  `discount_qty` int(11) NOT NULL DEFAULT 1,
  `max_discount` float NOT NULL,
  `name_ar` varchar(50) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `dishes`
--

INSERT INTO `dishes` (`id`, `name`, `category_id`, `description`, `sizes`, `prices`, `addons`, `ingredients`, `file`, `tax_id`, `ready_in`, `created_at`, `created_by`, `updated_at`, `deleted_01`, `aprices`, `updated_by`, `discount`, `website`, `favorite`, `discount_qty`, `max_discount`, `name_ar`) VALUES
(1, 'Water', 1, '', '[\"500ml\"]', '[\"0.1\"]', '[]', '[]', 0, 1, 0, '2022-10-07 11:21:22', 1, '2022-11-13 15:08:14', 1, '[]', 1, 1, 1, 0, 1, 55, ''),
(2, 'Water', 1, '', '[\"500ml\"]', '[\"0.1\"]', '[]', '[]', 190, 1, 0, '2022-10-07 11:23:11', 1, '2023-08-14 09:47:09', 0, '[]', 1, 1, 1, 0, 1, 55, ''),
(3, 'Water', 1, '', '[\"500ml\"]', '[\"0.1\"]', '[]', '[]', 191, 1, 0, '2022-10-07 11:23:30', 1, '2022-11-13 15:08:14', 1, '[]', 1, 1, 1, 0, 1, 55, ''),
(4, 'BBQ Plate', 2, '', '[\"Small\",\"Mid\",\"Larg\"]', '[\"2\",\"3\",\"5\"]', '[\"Ships\",\"Homos\"]', '[]', 192, 1, 0, '2022-10-07 11:24:50', 1, '2022-11-13 15:08:14', 0, '[\"0.2\",\"0.2\"]', 1, 1, 1, 0, 1, 55, ''),
(5, 'Pepsi', 1, '', '[\"0.300\",\"0.500\"]', '[\"0.3\",\"0.5\"]', '[]', '[]', 193, 1, 0, '2022-10-07 11:27:57', 1, '2022-11-13 15:08:14', 0, '[]', 1, 1, 1, 0, 1, 55, ''),
(6, 'Sawarma', 2, '', '[\"Sandwich\",\"Sarukh\"]', '[\"0.3\",\"0.6\"]', '[\"No matinees\"]', '[]', 194, 1, 0, '2022-10-07 11:29:55', 1, '2022-11-13 15:08:14', 0, '[\"\"]', 1, 1, 1, 0, 1, 55, '');

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

--
-- Table structure for table `email_q`
--

CREATE TABLE `email_q` (
  `id` int(11) NOT NULL,
  `template` text NOT NULL,
  `send_to` text NOT NULL,
  `title` varchar(250) NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `sent_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `expenses`
--

CREATE TABLE `expenses` (
  `id` int(11) NOT NULL,
  `e_date` varchar(50) NOT NULL,
  `type` varchar(100) NOT NULL,
  `amount` float NOT NULL,
  `note` text NOT NULL,
  `file` text NOT NULL,
  `created_by` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `updated_by` int(11) NOT NULL,
  `updated_at` timestamp NULL DEFAULT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `cash_d` int(11) NOT NULL DEFAULT 0,
  `recurring` int(1) NOT NULL DEFAULT 0,
  `recurring_type` varchar(250) NOT NULL,
  `expensses_id` int(11) DEFAULT NULL,
  `branch_id` int(11) NOT NULL DEFAULT 1
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `expenses`
--

INSERT INTO `expenses` (`id`, `e_date`, `type`, `amount`, `note`, `file`, `created_by`, `created_at`, `updated_by`, `updated_at`, `deleted_01`, `cash_d`, `recurring`, `recurring_type`, `expensses_id`, `branch_id`) VALUES
(1, '2022-06-04', 'test', 10, '', '', 1, '2022-06-04 15:23:41', 1, '2022-06-04 15:28:24', 0, 1, 0, 'Month', NULL, 1);

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

--
-- Table structure for table `imports`
--

CREATE TABLE `imports` (
  `id` int(11) NOT NULL,
  `sup_id` int(11) NOT NULL,
  `reference` varchar(100) NOT NULL,
  `paid` float NOT NULL,
  `note` text NOT NULL,
  `time_date` date DEFAULT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL,
  `updated_at` timestamp NULL DEFAULT NULL ON UPDATE current_timestamp(),
  `updated_by` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `file_id` int(11) DEFAULT NULL,
  `tax` float NOT NULL DEFAULT 0,
  `others` float NOT NULL DEFAULT 0,
  `branch_id` int(11) NOT NULL DEFAULT 1,
  `total_cost` float NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `imp_data`
--

CREATE TABLE `imp_data` (
  `id` int(11) NOT NULL,
  `imp_id` int(11) NOT NULL,
  `updated_by` int(11) NOT NULL,
  `updated_on` varchar(50) NOT NULL,
  `name` varchar(250) NOT NULL,
  `quantity` float NOT NULL DEFAULT 0,
  `cost` float NOT NULL DEFAULT 0,
  `tax` float NOT NULL DEFAULT 0,
  `item_id` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `items`
--

CREATE TABLE `items` (
  `id` int(11) NOT NULL,
  `name` varchar(100) NOT NULL,
  `qty` float NOT NULL,
  `category_id` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `items`
--

INSERT INTO `items` (`id`, `name`, `qty`, `category_id`, `deleted_01`, `created_at`, `created_by`) VALUES
(1, 'test', 0, 0, 0, '2022-05-26 14:23:09', 1);

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

--
-- Table structure for table `item_category`
--

CREATE TABLE `item_category` (
  `id` int(11) NOT NULL,
  `name` varchar(50) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `item_category`
--

INSERT INTO `item_category` (`id`, `name`, `deleted_01`) VALUES
(1, '==', 0);

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

--
-- Table structure for table `item_quantity`
--

CREATE TABLE `item_quantity` (
  `id` int(11) NOT NULL,
  `item_id` int(11) NOT NULL,
  `quantity` int(11) NOT NULL,
  `branch_id` int(11) NOT NULL,
  `name` varchar(100) NOT NULL,
  `cost` float NOT NULL,
  `purchase_id` int(11) NOT NULL,
  `tax` float NOT NULL DEFAULT 0,
  `tax_percent` int(11) NOT NULL DEFAULT 0,
  `remain` float NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `options`
--

CREATE TABLE `options` (
  `id` int(11) NOT NULL,
  `option_name` varchar(255) NOT NULL,
  `option_value` text NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `options`
--

INSERT INTO `options` (`id`, `option_name`, `option_value`) VALUES
(1, 'app_version', '2023.8.14.5'),
(2, 'cms_title', '5'),
(3, 'cms_subtitle', '5'),
(4, 'cms_description', '5'),
(5, 'cms_openhours', '45'),
(6, 'cms_about', '3'),
(7, 'cms_contacts', '2'),
(8, 'cms_color1', '#c5b6a6'),
(9, 'cms_color2', '#a1907d'),
(10, 'cms_bg1', '206'),
(11, 'cms_color3', '#323232');

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

--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` int(11) NOT NULL,
  `price` float NOT NULL,
  `tax` float NOT NULL,
  `discount` float NOT NULL,
  `branch_id` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL,
  `code` varchar(150) NOT NULL,
  `promo_code` int(11) NOT NULL,
  `json` text NOT NULL,
  `customer` varchar(20) NOT NULL,
  `customer_phone` varchar(10) NOT NULL,
  `customer_address` text NOT NULL,
  `car_number` varchar(10) NOT NULL,
  `note` text NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `updated_at` timestamp NULL DEFAULT NULL ON UPDATE current_timestamp(),
  `updated_by` int(11) DEFAULT NULL,
  `type` varchar(50) NOT NULL,
  `customer_name` varchar(70) NOT NULL,
  `status` varchar(50) NOT NULL DEFAULT 'Completed',
  `page` varchar(50) NOT NULL DEFAULT 'pos',
  `customer_id` int(11) NOT NULL,
  `totaldiscount` float NOT NULL,
  `delivery_id` int(11) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `order_data`
--

CREATE TABLE `order_data` (
  `id` int(11) NOT NULL,
  `order_id` int(11) NOT NULL,
  `price` float NOT NULL,
  `tax` float NOT NULL,
  `quantity` float NOT NULL,
  `size` varchar(20) NOT NULL,
  `name` varchar(50) NOT NULL,
  `json` text NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `branch_id` int(11) NOT NULL,
  `dish_id` int(11) NOT NULL,
  `note` text NOT NULL,
  `tax_percent` float NOT NULL,
  `discount` float NOT NULL,
  `name_ar` varchar(50) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `payments`
--

CREATE TABLE `payments` (
  `id` int(11) NOT NULL,
  `order_id` int(11) NOT NULL,
  `amount` float NOT NULL,
  `branch_id` int(11) NOT NULL,
  `created_by` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `updated_at` timestamp NULL DEFAULT NULL ON UPDATE current_timestamp(),
  `deleted_01` int(11) NOT NULL,
  `updated_by` int(11) DEFAULT NULL,
  `method` varchar(50) NOT NULL DEFAULT 'Cash',
  `points` float NOT NULL,
  `points_rate` float NOT NULL,
  `form_id` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `pole`
--

CREATE TABLE `pole` (
  `id` int(11) NOT NULL,
  `name` varchar(20) NOT NULL,
  `branch_id` int(11) NOT NULL,
  `host` text NOT NULL,
  `mode` varchar(20) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `printers`
--

CREATE TABLE `printers` (
  `id` int(11) NOT NULL,
  `name` varchar(50) NOT NULL,
  `counter` int(1) NOT NULL DEFAULT 0,
  `mode` varchar(50) NOT NULL DEFAULT 'web',
  `host` text NOT NULL,
  `branch_id` int(11) NOT NULL,
  `category_id` int(11) NOT NULL,
  `os` varchar(50) NOT NULL DEFAULT 'windows'
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `printers`
--

INSERT INTO `printers` (`id`, `name`, `counter`, `mode`, `host`, `branch_id`, `category_id`, `os`) VALUES
(2, 'POS-80-Series', 1, 'web', 'ws://localhost:40213', 1, 0, 'windows');

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

--
-- Table structure for table `roles`
--

CREATE TABLE `roles` (
  `id` int(11) NOT NULL,
  `name` varchar(250) NOT NULL,
  `description` text NOT NULL,
  `roles` text NOT NULL,
  `created_by` int(11) NOT NULL,
  `updated_by` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `roles`
--

INSERT INTO `roles` (`id`, `name`, `description`, `roles`, `created_by`, `updated_by`, `created_at`) VALUES
(1, 'Admin', 'Admin', '[\"manage-dishes\",\"view-dishes\",\"view-orders\",\"manage-orders\",\"manage-discount\",\"view-payments\",\"manage-users\",\"view-customers\",\"manage-customers\",\"view-purchases\",\"manage-purchases\",\"create-stock-requests\",\"manage-stock-requests\",\"add-expenses\",\"manage-expenses\",\"manage-suppliers\",\"view-reports\",\"discount\",\"branches\",\"settings\"]', 1, 1, '2020-12-24 14:55:15'),
(3, 'Cashier', 'Cashier', '[]', 1, 1, '2020-12-24 18:09:37');

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

--
-- Table structure for table `sms_q`
--

CREATE TABLE `sms_q` (
  `id` int(11) NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `phone` varchar(50) NOT NULL,
  `sms` text NOT NULL,
  `status` varchar(50) NOT NULL DEFAULT 'Queue',
  `send_date` varchar(50) NOT NULL,
  `response` varchar(200) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `sms_settings`
--

CREATE TABLE `sms_settings` (
  `id` int(11) NOT NULL,
  `repair_sms` text NOT NULL,
  `send_repair_sms` int(1) NOT NULL DEFAULT 0,
  `request_sms` text NOT NULL,
  `send_request_sms` int(1) NOT NULL DEFAULT 0,
  `order_sms` text NOT NULL,
  `send_order_sms` int(1) NOT NULL DEFAULT 0,
  `send_customer_debt` int(1) NOT NULL DEFAULT 1,
  `debt_sms` text NOT NULL,
  `reminder` int(1) NOT NULL DEFAULT 0,
  `reminder_sms` text NOT NULL,
  `reminder_categories` text NOT NULL,
  `monthly_debt_sms` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `stock_categories`
--

CREATE TABLE `stock_categories` (
  `id` int(11) NOT NULL,
  `name` varchar(250) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `added_by` int(11) NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `stock_imports`
--

CREATE TABLE `stock_imports` (
  `id` int(11) NOT NULL,
  `reference` varchar(50) NOT NULL,
  `created_by` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `sup_id` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `file` text NOT NULL,
  `time_date` date NOT NULL,
  `cost` float NOT NULL,
  `tax` float NOT NULL,
  `updated_at` timestamp NULL DEFAULT NULL ON UPDATE current_timestamp(),
  `updated_by` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `stock_imports_data`
--

CREATE TABLE `stock_imports_data` (
  `id` int(11) NOT NULL,
  `import_id` int(11) NOT NULL,
  `product_id` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL,
  `branch_id` int(11) NOT NULL,
  `qty` float NOT NULL,
  `cost` float NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `name` text NOT NULL,
  `tax` float NOT NULL,
  `tax_percent` float NOT NULL,
  `updated_at` timestamp NULL DEFAULT NULL ON UPDATE current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `stock_order_requests`
--

CREATE TABLE `stock_order_requests` (
  `id` int(11) NOT NULL,
  `branch_id` int(11) NOT NULL,
  `status` varchar(20) NOT NULL DEFAULT 'pending',
  `notes` text DEFAULT NULL,
  `purchase_id` int(11) DEFAULT NULL,
  `created_by` int(11) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `updated_by` int(11) DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL ON UPDATE current_timestamp(),
  `deleted_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

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

--
-- Table structure for table `stock_order_requests_data`
--

CREATE TABLE `stock_order_requests_data` (
  `id` int(11) NOT NULL,
  `request_id` int(11) NOT NULL,
  `product_id` int(11) NOT NULL,
  `qty` float NOT NULL DEFAULT 0,
  `notes` text DEFAULT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `deleted_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

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

--
-- Table structure for table `stock_poroducts`
--

CREATE TABLE `stock_poroducts` (
  `id` int(11) NOT NULL,
  `name` varchar(250) NOT NULL,
  `cat_id` int(11) NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `added_by` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `note` text NOT NULL,
  `qty` float UNSIGNED NOT NULL DEFAULT 0,
  `alert` float NOT NULL DEFAULT 0,
  `cost` float NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `stock_product_logs`
--

CREATE TABLE `stock_product_logs` (
  `id` int(11) NOT NULL,
  `p_id` int(11) NOT NULL,
  `branch_id` int(11) NOT NULL,
  `qty_change` varchar(50) NOT NULL,
  `added_by` int(11) NOT NULL,
  `type` varchar(100) NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `stock_product_quantity`
--

CREATE TABLE `stock_product_quantity` (
  `id` int(11) NOT NULL,
  `p_id` int(11) NOT NULL,
  `branch_id` int(11) NOT NULL,
  `quantity` float UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `stock_suppliers`
--

CREATE TABLE `stock_suppliers` (
  `id` int(11) NOT NULL,
  `name` varchar(250) NOT NULL,
  `phone` varchar(50) NOT NULL,
  `note` text NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `added_by` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `suppliers`
--

CREATE TABLE `suppliers` (
  `id` int(11) NOT NULL,
  `name` varchar(250) NOT NULL,
  `phone` varchar(250) NOT NULL,
  `address` varchar(250) NOT NULL,
  `description` varchar(500) NOT NULL,
  `start_amount` float NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `tax_no` varchar(250) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `suppliers`
--

INSERT INTO `suppliers` (`id`, `name`, `phone`, `address`, `description`, `start_amount`, `deleted_01`, `tax_no`) VALUES
(1, 'default ', '', '', '', 0, 0, '');

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

--
-- Table structure for table `sup_payment`
--

CREATE TABLE `sup_payment` (
  `id` int(11) NOT NULL,
  `sup_id` int(11) NOT NULL,
  `amount` float NOT NULL,
  `p_day` varchar(50) NOT NULL,
  `note` text NOT NULL,
  `p_for` varchar(300) NOT NULL,
  `pay_by` varchar(50) NOT NULL,
  `due_date` varchar(50) NOT NULL,
  `cheque_no` varchar(50) NOT NULL,
  `import_id` varchar(50) NOT NULL,
  `added_on` varchar(50) NOT NULL,
  `received_01` int(1) NOT NULL DEFAULT 0,
  `added_by` int(11) NOT NULL,
  `updated_on` varchar(50) NOT NULL,
  `updated_by` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `sup_payment`
--

INSERT INTO `sup_payment` (`id`, `sup_id`, `amount`, `p_day`, `note`, `p_for`, `pay_by`, `due_date`, `cheque_no`, `import_id`, `added_on`, `received_01`, `added_by`, `updated_on`, `updated_by`, `deleted_01`) VALUES
(1, 1, 10, '26-01-2022', '', '', 'cash', '', '', '', '20:14 26-01-2022', 1, 1, '', 0, 0),
(2, 1, 1, '22-03-2022', '', '', 'cash', '', '', '7', '12:18 22-03-2022', 1, 1, '', 0, 0);

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

--
-- Table structure for table `tables`
--

CREATE TABLE `tables` (
  `id` int(11) NOT NULL,
  `name` varchar(250) NOT NULL,
  `branch_id` int(11) NOT NULL,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `added_by` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `tables`
--

INSERT INTO `tables` (`id`, `name`, `branch_id`, `added_on`, `added_by`) VALUES
(1, 'Table 1', 1, '2020-03-04 05:39:46', 1),
(2, 'Table 2', 1, '2020-03-29 05:23:32', 1),
(3, 'Table 1', 1, '2020-03-29 05:24:37', 1),
(4, 'table', 2, '2020-11-10 08:38:50', 1),
(6, '2', 2, '2021-06-25 22:29:35', 1),
(7, '3', 2, '2021-06-25 22:29:38', 1),
(8, '4', 2, '2021-06-25 22:29:40', 1);

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

--
-- Table structure for table `taxes`
--

CREATE TABLE `taxes` (
  `id` int(11) NOT NULL,
  `name` varchar(250) NOT NULL,
  `percent` float NOT NULL,
  `amount` float NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `created_by` int(11) NOT NULL,
  `default_01` int(1) NOT NULL DEFAULT 0,
  `inv_val` float NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Dumping data for table `taxes`
--

INSERT INTO `taxes` (`id`, `name`, `percent`, `amount`, `created_at`, `created_by`, `default_01`, `inv_val`) VALUES
(1, 'لايوجد', 0, 0, '2020-12-29 15:18:38', 1, 1, 1),
(2, 'القيمة المضافة', 5, 0, '2021-01-07 22:34:46', 1, 0, 0.952381);

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

--
-- Table structure for table `uploads`
--

CREATE TABLE `uploads` (
  `id` int(11) NOT NULL,
  `file_name` text NOT NULL,
  `file` text NOT NULL,
  `temp_of` int(11) NOT NULL,
  `deleted_01` int(1) NOT NULL DEFAULT 0,
  `added_on` timestamp NOT NULL DEFAULT current_timestamp(),
  `public` int(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `users_signs`
--

CREATE TABLE `users_signs` (
  `id` int(11) NOT NULL,
  `user_id` int(11) NOT NULL,
  `sign_time` varchar(250) NOT NULL,
  `ip` varchar(250) NOT NULL,
  `lang` varchar(4) NOT NULL DEFAULT 'en'
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

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

--
-- Table structure for table `user_activities`
--

CREATE TABLE `user_activities` (
  `id` int(11) NOT NULL,
  `user_id` int(11) NOT NULL,
  `url` varchar(250) NOT NULL,
  `description` varchar(250) NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

--
-- Dumping data for table `user_activities`
--

INSERT INTO `user_activities` (`id`, `user_id`, `url`, `description`, `created_at`) VALUES
(36806, 1, 'http://127.0.0.1/resv81/dashboard.php', '', '2025-11-29 05:56:55'),
(36807, 1, 'http://127.0.0.1/resv81/orders/', '', '2025-11-29 05:56:58'),
(36808, 1, 'http://127.0.0.1/resv81/orders/', '', '2025-11-29 06:33:44'),
(36809, 1, 'http://127.0.0.1/resv81/dashboard.php', '', '2025-11-29 06:34:22'),
(36810, 1, 'http://127.0.0.1/resv81/roles/', '', '2025-11-29 06:34:57'),
(36811, 1, 'http://127.0.0.1/resv81/roles/?v=edit&i=1', '', '2025-11-29 06:35:00'),
(36812, 1, 'http://127.0.0.1/resv81/roles/?v=edit&i=1', '', '2025-11-29 06:35:40'),
(36813, 1, 'http://127.0.0.1/resv81/roles/?v=edit&i=1', '', '2025-11-29 06:38:07'),
(36814, 1, 'http://127.0.0.1/resv81/roles/?v=edit&i=1', '', '2025-11-29 06:38:54'),
(36815, 1, 'http://127.0.0.1/resv81/roles/?v=edit&i=1', '', '2025-11-29 06:38:57'),
(36816, 1, 'http://127.0.0.1/resv81/inventory/requests/', '', '2025-11-29 06:39:00'),
(36817, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=new', '', '2025-11-29 06:39:03'),
(36818, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=new', '', '2025-11-29 06:39:21'),
(36819, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=view&i=1', '', '2025-11-29 06:39:22'),
(36820, 1, 'http://127.0.0.1/resv81/inventory/requests/', '', '2025-11-29 06:39:28'),
(36821, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=view&i=1', '', '2025-11-29 06:39:32'),
(36822, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=view&i=1', '', '2025-11-29 06:42:10'),
(36823, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=edit&i=1', '', '2025-11-29 06:42:13'),
(36824, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=edit&i=1', '', '2025-11-29 06:42:17'),
(36825, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=view&i=1', '', '2025-11-29 06:42:18'),
(36826, 1, 'http://127.0.0.1/resv81/inventory/purchases/?v=new&from_request=1', '', '2025-11-29 06:42:20'),
(36827, 1, 'http://127.0.0.1/resv81/inventory/purchases/?v=new&from_request=1', '', '2025-11-29 06:42:30'),
(36828, 1, 'http://127.0.0.1/resv81/inventory/purchases/?from_request=1&v=edit&i=3', '', '2025-11-29 06:42:30'),
(36829, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:45:50'),
(36830, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:47:24'),
(36831, 1, 'http://127.0.0.1/resv81/reports/dishes.php', '', '2025-11-29 06:47:33'),
(36832, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:47:36'),
(36833, 1, 'http://127.0.0.1/resv81/inventory/requests/', '', '2025-11-29 06:47:47'),
(36834, 1, 'http://127.0.0.1/resv81/inventory/requests/', '', '2025-11-29 06:47:53'),
(36835, 1, 'http://127.0.0.1/resv81/inventory/requests/?v=view&i=1', '', '2025-11-29 06:48:01'),
(36836, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:48:50'),
(36837, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:51:06'),
(36838, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:51:34'),
(36839, 1, 'http://127.0.0.1/resv81/dashboard.php', '', '2025-11-29 06:52:14'),
(36840, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:52:17'),
(36841, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:55:20'),
(36842, 1, 'http://127.0.0.1/resv81/reports/', '', '2025-11-29 06:58:40'),
(36843, 1, 'http://127.0.0.1/resv81/inventory/report.php', '', '2025-11-29 06:58:49'),
(36844, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 06:59:31'),
(36845, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 06:59:33'),
(36846, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 06:59:35'),
(36847, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=all', '', '2025-11-29 06:59:39'),
(36848, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 06:59:45'),
(36849, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 06:59:48'),
(36850, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 07:00:05'),
(36851, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 07:01:03'),
(36852, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 07:01:06'),
(36853, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 07:01:08'),
(36854, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=all', '', '2025-11-29 07:01:10'),
(36855, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 07:01:12'),
(36856, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 07:03:01'),
(36857, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 07:03:05'),
(36858, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=2', '', '2025-11-29 07:03:07'),
(36859, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 07:03:14'),
(36860, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 07:04:47'),
(36861, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 07:04:56'),
(36862, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 07:05:08'),
(36863, 1, 'http://127.0.0.1/resv81/inventory/report.php?branch=1', '', '2025-11-29 07:05:13'),
(36864, 1, 'http://127.0.0.1/resv81/dashboard.php', '', '2025-11-29 12:29:55'),
(36865, 1, 'http://127.0.0.1/resv81/inventory/requests/', '', '2025-11-29 12:30:04'),
(36866, 1, 'http://127.0.0.1/resv81/inventory/purchases/?v=edit&i=3', '', '2025-11-29 12:30:07'),
(36867, 1, 'http://127.0.0.1/resv81/inventory/requests/', '', '2025-11-29 12:30:09'),
(36868, 1, 'http://127.0.0.1/resv81/inventory/purchases/', '', '2025-11-29 12:30:19'),
(36869, 1, 'http://127.0.0.1/resv81/inventory/suppliers.php', '', '2025-11-29 12:30:22'),
(36870, 1, 'http://127.0.0.1/resv81/inventory/purchases/', '', '2025-11-29 12:30:26'),
(36871, 1, 'http://127.0.0.1/resv81/inventory/purchases/', '', '2025-11-30 06:33:46');

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

--
-- Table structure for table `website_orders`
--

CREATE TABLE `website_orders` (
  `id` int(11) NOT NULL,
  `status` varchar(50) NOT NULL DEFAULT 'new',
  `cart` text NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `customer_id` int(11) NOT NULL,
  `branch_id` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;

--
-- Indexes for dumped tables
--

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

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

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

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

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

--
-- Indexes for table `cake_update`
--
ALTER TABLE `cake_update`
  ADD PRIMARY KEY (`update_id`);

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

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

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

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

--
-- Indexes for table `delivery`
--
ALTER TABLE `delivery`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `name` (`name`);

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

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

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

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

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

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

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

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

--
-- Indexes for table `options`
--
ALTER TABLE `options`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `option_name` (`option_name`);

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

--
-- AUTO_INCREMENT for dumped tables
--

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

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

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

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

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

--
-- AUTO_INCREMENT for table `cake_update`
--
ALTER TABLE `cake_update`
  MODIFY `update_id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

