Add empty primary key in new document

This commit is contained in:
Stanislav Romanov 2022-11-13 08:17:06 +03:00
parent c096e8943e
commit ac7fee5d0e

View file

@ -8,10 +8,8 @@ export default class AdminIndexesItemDocumentsNewRoute extends Route {
model() {
const index = this.modelFor('admin.indexes.item');
const document = new Document({ [index.primaryKey]: '' });
return hash({
index,
document: new Document(),
});
return hash({ index, document });
}
}