Skip to content

add reverse record#15

Open
cloud8little wants to merge 1 commit intoneo-project:masterfrom
cloud8little:add_reverserecord
Open

add reverse record#15
cloud8little wants to merge 1 commit intoneo-project:masterfrom
cloud8little:add_reverserecord

Conversation

@cloud8little
Copy link
Contributor

@cloud8little cloud8little commented Jun 16, 2022

  1. add setReverseRecord method, if there is any domain name ever set TXT record with this address, set successful. if the domain name is expired, set failed.
  2. add getReverseRecord method, if there is any domain name ever set TXT record with this address, and setReverseRecord already, get the name. if the domain name is expired, get failed.
  3. when register for expired token, clear the reverse record.

StorageContext context = Storage.CurrentContext;
StorageMap reverseMap = new(context, Prefix_ReverseRecord);
string record = GetRecord(name, RecordType.TXT);
if (record == owner.ToAddress(53))
Copy link
Member

Choose a reason for hiding this comment

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

I prefer to use the protocol settings value

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I prefer to use the protocol settings value

how to get the settings value from smart contract?

Copy link
Member

Choose a reason for hiding this comment

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

System.Runtime.GetAddressVersion

@cloud8little cloud8little changed the title add reverse record and clear records of expired token add reverse record Jun 17, 2022
@gsmachado gsmachado mentioned this pull request Oct 27, 2022
@cschuchardt88
Copy link
Member

Any update on this?

@Jim8y
Copy link

Jim8y commented Dec 17, 2023

@cloud8little any plan to complete this?

@cloud8little
Copy link
Contributor Author

@cloud8little any plan to complete this?

We have a seperate smart contract to analyze the reverse record now.

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.

4 participants