You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
69 lines
1.2 KiB
TypeScript
69 lines
1.2 KiB
TypeScript
|
6 years ago
|
import { Component, OnInit, Input } from '@angular/core';
|
||
|
|
import { ModalController, NavParams } from '@ionic/angular';
|
||
|
|
|
||
|
|
@Component({
|
||
|
|
selector: 'app-date-info-modal',
|
||
|
|
templateUrl: './date-info-modal.component.html',
|
||
|
|
styleUrls: ['./date-info-modal.component.scss'],
|
||
|
|
})
|
||
|
|
export class DateInfoModalComponent implements OnInit {
|
||
|
|
gaugeType = "full";
|
||
|
|
gaugeValue = 28.3;
|
||
|
|
gaugeLabel = "Days";
|
||
|
|
@Input() TODAYDATE: any;
|
||
|
6 years ago
|
today: any;
|
||
|
6 years ago
|
todayDate: any;
|
||
|
|
month: any;
|
||
|
|
monthDate: any;
|
||
|
|
|
||
|
|
constructor(public modalController: ModalController, public navParams: NavParams) { }
|
||
|
|
|
||
|
|
ngOnInit() {
|
||
|
6 years ago
|
let dateData = this.TODAYDATE.split(' ');
|
||
|
|
console.log(dateData)
|
||
|
|
this.today = dateData[0];
|
||
|
|
this.todayDate = dateData[1];
|
||
|
|
this.monthDate = dateData[2];
|
||
|
|
this.month = dateData[3];
|
||
|
|
console.log(this.todayDate);
|
||
|
|
console.log(this.today);
|
||
|
|
console.log(this.monthDate);
|
||
|
|
console.log(this.month);
|
||
|
6 years ago
|
}
|
||
|
|
|
||
|
|
|
||
|
6 years ago
|
public options = {
|
||
|
6 years ago
|
cutoutPercentage: 80,
|
||
|
|
|
||
|
|
tooltips: { enabled: false },
|
||
|
|
|
||
|
|
legend: { display: false }
|
||
|
|
|
||
|
|
};
|
||
|
|
|
||
|
|
|
||
|
|
|
||
|
|
public data = {
|
||
|
|
|
||
|
|
datasets: [
|
||
|
|
|
||
|
6 years ago
|
{
|
||
|
|
|
||
|
|
data: [120, 50],
|
||
|
6 years ago
|
|
||
|
6 years ago
|
backgroundColor: [
|
||
|
6 years ago
|
|
||
|
6 years ago
|
'#094875'
|
||
|
|
],
|
||
|
6 years ago
|
|
||
|
6 years ago
|
borderWidth: 2
|
||
|
6 years ago
|
|
||
|
6 years ago
|
}]
|
||
|
6 years ago
|
|
||
|
6 years ago
|
};
|
||
|
6 years ago
|
|
||
|
|
|
||
|
|
|
||
|
|
|
||
|
|
}
|