Skip to content

Instantly share code, notes, and snippets.

@hzm-s
Created April 1, 2014 05:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hzm-s/9908372 to your computer and use it in GitHub Desktop.
Save hzm-s/9908372 to your computer and use it in GitHub Desktop.
MSS Interaction
#logs
@timeline = Timeline.find(current_user)
@timeline.each do |activity|
p activity.date
p activity.balance
p activity.outgo
p activity.income
end
# record Balance
last_timeline = Timeline.find(current_user)
new_timeline = last_timeline.update(Money.yen(38500), Money.yen(33000))
Timeline.replace(new_timeline)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment