Open tickets in 3 days show right function but wrong number

Hi Martin,

I fixed a problem with wrong number of ticket in customer information sidebar.
There was also a problem with SateType and StateIDs. The problem was on search screen  with "Change search option". There is displayed wrong search attributes. States select box is not shown. 
Is it OK that we fix the both of them on this PR, or you maybe want that I make another one.

Regards
Zoran