所以這應該很簡單,我只是想用Formly在嵌套窗體中組合一個重複部分。Angular Formly - 將嵌套窗體與重複部分結合起來
有一些例子可以單獨做這些,但我找不到任何結合這些功能的例子。
重複節 http://jsbin.com/murule/32/edit?js,output
嵌套形式 http://jsbin.com/zaqeke/22/edit?js,output
我會非常感激的人誰可以幫助!
如果可能,一個例子會很棒。
所以這應該很簡單,我只是想用Formly在嵌套窗體中組合一個重複部分。Angular Formly - 將嵌套窗體與重複部分結合起來
有一些例子可以單獨做這些,但我找不到任何結合這些功能的例子。
重複節 http://jsbin.com/murule/32/edit?js,output
嵌套形式 http://jsbin.com/zaqeke/22/edit?js,output
我會非常感激的人誰可以幫助!
如果可能,一個例子會很棒。
Repeating Section
是Nested Form
一個複雜的例子可以在repeatSection.html
中繼ng-repeat="element in model[options.key]"
<div class="repeatsection" ng-repeat="element in model[options.key]" ng-init="fields = copyFields(to.fields)"> <formly-form fields="fields" model="element" form="form"> </formly-form> <div style="margin-bottom:20px;"> <button type="button" class="btn btn-sm btn-danger" ng-click="model[options.key].splice($index, 1)"> Remove </button> </div>