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

form model fixes

This commit is contained in:
Matthias Kretschmann 2020-07-28 14:32:45 +02:00
parent ef02919e5e
commit 8f19f8ac4e
Signed by: m
GPG Key ID: 606EEEF3C479A91F
2 changed files with 8 additions and 6 deletions

View File

@ -7,8 +7,8 @@ import styles from './index.module.css'
import PublishForm from './PublishForm'
import Web3Feedback from '../../molecules/Wallet/Feedback'
import { FormContent } from '../../../@types/Form'
import { initialValues, validationSchema } from './validation'
import { MetadataPublishForm, MetadataMarket } from '../../../@types/Metadata'
import { initialValues, validationSchema } from '../../../models/FormPublish'
import { MetadataPublishForm } from '../../../@types/Metadata'
import { transformPublishFormToMetadata } from './utils'
import Preview from './Preview'
@ -40,9 +40,11 @@ export default function PublishPage({
`)
try {
const ddo = await publish(metadata as any, tokensToMint, [
{ serviceType, cost }
])
const ddo = await publish(
metadata as any,
tokensToMint.toString(),
[{ serviceType, cost: cost.toString() }]
)
if (publishError) {
toast.error(publishError)

View File

@ -1,4 +1,4 @@
import { MetadataPublishForm } from '../../../@types/Metadata'
import { MetadataPublishForm } from '../@types/Metadata'
import { File as FileMetadata } from '@oceanprotocol/lib'
import * as Yup from 'yup'