将一块加入模块时,编辑器模式保存期间出现 ApostropheCMS 错误

ApostropheCMS error during editor modal save when joining a piece to a module

我创建了一个新的 "modal" 片段,我将在其中加入另一个模块(这样我就可以在模态中显示模块)。我可以 select 编辑器模式中的模块,但是当我保存时,我弹出这个错误: An error occurred. Please try again later. 前端控制台显示这是来自 /modules/apostrophe-browser-utils/js/always.js

我只有这样的 /lib/modules/modal/index.js 文件:

module.exports = {
    extend: "apostrophe-pieces",
    name: "modal",
    label: "Modal",
    seo: false,
    addFields: [
      {
        name: "_image",
        type: "joinByOne",
        withType: "apostrophe-image",
        label: "Pick an image",
        required: true,
        idField: "_id",
        filters: {
          // Thought maybe not having a projection was an issue. didn't help
          projection: {
            attachment: 1
          }
        }
      }
    ]
  };

屏幕截图:https://screencast.com/t/OGQOD0PiG

idField 名称与所有撇号文档的默认 ID 属性 冲突。将其更改为类似 imageId 的内容。在除 _id 之外的所有情况下,撇号中的 _ 前缀表示 属性 在某些时候被撇号 'filled in',实际上并没有与文档一起保存。