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

added txid to object page #1793

Merged
merged 4 commits into from
May 4, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions explorer/client/src/pages/object-result/ObjectLoaded.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -223,12 +223,23 @@ function ObjectLoaded({ data }: { data: DataType }) {
/>
</div>
</div>
{data.data?.tx_digest && (
<div>
<div>Last Transaction ID</div>
<div id="transactionID">
<Longtext
text={data.data?.tx_digest}
category="transactions"
isLink={true}
/>
</div>
</div>
)}

<div>
<div>Version</div>
<div>{data.version}</div>
</div>

{data.readonly && (
<div>
<div>Read Only?</div>
Expand All @@ -249,7 +260,6 @@ function ObjectLoaded({ data }: { data: DataType }) {
)}
</div>
)}

<div>
<div>Type</div>
<div>{prepObjTypeValue(data.objType)}</div>
Expand Down Expand Up @@ -280,7 +290,6 @@ function ObjectLoaded({ data }: { data: DataType }) {
/>
</div>
)}

{data.ethAddress && (
<div>
<div>Ethereum Contract Address</div>
Expand Down
2 changes: 1 addition & 1 deletion explorer/client/src/pages/object-result/ObjectResult.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const DATATYPE_DEFAULT: DataType = {
data: {
contents: {},
owner: { ObjectOwner: [] },
tx_digest: [],
tx_digest: '',
},
loadState: 'pending',
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export type DataType = {
[key: string]: any;
};
owner?: { ObjectOwner: [] };
tx_digest?: number[] | string;
tx_digest?: string;
};
loadState?: string;
};
Expand Down