Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/meteor/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Angularjs 队列任务中出现异常:TypeError:无法读取属性';拼接';指未定义的、有角的流星_Angularjs_Meteor_Angular Meteor_Minimongo_Meteor Publications - Fatal编程技术网

Angularjs 队列任务中出现异常:TypeError:无法读取属性';拼接';指未定义的、有角的流星

Angularjs 队列任务中出现异常:TypeError:无法读取属性';拼接';指未定义的、有角的流星,angularjs,meteor,angular-meteor,minimongo,meteor-publications,Angularjs,Meteor,Angular Meteor,Minimongo,Meteor Publications,我正在使用角流星为我的项目。当我删除“autopublish”并为我的集合添加发布方法时,当我尝试获取任何数据时,控制台中出现以下错误 Exception in queued task: TypeError: Cannot read property 'splice' of undefined at Object.addedAt (http://localhost:3000/packages/angular-meteor-data.js?36dfe4bee5b3da21eaa0d9bc0366a

我正在使用角流星为我的项目。当我删除“autopublish”并为我的集合添加发布方法时,当我尝试获取任何数据时,控制台中出现以下错误

Exception in queued task: TypeError: Cannot read property 'splice' of undefined
at Object.addedAt (http://localhost:3000/packages/angular-meteor-data.js?36dfe4bee5b3da21eaa0d9bc0366addac4788a1a:2191:24)
at observeChangesCallbacks.addedBefore (http://localhost:3000/packages/minimongo.js?cdf1a26cf7719fa9471a8017c3defd5aea812727:3623:28)
at Object.self.applyChange.addedBefore (http://localhost:3000/packages/minimongo.js?cdf1a26cf7719fa9471a8017c3defd5aea812727:3560:56)
at http://localhost:3000/packages/minimongo.js?cdf1a26cf7719fa9471a8017c3defd5aea812727:407:13
at _.extend.runTask (http://localhost:3000/packages/meteor.js?9730f4ff059088b3f7f14c0672d155218a1802d4:685:11)
at _.extend.flush (http://localhost:3000/packages/meteor.js?9730f4ff059088b3f7f14c0672d155218a1802d4:713:10)
at _.extend.drain (http://localhost:3000/packages/meteor.js?9730f4ff059088b3f7f14c0672d155218a1802d4:721:12)
at LocalCollection.insert (http://localhost:3000/packages/minimongo.js?cdf1a26cf7719fa9471a8017c3defd5aea812727:615:22)
at Object.self._connection.registerStore.update (http://localhost:3000/packages/mongo.js?69942a86515ec397dfd8cbb0a151a0eefdd9560d:250:28)
at Object.store.(anonymous function) [as update] (http://localhost:3000/packages/ddp-client.js?250b63e6c919c5383a0511ee4efbf42bb70a650f:3555:48)
很久以来,我一直试图解决这个问题,但找不到任何解决方案

我的控制器代码:

  controllerAs: 'dash',
  controller: function($scope, $reactive, $state) {
    $reactive(this).attach($scope);
     this.subscribe('sheets');
     this.helpers({
            sheets: () => {
              return Sheets.find({});
            }
          });
  }
}
并发布代码:

if (Meteor.isServer) {
Meteor.publish("sheets", function () {
return Sheets.find({});
 });
}

当我将“自动发布”添加到项目中时,我没有收到错误

此链接可能会引起您的兴趣。此链接可能会引起您的兴趣。