Changed logging options
Move some JavaScript and variables to separate files.
Read ticket from header instead of from (not available) request params.
Add gsp template: create relations.
renamed function loadPreviews

(name conflicts with already existing extension)
remove comments.
Update index after relation has changed.