【发布时间】:2016-04-16 15:05:51
【问题描述】:
我知道这种方式可以获取数据。
th:attr="ng-click='method(\''+${ans.numbers}+'\',true);
但我不想要这个点击事件。我只想要页面初始化时的这个数据。
【问题讨论】:
标签: angularjs spring thymeleaf
我知道这种方式可以获取数据。
th:attr="ng-click='method(\''+${ans.numbers}+'\',true);
但我不想要这个点击事件。我只想要页面初始化时的这个数据。
【问题讨论】:
标签: angularjs spring thymeleaf
试试这个
th:attr="ng-init='method(\''+${ans.numbers}+'\',true);
【讨论】:
ArrayList 传递给角度?我在thymeleaf 中有一个List。
$scope.List array 并分配您的结果并使用ng-repeat 指令在您的视图中访问它
ng-init只发生一次,不是吗?