浏览代码

Added record() function to tokenomics module functions

Nathan Schneider 2 年之前
父节点
当前提交
12a49ab66d
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      modpol_core/modules/tokenomics.lua

+ 4 - 0
modpol_core/modules/tokenomics.lua

@@ -93,16 +93,20 @@ function tokenomics.balance(org, token, user)
 end
 end
 
 
 function tokenomics.change_balance(org, token, user, amount)
 function tokenomics.change_balance(org, token, user, amount)
+   self.org:record("Changed token balance",self.slug)
 end
 end
 
 
 function tokenomics.transfer(org, token, sender, recipient, amount)
 function tokenomics.transfer(org, token, sender, recipient, amount)
+   -- use change_balance
 end
 end
 
 
 function tokenomics.treasury_transfer(org, token, recipient, amount)
 function tokenomics.treasury_transfer(org, token, recipient, amount)
+   -- use change_balance
 end
 end
 
 
 -- creates new tokens in the org treasury
 -- creates new tokens in the org treasury
 function tokenomics.issue(org, token, amount)
 function tokenomics.issue(org, token, amount)
+   self.org:record("Issued tokes to treasury",self.slug)
 end
 end
 
 
 ------------------------------------------
 ------------------------------------------