diff --git a/DB/demodatabase.sql b/DB/demodatabase.sql index b447c289f..45b42a788 100644 --- a/DB/demodatabase.sql +++ b/DB/demodatabase.sql @@ -1,11 +1,11 @@ -- phpMyAdmin SQL Dump --- version 4.1.14 --- http://www.phpmyadmin.net +-- version 4.6.4 +-- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 --- Generation Time: Dec 13, 2016 at 10:36 AM --- Server version: 5.6.17 --- PHP Version: 5.5.12 +-- Generation Time: Jan 03, 2017 at 06:22 AM +-- Server version: 5.7.14 +-- PHP Version: 5.6.25 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; @@ -14,10 +14,10 @@ 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 utf8 */; +/*!40101 SET NAMES utf8mb4 */; -- --- Database: `community` +-- Database: `final` -- -- -------------------------------------------------------- @@ -26,14 +26,13 @@ SET time_zone = "+00:00"; -- Table structure for table `api_settings` -- -CREATE TABLE IF NOT EXISTS `api_settings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `api_settings` ( + `id` int(10) UNSIGNED NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -41,15 +40,14 @@ CREATE TABLE IF NOT EXISTS `api_settings` ( -- Table structure for table `banlist` -- -CREATE TABLE IF NOT EXISTS `banlist` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `banlist` ( + `id` int(10) UNSIGNED NOT NULL, `ban_status` tinyint(1) NOT NULL, `email_address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -57,14 +55,13 @@ CREATE TABLE IF NOT EXISTS `banlist` ( -- Table structure for table `bar_notifications` -- -CREATE TABLE IF NOT EXISTS `bar_notifications` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `bar_notifications` ( + `id` int(10) UNSIGNED NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `bar_notifications` @@ -79,16 +76,14 @@ INSERT INTO `bar_notifications` (`id`, `key`, `value`, `created_at`, `updated_at -- Table structure for table `canned_response` -- -CREATE TABLE IF NOT EXISTS `canned_response` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `user_id` int(10) unsigned NOT NULL, +CREATE TABLE `canned_response` ( + `id` int(10) UNSIGNED NOT NULL, + `user_id` int(10) UNSIGNED NOT NULL, `title` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `message` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `user_id` (`user_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -96,16 +91,15 @@ CREATE TABLE IF NOT EXISTS `canned_response` ( -- Table structure for table `common_settings` -- -CREATE TABLE IF NOT EXISTS `common_settings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `common_settings` ( + `id` int(10) UNSIGNED NOT NULL, `option_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `option_value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `optional_field` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `common_settings` @@ -126,14 +120,13 @@ INSERT INTO `common_settings` (`id`, `option_name`, `option_value`, `status`, `o -- Table structure for table `conditions` -- -CREATE TABLE IF NOT EXISTS `conditions` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `conditions` ( + `id` int(10) UNSIGNED NOT NULL, `job` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -141,8 +134,8 @@ CREATE TABLE IF NOT EXISTS `conditions` ( -- Table structure for table `country_code` -- -CREATE TABLE IF NOT EXISTS `country_code` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `country_code` ( + `id` int(10) UNSIGNED NOT NULL, `iso` char(2) COLLATE utf8_unicode_ci NOT NULL, `name` varchar(100) COLLATE utf8_unicode_ci NOT NULL, `nicename` varchar(100) COLLATE utf8_unicode_ci NOT NULL, @@ -150,9 +143,8 @@ CREATE TABLE IF NOT EXISTS `country_code` ( `numcode` smallint(6) NOT NULL, `phonecode` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=240 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `country_code` @@ -405,13 +397,12 @@ INSERT INTO `country_code` (`id`, `iso`, `name`, `nicename`, `iso3`, `numcode`, -- Table structure for table `custom_forms` -- -CREATE TABLE IF NOT EXISTS `custom_forms` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `custom_forms` ( + `id` int(10) UNSIGNED NOT NULL, `formname` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -419,8 +410,8 @@ CREATE TABLE IF NOT EXISTS `custom_forms` ( -- Table structure for table `custom_form_fields` -- -CREATE TABLE IF NOT EXISTS `custom_form_fields` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `custom_form_fields` ( + `id` int(10) UNSIGNED NOT NULL, `forms_id` int(11) NOT NULL, `label` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -428,9 +419,8 @@ CREATE TABLE IF NOT EXISTS `custom_form_fields` ( `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `required` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -438,11 +428,10 @@ CREATE TABLE IF NOT EXISTS `custom_form_fields` ( -- Table structure for table `date_format` -- -CREATE TABLE IF NOT EXISTS `date_format` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=10 ; +CREATE TABLE `date_format` ( + `id` int(10) UNSIGNED NOT NULL, + `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `date_format` @@ -465,11 +454,10 @@ INSERT INTO `date_format` (`id`, `format`) VALUES -- Table structure for table `date_time_format` -- -CREATE TABLE IF NOT EXISTS `date_time_format` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=10 ; +CREATE TABLE `date_time_format` ( + `id` int(10) UNSIGNED NOT NULL, + `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `date_time_format` @@ -492,12 +480,12 @@ INSERT INTO `date_time_format` (`id`, `format`) VALUES -- Table structure for table `department` -- -CREATE TABLE IF NOT EXISTS `department` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `department` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `sla` int(10) unsigned DEFAULT NULL, - `manager` int(10) unsigned DEFAULT NULL, + `sla` int(10) UNSIGNED DEFAULT NULL, + `manager` int(10) UNSIGNED DEFAULT NULL, `ticket_assignment` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `outgoing_email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `template_set` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -508,11 +496,8 @@ CREATE TABLE IF NOT EXISTS `department` ( `group_access` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `department_sign` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `sla` (`sla`), - KEY `manager_2` (`manager`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `department` @@ -529,13 +514,13 @@ INSERT INTO `department` (`id`, `name`, `type`, `sla`, `manager`, `ticket_assign -- Table structure for table `emails` -- -CREATE TABLE IF NOT EXISTS `emails` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `emails` ( + `id` int(10) UNSIGNED NOT NULL, `email_address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `email_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `department` int(10) unsigned DEFAULT NULL, - `priority` int(10) unsigned DEFAULT NULL, - `help_topic` int(10) unsigned DEFAULT NULL, + `department` int(10) UNSIGNED DEFAULT NULL, + `priority` int(10) UNSIGNED DEFAULT NULL, + `help_topic` int(10) UNSIGNED DEFAULT NULL, `user_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `password` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `fetching_host` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -561,13 +546,8 @@ CREATE TABLE IF NOT EXISTS `emails` ( `authentication` tinyint(1) NOT NULL, `header_spoofing` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `department` (`department`,`priority`,`help_topic`), - KEY `department_2` (`department`,`priority`,`help_topic`), - KEY `priority` (`priority`), - KEY `help_topic` (`help_topic`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -575,14 +555,13 @@ CREATE TABLE IF NOT EXISTS `emails` ( -- Table structure for table `failed_jobs` -- -CREATE TABLE IF NOT EXISTS `failed_jobs` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `failed_jobs` ( + `id` int(10) UNSIGNED NOT NULL, `connection` text COLLATE utf8_unicode_ci NOT NULL, `queue` text COLLATE utf8_unicode_ci NOT NULL, `payload` longtext COLLATE utf8_unicode_ci NOT NULL, - `failed_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `failed_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -590,16 +569,15 @@ CREATE TABLE IF NOT EXISTS `failed_jobs` ( -- Table structure for table `faveo_mails` -- -CREATE TABLE IF NOT EXISTS `faveo_mails` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `faveo_mails` ( + `id` int(10) UNSIGNED NOT NULL, `email_id` int(11) NOT NULL, `drive` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -607,15 +585,14 @@ CREATE TABLE IF NOT EXISTS `faveo_mails` ( -- Table structure for table `faveo_queues` -- -CREATE TABLE IF NOT EXISTS `faveo_queues` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `faveo_queues` ( + `id` int(10) UNSIGNED NOT NULL, `service_id` int(11) NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -623,17 +600,15 @@ CREATE TABLE IF NOT EXISTS `faveo_queues` ( -- Table structure for table `field_values` -- -CREATE TABLE IF NOT EXISTS `field_values` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `field_id` int(10) unsigned DEFAULT NULL, - `child_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `field_values` ( + `id` int(10) UNSIGNED NOT NULL, + `field_id` int(10) UNSIGNED DEFAULT NULL, + `child_id` int(10) UNSIGNED DEFAULT NULL, `field_key` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `field_value` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `field_values_field_id_foreign` (`field_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -641,8 +616,8 @@ CREATE TABLE IF NOT EXISTS `field_values` ( -- Table structure for table `groups` -- -CREATE TABLE IF NOT EXISTS `groups` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `groups` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `group_status` tinyint(1) NOT NULL, `can_create_ticket` tinyint(1) NOT NULL, @@ -659,9 +634,8 @@ CREATE TABLE IF NOT EXISTS `groups` ( `department_access` tinyint(1) NOT NULL, `admin_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `groups` @@ -678,16 +652,13 @@ INSERT INTO `groups` (`id`, `name`, `group_status`, `can_create_ticket`, `can_ed -- Table structure for table `group_assign_department` -- -CREATE TABLE IF NOT EXISTS `group_assign_department` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `group_id` int(10) unsigned NOT NULL, - `department_id` int(10) unsigned NOT NULL, +CREATE TABLE `group_assign_department` ( + `id` int(10) UNSIGNED NOT NULL, + `group_id` int(10) UNSIGNED NOT NULL, + `department_id` int(10) UNSIGNED NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `group_id` (`group_id`), - KEY `department_id` (`department_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -695,32 +666,25 @@ CREATE TABLE IF NOT EXISTS `group_assign_department` ( -- Table structure for table `help_topic` -- -CREATE TABLE IF NOT EXISTS `help_topic` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `help_topic` ( + `id` int(10) UNSIGNED NOT NULL, `topic` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `parent_topic` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `custom_form` int(10) unsigned DEFAULT NULL, - `department` int(10) unsigned DEFAULT NULL, - `ticket_status` int(10) unsigned DEFAULT NULL, - `priority` int(10) unsigned DEFAULT NULL, - `sla_plan` int(10) unsigned DEFAULT NULL, + `custom_form` int(10) UNSIGNED DEFAULT NULL, + `department` int(10) UNSIGNED DEFAULT NULL, + `ticket_status` int(10) UNSIGNED DEFAULT NULL, + `priority` int(10) UNSIGNED DEFAULT NULL, + `sla_plan` int(10) UNSIGNED DEFAULT NULL, `thank_page` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `ticket_num_format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `type` tinyint(1) NOT NULL, - `auto_assign` int(10) unsigned DEFAULT NULL, + `auto_assign` int(10) UNSIGNED DEFAULT NULL, `auto_response` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `custom_form` (`custom_form`), - KEY `department` (`department`), - KEY `ticket_status` (`ticket_status`), - KEY `priority` (`priority`), - KEY `sla_plan` (`sla_plan`), - KEY `auto_assign_2` (`auto_assign`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `help_topic` @@ -737,18 +701,16 @@ INSERT INTO `help_topic` (`id`, `topic`, `parent_topic`, `custom_form`, `departm -- Table structure for table `jobs` -- -CREATE TABLE IF NOT EXISTS `jobs` ( - `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `jobs` ( + `id` bigint(20) UNSIGNED NOT NULL, `queue` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `payload` longtext COLLATE utf8_unicode_ci NOT NULL, - `attempts` tinyint(3) unsigned NOT NULL, - `reserved` tinyint(3) unsigned NOT NULL, - `reserved_at` int(10) unsigned DEFAULT NULL, - `available_at` int(10) unsigned NOT NULL, - `created_at` int(10) unsigned NOT NULL, - PRIMARY KEY (`id`), - KEY `jobs_queue_reserved_reserved_at_index` (`queue`,`reserved`,`reserved_at`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `attempts` tinyint(3) UNSIGNED NOT NULL, + `reserved` tinyint(3) UNSIGNED NOT NULL, + `reserved_at` int(10) UNSIGNED DEFAULT NULL, + `available_at` int(10) UNSIGNED NOT NULL, + `created_at` int(10) UNSIGNED NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -756,8 +718,8 @@ CREATE TABLE IF NOT EXISTS `jobs` ( -- Table structure for table `kb_article` -- -CREATE TABLE IF NOT EXISTS `kb_article` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_article` ( + `id` int(10) UNSIGNED NOT NULL, `name` text COLLATE utf8_unicode_ci NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `description` text COLLATE utf8_unicode_ci NOT NULL, @@ -765,9 +727,8 @@ CREATE TABLE IF NOT EXISTS `kb_article` ( `type` tinyint(1) NOT NULL, `publish_time` datetime DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_article` @@ -776,7 +737,7 @@ CREATE TABLE IF NOT EXISTS `kb_article` ( INSERT INTO `kb_article` (`id`, `name`, `slug`, `description`, `status`, `type`, `publish_time`, `created_at`, `updated_at`) VALUES (1, 'DISCLAIMERS', 'disclaimers', '

ABC clothing.com does not promise that the site will be inoffensive, error-free or uninterrupted, or that it will provide specific information from use of the site or any content, search, or link on it. The site and its content are delivered on an “as-is” and “as-available” basis. ABC clothing.com cannot ensure that files you download from the site will be free of viruses or contamination or destructive features.

\r\n\r\n

Thebclothing.com disclaims all warranties, express or implied, including any implied warranties of merchantability and fitness for a particular purpose. ABC clothing.com will not be liable for any damages of any kind arising from the use of this site, including, without limitation, direct, indirect, incidental, and punitive and consequential damages.

\r\n\r\n

ABC clothing.com disclaims any and all liability for the acts, omissions, and conduct of any third-party users, ABC clothing.com users, advertisers, and/or sponsors on the Site, in connection with the Site, or other-wise related to your use of the Site. ABC clothing.com is not responsible for the products, services, actions, or failure to act of any third party in connection with or referenced on the Site. Without limiting the fore-going, you may report the misconduct of users and/or third-party advertisers or service and/or product providers referenced on or included in the Site to ABC clothing.com at Support@abcclothing.com

\r\n\r\n

ABC clothing.com may investigate the claim and take appropriate action, at its sole discretion.

\r\n\r\n

For any query kindly drop mail us on  Support@abcclothing.com.

\r\n', 1, 1, '2016-12-13 08:54:00', '2016-12-13 03:25:28', '2016-12-13 03:25:28'), (2, 'CUSTOM ORDER', 'custom-order', '

You saw, you liked but couldn’t see your size? We will custom make it for you.

\r\n\r\n

How it works:

\r\n\r\n
  1. You liked something and want to modify a little or have something else on mind, do pen it down and share it with us on Support@abcclothing.com
  2. \r\n
  3. We’ll work out the price depending on how detailed or intricate you want your garment.
  4. \r\n
  5. An advance would be required for any customized orders.
  6. \r\n
  7. Once you’ve placed a deposit, we’ll make you a sketch of the garment.
  8. \r\n
  9. We can complete your order in 15-20 days depending on the workload.
  10. \r\n
  11. We will also share some updates on the garment in case something needs to be changed.
  12. \r\n
  13. We finally ship it to your given address.
  14. \r\n

Note: No returns and refunds.

\r\n', 1, 1, '2016-12-13 08:56:00', '2016-12-13 03:26:24', '2016-12-13 03:26:24'), -(3, 'TROUSER SKIRTS', 'trouser-skirts', '

Paris takes its fashion very, very seriously. So seriously, in fact, that wearing the wrong thing has actually caused a riot.

\r\n\r\n

In 1911, two rival Parisian couture houses launched their "trouser skirts," an innovation in fashion that trod the very fixed line between the genders and seemed to promise greater flexibility for women in general. There were two different versions of the trouser skirt: One was a sort of baggy pant with a very low hanging crotch, described as "a sack with holes made for the legs to go through," not unlike the fashions on high streets today, and the other a pair of the same kind of pants topped with an over-skirt, again, not unlike high street fashions of today. Both versions were launched by models at the opening day of racing season to general revulsion and disgust, but thankfully, no violence.

\r\n\r\n

It wasn''t until the ladies attempted to promenade their future fashions on the boulevards that the fisticuffs started—at the Place de l''Opera, the poor models were attacked by a jeering mob of fashion Philistines, who pulled their hair, trampled their hats, and reduced them to tears. A squad of police officers on bicycles were dispatched to rescue the girls and escort them to safety.

\r\n', 1, 1, '2016-12-13 08:56:00', '2016-12-13 03:27:02', '2016-12-13 03:27:02'), +(3, 'TROUSER SKIRTS', 'trouser-skirts', '

Paris takes its fashion very, very seriously. So seriously, in fact, that wearing the wrong thing has actually caused a riot.

\r\n\r\n

In 1911, two rival Parisian couture houses launched their "trouser skirts," an innovation in fashion that trod the very fixed line between the genders and seemed to promise greater flexibility for women in general. There were two different versions of the trouser skirt: One was a sort of baggy pant with a very low hanging crotch, described as "a sack with holes made for the legs to go through," not unlike the fashions on high streets today, and the other a pair of the same kind of pants topped with an over-skirt, again, not unlike high street fashions of today. Both versions were launched by models at the opening day of racing season to general revulsion and disgust, but thankfully, no violence.

\r\n\r\n

It wasn\'t until the ladies attempted to promenade their future fashions on the boulevards that the fisticuffs started—at the Place de l\'Opera, the poor models were attacked by a jeering mob of fashion Philistines, who pulled their hair, trampled their hats, and reduced them to tears. A squad of police officers on bicycles were dispatched to rescue the girls and escort them to safety.

\r\n', 1, 1, '2016-12-13 08:56:00', '2016-12-13 03:27:02', '2016-12-13 03:27:02'), (4, 'SECURE SHOPPING GUARANTEE', 'secure-shopping-guarantee', '

We accept all major Indian and International Credit/ Debit Cards, and Net Banking with over 40 Banks.

\r\n\r\n

NO Cash on Delivery (as random people order and share false addresses for fun)

\r\n\r\n

Yes, shopping at our e-store is 100% safe. All payment requests are directed to the secured PayU Payment Gateway. This gives you the highest level of protection possible whenever you use credit cards or make other financial or confidential transactions over the Internet.

\r\n\r\n

You can be assured that our e-store offers you the highest standards of security currently available on the net so as to ensure that your shopping experience is private, safe and secure.

\r\n', 1, 1, '2016-12-13 08:57:00', '2016-12-13 03:27:42', '2016-12-13 03:27:42'), (5, 'PRIVACY POLICY', 'privacy-policy', '

The ABC Clothing collects your basic information to service your requests. This basic information is gathered when you purchase products/Gift card vouchers or when you sign up for e-mail notifications. Information gathered from you includes your name, mailing address, e-mail and phone number. Only when you place an order, your card information is requested and is submitted via the highest level of encryption to make sure of the greatest amount of safety and security. Reason why we gather this information:

\r\n\r\n

To process your order.
\r\nShipping and Customer Service.
\r\nWe also use the information to upgrade our products, customer services, website content and navigation.

\r\n\r\n


Internal Record Keeping.
\r\nWe at The ABC Clothing respect that you do not want your personal information shared with other companies. The information you provide shall, therefore, be only used to process your order and customer support. The ABC Clothing does not share, sell or rent customer information to any other company.

\r\n', 1, 1, '2016-12-13 08:58:00', '2016-12-13 03:28:31', '2016-12-13 03:28:31'), (6, ' SHIPPING POLICY', 'shipping-policy', '

We ship worldwide. We use FedEx/DTDC for shipping.

\r\n\r\n

Standard Shipping is usually 3-7 Working days for orders within India and 12-15 Working days for International Orders, but usually faster. IF your order doesn’t reach you in time, you may write to us at support@abcclothing.com

\r\n\r\n

International Orders

\r\n\r\n

For international orders, please note, your shipping will be calculated at the time of Check out only, this is a System Generated amount, based on your Zip Code, Region and Order Weight. (Approx Costs Rs.1250-1500 for 500 gms – International Shipment, subject to region)

\r\n\r\n

Tracking

\r\n\r\n

For tracking your order go to the following website, it will require your tracking ID which is sent via mail in your invoice.

