ソースを参照

关注页面,修改初始化过滤条与列表之间有空白区域

xuchunyang 8 年 前
コミット
c7c024d5a1
共有3 個のファイルを変更した23 個の追加33 個の削除を含む
  1. 13 0
      app/html/attentions-list.html
  2. 4 17
      app/js/attentions.js
  3. 6 16
      app/js/attentions2.js

+ 13 - 0
app/html/attentions-list.html

@ -8,6 +8,7 @@
8 8
    <link href="../css/mui.min.css" rel="stylesheet"/>
9 9
    <link href="../css/iconfont.css" rel="stylesheet" />
10 10
    <link href="../css/app.css" rel="stylesheet"/>
11
    
11 12
</head>
12 13
<body>
13 14
	
@ -32,5 +33,17 @@
32 33
    <script src="../js/public/mui.min.js"></script>
33 34
	<script src="../js/public/base.js"></script>
34 35
	<script src="../js/attentions.js"></script>
36
	<script type="text/javascript">
37
		var box = document.getElementById("pullrefresh");
38
		var u = navigator.userAgent;
39
		var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Adr') > -1; //android终端
40
		var isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端
41
		if(isAndroid){
42
			//box.style.paddingTop="90px";
43
		}
44
		if(isiOS){
45
			box.style.top="90px";
46
		}
47
	</script>
35 48
</body>
36 49
</html>

+ 4 - 17
app/js/attentions.js

@ -8,9 +8,9 @@ var nodatabox1 = document.getElementById("nodatabox1");
8 8
mui.init({
9 9
	pullRefresh: {
10 10
		container: '#pullrefresh',
11
		down: {
11
		/*down: {
12 12
				callback: pulldownRefresh
13
			  },
13
			  },*/
14 14
		up: {
15 15
			contentrefresh: '正在加载...',
16 16
			callback: pullupRefresh,
@ -27,26 +27,13 @@ function pullupRefresh() {
27 27
	mui('#pullrefresh').pullRefresh().refresh(true);
28 28
}
29 29

30
function pulldownRefresh() {
30
/*function pulldownRefresh() {
31 31
	setTimeout(function() {
32 32
		getOneExpert(1, 10);	
33 33
		mui('#pullrefresh').pullRefresh().endPulldownToRefresh();
34 34
	}, 1000);
35 35
}
36

37

38
if(mui.os.plus) {
39
	mui.plusReady(function() {
40
		setTimeout(function() {
41
			mui('#pullrefresh').pullRefresh().pulldownLoading();
42
		}, 500);
43
	});
44
} else {
45
	mui.ready(function() {
46
		mui('#pullrefresh').pullRefresh().pulldownLoading();
47
	});
48
}
49

36
*/
50 37

51 38

52 39
mui.plusReady(function(){

+ 6 - 16
app/js/attentions2.js

@ -8,9 +8,9 @@ var nodatabox1 = document.getElementById("nodatabox1");
8 8
mui.init({
9 9
	pullRefresh: {
10 10
		container: '#pullrefresh',
11
		down: {
11
		/*down: {
12 12
				callback: pulldownRefresh
13
			  },
13
			  },*/
14 14
		up: {
15 15
			contentrefresh: '正在加载...',
16 16
			callback: pullupRefresh,
@ -25,27 +25,17 @@ function pullupRefresh() {
25 25
	setTimeout(function() {
26 26
		expert2(pageNo, 10)
27 27
	}, 1000);
28
	mui('#pullrefresh').pullRefresh().refresh(true);
28 29
}
29 30

30
function pulldownRefresh() {
31
/*function pulldownRefresh() {
31 32
	setTimeout(function() {
32 33
		getOneExpert(1, 10);	
33
		mui('#pullrefresh').pullRefresh().endPulldownToRefresh();
34
	    mui('#pullrefresh').pullRefresh().endPulldownToRefresh();
34 35
	}, 1000);
35
}
36
}*/
36 37

37 38

38
if(mui.os.plus) {
39
	mui.plusReady(function() {
40
		setTimeout(function() {
41
			mui('#pullrefresh').pullRefresh().pulldownLoading();
42
		}, 500);
43
	});
44
} else {
45
	mui.ready(function() {
46
		mui('#pullrefresh').pullRefresh().pulldownLoading();
47
	});
48
}
49 39

50 40

51 41