mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 07:07:35 +01:00
set _user.exp example
This commit is contained in:
@@ -56,7 +56,7 @@ ready (model) ->
|
|||||||
|
|
||||||
for habitType in lists
|
for habitType in lists
|
||||||
list = model.at "_#{habitType}List"
|
list = model.at "_#{habitType}List"
|
||||||
|
|
||||||
# Make the list draggable using jQuery UI
|
# Make the list draggable using jQuery UI
|
||||||
ul = $("\##{habitType}s")
|
ul = $("\##{habitType}s")
|
||||||
ul.sortable
|
ul.sortable
|
||||||
@@ -126,6 +126,12 @@ ready (model) ->
|
|||||||
# Derby extends model.at to support creation from DOM nodes
|
# Derby extends model.at to support creation from DOM nodes
|
||||||
model.at(e.target).remove()
|
model.at(e.target).remove()
|
||||||
|
|
||||||
|
exports.voteUp = (e) ->
|
||||||
|
todo = model.at(e.target)
|
||||||
|
exp = model.get '_user.exp'
|
||||||
|
model.set '_user.exp', exp +1
|
||||||
|
console.log todo
|
||||||
|
|
||||||
## RECONNECT & SHORTCUTS ##
|
## RECONNECT & SHORTCUTS ##
|
||||||
|
|
||||||
showReconnect = model.at '_showReconnect'
|
showReconnect = model.at '_showReconnect'
|
||||||
|
|||||||
Reference in New Issue
Block a user