diff --git a/Cargo.lock b/Cargo.lock index eb089fd7b..2ab8a792b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2495,6 +2495,7 @@ dependencies = [ "cosmwasm-schema", "cosmwasm-std", "cw-multi-test", + "cw-orch", "cw-storage-plus 1.2.0", "cw-utils 1.0.3", "cw2 1.1.2", @@ -2514,6 +2515,7 @@ dependencies = [ "cosmwasm-schema", "cosmwasm-std", "cw-multi-test", + "cw-orch", "cw-storage-plus 1.2.0", "cw-utils 1.0.3", "cw2 1.1.2", @@ -2532,6 +2534,7 @@ dependencies = [ "cosmwasm-schema", "cosmwasm-std", "cw-multi-test", + "cw-orch", "cw-ownable", "cw-storage-plus 1.2.0", "cw-utils 1.0.3", @@ -2558,6 +2561,7 @@ dependencies = [ "cw-controllers 1.1.2", "cw-hooks", "cw-multi-test", + "cw-orch", "cw-storage-plus 1.2.0", "cw-utils 1.0.3", "cw2 1.1.2", @@ -2588,6 +2592,7 @@ dependencies = [ "cw-controllers 1.1.2", "cw-hooks", "cw-multi-test", + "cw-orch", "cw-ownable", "cw-storage-plus 1.2.0", "cw-tokenfactory-issuer", diff --git a/contracts/voting/dao-voting-cw20-staked/Cargo.toml b/contracts/voting/dao-voting-cw20-staked/Cargo.toml index 4eae84a64..6a9863868 100644 --- a/contracts/voting/dao-voting-cw20-staked/Cargo.toml +++ b/contracts/voting/dao-voting-cw20-staked/Cargo.toml @@ -29,6 +29,7 @@ thiserror = { workspace = true } dao-dao-macros = { workspace = true } dao-interface = { workspace = true } dao-voting = { workspace = true } +cw-orch.workspace = true [dev-dependencies] cw-multi-test = { workspace = true } diff --git a/contracts/voting/dao-voting-cw20-staked/src/msg.rs b/contracts/voting/dao-voting-cw20-staked/src/msg.rs index bdb5e9f2a..0031d0deb 100644 --- a/contracts/voting/dao-voting-cw20-staked/src/msg.rs +++ b/contracts/voting/dao-voting-cw20-staked/src/msg.rs @@ -61,6 +61,7 @@ pub struct InstantiateMsg { } #[cw_serde] +#[derive(cw_orch::ExecuteFns)] pub enum ExecuteMsg { /// Sets the active threshold to a new value. Only the /// instantiator this contract (a DAO most likely) may call this @@ -74,7 +75,7 @@ pub enum ExecuteMsg { #[cw20_token_query] #[active_query] #[cw_serde] -#[derive(QueryResponses)] +#[derive(QueryResponses, cw_orch::QueryFns)] pub enum QueryMsg { /// Gets the address of the cw20-stake contract this voting module /// is wrapping. diff --git a/contracts/voting/dao-voting-cw4/Cargo.toml b/contracts/voting/dao-voting-cw4/Cargo.toml index 55c671560..6ad83eeb7 100644 --- a/contracts/voting/dao-voting-cw4/Cargo.toml +++ b/contracts/voting/dao-voting-cw4/Cargo.toml @@ -27,6 +27,7 @@ dao-dao-macros = { workspace = true } dao-interface = { workspace = true } cw4 = { workspace = true } cw4-group = { workspace = true } +cw-orch.workspace = true [dev-dependencies] cw-multi-test = { workspace = true } diff --git a/contracts/voting/dao-voting-cw4/src/msg.rs b/contracts/voting/dao-voting-cw4/src/msg.rs index 24bd0eebc..8ae8cc6b9 100644 --- a/contracts/voting/dao-voting-cw4/src/msg.rs +++ b/contracts/voting/dao-voting-cw4/src/msg.rs @@ -18,11 +18,12 @@ pub struct InstantiateMsg { } #[cw_serde] +#[derive(cw_orch::ExecuteFns)] pub enum ExecuteMsg {} #[voting_module_query] #[cw_serde] -#[derive(QueryResponses)] +#[derive(QueryResponses, cw_orch::QueryFns)] pub enum QueryMsg { #[returns(cosmwasm_std::Addr)] GroupContract {}, diff --git a/contracts/voting/dao-voting-cw721-roles/Cargo.toml b/contracts/voting/dao-voting-cw721-roles/Cargo.toml index e816d763c..3ad3128ea 100644 --- a/contracts/voting/dao-voting-cw721-roles/Cargo.toml +++ b/contracts/voting/dao-voting-cw721-roles/Cargo.toml @@ -29,6 +29,7 @@ cw-utils = { workspace = true } cw2 = { workspace = true } cw4 = { workspace = true } thiserror = { workspace = true } +cw-orch.workspace = true [dev-dependencies] cw-multi-test = { workspace = true } diff --git a/contracts/voting/dao-voting-cw721-roles/src/msg.rs b/contracts/voting/dao-voting-cw721-roles/src/msg.rs index b15099529..3a2314adf 100644 --- a/contracts/voting/dao-voting-cw721-roles/src/msg.rs +++ b/contracts/voting/dao-voting-cw721-roles/src/msg.rs @@ -44,11 +44,12 @@ pub struct InstantiateMsg { } #[cw_serde] +#[derive(cw_orch::ExecuteFns)] pub enum ExecuteMsg {} #[voting_module_query] #[cw_serde] -#[derive(QueryResponses)] +#[derive(QueryResponses, cw_orch::QueryFns)] pub enum QueryMsg { #[returns(crate::state::Config)] Config {}, diff --git a/contracts/voting/dao-voting-cw721-staked/Cargo.toml b/contracts/voting/dao-voting-cw721-staked/Cargo.toml index af7d5532e..edb6f2a9f 100644 --- a/contracts/voting/dao-voting-cw721-staked/Cargo.toml +++ b/contracts/voting/dao-voting-cw721-staked/Cargo.toml @@ -38,6 +38,7 @@ dao-hooks = { workspace = true } dao-interface = { workspace = true } dao-voting = { workspace = true } thiserror = { workspace = true } +cw-orch.workspace = true [dev-dependencies] anyhow = { workspace = true } diff --git a/contracts/voting/dao-voting-cw721-staked/src/msg.rs b/contracts/voting/dao-voting-cw721-staked/src/msg.rs index 837851ed3..d318ddb48 100644 --- a/contracts/voting/dao-voting-cw721-staked/src/msg.rs +++ b/contracts/voting/dao-voting-cw721-staked/src/msg.rs @@ -45,6 +45,7 @@ pub struct InstantiateMsg { } #[cw_serde] +#[derive(cw_orch::ExecuteFns)] pub enum ExecuteMsg { /// Used to stake NFTs. To stake a NFT send a cw721 send message /// to this contract with the NFT you would like to stake. The @@ -75,7 +76,7 @@ pub enum ExecuteMsg { #[active_query] #[voting_module_query] #[cw_serde] -#[derive(QueryResponses)] +#[derive(QueryResponses, cw_orch::QueryFns)] pub enum QueryMsg { #[returns(crate::state::Config)] Config {}, diff --git a/contracts/voting/dao-voting-token-staked/Cargo.toml b/contracts/voting/dao-voting-token-staked/Cargo.toml index 8be6ca1f6..e32a0f4cc 100644 --- a/contracts/voting/dao-voting-token-staked/Cargo.toml +++ b/contracts/voting/dao-voting-token-staked/Cargo.toml @@ -48,6 +48,7 @@ dao-voting = { workspace = true } cw-tokenfactory-issuer = { workspace = true, default-features = false, features = [ "library", ] } +cw-orch.workspace = true [dev-dependencies] anyhow = { workspace = true } diff --git a/contracts/voting/dao-voting-token-staked/src/msg.rs b/contracts/voting/dao-voting-token-staked/src/msg.rs index 98809ec9e..6a71bcaf1 100644 --- a/contracts/voting/dao-voting-token-staked/src/msg.rs +++ b/contracts/voting/dao-voting-token-staked/src/msg.rs @@ -36,6 +36,7 @@ pub struct InstantiateMsg { } #[cw_serde] +#[derive(cw_orch::ExecuteFns)] pub enum ExecuteMsg { /// Stakes tokens with the contract to get voting power in the DAO Stake {}, @@ -61,7 +62,7 @@ pub enum ExecuteMsg { #[active_query] #[voting_module_query] #[cw_serde] -#[derive(QueryResponses)] +#[derive(QueryResponses, cw_orch::QueryFns)] pub enum QueryMsg { #[returns(crate::state::Config)] GetConfig {},