-
Notifications
You must be signed in to change notification settings - Fork 2
/
friends_list.html
150 lines (140 loc) · 5.47 KB
/
friends_list.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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<link href="css/mui.min.css" rel="stylesheet" />
<link rel="stylesheet" href="css/friend.css" />
</head>
<body>
<div class="mui-content" id="refreshContainer">
<div class="mui-row friendtop">
<div class="mui-col-sm-4 mui-col-xs-4">
<a href="##">
<img src="img/friends_icon1.png" />
<span class="toptitle">生活号</span>
<span class="topcontent">钉钉更新了</span>
</a>
</div>
<div class="mui-col-sm-4 mui-col-xs-4">
<a href="##">
<img src="img/friends_icon2.png" />
<span class="toptitle">小程序</span>
<span class="topcontent">发现更多精品服务</span>
</a>
</div>
<div class="mui-col-sm-4 mui-col-xs-4">
<a href="##">
<img src="img/friends_icon3.png" />
<span class="toptitle">生活圈</span>
<span class="topcontent">和朋友分享生活</span>
</a>
</div>
</div>
<ul class="mui-table-view friendlist">
<li class="mui-table-view-cell mui-media">
<a href="javascript:;">
<img class="mui-media-object mui-pull-left" src="img/friends_icon4.png">
<div class="mui-media-body">
服务提醒(含支付助手)
<p class="mui-ellipsis">空气污染,送健康果咯!</p>
</div>
</a>
</li>
<li class="mui-table-view-cell mui-media">
<a href="javascript:;">
<img class="mui-media-object mui-pull-left" src="img/friends_icon5.png">
<div class="mui-media-body">
蚂蚁财富
<p class="mui-ellipsis">您有财富开运红包待领取</p>
</div>
</a>
</li>
<li class="mui-table-view-cell mui-media">
<a href="javascript:;">
<img class="mui-media-object mui-pull-left" src="img/friends_icon6.png">
<div class="mui-media-body">
手机充值
<p class="mui-ellipsis">快开学的你是否也有这样的苦恼.</p>
</div>
</a>
</li>
<li class="mui-table-view-cell mui-media">
<a href="javascript:;">
<img class="mui-media-object mui-pull-left" src="img/friends_icon7.png">
<div class="mui-media-body">
浦发银行信用卡
<p class="mui-ellipsis">[消息提醒]您有一波半价美食待领取</p>
</div>
</a>
</li>
<li class="mui-table-view-cell mui-media">
<a href="javascript:;">
<img class="mui-media-object mui-pull-left" src="img/friends_icon8.png">
<div class="mui-media-body">
浦发银行信用卡
<p class="mui-ellipsis">[消息提醒]您有一波半价美食待领取</p>
</div>
</a>
</li>
</ul>
</div>
<script src="js/mui.min.js"></script>
<script type="text/javascript">
mui.init({
pullRefresh : {
container:'#refreshContainer',
down : {
callback :pulldownfresh
},
up : {
callback :pullupfresh
}
}
});
function pulldownfresh(){
setTimeout(function(){
var friendlist = document.body.querySelector(".friendlist");
var liNode = document.createElement("li");
liNode.className = "mui-table-view-cell mui-media";
liNode.innerHTML = "<a href='javascript:;'>"
+ "<img class='mui-media-object mui-pull-left' src='img/friends_icon8.png'>"
+ "<div class='mui-media-body'>"
+ "浦发银行信用卡"
+ "<p class='mui-ellipsis'>[消息提醒]您有一波半价美食待领取</p>"
+ "</div></a>";
friendlist.insertBefore(liNode,friendlist.firstChild);
mui('#refreshContainer').pullRefresh().endPulldownToRefresh();
},1500);
}
function pullupfresh(){
setTimeout(function(){
var friendlist = document.body.querySelector(".friendlist");
var liNode = document.createElement("li");
liNode.className = "mui-table-view-cell mui-media";
liNode.innerHTML = "<a href='javascript:;'>"
+ "<img class='mui-media-object mui-pull-left' src='img/friends_icon8.png'>"
+ "<div class='mui-media-body'>"
+ "浦发银行信用卡"
+ "<p class='mui-ellipsis'>[消息提醒]您有一波半价美食待领取</p>"
+ "</div></a>";
friendlist.appendChild(liNode);
mui('#refreshContainer').pullRefresh().endPullupToRefresh(true);
},1500);
}
mui(".friendlist").on("tap","li",function(){
mui.openWindow({
url: "im-chat.html",
id: "im-chat.html",
styles:{
top: "0px",
bottom: "0px"
}
})
var imgchat = plus.webview.getWebviewById("im-chat.html");
mui.fire(imgchat,'getname',{username: "zhangsan"});
})
</script>
</body>
</html>