Methods
The operations that can be performed on the subDAO contract are listed below.
Read Operations
Pass a Component address in this function for it to retrieve its key.
Pass a key in this function for it to retrieve the array of the Component addresses corresponding to the key's history.
Pass multiple keys in this function for it to retrieve, for each key, the array of the addresses of the Components corresponding to the key's history.
Pass a Component key in this function for it to retrieve the Component's address.
Pass multiple Component keys in this function for it to retrieve, for each key, its address.
Pass a Component address in this function for it to retrieve whether the address corresponds to an active Component (true) or an inactive one (false).
Pass a key in this function for it to retrieve whether the key corresponds to an active Component (true) or an inactive one (false).
Retrieve the presetArrayMaxSize
(maximum number of Proposal Models in the subDAO) parameter set.
Retrieve all the Proposal Models set in the subDAO.
Pass a proposalId
and retrieve if the Proposal exists and if it was deprecated setting new Preset Proposals using the setPresetValues
function.
Write Operations
Pass a component
struct to add it to an Organization. If the key passed in the struct is already attached to a Component, that Component will be replaced with the new one.
The output function returns the address of the new Component.
Pass multiple component
structs to add them to an Organization. If a key passed in a struct is already attached to a Component, that Component will be replaced with the new one.
The output function returns the addresses of the new Components.
This function allows an authorized Component to ask an Organization to call another contract (address location
), passing specific parameters (payload
). If the contract sends the Organization some tokens etc., a restReceiver
can be specified to receive them. The Organization uses a call
function to perform the interaction with the smart contract (location)
This function can be used to set new Proposal Models. It deletes the old Proposal models from the subDAO.
This function can be used to set one or more Proposal Models in the subDAO if no Models were set when the SubDAO was initialized. This function can be called only by the address that previously initialized the subDAO contract.
This function can be used to change the votingRulesIndex
parameter of a Proposal Model.
This function can be used to change the creationRules
and triggeringRules
smart contract addresses of Proposal Model.
This function can be used to change the presetValues
parameter of a Proposal Model.
This function can be used to set the subDAO host at a later time and it can only be called by a subDAO Manager. Look here for more info.
Last updated