Skip to content

Instantly share code, notes, and snippets.

View Sampath-Lokuge's full-sized avatar
🏠
Working from home

Sampath Lokuge Sampath-Lokuge

🏠
Working from home
View GitHub Profile
@Sampath-Lokuge
Sampath-Lokuge / Chart
Last active October 31, 2017 02:26
Chart - 30-10-2017
Chart
Multi Budget
{
"name": "renoTracker",
"version": "0.0.1",
"author": "Ionic Framework",
"homepage": "http://ionicframework.com/",
"private": true,
"scripts": {
"clean": "ionic-app-scripts clean",
"build": "ionic-app-scripts build",
"lint": "ionic-app-scripts lint",
this.remainingAmount = this.totalOfBudgetAndContingency - spent;
this.paidPercentage = (this.amountPaid / this.totalOfBudgetAndContingency) * 100;
if (this.paidPercentage > 80) {
this.remainingPercentageExcludingPaid = 0;
this.contingencyPercentage = (totalContingency / this.totalOfBudgetAndContingency) * 100;
this.paidPercentage = 100 - this.contingencyPercentage;
} else {
this.remainingPercentageExcludingPaid = (this.remainingAmount / this.totalOfBudgetAndContingency) * 100;
this.contingencyPercentage = (totalContingency / this.totalOfBudgetAndContingency) * 100;
}
Ionic Native plugin: http://ionicframework.com/docs/native/firebase/
base-page.ts
-------------
import { Firebase } from "@ionic-native/firebase";
export abstract class BasePage {