\r\n', 1, 1, '2016-12-13 08:58:00', '2016-12-13 03:29:34', '2016-12-13 03:29:34'), @@ -788,16 +749,13 @@ INSERT INTO `kb_article` (`id`, `name`, `slug`, `description`, `status`, `type`, -- Table structure for table `kb_article_relationship` -- -CREATE TABLE IF NOT EXISTS `kb_article_relationship` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `article_id` int(10) unsigned NOT NULL, - `category_id` int(10) unsigned NOT NULL, +CREATE TABLE `kb_article_relationship` ( + `id` int(10) UNSIGNED NOT NULL, + `article_id` int(10) UNSIGNED NOT NULL, + `category_id` int(10) UNSIGNED NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `article_relationship_article_id_foreign` (`article_id`), - KEY `article_relationship_category_id_foreign` (`category_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_article_relationship` @@ -818,17 +776,16 @@ INSERT INTO `kb_article_relationship` (`id`, `article_id`, `category_id`, `creat -- Table structure for table `kb_category` -- -CREATE TABLE IF NOT EXISTS `kb_category` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_category` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `description` text COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `parent` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_category` @@ -844,19 +801,17 @@ INSERT INTO `kb_category` (`id`, `name`, `slug`, `description`, `status`, `paren -- Table structure for table `kb_comment` -- -CREATE TABLE IF NOT EXISTS `kb_comment` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `article_id` int(10) unsigned NOT NULL, +CREATE TABLE `kb_comment` ( + `id` int(10) UNSIGNED NOT NULL, + `article_id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `website` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `comment` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `comment_article_id_foreign` (`article_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -864,17 +819,16 @@ CREATE TABLE IF NOT EXISTS `kb_comment` ( -- Table structure for table `kb_pages` -- -CREATE TABLE IF NOT EXISTS `kb_pages` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_pages` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `visibility` tinyint(1) NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `description` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -882,13 +836,12 @@ CREATE TABLE IF NOT EXISTS `kb_pages` ( -- Table structure for table `kb_settings` -- -CREATE TABLE IF NOT EXISTS `kb_settings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_settings` ( + `id` int(10) UNSIGNED NOT NULL, `pagination` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_settings` @@ -903,12 +856,11 @@ INSERT INTO `kb_settings` (`id`, `pagination`, `created_at`, `updated_at`) VALUE -- Table structure for table `languages` -- -CREATE TABLE IF NOT EXISTS `languages` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `languages` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `locale` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=10 ; + `locale` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `languages` @@ -931,16 +883,15 @@ INSERT INTO `languages` (`id`, `name`, `locale`) VALUES -- Table structure for table `login_attempts` -- -CREATE TABLE IF NOT EXISTS `login_attempts` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `login_attempts` ( + `id` int(10) UNSIGNED NOT NULL, `User` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `IP` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `Attempts` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `LastLogin` datetime NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `login_attempts` @@ -955,13 +906,12 @@ INSERT INTO `login_attempts` (`id`, `User`, `IP`, `Attempts`, `LastLogin`, `crea -- Table structure for table `log_notification` -- -CREATE TABLE IF NOT EXISTS `log_notification` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `log_notification` ( + `id` int(10) UNSIGNED NOT NULL, `log` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `log_notification` @@ -976,12 +926,11 @@ INSERT INTO `log_notification` (`id`, `log`, `created_at`, `updated_at`) VALUES -- Table structure for table `mailbox_protocol` -- -CREATE TABLE IF NOT EXISTS `mailbox_protocol` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `mailbox_protocol` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `value` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=5 ; + `value` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `mailbox_protocol` @@ -999,14 +948,13 @@ INSERT INTO `mailbox_protocol` (`id`, `name`, `value`) VALUES -- Table structure for table `mail_services` -- -CREATE TABLE IF NOT EXISTS `mail_services` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `mail_services` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `short_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=7 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `mail_services` @@ -1026,7 +974,7 @@ INSERT INTO `mail_services` (`id`, `name`, `short_name`, `created_at`, `updated_ -- Table structure for table `migrations` -- -CREATE TABLE IF NOT EXISTS `migrations` ( +CREATE TABLE `migrations` ( `migration` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `batch` int(11) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; @@ -1141,15 +1089,14 @@ INSERT INTO `migrations` (`migration`, `batch`) VALUES -- Table structure for table `notifications` -- -CREATE TABLE IF NOT EXISTS `notifications` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `notifications` ( + `id` int(10) UNSIGNED NOT NULL, `model_id` int(11) NOT NULL, `userid_created` int(11) NOT NULL, `type_id` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `notifications` @@ -1170,15 +1117,14 @@ INSERT INTO `notifications` (`id`, `model_id`, `userid_created`, `type_id`, `cre -- Table structure for table `notification_types` -- -CREATE TABLE IF NOT EXISTS `notification_types` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `notification_types` ( + `id` int(10) UNSIGNED NOT NULL, `message` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `icon_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `notification_types` @@ -1195,19 +1141,17 @@ INSERT INTO `notification_types` (`id`, `message`, `type`, `icon_class`, `create -- Table structure for table `organization` -- -CREATE TABLE IF NOT EXISTS `organization` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `organization` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `phone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `website` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `head` int(10) unsigned DEFAULT NULL, + `head` int(10) UNSIGNED DEFAULT NULL, `internal_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `head` (`head`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1215,12 +1159,10 @@ CREATE TABLE IF NOT EXISTS `organization` ( -- Table structure for table `password_resets` -- -CREATE TABLE IF NOT EXISTS `password_resets` ( +CREATE TABLE `password_resets` ( `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `token` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `created_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', - KEY `password_resets_email_index` (`email`), - KEY `password_resets_token_index` (`token`) + `created_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00' ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1229,15 +1171,14 @@ CREATE TABLE IF NOT EXISTS `password_resets` ( -- Table structure for table `plugins` -- -CREATE TABLE IF NOT EXISTS `plugins` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `plugins` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `path` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1245,15 +1186,14 @@ CREATE TABLE IF NOT EXISTS `plugins` ( -- Table structure for table `queue_services` -- -CREATE TABLE IF NOT EXISTS `queue_services` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `queue_services` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `short_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=7 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `queue_services` @@ -1273,8 +1213,8 @@ INSERT INTO `queue_services` (`id`, `name`, `short_name`, `status`, `created_at` -- Table structure for table `ratings` -- -CREATE TABLE IF NOT EXISTS `ratings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ratings` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `display_order` int(11) NOT NULL, `allow_modification` int(11) NOT NULL, @@ -1282,9 +1222,8 @@ CREATE TABLE IF NOT EXISTS `ratings` ( `rating_area` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `restrict` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ratings` @@ -1300,16 +1239,15 @@ INSERT INTO `ratings` (`id`, `name`, `display_order`, `allow_modification`, `rat -- Table structure for table `rating_ref` -- -CREATE TABLE IF NOT EXISTS `rating_ref` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `rating_ref` ( + `id` int(10) UNSIGNED NOT NULL, `rating_id` int(11) NOT NULL, `ticket_id` int(11) NOT NULL, `thread_id` int(11) NOT NULL, `rating_value` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1317,8 +1255,8 @@ CREATE TABLE IF NOT EXISTS `rating_ref` ( -- Table structure for table `settings_alert_notice` -- -CREATE TABLE IF NOT EXISTS `settings_alert_notice` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_alert_notice` ( + `id` int(10) UNSIGNED NOT NULL, `ticket_status` tinyint(1) NOT NULL, `ticket_admin_email` tinyint(1) NOT NULL, `ticket_department_manager` tinyint(1) NOT NULL, @@ -1349,9 +1287,8 @@ CREATE TABLE IF NOT EXISTS `settings_alert_notice` ( `sql_error` tinyint(1) NOT NULL, `excessive_failure` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_alert_notice` @@ -1366,17 +1303,16 @@ INSERT INTO `settings_alert_notice` (`id`, `ticket_status`, `ticket_admin_email` -- Table structure for table `settings_auto_response` -- -CREATE TABLE IF NOT EXISTS `settings_auto_response` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_auto_response` ( + `id` int(10) UNSIGNED NOT NULL, `new_ticket` tinyint(1) NOT NULL, `agent_new_ticket` tinyint(1) NOT NULL, `submitter` tinyint(1) NOT NULL, `participants` tinyint(1) NOT NULL, `overlimit` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_auto_response` @@ -1391,8 +1327,8 @@ INSERT INTO `settings_auto_response` (`id`, `new_ticket`, `agent_new_ticket`, `s -- Table structure for table `settings_company` -- -CREATE TABLE IF NOT EXISTS `settings_company` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_company` ( + `id` int(10) UNSIGNED NOT NULL, `company_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `website` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `phone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1403,9 +1339,8 @@ CREATE TABLE IF NOT EXISTS `settings_company` ( `logo` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `use_logo` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_company` @@ -1420,8 +1355,8 @@ INSERT INTO `settings_company` (`id`, `company_name`, `website`, `phone`, `addre -- Table structure for table `settings_email` -- -CREATE TABLE IF NOT EXISTS `settings_email` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_email` ( + `id` int(10) UNSIGNED NOT NULL, `template` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `sys_email` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `alert_email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1435,9 +1370,8 @@ CREATE TABLE IF NOT EXISTS `settings_email` ( `email_collaborator` tinyint(1) NOT NULL, `attachment` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_email` @@ -1452,17 +1386,15 @@ INSERT INTO `settings_email` (`id`, `template`, `sys_email`, `alert_email`, `adm -- Table structure for table `settings_ratings` -- -CREATE TABLE IF NOT EXISTS `settings_ratings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_ratings` ( + `id` int(10) UNSIGNED NOT NULL, `rating_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `publish` int(11) NOT NULL, `modify` int(11) NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - UNIQUE KEY `settings_ratings_slug_unique` (`slug`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1470,17 +1402,16 @@ CREATE TABLE IF NOT EXISTS `settings_ratings` ( -- Table structure for table `settings_security` -- -CREATE TABLE IF NOT EXISTS `settings_security` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_security` ( + `id` int(10) UNSIGNED NOT NULL, `lockout_message` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `backlist_offender` int(11) NOT NULL, `backlist_threshold` int(11) NOT NULL, `lockout_period` int(11) NOT NULL, `days_to_keep_logs` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_security` @@ -1495,8 +1426,8 @@ INSERT INTO `settings_security` (`id`, `lockout_message`, `backlist_offender`, ` -- Table structure for table `settings_system` -- -CREATE TABLE IF NOT EXISTS `settings_system` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_system` ( + `id` int(10) UNSIGNED NOT NULL, `status` tinyint(1) NOT NULL, `url` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1508,21 +1439,16 @@ CREATE TABLE IF NOT EXISTS `settings_system` ( `api_key_mandatory` int(11) NOT NULL, `api_key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `name_format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `time_farmat` int(10) unsigned DEFAULT NULL, - `date_format` int(10) unsigned DEFAULT NULL, - `date_time_format` int(10) unsigned DEFAULT NULL, + `time_farmat` int(10) UNSIGNED DEFAULT NULL, + `date_format` int(10) UNSIGNED DEFAULT NULL, + `date_time_format` int(10) UNSIGNED DEFAULT NULL, `day_date_time` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `time_zone` int(10) unsigned DEFAULT NULL, + `time_zone` int(10) UNSIGNED DEFAULT NULL, `content` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `version` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `time_farmat` (`time_farmat`), - KEY `date_format` (`date_format`), - KEY `date_time_format` (`date_time_format`), - KEY `time_zone` (`time_zone`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_system` @@ -1530,7 +1456,8 @@ CREATE TABLE IF NOT EXISTS `settings_system` ( INSERT INTO `settings_system` (`id`, `status`, `url`, `name`, `department`, `page_size`, `log_level`, `purge_log`, `api_enable`, `api_key_mandatory`, `api_key`, `name_format`, `time_farmat`, `date_format`, `date_time_format`, `day_date_time`, `time_zone`, `content`, `version`, `created_at`, `updated_at`) VALUES (1, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 32, '', '', '2016-12-13 03:19:29', '2016-12-13 03:19:29'), -(2, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 79, '', '1.0.8.0', '2016-12-13 03:19:53', '2016-12-13 03:19:53'); +(2, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 79, '', '1.0.8.0', '2016-12-13 03:19:53', '2016-12-13 03:19:53'), +(3, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 14, '', '1.9.2', '2017-01-03 06:17:47', '2017-01-03 06:17:47'); -- -------------------------------------------------------- @@ -1538,8 +1465,8 @@ INSERT INTO `settings_system` (`id`, `status`, `url`, `name`, `department`, `pag -- Table structure for table `settings_ticket` -- -CREATE TABLE IF NOT EXISTS `settings_ticket` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_ticket` ( + `id` int(10) UNSIGNED NOT NULL, `num_format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `num_sequence` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `priority` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1558,9 +1485,8 @@ CREATE TABLE IF NOT EXISTS `settings_ticket` ( `client_update` tinyint(1) NOT NULL, `max_file_size` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_ticket` @@ -1575,8 +1501,8 @@ INSERT INTO `settings_ticket` (`id`, `num_format`, `num_sequence`, `priority`, ` -- Table structure for table `sla_plan` -- -CREATE TABLE IF NOT EXISTS `sla_plan` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `sla_plan` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `grace_period` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `admin_note` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1584,9 +1510,8 @@ CREATE TABLE IF NOT EXISTS `sla_plan` ( `transient` tinyint(1) NOT NULL, `ticket_overdue` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `sla_plan` @@ -1603,15 +1528,14 @@ INSERT INTO `sla_plan` (`id`, `name`, `grace_period`, `admin_note`, `status`, `t -- Table structure for table `social_media` -- -CREATE TABLE IF NOT EXISTS `social_media` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `social_media` ( + `id` int(10) UNSIGNED NOT NULL, `provider` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1619,18 +1543,16 @@ CREATE TABLE IF NOT EXISTS `social_media` ( -- Table structure for table `teams` -- -CREATE TABLE IF NOT EXISTS `teams` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `teams` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, - `team_lead` int(10) unsigned DEFAULT NULL, + `team_lead` int(10) UNSIGNED DEFAULT NULL, `assign_alert` tinyint(1) NOT NULL, `admin_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `team_lead` (`team_lead`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `teams` @@ -1647,16 +1569,13 @@ INSERT INTO `teams` (`id`, `name`, `status`, `team_lead`, `assign_alert`, `admin -- Table structure for table `team_assign_agent` -- -CREATE TABLE IF NOT EXISTS `team_assign_agent` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `team_id` int(10) unsigned DEFAULT NULL, - `agent_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `team_assign_agent` ( + `id` int(10) UNSIGNED NOT NULL, + `team_id` int(10) UNSIGNED DEFAULT NULL, + `agent_id` int(10) UNSIGNED DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `team_id` (`team_id`), - KEY `agent_id` (`agent_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `team_assign_agent` @@ -1672,17 +1591,16 @@ INSERT INTO `team_assign_agent` (`id`, `team_id`, `agent_id`, `created_at`, `upd -- Table structure for table `template` -- -CREATE TABLE IF NOT EXISTS `template` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `template` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `template_set_to_clone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `language` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_note` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1690,8 +1608,8 @@ CREATE TABLE IF NOT EXISTS `template` ( -- Table structure for table `templates` -- -CREATE TABLE IF NOT EXISTS `templates` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `templates` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `variable` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` int(11) NOT NULL, @@ -1700,9 +1618,8 @@ CREATE TABLE IF NOT EXISTS `templates` ( `description` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `set_id` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=14 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `templates` @@ -1716,12 +1633,13 @@ INSERT INTO `templates` (`id`, `name`, `variable`, `type`, `subject`, `message`, (5, 'This template is for sending notice to agent on new ticket creation', '0', 5, '', '
Hello {!!$ticket_agent_name!!},

New ticket {!!$ticket_number!!}created 

From
Name: {!!$ticket_client_name!!}   
E-mail: {!!$ticket_client_email!!}

{!!$content!!}

Kind Regards,
{!!$system_from!!}
', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (6, 'This template is for sending notice to client on new ticket created by agent in name of client', '0', 6, '', '
{!!$content!!}

{!!$agent_sign!!}

You can check the status of or update this ticket online at: {!!$system_link!!}
', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (7, 'This template is for sending notice to client on new registration during new ticket creation for un registered clients', '1', 7, 'Registration Confirmation', '

Hello {!!$user!!}, 

This email is confirmation that you are now registered at our helpdesk.

Registered Email: {!!$email_address!!}

Password: {!!$user_password!!}

You can visit the helpdesk to browse articles and contact us at any time: {!!$system_link!!}

Thank You.

Kind Regards,

{!!$system_from!!} 

', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), -(8, 'This template is for sending notice to any user about reset password option', '1', 8, 'Reset your Password', 'Hello {!!$user!!},

You asked to reset your password. To do so, please click this link:

{!!$password_reset_link!!}

This will let you change your password to something new. If you didn''t ask for this, don''t worry, we''ll keep your password safe.

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), +(8, 'This template is for sending notice to any user about reset password option', '1', 8, 'Reset your Password', 'Hello {!!$user!!},

You asked to reset your password. To do so, please click this link:

{!!$password_reset_link!!}

This will let you change your password to something new. If you didn\'t ask for this, don\'t worry, we\'ll keep your password safe.

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (9, 'This template is for sending notice to client when a reply made to his/her ticket', '0', 9, '', '

{!!$content!!}

{!!$agent_sign!!} 

Ticket Details

Ticket ID: {!!$ticket_number!!}

', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (10, 'This template is for sending notice to agent when ticket reply is made by client on a ticket', '0', 10, '', '
Hello {!!$ticket_agent_name!!},

A reply been made to ticket {!!$ticket_number!!}

From
Name: {!!$ticket_client_name!!}
E-mail: {!!$ticket_client_email!!}

{!!$content!!}

Kind Regards,
{!!$system_from!!}
', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (11, 'This template is for sending notice to client about registration confirmation link', '1', 11, 'Verify your email address', '

Hello {!!$user!!}, 

This email is confirmation that you are now registered at our helpdesk.

Registered Email: {!!$email_address!!}

Please click on the below link to activate your account and Login to the system {!!$password_reset_link!!}

Thank You.

Kind Regards,

{!!$system_from!!} 

', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'), (12, 'This template is for sending notice to team when ticket is assigned to team', '1', 12, '', '
Hello {!!$ticket_agent_name!!},

Ticket No: {!!$ticket_number!!}
Has been assigned to your team : {!!$team!!} by {!!$ticket_assigner!!} 

Thank You
Kind Regards,
{!!$system_from!!}
', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'), -(13, 'This template is for sending notice to client when password is changed', '1', 13, 'Verify your email address', 'Hello {!!$user!!},

Your password is successfully changed.Your new password is : {!!$user_password!!}

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'); +(13, 'This template is for sending notice to client when password is changed', '1', 13, 'Verify your email address', 'Hello {!!$user!!},

Your password is successfully changed.Your new password is : {!!$user_password!!}

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'), +(14, 'This template is to notify users when their tickets are merged.', '1', 14, 'Your tickets have been merged.', '

Hello {!!$user!!},
 

Your ticket(s) with ticket number {!!$merged_ticket_numbers!!} have been closed and merged with {!!$ticket_number!!}

Possible reasons for merging tickets

Click here to login to your account and check your tickets.

Regards,

{!!$system_from!!}

', '', 1, '2017-01-02 00:20:12', '2017-01-02 00:31:50'); -- -------------------------------------------------------- @@ -1729,14 +1647,13 @@ INSERT INTO `templates` (`id`, `name`, `variable`, `type`, `subject`, `message`, -- Table structure for table `template_sets` -- -CREATE TABLE IF NOT EXISTS `template_sets` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `template_sets` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `active` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `template_sets` @@ -1751,13 +1668,12 @@ INSERT INTO `template_sets` (`id`, `name`, `active`, `created_at`, `updated_at`) -- Table structure for table `template_types` -- -CREATE TABLE IF NOT EXISTS `template_types` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `template_types` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=14 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `template_types` @@ -1776,7 +1692,8 @@ INSERT INTO `template_types` (`id`, `name`, `created_at`, `updated_at`) VALUES (10, 'ticket-reply-agent', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), (11, 'registration', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), (12, 'team_assign_ticket', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), -(13, 'reset_new_password', '2016-12-13 03:19:48', '2016-12-13 03:19:48'); +(13, 'reset_new_password', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), +(14, 'merge-ticket-notification', '2017-01-02 00:20:11', '2017-01-02 00:20:11'); -- -------------------------------------------------------- @@ -1784,24 +1701,24 @@ INSERT INTO `template_types` (`id`, `name`, `created_at`, `updated_at`) VALUES -- Table structure for table `tickets` -- -CREATE TABLE IF NOT EXISTS `tickets` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `tickets` ( + `id` int(10) UNSIGNED NOT NULL, `ticket_number` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `user_id` int(10) unsigned DEFAULT NULL, - `dept_id` int(10) unsigned DEFAULT NULL, - `team_id` int(10) unsigned DEFAULT NULL, - `priority_id` int(10) unsigned DEFAULT NULL, - `sla` int(10) unsigned DEFAULT NULL, - `help_topic_id` int(10) unsigned DEFAULT NULL, - `status` int(10) unsigned DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, + `dept_id` int(10) UNSIGNED DEFAULT NULL, + `team_id` int(10) UNSIGNED DEFAULT NULL, + `priority_id` int(10) UNSIGNED DEFAULT NULL, + `sla` int(10) UNSIGNED DEFAULT NULL, + `help_topic_id` int(10) UNSIGNED DEFAULT NULL, + `status` int(10) UNSIGNED DEFAULT NULL, `rating` tinyint(1) NOT NULL, `ratingreply` tinyint(1) NOT NULL, `flags` int(11) NOT NULL, `ip_address` int(11) NOT NULL, - `assigned_to` int(10) unsigned DEFAULT NULL, + `assigned_to` int(10) UNSIGNED DEFAULT NULL, `lock_by` int(11) NOT NULL, `lock_at` datetime DEFAULT NULL, - `source` int(10) unsigned DEFAULT NULL, + `source` int(10) UNSIGNED DEFAULT NULL, `isoverdue` int(11) NOT NULL, `reopened` int(11) NOT NULL, `isanswered` int(11) NOT NULL, @@ -1818,18 +1735,8 @@ CREATE TABLE IF NOT EXISTS `tickets` ( `approval` int(11) NOT NULL, `follow_up` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `user_id` (`user_id`), - KEY `dept_id` (`dept_id`), - KEY `team_id` (`team_id`), - KEY `priority_id` (`priority_id`), - KEY `sla` (`sla`), - KEY `help_topic_id` (`help_topic_id`), - KEY `status` (`status`), - KEY `assigned_to` (`assigned_to`), - KEY `source` (`source`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=7 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `tickets` @@ -1849,10 +1756,10 @@ INSERT INTO `tickets` (`id`, `ticket_number`, `user_id`, `dept_id`, `team_id`, ` -- Table structure for table `ticket_attachment` -- -CREATE TABLE IF NOT EXISTS `ticket_attachment` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_attachment` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `thread_id` int(10) unsigned DEFAULT NULL, + `thread_id` int(10) UNSIGNED DEFAULT NULL, `size` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `poster` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1860,10 +1767,8 @@ CREATE TABLE IF NOT EXISTS `ticket_attachment` ( `updated_at` timestamp NULL DEFAULT NULL, `file` mediumblob, `driver` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `path` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`), - KEY `thread_id` (`thread_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `path` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1871,18 +1776,15 @@ CREATE TABLE IF NOT EXISTS `ticket_attachment` ( -- Table structure for table `ticket_collaborator` -- -CREATE TABLE IF NOT EXISTS `ticket_collaborator` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_collaborator` ( + `id` int(10) UNSIGNED NOT NULL, `isactive` tinyint(1) NOT NULL, - `ticket_id` int(10) unsigned DEFAULT NULL, - `user_id` int(10) unsigned DEFAULT NULL, + `ticket_id` int(10) UNSIGNED DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, `role` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `ticket_id` (`ticket_id`), - KEY `user_id` (`user_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1890,16 +1792,14 @@ CREATE TABLE IF NOT EXISTS `ticket_collaborator` ( -- Table structure for table `ticket_form_data` -- -CREATE TABLE IF NOT EXISTS `ticket_form_data` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `ticket_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `ticket_form_data` ( + `id` int(10) UNSIGNED NOT NULL, + `ticket_id` int(10) UNSIGNED DEFAULT NULL, `title` text COLLATE utf8_unicode_ci NOT NULL, `content` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `ticket_id` (`ticket_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1907,8 +1807,8 @@ CREATE TABLE IF NOT EXISTS `ticket_form_data` ( -- Table structure for table `ticket_priority` -- -CREATE TABLE IF NOT EXISTS `ticket_priority` ( - `priority_id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_priority` ( + `priority_id` int(10) UNSIGNED NOT NULL, `priority` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `priority_desc` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1917,9 +1817,8 @@ CREATE TABLE IF NOT EXISTS `ticket_priority` ( `ispublic` tinyint(1) NOT NULL, `is_default` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`priority_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=5 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_priority` @@ -1937,13 +1836,12 @@ INSERT INTO `ticket_priority` (`priority_id`, `priority`, `status`, `priority_de -- Table structure for table `ticket_source` -- -CREATE TABLE IF NOT EXISTS `ticket_source` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_source` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `css_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=11 ; + `css_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_source` @@ -1967,8 +1865,8 @@ INSERT INTO `ticket_source` (`id`, `name`, `value`, `css_class`) VALUES -- Table structure for table `ticket_status` -- -CREATE TABLE IF NOT EXISTS `ticket_status` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_status` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `state` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `mode` int(11) NOT NULL, @@ -1979,9 +1877,8 @@ CREATE TABLE IF NOT EXISTS `ticket_status` ( `icon_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `properties` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_status` @@ -2002,12 +1899,12 @@ INSERT INTO `ticket_status` (`id`, `name`, `state`, `mode`, `message`, `flags`, -- Table structure for table `ticket_thread` -- -CREATE TABLE IF NOT EXISTS `ticket_thread` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `ticket_id` int(10) unsigned DEFAULT NULL, - `user_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `ticket_thread` ( + `id` int(10) UNSIGNED NOT NULL, + `ticket_id` int(10) UNSIGNED DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, `poster` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `source` int(10) unsigned DEFAULT NULL, + `source` int(10) UNSIGNED DEFAULT NULL, `reply_rating` int(11) NOT NULL, `rating_count` int(11) NOT NULL, `is_internal` tinyint(1) NOT NULL, @@ -2016,12 +1913,8 @@ CREATE TABLE IF NOT EXISTS `ticket_thread` ( `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `ip_address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `ticket_id_2` (`ticket_id`), - KEY `user_id` (`user_id`), - KEY `source` (`source`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=12 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_thread` @@ -2046,14 +1939,13 @@ INSERT INTO `ticket_thread` (`id`, `ticket_id`, `user_id`, `poster`, `source`, ` -- Table structure for table `ticket_token` -- -CREATE TABLE IF NOT EXISTS `ticket_token` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_token` ( + `id` int(10) UNSIGNED NOT NULL, `ticket_id` int(11) NOT NULL, `token` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2061,12 +1953,11 @@ CREATE TABLE IF NOT EXISTS `ticket_token` ( -- Table structure for table `timezone` -- -CREATE TABLE IF NOT EXISTS `timezone` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `timezone` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `location` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=114 ; + `location` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `timezone` @@ -2193,11 +2084,10 @@ INSERT INTO `timezone` (`id`, `name`, `location`) VALUES -- Table structure for table `time_format` -- -CREATE TABLE IF NOT EXISTS `time_format` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; +CREATE TABLE `time_format` ( + `id` int(10) UNSIGNED NOT NULL, + `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `time_format` @@ -2213,8 +2103,8 @@ INSERT INTO `time_format` (`id`, `format`) VALUES -- Table structure for table `users` -- -CREATE TABLE IF NOT EXISTS `users` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `users` ( + `id` int(10) UNSIGNED NOT NULL, `user_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `first_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `last_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -2231,8 +2121,8 @@ CREATE TABLE IF NOT EXISTS `users` ( `agent_sign` text COLLATE utf8_unicode_ci NOT NULL, `account_type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `account_status` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `assign_group` int(10) unsigned DEFAULT NULL, - `primary_dpt` int(10) unsigned DEFAULT NULL, + `assign_group` int(10) UNSIGNED DEFAULT NULL, + `primary_dpt` int(10) UNSIGNED DEFAULT NULL, `agent_tzone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `daylight_save` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `limit_access` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -2244,26 +2134,21 @@ CREATE TABLE IF NOT EXISTS `users` ( `profile_pic` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `remember_token` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - UNIQUE KEY `users_email_unique` (`email`), - UNIQUE KEY `users_mobile_unique` (`mobile`), - KEY `assign_group_3` (`assign_group`), - KEY `primary_dpt_2` (`primary_dpt`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `users` -- INSERT INTO `users` (`id`, `user_name`, `first_name`, `last_name`, `gender`, `email`, `ban`, `password`, `active`, `is_delete`, `ext`, `country_code`, `phone_number`, `mobile`, `agent_sign`, `account_type`, `account_status`, `assign_group`, `primary_dpt`, `agent_tzone`, `daylight_save`, `limit_access`, `directory_listing`, `vacation_mode`, `company`, `role`, `internal_note`, `profile_pic`, `remember_token`, `created_at`, `updated_at`) VALUES -(1, 'demo@admin.com', 'Demo', 'admin', 0, 'demo@admin.com', 0, '$2y$10$ZkHOJeJCKFzLtL4yWXZ3suVZlG.fJwD9oUI3nM5FGESmIkQV1hMXC', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '', '', '', '', '', '', 'admin', '', '', NULL, '2016-12-13 03:19:53', '2016-12-13 03:19:53'), -(2, 'Abhrakasin', 'Abhrakasin', 'KK', 0, 'abhrakasin@gmail.com', 0, '$2y$10$nrMZMd72/HZbnzjBAi0RX.UQrNTtFeZFEK9aq.chDPZZ07rOC/6Ie', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '79', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:32:41', '2016-12-13 03:32:42'), -(3, 'Johan', 'Johan', 'Malhotra', 0, 'johan21@gmail.com', 0, '$2y$10$Eq8SHKUEXCkW5vqiWvA0Iu1UJmzZ.e5.Q3hI2tkxey5HZ2Lmbxb1C', 1, 0, '', 0, '', NULL, '', '', '', 2, 2, '7', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:35:29', '2016-12-13 03:35:30'), -(4, 'fidelm@gmail.com', 'Fidel Martin', '', 0, 'fidelm@gmail.com', 0, '$2y$10$wHupGhJqz2p4rcdS4eq4ZO.NQ65b0JjVsqhJwEEzOCl3vMKwzh9/S', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'PXj6d2s7rOqoh53gHdyPbiHOVvBmDoR5CnXg9kl7fRolIC92Y20UnFPSOryw', '2016-12-13 03:45:19', '2016-12-13 03:45:19'), -(5, 'joseph2321@gmail.com', 'Joseph Rossignol', '', 0, 'joseph2321@gmail.com', 0, '$2y$10$7eQ0nFxQpQkWaKwUbzTsQ.ufQpRN1rwUGY5ER1KsoXoLd6KbMIHnG', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'nv7Z37jhwAVdt87WCVzsqweY6wUbic7ll44FNmygMmwcnErafCrVpnw6Krys', '2016-12-13 03:50:55', '2016-12-13 03:50:55'), -(6, 'ichae1212@gmail.com', 'Ichae Semos', '', 0, 'ichae1212@gmail.com', 0, '$2y$10$aITz4IUuaxb0VHwF2V2CPefwf/Ft0VXpmHDC9feEfNXkW90GdjCFm', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'egq0NWPaxEkwkXmV3L0BJ4j4O6aKlgjzNZxea0XpYvCAeVvZLbXsjkKmWyBZ', '2016-12-13 03:55:54', '2016-12-13 03:55:54'), -(7, 'kusti09@yahoo.com', 'Kusti Franti', '', 0, 'kusti09@yahoo.com', 0, '$2y$10$yNHebbyWfr6m1t4srRlYbuj2JN706ZBpyMI.gSJmuY9czJ3OzuQpq', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', '4JPKOO9UUjZ2yX1GI7WYaeljcdyFATmguwNGuUD9chDodCVfJVGBJvbepgOt', '2016-12-13 03:58:40', '2016-12-13 03:58:40'); +(1, 'demo_admin', 'Demo', 'Admin', 0, NULL, 0, '$2y$10$ZkHOJeJCKFzLtL4yWXZ3suVZlG.fJwD9oUI3nM5FGESmIkQV1hMXC', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '', '', '', '', '', '', 'admin', '', '', NULL, '2016-12-13 03:19:53', '2016-12-13 03:19:53'), +(2, 'demo_agent', 'Abhrakasin', 'KK', 0, NULL, 0, '$2y$10$nrMZMd72/HZbnzjBAi0RX.UQrNTtFeZFEK9aq.chDPZZ07rOC/6Ie', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '79', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:32:41', '2016-12-13 03:32:42'), +(3, 'Johan', 'Johan', 'Malhotra', 0, NULL, 0, '$2y$10$Eq8SHKUEXCkW5vqiWvA0Iu1UJmzZ.e5.Q3hI2tkxey5HZ2Lmbxb1C', 1, 0, '', 0, '', NULL, '', '', '', 2, 2, '7', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:35:29', '2016-12-13 03:35:30'), +(4, 'demo_client', 'Fidel Martin', '', 0, NULL, 0, '$2y$10$wHupGhJqz2p4rcdS4eq4ZO.NQ65b0JjVsqhJwEEzOCl3vMKwzh9/S', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'PXj6d2s7rOqoh53gHdyPbiHOVvBmDoR5CnXg9kl7fRolIC92Y20UnFPSOryw', '2016-12-13 03:45:19', '2016-12-13 03:45:19'), +(5, 'joseph2321@gmail.com', 'Joseph Rossignol', '', 0, NULL, 0, '$2y$10$7eQ0nFxQpQkWaKwUbzTsQ.ufQpRN1rwUGY5ER1KsoXoLd6KbMIHnG', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'nv7Z37jhwAVdt87WCVzsqweY6wUbic7ll44FNmygMmwcnErafCrVpnw6Krys', '2016-12-13 03:50:55', '2016-12-13 03:50:55'), +(6, 'ichae1212@gmail.com', 'Ichae Semos', '', 0, NULL, 0, '$2y$10$aITz4IUuaxb0VHwF2V2CPefwf/Ft0VXpmHDC9feEfNXkW90GdjCFm', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'egq0NWPaxEkwkXmV3L0BJ4j4O6aKlgjzNZxea0XpYvCAeVvZLbXsjkKmWyBZ', '2016-12-13 03:55:54', '2016-12-13 03:55:54'), +(7, 'kusti09@yahoo.com', 'Kusti Franti', '', 0, NULL, 0, '$2y$10$yNHebbyWfr6m1t4srRlYbuj2JN706ZBpyMI.gSJmuY9czJ3OzuQpq', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', '4JPKOO9UUjZ2yX1GI7WYaeljcdyFATmguwNGuUD9chDodCVfJVGBJvbepgOt', '2016-12-13 03:58:40', '2016-12-13 03:58:40'); -- -------------------------------------------------------- @@ -2271,16 +2156,15 @@ INSERT INTO `users` (`id`, `user_name`, `first_name`, `last_name`, `gender`, `em -- Table structure for table `user_additional_infos` -- -CREATE TABLE IF NOT EXISTS `user_additional_infos` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `user_additional_infos` ( + `id` int(10) UNSIGNED NOT NULL, `owner` int(11) NOT NULL, `service` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2288,16 +2172,13 @@ CREATE TABLE IF NOT EXISTS `user_additional_infos` ( -- Table structure for table `user_assign_organization` -- -CREATE TABLE IF NOT EXISTS `user_assign_organization` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `org_id` int(10) unsigned DEFAULT NULL, - `user_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `user_assign_organization` ( + `id` int(10) UNSIGNED NOT NULL, + `org_id` int(10) UNSIGNED DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `org_id` (`org_id`), - KEY `user_id` (`user_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2305,15 +2186,14 @@ CREATE TABLE IF NOT EXISTS `user_assign_organization` ( -- Table structure for table `user_notification` -- -CREATE TABLE IF NOT EXISTS `user_notification` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `user_notification` ( + `id` int(10) UNSIGNED NOT NULL, `notification_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `is_read` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=15 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `user_notification` @@ -2341,14 +2221,13 @@ INSERT INTO `user_notification` (`id`, `notification_id`, `user_id`, `is_read`, -- Table structure for table `version_check` -- -CREATE TABLE IF NOT EXISTS `version_check` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `version_check` ( + `id` int(10) UNSIGNED NOT NULL, `current_version` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `new_version` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `version_check` @@ -2363,15 +2242,14 @@ INSERT INTO `version_check` (`id`, `current_version`, `new_version`, `created_at -- Table structure for table `widgets` -- -CREATE TABLE IF NOT EXISTS `widgets` ( - `id` int(11) NOT NULL AUTO_INCREMENT, +CREATE TABLE `widgets` ( + `id` int(11) NOT NULL, `name` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, `title` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL, `value` text COLLATE utf8_unicode_ci, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=21 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `widgets` @@ -2405,16 +2283,14 @@ INSERT INTO `widgets` (`id`, `name`, `title`, `value`, `created_at`, `updated_at -- Table structure for table `workflow_action` -- -CREATE TABLE IF NOT EXISTS `workflow_action` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `workflow_id` int(10) unsigned NOT NULL, +CREATE TABLE `workflow_action` ( + `id` int(10) UNSIGNED NOT NULL, + `workflow_id` int(10) UNSIGNED NOT NULL, `condition` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `action` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `workflow_action_1` (`workflow_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2422,16 +2298,15 @@ CREATE TABLE IF NOT EXISTS `workflow_action` ( -- Table structure for table `workflow_close` -- -CREATE TABLE IF NOT EXISTS `workflow_close` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `workflow_close` ( + `id` int(10) UNSIGNED NOT NULL, `days` int(11) NOT NULL, `condition` int(11) NOT NULL, `send_email` int(11) NOT NULL, `status` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `workflow_close` @@ -2446,17 +2321,16 @@ INSERT INTO `workflow_close` (`id`, `days`, `condition`, `send_email`, `status`, -- Table structure for table `workflow_name` -- -CREATE TABLE IF NOT EXISTS `workflow_name` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `workflow_name` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` int(11) NOT NULL, `order` int(11) NOT NULL, `target` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_note` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2464,19 +2338,921 @@ CREATE TABLE IF NOT EXISTS `workflow_name` ( -- Table structure for table `workflow_rules` -- -CREATE TABLE IF NOT EXISTS `workflow_rules` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `workflow_id` int(10) unsigned NOT NULL, +CREATE TABLE `workflow_rules` ( + `id` int(10) UNSIGNED NOT NULL, + `workflow_id` int(10) UNSIGNED NOT NULL, `matching_criteria` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `matching_scenario` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `matching_relation` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `matching_value` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `workflow_rules_1` (`workflow_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +-- +-- Indexes for dumped tables +-- + +-- +-- Indexes for table `api_settings` +-- +ALTER TABLE `api_settings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `banlist` +-- +ALTER TABLE `banlist` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `bar_notifications` +-- +ALTER TABLE `bar_notifications` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `canned_response` +-- +ALTER TABLE `canned_response` + ADD PRIMARY KEY (`id`), + ADD KEY `user_id` (`user_id`); + +-- +-- Indexes for table `common_settings` +-- +ALTER TABLE `common_settings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `conditions` +-- +ALTER TABLE `conditions` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `country_code` +-- +ALTER TABLE `country_code` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `custom_forms` +-- +ALTER TABLE `custom_forms` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `custom_form_fields` +-- +ALTER TABLE `custom_form_fields` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `date_format` +-- +ALTER TABLE `date_format` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `date_time_format` +-- +ALTER TABLE `date_time_format` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `department` +-- +ALTER TABLE `department` + ADD PRIMARY KEY (`id`), + ADD KEY `sla` (`sla`), + ADD KEY `manager_2` (`manager`); + +-- +-- Indexes for table `emails` +-- +ALTER TABLE `emails` + ADD PRIMARY KEY (`id`), + ADD KEY `department` (`department`,`priority`,`help_topic`), + ADD KEY `department_2` (`department`,`priority`,`help_topic`), + ADD KEY `priority` (`priority`), + ADD KEY `help_topic` (`help_topic`); + +-- +-- Indexes for table `failed_jobs` +-- +ALTER TABLE `failed_jobs` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `faveo_mails` +-- +ALTER TABLE `faveo_mails` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `faveo_queues` +-- +ALTER TABLE `faveo_queues` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `field_values` +-- +ALTER TABLE `field_values` + ADD PRIMARY KEY (`id`), + ADD KEY `field_values_field_id_foreign` (`field_id`); + +-- +-- Indexes for table `groups` +-- +ALTER TABLE `groups` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `group_assign_department` +-- +ALTER TABLE `group_assign_department` + ADD PRIMARY KEY (`id`), + ADD KEY `group_id` (`group_id`), + ADD KEY `department_id` (`department_id`); + +-- +-- Indexes for table `help_topic` +-- +ALTER TABLE `help_topic` + ADD PRIMARY KEY (`id`), + ADD KEY `custom_form` (`custom_form`), + ADD KEY `department` (`department`), + ADD KEY `ticket_status` (`ticket_status`), + ADD KEY `priority` (`priority`), + ADD KEY `sla_plan` (`sla_plan`), + ADD KEY `auto_assign_2` (`auto_assign`); + +-- +-- Indexes for table `jobs` +-- +ALTER TABLE `jobs` + ADD PRIMARY KEY (`id`), + ADD KEY `jobs_queue_reserved_reserved_at_index` (`queue`,`reserved`,`reserved_at`); + +-- +-- Indexes for table `kb_article` +-- +ALTER TABLE `kb_article` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `kb_article_relationship` +-- +ALTER TABLE `kb_article_relationship` + ADD PRIMARY KEY (`id`), + ADD KEY `article_relationship_article_id_foreign` (`article_id`), + ADD KEY `article_relationship_category_id_foreign` (`category_id`); + +-- +-- Indexes for table `kb_category` +-- +ALTER TABLE `kb_category` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `kb_comment` +-- +ALTER TABLE `kb_comment` + ADD PRIMARY KEY (`id`), + ADD KEY `comment_article_id_foreign` (`article_id`); + +-- +-- Indexes for table `kb_pages` +-- +ALTER TABLE `kb_pages` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `kb_settings` +-- +ALTER TABLE `kb_settings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `languages` +-- +ALTER TABLE `languages` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `login_attempts` +-- +ALTER TABLE `login_attempts` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `log_notification` +-- +ALTER TABLE `log_notification` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `mailbox_protocol` +-- +ALTER TABLE `mailbox_protocol` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `mail_services` +-- +ALTER TABLE `mail_services` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `notifications` +-- +ALTER TABLE `notifications` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `notification_types` +-- +ALTER TABLE `notification_types` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `organization` +-- +ALTER TABLE `organization` + ADD PRIMARY KEY (`id`), + ADD KEY `head` (`head`); + +-- +-- Indexes for table `password_resets` +-- +ALTER TABLE `password_resets` + ADD KEY `password_resets_email_index` (`email`), + ADD KEY `password_resets_token_index` (`token`); + +-- +-- Indexes for table `plugins` +-- +ALTER TABLE `plugins` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `queue_services` +-- +ALTER TABLE `queue_services` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `ratings` +-- +ALTER TABLE `ratings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `rating_ref` +-- +ALTER TABLE `rating_ref` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_alert_notice` +-- +ALTER TABLE `settings_alert_notice` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_auto_response` +-- +ALTER TABLE `settings_auto_response` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_company` +-- +ALTER TABLE `settings_company` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_email` +-- +ALTER TABLE `settings_email` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_ratings` +-- +ALTER TABLE `settings_ratings` + ADD PRIMARY KEY (`id`), + ADD UNIQUE KEY `settings_ratings_slug_unique` (`slug`); + +-- +-- Indexes for table `settings_security` +-- +ALTER TABLE `settings_security` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_system` +-- +ALTER TABLE `settings_system` + ADD PRIMARY KEY (`id`), + ADD KEY `time_farmat` (`time_farmat`), + ADD KEY `date_format` (`date_format`), + ADD KEY `date_time_format` (`date_time_format`), + ADD KEY `time_zone` (`time_zone`); + +-- +-- Indexes for table `settings_ticket` +-- +ALTER TABLE `settings_ticket` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `sla_plan` +-- +ALTER TABLE `sla_plan` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `social_media` +-- +ALTER TABLE `social_media` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `teams` +-- +ALTER TABLE `teams` + ADD PRIMARY KEY (`id`), + ADD KEY `team_lead` (`team_lead`); + +-- +-- Indexes for table `team_assign_agent` +-- +ALTER TABLE `team_assign_agent` + ADD PRIMARY KEY (`id`), + ADD KEY `team_id` (`team_id`), + ADD KEY `agent_id` (`agent_id`); + +-- +-- Indexes for table `template` +-- +ALTER TABLE `template` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `templates` +-- +ALTER TABLE `templates` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `template_sets` +-- +ALTER TABLE `template_sets` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `template_types` +-- +ALTER TABLE `template_types` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `tickets` +-- +ALTER TABLE `tickets` + ADD PRIMARY KEY (`id`), + ADD KEY `user_id` (`user_id`), + ADD KEY `dept_id` (`dept_id`), + ADD KEY `team_id` (`team_id`), + ADD KEY `priority_id` (`priority_id`), + ADD KEY `sla` (`sla`), + ADD KEY `help_topic_id` (`help_topic_id`), + ADD KEY `status` (`status`), + ADD KEY `assigned_to` (`assigned_to`), + ADD KEY `source` (`source`); + +-- +-- Indexes for table `ticket_attachment` +-- +ALTER TABLE `ticket_attachment` + ADD PRIMARY KEY (`id`), + ADD KEY `thread_id` (`thread_id`); + +-- +-- Indexes for table `ticket_collaborator` +-- +ALTER TABLE `ticket_collaborator` + ADD PRIMARY KEY (`id`), + ADD KEY `ticket_id` (`ticket_id`), + ADD KEY `user_id` (`user_id`); + +-- +-- Indexes for table `ticket_form_data` +-- +ALTER TABLE `ticket_form_data` + ADD PRIMARY KEY (`id`), + ADD KEY `ticket_id` (`ticket_id`); + +-- +-- Indexes for table `ticket_priority` +-- +ALTER TABLE `ticket_priority` + ADD PRIMARY KEY (`priority_id`); + +-- +-- Indexes for table `ticket_source` +-- +ALTER TABLE `ticket_source` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `ticket_status` +-- +ALTER TABLE `ticket_status` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `ticket_thread` +-- +ALTER TABLE `ticket_thread` + ADD PRIMARY KEY (`id`), + ADD KEY `ticket_id_2` (`ticket_id`), + ADD KEY `user_id` (`user_id`), + ADD KEY `source` (`source`); + +-- +-- Indexes for table `ticket_token` +-- +ALTER TABLE `ticket_token` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `timezone` +-- +ALTER TABLE `timezone` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `time_format` +-- +ALTER TABLE `time_format` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `users` +-- +ALTER TABLE `users` + ADD PRIMARY KEY (`id`), + ADD UNIQUE KEY `users_email_unique` (`email`), + ADD UNIQUE KEY `users_mobile_unique` (`mobile`), + ADD KEY `assign_group_3` (`assign_group`), + ADD KEY `primary_dpt_2` (`primary_dpt`); + +-- +-- Indexes for table `user_additional_infos` +-- +ALTER TABLE `user_additional_infos` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `user_assign_organization` +-- +ALTER TABLE `user_assign_organization` + ADD PRIMARY KEY (`id`), + ADD KEY `org_id` (`org_id`), + ADD KEY `user_id` (`user_id`); + +-- +-- Indexes for table `user_notification` +-- +ALTER TABLE `user_notification` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `version_check` +-- +ALTER TABLE `version_check` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `widgets` +-- +ALTER TABLE `widgets` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `workflow_action` +-- +ALTER TABLE `workflow_action` + ADD PRIMARY KEY (`id`), + ADD KEY `workflow_action_1` (`workflow_id`); + +-- +-- Indexes for table `workflow_close` +-- +ALTER TABLE `workflow_close` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `workflow_name` +-- +ALTER TABLE `workflow_name` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `workflow_rules` +-- +ALTER TABLE `workflow_rules` + ADD PRIMARY KEY (`id`), + ADD KEY `workflow_rules_1` (`workflow_id`); + +-- +-- AUTO_INCREMENT for dumped tables +-- + +-- +-- AUTO_INCREMENT for table `api_settings` +-- +ALTER TABLE `api_settings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `banlist` +-- +ALTER TABLE `banlist` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `bar_notifications` +-- +ALTER TABLE `bar_notifications` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `canned_response` +-- +ALTER TABLE `canned_response` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `common_settings` +-- +ALTER TABLE `common_settings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `conditions` +-- +ALTER TABLE `conditions` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `country_code` +-- +ALTER TABLE `country_code` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=240; +-- +-- AUTO_INCREMENT for table `custom_forms` +-- +ALTER TABLE `custom_forms` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `custom_form_fields` +-- +ALTER TABLE `custom_form_fields` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `date_format` +-- +ALTER TABLE `date_format` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10; +-- +-- AUTO_INCREMENT for table `date_time_format` +-- +ALTER TABLE `date_time_format` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10; +-- +-- AUTO_INCREMENT for table `department` +-- +ALTER TABLE `department` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `emails` +-- +ALTER TABLE `emails` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `failed_jobs` +-- +ALTER TABLE `failed_jobs` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `faveo_mails` +-- +ALTER TABLE `faveo_mails` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `faveo_queues` +-- +ALTER TABLE `faveo_queues` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `field_values` +-- +ALTER TABLE `field_values` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `groups` +-- +ALTER TABLE `groups` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `group_assign_department` +-- +ALTER TABLE `group_assign_department` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `help_topic` +-- +ALTER TABLE `help_topic` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `jobs` +-- +ALTER TABLE `jobs` + MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `kb_article` +-- +ALTER TABLE `kb_article` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `kb_article_relationship` +-- +ALTER TABLE `kb_article_relationship` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `kb_category` +-- +ALTER TABLE `kb_category` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `kb_comment` +-- +ALTER TABLE `kb_comment` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `kb_pages` +-- +ALTER TABLE `kb_pages` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `kb_settings` +-- +ALTER TABLE `kb_settings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `languages` +-- +ALTER TABLE `languages` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10; +-- +-- AUTO_INCREMENT for table `login_attempts` +-- +ALTER TABLE `login_attempts` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `log_notification` +-- +ALTER TABLE `log_notification` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `mailbox_protocol` +-- +ALTER TABLE `mailbox_protocol` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5; +-- +-- AUTO_INCREMENT for table `mail_services` +-- +ALTER TABLE `mail_services` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7; +-- +-- AUTO_INCREMENT for table `notifications` +-- +ALTER TABLE `notifications` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `notification_types` +-- +ALTER TABLE `notification_types` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `organization` +-- +ALTER TABLE `organization` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `plugins` +-- +ALTER TABLE `plugins` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `queue_services` +-- +ALTER TABLE `queue_services` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7; +-- +-- AUTO_INCREMENT for table `ratings` +-- +ALTER TABLE `ratings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `rating_ref` +-- +ALTER TABLE `rating_ref` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `settings_alert_notice` +-- +ALTER TABLE `settings_alert_notice` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_auto_response` +-- +ALTER TABLE `settings_auto_response` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_company` +-- +ALTER TABLE `settings_company` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_email` +-- +ALTER TABLE `settings_email` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_ratings` +-- +ALTER TABLE `settings_ratings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `settings_security` +-- +ALTER TABLE `settings_security` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_system` +-- +ALTER TABLE `settings_system` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `settings_ticket` +-- +ALTER TABLE `settings_ticket` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `sla_plan` +-- +ALTER TABLE `sla_plan` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `social_media` +-- +ALTER TABLE `social_media` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `teams` +-- +ALTER TABLE `teams` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `team_assign_agent` +-- +ALTER TABLE `team_assign_agent` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `template` +-- +ALTER TABLE `template` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `templates` +-- +ALTER TABLE `templates` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15; +-- +-- AUTO_INCREMENT for table `template_sets` +-- +ALTER TABLE `template_sets` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `template_types` +-- +ALTER TABLE `template_types` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15; +-- +-- AUTO_INCREMENT for table `tickets` +-- +ALTER TABLE `tickets` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7; +-- +-- AUTO_INCREMENT for table `ticket_attachment` +-- +ALTER TABLE `ticket_attachment` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `ticket_collaborator` +-- +ALTER TABLE `ticket_collaborator` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `ticket_form_data` +-- +ALTER TABLE `ticket_form_data` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `ticket_priority` +-- +ALTER TABLE `ticket_priority` + MODIFY `priority_id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5; +-- +-- AUTO_INCREMENT for table `ticket_source` +-- +ALTER TABLE `ticket_source` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11; +-- +-- AUTO_INCREMENT for table `ticket_status` +-- +ALTER TABLE `ticket_status` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `ticket_thread` +-- +ALTER TABLE `ticket_thread` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=12; +-- +-- AUTO_INCREMENT for table `ticket_token` +-- +ALTER TABLE `ticket_token` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `timezone` +-- +ALTER TABLE `timezone` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=114; +-- +-- AUTO_INCREMENT for table `time_format` +-- +ALTER TABLE `time_format` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `users` +-- +ALTER TABLE `users` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=9; +-- +-- AUTO_INCREMENT for table `user_additional_infos` +-- +ALTER TABLE `user_additional_infos` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `user_assign_organization` +-- +ALTER TABLE `user_assign_organization` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `user_notification` +-- +ALTER TABLE `user_notification` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15; +-- +-- AUTO_INCREMENT for table `version_check` +-- +ALTER TABLE `version_check` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `widgets` +-- +ALTER TABLE `widgets` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=21; +-- +-- AUTO_INCREMENT for table `workflow_action` +-- +ALTER TABLE `workflow_action` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `workflow_close` +-- +ALTER TABLE `workflow_close` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `workflow_name` +-- +ALTER TABLE `workflow_name` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `workflow_rules` +-- +ALTER TABLE `workflow_rules` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; -- -- Constraints for dumped tables -- @@ -2491,16 +3267,16 @@ ALTER TABLE `canned_response` -- Constraints for table `department` -- ALTER TABLE `department` - ADD CONSTRAINT `department_ibfk_2` FOREIGN KEY (`manager`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `department_ibfk_1` FOREIGN KEY (`sla`) REFERENCES `sla_plan` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `department_ibfk_1` FOREIGN KEY (`sla`) REFERENCES `sla_plan` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `department_ibfk_2` FOREIGN KEY (`manager`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `emails` -- ALTER TABLE `emails` - ADD CONSTRAINT `emails_ibfk_3` FOREIGN KEY (`help_topic`) REFERENCES `help_topic` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `emails_ibfk_1` FOREIGN KEY (`department`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `emails_ibfk_2` FOREIGN KEY (`priority`) REFERENCES `ticket_priority` (`priority_id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `emails_ibfk_2` FOREIGN KEY (`priority`) REFERENCES `ticket_priority` (`priority_id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `emails_ibfk_3` FOREIGN KEY (`help_topic`) REFERENCES `help_topic` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `field_values` @@ -2512,26 +3288,26 @@ ALTER TABLE `field_values` -- Constraints for table `group_assign_department` -- ALTER TABLE `group_assign_department` - ADD CONSTRAINT `group_assign_department_ibfk_2` FOREIGN KEY (`department_id`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `group_assign_department_ibfk_1` FOREIGN KEY (`group_id`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `group_assign_department_ibfk_1` FOREIGN KEY (`group_id`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `group_assign_department_ibfk_2` FOREIGN KEY (`department_id`) REFERENCES `department` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `help_topic` -- ALTER TABLE `help_topic` - ADD CONSTRAINT `help_topic_ibfk_6` FOREIGN KEY (`auto_assign`) REFERENCES `users` (`id`) ON DELETE SET NULL, ADD CONSTRAINT `help_topic_ibfk_1` FOREIGN KEY (`custom_form`) REFERENCES `custom_forms` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `help_topic_ibfk_2` FOREIGN KEY (`department`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `help_topic_ibfk_3` FOREIGN KEY (`ticket_status`) REFERENCES `ticket_status` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `help_topic_ibfk_4` FOREIGN KEY (`priority`) REFERENCES `ticket_priority` (`priority_id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `help_topic_ibfk_5` FOREIGN KEY (`sla_plan`) REFERENCES `sla_plan` (`id`); + ADD CONSTRAINT `help_topic_ibfk_5` FOREIGN KEY (`sla_plan`) REFERENCES `sla_plan` (`id`), + ADD CONSTRAINT `help_topic_ibfk_6` FOREIGN KEY (`auto_assign`) REFERENCES `users` (`id`) ON DELETE SET NULL; -- -- Constraints for table `kb_article_relationship` -- ALTER TABLE `kb_article_relationship` - ADD CONSTRAINT `article_relationship_category_id_foreign` FOREIGN KEY (`category_id`) REFERENCES `kb_category` (`id`), - ADD CONSTRAINT `article_relationship_article_id_foreign` FOREIGN KEY (`article_id`) REFERENCES `kb_article` (`id`); + ADD CONSTRAINT `article_relationship_article_id_foreign` FOREIGN KEY (`article_id`) REFERENCES `kb_article` (`id`), + ADD CONSTRAINT `article_relationship_category_id_foreign` FOREIGN KEY (`category_id`) REFERENCES `kb_category` (`id`); -- -- Constraints for table `kb_comment` @@ -2549,10 +3325,10 @@ ALTER TABLE `organization` -- Constraints for table `settings_system` -- ALTER TABLE `settings_system` - ADD CONSTRAINT `settings_system_ibfk_4` FOREIGN KEY (`date_time_format`) REFERENCES `date_time_format` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `settings_system_ibfk_1` FOREIGN KEY (`time_zone`) REFERENCES `timezone` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `settings_system_ibfk_2` FOREIGN KEY (`time_farmat`) REFERENCES `time_format` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `settings_system_ibfk_3` FOREIGN KEY (`date_format`) REFERENCES `date_format` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `settings_system_ibfk_3` FOREIGN KEY (`date_format`) REFERENCES `date_format` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `settings_system_ibfk_4` FOREIGN KEY (`date_time_format`) REFERENCES `date_time_format` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `teams` @@ -2564,14 +3340,13 @@ ALTER TABLE `teams` -- Constraints for table `team_assign_agent` -- ALTER TABLE `team_assign_agent` - ADD CONSTRAINT `team_assign_agent_ibfk_2` FOREIGN KEY (`agent_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `team_assign_agent_ibfk_1` FOREIGN KEY (`team_id`) REFERENCES `teams` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `team_assign_agent_ibfk_1` FOREIGN KEY (`team_id`) REFERENCES `teams` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `team_assign_agent_ibfk_2` FOREIGN KEY (`agent_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `tickets` -- ALTER TABLE `tickets` - ADD CONSTRAINT `tickets_ibfk_9` FOREIGN KEY (`assigned_to`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_2` FOREIGN KEY (`dept_id`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_3` FOREIGN KEY (`team_id`) REFERENCES `teams` (`id`) ON UPDATE NO ACTION, @@ -2579,7 +3354,8 @@ ALTER TABLE `tickets` ADD CONSTRAINT `tickets_ibfk_5` FOREIGN KEY (`sla`) REFERENCES `sla_plan` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_6` FOREIGN KEY (`help_topic_id`) REFERENCES `help_topic` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_7` FOREIGN KEY (`status`) REFERENCES `ticket_status` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `tickets_ibfk_8` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `tickets_ibfk_8` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `tickets_ibfk_9` FOREIGN KEY (`assigned_to`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `ticket_attachment` @@ -2591,8 +3367,8 @@ ALTER TABLE `ticket_attachment` -- Constraints for table `ticket_collaborator` -- ALTER TABLE `ticket_collaborator` - ADD CONSTRAINT `ticket_collaborator_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `ticket_collaborator_ibfk_1` FOREIGN KEY (`ticket_id`) REFERENCES `tickets` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `ticket_collaborator_ibfk_1` FOREIGN KEY (`ticket_id`) REFERENCES `tickets` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `ticket_collaborator_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `ticket_form_data` @@ -2604,23 +3380,23 @@ ALTER TABLE `ticket_form_data` -- Constraints for table `ticket_thread` -- ALTER TABLE `ticket_thread` - ADD CONSTRAINT `ticket_thread_ibfk_3` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `ticket_thread_ibfk_1` FOREIGN KEY (`ticket_id`) REFERENCES `tickets` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `ticket_thread_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `ticket_thread_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `ticket_thread_ibfk_3` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `users` -- ALTER TABLE `users` - ADD CONSTRAINT `users_ibfk_2` FOREIGN KEY (`primary_dpt`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `users_ibfk_1` FOREIGN KEY (`assign_group`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `users_ibfk_1` FOREIGN KEY (`assign_group`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `users_ibfk_2` FOREIGN KEY (`primary_dpt`) REFERENCES `department` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `user_assign_organization` -- ALTER TABLE `user_assign_organization` - ADD CONSTRAINT `user_assign_organization_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `user_assign_organization_ibfk_1` FOREIGN KEY (`org_id`) REFERENCES `organization` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `user_assign_organization_ibfk_1` FOREIGN KEY (`org_id`) REFERENCES `organization` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `user_assign_organization_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `workflow_action` diff --git a/DB/dummy-data.sql b/DB/dummy-data.sql index b447c289f..45b42a788 100644 --- a/DB/dummy-data.sql +++ b/DB/dummy-data.sql @@ -1,11 +1,11 @@ -- phpMyAdmin SQL Dump --- version 4.1.14 --- http://www.phpmyadmin.net +-- version 4.6.4 +-- https://www.phpmyadmin.net/ -- -- Host: 127.0.0.1 --- Generation Time: Dec 13, 2016 at 10:36 AM --- Server version: 5.6.17 --- PHP Version: 5.5.12 +-- Generation Time: Jan 03, 2017 at 06:22 AM +-- Server version: 5.7.14 +-- PHP Version: 5.6.25 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; @@ -14,10 +14,10 @@ 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 utf8 */; +/*!40101 SET NAMES utf8mb4 */; -- --- Database: `community` +-- Database: `final` -- -- -------------------------------------------------------- @@ -26,14 +26,13 @@ SET time_zone = "+00:00"; -- Table structure for table `api_settings` -- -CREATE TABLE IF NOT EXISTS `api_settings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `api_settings` ( + `id` int(10) UNSIGNED NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -41,15 +40,14 @@ CREATE TABLE IF NOT EXISTS `api_settings` ( -- Table structure for table `banlist` -- -CREATE TABLE IF NOT EXISTS `banlist` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `banlist` ( + `id` int(10) UNSIGNED NOT NULL, `ban_status` tinyint(1) NOT NULL, `email_address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -57,14 +55,13 @@ CREATE TABLE IF NOT EXISTS `banlist` ( -- Table structure for table `bar_notifications` -- -CREATE TABLE IF NOT EXISTS `bar_notifications` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `bar_notifications` ( + `id` int(10) UNSIGNED NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `bar_notifications` @@ -79,16 +76,14 @@ INSERT INTO `bar_notifications` (`id`, `key`, `value`, `created_at`, `updated_at -- Table structure for table `canned_response` -- -CREATE TABLE IF NOT EXISTS `canned_response` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `user_id` int(10) unsigned NOT NULL, +CREATE TABLE `canned_response` ( + `id` int(10) UNSIGNED NOT NULL, + `user_id` int(10) UNSIGNED NOT NULL, `title` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `message` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `user_id` (`user_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -96,16 +91,15 @@ CREATE TABLE IF NOT EXISTS `canned_response` ( -- Table structure for table `common_settings` -- -CREATE TABLE IF NOT EXISTS `common_settings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `common_settings` ( + `id` int(10) UNSIGNED NOT NULL, `option_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `option_value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `optional_field` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `common_settings` @@ -126,14 +120,13 @@ INSERT INTO `common_settings` (`id`, `option_name`, `option_value`, `status`, `o -- Table structure for table `conditions` -- -CREATE TABLE IF NOT EXISTS `conditions` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `conditions` ( + `id` int(10) UNSIGNED NOT NULL, `job` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -141,8 +134,8 @@ CREATE TABLE IF NOT EXISTS `conditions` ( -- Table structure for table `country_code` -- -CREATE TABLE IF NOT EXISTS `country_code` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `country_code` ( + `id` int(10) UNSIGNED NOT NULL, `iso` char(2) COLLATE utf8_unicode_ci NOT NULL, `name` varchar(100) COLLATE utf8_unicode_ci NOT NULL, `nicename` varchar(100) COLLATE utf8_unicode_ci NOT NULL, @@ -150,9 +143,8 @@ CREATE TABLE IF NOT EXISTS `country_code` ( `numcode` smallint(6) NOT NULL, `phonecode` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=240 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `country_code` @@ -405,13 +397,12 @@ INSERT INTO `country_code` (`id`, `iso`, `name`, `nicename`, `iso3`, `numcode`, -- Table structure for table `custom_forms` -- -CREATE TABLE IF NOT EXISTS `custom_forms` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `custom_forms` ( + `id` int(10) UNSIGNED NOT NULL, `formname` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -419,8 +410,8 @@ CREATE TABLE IF NOT EXISTS `custom_forms` ( -- Table structure for table `custom_form_fields` -- -CREATE TABLE IF NOT EXISTS `custom_form_fields` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `custom_form_fields` ( + `id` int(10) UNSIGNED NOT NULL, `forms_id` int(11) NOT NULL, `label` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -428,9 +419,8 @@ CREATE TABLE IF NOT EXISTS `custom_form_fields` ( `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `required` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -438,11 +428,10 @@ CREATE TABLE IF NOT EXISTS `custom_form_fields` ( -- Table structure for table `date_format` -- -CREATE TABLE IF NOT EXISTS `date_format` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=10 ; +CREATE TABLE `date_format` ( + `id` int(10) UNSIGNED NOT NULL, + `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `date_format` @@ -465,11 +454,10 @@ INSERT INTO `date_format` (`id`, `format`) VALUES -- Table structure for table `date_time_format` -- -CREATE TABLE IF NOT EXISTS `date_time_format` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=10 ; +CREATE TABLE `date_time_format` ( + `id` int(10) UNSIGNED NOT NULL, + `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `date_time_format` @@ -492,12 +480,12 @@ INSERT INTO `date_time_format` (`id`, `format`) VALUES -- Table structure for table `department` -- -CREATE TABLE IF NOT EXISTS `department` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `department` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `sla` int(10) unsigned DEFAULT NULL, - `manager` int(10) unsigned DEFAULT NULL, + `sla` int(10) UNSIGNED DEFAULT NULL, + `manager` int(10) UNSIGNED DEFAULT NULL, `ticket_assignment` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `outgoing_email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `template_set` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -508,11 +496,8 @@ CREATE TABLE IF NOT EXISTS `department` ( `group_access` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `department_sign` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `sla` (`sla`), - KEY `manager_2` (`manager`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `department` @@ -529,13 +514,13 @@ INSERT INTO `department` (`id`, `name`, `type`, `sla`, `manager`, `ticket_assign -- Table structure for table `emails` -- -CREATE TABLE IF NOT EXISTS `emails` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `emails` ( + `id` int(10) UNSIGNED NOT NULL, `email_address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `email_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `department` int(10) unsigned DEFAULT NULL, - `priority` int(10) unsigned DEFAULT NULL, - `help_topic` int(10) unsigned DEFAULT NULL, + `department` int(10) UNSIGNED DEFAULT NULL, + `priority` int(10) UNSIGNED DEFAULT NULL, + `help_topic` int(10) UNSIGNED DEFAULT NULL, `user_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `password` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `fetching_host` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -561,13 +546,8 @@ CREATE TABLE IF NOT EXISTS `emails` ( `authentication` tinyint(1) NOT NULL, `header_spoofing` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `department` (`department`,`priority`,`help_topic`), - KEY `department_2` (`department`,`priority`,`help_topic`), - KEY `priority` (`priority`), - KEY `help_topic` (`help_topic`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -575,14 +555,13 @@ CREATE TABLE IF NOT EXISTS `emails` ( -- Table structure for table `failed_jobs` -- -CREATE TABLE IF NOT EXISTS `failed_jobs` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `failed_jobs` ( + `id` int(10) UNSIGNED NOT NULL, `connection` text COLLATE utf8_unicode_ci NOT NULL, `queue` text COLLATE utf8_unicode_ci NOT NULL, `payload` longtext COLLATE utf8_unicode_ci NOT NULL, - `failed_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `failed_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -590,16 +569,15 @@ CREATE TABLE IF NOT EXISTS `failed_jobs` ( -- Table structure for table `faveo_mails` -- -CREATE TABLE IF NOT EXISTS `faveo_mails` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `faveo_mails` ( + `id` int(10) UNSIGNED NOT NULL, `email_id` int(11) NOT NULL, `drive` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -607,15 +585,14 @@ CREATE TABLE IF NOT EXISTS `faveo_mails` ( -- Table structure for table `faveo_queues` -- -CREATE TABLE IF NOT EXISTS `faveo_queues` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `faveo_queues` ( + `id` int(10) UNSIGNED NOT NULL, `service_id` int(11) NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -623,17 +600,15 @@ CREATE TABLE IF NOT EXISTS `faveo_queues` ( -- Table structure for table `field_values` -- -CREATE TABLE IF NOT EXISTS `field_values` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `field_id` int(10) unsigned DEFAULT NULL, - `child_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `field_values` ( + `id` int(10) UNSIGNED NOT NULL, + `field_id` int(10) UNSIGNED DEFAULT NULL, + `child_id` int(10) UNSIGNED DEFAULT NULL, `field_key` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `field_value` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `field_values_field_id_foreign` (`field_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -641,8 +616,8 @@ CREATE TABLE IF NOT EXISTS `field_values` ( -- Table structure for table `groups` -- -CREATE TABLE IF NOT EXISTS `groups` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `groups` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `group_status` tinyint(1) NOT NULL, `can_create_ticket` tinyint(1) NOT NULL, @@ -659,9 +634,8 @@ CREATE TABLE IF NOT EXISTS `groups` ( `department_access` tinyint(1) NOT NULL, `admin_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `groups` @@ -678,16 +652,13 @@ INSERT INTO `groups` (`id`, `name`, `group_status`, `can_create_ticket`, `can_ed -- Table structure for table `group_assign_department` -- -CREATE TABLE IF NOT EXISTS `group_assign_department` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `group_id` int(10) unsigned NOT NULL, - `department_id` int(10) unsigned NOT NULL, +CREATE TABLE `group_assign_department` ( + `id` int(10) UNSIGNED NOT NULL, + `group_id` int(10) UNSIGNED NOT NULL, + `department_id` int(10) UNSIGNED NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `group_id` (`group_id`), - KEY `department_id` (`department_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -695,32 +666,25 @@ CREATE TABLE IF NOT EXISTS `group_assign_department` ( -- Table structure for table `help_topic` -- -CREATE TABLE IF NOT EXISTS `help_topic` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `help_topic` ( + `id` int(10) UNSIGNED NOT NULL, `topic` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `parent_topic` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `custom_form` int(10) unsigned DEFAULT NULL, - `department` int(10) unsigned DEFAULT NULL, - `ticket_status` int(10) unsigned DEFAULT NULL, - `priority` int(10) unsigned DEFAULT NULL, - `sla_plan` int(10) unsigned DEFAULT NULL, + `custom_form` int(10) UNSIGNED DEFAULT NULL, + `department` int(10) UNSIGNED DEFAULT NULL, + `ticket_status` int(10) UNSIGNED DEFAULT NULL, + `priority` int(10) UNSIGNED DEFAULT NULL, + `sla_plan` int(10) UNSIGNED DEFAULT NULL, `thank_page` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `ticket_num_format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `type` tinyint(1) NOT NULL, - `auto_assign` int(10) unsigned DEFAULT NULL, + `auto_assign` int(10) UNSIGNED DEFAULT NULL, `auto_response` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `custom_form` (`custom_form`), - KEY `department` (`department`), - KEY `ticket_status` (`ticket_status`), - KEY `priority` (`priority`), - KEY `sla_plan` (`sla_plan`), - KEY `auto_assign_2` (`auto_assign`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `help_topic` @@ -737,18 +701,16 @@ INSERT INTO `help_topic` (`id`, `topic`, `parent_topic`, `custom_form`, `departm -- Table structure for table `jobs` -- -CREATE TABLE IF NOT EXISTS `jobs` ( - `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `jobs` ( + `id` bigint(20) UNSIGNED NOT NULL, `queue` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `payload` longtext COLLATE utf8_unicode_ci NOT NULL, - `attempts` tinyint(3) unsigned NOT NULL, - `reserved` tinyint(3) unsigned NOT NULL, - `reserved_at` int(10) unsigned DEFAULT NULL, - `available_at` int(10) unsigned NOT NULL, - `created_at` int(10) unsigned NOT NULL, - PRIMARY KEY (`id`), - KEY `jobs_queue_reserved_reserved_at_index` (`queue`,`reserved`,`reserved_at`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `attempts` tinyint(3) UNSIGNED NOT NULL, + `reserved` tinyint(3) UNSIGNED NOT NULL, + `reserved_at` int(10) UNSIGNED DEFAULT NULL, + `available_at` int(10) UNSIGNED NOT NULL, + `created_at` int(10) UNSIGNED NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -756,8 +718,8 @@ CREATE TABLE IF NOT EXISTS `jobs` ( -- Table structure for table `kb_article` -- -CREATE TABLE IF NOT EXISTS `kb_article` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_article` ( + `id` int(10) UNSIGNED NOT NULL, `name` text COLLATE utf8_unicode_ci NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `description` text COLLATE utf8_unicode_ci NOT NULL, @@ -765,9 +727,8 @@ CREATE TABLE IF NOT EXISTS `kb_article` ( `type` tinyint(1) NOT NULL, `publish_time` datetime DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_article` @@ -776,7 +737,7 @@ CREATE TABLE IF NOT EXISTS `kb_article` ( INSERT INTO `kb_article` (`id`, `name`, `slug`, `description`, `status`, `type`, `publish_time`, `created_at`, `updated_at`) VALUES (1, 'DISCLAIMERS', 'disclaimers', '

ABC clothing.com does not promise that the site will be inoffensive, error-free or uninterrupted, or that it will provide specific information from use of the site or any content, search, or link on it. The site and its content are delivered on an “as-is” and “as-available” basis. ABC clothing.com cannot ensure that files you download from the site will be free of viruses or contamination or destructive features.

\r\n\r\n

Thebclothing.com disclaims all warranties, express or implied, including any implied warranties of merchantability and fitness for a particular purpose. ABC clothing.com will not be liable for any damages of any kind arising from the use of this site, including, without limitation, direct, indirect, incidental, and punitive and consequential damages.

\r\n\r\n

ABC clothing.com disclaims any and all liability for the acts, omissions, and conduct of any third-party users, ABC clothing.com users, advertisers, and/or sponsors on the Site, in connection with the Site, or other-wise related to your use of the Site. ABC clothing.com is not responsible for the products, services, actions, or failure to act of any third party in connection with or referenced on the Site. Without limiting the fore-going, you may report the misconduct of users and/or third-party advertisers or service and/or product providers referenced on or included in the Site to ABC clothing.com at Support@abcclothing.com

\r\n\r\n

ABC clothing.com may investigate the claim and take appropriate action, at its sole discretion.

\r\n\r\n

For any query kindly drop mail us on  Support@abcclothing.com.

\r\n', 1, 1, '2016-12-13 08:54:00', '2016-12-13 03:25:28', '2016-12-13 03:25:28'), (2, 'CUSTOM ORDER', 'custom-order', '

You saw, you liked but couldn’t see your size? We will custom make it for you.

\r\n\r\n

How it works:

\r\n\r\n
  1. You liked something and want to modify a little or have something else on mind, do pen it down and share it with us on Support@abcclothing.com
  2. \r\n
  3. We’ll work out the price depending on how detailed or intricate you want your garment.
  4. \r\n
  5. An advance would be required for any customized orders.
  6. \r\n
  7. Once you’ve placed a deposit, we’ll make you a sketch of the garment.
  8. \r\n
  9. We can complete your order in 15-20 days depending on the workload.
  10. \r\n
  11. We will also share some updates on the garment in case something needs to be changed.
  12. \r\n
  13. We finally ship it to your given address.
  14. \r\n

Note: No returns and refunds.

\r\n', 1, 1, '2016-12-13 08:56:00', '2016-12-13 03:26:24', '2016-12-13 03:26:24'), -(3, 'TROUSER SKIRTS', 'trouser-skirts', '

Paris takes its fashion very, very seriously. So seriously, in fact, that wearing the wrong thing has actually caused a riot.

\r\n\r\n

In 1911, two rival Parisian couture houses launched their "trouser skirts," an innovation in fashion that trod the very fixed line between the genders and seemed to promise greater flexibility for women in general. There were two different versions of the trouser skirt: One was a sort of baggy pant with a very low hanging crotch, described as "a sack with holes made for the legs to go through," not unlike the fashions on high streets today, and the other a pair of the same kind of pants topped with an over-skirt, again, not unlike high street fashions of today. Both versions were launched by models at the opening day of racing season to general revulsion and disgust, but thankfully, no violence.

\r\n\r\n

It wasn''t until the ladies attempted to promenade their future fashions on the boulevards that the fisticuffs started—at the Place de l''Opera, the poor models were attacked by a jeering mob of fashion Philistines, who pulled their hair, trampled their hats, and reduced them to tears. A squad of police officers on bicycles were dispatched to rescue the girls and escort them to safety.

\r\n', 1, 1, '2016-12-13 08:56:00', '2016-12-13 03:27:02', '2016-12-13 03:27:02'), +(3, 'TROUSER SKIRTS', 'trouser-skirts', '

Paris takes its fashion very, very seriously. So seriously, in fact, that wearing the wrong thing has actually caused a riot.

\r\n\r\n

In 1911, two rival Parisian couture houses launched their "trouser skirts," an innovation in fashion that trod the very fixed line between the genders and seemed to promise greater flexibility for women in general. There were two different versions of the trouser skirt: One was a sort of baggy pant with a very low hanging crotch, described as "a sack with holes made for the legs to go through," not unlike the fashions on high streets today, and the other a pair of the same kind of pants topped with an over-skirt, again, not unlike high street fashions of today. Both versions were launched by models at the opening day of racing season to general revulsion and disgust, but thankfully, no violence.

\r\n\r\n

It wasn\'t until the ladies attempted to promenade their future fashions on the boulevards that the fisticuffs started—at the Place de l\'Opera, the poor models were attacked by a jeering mob of fashion Philistines, who pulled their hair, trampled their hats, and reduced them to tears. A squad of police officers on bicycles were dispatched to rescue the girls and escort them to safety.

\r\n', 1, 1, '2016-12-13 08:56:00', '2016-12-13 03:27:02', '2016-12-13 03:27:02'), (4, 'SECURE SHOPPING GUARANTEE', 'secure-shopping-guarantee', '

We accept all major Indian and International Credit/ Debit Cards, and Net Banking with over 40 Banks.

\r\n\r\n

NO Cash on Delivery (as random people order and share false addresses for fun)

\r\n\r\n

Yes, shopping at our e-store is 100% safe. All payment requests are directed to the secured PayU Payment Gateway. This gives you the highest level of protection possible whenever you use credit cards or make other financial or confidential transactions over the Internet.

\r\n\r\n

You can be assured that our e-store offers you the highest standards of security currently available on the net so as to ensure that your shopping experience is private, safe and secure.

\r\n', 1, 1, '2016-12-13 08:57:00', '2016-12-13 03:27:42', '2016-12-13 03:27:42'), (5, 'PRIVACY POLICY', 'privacy-policy', '

The ABC Clothing collects your basic information to service your requests. This basic information is gathered when you purchase products/Gift card vouchers or when you sign up for e-mail notifications. Information gathered from you includes your name, mailing address, e-mail and phone number. Only when you place an order, your card information is requested and is submitted via the highest level of encryption to make sure of the greatest amount of safety and security. Reason why we gather this information:

\r\n\r\n

To process your order.
\r\nShipping and Customer Service.
\r\nWe also use the information to upgrade our products, customer services, website content and navigation.

\r\n\r\n


Internal Record Keeping.
\r\nWe at The ABC Clothing respect that you do not want your personal information shared with other companies. The information you provide shall, therefore, be only used to process your order and customer support. The ABC Clothing does not share, sell or rent customer information to any other company.

\r\n', 1, 1, '2016-12-13 08:58:00', '2016-12-13 03:28:31', '2016-12-13 03:28:31'), (6, ' SHIPPING POLICY', 'shipping-policy', '

We ship worldwide. We use FedEx/DTDC for shipping.

\r\n\r\n

Standard Shipping is usually 3-7 Working days for orders within India and 12-15 Working days for International Orders, but usually faster. IF your order doesn’t reach you in time, you may write to us at support@abcclothing.com

\r\n\r\n

International Orders

\r\n\r\n

For international orders, please note, your shipping will be calculated at the time of Check out only, this is a System Generated amount, based on your Zip Code, Region and Order Weight. (Approx Costs Rs.1250-1500 for 500 gms – International Shipment, subject to region)

\r\n\r\n

Tracking

\r\n\r\n

For tracking your order go to the following website, it will require your tracking ID which is sent via mail in your invoice.

\r\n', 1, 1, '2016-12-13 08:58:00', '2016-12-13 03:29:34', '2016-12-13 03:29:34'), @@ -788,16 +749,13 @@ INSERT INTO `kb_article` (`id`, `name`, `slug`, `description`, `status`, `type`, -- Table structure for table `kb_article_relationship` -- -CREATE TABLE IF NOT EXISTS `kb_article_relationship` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `article_id` int(10) unsigned NOT NULL, - `category_id` int(10) unsigned NOT NULL, +CREATE TABLE `kb_article_relationship` ( + `id` int(10) UNSIGNED NOT NULL, + `article_id` int(10) UNSIGNED NOT NULL, + `category_id` int(10) UNSIGNED NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `article_relationship_article_id_foreign` (`article_id`), - KEY `article_relationship_category_id_foreign` (`category_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_article_relationship` @@ -818,17 +776,16 @@ INSERT INTO `kb_article_relationship` (`id`, `article_id`, `category_id`, `creat -- Table structure for table `kb_category` -- -CREATE TABLE IF NOT EXISTS `kb_category` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_category` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `description` text COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `parent` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_category` @@ -844,19 +801,17 @@ INSERT INTO `kb_category` (`id`, `name`, `slug`, `description`, `status`, `paren -- Table structure for table `kb_comment` -- -CREATE TABLE IF NOT EXISTS `kb_comment` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `article_id` int(10) unsigned NOT NULL, +CREATE TABLE `kb_comment` ( + `id` int(10) UNSIGNED NOT NULL, + `article_id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `website` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `comment` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `comment_article_id_foreign` (`article_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -864,17 +819,16 @@ CREATE TABLE IF NOT EXISTS `kb_comment` ( -- Table structure for table `kb_pages` -- -CREATE TABLE IF NOT EXISTS `kb_pages` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_pages` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `visibility` tinyint(1) NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `description` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -882,13 +836,12 @@ CREATE TABLE IF NOT EXISTS `kb_pages` ( -- Table structure for table `kb_settings` -- -CREATE TABLE IF NOT EXISTS `kb_settings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `kb_settings` ( + `id` int(10) UNSIGNED NOT NULL, `pagination` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `kb_settings` @@ -903,12 +856,11 @@ INSERT INTO `kb_settings` (`id`, `pagination`, `created_at`, `updated_at`) VALUE -- Table structure for table `languages` -- -CREATE TABLE IF NOT EXISTS `languages` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `languages` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `locale` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=10 ; + `locale` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `languages` @@ -931,16 +883,15 @@ INSERT INTO `languages` (`id`, `name`, `locale`) VALUES -- Table structure for table `login_attempts` -- -CREATE TABLE IF NOT EXISTS `login_attempts` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `login_attempts` ( + `id` int(10) UNSIGNED NOT NULL, `User` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `IP` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `Attempts` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `LastLogin` datetime NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `login_attempts` @@ -955,13 +906,12 @@ INSERT INTO `login_attempts` (`id`, `User`, `IP`, `Attempts`, `LastLogin`, `crea -- Table structure for table `log_notification` -- -CREATE TABLE IF NOT EXISTS `log_notification` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `log_notification` ( + `id` int(10) UNSIGNED NOT NULL, `log` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `log_notification` @@ -976,12 +926,11 @@ INSERT INTO `log_notification` (`id`, `log`, `created_at`, `updated_at`) VALUES -- Table structure for table `mailbox_protocol` -- -CREATE TABLE IF NOT EXISTS `mailbox_protocol` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `mailbox_protocol` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `value` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=5 ; + `value` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `mailbox_protocol` @@ -999,14 +948,13 @@ INSERT INTO `mailbox_protocol` (`id`, `name`, `value`) VALUES -- Table structure for table `mail_services` -- -CREATE TABLE IF NOT EXISTS `mail_services` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `mail_services` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `short_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=7 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `mail_services` @@ -1026,7 +974,7 @@ INSERT INTO `mail_services` (`id`, `name`, `short_name`, `created_at`, `updated_ -- Table structure for table `migrations` -- -CREATE TABLE IF NOT EXISTS `migrations` ( +CREATE TABLE `migrations` ( `migration` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `batch` int(11) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; @@ -1141,15 +1089,14 @@ INSERT INTO `migrations` (`migration`, `batch`) VALUES -- Table structure for table `notifications` -- -CREATE TABLE IF NOT EXISTS `notifications` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `notifications` ( + `id` int(10) UNSIGNED NOT NULL, `model_id` int(11) NOT NULL, `userid_created` int(11) NOT NULL, `type_id` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `notifications` @@ -1170,15 +1117,14 @@ INSERT INTO `notifications` (`id`, `model_id`, `userid_created`, `type_id`, `cre -- Table structure for table `notification_types` -- -CREATE TABLE IF NOT EXISTS `notification_types` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `notification_types` ( + `id` int(10) UNSIGNED NOT NULL, `message` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `icon_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `notification_types` @@ -1195,19 +1141,17 @@ INSERT INTO `notification_types` (`id`, `message`, `type`, `icon_class`, `create -- Table structure for table `organization` -- -CREATE TABLE IF NOT EXISTS `organization` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `organization` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `phone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `website` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `head` int(10) unsigned DEFAULT NULL, + `head` int(10) UNSIGNED DEFAULT NULL, `internal_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `head` (`head`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1215,12 +1159,10 @@ CREATE TABLE IF NOT EXISTS `organization` ( -- Table structure for table `password_resets` -- -CREATE TABLE IF NOT EXISTS `password_resets` ( +CREATE TABLE `password_resets` ( `email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `token` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `created_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', - KEY `password_resets_email_index` (`email`), - KEY `password_resets_token_index` (`token`) + `created_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00' ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1229,15 +1171,14 @@ CREATE TABLE IF NOT EXISTS `password_resets` ( -- Table structure for table `plugins` -- -CREATE TABLE IF NOT EXISTS `plugins` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `plugins` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `path` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1245,15 +1186,14 @@ CREATE TABLE IF NOT EXISTS `plugins` ( -- Table structure for table `queue_services` -- -CREATE TABLE IF NOT EXISTS `queue_services` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `queue_services` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `short_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=7 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `queue_services` @@ -1273,8 +1213,8 @@ INSERT INTO `queue_services` (`id`, `name`, `short_name`, `status`, `created_at` -- Table structure for table `ratings` -- -CREATE TABLE IF NOT EXISTS `ratings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ratings` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `display_order` int(11) NOT NULL, `allow_modification` int(11) NOT NULL, @@ -1282,9 +1222,8 @@ CREATE TABLE IF NOT EXISTS `ratings` ( `rating_area` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `restrict` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ratings` @@ -1300,16 +1239,15 @@ INSERT INTO `ratings` (`id`, `name`, `display_order`, `allow_modification`, `rat -- Table structure for table `rating_ref` -- -CREATE TABLE IF NOT EXISTS `rating_ref` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `rating_ref` ( + `id` int(10) UNSIGNED NOT NULL, `rating_id` int(11) NOT NULL, `ticket_id` int(11) NOT NULL, `thread_id` int(11) NOT NULL, `rating_value` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1317,8 +1255,8 @@ CREATE TABLE IF NOT EXISTS `rating_ref` ( -- Table structure for table `settings_alert_notice` -- -CREATE TABLE IF NOT EXISTS `settings_alert_notice` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_alert_notice` ( + `id` int(10) UNSIGNED NOT NULL, `ticket_status` tinyint(1) NOT NULL, `ticket_admin_email` tinyint(1) NOT NULL, `ticket_department_manager` tinyint(1) NOT NULL, @@ -1349,9 +1287,8 @@ CREATE TABLE IF NOT EXISTS `settings_alert_notice` ( `sql_error` tinyint(1) NOT NULL, `excessive_failure` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_alert_notice` @@ -1366,17 +1303,16 @@ INSERT INTO `settings_alert_notice` (`id`, `ticket_status`, `ticket_admin_email` -- Table structure for table `settings_auto_response` -- -CREATE TABLE IF NOT EXISTS `settings_auto_response` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_auto_response` ( + `id` int(10) UNSIGNED NOT NULL, `new_ticket` tinyint(1) NOT NULL, `agent_new_ticket` tinyint(1) NOT NULL, `submitter` tinyint(1) NOT NULL, `participants` tinyint(1) NOT NULL, `overlimit` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_auto_response` @@ -1391,8 +1327,8 @@ INSERT INTO `settings_auto_response` (`id`, `new_ticket`, `agent_new_ticket`, `s -- Table structure for table `settings_company` -- -CREATE TABLE IF NOT EXISTS `settings_company` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_company` ( + `id` int(10) UNSIGNED NOT NULL, `company_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `website` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `phone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1403,9 +1339,8 @@ CREATE TABLE IF NOT EXISTS `settings_company` ( `logo` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `use_logo` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_company` @@ -1420,8 +1355,8 @@ INSERT INTO `settings_company` (`id`, `company_name`, `website`, `phone`, `addre -- Table structure for table `settings_email` -- -CREATE TABLE IF NOT EXISTS `settings_email` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_email` ( + `id` int(10) UNSIGNED NOT NULL, `template` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `sys_email` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `alert_email` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1435,9 +1370,8 @@ CREATE TABLE IF NOT EXISTS `settings_email` ( `email_collaborator` tinyint(1) NOT NULL, `attachment` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_email` @@ -1452,17 +1386,15 @@ INSERT INTO `settings_email` (`id`, `template`, `sys_email`, `alert_email`, `adm -- Table structure for table `settings_ratings` -- -CREATE TABLE IF NOT EXISTS `settings_ratings` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_ratings` ( + `id` int(10) UNSIGNED NOT NULL, `rating_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `publish` int(11) NOT NULL, `modify` int(11) NOT NULL, `slug` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - UNIQUE KEY `settings_ratings_slug_unique` (`slug`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1470,17 +1402,16 @@ CREATE TABLE IF NOT EXISTS `settings_ratings` ( -- Table structure for table `settings_security` -- -CREATE TABLE IF NOT EXISTS `settings_security` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_security` ( + `id` int(10) UNSIGNED NOT NULL, `lockout_message` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `backlist_offender` int(11) NOT NULL, `backlist_threshold` int(11) NOT NULL, `lockout_period` int(11) NOT NULL, `days_to_keep_logs` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_security` @@ -1495,8 +1426,8 @@ INSERT INTO `settings_security` (`id`, `lockout_message`, `backlist_offender`, ` -- Table structure for table `settings_system` -- -CREATE TABLE IF NOT EXISTS `settings_system` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_system` ( + `id` int(10) UNSIGNED NOT NULL, `status` tinyint(1) NOT NULL, `url` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1508,21 +1439,16 @@ CREATE TABLE IF NOT EXISTS `settings_system` ( `api_key_mandatory` int(11) NOT NULL, `api_key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `name_format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `time_farmat` int(10) unsigned DEFAULT NULL, - `date_format` int(10) unsigned DEFAULT NULL, - `date_time_format` int(10) unsigned DEFAULT NULL, + `time_farmat` int(10) UNSIGNED DEFAULT NULL, + `date_format` int(10) UNSIGNED DEFAULT NULL, + `date_time_format` int(10) UNSIGNED DEFAULT NULL, `day_date_time` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `time_zone` int(10) unsigned DEFAULT NULL, + `time_zone` int(10) UNSIGNED DEFAULT NULL, `content` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `version` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `time_farmat` (`time_farmat`), - KEY `date_format` (`date_format`), - KEY `date_time_format` (`date_time_format`), - KEY `time_zone` (`time_zone`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_system` @@ -1530,7 +1456,8 @@ CREATE TABLE IF NOT EXISTS `settings_system` ( INSERT INTO `settings_system` (`id`, `status`, `url`, `name`, `department`, `page_size`, `log_level`, `purge_log`, `api_enable`, `api_key_mandatory`, `api_key`, `name_format`, `time_farmat`, `date_format`, `date_time_format`, `day_date_time`, `time_zone`, `content`, `version`, `created_at`, `updated_at`) VALUES (1, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 32, '', '', '2016-12-13 03:19:29', '2016-12-13 03:19:29'), -(2, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 79, '', '1.0.8.0', '2016-12-13 03:19:53', '2016-12-13 03:19:53'); +(2, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 79, '', '1.0.8.0', '2016-12-13 03:19:53', '2016-12-13 03:19:53'), +(3, 1, '', '', '1', '', '', '', 0, 0, '', '', NULL, NULL, 1, '', 14, '', '1.9.2', '2017-01-03 06:17:47', '2017-01-03 06:17:47'); -- -------------------------------------------------------- @@ -1538,8 +1465,8 @@ INSERT INTO `settings_system` (`id`, `status`, `url`, `name`, `department`, `pag -- Table structure for table `settings_ticket` -- -CREATE TABLE IF NOT EXISTS `settings_ticket` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `settings_ticket` ( + `id` int(10) UNSIGNED NOT NULL, `num_format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `num_sequence` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `priority` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1558,9 +1485,8 @@ CREATE TABLE IF NOT EXISTS `settings_ticket` ( `client_update` tinyint(1) NOT NULL, `max_file_size` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `settings_ticket` @@ -1575,8 +1501,8 @@ INSERT INTO `settings_ticket` (`id`, `num_format`, `num_sequence`, `priority`, ` -- Table structure for table `sla_plan` -- -CREATE TABLE IF NOT EXISTS `sla_plan` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `sla_plan` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `grace_period` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `admin_note` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1584,9 +1510,8 @@ CREATE TABLE IF NOT EXISTS `sla_plan` ( `transient` tinyint(1) NOT NULL, `ticket_overdue` tinyint(1) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `sla_plan` @@ -1603,15 +1528,14 @@ INSERT INTO `sla_plan` (`id`, `name`, `grace_period`, `admin_note`, `status`, `t -- Table structure for table `social_media` -- -CREATE TABLE IF NOT EXISTS `social_media` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `social_media` ( + `id` int(10) UNSIGNED NOT NULL, `provider` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1619,18 +1543,16 @@ CREATE TABLE IF NOT EXISTS `social_media` ( -- Table structure for table `teams` -- -CREATE TABLE IF NOT EXISTS `teams` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `teams` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, - `team_lead` int(10) unsigned DEFAULT NULL, + `team_lead` int(10) UNSIGNED DEFAULT NULL, `assign_alert` tinyint(1) NOT NULL, `admin_notes` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `team_lead` (`team_lead`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=4 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `teams` @@ -1647,16 +1569,13 @@ INSERT INTO `teams` (`id`, `name`, `status`, `team_lead`, `assign_alert`, `admin -- Table structure for table `team_assign_agent` -- -CREATE TABLE IF NOT EXISTS `team_assign_agent` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `team_id` int(10) unsigned DEFAULT NULL, - `agent_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `team_assign_agent` ( + `id` int(10) UNSIGNED NOT NULL, + `team_id` int(10) UNSIGNED DEFAULT NULL, + `agent_id` int(10) UNSIGNED DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `team_id` (`team_id`), - KEY `agent_id` (`agent_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `team_assign_agent` @@ -1672,17 +1591,16 @@ INSERT INTO `team_assign_agent` (`id`, `team_id`, `agent_id`, `created_at`, `upd -- Table structure for table `template` -- -CREATE TABLE IF NOT EXISTS `template` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `template` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` tinyint(1) NOT NULL, `template_set_to_clone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `language` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_note` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1690,8 +1608,8 @@ CREATE TABLE IF NOT EXISTS `template` ( -- Table structure for table `templates` -- -CREATE TABLE IF NOT EXISTS `templates` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `templates` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `variable` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` int(11) NOT NULL, @@ -1700,9 +1618,8 @@ CREATE TABLE IF NOT EXISTS `templates` ( `description` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `set_id` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=14 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `templates` @@ -1716,12 +1633,13 @@ INSERT INTO `templates` (`id`, `name`, `variable`, `type`, `subject`, `message`, (5, 'This template is for sending notice to agent on new ticket creation', '0', 5, '', '
Hello {!!$ticket_agent_name!!},

New ticket {!!$ticket_number!!}created 

From
Name: {!!$ticket_client_name!!}   
E-mail: {!!$ticket_client_email!!}

{!!$content!!}

Kind Regards,
{!!$system_from!!}
', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (6, 'This template is for sending notice to client on new ticket created by agent in name of client', '0', 6, '', '
{!!$content!!}

{!!$agent_sign!!}

You can check the status of or update this ticket online at: {!!$system_link!!}
', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (7, 'This template is for sending notice to client on new registration during new ticket creation for un registered clients', '1', 7, 'Registration Confirmation', '

Hello {!!$user!!}, 

This email is confirmation that you are now registered at our helpdesk.

Registered Email: {!!$email_address!!}

Password: {!!$user_password!!}

You can visit the helpdesk to browse articles and contact us at any time: {!!$system_link!!}

Thank You.

Kind Regards,

{!!$system_from!!} 

', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), -(8, 'This template is for sending notice to any user about reset password option', '1', 8, 'Reset your Password', 'Hello {!!$user!!},

You asked to reset your password. To do so, please click this link:

{!!$password_reset_link!!}

This will let you change your password to something new. If you didn''t ask for this, don''t worry, we''ll keep your password safe.

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), +(8, 'This template is for sending notice to any user about reset password option', '1', 8, 'Reset your Password', 'Hello {!!$user!!},

You asked to reset your password. To do so, please click this link:

{!!$password_reset_link!!}

This will let you change your password to something new. If you didn\'t ask for this, don\'t worry, we\'ll keep your password safe.

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (9, 'This template is for sending notice to client when a reply made to his/her ticket', '0', 9, '', '

{!!$content!!}

{!!$agent_sign!!} 

Ticket Details

Ticket ID: {!!$ticket_number!!}

', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (10, 'This template is for sending notice to agent when ticket reply is made by client on a ticket', '0', 10, '', '
Hello {!!$ticket_agent_name!!},

A reply been made to ticket {!!$ticket_number!!}

From
Name: {!!$ticket_client_name!!}
E-mail: {!!$ticket_client_email!!}

{!!$content!!}

Kind Regards,
{!!$system_from!!}
', '', 1, '2016-12-13 03:19:51', '2016-12-13 03:19:51'), (11, 'This template is for sending notice to client about registration confirmation link', '1', 11, 'Verify your email address', '

Hello {!!$user!!}, 

This email is confirmation that you are now registered at our helpdesk.

Registered Email: {!!$email_address!!}

Please click on the below link to activate your account and Login to the system {!!$password_reset_link!!}

Thank You.

Kind Regards,

{!!$system_from!!} 

', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'), (12, 'This template is for sending notice to team when ticket is assigned to team', '1', 12, '', '
Hello {!!$ticket_agent_name!!},

Ticket No: {!!$ticket_number!!}
Has been assigned to your team : {!!$team!!} by {!!$ticket_assigner!!} 

Thank You
Kind Regards,
{!!$system_from!!}
', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'), -(13, 'This template is for sending notice to client when password is changed', '1', 13, 'Verify your email address', 'Hello {!!$user!!},

Your password is successfully changed.Your new password is : {!!$user_password!!}

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'); +(13, 'This template is for sending notice to client when password is changed', '1', 13, 'Verify your email address', 'Hello {!!$user!!},

Your password is successfully changed.Your new password is : {!!$user_password!!}

Thank You.

Kind Regards,
{!!$system_from!!}', '', 1, '2016-12-13 03:19:52', '2016-12-13 03:19:52'), +(14, 'This template is to notify users when their tickets are merged.', '1', 14, 'Your tickets have been merged.', '

Hello {!!$user!!},
 

Your ticket(s) with ticket number {!!$merged_ticket_numbers!!} have been closed and merged with {!!$ticket_number!!}

Possible reasons for merging tickets

Click here to login to your account and check your tickets.

Regards,

{!!$system_from!!}

', '', 1, '2017-01-02 00:20:12', '2017-01-02 00:31:50'); -- -------------------------------------------------------- @@ -1729,14 +1647,13 @@ INSERT INTO `templates` (`id`, `name`, `variable`, `type`, `subject`, `message`, -- Table structure for table `template_sets` -- -CREATE TABLE IF NOT EXISTS `template_sets` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `template_sets` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `active` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `template_sets` @@ -1751,13 +1668,12 @@ INSERT INTO `template_sets` (`id`, `name`, `active`, `created_at`, `updated_at`) -- Table structure for table `template_types` -- -CREATE TABLE IF NOT EXISTS `template_types` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `template_types` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=14 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `template_types` @@ -1776,7 +1692,8 @@ INSERT INTO `template_types` (`id`, `name`, `created_at`, `updated_at`) VALUES (10, 'ticket-reply-agent', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), (11, 'registration', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), (12, 'team_assign_ticket', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), -(13, 'reset_new_password', '2016-12-13 03:19:48', '2016-12-13 03:19:48'); +(13, 'reset_new_password', '2016-12-13 03:19:48', '2016-12-13 03:19:48'), +(14, 'merge-ticket-notification', '2017-01-02 00:20:11', '2017-01-02 00:20:11'); -- -------------------------------------------------------- @@ -1784,24 +1701,24 @@ INSERT INTO `template_types` (`id`, `name`, `created_at`, `updated_at`) VALUES -- Table structure for table `tickets` -- -CREATE TABLE IF NOT EXISTS `tickets` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `tickets` ( + `id` int(10) UNSIGNED NOT NULL, `ticket_number` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `user_id` int(10) unsigned DEFAULT NULL, - `dept_id` int(10) unsigned DEFAULT NULL, - `team_id` int(10) unsigned DEFAULT NULL, - `priority_id` int(10) unsigned DEFAULT NULL, - `sla` int(10) unsigned DEFAULT NULL, - `help_topic_id` int(10) unsigned DEFAULT NULL, - `status` int(10) unsigned DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, + `dept_id` int(10) UNSIGNED DEFAULT NULL, + `team_id` int(10) UNSIGNED DEFAULT NULL, + `priority_id` int(10) UNSIGNED DEFAULT NULL, + `sla` int(10) UNSIGNED DEFAULT NULL, + `help_topic_id` int(10) UNSIGNED DEFAULT NULL, + `status` int(10) UNSIGNED DEFAULT NULL, `rating` tinyint(1) NOT NULL, `ratingreply` tinyint(1) NOT NULL, `flags` int(11) NOT NULL, `ip_address` int(11) NOT NULL, - `assigned_to` int(10) unsigned DEFAULT NULL, + `assigned_to` int(10) UNSIGNED DEFAULT NULL, `lock_by` int(11) NOT NULL, `lock_at` datetime DEFAULT NULL, - `source` int(10) unsigned DEFAULT NULL, + `source` int(10) UNSIGNED DEFAULT NULL, `isoverdue` int(11) NOT NULL, `reopened` int(11) NOT NULL, `isanswered` int(11) NOT NULL, @@ -1818,18 +1735,8 @@ CREATE TABLE IF NOT EXISTS `tickets` ( `approval` int(11) NOT NULL, `follow_up` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `user_id` (`user_id`), - KEY `dept_id` (`dept_id`), - KEY `team_id` (`team_id`), - KEY `priority_id` (`priority_id`), - KEY `sla` (`sla`), - KEY `help_topic_id` (`help_topic_id`), - KEY `status` (`status`), - KEY `assigned_to` (`assigned_to`), - KEY `source` (`source`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=7 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `tickets` @@ -1849,10 +1756,10 @@ INSERT INTO `tickets` (`id`, `ticket_number`, `user_id`, `dept_id`, `team_id`, ` -- Table structure for table `ticket_attachment` -- -CREATE TABLE IF NOT EXISTS `ticket_attachment` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_attachment` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `thread_id` int(10) unsigned DEFAULT NULL, + `thread_id` int(10) UNSIGNED DEFAULT NULL, `size` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `poster` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1860,10 +1767,8 @@ CREATE TABLE IF NOT EXISTS `ticket_attachment` ( `updated_at` timestamp NULL DEFAULT NULL, `file` mediumblob, `driver` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `path` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`), - KEY `thread_id` (`thread_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `path` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1871,18 +1776,15 @@ CREATE TABLE IF NOT EXISTS `ticket_attachment` ( -- Table structure for table `ticket_collaborator` -- -CREATE TABLE IF NOT EXISTS `ticket_collaborator` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_collaborator` ( + `id` int(10) UNSIGNED NOT NULL, `isactive` tinyint(1) NOT NULL, - `ticket_id` int(10) unsigned DEFAULT NULL, - `user_id` int(10) unsigned DEFAULT NULL, + `ticket_id` int(10) UNSIGNED DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, `role` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `ticket_id` (`ticket_id`), - KEY `user_id` (`user_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1890,16 +1792,14 @@ CREATE TABLE IF NOT EXISTS `ticket_collaborator` ( -- Table structure for table `ticket_form_data` -- -CREATE TABLE IF NOT EXISTS `ticket_form_data` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `ticket_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `ticket_form_data` ( + `id` int(10) UNSIGNED NOT NULL, + `ticket_id` int(10) UNSIGNED DEFAULT NULL, `title` text COLLATE utf8_unicode_ci NOT NULL, `content` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `ticket_id` (`ticket_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -1907,8 +1807,8 @@ CREATE TABLE IF NOT EXISTS `ticket_form_data` ( -- Table structure for table `ticket_priority` -- -CREATE TABLE IF NOT EXISTS `ticket_priority` ( - `priority_id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_priority` ( + `priority_id` int(10) UNSIGNED NOT NULL, `priority` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `priority_desc` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -1917,9 +1817,8 @@ CREATE TABLE IF NOT EXISTS `ticket_priority` ( `ispublic` tinyint(1) NOT NULL, `is_default` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`priority_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=5 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_priority` @@ -1937,13 +1836,12 @@ INSERT INTO `ticket_priority` (`priority_id`, `priority`, `status`, `priority_de -- Table structure for table `ticket_source` -- -CREATE TABLE IF NOT EXISTS `ticket_source` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_source` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `css_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=11 ; + `css_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_source` @@ -1967,8 +1865,8 @@ INSERT INTO `ticket_source` (`id`, `name`, `value`, `css_class`) VALUES -- Table structure for table `ticket_status` -- -CREATE TABLE IF NOT EXISTS `ticket_status` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_status` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `state` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `mode` int(11) NOT NULL, @@ -1979,9 +1877,8 @@ CREATE TABLE IF NOT EXISTS `ticket_status` ( `icon_class` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `properties` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_status` @@ -2002,12 +1899,12 @@ INSERT INTO `ticket_status` (`id`, `name`, `state`, `mode`, `message`, `flags`, -- Table structure for table `ticket_thread` -- -CREATE TABLE IF NOT EXISTS `ticket_thread` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `ticket_id` int(10) unsigned DEFAULT NULL, - `user_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `ticket_thread` ( + `id` int(10) UNSIGNED NOT NULL, + `ticket_id` int(10) UNSIGNED DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, `poster` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `source` int(10) unsigned DEFAULT NULL, + `source` int(10) UNSIGNED DEFAULT NULL, `reply_rating` int(11) NOT NULL, `rating_count` int(11) NOT NULL, `is_internal` tinyint(1) NOT NULL, @@ -2016,12 +1913,8 @@ CREATE TABLE IF NOT EXISTS `ticket_thread` ( `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `ip_address` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `ticket_id_2` (`ticket_id`), - KEY `user_id` (`user_id`), - KEY `source` (`source`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=12 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `ticket_thread` @@ -2046,14 +1939,13 @@ INSERT INTO `ticket_thread` (`id`, `ticket_id`, `user_id`, `poster`, `source`, ` -- Table structure for table `ticket_token` -- -CREATE TABLE IF NOT EXISTS `ticket_token` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `ticket_token` ( + `id` int(10) UNSIGNED NOT NULL, `ticket_id` int(11) NOT NULL, `token` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2061,12 +1953,11 @@ CREATE TABLE IF NOT EXISTS `ticket_token` ( -- Table structure for table `timezone` -- -CREATE TABLE IF NOT EXISTS `timezone` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `timezone` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `location` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=114 ; + `location` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `timezone` @@ -2193,11 +2084,10 @@ INSERT INTO `timezone` (`id`, `name`, `location`) VALUES -- Table structure for table `time_format` -- -CREATE TABLE IF NOT EXISTS `time_format` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=3 ; +CREATE TABLE `time_format` ( + `id` int(10) UNSIGNED NOT NULL, + `format` varchar(255) COLLATE utf8_unicode_ci NOT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `time_format` @@ -2213,8 +2103,8 @@ INSERT INTO `time_format` (`id`, `format`) VALUES -- Table structure for table `users` -- -CREATE TABLE IF NOT EXISTS `users` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `users` ( + `id` int(10) UNSIGNED NOT NULL, `user_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `first_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `last_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -2231,8 +2121,8 @@ CREATE TABLE IF NOT EXISTS `users` ( `agent_sign` text COLLATE utf8_unicode_ci NOT NULL, `account_type` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `account_status` varchar(255) COLLATE utf8_unicode_ci NOT NULL, - `assign_group` int(10) unsigned DEFAULT NULL, - `primary_dpt` int(10) unsigned DEFAULT NULL, + `assign_group` int(10) UNSIGNED DEFAULT NULL, + `primary_dpt` int(10) UNSIGNED DEFAULT NULL, `agent_tzone` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `daylight_save` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `limit_access` varchar(255) COLLATE utf8_unicode_ci NOT NULL, @@ -2244,26 +2134,21 @@ CREATE TABLE IF NOT EXISTS `users` ( `profile_pic` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `remember_token` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - UNIQUE KEY `users_email_unique` (`email`), - UNIQUE KEY `users_mobile_unique` (`mobile`), - KEY `assign_group_3` (`assign_group`), - KEY `primary_dpt_2` (`primary_dpt`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=8 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `users` -- INSERT INTO `users` (`id`, `user_name`, `first_name`, `last_name`, `gender`, `email`, `ban`, `password`, `active`, `is_delete`, `ext`, `country_code`, `phone_number`, `mobile`, `agent_sign`, `account_type`, `account_status`, `assign_group`, `primary_dpt`, `agent_tzone`, `daylight_save`, `limit_access`, `directory_listing`, `vacation_mode`, `company`, `role`, `internal_note`, `profile_pic`, `remember_token`, `created_at`, `updated_at`) VALUES -(1, 'demo@admin.com', 'Demo', 'admin', 0, 'demo@admin.com', 0, '$2y$10$ZkHOJeJCKFzLtL4yWXZ3suVZlG.fJwD9oUI3nM5FGESmIkQV1hMXC', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '', '', '', '', '', '', 'admin', '', '', NULL, '2016-12-13 03:19:53', '2016-12-13 03:19:53'), -(2, 'Abhrakasin', 'Abhrakasin', 'KK', 0, 'abhrakasin@gmail.com', 0, '$2y$10$nrMZMd72/HZbnzjBAi0RX.UQrNTtFeZFEK9aq.chDPZZ07rOC/6Ie', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '79', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:32:41', '2016-12-13 03:32:42'), -(3, 'Johan', 'Johan', 'Malhotra', 0, 'johan21@gmail.com', 0, '$2y$10$Eq8SHKUEXCkW5vqiWvA0Iu1UJmzZ.e5.Q3hI2tkxey5HZ2Lmbxb1C', 1, 0, '', 0, '', NULL, '', '', '', 2, 2, '7', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:35:29', '2016-12-13 03:35:30'), -(4, 'fidelm@gmail.com', 'Fidel Martin', '', 0, 'fidelm@gmail.com', 0, '$2y$10$wHupGhJqz2p4rcdS4eq4ZO.NQ65b0JjVsqhJwEEzOCl3vMKwzh9/S', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'PXj6d2s7rOqoh53gHdyPbiHOVvBmDoR5CnXg9kl7fRolIC92Y20UnFPSOryw', '2016-12-13 03:45:19', '2016-12-13 03:45:19'), -(5, 'joseph2321@gmail.com', 'Joseph Rossignol', '', 0, 'joseph2321@gmail.com', 0, '$2y$10$7eQ0nFxQpQkWaKwUbzTsQ.ufQpRN1rwUGY5ER1KsoXoLd6KbMIHnG', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'nv7Z37jhwAVdt87WCVzsqweY6wUbic7ll44FNmygMmwcnErafCrVpnw6Krys', '2016-12-13 03:50:55', '2016-12-13 03:50:55'), -(6, 'ichae1212@gmail.com', 'Ichae Semos', '', 0, 'ichae1212@gmail.com', 0, '$2y$10$aITz4IUuaxb0VHwF2V2CPefwf/Ft0VXpmHDC9feEfNXkW90GdjCFm', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'egq0NWPaxEkwkXmV3L0BJ4j4O6aKlgjzNZxea0XpYvCAeVvZLbXsjkKmWyBZ', '2016-12-13 03:55:54', '2016-12-13 03:55:54'), -(7, 'kusti09@yahoo.com', 'Kusti Franti', '', 0, 'kusti09@yahoo.com', 0, '$2y$10$yNHebbyWfr6m1t4srRlYbuj2JN706ZBpyMI.gSJmuY9czJ3OzuQpq', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', '4JPKOO9UUjZ2yX1GI7WYaeljcdyFATmguwNGuUD9chDodCVfJVGBJvbepgOt', '2016-12-13 03:58:40', '2016-12-13 03:58:40'); +(1, 'demo_admin', 'Demo', 'Admin', 0, NULL, 0, '$2y$10$ZkHOJeJCKFzLtL4yWXZ3suVZlG.fJwD9oUI3nM5FGESmIkQV1hMXC', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '', '', '', '', '', '', 'admin', '', '', NULL, '2016-12-13 03:19:53', '2016-12-13 03:19:53'), +(2, 'demo_agent', 'Abhrakasin', 'KK', 0, NULL, 0, '$2y$10$nrMZMd72/HZbnzjBAi0RX.UQrNTtFeZFEK9aq.chDPZZ07rOC/6Ie', 1, 0, '', 0, '', NULL, '', '', '', 1, 1, '79', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:32:41', '2016-12-13 03:32:42'), +(3, 'Johan', 'Johan', 'Malhotra', 0, NULL, 0, '$2y$10$Eq8SHKUEXCkW5vqiWvA0Iu1UJmzZ.e5.Q3hI2tkxey5HZ2Lmbxb1C', 1, 0, '', 0, '', NULL, '', '', '', 2, 2, '7', '', '', '', '', '', 'agent', '', '', NULL, '2016-12-13 03:35:29', '2016-12-13 03:35:30'), +(4, 'demo_client', 'Fidel Martin', '', 0, NULL, 0, '$2y$10$wHupGhJqz2p4rcdS4eq4ZO.NQ65b0JjVsqhJwEEzOCl3vMKwzh9/S', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'PXj6d2s7rOqoh53gHdyPbiHOVvBmDoR5CnXg9kl7fRolIC92Y20UnFPSOryw', '2016-12-13 03:45:19', '2016-12-13 03:45:19'), +(5, 'joseph2321@gmail.com', 'Joseph Rossignol', '', 0, NULL, 0, '$2y$10$7eQ0nFxQpQkWaKwUbzTsQ.ufQpRN1rwUGY5ER1KsoXoLd6KbMIHnG', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'nv7Z37jhwAVdt87WCVzsqweY6wUbic7ll44FNmygMmwcnErafCrVpnw6Krys', '2016-12-13 03:50:55', '2016-12-13 03:50:55'), +(6, 'ichae1212@gmail.com', 'Ichae Semos', '', 0, NULL, 0, '$2y$10$aITz4IUuaxb0VHwF2V2CPefwf/Ft0VXpmHDC9feEfNXkW90GdjCFm', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', 'egq0NWPaxEkwkXmV3L0BJ4j4O6aKlgjzNZxea0XpYvCAeVvZLbXsjkKmWyBZ', '2016-12-13 03:55:54', '2016-12-13 03:55:54'), +(7, 'kusti09@yahoo.com', 'Kusti Franti', '', 0, NULL, 0, '$2y$10$yNHebbyWfr6m1t4srRlYbuj2JN706ZBpyMI.gSJmuY9czJ3OzuQpq', 1, 0, '', 0, '', NULL, '', '', '', NULL, NULL, '', '', '', '', '', '', 'user', '', '', '4JPKOO9UUjZ2yX1GI7WYaeljcdyFATmguwNGuUD9chDodCVfJVGBJvbepgOt', '2016-12-13 03:58:40', '2016-12-13 03:58:40'); -- -------------------------------------------------------- @@ -2271,16 +2156,15 @@ INSERT INTO `users` (`id`, `user_name`, `first_name`, `last_name`, `gender`, `em -- Table structure for table `user_additional_infos` -- -CREATE TABLE IF NOT EXISTS `user_additional_infos` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `user_additional_infos` ( + `id` int(10) UNSIGNED NOT NULL, `owner` int(11) NOT NULL, `service` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `key` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `value` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2288,16 +2172,13 @@ CREATE TABLE IF NOT EXISTS `user_additional_infos` ( -- Table structure for table `user_assign_organization` -- -CREATE TABLE IF NOT EXISTS `user_assign_organization` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `org_id` int(10) unsigned DEFAULT NULL, - `user_id` int(10) unsigned DEFAULT NULL, +CREATE TABLE `user_assign_organization` ( + `id` int(10) UNSIGNED NOT NULL, + `org_id` int(10) UNSIGNED DEFAULT NULL, + `user_id` int(10) UNSIGNED DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `org_id` (`org_id`), - KEY `user_id` (`user_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2305,15 +2186,14 @@ CREATE TABLE IF NOT EXISTS `user_assign_organization` ( -- Table structure for table `user_notification` -- -CREATE TABLE IF NOT EXISTS `user_notification` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `user_notification` ( + `id` int(10) UNSIGNED NOT NULL, `notification_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `is_read` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=15 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `user_notification` @@ -2341,14 +2221,13 @@ INSERT INTO `user_notification` (`id`, `notification_id`, `user_id`, `is_read`, -- Table structure for table `version_check` -- -CREATE TABLE IF NOT EXISTS `version_check` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `version_check` ( + `id` int(10) UNSIGNED NOT NULL, `current_version` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `new_version` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `version_check` @@ -2363,15 +2242,14 @@ INSERT INTO `version_check` (`id`, `current_version`, `new_version`, `created_at -- Table structure for table `widgets` -- -CREATE TABLE IF NOT EXISTS `widgets` ( - `id` int(11) NOT NULL AUTO_INCREMENT, +CREATE TABLE `widgets` ( + `id` int(11) NOT NULL, `name` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, `title` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL, `value` text COLLATE utf8_unicode_ci, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=21 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `widgets` @@ -2405,16 +2283,14 @@ INSERT INTO `widgets` (`id`, `name`, `title`, `value`, `created_at`, `updated_at -- Table structure for table `workflow_action` -- -CREATE TABLE IF NOT EXISTS `workflow_action` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `workflow_id` int(10) unsigned NOT NULL, +CREATE TABLE `workflow_action` ( + `id` int(10) UNSIGNED NOT NULL, + `workflow_id` int(10) UNSIGNED NOT NULL, `condition` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `action` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `workflow_action_1` (`workflow_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2422,16 +2298,15 @@ CREATE TABLE IF NOT EXISTS `workflow_action` ( -- Table structure for table `workflow_close` -- -CREATE TABLE IF NOT EXISTS `workflow_close` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `workflow_close` ( + `id` int(10) UNSIGNED NOT NULL, `days` int(11) NOT NULL, `condition` int(11) NOT NULL, `send_email` int(11) NOT NULL, `status` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=2 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -- Dumping data for table `workflow_close` @@ -2446,17 +2321,16 @@ INSERT INTO `workflow_close` (`id`, `days`, `condition`, `send_email`, `status`, -- Table structure for table `workflow_name` -- -CREATE TABLE IF NOT EXISTS `workflow_name` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, +CREATE TABLE `workflow_name` ( + `id` int(10) UNSIGNED NOT NULL, `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `status` int(11) NOT NULL, `order` int(11) NOT NULL, `target` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `internal_note` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; -- -------------------------------------------------------- @@ -2464,19 +2338,921 @@ CREATE TABLE IF NOT EXISTS `workflow_name` ( -- Table structure for table `workflow_rules` -- -CREATE TABLE IF NOT EXISTS `workflow_rules` ( - `id` int(10) unsigned NOT NULL AUTO_INCREMENT, - `workflow_id` int(10) unsigned NOT NULL, +CREATE TABLE `workflow_rules` ( + `id` int(10) UNSIGNED NOT NULL, + `workflow_id` int(10) UNSIGNED NOT NULL, `matching_criteria` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `matching_scenario` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `matching_relation` varchar(255) COLLATE utf8_unicode_ci NOT NULL, `matching_value` text COLLATE utf8_unicode_ci NOT NULL, `created_at` timestamp NULL DEFAULT NULL, - `updated_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`id`), - KEY `workflow_rules_1` (`workflow_id`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ; + `updated_at` timestamp NULL DEFAULT NULL +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +-- +-- Indexes for dumped tables +-- + +-- +-- Indexes for table `api_settings` +-- +ALTER TABLE `api_settings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `banlist` +-- +ALTER TABLE `banlist` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `bar_notifications` +-- +ALTER TABLE `bar_notifications` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `canned_response` +-- +ALTER TABLE `canned_response` + ADD PRIMARY KEY (`id`), + ADD KEY `user_id` (`user_id`); + +-- +-- Indexes for table `common_settings` +-- +ALTER TABLE `common_settings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `conditions` +-- +ALTER TABLE `conditions` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `country_code` +-- +ALTER TABLE `country_code` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `custom_forms` +-- +ALTER TABLE `custom_forms` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `custom_form_fields` +-- +ALTER TABLE `custom_form_fields` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `date_format` +-- +ALTER TABLE `date_format` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `date_time_format` +-- +ALTER TABLE `date_time_format` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `department` +-- +ALTER TABLE `department` + ADD PRIMARY KEY (`id`), + ADD KEY `sla` (`sla`), + ADD KEY `manager_2` (`manager`); + +-- +-- Indexes for table `emails` +-- +ALTER TABLE `emails` + ADD PRIMARY KEY (`id`), + ADD KEY `department` (`department`,`priority`,`help_topic`), + ADD KEY `department_2` (`department`,`priority`,`help_topic`), + ADD KEY `priority` (`priority`), + ADD KEY `help_topic` (`help_topic`); + +-- +-- Indexes for table `failed_jobs` +-- +ALTER TABLE `failed_jobs` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `faveo_mails` +-- +ALTER TABLE `faveo_mails` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `faveo_queues` +-- +ALTER TABLE `faveo_queues` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `field_values` +-- +ALTER TABLE `field_values` + ADD PRIMARY KEY (`id`), + ADD KEY `field_values_field_id_foreign` (`field_id`); + +-- +-- Indexes for table `groups` +-- +ALTER TABLE `groups` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `group_assign_department` +-- +ALTER TABLE `group_assign_department` + ADD PRIMARY KEY (`id`), + ADD KEY `group_id` (`group_id`), + ADD KEY `department_id` (`department_id`); + +-- +-- Indexes for table `help_topic` +-- +ALTER TABLE `help_topic` + ADD PRIMARY KEY (`id`), + ADD KEY `custom_form` (`custom_form`), + ADD KEY `department` (`department`), + ADD KEY `ticket_status` (`ticket_status`), + ADD KEY `priority` (`priority`), + ADD KEY `sla_plan` (`sla_plan`), + ADD KEY `auto_assign_2` (`auto_assign`); + +-- +-- Indexes for table `jobs` +-- +ALTER TABLE `jobs` + ADD PRIMARY KEY (`id`), + ADD KEY `jobs_queue_reserved_reserved_at_index` (`queue`,`reserved`,`reserved_at`); + +-- +-- Indexes for table `kb_article` +-- +ALTER TABLE `kb_article` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `kb_article_relationship` +-- +ALTER TABLE `kb_article_relationship` + ADD PRIMARY KEY (`id`), + ADD KEY `article_relationship_article_id_foreign` (`article_id`), + ADD KEY `article_relationship_category_id_foreign` (`category_id`); + +-- +-- Indexes for table `kb_category` +-- +ALTER TABLE `kb_category` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `kb_comment` +-- +ALTER TABLE `kb_comment` + ADD PRIMARY KEY (`id`), + ADD KEY `comment_article_id_foreign` (`article_id`); + +-- +-- Indexes for table `kb_pages` +-- +ALTER TABLE `kb_pages` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `kb_settings` +-- +ALTER TABLE `kb_settings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `languages` +-- +ALTER TABLE `languages` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `login_attempts` +-- +ALTER TABLE `login_attempts` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `log_notification` +-- +ALTER TABLE `log_notification` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `mailbox_protocol` +-- +ALTER TABLE `mailbox_protocol` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `mail_services` +-- +ALTER TABLE `mail_services` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `notifications` +-- +ALTER TABLE `notifications` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `notification_types` +-- +ALTER TABLE `notification_types` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `organization` +-- +ALTER TABLE `organization` + ADD PRIMARY KEY (`id`), + ADD KEY `head` (`head`); + +-- +-- Indexes for table `password_resets` +-- +ALTER TABLE `password_resets` + ADD KEY `password_resets_email_index` (`email`), + ADD KEY `password_resets_token_index` (`token`); + +-- +-- Indexes for table `plugins` +-- +ALTER TABLE `plugins` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `queue_services` +-- +ALTER TABLE `queue_services` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `ratings` +-- +ALTER TABLE `ratings` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `rating_ref` +-- +ALTER TABLE `rating_ref` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_alert_notice` +-- +ALTER TABLE `settings_alert_notice` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_auto_response` +-- +ALTER TABLE `settings_auto_response` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_company` +-- +ALTER TABLE `settings_company` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_email` +-- +ALTER TABLE `settings_email` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_ratings` +-- +ALTER TABLE `settings_ratings` + ADD PRIMARY KEY (`id`), + ADD UNIQUE KEY `settings_ratings_slug_unique` (`slug`); + +-- +-- Indexes for table `settings_security` +-- +ALTER TABLE `settings_security` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `settings_system` +-- +ALTER TABLE `settings_system` + ADD PRIMARY KEY (`id`), + ADD KEY `time_farmat` (`time_farmat`), + ADD KEY `date_format` (`date_format`), + ADD KEY `date_time_format` (`date_time_format`), + ADD KEY `time_zone` (`time_zone`); + +-- +-- Indexes for table `settings_ticket` +-- +ALTER TABLE `settings_ticket` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `sla_plan` +-- +ALTER TABLE `sla_plan` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `social_media` +-- +ALTER TABLE `social_media` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `teams` +-- +ALTER TABLE `teams` + ADD PRIMARY KEY (`id`), + ADD KEY `team_lead` (`team_lead`); + +-- +-- Indexes for table `team_assign_agent` +-- +ALTER TABLE `team_assign_agent` + ADD PRIMARY KEY (`id`), + ADD KEY `team_id` (`team_id`), + ADD KEY `agent_id` (`agent_id`); + +-- +-- Indexes for table `template` +-- +ALTER TABLE `template` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `templates` +-- +ALTER TABLE `templates` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `template_sets` +-- +ALTER TABLE `template_sets` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `template_types` +-- +ALTER TABLE `template_types` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `tickets` +-- +ALTER TABLE `tickets` + ADD PRIMARY KEY (`id`), + ADD KEY `user_id` (`user_id`), + ADD KEY `dept_id` (`dept_id`), + ADD KEY `team_id` (`team_id`), + ADD KEY `priority_id` (`priority_id`), + ADD KEY `sla` (`sla`), + ADD KEY `help_topic_id` (`help_topic_id`), + ADD KEY `status` (`status`), + ADD KEY `assigned_to` (`assigned_to`), + ADD KEY `source` (`source`); + +-- +-- Indexes for table `ticket_attachment` +-- +ALTER TABLE `ticket_attachment` + ADD PRIMARY KEY (`id`), + ADD KEY `thread_id` (`thread_id`); + +-- +-- Indexes for table `ticket_collaborator` +-- +ALTER TABLE `ticket_collaborator` + ADD PRIMARY KEY (`id`), + ADD KEY `ticket_id` (`ticket_id`), + ADD KEY `user_id` (`user_id`); + +-- +-- Indexes for table `ticket_form_data` +-- +ALTER TABLE `ticket_form_data` + ADD PRIMARY KEY (`id`), + ADD KEY `ticket_id` (`ticket_id`); + +-- +-- Indexes for table `ticket_priority` +-- +ALTER TABLE `ticket_priority` + ADD PRIMARY KEY (`priority_id`); + +-- +-- Indexes for table `ticket_source` +-- +ALTER TABLE `ticket_source` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `ticket_status` +-- +ALTER TABLE `ticket_status` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `ticket_thread` +-- +ALTER TABLE `ticket_thread` + ADD PRIMARY KEY (`id`), + ADD KEY `ticket_id_2` (`ticket_id`), + ADD KEY `user_id` (`user_id`), + ADD KEY `source` (`source`); + +-- +-- Indexes for table `ticket_token` +-- +ALTER TABLE `ticket_token` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `timezone` +-- +ALTER TABLE `timezone` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `time_format` +-- +ALTER TABLE `time_format` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `users` +-- +ALTER TABLE `users` + ADD PRIMARY KEY (`id`), + ADD UNIQUE KEY `users_email_unique` (`email`), + ADD UNIQUE KEY `users_mobile_unique` (`mobile`), + ADD KEY `assign_group_3` (`assign_group`), + ADD KEY `primary_dpt_2` (`primary_dpt`); + +-- +-- Indexes for table `user_additional_infos` +-- +ALTER TABLE `user_additional_infos` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `user_assign_organization` +-- +ALTER TABLE `user_assign_organization` + ADD PRIMARY KEY (`id`), + ADD KEY `org_id` (`org_id`), + ADD KEY `user_id` (`user_id`); + +-- +-- Indexes for table `user_notification` +-- +ALTER TABLE `user_notification` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `version_check` +-- +ALTER TABLE `version_check` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `widgets` +-- +ALTER TABLE `widgets` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `workflow_action` +-- +ALTER TABLE `workflow_action` + ADD PRIMARY KEY (`id`), + ADD KEY `workflow_action_1` (`workflow_id`); + +-- +-- Indexes for table `workflow_close` +-- +ALTER TABLE `workflow_close` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `workflow_name` +-- +ALTER TABLE `workflow_name` + ADD PRIMARY KEY (`id`); + +-- +-- Indexes for table `workflow_rules` +-- +ALTER TABLE `workflow_rules` + ADD PRIMARY KEY (`id`), + ADD KEY `workflow_rules_1` (`workflow_id`); + +-- +-- AUTO_INCREMENT for dumped tables +-- + +-- +-- AUTO_INCREMENT for table `api_settings` +-- +ALTER TABLE `api_settings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `banlist` +-- +ALTER TABLE `banlist` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `bar_notifications` +-- +ALTER TABLE `bar_notifications` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `canned_response` +-- +ALTER TABLE `canned_response` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `common_settings` +-- +ALTER TABLE `common_settings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `conditions` +-- +ALTER TABLE `conditions` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `country_code` +-- +ALTER TABLE `country_code` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=240; +-- +-- AUTO_INCREMENT for table `custom_forms` +-- +ALTER TABLE `custom_forms` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `custom_form_fields` +-- +ALTER TABLE `custom_form_fields` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `date_format` +-- +ALTER TABLE `date_format` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10; +-- +-- AUTO_INCREMENT for table `date_time_format` +-- +ALTER TABLE `date_time_format` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10; +-- +-- AUTO_INCREMENT for table `department` +-- +ALTER TABLE `department` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `emails` +-- +ALTER TABLE `emails` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `failed_jobs` +-- +ALTER TABLE `failed_jobs` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `faveo_mails` +-- +ALTER TABLE `faveo_mails` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `faveo_queues` +-- +ALTER TABLE `faveo_queues` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `field_values` +-- +ALTER TABLE `field_values` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `groups` +-- +ALTER TABLE `groups` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `group_assign_department` +-- +ALTER TABLE `group_assign_department` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `help_topic` +-- +ALTER TABLE `help_topic` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `jobs` +-- +ALTER TABLE `jobs` + MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `kb_article` +-- +ALTER TABLE `kb_article` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `kb_article_relationship` +-- +ALTER TABLE `kb_article_relationship` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `kb_category` +-- +ALTER TABLE `kb_category` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `kb_comment` +-- +ALTER TABLE `kb_comment` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `kb_pages` +-- +ALTER TABLE `kb_pages` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `kb_settings` +-- +ALTER TABLE `kb_settings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `languages` +-- +ALTER TABLE `languages` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10; +-- +-- AUTO_INCREMENT for table `login_attempts` +-- +ALTER TABLE `login_attempts` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `log_notification` +-- +ALTER TABLE `log_notification` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `mailbox_protocol` +-- +ALTER TABLE `mailbox_protocol` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5; +-- +-- AUTO_INCREMENT for table `mail_services` +-- +ALTER TABLE `mail_services` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7; +-- +-- AUTO_INCREMENT for table `notifications` +-- +ALTER TABLE `notifications` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `notification_types` +-- +ALTER TABLE `notification_types` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `organization` +-- +ALTER TABLE `organization` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `plugins` +-- +ALTER TABLE `plugins` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `queue_services` +-- +ALTER TABLE `queue_services` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7; +-- +-- AUTO_INCREMENT for table `ratings` +-- +ALTER TABLE `ratings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `rating_ref` +-- +ALTER TABLE `rating_ref` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `settings_alert_notice` +-- +ALTER TABLE `settings_alert_notice` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_auto_response` +-- +ALTER TABLE `settings_auto_response` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_company` +-- +ALTER TABLE `settings_company` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_email` +-- +ALTER TABLE `settings_email` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_ratings` +-- +ALTER TABLE `settings_ratings` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `settings_security` +-- +ALTER TABLE `settings_security` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `settings_system` +-- +ALTER TABLE `settings_system` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `settings_ticket` +-- +ALTER TABLE `settings_ticket` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `sla_plan` +-- +ALTER TABLE `sla_plan` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `social_media` +-- +ALTER TABLE `social_media` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `teams` +-- +ALTER TABLE `teams` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4; +-- +-- AUTO_INCREMENT for table `team_assign_agent` +-- +ALTER TABLE `team_assign_agent` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `template` +-- +ALTER TABLE `template` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `templates` +-- +ALTER TABLE `templates` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15; +-- +-- AUTO_INCREMENT for table `template_sets` +-- +ALTER TABLE `template_sets` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `template_types` +-- +ALTER TABLE `template_types` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15; +-- +-- AUTO_INCREMENT for table `tickets` +-- +ALTER TABLE `tickets` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=7; +-- +-- AUTO_INCREMENT for table `ticket_attachment` +-- +ALTER TABLE `ticket_attachment` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `ticket_collaborator` +-- +ALTER TABLE `ticket_collaborator` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `ticket_form_data` +-- +ALTER TABLE `ticket_form_data` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `ticket_priority` +-- +ALTER TABLE `ticket_priority` + MODIFY `priority_id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5; +-- +-- AUTO_INCREMENT for table `ticket_source` +-- +ALTER TABLE `ticket_source` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11; +-- +-- AUTO_INCREMENT for table `ticket_status` +-- +ALTER TABLE `ticket_status` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8; +-- +-- AUTO_INCREMENT for table `ticket_thread` +-- +ALTER TABLE `ticket_thread` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=12; +-- +-- AUTO_INCREMENT for table `ticket_token` +-- +ALTER TABLE `ticket_token` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `timezone` +-- +ALTER TABLE `timezone` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=114; +-- +-- AUTO_INCREMENT for table `time_format` +-- +ALTER TABLE `time_format` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3; +-- +-- AUTO_INCREMENT for table `users` +-- +ALTER TABLE `users` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=9; +-- +-- AUTO_INCREMENT for table `user_additional_infos` +-- +ALTER TABLE `user_additional_infos` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `user_assign_organization` +-- +ALTER TABLE `user_assign_organization` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `user_notification` +-- +ALTER TABLE `user_notification` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15; +-- +-- AUTO_INCREMENT for table `version_check` +-- +ALTER TABLE `version_check` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `widgets` +-- +ALTER TABLE `widgets` + MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=21; +-- +-- AUTO_INCREMENT for table `workflow_action` +-- +ALTER TABLE `workflow_action` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `workflow_close` +-- +ALTER TABLE `workflow_close` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2; +-- +-- AUTO_INCREMENT for table `workflow_name` +-- +ALTER TABLE `workflow_name` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; +-- +-- AUTO_INCREMENT for table `workflow_rules` +-- +ALTER TABLE `workflow_rules` + MODIFY `id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT; -- -- Constraints for dumped tables -- @@ -2491,16 +3267,16 @@ ALTER TABLE `canned_response` -- Constraints for table `department` -- ALTER TABLE `department` - ADD CONSTRAINT `department_ibfk_2` FOREIGN KEY (`manager`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `department_ibfk_1` FOREIGN KEY (`sla`) REFERENCES `sla_plan` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `department_ibfk_1` FOREIGN KEY (`sla`) REFERENCES `sla_plan` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `department_ibfk_2` FOREIGN KEY (`manager`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `emails` -- ALTER TABLE `emails` - ADD CONSTRAINT `emails_ibfk_3` FOREIGN KEY (`help_topic`) REFERENCES `help_topic` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `emails_ibfk_1` FOREIGN KEY (`department`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `emails_ibfk_2` FOREIGN KEY (`priority`) REFERENCES `ticket_priority` (`priority_id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `emails_ibfk_2` FOREIGN KEY (`priority`) REFERENCES `ticket_priority` (`priority_id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `emails_ibfk_3` FOREIGN KEY (`help_topic`) REFERENCES `help_topic` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `field_values` @@ -2512,26 +3288,26 @@ ALTER TABLE `field_values` -- Constraints for table `group_assign_department` -- ALTER TABLE `group_assign_department` - ADD CONSTRAINT `group_assign_department_ibfk_2` FOREIGN KEY (`department_id`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `group_assign_department_ibfk_1` FOREIGN KEY (`group_id`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `group_assign_department_ibfk_1` FOREIGN KEY (`group_id`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `group_assign_department_ibfk_2` FOREIGN KEY (`department_id`) REFERENCES `department` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `help_topic` -- ALTER TABLE `help_topic` - ADD CONSTRAINT `help_topic_ibfk_6` FOREIGN KEY (`auto_assign`) REFERENCES `users` (`id`) ON DELETE SET NULL, ADD CONSTRAINT `help_topic_ibfk_1` FOREIGN KEY (`custom_form`) REFERENCES `custom_forms` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `help_topic_ibfk_2` FOREIGN KEY (`department`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `help_topic_ibfk_3` FOREIGN KEY (`ticket_status`) REFERENCES `ticket_status` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `help_topic_ibfk_4` FOREIGN KEY (`priority`) REFERENCES `ticket_priority` (`priority_id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `help_topic_ibfk_5` FOREIGN KEY (`sla_plan`) REFERENCES `sla_plan` (`id`); + ADD CONSTRAINT `help_topic_ibfk_5` FOREIGN KEY (`sla_plan`) REFERENCES `sla_plan` (`id`), + ADD CONSTRAINT `help_topic_ibfk_6` FOREIGN KEY (`auto_assign`) REFERENCES `users` (`id`) ON DELETE SET NULL; -- -- Constraints for table `kb_article_relationship` -- ALTER TABLE `kb_article_relationship` - ADD CONSTRAINT `article_relationship_category_id_foreign` FOREIGN KEY (`category_id`) REFERENCES `kb_category` (`id`), - ADD CONSTRAINT `article_relationship_article_id_foreign` FOREIGN KEY (`article_id`) REFERENCES `kb_article` (`id`); + ADD CONSTRAINT `article_relationship_article_id_foreign` FOREIGN KEY (`article_id`) REFERENCES `kb_article` (`id`), + ADD CONSTRAINT `article_relationship_category_id_foreign` FOREIGN KEY (`category_id`) REFERENCES `kb_category` (`id`); -- -- Constraints for table `kb_comment` @@ -2549,10 +3325,10 @@ ALTER TABLE `organization` -- Constraints for table `settings_system` -- ALTER TABLE `settings_system` - ADD CONSTRAINT `settings_system_ibfk_4` FOREIGN KEY (`date_time_format`) REFERENCES `date_time_format` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `settings_system_ibfk_1` FOREIGN KEY (`time_zone`) REFERENCES `timezone` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `settings_system_ibfk_2` FOREIGN KEY (`time_farmat`) REFERENCES `time_format` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `settings_system_ibfk_3` FOREIGN KEY (`date_format`) REFERENCES `date_format` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `settings_system_ibfk_3` FOREIGN KEY (`date_format`) REFERENCES `date_format` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `settings_system_ibfk_4` FOREIGN KEY (`date_time_format`) REFERENCES `date_time_format` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `teams` @@ -2564,14 +3340,13 @@ ALTER TABLE `teams` -- Constraints for table `team_assign_agent` -- ALTER TABLE `team_assign_agent` - ADD CONSTRAINT `team_assign_agent_ibfk_2` FOREIGN KEY (`agent_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `team_assign_agent_ibfk_1` FOREIGN KEY (`team_id`) REFERENCES `teams` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `team_assign_agent_ibfk_1` FOREIGN KEY (`team_id`) REFERENCES `teams` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `team_assign_agent_ibfk_2` FOREIGN KEY (`agent_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `tickets` -- ALTER TABLE `tickets` - ADD CONSTRAINT `tickets_ibfk_9` FOREIGN KEY (`assigned_to`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_2` FOREIGN KEY (`dept_id`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_3` FOREIGN KEY (`team_id`) REFERENCES `teams` (`id`) ON UPDATE NO ACTION, @@ -2579,7 +3354,8 @@ ALTER TABLE `tickets` ADD CONSTRAINT `tickets_ibfk_5` FOREIGN KEY (`sla`) REFERENCES `sla_plan` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_6` FOREIGN KEY (`help_topic_id`) REFERENCES `help_topic` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `tickets_ibfk_7` FOREIGN KEY (`status`) REFERENCES `ticket_status` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `tickets_ibfk_8` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `tickets_ibfk_8` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `tickets_ibfk_9` FOREIGN KEY (`assigned_to`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `ticket_attachment` @@ -2591,8 +3367,8 @@ ALTER TABLE `ticket_attachment` -- Constraints for table `ticket_collaborator` -- ALTER TABLE `ticket_collaborator` - ADD CONSTRAINT `ticket_collaborator_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `ticket_collaborator_ibfk_1` FOREIGN KEY (`ticket_id`) REFERENCES `tickets` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `ticket_collaborator_ibfk_1` FOREIGN KEY (`ticket_id`) REFERENCES `tickets` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `ticket_collaborator_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `ticket_form_data` @@ -2604,23 +3380,23 @@ ALTER TABLE `ticket_form_data` -- Constraints for table `ticket_thread` -- ALTER TABLE `ticket_thread` - ADD CONSTRAINT `ticket_thread_ibfk_3` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION, ADD CONSTRAINT `ticket_thread_ibfk_1` FOREIGN KEY (`ticket_id`) REFERENCES `tickets` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `ticket_thread_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `ticket_thread_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `ticket_thread_ibfk_3` FOREIGN KEY (`source`) REFERENCES `ticket_source` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `users` -- ALTER TABLE `users` - ADD CONSTRAINT `users_ibfk_2` FOREIGN KEY (`primary_dpt`) REFERENCES `department` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `users_ibfk_1` FOREIGN KEY (`assign_group`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `users_ibfk_1` FOREIGN KEY (`assign_group`) REFERENCES `groups` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `users_ibfk_2` FOREIGN KEY (`primary_dpt`) REFERENCES `department` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `user_assign_organization` -- ALTER TABLE `user_assign_organization` - ADD CONSTRAINT `user_assign_organization_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION, - ADD CONSTRAINT `user_assign_organization_ibfk_1` FOREIGN KEY (`org_id`) REFERENCES `organization` (`id`) ON UPDATE NO ACTION; + ADD CONSTRAINT `user_assign_organization_ibfk_1` FOREIGN KEY (`org_id`) REFERENCES `organization` (`id`) ON UPDATE NO ACTION, + ADD CONSTRAINT `user_assign_organization_ibfk_2` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON UPDATE NO ACTION; -- -- Constraints for table `workflow_action` diff --git a/DB/update from 1.9.0 to 1.9.2/updatedatabase.sql b/DB/update from 1.9.0 to 1.9.2/updatedatabase.sql new file mode 100644 index 000000000..0a8fe63a1 --- /dev/null +++ b/DB/update from 1.9.0 to 1.9.2/updatedatabase.sql @@ -0,0 +1,14 @@ +-- +-- Dumping data for table `template_types` +-- + +INSERT INTO `template_types` (`id`, `name`, `created_at`, `updated_at`) VALUES +(14, 'merge-ticket-notification', '2017-01-02 05:50:11', '2017-01-02 05:50:11'); + +-- +-- Dumping data for table `templates` +-- + +INSERT INTO `templates` (`name`, `variable`, `type`, `subject`, `message`, `description`, `set_id`, `created_at`, `updated_at`) +SELECT 'This template is to notify users when their tickets are merged.', '1', 14, 'Your tickets have been merged.', '

Hello {!!$user!!},
 

Your ticket(s) with ticket number {!!$merged_ticket_numbers!!} have been closed and merged with {!!$ticket_number!!}

Possible reasons for merging tickets

Click here to login to your account and check your tickets.

Regards,

{!!$system_from!!}

', '', id, '2017-01-02 05:50:12', '2017-01-02 06:01:50' +FROM `template_sets`; \ No newline at end of file diff --git a/app/FaveoStorage/views/settings.blade.php b/app/FaveoStorage/views/settings.blade.php index 52fb6dda4..ba5b0d5e9 100644 --- a/app/FaveoStorage/views/settings.blade.php +++ b/app/FaveoStorage/views/settings.blade.php @@ -1,9 +1,24 @@ @extends('themes.default1.admin.layout.admin') -@section('content') -
-

{{Lang::get('storage::lang.settings')}}

-
+@section('Settings') +active +@stop + +@section('settings-bar') +active +@stop + +@section('storage') +class="active" +@stop + +@section('PageHeader') +

{{ Lang::get('storage::lang.storage')}}

+@stop + +@section('HeadInclude') +@stop +@section('content')
diff --git a/app/Http/Controllers/Admin/helpdesk/HelptopicController.php b/app/Http/Controllers/Admin/helpdesk/HelptopicController.php index 0f78400fa..82a1669af 100644 --- a/app/Http/Controllers/Admin/helpdesk/HelptopicController.php +++ b/app/Http/Controllers/Admin/helpdesk/HelptopicController.php @@ -85,7 +85,7 @@ class HelptopicController extends Controller $departments = $department->get(); $topics = $topic->get(); $forms = $form->get(); - $agents = $agent->where('role', '=', 'agent')->get(); + $agents = $agent->where('role', '!=', 'user')->where('active', '=', 1)->orderBy('first_name')->get(); $slas = $sla->get(); $priority = Ticket_Priority::where('status', '=', 1)->get(); @@ -143,7 +143,7 @@ class HelptopicController extends Controller public function edit($id, Ticket_Priority $priority, Department $department, Help_topic $topic, Forms $form, Sla_plan $sla) { try { - $agents = User::where('role', '=', 'agent')->get(); + $agents = User::where('role', '!=', 'user')->where('active', '=', 1)->orderBy('first_name')->get(); $departments = $department->get(); $topics = $topic->whereId($id)->first(); $forms = $form->get(); diff --git a/app/Http/Controllers/Admin/helpdesk/LanguageController.php b/app/Http/Controllers/Admin/helpdesk/LanguageController.php index 8eb174a22..684f2c7d4 100644 --- a/app/Http/Controllers/Admin/helpdesk/LanguageController.php +++ b/app/Http/Controllers/Admin/helpdesk/LanguageController.php @@ -122,79 +122,84 @@ class LanguageController extends Controller */ public function postForm() { - // getting all of the post data - $file = [ - 'File' => Input::file('File'), - 'language-name' => Input::input('language-name'), - 'iso-code' => Input::input('iso-code'), - ]; + try { + // getting all of the post data + $file = [ + 'File' => Input::file('File'), + 'language-name' => Input::input('language-name'), + 'iso-code' => Input::input('iso-code'), + ]; - // setting up rules - $rules = [ - 'File' => 'required|mimes:zip|max:30000', - 'language-name' => 'required', - 'iso-code' => 'required|max:2', - ]; // and for max size - // doing the validation, passing post data, rules and the messages - $validator = Validator::make($file, $rules); - if ($validator->fails()) { + // setting up rules + $rules = [ + 'File' => 'required|mimes:zip|max:30000', + 'language-name' => 'required', + 'iso-code' => 'required|max:2', + ]; // and for max size + // doing the validation, passing post data, rules and the messages + $validator = Validator::make($file, $rules); + if ($validator->fails()) { - // send back to the page with the input data and errors - return Redirect::back()->withInput()->withErrors($validator); - } else { - - //Checking if package already exists or not in lang folder - $path = base_path('resources/lang'); - if (in_array(strtolower(Input::get('iso-code')), scandir($path))) { - - //sending back with error message - Session::flash('fails', Lang::get('lang.package_exist')); - Session::flash('link', 'change-language/'.strtolower(Input::get('iso-code'))); - - return Redirect::back()->withInput(); - } elseif (!array_key_exists(strtolower(Input::get('iso-code')), Config::get('languages'))) {//Checking Valid ISO code form Languages.php - //sending back with error message - Session::flash('fails', Lang::get('lang.iso-code-error')); - - return Redirect::back()->withInput(); + // send back to the page with the input data and errors + return Redirect::back()->withInput()->withErrors($validator); } else { - // checking file is valid. - if (Input::file('File')->isValid()) { - $name = Input::file('File')->getClientOriginalName(); //uploaded file's original name - $destinationPath = base_path('public/uploads/'); // defining uploading path - $extractpath = base_path('resources/lang').'/'.strtolower(Input::get('iso-code')); //defining extracting path - mkdir($extractpath); //creating directroy for extracting uploadd file - //mkdir($destinationPath); - Input::file('File')->move($destinationPath, $name); // uploading file to given path - \Zipper::make($destinationPath.'/'.$name)->extractTo($extractpath); //extracting file to give path - //check if Zip extract foldercontains any subfolder - $directories = File::directories($extractpath); - //$directories = glob($extractpath. '/*' , GLOB_ONLYDIR); - if (!empty($directories)) { //if extract folder contains subfolder - $success = File::deleteDirectory($extractpath); //remove extracted folder and it's subfolder from lang - //$success2 = File::delete($destinationPath.'/'.$name); - if ($success) { - //sending back with error message - Session::flash('fails', Lang::get('lang.zipp-error')); - Session::flash('link2', 'http://www.ladybirdweb.com/support/show/how-to-translate-faveo-into-multiple-languages'); + //Checking if package already exists or not in lang folder + $path = base_path('resources/lang'); + if (in_array(strtolower(Input::get('iso-code')), scandir($path))) { - return Redirect::back()->withInput(); + //sending back with error message + Session::flash('fails', Lang::get('lang.package_exist')); + Session::flash('link', 'change-language/'.strtolower(Input::get('iso-code'))); + + return Redirect::back()->withInput(); + } elseif (!array_key_exists(strtolower(Input::get('iso-code')), Config::get('languages'))) {//Checking Valid ISO code form Languages.php + //sending back with error message + Session::flash('fails', Lang::get('lang.iso-code-error')); + + return Redirect::back()->withInput(); + } else { + + // checking file is valid. + if (Input::file('File')->isValid()) { + $name = Input::file('File')->getClientOriginalName(); //uploaded file's original name + $destinationPath = base_path('public/uploads/'); // defining uploading path + $extractpath = base_path('resources/lang').'/'.strtolower(Input::get('iso-code')); //defining extracting path + mkdir($extractpath); //creating directroy for extracting uploadd file + //mkdir($destinationPath); + Input::file('File')->move($destinationPath, $name); // uploading file to given path + \Zipper::make($destinationPath.'/'.$name)->extractTo($extractpath); //extracting file to give path + //check if Zip extract foldercontains any subfolder + $directories = File::directories($extractpath); + //$directories = glob($extractpath. '/*' , GLOB_ONLYDIR); + if (!empty($directories)) { //if extract folder contains subfolder + $success = File::deleteDirectory($extractpath); //remove extracted folder and it's subfolder from lang + //$success2 = File::delete($destinationPath.'/'.$name); + if ($success) { + //sending back with error message + Session::flash('fails', Lang::get('lang.zipp-error')); + Session::flash('link2', 'http://www.ladybirdweb.com/support/show/how-to-translate-faveo-into-multiple-languages'); + + return Redirect::back()->withInput(); + } + } else { + // sending back with success message + Session::flash('success', Lang::get('lang.upload-success')); + Session::flash('link', 'change-language/'.strtolower(Input::get('iso-code'))); + + return Redirect::route('LanguageController'); } } else { - // sending back with success message - Session::flash('success', Lang::get('lang.upload-success')); - Session::flash('link', 'change-language/'.strtolower(Input::get('iso-code'))); + // sending back with error message. + Session::flash('fails', Lang::get('lang.file-error')); - return Redirect::route('LanguageController'); + return Redirect::route('form'); } - } else { - // sending back with error message. - Session::flash('fails', Lang::get('lang.file-error')); - - return Redirect::route('form'); } } + } catch (\Exception $e) { + Session::flash('fails', $e->getMessage()); + Redirect::back()->withInput(); } } @@ -205,7 +210,8 @@ class LanguageController extends Controller */ public function download() { - $file_path = base_path('public/downloads/en.zip'); + $path = 'downloads'.DIRECTORY_SEPARATOR.'en.zip'; + $file_path = public_path($path); return response()->download($file_path); } diff --git a/app/Http/Controllers/Admin/helpdesk/TeamController.php b/app/Http/Controllers/Admin/helpdesk/TeamController.php index a56df80d0..d662875c1 100644 --- a/app/Http/Controllers/Admin/helpdesk/TeamController.php +++ b/app/Http/Controllers/Admin/helpdesk/TeamController.php @@ -68,7 +68,7 @@ class TeamController extends Controller public function create(User $user) { try { - $user = $user->where('role', '<>', 'user')->where('active', '=', 1)->get(); + $user = $user->where('role', '<>', 'user')->where('active', '=', 1)->orderBy('first_name')->get(); return view('themes.default1.admin.helpdesk.agent.teams.create', compact('user')); } catch (Exception $e) { @@ -86,15 +86,23 @@ class TeamController extends Controller */ public function store(Teams $team, TeamRequest $request) { - if ($request->team_lead) { - $team_lead = $request->team_lead; - } else { - $team_lead = null; - } - $team->team_lead = $team_lead; try { /* Check whether function success or not */ $team->fill($request->except('team_lead'))->save(); + $team_update = Teams::find($team->id); + if ($request->team_lead) { + $team_lead = $request->team_lead; + $team_update->update([ + 'team_lead' => $team_lead, + ]); + Assign_team_agent::create([ + 'team_id' => $team_update->id, + 'agent_id' => $team_lead, + ]); + } else { + $team_lead = null; + } + /* redirect to Index page with Success Message */ return redirect('teams')->with('success', Lang::get('lang.teams_created_successfully')); } catch (Exception $e) { @@ -202,11 +210,16 @@ $users = DB::table('team_assign_agent')->select('team_assign_agent.id', 'team_as public function edit($id, User $user, Assign_team_agent $assign_team_agent, Teams $team) { try { - $user = $user->where('role', '<>', 'user')->where('active', '=', 1)->get(); + $a_id = []; $teams = $team->whereId($id)->first(); $agent_team = $assign_team_agent->where('team_id', $id)->get(); $agent_id = $agent_team->lists('agent_id', 'agent_id'); - + foreach ($agent_id as $value) { + array_push($a_id, $value); + } + // dd($a_id); + $user = $user->whereIn('id', $a_id)->where('active', '=', 1)->orderBy('first_name')->get(); + // dd($user); return view('themes.default1.admin.helpdesk.agent.teams.edit', compact('agent_id', 'user', 'teams', 'allagents')); } catch (Exception $e) { return redirect()->back()->with('fails', $e->getMessage()); diff --git a/app/Http/Controllers/Agent/helpdesk/Filter/FilterController.php b/app/Http/Controllers/Agent/helpdesk/Filter/FilterController.php index 4b6ba59ed..927787da4 100644 --- a/app/Http/Controllers/Agent/helpdesk/Filter/FilterController.php +++ b/app/Http/Controllers/Agent/helpdesk/Filter/FilterController.php @@ -132,7 +132,7 @@ class FilterController extends Controller $join->on('ticket_status.id', '=', 'tickets.status'); }) ->where('tickets.status', '=', 1) - // ->where('tickets.isanswered', '=', 0) + ->where('tickets.isanswered', '=', 0) ->whereNotNull('tickets.duedate') ->where('tickets.duedate', '!=', '00-00-00 00:00:00') @@ -196,6 +196,7 @@ class FilterController extends Controller ->leftJoin('ticket_status', function ($join) { $join->on('ticket_status.id', '=', 'tickets.status'); }) + ->where('isanswered', '=', 0) ->where('tickets.status', '=', 1); case '/duetoday': if (Auth::user()->role == 'agent') { @@ -238,7 +239,7 @@ class FilterController extends Controller ->whereNotNull('title') ->where('ticket_thread.is_internal', '<>', 1); }) - + ->leftJoin('ticket_thread as ticket_thread2', 'ticket_thread2.ticket_id', '=', 'tickets.id') ->Join('ticket_source', 'ticket_source.id', '=', 'tickets.source') ->leftJoin('ticket_priority', 'ticket_priority.priority_id', '=', 'tickets.priority_id') ->leftJoin('users as u', 'u.id', '=', 'tickets.user_id') @@ -255,17 +256,17 @@ class FilterController extends Controller 'u1.user_name as assign_user_name', \DB::raw('max(ticket_thread.updated_at) as updated_at'), \DB::raw('min(ticket_thread.updated_at) as created_at'), - 'tickets.priority_id', 'tickets.assigned_to', - DB::raw('COUNT(ticket_thread.updated_at) as countthread'), - 'ticket_priority.priority_color', 'u.first_name as first_name', 'u.last_name as last_name', 'u1.first_name as assign_first_name', 'u1.last_name as assign_last_name', - 'tickets.status', - 'tickets.user_id', + 'ticket_priority.priority_color', + DB::raw('COUNT(DISTINCT ticket_thread2.id) as countthread'), DB::raw('COUNT(ticket_attachment.thread_id) as countattachment'), DB::raw('COUNT(ticket_collaborator.ticket_id) as countcollaborator'), + 'tickets.status', + 'tickets.user_id', + 'tickets.priority_id', 'tickets.assigned_to', 'ticket_status.name as tickets_status', 'ticket_source.css_class as css', DB::raw('substring_index(group_concat(ticket_thread.poster order by ticket_thread.id desc) , ",", 1) as last_replier'), diff --git a/app/Http/Controllers/Agent/helpdesk/TicketController.php b/app/Http/Controllers/Agent/helpdesk/TicketController.php index 1749ccfb2..f828d5dc0 100644 --- a/app/Http/Controllers/Agent/helpdesk/TicketController.php +++ b/app/Http/Controllers/Agent/helpdesk/TicketController.php @@ -2218,6 +2218,9 @@ class TicketController extends Controller if ($count === 1) { $user_id = $user->id; $ticket = Tickets::where('id', '=', $id)->first(); + if ($user_id === (int) $ticket->user_id) { + return 400; + } $ticket_number = $ticket->ticket_number; $ticket->user_id = $user_id; $ticket->save(); @@ -2422,6 +2425,7 @@ class TicketController extends Controller $success = 0; } } + $this->sendMergeNotification($p_id, $t_id); return $success; } @@ -2896,4 +2900,32 @@ class TicketController extends Controller return $base64; } + + /** + *@category function to send notification of ticket merging to the owners + * + *@param srting array $t_id, $p_id + * + *@return null + */ + public function sendMergeNotification($p_id, $t_id) + { + try { + $ticket_details = Tickets::select('ticket_number', 'user_id', 'dept_id')->where('id', '=', $p_id)->first(); + $user_detail = User::where('id', '=', $ticket_details->user_id)->first(); + if ($user_detail->count() > 0) { + if ($user_detail->email !== null || $user_detail->email !== '') { + $meged_ticket_details = Tickets::select('ticket_number')->whereIn('id', $t_id)->get(); + $child_ticket_numbers = []; + foreach ($meged_ticket_details as $value) { + array_push($child_ticket_numbers, $value->ticket_number); + } + // dd(implode(", ",$child_ticket_numbers), $ticket_details->ticket_number); + $this->PhpMailController->sendmail($from = $this->PhpMailController->mailfrom('0', $ticket_details->dept_id), $to = ['user' => $user_detail->full_name, 'email' => $user_detail->email], $message = ['subject' => '', 'body' => '', 'scenario' => 'merge-ticket-notification'], $template_variables = ['user' => $user_detail->full_name, 'ticket_number' => $ticket_details->ticket_number, 'ticket_link' => route('ticket.thread', $p_id), 'merged_ticket_numbers' => implode(', ', $child_ticket_numbers)]); + } + } + } catch (\Exception $e) { + //catch the exception + } + } } diff --git a/app/Http/Controllers/Agent/helpdesk/UserController.php b/app/Http/Controllers/Agent/helpdesk/UserController.php index 9ba440655..ccc0a6896 100644 --- a/app/Http/Controllers/Agent/helpdesk/UserController.php +++ b/app/Http/Controllers/Agent/helpdesk/UserController.php @@ -32,6 +32,7 @@ use App\Model\helpdesk\Utility\Otp; use App\User; // classes use Auth; +use Datatables; use DateTime; use DB; use Exception; @@ -85,7 +86,6 @@ class UserController extends Controller Lang::get('lang.email'), Lang::get('lang.phone'), Lang::get('lang.status'), - Lang::get('lang.ban'), Lang::get('lang.last_login'), Lang::get('lang.role'), Lang::get('lang.action')) // these are the column headings to be shown @@ -116,21 +116,42 @@ class UserController extends Controller public function user_list(Request $request) { $type = $request->input('profiletype'); + $search = $request->input('searchTerm'); - if ($type == 'active') { - $users = User::where('role', '!=', 'admin')->where('is_delete', '=', 0)->get(); + if ($type === 'agents') { + $users = User::where('role', '=', 'agent')->where('is_delete', '=', 0); + } elseif ($type === 'users') { + $users = User::where('role', '=', 'user')->where('is_delete', '=', 0); + } elseif ($type === 'active-users') { + $users = User::where('role', '!=', 'admin')->where('active', '=', 1); + } elseif ($type === 'inactive') { + $users = User::where('role', '!=', 'admin')->where('active', '=', 0); + } elseif ($type === 'deleted') { + $users = User::where('role', '!=', 'admin')->where('is_delete', '=', 1); + } elseif ($type === 'banned') { + $users = User::where('role', '!=', 'admin')->where('ban', '=', 1); } else { - $users = User::where('role', '!=', 'admin')->where('is_delete', '=', 1)->get(); + $users = User::where('role', '!=', 'admin')->where('is_delete', '=', 0); } + $users = $users->select('user_name', 'email', 'mobile', 'active', 'updated_at', 'role', 'id', 'last_name', 'country_code', 'phone_number'); + + if ($search !== '') { + $users = $users->where(function ($query) use ($search) { + $query->where('user_name', 'LIKE', '%'.$search.'%'); + $query->orWhere('email', 'LIKE', '%'.$search.'%'); + $query->orWhere('first_name', 'LIKE', '%'.$search.'%'); + $query->orWhere('last_name', 'LIKE', '%'.$search.'%'); + $query->orWhere('mobile', 'LIKE', '%'.$search.'%'); + $query->orWhere('updated_at', 'LIKE', '%'.$search.'%'); + $query->orWhere('country_code', 'LIKE', '%'.$search.'%'); + }); + } // displaying list of users with chumper datatables // return \Datatable::collection(User::where('role', "!=", "admin")->get()) - return \Datatable::collection($users) - /* searchable column username and email */ - ->searchColumns('user_name', 'email', 'phone') - /* order column username and email */ - ->orderColumns('user_name', 'email') + return \Datatables::of($users) /* column username */ + ->removeColumn('id', 'last_name', 'country_code', 'phone_number') ->addColumn('user_name', function ($model) { if ($model->first_name) { $string = strip_tags($model->first_name.' '.$model->last_name); @@ -153,7 +174,7 @@ class UserController extends Controller return $email; }) /* column phone */ - ->addColumn('phone', function ($model) { + ->addColumn('mobile', function ($model) { $phone = ''; if ($model->phone_number) { $phone = $model->ext.' '.$model->phone_number; @@ -167,7 +188,7 @@ class UserController extends Controller return $phone; }) /* column account status */ - ->addColumn('status', function ($model) { + ->addColumn('active', function ($model) { $status = $model->active; if ($status == 1) { $stat = ''; @@ -177,19 +198,8 @@ class UserController extends Controller return $stat; }) - /* column ban status */ - ->addColumn('ban', function ($model) { - $status = $model->ban; - if ($status == 1) { - $stat = ''; - } else { - $stat = ''; - } - - return $stat; - }) /* column last login date */ - ->addColumn('lastlogin', function ($model) { + ->addColumn('updated_at', function ($model) { $t = $model->updated_at; return TicketController::usertimezone($t); @@ -1064,7 +1074,7 @@ class UserController extends Controller public function getAgentDetails() { - $users = User::where('role', '<>', 'user')->where('active', '=', 1)->get(); + $users = User::where('role', '<>', 'user')->where('active', '=', 1)->orderBy('first_name')->get(); foreach ($users as $user) { echo "'; } diff --git a/app/Http/Controllers/Auth/AuthController.php b/app/Http/Controllers/Auth/AuthController.php index 971ebc449..7692962c2 100644 --- a/app/Http/Controllers/Auth/AuthController.php +++ b/app/Http/Controllers/Auth/AuthController.php @@ -183,9 +183,11 @@ class AuthController extends Controller $message12 = ''; $settings = CommonSettings::select('status')->where('option_name', '=', 'send_otp')->first(); $sms = Plugin::select('status')->where('name', '=', 'SMS')->first(); - // Event for login - \Event::fire(new \App\Events\LoginEvent($request)); - $var = $this->PhpMailController->sendmail($from = $this->PhpMailController->mailfrom('1', '0'), $to = ['name' => $name, 'email' => $request->input('email')], $message = ['subject' => null, 'scenario' => 'registration'], $template_variables = ['user' => $name, 'email_address' => $request->input('email'), 'password_reset_link' => url('account/activate/'.$code)]); + // Event for login + \Event::fire(new \App\Events\LoginEvent($request)); + if ($request->input('email') !== '') { + $var = $this->PhpMailController->sendmail($from = $this->PhpMailController->mailfrom('1', '0'), $to = ['name' => $name, 'email' => $request->input('email')], $message = ['subject' => null, 'scenario' => 'registration'], $template_variables = ['user' => $name, 'email_address' => $request->input('email'), 'password_reset_link' => url('account/activate/'.$code)]); + } if ($settings->status == 1 || $settings->status == '1') { if (count($sms) > 0) { if ($sms->status == 1 || $sms->status == '1') { @@ -194,7 +196,11 @@ class AuthController extends Controller $message12 = Lang::get('lang.activate_your_account_click_on_Link_that_send_to_your_mail_sms_plugin_inactive_or_not_setup'); } } else { - $message12 = Lang::get('lang.activate_your_account_click_on_Link_that_send_to_your_mail'); + if ($request->input('email') !== '') { + $message12 = Lang::get('lang.activate_your_account_click_on_Link_that_send_to_your_mail'); + } else { + $message12 = Lang::get('lang.account-created-contact-admin-as-we-were-not-able-to-send-opt'); + } } } else { $message12 = Lang::get('lang.activate_your_account_click_on_Link_that_send_to_your_mail'); diff --git a/app/Http/Controllers/Client/helpdesk/FormController.php b/app/Http/Controllers/Client/helpdesk/FormController.php index 5c6d061df..d2afa550b 100644 --- a/app/Http/Controllers/Client/helpdesk/FormController.php +++ b/app/Http/Controllers/Client/helpdesk/FormController.php @@ -178,10 +178,13 @@ class FormController extends Controller $sla = $ticket_settings->first()->sla; // $priority = $ticket_settings->first()->priority; - $default_priority = Ticket_Priority::where('is_default', '=', 1)->first(); + $default_priority = Ticket_Priority::where('is_default', '=', 1)->first(); $user_priority = CommonSettings::where('option_name', '=', 'user_priority')->first(); if (!($request->input('priority'))) { $priority = $default_priority->priority_id; + if ($helpTopicObj->exists() && ($helpTopicObj->value('status') == 1)) { + $priority = $helpTopicObj->value('priority'); + } } else { $priority = $request->input('priority'); } @@ -189,6 +192,9 @@ class FormController extends Controller $attachments = $request->file('attachment'); $collaborator = null; $assignto = null; + if ($helpTopicObj->exists() && ($helpTopicObj->value('status') == 1)) { + $assignto = $helpTopicObj->value('auto_assign'); + } $auto_response = 0; $team_assign = null; if ($phone != null || $mobile_number != null) { diff --git a/app/Http/Controllers/Common/NotificationController.php b/app/Http/Controllers/Common/NotificationController.php index 1ab7058b1..8e77432ac 100644 --- a/app/Http/Controllers/Common/NotificationController.php +++ b/app/Http/Controllers/Common/NotificationController.php @@ -164,7 +164,7 @@ class NotificationController extends Controller }, 'notification.model' => function ($query) { $query->select('id', 'ticket_number'); }, - ]); + ])->where('user_id', '=', \Auth::user()->id); return $notifications; } diff --git a/app/Http/Controllers/Common/PhpMailController.php b/app/Http/Controllers/Common/PhpMailController.php index 015aa62cc..3432c50f5 100644 --- a/app/Http/Controllers/Common/PhpMailController.php +++ b/app/Http/Controllers/Common/PhpMailController.php @@ -115,7 +115,7 @@ class PhpMailController extends Controller $department_sign = $this->checkElement('department_sign', $template_variables); $password_reset_link = $this->checkElement('password_reset_link', $template_variables); $user_password = $this->checkElement('user_password', $template_variables); - + $merged_ticket_numbers = $this->checkElement('merged_ticket_numbers', $template_variables); $email_address = $this->checkElement('email_address', $template_variables); $user = $this->checkElement('user', $template_variables); @@ -145,9 +145,9 @@ class PhpMailController extends Controller $subject = null; } - $variables = ['{!!$user!!}', '{!!$agent!!}', '{!!$ticket_number!!}', '{!!$content!!}', '{!!$from!!}', '{!!$ticket_agent_name!!}', '{!!$ticket_client_name!!}', '{!!$ticket_client_email!!}', '{!!$ticket_body!!}', '{!!$ticket_assigner!!}', '{!!$ticket_link_with_number!!}', '{!!$system_error!!}', '{!!$agent_sign!!}', '{!!$department_sign!!}', '{!!$password_reset_link!!}', '{!!$email_address!!}', '{!!$user_password!!}', '{!!$system_from!!}', '{!!$system_link!!}', '{!!$ticket_link!!}']; + $variables = ['{!!$user!!}', '{!!$agent!!}', '{!!$ticket_number!!}', '{!!$content!!}', '{!!$from!!}', '{!!$ticket_agent_name!!}', '{!!$ticket_client_name!!}', '{!!$ticket_client_email!!}', '{!!$ticket_body!!}', '{!!$ticket_assigner!!}', '{!!$ticket_link_with_number!!}', '{!!$system_error!!}', '{!!$agent_sign!!}', '{!!$department_sign!!}', '{!!$password_reset_link!!}', '{!!$email_address!!}', '{!!$user_password!!}', '{!!$system_from!!}', '{!!$system_link!!}', '{!!$ticket_link!!}', '{!!$merged_ticket_numbers!!}']; - $data = [$user, $agent, $ticket_number, $content, $from, $ticket_agent_name, $ticket_client_name, $ticket_client_email, $ticket_body, $ticket_assigner, $ticket_link_with_number, $system_error, $agent_sign, $department_sign, $password_reset_link, $email_address, $user_password, $system_from, $system_link, $ticket_link]; + $data = [$user, $agent, $ticket_number, $content, $from, $ticket_agent_name, $ticket_client_name, $ticket_client_email, $ticket_body, $ticket_assigner, $ticket_link_with_number, $system_error, $agent_sign, $department_sign, $password_reset_link, $email_address, $user_password, $system_from, $system_link, $ticket_link, $merged_ticket_numbers]; foreach ($variables as $key => $variable) { $messagebody = str_replace($variables[$key], $data[$key], $contents); diff --git a/app/Http/ViewComposers/AgentLayout.php b/app/Http/ViewComposers/AgentLayout.php index df04bf23d..1fdef6059 100644 --- a/app/Http/ViewComposers/AgentLayout.php +++ b/app/Http/ViewComposers/AgentLayout.php @@ -150,9 +150,9 @@ class AgentLayout } return $table->Join('ticket_status', function ($join) { - $join->on('ticket_status.id', '=', 'tickets.status') + $join->on('ticket_status.id', '=', 'tickets.status') ->whereIn('ticket_status.id', [1, 7]); - }); + }); } public function overdues() diff --git a/app/Http/breadcrumbs.php b/app/Http/breadcrumbs.php index 5366a534e..cef4a36c6 100644 --- a/app/Http/breadcrumbs.php +++ b/app/Http/breadcrumbs.php @@ -426,10 +426,10 @@ Breadcrumbs::register('report.index', function ($breadcrumbs) { $breadcrumbs->push(Lang::get('lang.dashboard'), route('dashboard')); }); Breadcrumbs::register('home', function ($breadcrumbs) { - $breadcrumbs->push('Home', route('home')); + $breadcrumbs->push(Lang::get('lang.home'), route('home')); }); Breadcrumbs::register('/', function ($breadcrumbs) { - $breadcrumbs->push('Home', route('/')); + $breadcrumbs->push(Lang::get('lang.home'), route('/')); }); Breadcrumbs::register('form', function ($breadcrumbs) { $breadcrumbs->push('Create Ticket', route('form')); diff --git a/config/app.php b/config/app.php index 50867e651..185017670 100644 --- a/config/app.php +++ b/config/app.php @@ -33,7 +33,7 @@ return [ | This tells about aplication current version. | */ - 'version' => 'Community 1.9.0', + 'version' => 'Community 1.9.2', /* |-------------------------------------------------------------------------- | Application Name diff --git a/database/seeds/DatabaseSeeder.php b/database/seeds/DatabaseSeeder.php index d64053fe8..0fcb58623 100644 --- a/database/seeds/DatabaseSeeder.php +++ b/database/seeds/DatabaseSeeder.php @@ -1994,6 +1994,7 @@ class DatabaseSeeder extends Seeder TemplateType::create(['id' => '11', 'name' => 'registration']); TemplateType::create(['id' => '12', 'name' => 'team_assign_ticket']); TemplateType::create(['id' => '13', 'name' => 'reset_new_password']); + TemplateType::create(['id' => '14', 'name' => 'merge-ticket-notification']); Template::create(['id' => '1', 'variable' => '0', 'name' => 'This template is for sending notice to agent when ticket is assigned to them', 'type' => '1', 'message' => '
Hello {!!$ticket_agent_name!!},

Ticket No: {!!$ticket_number!!}
Has been assigned to you by {!!$ticket_assigner!!}
Please check and resppond on the ticket.
Link: {!!$ticket_link!!}

Thank You
Kind Regards,
{!!$system_from!!}
', 'set_id' => '1']); Template::create(['id' => '2', 'variable' => '1', 'name' => 'This template is for sending notice to client with ticket link to check ticket without logging in to system', 'type' => '2', 'subject' => 'Check your Ticket', 'message' => '
Hello {!!$user!!},

Click the link below to view your requested ticket
{!!$ticket_link_with_number!!}

Kind Regards,
{!!$system_from!!}
', 'set_id' => '1']); @@ -2008,6 +2009,7 @@ class DatabaseSeeder extends Seeder Template::create(['id' => '11', 'variable' => '1', 'name' => 'This template is for sending notice to client about registration confirmation link', 'type' => '11', 'subject' => 'Verify your email address', 'message' => '

Hello {!!$user!!}, 

This email is confirmation that you are now registered at our helpdesk.

Registered Email: {!!$email_address!!}

Please click on the below link to activate your account and Login to the system {!!$password_reset_link!!}

Thank You.

Kind Regards,

{!!$system_from!!} 

', 'set_id' => '1']); Template::create(['id' => '12', 'variable' => '1', 'name' => 'This template is for sending notice to team when ticket is assigned to team', 'type' => '12', 'message' => '
Hello {!!$ticket_agent_name!!},

Ticket No: {!!$ticket_number!!}
Has been assigned to your team : {!!$team!!} by {!!$ticket_assigner!!} 

Thank You
Kind Regards,
{!!$system_from!!}
', 'set_id' => '1']); Template::create(['id' => '13', 'variable' => '1', 'name' => 'This template is for sending notice to client when password is changed', 'type' => '13', 'subject' => 'Verify your email address', 'message' => 'Hello {!!$user!!},

Your password is successfully changed.Your new password is : {!!$user_password!!}

Thank You.

Kind Regards,
{!!$system_from!!}', 'set_id' => '1']); + Template::create(['id' => '14', 'variable' => '1', 'name' => 'This template is to notify users when their tickets are merged.', 'type' => '14', 'subject' => 'Your tickets have been merged.', 'message' => '

Hello {!!$user!!},
 

Your ticket(s) with ticket number {!!$merged_ticket_numbers!!} have been closed and merged with {!!$ticket_number!!}

Possible reasons for merging tickets

Click here to login to your account and check your tickets.

Regards,

{!!$system_from!!}

', 'set_id' => '1']); /* * All the common settings will be listed here diff --git a/public/downloads/en.zip b/public/downloads/en.zip index 990d04dc0..92e7528f9 100644 Binary files a/public/downloads/en.zip and b/public/downloads/en.zip differ diff --git a/release-notes.txt b/release-notes.txt index 01af93884..2cf728a7a 100644 --- a/release-notes.txt +++ b/release-notes.txt @@ -1,3 +1,38 @@ +|====================================================== +|v1.9.2 +|====================================================== + +Bug Fixes + Corrected notification counts + Fixed canned response error + Correct message for registration + Removed routes of PRO features + Exception handling while adding language + Showing agents in alphabetical order in various drop down menus + Handling the case when agent/admin adds same owner while changing ticket's owner + Fixed priority and auto assignment while creating ticket form cleint panel + Fixed typos in english language translation + Fixed counts of tickets of every categroy + Removed duplicate option from top nav bar + Fixed empty database check while installation + Assigning team leader in a team while creating new team + Fixed #361 + +Enhancements + + Sending email notfications to users while merging their duplicate tickets + Implemented Yajra in users table + Custom filter and search option in users table + Check if JavaScript is enabled or not while installation + Put max execution time and "mbstring" extension check while installation + + |======================================================== + | Upgrade giude + |======================================================== + + Follow this wiki article to upgrade your Faveo system + https://github.com/ladybirdweb/faveo-helpdesk/wiki/Upgrade-guide-for-v1.9.2 + |======================================================= | v1.9.1 |======================================================= diff --git a/resources/lang/de/lang.php b/resources/lang/de/lang.php index e2d90f32e..f7f610765 100644 --- a/resources/lang/de/lang.php +++ b/resources/lang/de/lang.php @@ -1146,4 +1146,16 @@ return [ 'delete-account-caution-info' => 'Please note this account may still have open tickets in the system.', 'reply-can-not-be-empty' => 'Reply can not be blank. Please enter your reply.', + //update 18-12-2016 + 'account-created-contact-admin-as-we-were-not-able-to-send-opt' => 'Your account has been created successfully. Please contact admin for account activation as we were not able to send you an OPT code.', + //update 19-12-2016 + 'only-agents' => 'Agent users', + 'only-users' => 'Clients users', + 'banned-users' => 'Banned users', + 'inactive-users' => 'Inactive users', + 'all-users' => 'All users', + 'search' => 'Search...', + //update 21-12-2016 + 'selected-user-is-already-the-owner' => 'Selected user is already the owner of this ticket.', + ]; diff --git a/resources/lang/en/lang.php b/resources/lang/en/lang.php index d96b13e49..2cefeee50 100644 --- a/resources/lang/en/lang.php +++ b/resources/lang/en/lang.php @@ -106,7 +106,7 @@ return [ */ 'i_know_my_password' => 'I know my password', 'recover_passord' => 'Recover password', - 'send_password_reset_link' => 'Send pasword reset link', + 'send_password_reset_link' => 'Send password reset link', 'enter_email_to_reset_password' => 'Enter email/mobile number to reset password', 'link' => 'Link', 'email_or_mobile' => 'Email or mobile', @@ -474,7 +474,7 @@ return [ 'default' => 'default', 'language-settings' => 'Language settings', 'iso-code' => 'ISO-CODE', - 'download' => 'Downlaod', + 'download' => 'Download', 'upload_file' => 'Upload file', 'enter_iso-code' => 'Enter ISO code', 'eg.' => 'Example', @@ -493,8 +493,8 @@ return [ 'delete-success' => 'Language package deleted successfully.', 'lang-doesnot-exist' => 'Language package does not exist.', 'active-lang-error' => 'Language package can not be deleted when it is active.', - 'language-error' => 'Language package not found in your lang directroy.', - 'lang-fallback-lang' => 'Cannot delete system\'s defualt fallback language', + 'language-error' => 'Language package not found in your lang directory.', + 'lang-fallback-lang' => 'Can not delete system\'s defualt fallback language', /* |-------------------------------------- @@ -550,7 +550,7 @@ return [ 'SLA_plan' => 'SLA plan', 'sla-plans' => 'SLA plans', 'auto_assign' => 'Auto assign', - 'auto_respons' => 'Auto respons', + 'auto_respons' => 'Auto response', 'ticket_number_format' => 'Ticket number format', 'system_default' => 'System default', 'custom' => 'Custom', @@ -807,7 +807,7 @@ return [ 'outgoing_emails' => 'Outgoing emails', 'outgoing_email' => 'Outgoing email', 'template_set' => 'Template set', - 'auto_responding_settings' => 'Auto-Responding settigs', + 'auto_responding_settings' => 'Auto-Responding settings', 'disable_for_this_department' => 'Disable for this department', 'auto_response_email' => 'Auto-Response email', 'recipient' => 'Recipient', @@ -819,14 +819,14 @@ return [ 'edit_department' => 'Edit department', 'select_a_sla' => 'Select a SLA', 'select_a_manager' => 'Select a manager', - 'department_created_sucessfully' => 'Department created sucessfully', + 'department_created_sucessfully' => 'Department created successfully', 'failed_to_create_department' => 'Failed to create department', - 'department_updated_sucessfully' => 'Department updated sucessfully', + 'department_updated_sucessfully' => 'Department updated successfully', 'department_not_updated' => 'Department not updated', 'you_cannot_delete_default_department' => 'You cannot delete default department', 'have_been_moved_to_default_department' => 'have been moved to default department', 'the_associated_helptopic_has_been_deactivated' => 'The associated helptopic has been deactivated', - 'department_deleted_sucessfully' => 'Department deleted sucessfully', + 'department_deleted_sucessfully' => 'Department deleted successfully', 'department_can_not_delete' => 'Department can not be deleted', 'select_a_department' => 'Select a department', 'make-default-department' => 'Make system\'s default department', @@ -1104,7 +1104,7 @@ return [ 'submit' => 'Submit', 'max' => 'Maximum file size', 'add_cc' => 'Add CC', - 'recepients' => 'Recepients', + 'recepients' => 'Recipients', 'select_a_canned_response' => 'Select a canned response', 'assign_to' => 'Assign to', 'detail' => 'Detail', @@ -1118,7 +1118,7 @@ return [ 'minutes' => ' minutes', 'in_minutes' => 'In minutes', 'add_another_owner' => 'Add another owner', - 'user-not-found' => 'User not found. Try again or add a new user.', + 'user-not-found' => 'User not found or user is inactive. Try again or add a new user.', 'change-success' => 'Success! owner has been changed for this ticket.', 'user-exists' => 'User already exists. Try search existing user.', 'valid-email' => 'Enter a valid email address.', @@ -1137,7 +1137,7 @@ return [ 'merge-success' => 'Tickets have been merged successfully.', 'merge-error2' => 'Please select ticket to merge.', 'select-tickets-to merge' => 'Select two or more tickets to merge.', - 'different-users' => 'Ticktes from different users', + 'different-users' => 'Selected tickets are from different users', 'clean-up' => 'Delete forever', 'hard-delete-success-message' => 'Tickets have been deleted permanently.', 'overdue' => 'Overdue', @@ -1364,11 +1364,11 @@ return [ 'Send' => 'SEND', 'no_article' => 'No article', 'profile_settings' => 'Profile settings', - 'please_fill_all_required_feilds' => 'Please fill all required feilds.', + 'please_fill_all_required_feilds' => 'Please fill all required fields.', 'successfully_replied' => 'Successfully replied', 'please_fill_some_data' => 'Please fill some data!', 'profile_updated_sucessfully' => 'Profile updated sucessfully', - 'password_updated_sucessfully' => 'Password updated sucessfully', + 'password_updated_sucessfully' => 'Password updated successfully', 'password_was_not_updated_incorrect_old_password' => 'Password was not updated. Incorrect old password', 'there_is_no_such_ticket_number' => 'There is no such ticket number', "email_didn't_match_with_ticket_number" => "Email didn't match with ticket number", @@ -1546,9 +1546,9 @@ return [ 'change_password' => 'Change password', 'role_change' => 'Role change', 'password_generator' => 'Password generator', - 'depertment' => 'Depertment', + 'depertment' => 'Department', 'duetoday' => 'Due today', - 'today-due_tickets' => 'Today\'s due ticekts', + 'today-due_tickets' => 'Today\'s due tickets', 'password_change_successfully' => 'Password changed successfully', 'role_change_successfully' => 'Role changed successfully', 'user_delete_successfully' => 'User deleted successfully', @@ -1583,4 +1583,15 @@ return [ 'delete-account-caution-info' => 'Please note this account may still have open tickets in the system.', 'reply-can-not-be-empty' => 'Reply can not be blank. Please enter your reply.', + //update 18-12-2016 + 'account-created-contact-admin-as-we-were-not-able-to-send-opt' => 'Your account has been created successfully. Please contact admin for account activation as we were not able to send you an OTP code.', + //update 19-12-2016 + 'only-agents' => 'Agent users', + 'only-users' => 'Clients users', + 'banned-users' => 'Banned users', + 'inactive-users' => 'Inactive users', + 'all-users' => 'All users', + 'search' => 'Search...', + //update 21-12-2016 + 'selected-user-is-already-the-owner' => 'Selected user is already the owner of this ticket.', ]; diff --git a/resources/lang/fr/lang.php b/resources/lang/fr/lang.php index 2df9999b9..e3b5c8cf4 100644 --- a/resources/lang/fr/lang.php +++ b/resources/lang/fr/lang.php @@ -1554,4 +1554,16 @@ return [ 'delete-account-caution-info' => 'Please note this account may still have open tickets in the system.', 'reply-can-not-be-empty' => 'Reply can not be blank. Please enter your reply.', + //update 18-12-2016 + 'account-created-contact-admin-as-we-were-not-able-to-send-opt' => 'Your account has been created successfully. Please contact admin for account activation as we were not able to send you an OPT code.', + //update 19-12-2016 + 'only-agents' => 'Agent users', + 'only-users' => 'Clients users', + 'banned-users' => 'Banned users', + 'inactive-users' => 'Inactive users', + 'all-users' => 'All users', + 'search' => 'Search...', + //update 21-12-2016 + 'selected-user-is-already-the-owner' => 'Selected user is already the owner of this ticket.', + ]; diff --git a/resources/lang/it/lang.php b/resources/lang/it/lang.php index 40bb8faaf..aa4fc7cc3 100644 --- a/resources/lang/it/lang.php +++ b/resources/lang/it/lang.php @@ -1105,4 +1105,16 @@ return [ 'restore-user' => 'Restore user account', 'delete-account-caution-info' => 'Please note this account may still have open tickets in the system.', 'reply-can-not-be-empty' => 'Reply can not be blank. Please enter your reply.', + + //update 18-12-2016 + 'account-created-contact-admin-as-we-were-not-able-to-send-opt' => 'Your account has been created successfully. Please contact admin for account activation as we were not able to send you an OPT code.', + //update 19-12-2016 + 'only-agents' => 'Agent users', + 'only-users' => 'Clients users', + 'banned-users' => 'Banned users', + 'inactive-users' => 'Inactive users', + 'all-users' => 'All users', + 'search' => 'Search...', + //update 21-12-2016 + 'selected-user-is-already-the-owner' => 'Selected user is already the owner of this ticket.', ]; diff --git a/resources/lang/nl/lang.php b/resources/lang/nl/lang.php index 34c6e13ce..4ab5bce4c 100644 --- a/resources/lang/nl/lang.php +++ b/resources/lang/nl/lang.php @@ -1599,4 +1599,16 @@ return [ 'delete-account-caution-info' => 'Please note this account may still have open tickets in the system.', 'reply-can-not-be-empty' => 'Reply can not be blank. Please enter your reply.', + //update 18-12-2016 + 'account-created-contact-admin-as-we-were-not-able-to-send-opt' => 'Your account has been created successfully. Please contact admin for account activation as we were not able to send you an OPT code.', + + //update 19-12-2016 + 'only-agents' => 'Agent users', + 'only-users' => 'Clients users', + 'banned-users' => 'Banned users', + 'inactive-users' => 'Inactive users', + 'all-users' => 'All users', + 'search' => 'Search...', + //update 21-12-2016 + 'selected-user-is-already-the-owner' => 'Selected user is already the owner of this ticket.', ]; diff --git a/resources/lang/pt/lang.php b/resources/lang/pt/lang.php index fed5c3db7..79a0ec520 100644 --- a/resources/lang/pt/lang.php +++ b/resources/lang/pt/lang.php @@ -1544,4 +1544,17 @@ return [ 'delete-account-caution-info' => 'Please note this account may still have open tickets in the system.', 'reply-can-not-be-empty' => 'Reply can not be blank. Please enter your reply.', + //update 18-12-2016 + 'account-created-contact-admin-as-we-were-not-able-to-send-opt' => 'Your account has been created successfully. Please contact admin for account activation as we were not able to send you an OPT code.', + + //update 19-12-2016 + 'only-agents' => 'Agent users', + 'only-users' => 'Clients users', + 'banned-users' => 'Banned users', + 'inactive-users' => 'Inactive users', + 'all-users' => 'All users', + 'search' => 'Search...', + //update 21-12-2016 + 'selected-user-is-already-the-owner' => 'Selected user is already the owner of this ticket.', + ]; diff --git a/resources/lang/ru/lang.php b/resources/lang/ru/lang.php index df3ffe5c0..e6a4ae651 100644 --- a/resources/lang/ru/lang.php +++ b/resources/lang/ru/lang.php @@ -1052,4 +1052,17 @@ return [ 'restore-user' => 'Restore user account', 'delete-account-caution-info' => 'Please note this account may still have open tickets in the system.', 'reply-can-not-be-empty' => 'Reply can not be blank. Please enter your reply.', + + //update 18-12-2016 + 'account-created-contact-admin-as-we-were-not-able-to-send-opt' => 'Your account has been created successfully. Please contact admin for account activation as we were not able to send you an OPT code.', + + //update 19-12-2016 + 'only-agents' => 'Agent users', + 'only-users' => 'Clients users', + 'banned-users' => 'Banned users', + 'inactive-users' => 'Inactive users', + 'all-users' => 'All users', + 'search' => 'Search...', + //update 21-12-2016 + 'selected-user-is-already-the-owner' => 'Selected user is already the owner of this ticket.', ]; diff --git a/resources/views/themes/default1/admin/helpdesk/agent/teams/create.blade.php b/resources/views/themes/default1/admin/helpdesk/agent/teams/create.blade.php index a906686ef..dca50dfbb 100644 --- a/resources/views/themes/default1/admin/helpdesk/agent/teams/create.blade.php +++ b/resources/views/themes/default1/admin/helpdesk/agent/teams/create.blade.php @@ -61,7 +61,6 @@ class="active"
{!! Form::label('team_lead',Lang::get('lang.team_lead')) !!} - orWhere('role', 'agent')->get(); ?> {!! Form::select('team_lead',[''=>Lang::get('lang.select_a_team_lead'), Lang::get('lang.members')=>$user->lists('full_name','id')->toArray()],null,['class' => 'form-control']) !!}
diff --git a/resources/views/themes/default1/admin/helpdesk/agent/teams/edit.blade.php b/resources/views/themes/default1/admin/helpdesk/agent/teams/edit.blade.php index c835b58db..2401f0cc7 100644 --- a/resources/views/themes/default1/admin/helpdesk/agent/teams/edit.blade.php +++ b/resources/views/themes/default1/admin/helpdesk/agent/teams/edit.blade.php @@ -60,7 +60,6 @@ class="active"
{!! Form::label('team_lead',Lang::get('lang.team_lead')) !!} - orWhere('role', 'agent')->get(); ?> {!! Form::select('team_lead',[''=>Lang::get('lang.select_a_team_lead'), Lang::get('lang.members')=>$user->lists('full_name','id')->toArray()],null,['class' => 'form-control']) !!}
diff --git a/resources/views/themes/default1/admin/helpdesk/manage/helptopic/create.blade.php b/resources/views/themes/default1/admin/helpdesk/manage/helptopic/create.blade.php index 319f40607..46419ceff 100644 --- a/resources/views/themes/default1/admin/helpdesk/manage/helptopic/create.blade.php +++ b/resources/views/themes/default1/admin/helpdesk/manage/helptopic/create.blade.php @@ -137,7 +137,7 @@ class="active"
{!! Form::label('auto_assign',Lang::get('lang.auto_assign')) !!} - {!!Form::select('auto_assign', [''=>Lang::get('lang.select_an_agent'),Lang::get('lang.agents')=>$agents->lists('first_name','id')->toArray()],null,['class' => 'form-control']) !!} + {!!Form::select('auto_assign', [''=>Lang::get('lang.select_an_agent'),Lang::get('lang.agents')=>$agents->lists('full_name','id')->toArray()],null,['class' => 'form-control']) !!}
diff --git a/resources/views/themes/default1/admin/helpdesk/manage/helptopic/edit.blade.php b/resources/views/themes/default1/admin/helpdesk/manage/helptopic/edit.blade.php index a7da41666..36f8707de 100644 --- a/resources/views/themes/default1/admin/helpdesk/manage/helptopic/edit.blade.php +++ b/resources/views/themes/default1/admin/helpdesk/manage/helptopic/edit.blade.php @@ -135,7 +135,7 @@ class="active"
{!! Form::label('auto_assign',Lang::get('lang.auto_assign')) !!} - {!!Form::select('auto_assign', [''=>Lang::get('lang.select_an_agent'),Lang::get('lang.agents')=>$agents->lists('first_name','id')->toArray()],null,['class' => 'form-control']) !!} + {!!Form::select('auto_assign', [''=>Lang::get('lang.select_an_agent'),Lang::get('lang.agents')=>$agents->lists('full_name','id')->toArray()],null,['class' => 'form-control']) !!}
diff --git a/resources/views/themes/default1/admin/helpdesk/settings/plugins.blade.php b/resources/views/themes/default1/admin/helpdesk/settings/plugins.blade.php index 65cd34bca..138d61143 100644 --- a/resources/views/themes/default1/admin/helpdesk/settings/plugins.blade.php +++ b/resources/views/themes/default1/admin/helpdesk/settings/plugins.blade.php @@ -54,6 +54,11 @@ class="active"
+
+ + {!! Lang::get('lang.plugin-info') !!}
+ {!!Lang::get('lang.click-here')!!} {!!Lang::get('lang.plugin-info-pro')!!} +
@if (count($errors) > 0)
diff --git a/resources/views/themes/default1/admin/layout/admin.blade.php b/resources/views/themes/default1/admin/layout/admin.blade.php index 6715f0df6..bf6c51e1e 100644 --- a/resources/views/themes/default1/admin/layout/admin.blade.php +++ b/resources/views/themes/default1/admin/layout/admin.blade.php @@ -278,7 +278,6 @@
  • {!! Lang::get('lang.auto_response') !!}
  • {!! Lang::get('lang.alert_notices') !!}
  • {!! Lang::get('lang.status') !!}
  • -
  • {!! Lang::get('lang.labels') !!}
  • {!! Lang::get('lang.ratings') !!}
  • {!! Lang::get('lang.close-workflow') !!}
  • @@ -297,7 +296,7 @@
  • {!! Lang::get('lang.cron') !!}
  • {!! Lang::get('lang.security') !!}
  • {!! Lang::get('lang.notifications') !!}
  • -
  • {!! Lang::get('lang.approval') !!}
  • +
  • {!! Lang::get('storage::lang.storage') !!}
  • diff --git a/resources/views/themes/default1/agent/helpdesk/dashboard/dashboard.blade.php b/resources/views/themes/default1/agent/helpdesk/dashboard/dashboard.blade.php index 413abe043..3cec0bf17 100644 --- a/resources/views/themes/default1/agent/helpdesk/dashboard/dashboard.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/dashboard/dashboard.blade.php @@ -38,9 +38,6 @@ class="active" {{-- --}}
    -
    @@ -75,18 +72,8 @@ class="active"
    - - role == 'admin') { - $overdue_ticket = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('tickets.duedate','<', \Carbon\Carbon::now())->count(); - } else { - $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $overdue_ticket = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('tickets.duedate','<', \Carbon\Carbon::now())->where('dept_id', '=', $dept->id)->count(); - } - ?> - {!! Lang::get('lang.overdue') !!} - {{ $overdue_ticket }} Tickets + {{ $overdues->count() }} Tickets
    diff --git a/resources/views/themes/default1/agent/helpdesk/dept-ticket/tickets.blade.php b/resources/views/themes/default1/agent/helpdesk/dept-ticket/tickets.blade.php index 14fb6a50d..ff88f6abc 100644 --- a/resources/views/themes/default1/agent/helpdesk/dept-ticket/tickets.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/dept-ticket/tickets.blade.php @@ -45,17 +45,15 @@ class="active" $date_time_format = UTC::getDateTimeFormat(); if (Auth::user()->role == 'agent') { $dept = App\Model\helpdesk\Agent\Department::select('id', 'name')->where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::whereIn('status', array(1, 7))->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->paginate(20); $dept_name = $dept->name; } else { $dept_name = \Request::segments()[1]; - $tickets = App\Model\helpdesk\Ticket\Tickets::whereIn('status', array(1, 7))->orderBy('id', 'DESC')->paginate(20); } ?>
    -

    {!! $dept_name !!} / {!! $status !!}

    {!! $tickets->total() !!} {!! Lang::get('lang.tickets') !!} +

    {!! $dept_name !!} / {!! $status !!}

    diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/answered.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/answered.blade.php index 1ff95fbfd..531dcc6e2 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/answered.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/answered.blade.php @@ -46,15 +46,15 @@ class="active" $date_time_format = UTC::getDateTimeFormat(); if (Auth::user()->role == 'agent') { $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 1)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 1)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->count(); } else { - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 1)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 1)->orderBy('id', 'DESC')->count(); } ?>
    -

    {!! Lang::get('lang.answered') !!}

    {!! $tickets->total() !!} {!! Lang::get('lang.tickets') !!} +

    {!! Lang::get('lang.answered') !!}

    {!! $tickets !!} {!! Lang::get('lang.tickets') !!}
    diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/assigned.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/assigned.blade.php index 40faa1ae4..d0f7c0dbd 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/assigned.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/assigned.blade.php @@ -46,15 +46,15 @@ class="active" $date_time_format = UTC::getDateTimeFormat(); if (Auth::user()->role == 'agent') { $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '>', 0)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '>', 0)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->count(); } else { - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '>', 0)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '>', 0)->orderBy('id', 'DESC')->count(); } ?>
    -

    {!! Lang::get('lang.assigned') !!}

    {!! $tickets->total() !!} {!! Lang::get('lang.tickets') !!} +

    {!! Lang::get('lang.assigned') !!}

    {!! $tickets !!} {!! Lang::get('lang.tickets') !!}
    @if(Session::has('success')) diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/closed.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/closed.blade.php index 5665bab35..8697a33da 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/closed.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/closed.blade.php @@ -46,15 +46,15 @@ class="active" $date_time_format = UTC::getDateTimeFormat(); if (Auth::user()->role == 'agent') { $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '>', 1)->where('dept_id', '=', $dept->id)->where('status', '<', 4)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '>', 1)->where('dept_id', '=', $dept->id)->where('status', '<', 4)->orderBy('id', 'DESC')->count(); } else { - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '>', 1)->where('status', '<', 4)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '>', 1)->where('status', '<', 4)->orderBy('id', 'DESC')->count(); } ?>
    -

    {!! Lang::get('lang.closed') !!}

    {!! $tickets->total() !!} {!! Lang::get('lang.tickets') !!} +

    {!! Lang::get('lang.closed') !!}

    {!! $tickets !!} {!! Lang::get('lang.tickets') !!}
    @if(Session::has('success')) diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/duetodayticket.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/duetodayticket.blade.php index 6c646ab46..e0fc82183 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/duetodayticket.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/duetodayticket.blade.php @@ -48,23 +48,14 @@ class="active" $todaytickets = count(App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->whereRaw('date(duedate) = ?', [date('Y-m-d')])->get()); } else { $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $todaytickets = count(App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->whereRaw('date(duedate) = ?', [date('Y-m-d')])->where('dept_id', '=', $dept->id)->get()); + $todaytickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->whereRaw('date(duedate) = ?', [date('Y-m-d')])->where('dept_id', '=', $dept->id)->count(); } ?> -role == 'agent') { - $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->paginate(20); -} else { - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->orderBy('id', 'DESC')->paginate(20); -} -?>
    -

    {!! Lang::get('lang.open') !!}

    {!! $todaytickets !!} {!! Lang::get('lang.tickets') !!} +

    {!! Lang::get('lang.duetoday') !!}

    {!! $todaytickets !!} {!! Lang::get('lang.tickets') !!}
    diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/inbox.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/inbox.blade.php index a700033d0..e644c5fee 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/inbox.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/inbox.blade.php @@ -45,15 +45,15 @@ class="active" $date_time_format = UTC::getDateTimeFormat(); if (Auth::user()->role == 'agent') { $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::whereIn('status', array(1, 7))->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::whereIn('status', array(1, 7))->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->count(); } else { - $tickets = App\Model\helpdesk\Ticket\Tickets::whereIn('status', array(1, 7))->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::whereIn('status', array(1, 7))->orderBy('id', 'DESC')->count(); } ?>
    -

    {!! Lang::get('lang.inbox') !!}

    {!! $tickets->total() !!} {!! Lang::get('lang.tickets') !!} +

    {!! Lang::get('lang.inbox') !!}

    {!! $tickets !!} {!! Lang::get('lang.tickets') !!}
    diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/myticket.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/myticket.blade.php index 84846f332..72e2998c0 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/myticket.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/myticket.blade.php @@ -44,15 +44,15 @@ class="active" $date_time_format = UTC::getDateTimeFormat(); if (Auth::user()->role == 'agent') { $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '=', Auth::user()->id)->orderBy('id', 'ASC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '=', Auth::user()->id)->orderBy('id', 'ASC')->count(); } else { - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '=', Auth::user()->id)->orderBy('id', 'ASC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '=', Auth::user()->id)->orderBy('id', 'ASC')->count(); } ?>
    -

    {!! Lang::get('lang.my_tickets') !!}

    {!! $tickets->total() !!} {!! Lang::get('lang.tickets') !!} +

    {!! Lang::get('lang.my_tickets') !!}

    {!! $tickets !!} {!! Lang::get('lang.tickets') !!}
    diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/open.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/open.blade.php index 28cbb9466..627ddc735 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/open.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/open.blade.php @@ -46,15 +46,15 @@ class="active" $date_time_format = UTC::getDateTimeFormat(); if (Auth::user()->role == 'agent') { $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->count(); } else { - $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->orderBy('id', 'DESC')->paginate(20); + $tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->orderBy('id', 'DESC')->count(); } ?>
    -

    {!! Lang::get('lang.open') !!}

    {!! $tickets->total() !!} {!! Lang::get('lang.tickets') !!} +

    {!! Lang::get('lang.open') !!}

    {!! $tickets !!} {!! Lang::get('lang.tickets') !!}
    diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/overdue.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/overdue.blade.php index 37e16b856..1bd289111 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/overdue.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/overdue.blade.php @@ -41,38 +41,20 @@ class="active" @stop @section('content') role == 'agent') { -// $dept = \App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); -// $overdues = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->where('dept_id', '=', $dept->id)->orderBy('id', 'DESC')->get(); -// } else { -// $overdues = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('isanswered', '=', 0)->orderBy('id', 'DESC')->get(); -// } -// $i = count($overdues); -// if ($i == 0) { -// $overdue_ticket = 0; -// } else { -// $j = 0; -// foreach ($overdues as $overdue) { -// $sla_plan = App\Model\helpdesk\Manage\Sla_plan::where('id', '=', $overdue->sla)->first(); -// $ovadate = $overdue->created_at; -// $new_date = date_add($ovadate, date_interval_create_from_date_string($sla_plan->grace_period)) . '

    '; -// if (date('Y-m-d H:i:s') > $new_date) { -// $j++; -// //$value[] = $overdue; -// } -// } -// // dd(count($value)); -// if ($j > 0) { -// $overdue_ticket = $j; -// } else { -// $overdue_ticket = 0; -// } -// } - $overdue_ticket=App\Model\helpdesk\Ticket\Tickets::where('tickets.duedate','<', \Carbon\Carbon::now())->count(); + $otickets = App\Model\helpdesk\Ticket\Tickets::where('tickets.status', '=', 1) + ->where('tickets.isanswered', '=', 0) + ->whereNotNull('tickets.duedate') + ->where('tickets.duedate', '!=', '00-00-00 00:00:00') + // ->where('duedate','>',\Carbon\Carbon::now()); + ->where('tickets.duedate', '<', \Carbon\Carbon::now()); + if (\Auth::user()->role === 'agent') { + $dept = App\Model\helpdesk\Agent\Department::where('id', '=', Auth::user()->primary_dpt)->first(); + $otickets = $otickets->where('dept_id', '=', $dept->id); + } + $overdue_ticket = $otickets->count(); ?> diff --git a/resources/views/themes/default1/agent/helpdesk/ticket/timeline.blade.php b/resources/views/themes/default1/agent/helpdesk/ticket/timeline.blade.php index a9a0ab028..a3508c1ca 100644 --- a/resources/views/themes/default1/agent/helpdesk/ticket/timeline.blade.php +++ b/resources/views/themes/default1/agent/helpdesk/ticket/timeline.blade.php @@ -397,14 +397,14 @@ if ($thread->title != "") {
    - id)->get(); ?> @foreach($canneds as $canned) - + @endforeach {{-- --}} @@ -948,7 +948,7 @@ alert(h+20);
    +
    -
    +
    Export diff --git a/resources/views/themes/default1/agent/layout/agent.blade.php b/resources/views/themes/default1/agent/layout/agent.blade.php index 052388d57..6f032b588 100644 --- a/resources/views/themes/default1/agent/layout/agent.blade.php +++ b/resources/views/themes/default1/agent/layout/agent.blade.php @@ -320,7 +320,7 @@ where('group_status', '=', '1')->first(); +$group = App\Model\helpdesk\Agent\Groups::where('id', '=', $agent_group)->first(); ?>
    @@ -344,10 +344,6 @@ $group = App\Model\helpdesk\Agent\Groups::where('id', '=', $agent_group)->where(
    - +
    +
    +
    + {!! Form::close() !!} +
    {{Lang::get('lang.or')}}
    diff --git a/resources/views/themes/default1/installer/helpdesk/check-js.blade.php b/resources/views/themes/default1/installer/helpdesk/check-js.blade.php index aa44a40fb..b16f7b07e 100644 --- a/resources/views/themes/default1/installer/helpdesk/check-js.blade.php +++ b/resources/views/themes/default1/installer/helpdesk/check-js.blade.php @@ -9,11 +9,12 @@ active
    JavaScript Disabled!
    -

    Hello, Sparky! You are just few steps away from your support system. It looks like that JavaScript is disabled in your browser or not supported by your browser. FAVEO doesn't work properly without JavaScript, and it may cause errors in installation. Please check and enable JavaScript in your browser in order to install and run FAVEO to its full extent.

    -
    -

    - +

    Hello, Sparky! You are just a few steps away from your support system. It looks like that JavaScript is disabled in your browser or not supported by your browser. FAVEO doesn't work properly without JavaScript, and it may cause errors in installation. Please check and enable JavaScript in your browser in order to install and run FAVEO to its full extent.

    +

    + Have you enabled JavaScript?  + Click here to reload the page now.

    +
    diff --git a/resources/views/themes/default1/installer/helpdesk/view2.blade.php b/resources/views/themes/default1/installer/helpdesk/view2.blade.php index 37c0da96f..4d4ec1f51 100644 --- a/resources/views/themes/default1/installer/helpdesk/view2.blade.php +++ b/resources/views/themes/default1/installer/helpdesk/view2.blade.php @@ -12,37 +12,7 @@ active @section('content') - - - - $value) { -// // # code... -// // } -// if (strpos($to_check, $statement) !== false) { -// return true; -// } else { -// return false; -// } -?> - -
    +

    Environment Test

    @if (Session::has('fail_to_change'))
    @@ -208,7 +178,7 @@ function validate_zend_compatibility_mode(&$results) { function validate_extensions(&$results) { $ok = true; - $required_extensions = array('mcrypt', 'openssl', 'pdo', 'fileinfo', 'curl', 'zip'); + $required_extensions = array('mcrypt', 'openssl', 'pdo', 'fileinfo', 'curl', 'zip', 'mbstring'); foreach ($required_extensions as $required_extension) { if (extension_loaded($required_extension)) { @@ -277,6 +247,16 @@ function checkDisabledFunctions(&$results) { return $ok; } +function checkMaxExecutiontime(&$results) +{ + $ok = true; + if ((int)ini_get('max_execution_time') >= 120) { + $results[] = new TestResult("Maximum execution time is as per requirement.", STATUS_OK); + } else { + $results[] = new TestResult("Maximum execution time is too low. Recommneded execution time is 120 seconds ", STATUS_WARNING); + } + return $ok; +} // --------------------------------------------------- // Do the magic // --------------------------------------------------- @@ -288,6 +268,7 @@ $memory_ok = validate_memory_limit($results); $extensions_ok = validate_extensions($results); $file_permission = checkFilePermission($results); $required_functions = checkDisabledFunctions($results); +$check_execution_time = checkMaxExecutiontime($results); ?>

    diff --git a/resources/views/themes/default1/installer/layout/installer2.blade.php b/resources/views/themes/default1/installer/layout/installer2.blade.php new file mode 100644 index 000000000..e48ef80ab --- /dev/null +++ b/resources/views/themes/default1/installer/layout/installer2.blade.php @@ -0,0 +1,63 @@ + + + + + + Faveo HELPDESK + + + + + + + + + + + + + + +

    + faveo

    + +
    + @yield('content') +
    + + +

    Copyright © 2015 - · Ladybird Web Solution Pvt Ltd. All Rights Reserved. Powered by Faveo

    + + + + + + + + + + + + \ No newline at end of file diff --git a/resources/views/vendor/Chumper/user-javascript.blade.php b/resources/views/vendor/Chumper/user-javascript.blade.php index fd79a2be8..f1f55b214 100644 --- a/resources/views/vendor/Chumper/user-javascript.blade.php +++ b/resources/views/vendor/Chumper/user-javascript.blade.php @@ -7,8 +7,9 @@ foreach($segments as $seg){ ?> \ No newline at end of file diff --git a/storage/5948.logo (1).png b/storage/5948.logo (1).png deleted file mode 100644 index be208e255..000000000 Binary files a/storage/5948.logo (1).png and /dev/null differ diff --git a/storage/framework/schedule-0fc9543999976ea67163c202f07106ac6b5d4ee5 b/storage/framework/schedule-0fc9543999976ea67163c202f07106ac6b5d4ee5 deleted file mode 100644 index e69de29bb..000000000 diff --git a/storage/framework/schedule-7ac1bfcc9d3826bdef602559e20d96a860abcbf8 b/storage/framework/schedule-7ac1bfcc9d3826bdef602559e20d96a860abcbf8 deleted file mode 100644 index e69de29bb..000000000 diff --git a/storage/framework/schedule-8b8857ebecf54136e0e5448c79a33366a761a976 b/storage/framework/schedule-8b8857ebecf54136e0e5448c79a33366a761a976 deleted file mode 100644 index e69de29bb..000000000 diff --git a/storage/localhost _ 127.0.0.1 _ pro-fork _ filters _ phpMyAdmin 4.4.11.html b/storage/localhost _ 127.0.0.1 _ pro-fork _ filters _ phpMyAdmin 4.4.11.html deleted file mode 100644 index 94747cf6f..000000000 --- a/storage/localhost _ 127.0.0.1 _ pro-fork _ filters _ phpMyAdmin 4.4.11.html +++ /dev/null @@ -1,172 +0,0 @@ - - -localhost / 127.0.0.1 / pro-fork / filters | phpMyAdmin 4.4.11
    Favorites
    • X
    Drop files here

    SQL upload ( 0 ) x-

    -Click on the bar to scroll to top of page
    Options
    Set default



    Collapse Expand Requery Edit Explain Profiling Query failed Database: Queried time:
    - - - - - - -
    Run SQL query/queries on database pro-fork: Documentation
    x
    54
    select 
     
    32
        `label`.`value` as `label_values`, 
    33
        `tag`.`value` as `tag_values` 
    34
    from 
    35
        `tickets` 
    36
        left join `ticket_thread` on `tickets`.`id` = `ticket_thread`.`ticket_id` 
    37
        and `title` is not null 
    38
        and `ticket_thread`.`is_internal` <> ? 
    39
        inner join `ticket_status` on `ticket_status`.`id` = `tickets`.`status` 
    40
        and `ticket_status`.`id` in (?, ?) 
    41
        inner join `ticket_source` on `ticket_source`.`id` = `tickets`.`source` 
    42
        left join `ticket_priority` on `ticket_priority`.`priority_id` = `tickets`.`priority_id` 
    43
        left join `users` as `u` on `u`.`id` = `tickets`.`user_id` 
    44
        left join `users` as `u1` on `u1`.`id` = `tickets`.`assigned_to` 
    45
        left join `ticket_attachment` on `ticket_attachment`.`thread_id` = `ticket_thread`.`id` 
    46
        left join `filters` as `label` on `tickets`.`id` = `label`.`ticket_id` 
    47
        and `label`.`key` = ? 
    48
        left join `filters` as `tag` on `tickets`.`id` = `tag`.`ticket_id` 
    49
        and `tag`.`key` = ? 
    50
        left join `ticket_collaborator` on `ticket_collaborator`.`ticket_id` = `tickets`.`id` 
    51
    where 
    52
        FIND_IN_SET('on', 'tag.value')
    53
    group by 
    54
        `tickets`.`id`
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    -
    - - ]
    - -
    -
    -
    -
    - -

    Error

    -

    There seems to be an error in your SQL query. The MySQL server error output below, if there is any, may also help you in diagnosing the problem.

    -
    ERROR: Unknown Punctuation String @ 1264
    -STR: ?,
    -SQL: select 
    -	`tickets`.`id`, 
    -	`tickets`.`ticket_number`, 
    -	`tickets`.`status`, 
    -	`tickets`.`user_id`, 
    -	`tickets`.`priority_id`, 
    -	`tickets`.`assigned_to`, 
    -	`ticket_thread`.`title`, 
    -	max(ticket_thread.updated_at) as updated_at, 
    -	COUNT(ticket_thread.updated_at) as countthread, 
    -	`ticket_priority`.`priority`, 
    -	`ticket_priority`.`priority_color`, 
    -	`u`.`user_name` as `user_name`, 
    -	`u`.`first_name` as `first_name`, 
    -	`u`.`last_name` as `last_name`, 
    -	`u1`.`user_name` as `assign_user_name`, 
    -	`u1`.`first_name` as `assign_first_name`, 
    -	`u1`.`last_name` as `assign_last_name`, 
    -	COUNT(ticket_attachment.thread_id) as countattachment, 
    -	COUNT(ticket_collaborator.ticket_id) as countcollaborator, 
    -	`ticket_status`.`name` as `tickets_status`, 
    -	`ticket_source`.`css_class` as `css`, 
    -	substring_index(
    -		group_concat(
    -			ticket_thread.poster 
    -			order by 
    -				ticket_thread.updated_at desc
    -		), 
    -		",", 
    -		1
    -	) as last_replier, 
    -	`label`.`value` as `label_values`, 
    -	`tag`.`value` as `tag_values` 
    -from 
    -	`tickets` 
    -	left join `ticket_thread` on `tickets`.`id` = `ticket_thread`.`ticket_id` 
    -	and `title` is not null 
    -	and `ticket_thread`.`is_internal` <> ? 
    -	inner join `ticket_status` on `ticket_status`.`id` = `tickets`.`status` 
    -	and `ticket_status`.`id` in (?, ?) 
    -	inner join `ticket_source` on `ticket_source`.`id` = `tickets`.`source` 
    -	left join `ticket_priority` on `ticket_priority`.`priority_id` = `tickets`.`priority_id` 
    -	left join `users` as `u` on `u`.`id` = `tickets`.`user_id` 
    -	left join `users` as `u1` on `u1`.`id` = `tickets`.`assigned_to` 
    -	left join `ticket_attachment` on `ticket_attachment`.`thread_id` = `ticket_thread`.`id` 
    -	left join `filters` as `label` on `tickets`.`id` = `label`.`ticket_id` 
    -	and `label`.`key` = ? 
    -	left join `filters` as `tag` on `tickets`.`id` = `tag`.`ticket_id` 
    -	and `tag`.`key` = ? 
    -	left join `ticket_collaborator` on `ticket_collaborator`.`ticket_id` = `tickets`.`id` 
    -where 
    -	FIND_IN_SET('on', 'tag.value')<> 0 
    -group by 
    -	`tickets`.`id`
    -
    - -
    -

    SQL query: -Documentation

    -

    -select - `tickets`.`id`, - `tickets`.`ticket_number`, - `tickets`.`status`, - `tickets`.`user_id`, - `tickets`.`priority_id`, - `tickets`.`assigned_to`, - `ticket_thread`.`title`, - max(ticket_thread.updated_at) as updated_at, - COUNT(ticket_thread.updated_at) as countthread, - `ticket_priority`.`priority`, - `ticket_priority`.`priority_color`, - `u`.`user_name` as `user_name`, - `u`.`first_name` as `first_name`, - `u`.`last_name` as `last_name`, - `u1`.`user_name` as `assign_user_name`, - `u1`.`first_name` as `assign_first_name`, - `u1`.`last_name` as `assign_last_name`, - COUNT(ticket_attachment.thread_id) as countattachment, - COUNT(ticket_collaborator.ticket_id) as countcollaborator, - `ticket_status`.`name` as `tickets_status`, - `ticket_source`.`css_class` as `css`, - substring_index( - group_concat( - ticket_thread.poster - order by - ticket_thread.updated_at desc - ), - ",", - 1 - ) as last_replier, - `label`.`value` as `label_values`, - `tag`.`value` as `tag_values` -from - `tickets` - left join `ticket_thread` on `tickets`.`id` = `ticket_thread`.`ticket_id` - and `title` is not null - and `ticket_thread`.`is_internal` <> ? - inner join `ticket_status` on `ticket_status`.`id` = `tickets`.`status` - and `ticket_status`.`id` in (?, ?) - inner join `ticket_source` on `ticket_source`.`id` = `tickets`.`source` - left join `ticket_priority` on `ticket_priority`.`priority_id` = `tickets`.`priority_id` - left join `users` as `u` on `u`.`id` = `tickets`.`user_id` - left join `users` as `u1` on `u1`.`id` = `tickets`.`assigned_to` - left join `ticket_attachment` on `ticket_attachment`.`thread_id` = `ticket_thread`.`id` - left join `filters` as `label` on `tickets`.`id` = `label`.`ticket_id` - and `label`.`key` = ? - left join `filters` as `tag` on `tickets`.`id` = `tag`.`ticket_id` - and `tag`.`key` = ? - left join `ticket_collaborator` on `ticket_collaborator`.`ticket_id` = `tickets`.`id` -where - FIND_IN_SET('on', 'tag.value')<> 0 -group by - `tickets`.`id` -

    -

    - MySQL said: Documentation -

    - -#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '?
    -    inner join `ticket_status` on `ticket_status`.`id` = `tickets`.`status`
    -    ' at line 38 -

    -
    \ No newline at end of file