Skip to content

Commit

Permalink
delete content of datepickers with a button
Browse files Browse the repository at this point in the history
Signed-off-by: Balint Erdi <balint.erdi@gmail.com>
  • Loading branch information
balinterdi committed Mar 16, 2009
1 parent 2d10dc7 commit 71cf939
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 5 deletions.
7 changes: 5 additions & 2 deletions todos.markdown
Expand Up @@ -2,9 +2,10 @@

## Short-term

* revisit layout of the expenses page (Total amount is too close to the date filters)
* check layout of the date selectors on expensese page in Safari (looks ugly now)
* fix layout when subject of expense is too long
* buttons to delete dates and to select all tags/none
* add README
* make everything UTF-8 encoded
* make a form builder for the commonly used form (ul-li-label-input)

## Long-term
Expand All @@ -13,6 +14,8 @@

# DONE

* revisit layout of the expenses page (Total amount is too close to the date filters)
* check layout of the date selectors on expensese page in Safari (looks ugly now)
* make layout of the login and register pages nice
* correct the '/' action (gives error on 'name')
* get rid of the Pot model
Expand Down
8 changes: 8 additions & 0 deletions views/expenses.haml
Expand Up @@ -39,6 +39,11 @@

$(document).ready(function() {
$(".expense_date").datepicker({ firstDay : 1, showButtonPanel : true });
$("#delete-dates").click(function(){
$.each($(".expense_date"), function() {
$(this).val('');
})
})
$(".expense_date").change(function() {
updateExpenseList();
});
Expand All @@ -61,6 +66,9 @@
#to-label To
#to-input
%input.expense_date#spent-at-to
#dates-buttons
#delete-dates
%button#delete-dates{ :type => "button" } Delete

#expenses
%ul#expenses-list
Expand Down
10 changes: 7 additions & 3 deletions views/main.sass
Expand Up @@ -149,25 +149,29 @@ div#expenses
:margin-right 10px
:text-align right
#to-input
#dates-buttons
+float-align-right
:margin-left 5px

ul#expenses-list
:list-style-type none
li
:clear both
:width 500px
:width 600px
.amount
+float-align-left
:width 20%
:color red
.subject
+float-align-left
:width 20%
:width 40%
:overflow hidden
.spent_at
+float-align-left
:width 20%
.links
+float-align-right
:width 40%
:width 20%

#sum
:width 200px
Expand Down

0 comments on commit 71cf939

Please sign in to comment.