From f825db1c897d664a8705cd6f0063b54ee932595f Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Fri, 24 Jun 2011 18:56:50 +0000 Subject: [PATCH] web: update search help and make it slidey --- hledger-web/.hledger/web/static/hledger.js | 3 +++ hledger-web/.hledger/web/static/style.css | 1 + .../.hledger/web/templates/searchform.hamlet | 18 ++++++++++++------ 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/hledger-web/.hledger/web/static/hledger.js b/hledger-web/.hledger/web/static/hledger.js index d4ebe51a4..1065f67ce 100644 --- a/hledger-web/.hledger/web/static/hledger.js +++ b/hledger-web/.hledger/web/static/hledger.js @@ -11,6 +11,9 @@ $(document).ready(function() { $('.balancereport td.account').mouseenter(function(){ $(this).addClass('mouseover'); }); $('.balancereport td.account').mouseleave(function(){ $(this).removeClass('mouseover'); }); + /* set up various show/hide toggles */ + $('#search-help-link').click(function() { $('#search-help').slideToggle('fast'); }); + }); function searchformToggle() { diff --git a/hledger-web/.hledger/web/static/style.css b/hledger-web/.hledger/web/static/style.css index 362c9c9d7..27d876e35 100644 --- a/hledger-web/.hledger/web/static/style.css +++ b/hledger-web/.hledger/web/static/style.css @@ -21,6 +21,7 @@ body { backgroun #addform input.textinput, #addform .dhx_combo_input, .dhx_combo_list { background-color:#eee; } #editform textarea { background-color:#eee; } .negative { color:#800; } +.help { } .balancereport .inacct { background-color:#eee; font-weight:bold; } .notinacct, .notinacct :link, .notinacct :visited, .notinacct .negative { /*color:#aaa;*/ } diff --git a/hledger-web/.hledger/web/templates/searchform.hamlet b/hledger-web/.hledger/web/templates/searchform.hamlet index d088210e3..372639d80 100644 --- a/hledger-web/.hledger/web/templates/searchform.hamlet +++ b/hledger-web/.hledger/web/templates/searchform.hamlet @@ -8,15 +8,21 @@ help $if filtering \ # clear search - - inacct:FULLACCTNAME or click an account to focus on one account, or inaccts: to include subs
- acct:REGEXP to see postings to matched accounts, desc:REGEXP to search by description
- date:PERIODEXP or edate:PERIODEXP to match by date or effective date
- not: to negate, single or double quotes to include spaces, multiple patterns are AND'ed + + acct:REGEXP to filter postings/transactions by account, # + desc:REGEXP by description, # + date:PERIODEXP or edate:PERIODEXP by date or effective date. +
+ not: to negate, use single or double quotes to include spaces, multiple patterns are AND'ed.