-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feature: Split getPluginSetings in getVotingSettings and getMembers (#…
…147) * add getMembers and getVotingSettings * update changelog * update version
- Loading branch information
1 parent
d072b24
commit c201f8f
Showing
11 changed files
with
169 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
modules/client/examples/06-multisig-client/12-get-members.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
/* MARKDOWN | ||
### Loading the list of members (multisig plugin) | ||
*/ | ||
import { | ||
Context, | ||
ContextPlugin, | ||
MultisigClient, | ||
MultisigVotingSettings, | ||
} from "@aragon/sdk-client"; | ||
import { contextParams } from "../00-client/00-context"; | ||
|
||
// Create a simple context | ||
const context: Context = new Context(contextParams); | ||
// Create a plugin context from the simple context | ||
const contextPlugin: ContextPlugin = ContextPlugin.fromContext(context); | ||
// Create an multisig client | ||
const client = new MultisigClient(contextPlugin); | ||
|
||
const daoAddressorEns = "0x12345..."; | ||
|
||
const settings: string[] = await client.methods | ||
.getMembers(daoAddressorEns); | ||
console.log(settings); | ||
/* | ||
[ | ||
"0x1234567890...", | ||
"0x2345678901...", | ||
"0x3456789012...", | ||
] | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
modules/client/src/multisig/internal/graphql-queries/members.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { gql } from "graphql-request"; | ||
|
||
export const QueryMultisigMembers = gql` | ||
query MultisigMembers($address: ID!) { | ||
multisigPlugin(id: $address){ | ||
members { | ||
address | ||
} | ||
} | ||
} | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters