2015-04-01 65 views

回答

1

的解决方案是之前添加:在Autoform.hooks与插入钩:功能在它,这将修改文档条目(这个工作参数必须在模式中定义)。例如:

AutoForm.hooks({ 
    'add-form': { 
     before:{ 
      insert:function(doc){ 
       doc.fileId = '1234; // doc is the data from the form. 
       return doc; // .fileId is the element we try to modify 
      } 
     } 
    } 
}); 
+0

提到架构的额外功劳需要该字段。这就是我被封锁的原因。 – IanBussieres 2015-06-19 00:52:05