redpac.js
1.22 KB
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
/**
* Created by qiujun on 2018/10/9.
*/
class RedpacModel extends global.yoho.BaseModel {
constructor(ctx) {
super(ctx);
}
/**
* 领取红包
* @param uid
* @param actSource
* @param redpacToken
*/
getRedpac(uid, udid, actSource, redpacToken) {
return this.get({
url: '',
data: {
method: 'app.redpac.addRedpac',
uid: uid,
udid: udid,
actSource: actSource,
redpacToken: redpacToken
}
});
}
/**
* 获取我的红包列表
* @param uid
*/
getMyRedpac(uid) {
return this.get({
url: '',
data: {
method: 'app.redpac.redpacNum',
uid: uid
}
});
}
/**
* 获取红包token
* @param udid
* @param actSource
*/
getRedpacToken(udid, actSource) {
// console.log(udid, actSource);
return this.get({
url: '',
data: {
method: 'app.redpac.redpacToken',
actSource: actSource,
udid: udid
}
});
}
}
module.exports = RedpacModel;