如何在点击后以动态方式初始化此对象并将其绑定到模板中?
$scope.send = function(){
var setting = {};
var uploader = new FileUploader({
url: settings.path,
alias: settings.alias,
formData: settings.data,
autoUpload: true,
queueLimit: settings.limit
});
}
对象uploader
将在模板中可用:
<div class="attachements" nv-file-drop="" uploader="uploader"></div>
现在,在加载页面后我收到错误,应该定义uploader
:
TypeError:“Uploader”必须是FileUploader的实例