Corrected user output. Added debug mode.
Added labels to next/last statements as required by the OTRS code style guide (WIP).
Added labels to next/last statements as required by the OTRS code style guide (WIP).
Fixed: PGP Crypted and Signed emails could be wrongly parsed (bug#9954).
Fixed: Cannot search for "Date" dynamic fields (bug#9945).
Code cleanup.
Fixed: Reply to previously signed email breaks PGP verification (bug#9921).
Added unit tests.
Also pass EncodeObject to permission modules.
Also pass standard objects to permission modules.
Split up layout tests.
Added nested blocks test.
Fixed mail configuration steps of windows installer.

This is a follow-up fix for http://bugs.otrs.org/show_bug.cgi?id=9942
If you clicked 'Check Mail Configuration' which leads to an error
(for instance without providing credentials),
and then clicked 'Skip Mail Configuration', the bug was not yet fixed.
Fixed customersearch with non-ascii chars on MSSQL

This fixes bug#7008 - http://bugs.otrs.org/show_bug.cgi?id=7008

On SQL Server, the CustomerUser.t and Service.t tests were failing.
This is because using a SQL Statement like this:

SELECT id FROM customer_user WHERE login LIKE '%string%';

causes problems if the string contains non-ascii characters on SQL
Server. This is a problem with DBD::ODBC actually.

It DOES work if we use bind-variables in the SQL statement.
Since using bind-variables is better for multiple reasons,
including preventing SQL injection, we changed the code to use
bind variables.

For this we extended the DBObjects' QueryCondition
to include a mode where it returns both the SQL string and the
bind variables.
Merge remote-tracking branch 'upstream/master' into otrs-master