Skip to content

Instantly share code, notes, and snippets.

@cindywu
Created May 13, 2022 00:30
Show Gist options
  • Save cindywu/fd622b908cb4a701c9f54999730c1ba9 to your computer and use it in GitHub Desktop.
Save cindywu/fd622b908cb4a701c9f54999730c1ba9 to your computer and use it in GitHub Desktop.
creating manual payout for experiment using console
// find the project
p = Project.find [projectID]
// create and save the funds payout in db
po = Payout.new
po.project_id = p.id
po.credit_type = 0
po.amount = [amount]
po.token = "[tokenID]"
po.user_id = [userID] (mine is 5)
po.save
//create and save the fees payout in db
po = Payout.new
po.project_id = p.id
po.credit_type = 1
po.amount = [amount]
po.token = "[tokenID]"
po.user_id = [userID] (mine is 5)
po.save
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment