Bugfixes in helpdesk system

I fix some bugs in the helpdesk system which prevent from creating
tickets in frontend.