Skip to content

Commit

Permalink
Added other derives
Browse files Browse the repository at this point in the history
  • Loading branch information
Kayanski authored and Jake Hartnell committed Aug 14, 2024
1 parent 7bf054c commit 1cce2ea
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 5 deletions.
5 changes: 5 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions contracts/voting/dao-voting-cw20-staked/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }
3 changes: 2 additions & 1 deletion contracts/voting/dao-voting-cw20-staked/src/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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.
Expand Down
1 change: 1 addition & 0 deletions contracts/voting/dao-voting-cw4/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }
3 changes: 2 additions & 1 deletion contracts/voting/dao-voting-cw4/src/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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 {},
Expand Down
1 change: 1 addition & 0 deletions contracts/voting/dao-voting-cw721-roles/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }
Expand Down
3 changes: 2 additions & 1 deletion contracts/voting/dao-voting-cw721-roles/src/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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 {},
Expand Down
1 change: 1 addition & 0 deletions contracts/voting/dao-voting-cw721-staked/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }
Expand Down
3 changes: 2 additions & 1 deletion contracts/voting/dao-voting-cw721-staked/src/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -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 {},
Expand Down
1 change: 1 addition & 0 deletions contracts/voting/dao-voting-token-staked/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }
Expand Down
3 changes: 2 additions & 1 deletion contracts/voting/dao-voting-token-staked/src/msg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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 {},
Expand All @@ -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 {},
Expand Down

0 comments on commit 1cce2ea

Please sign in to comment.