<div ng-controller="LearnCenterListCtrl" class="wrapper">
	<div class="panel panel-default">
		<div class="panel-body">
			<button ng-click="goUpload()" class="btn btn-default" 
				ng-if="curUserRole.code=='processManagement' 
							|| (curUser.userType == userType.secretary && categoryCode == 'sczx')">
							<!-- 学科秘书只能上传素材 -->
				<i class="glyphicon glyphicon-upload">上传文件</i>
			</button>
			
			<table class="table table-striped">
				<thead>
					<tr>
						<th>序号</th>
						<th>文档名称</th>
						<th>课程代码</th>
						<th>操作</th>
					</tr>										
				</thead>
				<tbody>
					<tr ng-repeat="row in array | filter:search">
						<td>{{$index+1}}</td>
						<td>
							<a target='_blank' href="attachment/preview/{{row.attachmentId}}">
								{{row.keyword}}
							</a>
						</td>
						<td>{{row.courseCode}}</td>
						<td>
							<a target='_blank' href="attachment/download/{{row.attachmentId}}">
								<i class="glyphicon glyphicon-download">下载</i>
							</a>
							
							<a href="#" ng-click="deleteRow(row)" class="text-danger" ng-if="curUserRole.code=='processManagement'">
								&nbsp;
								<i class="glyphicon glyphicon-trash">删除</i>								
							</a>
						</td>
					</tr>
				</tbody>

			</table>
		</div>
	</div>
</div>