-
Notifications
You must be signed in to change notification settings - Fork 3
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
MCR-3900 Can continue or save as draft with new API #2313
Changes from all commits
f35608a
d09dc10
2e79ac5
eedb097
085ceff
299208f
96ec412
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -62,7 +62,24 @@ Amplify.configure({ | |
|
||
const authMode = process.env.REACT_APP_AUTH_MODE | ||
assertIsAuthMode(authMode) | ||
const cache = new InMemoryCache() | ||
const cache = new InMemoryCache({ | ||
typePolicies: { | ||
ContractRevision: { | ||
fields: { | ||
formData: { | ||
merge: true, | ||
}, | ||
}, | ||
}, | ||
RateRevision: { | ||
fields: { | ||
formData: { | ||
merge: true, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Getting GQL warnings (not blocking but they clutter the console) because form datas dont have Following docs, I believe this is the proper way to address but welcome other eyes. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. interesting, funny because these aren't really stand alone objects, we just made formData to wrap the data up nicely. This looks right to me based on those docs |
||
}, | ||
}, | ||
}, | ||
}, | ||
}) | ||
const defaultOptions: DefaultOptions = { | ||
watchQuery: { | ||
fetchPolicy: 'network-only', | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,7 +16,7 @@ describe('LinkYourRates', () => { | |
onSubmit={(values) => console.info('submitted', values)} | ||
> | ||
<form> | ||
<LinkYourRates fieldNamePrefix="rates.1" index={1} /> | ||
<LinkYourRates fieldNamePrefix="rateForms.1" index={1} /> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. good name change |
||
</form> | ||
</Formik>, | ||
{ | ||
|
@@ -48,7 +48,7 @@ describe('LinkYourRates', () => { | |
onSubmit={(values) => console.info('submitted', values)} | ||
> | ||
<form> | ||
<LinkYourRates fieldNamePrefix="rates.1" index={1} /> | ||
<LinkYourRates fieldNamePrefix="rateForms.1" index={1} /> | ||
</form> | ||
</Formik>, | ||
{ | ||
|
@@ -83,7 +83,7 @@ describe('LinkYourRates', () => { | |
onSubmit={(values) => console.info('submitted', values)} | ||
> | ||
<form> | ||
<LinkYourRates fieldNamePrefix="rates.1" index={1} /> | ||
<LinkYourRates fieldNamePrefix="rateForms.1" index={1} /> | ||
</form> | ||
</Formik>, | ||
{ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suspect you could just use
any
here and it would work the same as the generic parameter