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

Trading trait and deal with metadata in Mutate trait for nonfungibles_v2 #1561

Merged
merged 10 commits into from
Oct 18, 2023

Conversation

AlexD10S
Copy link
Contributor

@AlexD10S AlexD10S commented Sep 14, 2023

I have added some Traits that are missing and are useful for dealing with non-fungible tokens on other pallets and their implementations for NFTs pallet.

  • In the Mutate trait, added methods for dealing with the metadata: set_metadata, set_collection_metadata, clear_metadata and clear_collection_metadata.
    The motivation of adding this methods coming from a StackExchange question asking for it: Setting metadata of an item of the Nfts pallet in a custom pallet

  • A Trait for trading non-fungible items. The methods in that Trait are buy_item, set_price and item_price
    An example of where this Trait can be useful is a pallet that deals with NFT Royalties and needs to perform this actions.

@AlexD10S AlexD10S changed the title Trading trait for nonfungibles_v2 Trading and more Mutate traits for nonfungibles_v2 Sep 21, 2023
@AlexD10S AlexD10S changed the title Trading and more Mutate traits for nonfungibles_v2 Trading and more Mutate methods for nonfungibles_v2 Sep 21, 2023
@AlexD10S AlexD10S changed the title Trading and more Mutate methods for nonfungibles_v2 Trading trait and deal with metadata in Mutate trait for nonfungibles_v2 Sep 21, 2023
@AlexD10S AlexD10S marked this pull request as ready for review September 29, 2023 08:10
@AlexD10S AlexD10S requested review from a team September 29, 2023 08:10
Copy link
Contributor

@sacha-l sacha-l left a comment

Choose a reason for hiding this comment

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

Nice ! 🚀

@paritytech-cicd-pr
Copy link

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-clippy
Logs: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/3981653

@jsidorenko
Copy link
Contributor

bot merge

@command-bot
Copy link

command-bot bot commented Oct 18, 2023

@jsidorenko bot merge and bot rebase are not supported anymore. Please use native Github "Auto-Merge" and "Update Branch" buttons instead.
image

@jsidorenko jsidorenko merged commit 3aaf62a into master Oct 18, 2023
109 of 111 checks passed
@jsidorenko jsidorenko deleted the alexd10s-trading-traits-nonfungibles_v2 branch October 18, 2023 10:33
ordian added a commit that referenced this pull request Oct 20, 2023
* tsv-disabling: (39 commits)
  Handling of disabled validators in backing subsystem (#1259)
  Switch trie cache random seed (#1935)
  Expose prometheus metrics for minimal-relay-chain node in collators (#1942)
  Do not force collators to update after enabling async backing (#1920)
  Pin PRDoc image to v0.0.5 until we are ready for v0.0.6 (#1947)
  [prdoc] Start BEEFY gadget by default for Polkadot nodes (#1945)
  Update bridges subtree  (#1944)
  bump zombienet version (#1931)
  [FRAME] Message Queue use proper overweight limit (#1873)
  Cumulus: Allow aura to use initialized collation request receiver (#1911)
  Use prebuilt try-runtime binary in CI (#1898)
  Update kusama/polkadot bootnodes (#1895)
  Introduce XcmFeesToAccount fee manager (#1234)
  upgraded review bot to v2.1.0 (#1908)
  Trading trait and deal with metadata in Mutate trait for nonfungibles_v2 (#1561)
  Add Runtime Missing Crate Descriptions (#1909)
  Switch to the release env (#1910)
  Bump paritytech/review-bot from 2.0.1 to 2.1.0 (#1924)
  Bump actions/checkout from 4.1.0 to 4.1.1 (#1925)
  Start BEEFY client by default for Polkadot nodes (#1913)
  ...
tdimitrov pushed a commit that referenced this pull request Oct 23, 2023
…_v2 (#1561)

I have added some Traits that are missing and are useful for dealing
with non-fungible tokens on other pallets and their implementations for
NFTs pallet.

- In the Mutate trait, added methods for dealing with the metadata:
`set_metadata`, `set_collection_metadata`, `clear_metadata` and
`clear_collection_metadata`.
The motivation of adding this methods coming from a StackExchange
question asking for it: [Setting metadata of an item of the Nfts pallet
in a custom
pallet](https://substrate.stackexchange.com/questions/9974/setting-metadata-of-an-item-of-the-nfts-pallet-in-a-custom-pallet)

- A Trait for trading non-fungible items. The methods in that Trait are
`buy_item`, `set_price` and `item_price`
An example of where this Trait can be useful is a pallet that deals with
[NFT
Royalties](https://forum.polkadot.network/t/nfts-royalty-pallet/3766)
and needs to perform this actions.

---------

Co-authored-by: Jegor Sidorenko <5252494+jsidorenko@users.noreply.github.com>
@Polkadot-Forum
Copy link

This pull request has been mentioned on Polkadot Forum. There might be relevant details there:

https://forum.polkadot.network/t/polkadot-release-analysis-v1-3-0/4614/1

bgallois pushed a commit to duniter/duniter-polkadot-sdk that referenced this pull request Mar 25, 2024
…_v2 (paritytech#1561)

I have added some Traits that are missing and are useful for dealing
with non-fungible tokens on other pallets and their implementations for
NFTs pallet.

- In the Mutate trait, added methods for dealing with the metadata:
`set_metadata`, `set_collection_metadata`, `clear_metadata` and
`clear_collection_metadata`.
The motivation of adding this methods coming from a StackExchange
question asking for it: [Setting metadata of an item of the Nfts pallet
in a custom
pallet](https://substrate.stackexchange.com/questions/9974/setting-metadata-of-an-item-of-the-nfts-pallet-in-a-custom-pallet)

- A Trait for trading non-fungible items. The methods in that Trait are
`buy_item`, `set_price` and `item_price`
An example of where this Trait can be useful is a pallet that deals with
[NFT
Royalties](https://forum.polkadot.network/t/nfts-royalty-pallet/3766)
and needs to perform this actions.

---------

Co-authored-by: Jegor Sidorenko <5252494+jsidorenko@users.noreply.github.com>
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 8, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 8, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 8, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 8, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 9, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 9, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 9, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 9, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 9, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 9, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 10, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
serban300 pushed a commit to serban300/polkadot-sdk that referenced this pull request Apr 10, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
bkchr pushed a commit that referenced this pull request Apr 10, 2024
* change sign_transaction method

* clippy

* rustup update && clippy

* remove redudnant clone
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T2-pallets This PR/Issue is related to a particular pallet.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants