Remove flag relation select (#3588)
* Remove feature flag on relation and select * Move packages back to twenty-server to enable smaller build without using nx * Fix package.json
This commit is contained in:
@ -1,17 +0,0 @@
|
||||
import { PrismaClient, Prisma } from '@prisma/client';
|
||||
|
||||
import { camelCase } from 'src/utils/camel-case';
|
||||
|
||||
const prisma = new PrismaClient();
|
||||
|
||||
export default async () => {
|
||||
const models = Prisma.dmmf.datamodel.models;
|
||||
const modelNames = models.map((model) => model.name);
|
||||
const entities = modelNames.map((modelName) => camelCase(modelName));
|
||||
|
||||
await prisma.$transaction(
|
||||
entities.map((entity) => {
|
||||
return prisma[entity].deleteMany();
|
||||
}),
|
||||
);
|
||||
};
|
||||
@ -1,5 +1,3 @@
|
||||
import resetDb from './reset-db';
|
||||
|
||||
global.beforeEach(() => {
|
||||
// resetDb();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user