2013-07-12 43 views
1

我Plunker:http://plnkr.co/edit/xrzhG9NqYfv2Mbskbh1D?p=previewNG-包括莫代爾第一參考書,第二參考失敗

在堅果殼,我有我的index.html下面列出的代碼

<div data-ng-controller="addCtrl" data-ng-include="'app/views/add.html'" /> 
<div data-ng-controller="editCtrl" data-ng-include="'app/views/edit.html'" /> 

我有兩個按鈕,其中一個顯示add.html,另一個edit.html通過$broadcast 使用當前順序添加作品,但編輯不。如果我翻轉訂單,例如:

<div data-ng-controller="editCtrl" data-ng-include="'app/views/edit.html'" /> 
<div data-ng-controller="addCtrl" data-ng-include="'app/views/add.html'" /> 

然後編輯工作,但添加不。 這可能與爲什麼我的上一個問題搞砸了,但不知道:"Element is not currently visible and so may not be interacted with" but another is?

回答

2

看來,角不能部分<div />表示法。

擴展爲<div ...></div>的作品。