console: fix custom root field placeholder for insert one mutation (close #5345) (#5346)

This commit is contained in:
Todd Heslin 2020-07-21 02:15:52 +12:00 committed by GitHub
parent 0780ceef03
commit a677c62dae
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -33,6 +33,9 @@ const RootFieldEditor = ({
if (rfType.includes('select')) {
return rfType.replace('select', tableName);
}
if (rfType.includes('one')) {
return rfType.replace('one', tableName) + '_one';
}
return `${rfType}_${tableName}`;
};