1
我怎样才能改变this.messages myfunction2里面???谢谢Angularjs服务,如何更改服务功能内的服务属性?
app.service('myservice', function() {
this.messages=[];
this.myfunction1=function(){
//Stuff
function myfunction2(){
//"How to access this.messages now?
}
}
});
完美,谢谢! – lukabers 2014-11-04 09:46:50