import gql from 'graphql-tag' ; export const getExecutedMotionsWithPreimageHash = gql `
    query getExecutedMotionsWithPreimageHash($preimageHash: String!, $blockNumber: Int!) {
        motions(
            where: {
                AND: [
                    { motionStatus_some : {blockNumber: {number_lt : $blockNumber}}}
                    { motionStatus_some: { status: "Executed" } }
                    { preimageHash: $preimageHash }
                ]
            }
            orderBy: id_DESC
        ) {
            motionProposalId
        }
    }
` ; export const getTabledProposalsAtBlockQuery = gql `
    query getTabledProposalAtBlock($blockNumber: Int!) {
        proposals(
            where: {
                proposalStatus_some: {
                    AND: [
                        {
                            blockNumber: {
                                number: $blockNumber
                            }
                        },
                        { status: "Tabled" }
                    ]
                }
            }
        ) {
            proposalId
                preimage {
                    hash
                }
        }
    }
` ;