Skip to content
my-follow.component.ts 1006 B
Newer Older
wangqinghua's avatar
wangqinghua committed
import {Component, OnInit, ViewChild} from '@angular/core';
import {OverviewService} from '../overview.service';
import {ModuleConfigComponent} from '../modal/module-config/module-config.component';
wangqinghua's avatar
wangqinghua committed

@Component({
wangqinghua's avatar
wangqinghua committed
    selector: 'smart-my-follow',
    templateUrl: './my-follow.component.html',
    styles: []
wangqinghua's avatar
wangqinghua committed
})
export class MyFollowComponent implements OnInit {
wangqinghua's avatar
wangqinghua committed
    @ViewChild('smartModuleConfig') smartModuleConfig: ModuleConfigComponent;
wangqinghua's avatar
wangqinghua committed

wangqinghua's avatar
wangqinghua committed
    page = {
        list: null,
        isLoading: false,
    };
wangqinghua's avatar
wangqinghua committed

wangqinghua's avatar
wangqinghua committed
    constructor(private overViewSer: OverviewService) {
    }

    ngOnInit() {
        this.getAllModule();
    }

    //查询所有的工作模块
    getAllModule() {
        this.overViewSer.selectWorkModule(null).subscribe(
            (res) => {
                if (res.errCode == 10000) {
                    this.page.list = res.data;
                }
            }
        );
    }

    showModal() {
        this.smartModuleConfig.showModal('关注项配置', this.page.list);
    }
wangqinghua's avatar
wangqinghua committed

}