我有以下应用程序配置,应该加载一整页,但相反它什么都没显示,当我检查控制台时它完全为空,零错误:
我的代码如下:
App.js
'use strict';
angular.module('inspinia', ['ngRoute', 'AdalAngular'])
.config(['$routeProvider', '$httpProvider', 'adalAuthenticationServiceProvider', function ($routeProvider, $httpProvider, adalAuthenticationServiceProvider) {
$routeProvider.when("/dashboard_1", {
controller: "MainCtrl",
templateUrl: "/views/dashboard_1.html",
resolve: {
loadPlugin: function ($ocLazyLoad) {
return $ocLazyLoad.load([
{
serie: true,
name: 'angular-flot',
files: ['js/plugins/flot/jquery.flot.js', 'js/plugins/flot/jquery.flot.time.js', 'js/plugins/flot/jquery.flot.tooltip.min.js', 'js/plugins/flot/jquery.flot.spline.js', 'js/plugins/flot/jquery.flot.resize.js', 'js/plugins/flot/jquery.flot.pie.js', 'js/plugins/flot/curvedLines.js', 'js/plugins/flot/angular-flot.js', ]
},
{
name: 'angles',
files: ['js/plugins/chartJs/angles.js', 'js/plugins/chartJs/Chart.min.js']
},
{
name: 'angular-peity',
files: ['js/plugins/peity/jquery.peity.min.js', 'js/plugins/peity/angular-peity.js']
}
]);
}
}
}).otherwise({ redirectTo: "/dashboard_1" });
}]);
Run Code Online (Sandbox Code Playgroud)
的index.html
<!DOCTYPE html>
<html ng-app="inspinia">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0"> …
Run Code Online (Sandbox Code Playgroud) 行是动态绘制的,还有删除每行的按钮。
<span className="ms-Table-cell">
<div>
<IconButton
onClick= { this._removeItemFromDetail }
id={ detail.Id.toString() }
iconProps={ { iconName: 'Cancel' } }
title='Delete' />
</div>
</span>
private _removeItemFromDetail(e) {
console.log("e.target",e.target);
}
Run Code Online (Sandbox Code Playgroud)
问题是,每次我在控制台中单击删除按钮时,都会向我显示:
因此,我无法访问Button Id属性,但这仅在发布Webpart时发生。有谁知道如何解决?
谢谢!