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

Wasm to submit proposals to the blockchain #877

Open
alenmestrov opened this issue Oct 28, 2024 · 1 comment
Open

Wasm to submit proposals to the blockchain #877

alenmestrov opened this issue Oct 28, 2024 · 1 comment
Assignees
Labels
blockchain-integrations Issues regarding Blockchain integrations needs-team-review

Comments

@alenmestrov
Copy link
Member

alenmestrov commented Oct 28, 2024

Needed is a mechanism to register user-defined functionality to handle proposals.

This could be done along the following lines:

Blockchain::register_proposal_function(|recipient| {
    pending_op = {
        balance,
        signature
    }
    ctx_contract.call("modify_value", contractor, pending_op)
}

In the above, modify_value is the name of a method that HAS to be defined and present so it can be used over the bridge (just like other similar methods), and pending_op is data that is already serialized to JSON – i.e. a JSON String.

This could also be achieved in other ways providing the core functionality is achievable.

@MatejVukosav
Copy link
Member

@danwilliams can u update description?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blockchain-integrations Issues regarding Blockchain integrations needs-team-review
Projects
Status: In progress
Development

No branches or pull requests

3 participants