(table, values)
| 301 | ); |
| 302 | }, |
| 303 | async createMany(table, values) { |
| 304 | await init; |
| 305 | const idField = table.getIdColumn().names.prisma; |
| 306 | if (relationMode === "prisma") { |
| 307 | await Promise.all( |
| 308 | table.foreignKeys.map((key) => |
| 309 | checkForeignKeyOnInsert(this, key, values), |
| 310 | ), |
| 311 | ); |
| 312 | } |
| 313 | |
| 314 | values = values.map((value) => mapValues(table, value, true)); |
| 315 | await getPrismaModel(table).createMany({ data: values }); |
| 316 | return values.map((value) => ({ _id: value[idField] })); |
| 317 | }, |
| 318 | async deleteMany(table, v) { |
| 319 | await init; |
| 320 | const model = getPrismaModel(table); |
nothing calls this directly
no test coverage detected