Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

release v12 #205

Merged
merged 1 commit into from
Nov 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion release/v12/BuildInfo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ compiled_package_info:
? address: "0x00000000000000000000000000000001"
name: YieldFarmingV2
: StarcoinFramework
source_digest: E2AE9B65FA7E7B645BCC6FFF7E1C5A23CC82751DCC3A587627C198DC0F9119A0
source_digest: E90F2F8FC8A933897A28C415C88680705ED69370B7BE7AE1025E9CE037CE07FC
build_flags:
dev_mode: false
test_mode: false
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified release/v12/abis/MemberProposalPlugin/create_proposal_entry.abi
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified release/v12/abis/StakeToSBTPlugin/stake_entry.abi
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified release/v12/abis/UpgradeModulePlugin/create_proposal_entry.abi
Binary file not shown.
Binary file not shown.
Binary file modified release/v12/bytecode_modules/MemberProposalPlugin.mv
Binary file not shown.
Binary file modified release/v12/bytecode_modules/StakeToSBTPlugin.mv
Binary file not shown.
13 changes: 7 additions & 6 deletions release/v12/docs/AnyMemberPlugin.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

# Module `0x1::AnyMemberPlugin`

This plugin let every can join the DAO, and auto get 1 sbt.


- [Struct `AnyMemberPlugin`](#0x1_AnyMemberPlugin_AnyMemberPlugin)
Expand Down Expand Up @@ -190,7 +191,7 @@



<pre><code><b>public</b> <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT: store&gt;(sender: &signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay: u64)
<pre><code><b>public</b> <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT: store&gt;(sender: &signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay: u64)
</code></pre>


Expand All @@ -199,8 +200,8 @@
<summary>Implementation</summary>


<pre><code><b>public</b> <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT:store&gt;(sender:&signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay:u64){
<a href="InstallPluginProposalPlugin.md#0x1_InstallPluginProposalPlugin_create_proposal">InstallPluginProposalPlugin::create_proposal</a>&lt;DAOT, <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin">AnyMemberPlugin</a>&gt;(sender, <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_required_caps">required_caps</a>(), title, introduction, description, action_delay);
<pre><code><b>public</b> <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT:store&gt;(sender:&signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay:u64){
<a href="InstallPluginProposalPlugin.md#0x1_InstallPluginProposalPlugin_create_proposal">InstallPluginProposalPlugin::create_proposal</a>&lt;DAOT, <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin">AnyMemberPlugin</a>&gt;(sender, <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_required_caps">required_caps</a>(), title, introduction, extend, action_delay);
}
</code></pre>

Expand All @@ -214,7 +215,7 @@



<pre><code><b>public</b>(<b>script</b>) <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT: store&gt;(sender: signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay: u64)
<pre><code><b>public</b>(<b>script</b>) <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT: store&gt;(sender: signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay: u64)
</code></pre>


Expand All @@ -223,8 +224,8 @@
<summary>Implementation</summary>


<pre><code><b>public</b> (<b>script</b>) <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT:store&gt;(sender:signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay:u64){
<a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT&gt;(&sender, title, introduction, description, action_delay);
<pre><code><b>public</b> (<b>script</b>) <b>fun</b> <a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT:store&gt;(sender:signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay:u64){
<a href="AnyMemberPlugin.md#0x1_AnyMemberPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT&gt;(&sender, title, introduction, extend, action_delay);
}
</code></pre>

Expand Down
18 changes: 9 additions & 9 deletions release/v12/docs/ConfigProposalPlugin.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ Called by other contract which need proposal config



<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_create_proposal">create_proposal</a>&lt;DAOT: store, ConfigT: drop, store&gt;(sender: &signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay: u64, config: ConfigT)
<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_create_proposal">create_proposal</a>&lt;DAOT: store, ConfigT: drop, store&gt;(sender: &signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay: u64, config: ConfigT)
</code></pre>


Expand All @@ -163,7 +163,7 @@ Called by other contract which need proposal config
<summary>Implementation</summary>


<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_create_proposal">create_proposal</a>&lt;DAOT: store, ConfigT: store+drop&gt;(sender: &signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, description: vector&lt;u8&gt;,action_delay: u64, config: ConfigT) {
<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_create_proposal">create_proposal</a>&lt;DAOT: store, ConfigT: store+drop&gt;(sender: &signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, extend: vector&lt;u8&gt;,action_delay: u64, config: ConfigT) {
<b>let</b> witness = <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin">ConfigProposalPlugin</a>{};
<b>let</b> cap = <a href="DAOSpace.md#0x1_DAOSpace_acquire_proposal_cap">DAOSpace::acquire_proposal_cap</a>&lt;DAOT, <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin">ConfigProposalPlugin</a>&gt;(&witness);
<b>let</b> action = <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_ConfigProposalAction">ConfigProposalAction</a>&lt;ConfigT&gt;{
Expand All @@ -172,7 +172,7 @@ Called by other contract which need proposal config
<a href="DAOSpace.md#0x1_DAOSpace_create_proposal">DAOSpace::create_proposal</a>&lt;
DAOT,
<a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin">ConfigProposalPlugin</a>,
<a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_ConfigProposalAction">ConfigProposalAction</a>&lt;ConfigT&gt;&gt;(&cap, sender, action, title, introduction, description, action_delay, <a href="Option.md#0x1_Option_none">Option::none</a>&lt;u8&gt;());
<a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_ConfigProposalAction">ConfigProposalAction</a>&lt;ConfigT&gt;&gt;(&cap, sender, action, title, introduction, extend, action_delay, <a href="Option.md#0x1_Option_none">Option::none</a>&lt;u8&gt;());
}
</code></pre>

