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

START TRANSACTION;



--
-- Database: `developer_tbi`
--

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

--
-- Table structure for table `configurations`
--

CREATE TABLE `configurations` (
  `id` int(11) NOT NULL,
  `store_id` int(11) NOT NULL,
  `meta_key` varchar(255) DEFAULT NULL,
  `meta_value` text,
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  `updated_at` datetime DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `configurations`
--

INSERT INTO `configurations` (`id`, `store_id`, `meta_key`, `meta_value`, `created_at`, `updated_at`) VALUES
(3, 14, 'square-checkout-tanya.myshopify.com_square_detail', 'a:8:{s:13:\"enable_square\";N;s:7:\"sandbox\";s:1:\"1\";s:22:\"sandbox_application_id\";s:37:\"sandbox-sq0idb-982xcqCmXORUk5-5yRgZVw\";s:20:\"sandbox_access_token\";s:64:\"EAAAEFniXzm8AL0e0lPd-PUdxGBq3kcoRUfrbLy-NjU9bRp1sNEPBtH5veGoaDZN\";s:19:\"sandbox_location_id\";s:13:\"855PFV5PQ6YD5\";s:19:\"live_application_id\";s:0:\"\";s:17:\"live_access_token\";s:0:\"\";s:16:\"live_location_id\";s:0:\"\";}', '2020-11-03 23:14:18', '2020-11-03 23:17:30'),
(4, 15, 'ivannavape.myshopify.com_square_detail', 'a:8:{s:13:\"enable_square\";N;s:7:\"sandbox\";s:1:\"1\";s:22:\"sandbox_application_id\";s:37:\"sandbox-sq0idb-982xcqCmXORUk5-5yRgZVw\";s:20:\"sandbox_access_token\";s:64:\"EAAAEFniXzm8AL0e0lPd-PUdxGBq3kcoRUfrbLy-NjU9bRp1sNEPBtH5veGoaDZN\";s:19:\"sandbox_location_id\";s:13:\"855PFV5PQ6YD5\";s:19:\"live_application_id\";s:0:\"\";s:17:\"live_access_token\";s:0:\"\";s:16:\"live_location_id\";s:0:\"\";}', '2020-11-04 01:31:30', '2020-11-04 01:31:30');

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

--
-- Table structure for table `migration`
--

CREATE TABLE `migration` (
  `version` varchar(180) NOT NULL,
  `apply_time` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `migration`
--

INSERT INTO `migration` (`version`, `apply_time`) VALUES
('m000000_000000_base', 1598362394),
('m130524_201442_init', 1598362396),
('m190124_110200_add_verification_token_column_to_user_table', 1598362396);

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

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

CREATE TABLE `orders` (
  `id` int(11) NOT NULL,
  `store_id` int(11) NOT NULL,
  `order_id` varchar(255) DEFAULT NULL,
  `order_name` varchar(255) DEFAULT NULL,
  `customer_name` varchar(255) DEFAULT NULL,
  `email` varchar(255) DEFAULT NULL,
  `pin` varchar(255) DEFAULT NULL,
  `country` varchar(255) DEFAULT NULL,
  `status` varchar(255) DEFAULT NULL,
  `sequare_payment_id` varchar(255) NOT NULL,
  `square_customer_id` varchar(255) DEFAULT NULL,
  `amount` int(11) NOT NULL,
  `currency` varchar(5) NOT NULL,
  `card_status` varchar(128) NOT NULL,
  `card_brand` varchar(128) NOT NULL,
  `last_4` int(11) NOT NULL,
  `expiry` varchar(32) NOT NULL,
  `location_id` varchar(128) NOT NULL,
  `square_order_id` varchar(128) NOT NULL,
  `payment_mode` varchar(128) NOT NULL,
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  `updated_at` datetime DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `orders`
--

INSERT INTO `orders` (`id`, `store_id`, `order_id`, `order_name`, `customer_name`, `email`, `pin`, `country`, `status`, `sequare_payment_id`, `square_customer_id`, `amount`, `currency`, `card_status`, `card_brand`, `last_4`, `expiry`, `location_id`, `square_order_id`, `payment_mode`, `created_at`, `updated_at`) VALUES
(1, 4, '3028319928488', '#1001', 'brst1 dev', 'brstdev12@gmail.com', '90001', 'US', 'COMPLETED', 'DPzm8kioEPZ9UuOiXPMxODbbETYZY', 'NWS6QNX5PRTAH19T5XBCEG1S2W', 2307, 'USD', 'CAPTURED', 'VISA', 1111, '2 2023', '855PFV5PQ6YD5', 'mQMIFo3oLs7ZcQ4zAkKTmB3dEf4F', 'Card', '2020-11-03 04:49:24', '2020-11-03 04:49:24'),
(2, 4, '3028364591272', '#1002', 'brst52 dev', 'brstdev12@gmail.com', '90001', 'US', 'COMPLETED', 'lEHBhoxlepS3SOBRSvb6JnGqx4dZY', 'NWS6QNX5PRTAH19T5XBCEG1S2W', 1807, 'USD', 'CAPTURED', 'VISA', 1111, '2 2023', '855PFV5PQ6YD5', '2ISRMlUqRGLmDVQZQWDVKDuW3h4F', 'Card', '2020-11-03 04:56:48', '2020-11-03 04:56:48'),
(3, 14, '3034733281448', '#1003', 'brst52 dev', 'brstdev12@gmail.com', '90001', 'US', 'COMPLETED', 'ZKjeaYRGzCsgNQCeRXISlkVmnJVZY', 'NWS6QNX5PRTAH19T5XBCEG1S2W', 2307, 'USD', 'CAPTURED', 'VISA', 1111, '2 2022', '855PFV5PQ6YD5', 'CC0fHCOoN9sVkLFdx83q58kqHi4F', 'Card', '2020-11-03 23:15:05', '2020-11-03 23:15:05'),
(4, 14, '3034743210152', '#1004', 'brst52 dev', 'brstdev12@gmail.com', '90001', 'US', 'COMPLETED', '5YI3D10gepiQMuiZDExJFK49XHAZY', 'NWS6QNX5PRTAH19T5XBCEG1S2W', 1807, 'USD', 'CAPTURED', 'VISA', 1111, '2 2022', '855PFV5PQ6YD5', '2CpkFkEOzK58dSGWwSJkuwkKsc4F', 'Card', '2020-11-03 23:17:10', '2020-11-03 23:17:10');

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

--
-- Table structure for table `refunds`
--

CREATE TABLE `refunds` (
  `id` int(11) NOT NULL,
  `store_id` int(11) NOT NULL,
  `order_id` varchar(255) DEFAULT NULL,
  `refund_id` varchar(255) DEFAULT NULL,
  `refund_status` varchar(255) DEFAULT NULL,
  `transaction_id` varchar(255) DEFAULT NULL,
  `square_refund_id` varchar(255) DEFAULT NULL,
  `status` varchar(255) NOT NULL,
  `amount` varchar(255) NOT NULL,
  `reason` text NOT NULL,
  `currency` varchar(32) DEFAULT NULL,
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  `updated_at` datetime DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

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

--
-- Table structure for table `store`
--

CREATE TABLE `store` (
  `id` int(11) NOT NULL,
  `token` varchar(255) DEFAULT NULL,
  `name` varchar(255) DEFAULT NULL,
  `code` varchar(255) DEFAULT NULL,
  `status` int(11) DEFAULT NULL,
  `created_at` datetime DEFAULT CURRENT_TIMESTAMP,
  `updated_at` datetime DEFAULT CURRENT_TIMESTAMP
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Dumping data for table `store`
--

INSERT INTO `store` (`id`, `token`, `name`, `code`, `status`, `created_at`, `updated_at`) VALUES
(14, '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', 'square-checkout-tanya.myshopify.com', '954c27b8ae604c795d9fe36c794bec25', 1, '2020-11-03 23:12:28', '2020-11-03 23:12:28'),
(15, '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', 'ivannavape.myshopify.com', 'c6bea1e8cc68f84358611e09c88c2c19', 1, '2020-11-04 00:18:01', '2020-11-04 00:18:01');

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

--
-- Table structure for table `user`
--

CREATE TABLE `user` (
  `id` int(11) NOT NULL,
  `username` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
  `auth_key` varchar(32) COLLATE utf8_unicode_ci NOT NULL,
  `password_hash` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
  `password_reset_token` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
  `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
  `status` smallint(6) NOT NULL DEFAULT '10',
  `created_at` int(11) NOT NULL,
  `updated_at` int(11) NOT NULL,
  `verification_token` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

--
-- Indexes for dumped tables
--

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

--
-- Indexes for table `migration`
--
ALTER TABLE `migration`
  ADD PRIMARY KEY (`version`);

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

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

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

--
-- Indexes for table `user`
--
ALTER TABLE `user`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `username` (`username`),
  ADD UNIQUE KEY `email` (`email`),
  ADD UNIQUE KEY `password_reset_token` (`password_reset_token`);

--
-- AUTO_INCREMENT for dumped tables
--

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

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

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

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

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

