Javascript angularjs中缺少绑定值
我使用push,但在index.html中Javascript angularjs中缺少绑定值,javascript,angularjs,Javascript,Angularjs,我使用push,但在index.html中{{tab.tabName}返回空白(第46行)这是您的问题:(在app.js中,在addTab函数下) “名称”:资本家密码(this.NewTabName), 应该是: “tabName”:资本家firstletter(this.NewTabName), 替换: $scope.tabs.push({ "tabId": tabId = tabId + 1, "name" : capitaliseFirstLetter(this.NewT
{{tab.tabName}
返回空白(第46行)这是您的问题:(在app.js中,在addTab函数下)
“名称”:资本家密码(this.NewTabName),
应该是:
“tabName”:资本家firstletter(this.NewTabName),
替换:
$scope.tabs.push({
"tabId": tabId = tabId + 1,
"name" : capitaliseFirstLetter(this.NewTabName),
"active" : true
});
到
@NitishKumar不,不,尝试键入一些内容,然后单击“添加”按钮。您继续放置tab.tabName,但它是tab.name。解决这个问题
$scope.tabs.push({
"tabId": tabId = tabId + 1,
"name" : capitaliseFirstLetter(this.NewTabName),
"active" : true
});
$scope.tabs.push({
"tabId": tabId += 1,
"tabName" : capitaliseFirstLetter(this.NewTabName),
"active" : true
});