Hello Roberto,
On 2013-05-08 12:41, Roberto Bartali wrote:
Hi everyone
I'm new to mailpiler and just trying to understand if is it suitable
for my organization needs. I'm using compiled version of mailpiler and
sphinx.
This is the "problem": if i search a message using the "search"
button it performa a query only for received messages. If I want to
extend the search to the "Sent" messages i must use the "Advanced
Search" writing my mail address in the "From" field.
Is this a normal behavior?
yes, it's a feature, not a bug :-) If a regular user issues a search
query
then an email address filter is applied based on his email addresses to
search within only his emails. If the user defines whether to search in
the sent emails, then it's honored and set accordingly in the filter
expression.
However if you just enter some subject or body expression then the
default
filter is set which narrows the search to the received emails.
Option #1 is to use the "advanced" search and specify your own address.
The other option is to write 'from: your@address' to the long search
field.
Can I modify it by configuration settings?
Edit model/search/search.php, and around the 215th line it says:
if($f_f == '' && $o_f == '' && $f_t == '' && $o_t == '') { return "@to
$all_your_addresses"; }
change it to the following:
if($f_f == '' && $o_f == '' && $f_t == '' && $o_t == '') { return
"@from $all_your_addresses"; }
and from then if a user doesn't define whether he wants to search in
the sent
or received emails, then the gui will focus on the sent emails.
Perhaps I'll add a config.php option to define which direction to
prefer by
defult: the sent or the received.
Janos