-- phpMyAdmin SQL Dump
-- version 5.2.1
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: May 18, 2023 at 12:43 PM
-- Server version: 5.7.42
-- PHP Version: 8.1.16

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: `doctoretcm_download`
--

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

--
-- Table structure for table `oc_service_partner_sale_order`
--

CREATE TABLE `oc_service_partner_sale_order` (
  `sale_order_id` int(11) NOT NULL,
  `etcm_purchase_order_id` int(11) NOT NULL,
  `store_id` int(11) NOT NULL,
  `doc_no` varchar(100) NOT NULL,
  `doc_date` varchar(100) NOT NULL,
  `etcm_customer_id` int(11) NOT NULL,
  `customer_id` int(11) NOT NULL,
  `customer_name` varchar(100) NOT NULL,
  `customer_telephone` varchar(100) NOT NULL,
  `customer_email` varchar(100) NOT NULL,
  `medical_record_id` int(11) NOT NULL,
  `service_partner_id` int(11) NOT NULL,
  `service_partner_name` varchar(100) NOT NULL,
  `service_type` varchar(100) NOT NULL,
  `transaction_fee` decimal(10,4) NOT NULL COMMENT 'value in percentage',
  `shipping_type` varchar(100) NOT NULL,
  `estimated_date` varchar(100) NOT NULL,
  `tracking_no` varchar(255) NOT NULL,
  `proof_of_delivery` varchar(255) NOT NULL,
  `shipping_address_id` int(11) NOT NULL,
  `shipping_address` varchar(255) NOT NULL,
  `shipping_address_json` varchar(3000) NOT NULL,
  `shipping_method` varchar(100) NOT NULL,
  `payment_address` varchar(255) NOT NULL,
  `payment_address_json` varchar(3000) NOT NULL,
  `payment_method` varchar(100) NOT NULL,
  `add_order` varchar(100) NOT NULL,
  `carrier_id` varchar(100) NOT NULL,
  `image_json` text NOT NULL,
  `service_partner_prescription_json` text,
  `service_partner_total_json` text,
  `service_partner_total` decimal(15,4) NOT NULL,
  `service_partner_total_text` varchar(100) NOT NULL,
  `service_charges` decimal(15,4) NOT NULL,
  `service_tax` decimal(15,4) NOT NULL,
  `tax_class_id` int(11) NOT NULL,
  `discount` decimal(15,4) NOT NULL,
  `total` decimal(15,4) NOT NULL,
  `status_id` int(11) NOT NULL,
  `etcm_status_code` varchar(100) NOT NULL,
  `remark` text NOT NULL,
  `date_ordered` varchar(100) DEFAULT NULL,
  `date_payment` varchar(100) DEFAULT NULL,
  `date_prepared` varchar(100) DEFAULT NULL,
  `date_shipped` varchar(100) DEFAULT NULL,
  `date_rated` varchar(100) DEFAULT NULL,
  `rate_details` text NOT NULL,
  `date_completed` varchar(100) DEFAULT NULL,
  `date_cancelled` varchar(100) DEFAULT NULL,
  `cancelled` tinyint(1) NOT NULL,
  `cancel_reason` text NOT NULL,
  `date_added` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `added_by` int(11) NOT NULL,
  `date_modified` datetime NOT NULL,
  `modified_by` int(11) NOT NULL,
  `hide` tinyint(1) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

--
-- Indexes for dumped tables
--

--
-- Indexes for table `oc_service_partner_sale_order`
--
ALTER TABLE `oc_service_partner_sale_order`
  ADD PRIMARY KEY (`sale_order_id`);

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `oc_service_partner_sale_order`
--
ALTER TABLE `oc_service_partner_sale_order`
  MODIFY `sale_order_id` int(11) NOT NULL AUTO_INCREMENT;
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 */;
