-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdemo42.html
50 lines (46 loc) · 1.09 KB
/
demo42.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
<!DOCTYPE html>
<html ng-app="myApp">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Examples</title>
<meta name="description" content="">
<meta name="keywords" content="">
<link href="" rel="stylesheet">
</head>
<body>
<script src="js/jquery-1.10.2.min.js"></script>
<script src="http://apps.bdimg.com/libs/angular.js/1.4.6/angular.min.js"></script>
<script>
var app = angular.module('myApp', []);
app.controller("ngselect4",['$scope',function($sc){
$sc.text1 = "hello";
$sc.click = function(){
console.log(1);
};
}]);
</script>
<script>
$(function(){
var i = true;
$(".demo").click(function(){
if(i == true ){
$(".jiantou").css({"background":"#ccc"})
i = false;
}else{
$(".jiantou").css({"background":"#f00"})
i = true;
}
})
})
</script>
<div ng-controller="ngselect4">
<span>{{text1}}</span>
</div>
<div class="demo">
<div class="jiantou">
123456
</div>
</div>
</body>
</html>