/*!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 utf8 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: backup
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `backup` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` text NOT NULL,
  `file_url` text NOT NULL,
  `status` text NOT NULL,
  `created_at` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB AUTO_INCREMENT = 51 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: brand_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `brand_settings` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `company_name` varchar(255) DEFAULT NULL,
  `address_line_1` varchar(255) DEFAULT NULL,
  `country` varchar(100) DEFAULT NULL,
  `state_province` varchar(100) DEFAULT NULL,
  `city` varchar(100) DEFAULT NULL,
  `postal_zip_code` varchar(20) DEFAULT NULL,
  `phone` varchar(20) DEFAULT NULL,
  `support_email` varchar(100) DEFAULT NULL,
  `website` varchar(255) DEFAULT NULL,
  `tax_vat_registration_number` varchar(100) DEFAULT NULL,
  `global_tax` text NOT NULL,
  `default_language` varchar(50) DEFAULT NULL,
  `company_logo` text DEFAULT NULL,
  `company_logo_color` text NOT NULL,
  `created_at` timestamp NULL DEFAULT current_timestamp(),
  `updated_at` timestamp NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `date_format` text DEFAULT NULL,
  `date_separator` varchar(5) DEFAULT '/',
  `time_zone` text DEFAULT NULL,
  `currency_format` text DEFAULT NULL,
  `decimal_precision` text DEFAULT NULL,
  `thousand_separator` text DEFAULT NULL,
  `primary_color` text DEFAULT NULL,
  `currencies` text NOT NULL,
  `max_discount_percentage` text NOT NULL,
  `max_discount_amount` text NOT NULL,
  `payment_banks` longtext NOT NULL,
  `seo_title` text DEFAULT NULL,
  `seo_description` longtext NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB AUTO_INCREMENT = 3 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: customer
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `customer` (
  `customer_id` int(11) NOT NULL AUTO_INCREMENT,
  `customer_type` text DEFAULT NULL,
  `lead_source` text DEFAULT NULL,
  `salutation` text DEFAULT NULL,
  `name` text DEFAULT NULL,
  `email` text DEFAULT NULL,
  `phone` text DEFAULT NULL,
  `whatsapp` text DEFAULT NULL,
  `default_currency` text DEFAULT NULL,
  `website` text DEFAULT NULL,
  `gst_vat_number` text DEFAULT NULL,
  `address_line_1` text DEFAULT NULL,
  `address_line_2` text DEFAULT NULL,
  `country` text DEFAULT NULL,
  `state_province` text DEFAULT NULL,
  `city` text DEFAULT NULL,
  `zip_postal_code` text DEFAULT NULL,
  `shipping_address_line_1` varchar(255) DEFAULT NULL,
  `shipping_country` varchar(100) DEFAULT NULL,
  `shipping_state_province` varchar(100) DEFAULT NULL,
  `shipping_city` varchar(100) DEFAULT NULL,
  `shipping_zip_postal_code` varchar(20) DEFAULT NULL,
  `status` text DEFAULT NULL,
  `type` text NOT NULL,
  `industry` text DEFAULT NULL,
  `contact_persons` text NOT NULL,
  `customer_docs` longtext NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  PRIMARY KEY (`customer_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 441 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: customer_ledger
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `customer_ledger` (
  `id` int(11) NOT NULL,
  `entry_date` text DEFAULT NULL,
  `entry_type` text DEFAULT NULL,
  `reference_no` text DEFAULT NULL,
  `invoice_id` text NOT NULL,
  `payment_id` text NOT NULL,
  `description` text DEFAULT NULL,
  `debit` text DEFAULT NULL,
  `credit` text DEFAULT NULL,
  `balance` text DEFAULT NULL,
  `created_at` timestamp NULL DEFAULT current_timestamp(),
  `updated_at` timestamp NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  PRIMARY KEY (`id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: customerpayment
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `customerpayment` (
  `payment_id` int(11) NOT NULL AUTO_INCREMENT,
  `customer_id` text NOT NULL,
  `customer_name` text DEFAULT NULL,
  `customer_info` longtext DEFAULT NULL,
  `invoice_id` longtext DEFAULT NULL,
  `current_invoice_number` text DEFAULT NULL,
  `payment_number` text DEFAULT NULL,
  `payment_date` text DEFAULT NULL,
  `payment_amount` text DEFAULT NULL,
  `balance_amount` text NOT NULL,
  `wallet_amount` text NOT NULL,
  `payment_type` text DEFAULT NULL,
  `transaction_type` text NOT NULL,
  `payment_bank` text DEFAULT NULL,
  `cheque_number` text DEFAULT NULL,
  `cheque_date` text DEFAULT NULL,
  `reference_no` text NOT NULL,
  `payee_bank` text NOT NULL,
  `pdc_date` text NOT NULL,
  `pdc_number` text NOT NULL,
  `pdc_status` text NOT NULL,
  `add_attachment` text NOT NULL,
  `doc` text DEFAULT NULL,
  `notes` text DEFAULT NULL,
  `status` text NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  `status_history` text NOT NULL,
  `bank_transaction_id` text NOT NULL,
  `created_time` text DEFAULT NULL,
  `updated_time` text DEFAULT NULL,
  `created_username` text DEFAULT NULL,
  `updated_username` text DEFAULT NULL,
  PRIMARY KEY (`payment_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 357 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: customerwallet
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `customerwallet` (
  `wallet_id` int(11) NOT NULL AUTO_INCREMENT,
  `customer_id` text DEFAULT NULL,
  `transactions` longtext DEFAULT NULL,
  `available_balance` text DEFAULT NULL,
  `created_at` datetime NOT NULL DEFAULT current_timestamp(),
  `updated_at` datetime DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  PRIMARY KEY (`wallet_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 3 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: deliverynote
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `deliverynote` (
  `deliverynote_id` int(11) NOT NULL AUTO_INCREMENT,
  `quote_id` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `proforma_id` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `deliverynote_date` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `customer_name` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `customer_info` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `customer_id` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `deliverynote_number` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `currency` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `deliverynote_content` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `general_terms_conditions` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `notes` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `status` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `line_items` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `line_items_short` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL,
  `doc` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `lpo` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_time` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `updated_time` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `created_username` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `updated_username` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `locked` longtext NOT NULL,
  `serializationSerial` longtext NOT NULL,
  PRIMARY KEY (`deliverynote_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 93 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: deliverynote_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `deliverynote_settings` (
  `id` int(11) NOT NULL,
  `prefix` text NOT NULL,
  `padding` text NOT NULL,
  `startFrom` text NOT NULL,
  `terms_conditions` text NOT NULL
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: email_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `email_settings` (
  `id` int(11) NOT NULL,
  `method` varchar(50) DEFAULT NULL,
  `host` varchar(255) DEFAULT NULL,
  `port` varchar(10) DEFAULT NULL,
  `encryption` varchar(50) DEFAULT NULL,
  `username` varchar(255) DEFAULT NULL,
  `password` varchar(255) DEFAULT NULL,
  `fromName` varchar(255) DEFAULT NULL,
  `fromEmail` varchar(255) DEFAULT NULL,
  `signature` text DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: expense
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `expense` (
  `expense_id` int(11) NOT NULL AUTO_INCREMENT,
  `expense_number` text DEFAULT NULL,
  `type_of_expense` text NOT NULL,
  `expense_date` text NOT NULL,
  `amount` text NOT NULL,
  `description` text DEFAULT NULL,
  `created_at` text NOT NULL,
  `updated_at` text NOT NULL,
  PRIMARY KEY (`expense_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 52 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: expense_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `expense_settings` (
  `expense_id` int(11) NOT NULL AUTO_INCREMENT,
  `prefix` varchar(10) DEFAULT NULL,
  `padding` int(11) DEFAULT NULL,
  `startFrom` int(11) DEFAULT NULL,
  `type_of_expenses` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL,
  `sub_type_of_expenses` longtext NOT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `updated_at` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  PRIMARY KEY (`expense_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 6 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: inventory
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `inventory` (
  `inventory_id` int(11) NOT NULL AUTO_INCREMENT,
  `inventory_type` text NOT NULL,
  `inventory_name` text NOT NULL,
  `description` text NOT NULL,
  `unit` text NOT NULL,
  `price` text NOT NULL,
  `buying_price` text NOT NULL,
  `created_at` text NOT NULL,
  `updated_at` text NOT NULL,
  `unit_id` text DEFAULT NULL,
  `stock` text NOT NULL,
  `sku` text DEFAULT NULL,
  `supplier_prices` longtext NOT NULL,
  `serialization` text NOT NULL,
  `status` longtext NOT NULL,
  PRIMARY KEY (`inventory_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 1114 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: invoice
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `invoice` (
  `invoice_id` int(11) NOT NULL AUTO_INCREMENT,
  `customer_id` text DEFAULT NULL,
  `customer_name` text DEFAULT NULL,
  `customer_info` longtext DEFAULT NULL,
  `invoice_number` text DEFAULT NULL,
  `invoice_date` text DEFAULT NULL,
  `expiry_date` text DEFAULT NULL,
  `quote_ref_number` text DEFAULT NULL,
  `proforma_ref_number` varchar(255) DEFAULT NULL,
  `delivery_note_ref_number` text DEFAULT NULL,
  `lpo_number` text DEFAULT NULL,
  `currency` text DEFAULT NULL,
  `terms` text DEFAULT NULL,
  `notes` text DEFAULT NULL,
  `line_items` text DEFAULT NULL,
  `updated_line_items` longtext DEFAULT NULL,
  `subtotal` text DEFAULT NULL,
  `total_invoice_value` decimal(10, 2) DEFAULT NULL,
  `balance_amount` text NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  `doc` text DEFAULT NULL,
  `invoice_docs` longtext NOT NULL,
  `status` text DEFAULT NULL,
  `status_history` text NOT NULL,
  `profit` text NOT NULL,
  `created_time` text DEFAULT NULL,
  `updated_time` text DEFAULT NULL,
  `created_username` text DEFAULT NULL,
  `updated_username` text DEFAULT NULL,
  `locked` longtext NOT NULL,
  PRIMARY KEY (`invoice_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 428 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: invoice_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `invoice_settings` (
  `id` int(10) unsigned NOT NULL,
  `prefix` varchar(50) DEFAULT NULL,
  `padding` int(11) DEFAULT NULL,
  `startFrom` int(11) DEFAULT NULL,
  `expiryDays` int(11) DEFAULT NULL,
  `emailSubject` varchar(255) DEFAULT NULL,
  `emailBody` text DEFAULT NULL,
  `cc` varchar(255) DEFAULT NULL,
  `terms_conditions` text NOT NULL,
  `whatsappActive` text NOT NULL,
  `whatsappAttachments` text NOT NULL,
  `whatsappMessage` longtext NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: lead
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `lead` (
  `lead_id` int(11) NOT NULL AUTO_INCREMENT,
  `lead_type` text DEFAULT NULL,
  `customer_type` text NOT NULL,
  `lead_source` text DEFAULT NULL,
  `name` text DEFAULT NULL,
  `email` text DEFAULT NULL,
  `phone` text DEFAULT NULL,
  `whatsapp` text DEFAULT NULL,
  `website` text DEFAULT NULL,
  `contact_persons` text DEFAULT NULL,
  `converted_to_customer` text DEFAULT NULL,
  `status` longtext NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  PRIMARY KEY (`lead_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 124 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: password_resets
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `password_resets` (
  `id` int(11) NOT NULL,
  `user_id` int(11) NOT NULL,
  `token` varchar(255) NOT NULL,
  `expires_at` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `used` tinyint(1) DEFAULT 0,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp()
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: payment_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `payment_settings` (
  `id` int(11) NOT NULL,
  `prefix` varchar(50) DEFAULT NULL,
  `padding` varchar(10) DEFAULT NULL,
  `startFrom` varchar(20) DEFAULT NULL,
  `expiryDays` int(11) DEFAULT NULL,
  `emailSubject` text DEFAULT NULL,
  `emailBody` text DEFAULT NULL,
  `cc` varchar(255) DEFAULT NULL,
  `whatsappActive` text NOT NULL,
  `whatsappAttachments` text NOT NULL,
  `whatsappMessage` longtext NOT NULL,
  `paymentPrefix` text NOT NULL,
  `paymentPadding` text NOT NULL,
  `paymentStartFrom` text NOT NULL,
  `advancePaymentEmailSubject` text DEFAULT NULL,
  `advancePaymentEmailBody` longtext DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: proforma
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `proforma` (
  `proforma_id` int(11) NOT NULL AUTO_INCREMENT,
  `customer_name` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `customer_info` longtext DEFAULT NULL,
  `customer_id` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `proforma_number` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `proforma_date` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `expiry_date` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `cheque_date` text DEFAULT NULL,
  `quote_ref_number` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `lpo_number` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `currency` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `proforma_terms` text DEFAULT NULL,
  `notes` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `line_items` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL,
  `subtotal` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `discount_global` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `advance_payment_received` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `progress_amount_payable` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `total_proforma_value` decimal(10, 2) DEFAULT NULL,
  `balance_amount` text NOT NULL,
  `refund_amount` text NOT NULL,
  `created_at` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `updated_at` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `doc` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `advance_payment_doc` longtext NOT NULL,
  `status` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `status_history` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `profit` text NOT NULL,
  `created_time` text NOT NULL,
  `updated_time` text DEFAULT NULL,
  `created_username` text NOT NULL,
  `updated_username` text NOT NULL,
  `billing_notes_status` text NOT NULL,
  `locked` text NOT NULL,
  PRIMARY KEY (`proforma_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 206 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: proforma_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `proforma_settings` (
  `id` int(11) NOT NULL,
  `prefix` varchar(50) DEFAULT NULL,
  `padding` varchar(10) DEFAULT NULL,
  `startFrom` varchar(20) DEFAULT NULL,
  `expiryDays` int(11) DEFAULT NULL,
  `proforma_terms_conditions` text DEFAULT NULL,
  `emailSubject` text DEFAULT NULL,
  `emailBody` text DEFAULT NULL,
  `cc` varchar(255) DEFAULT NULL,
  `autoAttachPdf` tinyint(1) DEFAULT NULL,
  `whatsappActive` text NOT NULL,
  `whatsappAttachments` text DEFAULT NULL,
  `whatsappMessage` longtext NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: purchase
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `purchase` (
  `purchase_id` int(11) NOT NULL AUTO_INCREMENT,
  `supplier_name` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `supplier_id` text DEFAULT NULL,
  `purchaseorder_ref_number` longtext NOT NULL,
  `purchase_number` text DEFAULT NULL,
  `invoice_number` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `purchase_date` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `payment_terms` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `line_items` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL,
  `total_value` text NOT NULL,
  `balance_amount` text NOT NULL,
  `currency` text NOT NULL,
  `tax` text NOT NULL,
  `lpo` text NOT NULL,
  `doc` longtext NOT NULL,
  `status` text NOT NULL,
  `returns` longtext NOT NULL,
  `locked` longtext NOT NULL,
  `created_username` text NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  PRIMARY KEY (`purchase_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 244 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: purchase_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `purchase_settings` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `prefix` longtext DEFAULT NULL,
  `padding` longtext DEFAULT NULL,
  `startFrom` longtext DEFAULT NULL,
  `terms_conditions` longtext DEFAULT NULL,
  `prefixSupplier` text NOT NULL,
  `paddingSupplier` text NOT NULL,
  `startFromSupplier` text NOT NULL,
  `emailSubject` longtext DEFAULT NULL,
  `emailBody` longtext DEFAULT NULL,
  `cc` longtext DEFAULT NULL,
  `po_prefix` longtext DEFAULT NULL,
  `po_padding` longtext DEFAULT NULL,
  `po_startFrom` longtext DEFAULT NULL,
  `po_emailSubject` longtext DEFAULT NULL,
  `po_emailBody` longtext DEFAULT NULL,
  `po_emailcc` longtext DEFAULT NULL,
  `po_terms_conditions` longtext DEFAULT NULL,
  `created_at` timestamp NULL DEFAULT current_timestamp(),
  `updated_at` timestamp NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  PRIMARY KEY (`id`)
) ENGINE = InnoDB AUTO_INCREMENT = 2 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: purchaseorder
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `purchaseorder` (
  `purchaseorder_id` int(11) NOT NULL AUTO_INCREMENT,
  `supplier_name` longtext NOT NULL,
  `supplier_id` text NOT NULL,
  `purchaseorder_number` text NOT NULL,
  `purchaseorder_date` text NOT NULL,
  `quote_reference` longtext NOT NULL,
  `ship_via` longtext NOT NULL,
  `fob` longtext NOT NULL,
  `po_terms_conditions` longtext NOT NULL,
  `po_payment_terms` longtext NOT NULL,
  `line_items` longtext NOT NULL,
  `order_stock` text NOT NULL,
  `total_value` text NOT NULL,
  `balance_amount` text NOT NULL,
  `currency` text NOT NULL,
  `tax` text NOT NULL,
  `doc` longtext NOT NULL,
  `status` text NOT NULL,
  `returns` longtext NOT NULL,
  `locked` longtext NOT NULL,
  `closed` text NOT NULL,
  `created_username` text NOT NULL,
  `created_at` text NOT NULL,
  `updated_at` text NOT NULL,
  PRIMARY KEY (`purchaseorder_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 44 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: purchasereturn
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `purchasereturn` (
  `purchasereturn_id` int(11) NOT NULL AUTO_INCREMENT,
  `purchasereturn_date` longtext DEFAULT NULL,
  `purchase_info` longtext DEFAULT NULL,
  `payment_info` longtext DEFAULT NULL,
  `purchase_order` longtext DEFAULT NULL,
  `purchasereturn_number` longtext DEFAULT NULL,
  `line_items` longtext DEFAULT NULL,
  `updated_line_items` longtext DEFAULT NULL,
  `created_at` longtext DEFAULT NULL,
  `updated_at` longtext DEFAULT NULL,
  `status` longtext DEFAULT NULL,
  `supplier_name` longtext DEFAULT NULL,
  `amount` longtext DEFAULT NULL,
  `return_amount` longtext DEFAULT NULL,
  `qty` longtext DEFAULT NULL,
  `return_qty` longtext DEFAULT NULL,
  `serialnumbers` longtext NOT NULL,
  PRIMARY KEY (`purchasereturn_id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: purchasereturn_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `purchasereturn_settings` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `prefix` longtext NOT NULL,
  `padding` longtext NOT NULL,
  `startFrom` longtext NOT NULL,
  `emailSubject` longtext NOT NULL,
  `emailBody` longtext NOT NULL,
  `terms_conditions` longtext NOT NULL,
  `cc` longtext NOT NULL,
  `created_at` longtext NOT NULL,
  `updated_at` longtext NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: quote
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `quote` (
  `quote_id` int(11) NOT NULL AUTO_INCREMENT,
  `customer_name` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `customer_info` longtext DEFAULT NULL,
  `customer_id` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `quote_number` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `quote_date` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `expiry_date` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `currency` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `quote_content` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `general_terms_conditions` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `notes` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `status` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `signature` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `subtotal` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `discount` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `discount_global` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `total_quote_value` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `line_items` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL,
  `doc` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `attachments` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  `status_history` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `winning_probability` longtext DEFAULT NULL,
  `billing_notes_status` text NOT NULL,
  `billing_notes_short` text NOT NULL,
  `profit` text NOT NULL,
  `created_time` text DEFAULT NULL,
  `updated_time` text DEFAULT NULL,
  `created_username` text DEFAULT NULL,
  `updated_username` text DEFAULT NULL,
  `lpo_number` text NOT NULL,
  `lpo_document` longtext NOT NULL,
  `locked` text NOT NULL,
  PRIMARY KEY (`quote_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 813 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: quote_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `quote_settings` (
  `id` int(11) NOT NULL,
  `prefix` varchar(50) DEFAULT NULL,
  `padding` varchar(10) DEFAULT NULL,
  `startFrom` varchar(20) DEFAULT NULL,
  `terms_conditions` text NOT NULL,
  `expiryDays` int(11) DEFAULT NULL,
  `emailSubject` text DEFAULT NULL,
  `emailBody` text DEFAULT NULL,
  `cc` varchar(255) DEFAULT NULL,
  `winning_probability` longtext NOT NULL,
  `whatsappActive` text NOT NULL,
  `whatsappAttachments` text NOT NULL,
  `whatsappMessage` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: recurringinvoice
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `recurringinvoice` (
  `recurringinvoice_id` bigint(20) NOT NULL AUTO_INCREMENT,
  `customer_id` longtext DEFAULT NULL,
  `invoice_number` longtext DEFAULT NULL,
  `recurring_repeat_every` longtext DEFAULT NULL,
  `recurring_interval_count` longtext DEFAULT NULL,
  `recurring_start_date` longtext DEFAULT NULL,
  `recurring_end_date` longtext DEFAULT NULL,
  `recurring_never_expire` longtext DEFAULT NULL,
  `next_due_date` longtext DEFAULT NULL,
  `status` longtext DEFAULT NULL,
  `recurringinvoice_created_at` longtext DEFAULT NULL,
  `recurringinvoice_updated_at` longtext DEFAULT NULL,
  PRIMARY KEY (`recurringinvoice_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 41 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: role
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `role` (
  `role_id` int(11) NOT NULL AUTO_INCREMENT,
  `role_name` text NOT NULL,
  `privileges` text DEFAULT NULL,
  `status` longtext DEFAULT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  PRIMARY KEY (`role_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 31 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: salesreturn
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `salesreturn` (
  `salesreturn_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  `salesreturn_date` text NOT NULL,
  `invoice_info` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `payment_info` longtext NOT NULL,
  `delivery_notes` longtext NOT NULL,
  `used_serial_numbers` longtext NOT NULL,
  `salesreturn_number` text NOT NULL,
  `line_items` longtext DEFAULT NULL,
  `updated_line_items` longtext DEFAULT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `updated_at` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  `status` longtext DEFAULT NULL,
  `customer_name` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `amount` longtext DEFAULT NULL,
  `return_amount` longtext DEFAULT NULL,
  `qty` longtext DEFAULT NULL,
  `return_qty` longtext DEFAULT NULL,
  `doc` longtext DEFAULT NULL,
  `terms_and_conditions` longtext DEFAULT NULL,
  `internal_notes` longtext DEFAULT NULL,
  PRIMARY KEY (`salesreturn_id`)
) ENGINE = MyISAM DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: salesreturn_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `salesreturn_settings` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `prefix` longtext DEFAULT NULL,
  `padding` longtext DEFAULT NULL,
  `startFrom` longtext DEFAULT NULL,
  `emailSubject` longtext DEFAULT NULL,
  `emailBody` longtext DEFAULT NULL,
  `terms_conditions` longtext DEFAULT NULL,
  `cc` longtext DEFAULT NULL,
  `created_at` timestamp NOT NULL DEFAULT current_timestamp(),
  `updated_at` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
  PRIMARY KEY (`id`)
) ENGINE = MyISAM DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: serial_numbers
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `serial_numbers` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `item_id` longtext NOT NULL,
  `document_type` longtext NOT NULL,
  `document_id` longtext NOT NULL,
  `serial_number` longtext NOT NULL,
  `created_at` longtext DEFAULT NULL,
  `updated_at` longtext DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE = MyISAM DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: supplier
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `supplier` (
  `supplier_id` int(11) NOT NULL AUTO_INCREMENT,
  `supplier_type` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `name` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `email` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `contact_number` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `address_line` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `website` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `currency` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `payment_terms` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `tax_number` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `credit_limit` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `contact_persons` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL,
  `supplier_docs` longtext NOT NULL,
  `status` longtext NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  PRIMARY KEY (`supplier_id`)
) ENGINE = MyISAM AUTO_INCREMENT = 85 DEFAULT CHARSET = latin1 COLLATE = latin1_swedish_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: supplier_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `supplier_settings` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `prefix` text NOT NULL,
  `padding` text NOT NULL,
  `startFrom` text NOT NULL,
  `prefixSupplierPayment` text DEFAULT NULL,
  `paddingSupplierPayment` text DEFAULT NULL,
  `startFromSupplierPayment` text DEFAULT NULL,
  `emailSubject` text NOT NULL,
  `emailBody` text NOT NULL,
  `cc` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB AUTO_INCREMENT = 2 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: supplier_wallet
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `supplier_wallet` (
  `wallet_id` int(11) NOT NULL AUTO_INCREMENT,
  `supplier_id` text NOT NULL,
  `transactions` longtext NOT NULL,
  `available_balance` text NOT NULL,
  `created_at` text NOT NULL,
  `updated_at` text NOT NULL,
  PRIMARY KEY (`wallet_id`)
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: supplierpayment
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `supplierpayment` (
  `supplierpayment_id` int(11) NOT NULL AUTO_INCREMENT,
  `supplierpayment_name` text DEFAULT NULL,
  `supplier_id` text NOT NULL,
  `purchase_id` text DEFAULT NULL,
  `current_purchase_number` text DEFAULT NULL,
  `supplierpayment_number` text DEFAULT NULL,
  `payment_date` text DEFAULT NULL,
  `payment_amount` text DEFAULT NULL,
  `balance_amount` text NOT NULL,
  `wallet_amount` longtext NOT NULL,
  `payment_type` text DEFAULT NULL,
  `payment_bank` text DEFAULT NULL,
  `cheque_number` text DEFAULT NULL,
  `cheque_date` text DEFAULT NULL,
  `pdc_date` text NOT NULL,
  `pdc_number` text NOT NULL,
  `pdc_status` text NOT NULL,
  `reference_no` text NOT NULL,
  `add_attachment` text NOT NULL,
  `doc` text DEFAULT NULL,
  `notes` text DEFAULT NULL,
  `status` text NOT NULL,
  `created_username` text NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  `status_history` text NOT NULL,
  PRIMARY KEY (`supplierpayment_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 294 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: supplierpayment_settings
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `supplierpayment_settings` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `prefix` text NOT NULL,
  `padding` text NOT NULL,
  `startFrom` text NOT NULL,
  `emailSubject` text NOT NULL,
  `emailBody` text NOT NULL,
  `cc` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB AUTO_INCREMENT = 2 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: transation_bank
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `transation_bank` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `payment_method` text NOT NULL,
  `transaction_info` longtext NOT NULL,
  `status` text NOT NULL,
  `created_at` text NOT NULL,
  `updated_at` text NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE = InnoDB AUTO_INCREMENT = 11 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: unit
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `unit` (
  `unit_id` int(11) NOT NULL AUTO_INCREMENT,
  `unit_name` text NOT NULL,
  `description` text DEFAULT NULL,
  `status` longtext NOT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  PRIMARY KEY (`unit_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 92 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci;

# ------------------------------------------------------------
# SCHEMA DUMP FOR TABLE: user
# ------------------------------------------------------------

CREATE TABLE IF NOT EXISTS `user` (
  `user_id` int(11) NOT NULL AUTO_INCREMENT,
  `full_name` text NOT NULL,
  `username` text NOT NULL,
  `password` varchar(255) NOT NULL,
  `status` varchar(50) NOT NULL DEFAULT 'Active',
  `email` varchar(100) NOT NULL,
  `designation` varchar(100) DEFAULT NULL,
  `mobile_number` varchar(20) DEFAULT NULL,
  `digital_signature` text DEFAULT NULL,
  `email_signature` text DEFAULT NULL,
  `last_login_ip` varchar(45) DEFAULT NULL,
  `last_login_at` text DEFAULT NULL,
  `created_at` text DEFAULT NULL,
  `updated_at` text DEFAULT NULL,
  `privileges` longtext DEFAULT NULL,
  `role_id` text DEFAULT NULL,
  PRIMARY KEY (`user_id`)
) ENGINE = InnoDB AUTO_INCREMENT = 102 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci;

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: backup
# ------------------------------------------------------------

INSERT INTO
  `backup` (`id`, `name`, `file_url`, `status`, `created_at`)
VALUES
  (
    46,
    'backup-1762236436270-1762236436644',
    '/backups/backup-1762236436270-1762236436644/database.sql',
    'Success',
    '2025-11-04T06:07:16.644Z'
  );
INSERT INTO
  `backup` (`id`, `name`, `file_url`, `status`, `created_at`)
VALUES
  (
    47,
    'backup-1763188788809-1763188788981',
    '/backups/backup-1763188788809-1763188788981/database.sql',
    'Restored',
    '2025-11-15T06:39:48.981Z'
  );
INSERT INTO
  `backup` (`id`, `name`, `file_url`, `status`, `created_at`)
VALUES
  (
    48,
    'backup-1767444410671-1767444411100',
    '/backups/backup-1767444410671-1767444411100/database.sql',
    'Success',
    '2026-01-03T12:46:51.101Z'
  );
INSERT INTO
  `backup` (`id`, `name`, `file_url`, `status`, `created_at`)
VALUES
  (
    49,
    'backup-1768990205596-1768990205772',
    '/backups/backup-1768990205596-1768990205772/database.sql',
    'Success',
    '2026-01-21T10:10:05.773Z'
  );
INSERT INTO
  `backup` (`id`, `name`, `file_url`, `status`, `created_at`)
VALUES
  (
    50,
    'backup-1768990217045-1768990218036',
    '/backups/backup-1768990217045-1768990218036/database.sql',
    'Backup DB',
    '2026-01-21T10:10:18.036Z'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: brand_settings
# ------------------------------------------------------------

INSERT INTO
  `brand_settings` (
    `id`,
    `company_name`,
    `address_line_1`,
    `country`,
    `state_province`,
    `city`,
    `postal_zip_code`,
    `phone`,
    `support_email`,
    `website`,
    `tax_vat_registration_number`,
    `global_tax`,
    `default_language`,
    `company_logo`,
    `company_logo_color`,
    `created_at`,
    `updated_at`,
    `date_format`,
    `date_separator`,
    `time_zone`,
    `currency_format`,
    `decimal_precision`,
    `thousand_separator`,
    `primary_color`,
    `currencies`,
    `max_discount_percentage`,
    `max_discount_amount`,
    `payment_banks`,
    `seo_title`,
    `seo_description`
  )
VALUES
  (
    1,
    'Test Company 1',
    'testing address\ndfg',
    'AE',
    'DU',
    'sdfsdf',
    '123456',
    '+9685345345435',
    'jaseer9746@gmail.com',
    'upturnist.com',
    '100200300400003',
    '5',
    'English',
    '',
    '',
    '2026-01-21 00:53:17',
    '2026-01-21 01:50:57',
    'YYYY MM DD',
    ' ',
    'Asia/Dubai',
    'before',
    '2 decimals',
    'comma',
    '#34be46',
    '[\"AED\"]',
    '10',
    '500',
    '[{\"bank_name\":\"\",\"account_number\":\"\"}]',
    '',
    'hfghfgh'
  );
INSERT INTO
  `brand_settings` (
    `id`,
    `company_name`,
    `address_line_1`,
    `country`,
    `state_province`,
    `city`,
    `postal_zip_code`,
    `phone`,
    `support_email`,
    `website`,
    `tax_vat_registration_number`,
    `global_tax`,
    `default_language`,
    `company_logo`,
    `company_logo_color`,
    `created_at`,
    `updated_at`,
    `date_format`,
    `date_separator`,
    `time_zone`,
    `currency_format`,
    `decimal_precision`,
    `thousand_separator`,
    `primary_color`,
    `currencies`,
    `max_discount_percentage`,
    `max_discount_amount`,
    `payment_banks`,
    `seo_title`,
    `seo_description`
  )
VALUES
  (
    2,
    'Test Company 1',
    'testing address\ndfg',
    'AE',
    'DU',
    'sdfsdf',
    '123456',
    '+9685345345435',
    'jaseer9746@gmail.com',
    'upturnist.com',
    '100200300400003',
    '5',
    'English',
    '',
    '',
    '2026-01-21 00:53:28',
    '2026-01-21 00:53:28',
    'YYYY MM DD',
    ' ',
    'Asia/Dubai',
    'before',
    '2 decimals',
    'comma',
    '#34be46',
    '[\"AED\"]',
    '10',
    '500',
    '[{\"bank_name\":\"\",\"account_number\":\"\"}]',
    '',
    ''
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: customer
# ------------------------------------------------------------

INSERT INTO
  `customer` (
    `customer_id`,
    `customer_type`,
    `lead_source`,
    `salutation`,
    `name`,
    `email`,
    `phone`,
    `whatsapp`,
    `default_currency`,
    `website`,
    `gst_vat_number`,
    `address_line_1`,
    `address_line_2`,
    `country`,
    `state_province`,
    `city`,
    `zip_postal_code`,
    `shipping_address_line_1`,
    `shipping_country`,
    `shipping_state_province`,
    `shipping_city`,
    `shipping_zip_postal_code`,
    `status`,
    `type`,
    `industry`,
    `contact_persons`,
    `customer_docs`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    440,
    'Company',
    'Referrals',
    '',
    'Testing Company',
    'jaseer9746@gmail.com',
    '+968345345435435',
    '+971',
    'AED',
    'upturnist.com',
    '43534545',
    'Test house\nTest street',
    '',
    'AE',
    'AZ',
    '',
    '4543543',
    'Test house\nTest street',
    'AE',
    'AZ',
    '',
    '4543543',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]',
    'Normal',
    'testing',
    '[{\"salutation\":\"Mr.\",\"full_name\":\"Test user\",\"designation\":\"Test user\",\"department\":\"Test user\",\"phone_1\":\"+9714545435\",\"phone_2\":\"+91453455345\",\"email\":\"jaseer9746@gmail.com\",\"notes\":\"geger\"}]',
    '[{\"docName\":\"test\",\"docExpiryDate\":\"2026-01-20T18:30:00.000Z\",\"uploadedPath\":\"/uploads/customer_docs/test_2026-01-21_3371_9e159855-203a-4f82-9738-52b4319a4c0b.png\",\"uploadedName\":\"test_2026-01-21_3371_9e159855-203a-4f82-9738-52b4319a4c0b.png\",\"size\":10647,\"type\":\"image/png\"}]',
    '2026-01-21T09:54:02.046Z',
    '2026-01-21T09:54:02.046Z'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: customer_ledger
# ------------------------------------------------------------

INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1423,
    '2025-11-08T12:34:00.000Z',
    'Payment',
    'PAY-01',
    '0',
    '74',
    'Payment from Wilson PLC',
    '0.00',
    '10000.00',
    '-10000.00',
    '2025-08-13 23:44:27',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1424,
    '2025-11-08T14:52:00.000Z',
    'Payment',
    'PAY-2',
    '0',
    '75',
    'Payment from Wilson PLC',
    '0.00',
    '13.00',
    '-10013.00',
    '2025-08-13 23:44:27',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1425,
    '2025-11-08T15:11:00.000Z',
    'Payment',
    'PAY-3',
    '0',
    '76',
    'Payment from Ronald Hayes',
    '0.00',
    '500.00',
    '-10513.00',
    '2025-08-13 23:44:27',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1426,
    '2025-08-12T00:00:00.000Z',
    'Invoice',
    'IV-1',
    '64',
    '0',
    'Invoice to Wilson PLC',
    '42.00',
    '0.00',
    '-10471.00',
    '2025-08-13 23:44:27',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1427,
    '2025-08-12T00:00:00.000Z',
    'Invoice',
    'IV-2',
    '65',
    '0',
    'Invoice to Wilson PLC',
    '42.00',
    '0.00',
    '-10429.00',
    '2025-08-13 23:44:27',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1428,
    '2025-08-13T00:00:00.000Z',
    'Invoice',
    'IV-3',
    '73',
    '0',
    'Invoice to Wilson PLC',
    '12.60',
    '0.00',
    '-10416.40',
    '2025-08-13 23:44:27',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1429,
    '2025-08-13T00:00:00.000Z',
    'Invoice',
    'IV-4',
    '74',
    '0',
    'Invoice to Wilson PLC',
    '176.40',
    '0.00',
    '-10240.00',
    '2025-08-13 23:44:27',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1430,
    '2025-08-13T00:00:00.000Z',
    'Invoice',
    'IV-5',
    '75',
    '0',
    'Invoice to Ronald Hayes',
    '12.00',
    '0.00',
    '-10228.00',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1431,
    '2025-08-13T00:00:00.000Z',
    'Invoice',
    'IV-6',
    '76',
    '0',
    'Invoice to Bailey PLC',
    '12.00',
    '0.00',
    '-10216.00',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1432,
    '2025-08-13T00:00:00.000Z',
    'Invoice',
    'IV-7',
    '77',
    '0',
    'Invoice to Chambers Inc',
    '1.25',
    '0.00',
    '-10214.75',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1433,
    '2025-08-13T00:00:00.000Z',
    'Invoice',
    'IV-8',
    '78',
    '0',
    'Invoice to Test user',
    '1.31',
    '0.00',
    '-10213.44',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1434,
    '2025-08-13T00:00:00.000Z',
    'Invoice',
    'IV-9',
    '79',
    '0',
    'Invoice to Ronald Hayes',
    '630.00',
    '0.00',
    '-9583.44',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1435,
    '2025-08-14T00:00:00.000Z',
    'Invoice',
    'IV-10',
    '80',
    '0',
    'Invoice to Wilson PLC',
    '84.00',
    '0.00',
    '-9499.44',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1436,
    '2025-08-14T00:00:00.000Z',
    'Invoice',
    'IV-11',
    '81',
    '0',
    'Invoice to Wilson PLC',
    '1.31',
    '0.00',
    '-9498.13',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );
INSERT INTO
  `customer_ledger` (
    `id`,
    `entry_date`,
    `entry_type`,
    `reference_no`,
    `invoice_id`,
    `payment_id`,
    `description`,
    `debit`,
    `credit`,
    `balance`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1437,
    '2025-08-14T00:00:00.000Z',
    'Invoice',
    'IV-12',
    '82',
    '0',
    'Invoice to Wilson PLC',
    '12.60',
    '0.00',
    '-9485.53',
    '2025-08-13 23:44:28',
    '2025-11-28 02:41:20'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: customerpayment
# ------------------------------------------------------------

INSERT INTO
  `customerpayment` (
    `payment_id`,
    `customer_id`,
    `customer_name`,
    `customer_info`,
    `invoice_id`,
    `current_invoice_number`,
    `payment_number`,
    `payment_date`,
    `payment_amount`,
    `balance_amount`,
    `wallet_amount`,
    `payment_type`,
    `transaction_type`,
    `payment_bank`,
    `cheque_number`,
    `cheque_date`,
    `reference_no`,
    `payee_bank`,
    `pdc_date`,
    `pdc_number`,
    `pdc_status`,
    `add_attachment`,
    `doc`,
    `notes`,
    `status`,
    `created_at`,
    `updated_at`,
    `status_history`,
    `bank_transaction_id`,
    `created_time`,
    `updated_time`,
    `created_username`,
    `updated_username`
  )
VALUES
  (
    355,
    '438',
    'Testing Company',
    '{\"customer_id\":438,\"name\":\"Testing Company\",\"customer_type\":\"Company\",\"lead_source\":\"Referrals\",\"email\":\"jaseer9746@gmail.com\",\"phone\":\"+91558854585\",\"whatsapp\":\"+9685654645654\",\"default_currency\":\"AED\",\"website\":\"www.test.com\",\"gst_vat_number\":\"54435435\",\"address_line_1\":\"testing address\\ndfg\",\"country\":\"AF\",\"state\":\"\",\"zip_postal_code\":\"564565\",\"industry\":\"IT\",\"contact_persons\":[{\"salutation\":\"Mr.\",\"full_name\":\"Test user\",\"designation\":\"Test user\",\"department\":\"Test user\",\"phone_1\":\"+971456546546\",\"phone_2\":\"+968456456456546\",\"email\":\"jaseer9746@gmail.com\",\"notes\":\"\"}],\"status\":\"[{\\\"id\\\":12,\\\"key\\\":\\\"active\\\",\\\"label\\\":\\\"Active\\\"}]\",\"type\":\"Normal\"}',
    '[{\"key\":427,\"invoice_id\":427,\"invoice_number\":\"INV-0100\",\"delivery_note_number\":\"DLV-0011\",\"invoiceAmount\":3605.7,\"invoiceDate\":\"2026-01-07T00:00:00.000Z\",\"initialBalanceAmount\":3605.7,\"balanceAmount\":0,\"payAmount\":3605.7,\"status\":\"Paid\"}]',
    '',
    'PAY-0100',
    '2026-01-07T00:00:00.000Z',
    'AED 3605.70',
    'AED 0.00',
    '\"AED 0.00\"',
    'Cash',
    'Payment',
    '',
    '',
    '2026-01-07T00:00:00.000Z',
    '',
    '',
    '',
    '',
    '',
    'true',
    'doc/customerpayment/customerpayment-pay-0100-testing_company-01-07-2026-12-00-00-AM.pdf',
    '',
    '[{\"id\":4,\"key\":\"cancelled\",\"label\":\"Cancelled\",\"reason\":\"gdfgdgdg\",\"cancelled_by\":\"\",\"date_time\":\"09:54:24 AM\",\"time_none\":\"\"}]',
    '2026-01-07T09:52:44.856Z',
    '2026-01-07T09:54:24.788Z',
    '[]',
    '9',
    '01:52:34 PM',
    NULL,
    'saleem',
    NULL
  );
INSERT INTO
  `customerpayment` (
    `payment_id`,
    `customer_id`,
    `customer_name`,
    `customer_info`,
    `invoice_id`,
    `current_invoice_number`,
    `payment_number`,
    `payment_date`,
    `payment_amount`,
    `balance_amount`,
    `wallet_amount`,
    `payment_type`,
    `transaction_type`,
    `payment_bank`,
    `cheque_number`,
    `cheque_date`,
    `reference_no`,
    `payee_bank`,
    `pdc_date`,
    `pdc_number`,
    `pdc_status`,
    `add_attachment`,
    `doc`,
    `notes`,
    `status`,
    `created_at`,
    `updated_at`,
    `status_history`,
    `bank_transaction_id`,
    `created_time`,
    `updated_time`,
    `created_username`,
    `updated_username`
  )
VALUES
  (
    356,
    '438',
    'Testing Company',
    '{\"customer_id\":438,\"name\":\"Testing Company\",\"customer_type\":\"Company\",\"lead_source\":\"Referrals\",\"email\":\"jaseer9746@gmail.com\",\"phone\":\"+91558854585\",\"whatsapp\":\"+9685654645654\",\"default_currency\":\"AED\",\"website\":\"www.test.com\",\"gst_vat_number\":\"54435435\",\"address_line_1\":\"testing address\\ndfg\",\"country\":\"AF\",\"state\":\"\",\"zip_postal_code\":\"564565\",\"industry\":\"IT\",\"contact_persons\":[{\"salutation\":\"Mr.\",\"full_name\":\"Test user\",\"designation\":\"Test user\",\"department\":\"Test user\",\"phone_1\":\"+971456546546\",\"phone_2\":\"+968456456456546\",\"email\":\"jaseer9746@gmail.com\",\"notes\":\"\"}],\"status\":\"[{\\\"id\\\":12,\\\"key\\\":\\\"active\\\",\\\"label\\\":\\\"Active\\\"}]\",\"type\":\"Normal\"}',
    '[{\"key\":427,\"invoice_id\":427,\"invoice_number\":\"INV-0100\",\"delivery_note_number\":\"DLV-0011\",\"invoiceAmount\":3605.7,\"invoiceDate\":\"2026-01-07T00:00:00.000Z\",\"initialBalanceAmount\":3605.7,\"balanceAmount\":0,\"payAmount\":3605.7,\"status\":\"Paid\"}]',
    '',
    NULL,
    '2026-01-07T09:54:24.411Z',
    'AED -3605.70',
    '3605.7',
    '\"AED 0.00\"',
    'Cash',
    'Reversal',
    NULL,
    NULL,
    NULL,
    'REVERSAL',
    '',
    '',
    '',
    '',
    '',
    '/doc/customerpayment/customerpayment_cancel_355.pdf',
    'gdfgdgdg',
    '[{\"id\":11,\"key\":\"reversed\",\"label\":\"Reversed\"}]',
    '2026-01-07T09:54:24.432Z',
    '2026-01-07T09:54:24.432Z',
    '[]',
    '9',
    NULL,
    NULL,
    NULL,
    NULL
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: customerwallet
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: deliverynote
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: deliverynote_settings
# ------------------------------------------------------------

INSERT INTO
  `deliverynote_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `terms_conditions`
  )
VALUES
  (
    3,
    'DLV',
    '4',
    '11',
    '<p class=\"MsoNormal\" style=\"margin: 0cm; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0);\"><span lang=\"EN-US\" style=\"font-size: 12pt; line-height: 18.4px;\">Kindly check all product/services are delivered as specified in the respective LPO/Quote<o:p></o:p></span></p><p class=\"MsoNormal\" style=\"margin: 0cm; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0);\"><span style=\"font-size: 12pt; line-height: 18.4px;\">If there is any dispute or mismatch on the delivery, please reach out to us at info@uptunist.com.</span></p>'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: email_settings
# ------------------------------------------------------------

INSERT INTO
  `email_settings` (
    `id`,
    `method`,
    `host`,
    `port`,
    `encryption`,
    `username`,
    `password`,
    `fromName`,
    `fromEmail`,
    `signature`
  )
VALUES
  (
    2,
    'SMTP',
    'smtp.maileroo.com',
    '465',
    'SSL',
    'mail@upturnist.com',
    '9ddee03d9cbfc4ba1ff05ea0',
    'Upturnist Technologies',
    'mail@upturnist.com',
    'gfgbvjkhihihjk jhbhojhijiojpo dfgdfgdfgdffghvghj'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: expense
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: expense_settings
# ------------------------------------------------------------

INSERT INTO
  `expense_settings` (
    `expense_id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `type_of_expenses`,
    `sub_type_of_expenses`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    5,
    'EXP',
    1,
    1,
    '[{\"value\":\"vehicle\",\"title\":\"vehicle\",\"children\":[{\"value\":\"petrol\",\"title\":\"petrol\",\"children\":[]},{\"value\":\"fssfgjk\",\"title\":\"fssfgjk\",\"children\":[]},{\"value\":\"hjh\",\"title\":\"hjh\",\"children\":[]},{\"value\":\"rdfgh\",\"title\":\"rdfgh\",\"children\":[]}]},{\"value\":\"cvxvchsvhgwdh\",\"title\":\"cvxvchsvhgwdh\",\"children\":[{\"value\":\"tdgfgfgh\",\"title\":\"tdgfgfgh\",\"children\":[]}]},{\"value\":\"main\",\"title\":\"main\",\"children\":[]}]',
    '',
    '2025-09-08 00:32:54',
    '2025-11-05 22:58:42'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: inventory
# ------------------------------------------------------------

INSERT INTO
  `inventory` (
    `inventory_id`,
    `inventory_type`,
    `inventory_name`,
    `description`,
    `unit`,
    `price`,
    `buying_price`,
    `created_at`,
    `updated_at`,
    `unit_id`,
    `stock`,
    `sku`,
    `supplier_prices`,
    `serialization`,
    `status`
  )
VALUES
  (
    1111,
    '[{\"id\":1,\"key\":\"stock-item\",\"label\":\"Stock Item\"}]',
    'Laptop',
    '',
    'Box',
    '[]',
    '[]',
    '2026-01-21T10:07:20.770Z',
    '2026-01-21T10:07:20.770Z',
    NULL,
    '0',
    'LP100',
    '[]',
    '1',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]'
  );
INSERT INTO
  `inventory` (
    `inventory_id`,
    `inventory_type`,
    `inventory_name`,
    `description`,
    `unit`,
    `price`,
    `buying_price`,
    `created_at`,
    `updated_at`,
    `unit_id`,
    `stock`,
    `sku`,
    `supplier_prices`,
    `serialization`,
    `status`
  )
VALUES
  (
    1112,
    '[{\"id\":1,\"key\":\"stock-item\",\"label\":\"Stock Item\"}]',
    'Desktop',
    '',
    'Box',
    '[]',
    '[]',
    '2026-01-21T10:07:47.605Z',
    '2026-01-21T10:07:47.605Z',
    NULL,
    '0',
    'DS100',
    '[]',
    '',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]'
  );
INSERT INTO
  `inventory` (
    `inventory_id`,
    `inventory_type`,
    `inventory_name`,
    `description`,
    `unit`,
    `price`,
    `buying_price`,
    `created_at`,
    `updated_at`,
    `unit_id`,
    `stock`,
    `sku`,
    `supplier_prices`,
    `serialization`,
    `status`
  )
VALUES
  (
    1113,
    '[{\"id\":1,\"key\":\"stock-item\",\"label\":\"Stock Item\"}]',
    'Mobile',
    'Test',
    'Box',
    '[{\"AED\":1500}]',
    '[{\"AED\":1000}]',
    '2026-01-21T10:08:13.640Z',
    '2026-01-21T10:08:13.640Z',
    NULL,
    '0',
    'MB50',
    '[]',
    '',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: invoice
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: invoice_settings
# ------------------------------------------------------------

INSERT INTO
  `invoice_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `expiryDays`,
    `emailSubject`,
    `emailBody`,
    `cc`,
    `terms_conditions`,
    `whatsappActive`,
    `whatsappAttachments`,
    `whatsappMessage`
  )
VALUES
  (
    1,
    'INV',
    4,
    100,
    5,
    'Your Invoice from {{company}}',
    '<div bis_skin_checked=\"1\">Dear {{customer_name}},</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Please find attached the proforma invoice for your upcoming order.</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Proforma Invoice Number:&nbsp;<span style=\"font-weight: bolder;\">{{invoice_number}}</span></div><div bis_skin_checked=\"1\">Date Issued:<span style=\"font-weight: bolder;\">&nbsp;</span><span style=\"font-weight: bolder;\">{{invoice_date}}</span></div><div bis_skin_checked=\"1\">Total Amount:&nbsp;<span style=\"font-weight: bolder;\">{{total_invoice_value}}</span></div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">This proforma invoice outlines the products/services and costs as discussed. It is not a final tax invoice but serves as a formal offer.</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">To proceed with the order, kindly confirm by replying to this email or making the payment as per the instructions in the document.</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">If you have any questions or need modifications, feel free to reply to this email. We look forward to working with you.&nbsp;</div>',
    '',
    '<p class=\"MsoNormal\" style=\"margin: 0cm; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0);\"><span style=\"font-size: 12pt; line-height: 18.4px;\">Kindly ensure that all payments are made via Bank Transfer to the designated Bank Account.<o:p></o:p></span></p><p class=\"MsoNormal\" style=\"margin: 0cm; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0);\"><span style=\"font-size: 12pt; line-height: 18.4px;\">Once payment has been made for Services Invoices, shall not be refunded.<o:p></o:p></span></p><p class=\"MsoNormal\" style=\"margin: 0cm; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0);\"><span style=\"font-size: 12pt; line-height: 18.4px;\">If there is any dispute on this invoice, please reach out to us at info@uptunist.com.<o:p></o:p></span></p><p class=\"MsoNormal\" style=\"margin: 0cm; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0);\"><span style=\"font-size: 12pt; line-height: 18.4px;\">All currencies mentioned in this invoice are in AED</span><span lang=\"EN-US\" style=\"font-size: 12pt; line-height: 18.4px;\"> Excluding VAT</span><span style=\"font-size: 12pt; line-height: 18.4px;\"> (Unit Arab Emirates Dirhams)<o:p></o:p></span></p>',
    'Active',
    'Active',
    'Here is your invoice'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: lead
# ------------------------------------------------------------

INSERT INTO
  `lead` (
    `lead_id`,
    `lead_type`,
    `customer_type`,
    `lead_source`,
    `name`,
    `email`,
    `phone`,
    `whatsapp`,
    `website`,
    `contact_persons`,
    `converted_to_customer`,
    `status`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    123,
    'Normal',
    'Company',
    'Referrals',
    'Testing Company',
    'jaseer9746@gmail.com',
    '+968345345435435',
    '+91',
    'upturnist.com',
    '[{\"salutation\":\"Mr.\",\"full_name\":\"Test user\",\"designation\":\"Test user\",\"department\":\"Test user\",\"phone_1\":\"+9714545435\",\"phone_2\":\"+91\",\"email\":\"jaseer9746@gmail.com\",\"notes\":\"\"}]',
    '1',
    '[{\"id\":16,\"key\":\"converted\",\"label\":\"Converted\"}]',
    '2026-01-21T09:51:43.380Z',
    '2026-01-21T09:54:02.347Z'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: password_resets
# ------------------------------------------------------------

INSERT INTO
  `password_resets` (
    `id`,
    `user_id`,
    `token`,
    `expires_at`,
    `used`,
    `created_at`
  )
VALUES
  (
    0,
    4,
    '2b35a0eb1ceab97481eb99be39da96060ac8fce2a598b1483ab9017fa47a1216',
    '2025-07-21 00:24:29',
    1,
    '2025-07-21 00:21:22'
  );
INSERT INTO
  `password_resets` (
    `id`,
    `user_id`,
    `token`,
    `expires_at`,
    `used`,
    `created_at`
  )
VALUES
  (
    0,
    3,
    '843fcd987e8418e5b49e900a50ac196d20a5c4d76cf7f53ca5b2294a1860c688',
    '2025-08-06 03:06:30',
    1,
    '2025-08-06 03:05:23'
  );
INSERT INTO
  `password_resets` (
    `id`,
    `user_id`,
    `token`,
    `expires_at`,
    `used`,
    `created_at`
  )
VALUES
  (
    0,
    14,
    '4d3da59b9f21363e0807e2e92ebdf90a5b4aa875ef2a8cb10b34259415fd6023',
    '2025-08-11 03:20:08',
    1,
    '2025-08-11 03:18:44'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: payment_settings
# ------------------------------------------------------------

INSERT INTO
  `payment_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `expiryDays`,
    `emailSubject`,
    `emailBody`,
    `cc`,
    `whatsappActive`,
    `whatsappAttachments`,
    `whatsappMessage`,
    `paymentPrefix`,
    `paymentPadding`,
    `paymentStartFrom`,
    `advancePaymentEmailSubject`,
    `advancePaymentEmailBody`
  )
VALUES
  (
    4,
    'PAY',
    '4',
    '100',
    3,
    'Your Payment Receipt from {{company}}',
    'Hello {{customer_name}},<div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Thank you for your payment. This email is to confirm that we have received your payment for the following invoice:&nbsp;</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Invoice Number:&nbsp;<b>{{current_invoice_number}}</b></div><div bis_skin_checked=\"1\">Date Paid: <b>{{payment_date}}</b></div><div bis_skin_checked=\"1\">Amount Received: <b>{{payment_amount}}</b></div><div bis_skin_checked=\"1\">Payment Method:&nbsp;<b>{{payment_type}}</b></div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">&nbsp;A PDF copy of your payment receipt is attached for your records.\n\nIf you have any questions or need further assistance, feel free to contact us.\n\nThank you for your business!&nbsp;</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">{{customer_id}}{{status}}</div>',
    '',
    'Active',
    'Active',
    'here is your payment reciept',
    'SUP-PAY',
    '4',
    '100',
    NULL,
    NULL
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: proforma
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: proforma_settings
# ------------------------------------------------------------

INSERT INTO
  `proforma_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `expiryDays`,
    `proforma_terms_conditions`,
    `emailSubject`,
    `emailBody`,
    `cc`,
    `autoAttachPdf`,
    `whatsappActive`,
    `whatsappAttachments`,
    `whatsappMessage`
  )
VALUES
  (
    1,
    'PI',
    '4',
    '100',
    5,
    '<p style=\"margin-bottom: 8px; border-style: initial !important;\"><br></p>',
    'Your Proforma Invoice from {{company}}',
    '<div bis_skin_checked=\"1\">Dear {{customer_name}},</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Please find attached the proforma invoice for your upcoming order.</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Proforma Invoice Number:&nbsp;<b>{{proforma_number}}</b></div><div bis_skin_checked=\"1\">Date Issued:<b>&nbsp;{{proforma_date}}</b></div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">This proforma invoice outlines the products/services and costs as discussed. It is not a final tax invoice but serves as a formal offer.</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">To proceed with the order, kindly confirm by replying to this email or making the payment as per the instructions in the document.</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">If you have any questions or need modifications, feel free to reply to this email. We look forward to working with you.&nbsp;</div><div bis_skin_checked=\"1\"></div>',
    '',
    1,
    'Active',
    'Active',
    'Kindly Find the proforma invoice'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: purchase
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: purchase_settings
# ------------------------------------------------------------

INSERT INTO
  `purchase_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `terms_conditions`,
    `prefixSupplier`,
    `paddingSupplier`,
    `startFromSupplier`,
    `emailSubject`,
    `emailBody`,
    `cc`,
    `po_prefix`,
    `po_padding`,
    `po_startFrom`,
    `po_emailSubject`,
    `po_emailBody`,
    `po_emailcc`,
    `po_terms_conditions`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    1,
    'PU',
    '1',
    '1',
    '<br>',
    'SUPPLIER PAYMENT',
    '1',
    '1',
    'Payment Receipt for Invoice {{number}}',
    'Hello {{customer_name}},\n\nThank you for your payment. This email is to confirm that we have received your payment for the following invoice:\n\nInvoice Number: {{number}}\nDate Paid: {{payment_date}}\nAmount Received: {{amount_paid}}\nPayment Method: {{payment_method}}\n\nA PDF copy of your payment receipt is attached for your records.\n\nIf you have any questions or need further assistance, feel free to contact us.\n\nThank you for your business!\n\nBest regards,\n{{company_name}}\n{{company_email}} | {{company_phone}}',
    'assad@asdas.com',
    'puorder',
    '1',
    '1',
    'fsf',
    'sdfdsfdsf',
    'dsf@asddd.com',
    'sdfdsf',
    '2025-09-08 05:39:18',
    '2025-11-24 20:09:08'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: purchaseorder
# ------------------------------------------------------------

INSERT INTO
  `purchaseorder` (
    `purchaseorder_id`,
    `supplier_name`,
    `supplier_id`,
    `purchaseorder_number`,
    `purchaseorder_date`,
    `quote_reference`,
    `ship_via`,
    `fob`,
    `po_terms_conditions`,
    `po_payment_terms`,
    `line_items`,
    `order_stock`,
    `total_value`,
    `balance_amount`,
    `currency`,
    `tax`,
    `doc`,
    `status`,
    `returns`,
    `locked`,
    `closed`,
    `created_username`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    43,
    'Testing Company',
    '84',
    'puorder-1',
    '2026-01-21T00:00:00.000Z',
    '',
    '',
    '',
    'sdfdsf',
    '',
    '[{\"key\":1768990157565,\"type\":[{\"id\":1,\"key\":\"stock-item\",\"label\":\"Stock Item\"}],\"item_id\":1113,\"item_name\":\"Mobile\",\"item_description\":\"Test\",\"qty\":10,\"price\":1000,\"buying_price\":1000,\"discountPercentage\":\"\",\"discountAmount\":\"\",\"sku\":\"MB50\",\"unit\":\"Box\",\"total\":\"10500.00\",\"serialization\":false},{\"key\":1768990163675,\"type\":[{\"id\":1,\"key\":\"stock-item\",\"label\":\"Stock Item\"}],\"item_id\":1112,\"item_name\":\"Desktop\",\"item_description\":\"\",\"qty\":10,\"price\":2000,\"buying_price\":0,\"discountPercentage\":\"\",\"discountAmount\":\"\",\"sku\":\"DS100\",\"unit\":\"Box\",\"total\":\"21000.00\",\"serialization\":false},{\"key\":1768990164317,\"type\":[{\"id\":1,\"key\":\"stock-item\",\"label\":\"Stock Item\"}],\"item_id\":1111,\"item_name\":\"Laptop\",\"item_description\":\"\",\"qty\":10,\"price\":3000,\"buying_price\":0,\"discountPercentage\":\"\",\"discountAmount\":\"\",\"sku\":\"LP100\",\"unit\":\"Box\",\"total\":\"31500.00\",\"serialization\":false}]',
    '[]',
    '63000',
    '63000',
    'AED',
    '\"yes\"',
    'doc/purchaseorder/purchaseorder-puorder-1--21-01-2026-03-39-34-PM.pdf',
    '[{\"id\":2,\"key\":\"approved\",\"label\":\"Approved\"}]',
    '[]',
    '',
    '',
    'saleem',
    '2026-01-21T10:09:45.163Z',
    '2026-01-21T10:09:49.275Z'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: purchasereturn
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: purchasereturn_settings
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: quote
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: quote_settings
# ------------------------------------------------------------

INSERT INTO
  `quote_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `terms_conditions`,
    `expiryDays`,
    `emailSubject`,
    `emailBody`,
    `cc`,
    `winning_probability`,
    `whatsappActive`,
    `whatsappAttachments`,
    `whatsappMessage`
  )
VALUES
  (
    1,
    'QT',
    '4',
    '100',
    '<div bis_skin_checked=\"1\"><p class=\"MsoNormal\" style=\"margin: 0cm; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0);\"><span style=\"font-family: Calibri, sans-serif; font-size: 11pt; text-indent: -108pt;\">Currency and TAX</span><span style=\"font-family: Calibri, sans-serif; font-size: 11pt; text-indent: -108pt;\">: All amounts mentioned in the proposal are in AED exclusive of VAT.</span></p><p class=\"MsoNormal\" style=\"margin: 0cm 0cm 0cm 108pt; line-height: 16.8667px; font-size: 11pt; font-family: Arial, sans-serif; color: rgb(0, 0, 0); text-indent: -108pt;\"><span lang=\"EN\" style=\"font-family: Calibri, sans-serif;\">Payment Terms: One-time payments: 70% Advance - 30% on completion. Recurring payments: Quarterly in Advance. &nbsp;&nbsp;<o:p></o:p></span></p></div>',
    14,
    'Here’s your quote from {{company_name}}',
    'Hi&nbsp;{{customer_name}}<div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Thank you for your interest in our services. Please find below your quote details:&nbsp;</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">Quote Number: <b>{{quote_number}}&nbsp;</b></div><div bis_skin_checked=\"1\">Quote Date: <b>{{quote_date}}&nbsp;</b></div><div bis_skin_checked=\"1\">Total Amount: <b>{{total_quote_value}}&nbsp;</b></div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">You can view and download your full quote here: {{quote_link}}&nbsp;</div><div bis_skin_checked=\"1\"><br></div><div bis_skin_checked=\"1\">If you have any questions or need modifications, feel free to reply to this email.\n\nWe look forward to working with you.&nbsp;<br><br></div><div bis_skin_checked=\"1\"><br></div>',
    '',
    '[\"10\",\"30\",\"50\",\"70\",\"90\",\"100\"]',
    '0',
    'Active',
    'As discussed, please find the quotation details attached ?.\nLet me know if you have any questions or need any changes ?.\n\nLooking forward to your confirmation ✅.\n\nBest regards,\nTest admin\nUpturnist'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: recurringinvoice
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: role
# ------------------------------------------------------------

INSERT INTO
  `role` (
    `role_id`,
    `role_name`,
    `privileges`,
    `status`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    29,
    'Owner',
    '{\"dashboard\":{\"view\":false,\"modify\":false},\"lead\":{\"view\":true,\"modify\":false},\"customer\":{\"view\":false,\"modify\":false},\"supplier\":{\"view\":false,\"modify\":false},\"purchase\":{\"view\":false,\"modify\":false},\"purchaseorder\":{\"view\":false,\"modify\":false},\"inventory\":{\"view\":false,\"modify\":false},\"unit\":{\"view\":false,\"modify\":false},\"quote\":{\"view\":false,\"modify\":false},\"quote-settings\":{\"view\":false,\"modify\":false},\"proforma\":{\"view\":false,\"modify\":false},\"proforma-settings\":{\"view\":false,\"modify\":false},\"deliverynote\":{\"view\":false,\"modify\":false},\"deliverynote-settings\":{\"view\":false,\"modify\":false},\"invoice\":{\"view\":false,\"modify\":false},\"invoice-settings\":{\"view\":false,\"modify\":false},\"customerpayment\":{\"view\":false,\"modify\":false},\"supplierpayment\":{\"view\":false,\"modify\":false},\"payment-settings\":{\"view\":false,\"modify\":false},\"purchase-return\":{\"view\":false,\"modify\":false},\"salesreturn\":{\"view\":false,\"modify\":false},\"salesreturn-settings\":{\"view\":false,\"modify\":false},\"reports\":{\"view\":false,\"modify\":false},\"user\":{\"view\":false,\"modify\":false},\"role\":{\"view\":false,\"modify\":false},\"settings\":{\"view\":false,\"modify\":false},\"general-settings\":{\"view\":false,\"modify\":false},\"email-settings\":{\"view\":false,\"modify\":false},\"backup & restore\":{\"view\":false,\"modify\":false}}',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]',
    '2025-10-29T05:30:43.053Z',
    '2026-01-07T13:08:55.585Z'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: salesreturn
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: salesreturn_settings
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: serial_numbers
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: supplier
# ------------------------------------------------------------

INSERT INTO
  `supplier` (
    `supplier_id`,
    `supplier_type`,
    `name`,
    `email`,
    `contact_number`,
    `address_line`,
    `website`,
    `currency`,
    `payment_terms`,
    `tax_number`,
    `credit_limit`,
    `contact_persons`,
    `supplier_docs`,
    `status`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    84,
    'Business',
    'Testing Company',
    'jaseer9746@gmail.com',
    '+968',
    'testing address',
    'upturnist.com',
    'AED',
    'fghgfh',
    '5646',
    '500000',
    '[{\"salutation\":\"Mr.\",\"full_name\":\"Test user\",\"designation\":\"Test user\",\"department\":\"Test user\",\"phone_1\":\"+9714545435\",\"phone_2\":\"+91\",\"email\":\"jaseer9746@gmail.com\",\"notes\":\"\"}]',
    '[{\"docName\":\"gfhfgh\",\"docExpiryDate\":\"2027-01-07T18:30:00.000Z\",\"uploadedPath\":\"/uploads/supplier_docs/gfhfgh_2026-01-21_9708_a3b3e330-56ca-439c-bde1-878d8e120743.png\",\"uploadedName\":\"gfhfgh_2026-01-21_9708_a3b3e330-56ca-439c-bde1-878d8e120743.png\",\"size\":10647,\"type\":\"image/png\"}]',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]',
    '2026-01-21T09:54:54.249Z',
    '2026-01-21T09:55:16.288Z'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: supplier_settings
# ------------------------------------------------------------

INSERT INTO
  `supplier_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `prefixSupplierPayment`,
    `paddingSupplierPayment`,
    `startFromSupplierPayment`,
    `emailSubject`,
    `emailBody`,
    `cc`
  )
VALUES
  (
    1,
    'SUP',
    '4',
    '1',
    'SUPYYYYYY',
    '1',
    '1',
    'Payment Receipt for Invoice {{number}}',
    'Hello {{customer_name}},\n\nThank you for your payment. This email is to confirm that we have received your payment for the following invoice:\n\nInvoice Number: {{number}}\nDate Paid: {{payment_date}}\nAmount Received: {{amount_paid}}\nPayment Method: {{payment_method}}\n\nA PDF copy of your payment receipt is attached for your records.\n\nIf you have any questions or need further assistance, feel free to contact us.\n\nThank you for your business!\n\nBest regards,\n{{company_name}}\n{{company_email}} | {{company_phone}}',
    'jaseerali2012@gmail.com'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: supplier_wallet
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: supplierpayment
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: supplierpayment_settings
# ------------------------------------------------------------

INSERT INTO
  `supplierpayment_settings` (
    `id`,
    `prefix`,
    `padding`,
    `startFrom`,
    `emailSubject`,
    `emailBody`,
    `cc`
  )
VALUES
  (
    1,
    'SUPLL',
    '1',
    '1',
    'Payment Receipt for Invoice {{number}}',
    'Hello {{customer_name}},\n\nThank you for your payment. This email is to confirm that we have received your payment for the following invoice:\n\nInvoice Number: {{number}}\nDate Paid: {{payment_date}}\nAmount Received: {{amount_paid}}\nPayment Method: {{payment_method}}\n\nA PDF copy of your payment receipt is attached for your records.\n\nIf you have any questions or need further assistance, feel free to contact us.\n\nThank you for your business!\n\nBest regards,\n{{company_name}}\n{{company_email}} | {{company_phone}}',
    'jaseerali2012@gmail.com'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: transation_bank
# ------------------------------------------------------------


# ------------------------------------------------------------
# DATA DUMP FOR TABLE: unit
# ------------------------------------------------------------

INSERT INTO
  `unit` (
    `unit_id`,
    `unit_name`,
    `description`,
    `status`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    90,
    'Piece',
    'Test description updated',
    '\"[{\\\"id\\\":12,\\\"key\\\":\\\"active\\\",\\\"label\\\":\\\"Active\\\"}]\"',
    '2026-01-21T09:55:57.730Z',
    '2026-01-21T09:56:10.333Z'
  );
INSERT INTO
  `unit` (
    `unit_id`,
    `unit_name`,
    `description`,
    `status`,
    `created_at`,
    `updated_at`
  )
VALUES
  (
    91,
    'Box',
    'asdasd',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]',
    '2026-01-21T10:06:54.038Z',
    '2026-01-21T10:06:54.038Z'
  );

# ------------------------------------------------------------
# DATA DUMP FOR TABLE: user
# ------------------------------------------------------------

INSERT INTO
  `user` (
    `user_id`,
    `full_name`,
    `username`,
    `password`,
    `status`,
    `email`,
    `designation`,
    `mobile_number`,
    `digital_signature`,
    `email_signature`,
    `last_login_ip`,
    `last_login_at`,
    `created_at`,
    `updated_at`,
    `privileges`,
    `role_id`
  )
VALUES
  (
    1,
    'Super Admin',
    'saleem',
    '$2b$10$8GpXZ0nM/UkW5ZgDjhrsWe7WpqhHIw2i9u4opFajhcC/PmtHa2bx6',
    '[{\"id\": 12, \"key\": \"active\", \"label\": \"Active\"}]',
    'sd@upturnist.com',
    'superadmin',
    '+971563723805',
    '/uploads/profile/446mcykdupw_2025_11_15.webp',
    'Regards,<br>Mohammed Saleem AK<br>Project Manager',
    '103.66.76.111',
    '2026-01-03T16:11:05.063Z',
    '2025-09-26 12:37:25',
    '2026-01-03T16:11:05.087Z',
    '[\"*\"]',
    'superadmin'
  );
INSERT INTO
  `user` (
    `user_id`,
    `full_name`,
    `username`,
    `password`,
    `status`,
    `email`,
    `designation`,
    `mobile_number`,
    `digital_signature`,
    `email_signature`,
    `last_login_ip`,
    `last_login_at`,
    `created_at`,
    `updated_at`,
    `privileges`,
    `role_id`
  )
VALUES
  (
    98,
    'Fatima Al-Husseini',
    'fatima',
    '$2b$10$oQih7zjKZKnko5fAhs7Cq.bHk2xodKqOYGqxL.2n.eUqzFuhWrlqC',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]',
    'fatima@apexitsolutions.ae',
    'Sales Manager',
    '+971561234567',
    '/uploads/profile/2rvfo01kmuy_2025_11_04.png',
    NULL,
    '2.48.229.207',
    '2025-11-13T08:05:44.856Z',
    '2025-11-04T04:30:29.390Z',
    '2026-01-03T12:41:54.167Z',
    '[]',
    '29'
  );
INSERT INTO
  `user` (
    `user_id`,
    `full_name`,
    `username`,
    `password`,
    `status`,
    `email`,
    `designation`,
    `mobile_number`,
    `digital_signature`,
    `email_signature`,
    `last_login_ip`,
    `last_login_at`,
    `created_at`,
    `updated_at`,
    `privileges`,
    `role_id`
  )
VALUES
  (
    99,
    'demo',
    'demo',
    '$2b$10$j8Zx0EXovqbElFq7/OkEu.Xlx3yWEpRybx9yRkiXRjVo1Xtnjubs6',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]',
    'demo@upturnist.com',
    'sales',
    '+971456777668',
    '0',
    '',
    '2.48.229.207',
    '2025-11-13T13:36:55.849Z',
    '2025-11-12T09:13:43.544Z',
    '2026-01-07T09:56:04.816Z',
    '[]',
    '29'
  );
INSERT INTO
  `user` (
    `user_id`,
    `full_name`,
    `username`,
    `password`,
    `status`,
    `email`,
    `designation`,
    `mobile_number`,
    `digital_signature`,
    `email_signature`,
    `last_login_ip`,
    `last_login_at`,
    `created_at`,
    `updated_at`,
    `privileges`,
    `role_id`
  )
VALUES
  (
    101,
    'test user demo',
    'testuser',
    '$2b$10$MZieD7P02VgRA7OwqFTM4u4cSTLLvR4.sdaD4/V5H9aLVvWlljBBq',
    '[{\"id\":12,\"key\":\"active\",\"label\":\"Active\"}]',
    'jaseerali2012@gmail.com',
    'Test',
    '+971195555555',
    '0',
    '',
    '103.74.138.81',
    '2025-11-15T07:38:05.015Z',
    '2025-11-15T06:08:26.853Z',
    '2026-01-03T12:22:19.332Z',
    '[]',
    '29'
  );

/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!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 */;
