这是指令
(function() {
'use strict';
angular
.module('angle')
.directive('tsDynamicDetailsList', tsDynamicDetailsList);
tsDynamicDetailsList.$inject = ['$window'];
function tsDynamicDetailsList($window) {
// Usage:
// <ts_dynamic_details_list></ts_dynamic_details_list>
// Creates:
//
var directive = {
link: link,
restrict: 'E',
templateUrl: 'app/views/partials/tsDynamicDetailsList.html',
scope: {
singleItemName: '=',
list: '=',
snippetPartial: '=',
detailsPartial: '='
}
};
return directive;
function link(scope, element, attrs) {
}
}
})();
我称之为:
<ts-dynamic-details-list singleItemName="'user'" list="users" snippetPartial="'userListSnippet.html'" detailsPartial="'userListDetail.html'"></ts-dynamic-details-list>
什么都没有加载。 tsDynamicDetailsList.html肯定存在。所有的建议都表示赞赏,提前谢谢。