1
0
mirror of https://github.com/oceanprotocol/market.git synced 2024-12-02 05:57:29 +01:00

fix your compute jobs section when asset network not selected

This commit is contained in:
Bogdan Fazakas 2022-04-29 10:18:26 +03:00
parent ad9ecd034c
commit 759c9332a0
2 changed files with 5 additions and 3 deletions

View File

@ -527,7 +527,7 @@ export default function Compute({
</footer> </footer>
{accountId && asset?.accessDetails?.datatoken && ( {accountId && asset?.accessDetails?.datatoken && (
<AssetActionHistoryTable title="Your Compute Jobs"> <AssetActionHistoryTable title="Your Compute Jobs">
<ComputeJobs minimal /> <ComputeJobs minimal assetChainId={[asset?.chainId]} />
</AssetActionHistoryTable> </AssetActionHistoryTable>
)} )}
</> </>

View File

@ -70,9 +70,11 @@ const columns = [
] ]
export default function ComputeJobs({ export default function ComputeJobs({
minimal minimal,
assetChainId
}: { }: {
minimal?: boolean minimal?: boolean
assetChainId?: number[]
}): ReactElement { }): ReactElement {
const { accountId, networkId } = useWeb3() const { accountId, networkId } = useWeb3()
const { asset } = useAsset() const { asset } = useAsset()
@ -93,7 +95,7 @@ export default function ComputeJobs({
try { try {
setIsLoading(true) setIsLoading(true)
const jobs = await getComputeJobs( const jobs = await getComputeJobs(
chainIds, assetChainId || chainIds,
accountId, accountId,
asset, asset,
newCancelToken() newCancelToken()