-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathboundToDirective.react.html
51 lines (47 loc) · 1.95 KB
/
boundToDirective.react.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>react component bound to controller</title>
<link rel="stylesheet" href="bower_components/bootstrap/dist/css/bootstrap.min.css">
<style>
.main-container {
width: 95%;
margin-left: auto;
margin-right: auto;
margin-top: 100px;
}
input[type=text]{
width: 100%;
}
</style>
</head>
<body ng-app="app">
<div class="main-container">
<div ng-controller="BoundToDirectiveController as vm">
<h1>AnyTable-Data</h1>
<div class="row">
<div class="col-md-4">
<button ng-click="vm.updateSingelValue()" class="btn btn-info pull-right">Update Single Value</button>
<button ng-click="vm.regenerate()" class="btn btn-info pull-right">Cycle TableData</button>
</div>
<div class="col-md-4">
<input type="text" placeholder="i trigger a live update.." ng-model="vm.liveUpdate" class="form-control"/>
</div>
<div class="col-md-4">
<input type="text" placeholder="filter by first name (case sensitive)" ng-model="vm.filterQuery" ng-change="vm.filterTable(vm.filterQuery)" class="form-control"/>
</div>
</div>
<bound-to-directive table="vm.tableViewData" on-col-click="vm.sortTable" live-update="vm.liveUpdate"></bound-to-directive>
</div>
</div>
<script src="bower_components/jquery/dist/jquery.min.js"></script>
<script src="bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="bower_components/angular/angular.js"></script>
<script src="bower_components/react/react.js"></script>
<script src="bower_components/react/react-dom.js"></script>
<script src="bower_components/ngreact/ngReact.min.js"></script>
<script src="app/app.js"></script>
<script src="app/components/bound-to-directive/bound-to-directive.js"></script>
</body>
</html>