Expand Down Expand Up @@ -244,7 +244,7 @@ Called by other contract which need proposal config



<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT: store&gt;(sender: &signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay: u64)
<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT: store&gt;(sender: &signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay: u64)
</code></pre>


Expand All @@ -253,8 +253,8 @@ Called by other contract which need proposal config
<summary>Implementation</summary>


<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT:store&gt;(sender:&signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay:u64){
<a href="InstallPluginProposalPlugin.md#0x1_InstallPluginProposalPlugin_create_proposal">InstallPluginProposalPlugin::create_proposal</a>&lt;DAOT, <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin">ConfigProposalPlugin</a>&gt;(sender, <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_required_caps">required_caps</a>(), title, introduction, description, action_delay);
<pre><code><b>public</b> <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT:store&gt;(sender:&signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay:u64){
<a href="InstallPluginProposalPlugin.md#0x1_InstallPluginProposalPlugin_create_proposal">InstallPluginProposalPlugin::create_proposal</a>&lt;DAOT, <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin">ConfigProposalPlugin</a>&gt;(sender, <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_required_caps">required_caps</a>(), title, introduction, extend, action_delay);
}
</code></pre>

Expand All @@ -268,7 +268,7 @@ Called by other contract which need proposal config



<pre><code><b>public</b>(<b>script</b>) <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT: store&gt;(sender: signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay: u64)
<pre><code><b>public</b>(<b>script</b>) <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT: store&gt;(sender: signer, title: vector&lt;u8&gt;, introduction: vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay: u64)
</code></pre>


Expand All @@ -277,8 +277,8 @@ Called by other contract which need proposal config
<summary>Implementation</summary>


<pre><code><b>public</b> (<b>script</b>) <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT:store&gt;(sender:signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, description: vector&lt;u8&gt;, action_delay:u64){
<a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT&gt;(&sender, title, introduction, description, action_delay);
<pre><code><b>public</b> (<b>script</b>) <b>fun</b> <a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal_entry">install_plugin_proposal_entry</a>&lt;DAOT:store&gt;(sender:signer, title:vector&lt;u8&gt;, introduction:vector&lt;u8&gt;, extend: vector&lt;u8&gt;, action_delay:u64){
<a href="ConfigProposalPlugin.md#0x1_ConfigProposalPlugin_install_plugin_proposal">install_plugin_proposal</a>&lt;DAOT&gt;(&sender, title, introduction, extend, action_delay);
}
</code></pre>

Expand Down
5 changes: 4 additions & 1 deletion release/v12/docs/DAOSpace.md
Original file line number Diff line number Diff line change
Expand Up @@ -6022,6 +6022,9 @@ no_with_veto counts as no but also adds a veto vote
## Function `create_proposal`

propose a proposal.
<code>title</code>: title of the proposal
<code>introduction</code>: short introduction of the proposal
<code>extend</code>: extend of proposal , ipfs:// | { "title":"xxxxx",........ }
<code>action</code>: the actual action to execute.
<code>action_delay</code>: the delay to execute after the proposal is agreed
<code>quorum_scale_factor</code>: used to scale up the base quorum_votes_rate.
Expand Down Expand Up @@ -6760,7 +6763,7 @@ A portion of the pledged tokens will be rewarded to the executor who executes th
<b>let</b> dao_address = <a href="DAOSpace.md#0x1_DAOSpace_dao_address">dao_address</a>&lt;DAOT&gt;();
<b>assert</b>!(<b>exists</b>&lt;<a href="DAOSpace.md#0x1_DAOSpace_ProposalActions">ProposalActions</a>&lt;ActionT&gt;&gt;(dao_address), <a href="Errors.md#0x1_Errors_invalid_state">Errors::invalid_state</a>(<a href="DAOSpace.md#0x1_DAOSpace_ERR_PROPOSAL_ACTIONS_NOT_EXIST">ERR_PROPOSAL_ACTIONS_NOT_EXIST</a>));
<b>let</b> (_, token) = <a href="DAOSpace.md#0x1_DAOSpace_take_proposal_action">take_proposal_action</a>&lt;ActionT&gt;(dao_address, proposal_id);
// Part of the token is awarded <b>to</b> whoever executes this method , TODO: 10 %
// Part of the token is awarded <b>to</b> whoever executes this method , current: 10 %
<b>let</b> award_amount = <a href="Token.md#0x1_Token_value">Token::value</a>(&token) / 10;
<b>let</b> (burn_token , award_token) = <a href="Token.md#0x1_Token_split">Token::split</a>(token, award_amount);
<a href="Account.md#0x1_Account_deposit">Account::deposit</a>(<a href="Signer.md#0x1_Signer_address_of">Signer::address_of</a>(sender), award_token);
Expand Down
Loading