Open jdville03 opened 3 years ago
Creating a Bank
On Dao creation, we need to create the bank immediately after and set the ACL for adapters to access the bank.
For example, after calling createDao(name, creator)
from the DaoFactory contract, we should:
Call createBank
from the BankFactory
using the bank factory contract address, either with a default maxExternalTokens
value of 200 or accept user input value.
.createBank(200)
returns bankAddress
Then, call the .addExtension(sha3(“bank”),bankAddress,creator)
from the daoRegistry(daoAddress)
contract.
Lastly, we should give permission to adapters that require access to the bank, such as the OffChainVotingContract. An example:
Using the DaoFactory contract, we need to call configureExtension(DaoRegistry dao,address extension,Adapter[] calldata adapters)
.
configureExtension(daoAddress,bankAddress,adapters[])
Suggestion, we should perhaps call this function when the finalizing DAO action is called.
Sets the access control for a particular adapter (by address) to a specific extension. Both adapter and extension need to be already registered to the DAO.
We can use the DAO Artifacts to retrieve/manage/view adapters/extensions https://github.com/openlawteam/tribute-contracts/issues/273
Placeholder
Finish the DAO Creation UI