Newer
Older
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
import {Component} from '@angular/core';
import {IonicPage, NavController, NavParams} from 'ionic-angular';
import {DutyApplyHandlePage} from "../duty-apply-handle/duty-apply-handle";
import {DutyChangeDetailPage} from "../duty-change-detail/duty-change-detail";
import {AppService} from "../../../../service/http.service";
@IonicPage()
@Component({
selector: 'page-change-apply-list',
templateUrl: 'change-apply-list.html',
})
export class ChangeApplyListPage {
menuList = [
{name: '待处理'},
{name: '已处理'},
];
changeType = 1;
noList = [];
doneList = [];
constructor(public navCtrl: NavController, public navParams: NavParams,
public appService: AppService) {
}
ionViewDidEnter() {
const len = this.navCtrl.length() - 2 - 1;
this.navCtrl.remove(2, len);
this.getList();
}
getList() {
//0 未处理 1 已处理
const data = {
type: 0
};
this.appService.ObserverHttpGetOption('/wisdomgroup/changeApply/app/applyListOfType', data)
.subscribe((res) => {
this.noList = res.json();
}
);
const data1 = {
type: 1
};
this.appService.ObserverHttpGetOption('/wisdomgroup/changeApply/app/applyListOfType', data1)
.subscribe((res) => {
this.doneList = res.json();
}
);
}
change(type) {
this.changeType = type;
}
goApplyDetail(item) {
this.navCtrl.push('DutyApplyHandlePage', {'item': item});
}
goToDetail(item) {
this.navCtrl.push('DutyChangeDetailPage', {'item': item});
}
}