-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtms_db.sql
More file actions
254 lines (207 loc) · 8.71 KB
/
tms_db.sql
File metadata and controls
254 lines (207 loc) · 8.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
-- phpMyAdmin SQL Dump
-- version 5.2.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Nov 15, 2024 at 03:44 PM
-- Server version: 10.4.28-MariaDB
-- PHP Version: 8.2.4
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;
--
-- Database: `tms_db`
--
-- --------------------------------------------------------
--
-- Table structure for table `project_list`
--
CREATE TABLE `project_list` (
`id` int(30) NOT NULL,
`name` varchar(200) NOT NULL,
`description` text NOT NULL,
`status` tinyint(2) NOT NULL,
`start_date` date NOT NULL,
`end_date` date NOT NULL,
`manager_id` int(30) NOT NULL,
`user_ids` text NOT NULL,
`date_created` datetime NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
--
-- Dumping data for table `project_list`
--
INSERT INTO `project_list` (`id`, `name`, `description`, `status`, `start_date`, `end_date`, `manager_id`, `user_ids`, `date_created`) VALUES
(3, 'Mini Project', 'Finish the project as soon as possible , if any queries contact me', 0, '2024-11-05', '2024-11-12', 6, '7', '2024-11-11 19:53:50');
-- --------------------------------------------------------
--
-- Table structure for table `system_settings`
--
CREATE TABLE `system_settings` (
`id` int(30) NOT NULL,
`name` text NOT NULL,
`email` varchar(200) NOT NULL,
`contact` varchar(20) NOT NULL,
`address` text NOT NULL,
`cover_img` text NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
--
-- Dumping data for table `system_settings`
--
INSERT INTO `system_settings` (`id`, `name`, `email`, `contact`, `address`, `cover_img`) VALUES
(1, 'Task Management System', 'info@sample.comm', '+6948 8542 623', '2102 Caldwell Road, Rochester, New York, 14608', ''),
(2, 'Task Loop', 'info@sample.comm', '+6948 8542 623', '2102 Caldwell Road, Rochester, New York, 14608', '');
-- --------------------------------------------------------
--
-- Table structure for table `task_list`
--
CREATE TABLE `task_list` (
`id` int(30) NOT NULL,
`project_id` int(30) NOT NULL,
`task` varchar(200) NOT NULL,
`description` text NOT NULL,
`status` tinyint(4) NOT NULL,
`date_created` datetime NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
-- Table structure for table `attendance`
CREATE TABLE `attendance` (
`id` int(30) NOT NULL AUTO_INCREMENT,
`user_id` int(30) NOT NULL,
`date` date NOT NULL,
`status` varchar(20) NOT NULL COMMENT 'present, absent, leave',
`check_in_time` time DEFAULT NULL,
`check_out_time` time DEFAULT NULL,
`remarks` text DEFAULT NULL,
`date_created` datetime NOT NULL DEFAULT current_timestamp(),
PRIMARY KEY (`id`),
FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- Dumping data for table `attendance`
INSERT INTO `attendance` (`id`, `user_id`, `date`, `status`, `check_in_time`, `check_out_time`, `remarks`, `date_created`) VALUES
(1, 2, '2024-11-15', 'present', '08:00:00', '16:00:00', 'On time', '2024-11-15 08:00:00'),
(2, 3, '2024-11-15', 'absent', NULL, NULL, 'On leave', '2024-11-15 08:00:00'),
(3, 4, '2024-11-15', 'present', '09:00:00', '17:00:00', 'Late arrival', '2024-11-15 08:00:00');
-- Update the AUTO_INCREMENT value for the new `attendance` table
ALTER TABLE `attendance`
MODIFY `id` int(30) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;
--
-- Dumping data for table `task_list`
--
INSERT INTO `task_list` (`id`, `project_id`, `task`, `description`, `status`, `date_created`) VALUES
(1, 1, 'Sample Task 1', ' <span style="color: rgb(0, 0, 0); font-family: &quot;Open Sans&quot;, Arial, sans-serif; font-size: 14px; text-align: justify;">Fusce ullamcorper mattis semper. Nunc vel risus ipsum. Sed maximus dapibus nisl non laoreet. Pellentesque quis mauris odio. Donec fermentum facilisis odio, sit amet aliquet purus scelerisque eget.&nbsp;</span> ', 3, '2020-12-03 11:08:58'),
(2, 1, 'Sample Task 2', 'Sample Task 2 ', 1, '2020-12-03 13:50:15'),
(3, 2, 'Task Test', 'Sample', 1, '2020-12-03 13:52:25'),
(4, 2, 'test 23', 'Sample test 23', 1, '2020-12-03 13:52:40'),
(5, 3, 'Frontend', ' Managed by gobi ', 3, '2024-11-11 19:57:36');
-- --------------------------------------------------------
--
-- Table structure for table `users`
--
CREATE TABLE `users` (
`id` int(30) NOT NULL,
`firstname` varchar(200) NOT NULL,
`lastname` varchar(200) NOT NULL,
`email` varchar(200) NOT NULL,
`password` text NOT NULL,
`type` tinyint(1) NOT NULL DEFAULT 2 COMMENT '1 = admin, 2 = staff',
`avatar` text NOT NULL DEFAULT 'no-image-available.png',
`date_created` datetime NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
--
-- Dumping data for table `users`
--
INSERT INTO `users` (`id`, `firstname`, `lastname`, `email`, `password`, `type`, `avatar`, `date_created`) VALUES
(1, 'Administrator', '', 'admin@admin.com', '0192023a7bbd73250516f069df18b500', 1, 'no-image-available.png', '2020-11-26 10:57:04'),
(6, 'Chandramadhan', 'V', 'cmneymar05112003@gmail.com', '4371c4dc60302abc1a9cb4d0437945b8', 2, 'no-image-available.png', '2024-11-11 19:50:31'),
(7, 'Gobikrishna', 'V', 'vgobikrishna2003@gmail.com', 'b3ce3ea960a4f9c4c89f3d1b23888403', 3, 'no-image-available.png', '2024-11-11 19:52:46');
-- --------------------------------------------------------
--
-- Table structure for table `user_productivity`
--
CREATE TABLE `user_productivity` (
`id` int(30) NOT NULL,
`project_id` int(30) NOT NULL,
`task_id` int(30) NOT NULL,
`comment` text NOT NULL,
`subject` varchar(200) NOT NULL,
`date` date NOT NULL,
`start_time` time NOT NULL,
`end_time` time NOT NULL,
`user_id` int(30) NOT NULL,
`time_rendered` float NOT NULL,
`date_created` datetime NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
--
-- Dumping data for table `user_productivity`
--
INSERT INTO `user_productivity` (`id`, `project_id`, `task_id`, `comment`, `subject`, `date`, `start_time`, `end_time`, `user_id`, `time_rendered`, `date_created`) VALUES
(1, 1, 1, ' <p>Sample Progress</p><ul><li>Test 1</li><li>Test 2</li><li>Test 3</li></ul> ', 'Sample Progress', '2020-12-03', '08:00:00', '10:00:00', 1, 2, '2020-12-03 12:13:28'),
(2, 1, 1, ' Sample Progress ', 'Sample Progress 2', '2020-12-03', '13:00:00', '14:00:00', 1, 1, '2020-12-03 13:48:28'),
(3, 1, 2, ' Sample ', 'Test', '2020-12-03', '08:00:00', '09:00:00', 5, 1, '2020-12-03 13:57:22'),
(4, 1, 2, 'asdasdasd', 'Sample Progress', '2020-12-02', '08:00:00', '10:00:00', 2, 2, '2020-12-03 14:36:30'),
(5, 3, 5, ' ', 'Finished', '2024-11-11', '11:30:00', '16:00:00', 6, 4.5, '2024-11-11 20:02:11'),
(6, 3, 5, ' ', 'Finished by gobi', '2024-11-15', '10:00:00', '14:00:00', 7, 4, '2024-11-15 12:09:02'),
(7, 3, 5, ' ', 'Finished', '2024-11-15', '19:54:00', '21:54:00', 7, 2, '2024-11-15 19:55:00');
--
-- Indexes for dumped tables
--
--
-- Indexes for table `project_list`
--
ALTER TABLE `project_list`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `system_settings`
--
ALTER TABLE `system_settings`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `task_list`
--
ALTER TABLE `task_list`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `users`
--
ALTER TABLE `users`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `user_productivity`
--
ALTER TABLE `user_productivity`
ADD PRIMARY KEY (`id`);
--
-- AUTO_INCREMENT for dumped tables
--
--
-- AUTO_INCREMENT for table `project_list`
--
ALTER TABLE `project_list`
MODIFY `id` int(30) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;
--
-- AUTO_INCREMENT for table `system_settings`
--
ALTER TABLE `system_settings`
MODIFY `id` int(30) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;
--
-- AUTO_INCREMENT for table `task_list`
--
ALTER TABLE `task_list`
MODIFY `id` int(30) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;
--
-- AUTO_INCREMENT for table `users`
--
ALTER TABLE `users`
MODIFY `id` int(30) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8;
--
-- AUTO_INCREMENT for table `user_productivity`
--
ALTER TABLE `user_productivity`
MODIFY `id` int(30) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8;
COMMIT;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;