import { Component, OnInit } from '@angular/core';
import {CommonService} from '../common.service';

@Component({
  selector: 'app-income',
  templateUrl: './income.component.html',
  styleUrls: ['./income.component.css']
})
export class IncomeComponent implements OnInit {
  hasMate:boolean;
  curPageData:Array<any>;
  constructor(private commonService: CommonService) { }

  ngOnInit() {
    this.surveyInfo()
    this.hasMate = true;
  }
  surveyInfo() {
    this.commonService.surveyInfo().then(res => {
      if (res['success']) {
        this.curPageData = res['data']['survey'].pages['6']
        console.log(this.curPageData)
      }
    })
  }

}
