我想用一个查询针对 10 个查询插入 10 个条目。
我需要设置一些东西吗?我根本不知道该怎么办。
带有示例的仓库:https://github.com/mathias22osterhagen22/loopback-array-post-sample
编辑:people-model.ts:
import {Entity, model, property} from '@loopback/repository';
@model()
export class People extends Entity {
@property({
type: 'number',
id: true,
generated: true,
})
id?: number;
@property({
type: 'string',
required: true,
})
name: string;
constructor(data?: Partial<People>) {
super(data);
}
}
export interface PeopleRelations {
// describe navigational properties here
}
export type PeopleWithRelations = People & PeopleRelations;
Run Code Online (Sandbox Code Playgroud)