tickets
id int(11)
user_id int(11)
message text
is_active tinyint(1)
created_at datetime
time_spent int(5) //unless your going to spend more than 99999 mins on a ticket
Ticketing systems are a pretty easy build, have a database table:
tickets
id int(11)
user_id int(11)
message text
is_active tinyint(1)
created_at datetime
time_spent int(5) //unless your going to spend more than 99999 mins on a ticket
Now each time a user creates a ticket it goes into the db as VALUES(id,'$user_id','$message',0,NOW(),0)//remember to clean the vars
Admin can complete a ticket, update the field so that is_active = 1, then request time spent from the admin and update time_spent = '$time_spent'
You could add a commenting system simply
Database table: comments
id int(11)
ticket_id int(11)
user_id int(11)
comment text
created_at datetime
This way you can have unlimited(up to a total total of 99999999999) comments per ticket and you track the user id so you can put names next to each comment.
You can call the comments using
select * from comments where ticket_id = $id //the current tickets id
I hope this helps, its a nice easy build and means you know exactly how it works, its always nice to have done it yourself and its easily customisable.
发布评论
评论(3)
票务系统是一个非常简单的构建,有一个数据库表:
现在,每次用户创建票证时,它都会以
VALUES(id,'$user_id','$message',0,NOW(), 0)//记得清理变量
管理员可以完成一个票证,更新字段以使 is_active = 1,然后向管理员请求花费的时间并更新 time_spent = '$time_spent'
您可以简单地添加一个评论系统
这样,您可以在每张票证上拥有无限的评论(总共最多 99999999999 条),并且您可以跟踪用户 ID,以便您可以在每个评论旁边添加名称。
调用评论
您可以使用
select * from comments where Ticket_id = $id //the current Ticket id
来我希望这会有所帮助,它是一个很好的简单构建,意味着您确切地知道它是如何工作的,它总是很好自己完成并且可以轻松定制。
问候卢克
Ticketing systems are a pretty easy build, have a database table:
Now each time a user creates a ticket it goes into the db as
VALUES(id,'$user_id','$message',0,NOW(),0)//remember to clean the vars
Admin can complete a ticket, update the field so that is_active = 1, then request time spent from the admin and update time_spent = '$time_spent'
You could add a commenting system simply
This way you can have unlimited(up to a total total of 99999999999) comments per ticket and you track the user id so you can put names next to each comment.
You can call the comments using
select * from comments where ticket_id = $id //the current tickets id
I hope this helps, its a nice easy build and means you know exactly how it works, its always nice to have done it yourself and its easily customisable.
Regards Luke
您可以使用开源且免费的osTicket。
You could use osTicket which is open source and free.
或者使用 Spiceworks。它是免费的。
Or use Spiceworks. It's free.