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

feat(client:go): add batch create contract #689

Merged
merged 3 commits into from
May 8, 2023

Conversation

AbdelrahmanElawady
Copy link
Contributor

@AbdelrahmanElawady AbdelrahmanElawady commented May 3, 2023

add batch and batch all for create contracts

@@ -233,6 +233,113 @@ func (s *Substrate) CreateNodeContract(identity Identity, node uint32, body stri
return s.GetContractWithHash(node, h)
}

// BatchCreateContractData struct for batch create contract
type BatchCreateContractData struct {
Node uint32
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add json tags please? We need them for the web3 proxy.

// and other fields are ignored
Name string

hexHash HexHash
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This field will be private, it doesn't start with upper case.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that was intentional as it is generated internally and not provided by user, should it be public?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you don't return this object then no there is no use to it.

// and other fields are ignored
Name string

hexHash HexHash
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you don't return this object then no there is no use to it.

@DylanVerstraete DylanVerstraete merged commit 7ffdc0b into development May 8, 2023
@DylanVerstraete DylanVerstraete deleted the development_add_batch_create_contract branch May 8, 2023 10:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants