web: use full width for search box, update search help

This commit is contained in:
Simon Michael 2013-04-15 17:28:30 -07:00
parent b878779c8a
commit 05da80b71d
2 changed files with 18 additions and 17 deletions

View File

@ -72,38 +72,39 @@ searchform :: ViewData -> HtmlUrl AppRoute
searchform VD{..} = [hamlet| searchform VD{..} = [hamlet|
<div#searchformdiv> <div#searchformdiv>
<form#searchform.form method=GET> <form#searchform.form method=GET>
<table> <table width="100%">
<tr> <tr>
<td> <td width="99%">
Search: <input name=q value=#{q} style="width:98%;">
\ # <td width="1%">
<td>
<input name=q size=70 value=#{q}>
<input type=submit value="Search"> <input type=submit value="Search">
<tr valign=top>
<td colspan=2 style="text-align:right;">
$if filtering $if filtering
\ # \ #
<span.showall> <span.showall>
<a href=@{here}>clear search <a href=@{here}>clear
\ # \ #
<a#search-help-link href="#" title="Toggle search help">help <a#search-help-link href="#" title="Toggle search help">help
<tr> <tr>
<td> <td colspan=2>
<td>
<div#search-help.help style="display:none;"> <div#search-help.help style="display:none;">
Leave blank to see journal (all transactions), or click account links to see transactions under that account. Leave blank to see journal (all transactions), or click account links to see transactions under that account.
<br> <br>
Transactions/postings may additionally be filtered by: Transactions/postings may additionally be filtered by
<br>
acct:REGEXP (target account), # acct:REGEXP (target account), #
code:REGEXP (transaction code), #
desc:REGEXP (description), # desc:REGEXP (description), #
date:PERIODEXP (date), # date:PERIODEXP (date), #
edate:PERIODEXP (secondary date), # date2:PERIODEXP (secondary date), #
<br> tag:TAG[=REGEX] (tag and optionally tag value), #
status:BOOL (cleared status), # depth:N (accounts at or above this depth), #
status:*, status:!, status: (cleared status), #
real:BOOL (real/virtual-ness), # real:BOOL (real/virtual-ness), #
empty:BOOL (posting amount = 0). empty:BOOL (is amount zero), #
amt:<N, amt:=N, amt:>N (test magnitude of single-commodity amount).
<br> <br>
not: to negate, enclose space-containing patterns in quotes, multiple filters are AND'ed. Prepend not: to negate, enclose multi-word patterns in quotes, multiple search terms are AND'ed.
|] |]
where where
filtering = not $ null q filtering = not $ null q

View File

@ -87,7 +87,7 @@ body { margin:0; }
.navlinkcurrent { font-weight:bold; } .navlinkcurrent { font-weight:bold; }
.form { margin:0em; } .form { margin:0em; }
#searchformdiv { margin:0 0 1em 0; white-space:nowrap; } #searchformdiv { margin:0 0 1em 0; }
#searchform { margin:0; } #searchform { margin:0; }
#searchform span { padding:4px; } #searchform span { padding:4px; }
#stopfilterlink { font-weight:bold; } #stopfilterlink { font-weight:bold; }