classify.js
949 字节
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
var t = require("../../utils/network.js");
Page({
data: {
terms: []
},
godetail: function(t) {
var n = t.currentTarget.dataset.id;
wx.navigateTo({
url: "detail/detail?term_id=" + n
});
},
onLoad: function(t) {
this.getterms();
},
getterms: function() {
var n = this;
new Object();
t.POST({
url: "Index/terms",
header: "application/x-www-form-urlencoded",
params: "",
success: function(t) {
"success" == t.data.state && n.setData({
terms: t.data.terms
});
},
fail: function() {}
});
},
onReady: function() {},
onShow: function() {},
onHide: function() {},
onUnload: function() {},
onPullDownRefresh: function() {},
onReachBottom: function() {},
onShareAppMessage: function() {}
});