From 3a4d79e175f19d75e8d4fdb01669796d885018c7 Mon Sep 17 00:00:00 2001 From: Tyler Renelle Date: Mon, 11 Feb 2013 01:27:52 -0500 Subject: [PATCH] add items to the top of the list, since "add new __" is at the top --- src/app/tasks.coffee | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/app/tasks.coffee b/src/app/tasks.coffee index ff2feedf84..0532fd33a6 100644 --- a/src/app/tasks.coffee +++ b/src/app/tasks.coffee @@ -50,16 +50,16 @@ module.exports.app = (appExports, model) -> switch type when 'habit' - list.push {type: type, text: text, notes: '', value: 0, up: true, down: true} + list.unshift {type: type, text: text, notes: '', value: 0, up: true, down: true} when 'reward' - list.push {type: type, text: text, notes: '', value: 20 } + list.unshift {type: type, text: text, notes: '', value: 20 } when 'daily' - list.push {type: type, text: text, notes: '', value: 0, repeat:{su:true,m:true,t:true,w:true,th:true,f:true,s:true}, completed: false } + list.unshift {type: type, text: text, notes: '', value: 0, repeat:{su:true,m:true,t:true,w:true,th:true,f:true,s:true}, completed: false } when 'todo' - list.push {type: type, text: text, notes: '', value: 0, completed: false } + list.unshift {type: type, text: text, notes: '', value: 0, completed: false } # list.on 'set', '*.completed', (i, completed, previous, isLocal) -> # # Move the item to the bottom if it was checked off