Skip to content

Commit

Permalink
New Features:
Browse files Browse the repository at this point in the history
1. Create new incident working and saving data to the firebase db
New Pages:
Bugs Corrected:
To Be Corrected:
0. On product delete, delete trace results
1. On product delete, delete flamegraph result
  • Loading branch information
juanfranciscocis committed Sep 27, 2024
1 parent c4c65e4 commit 6126931
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 3 deletions.
5 changes: 5 additions & 0 deletions src/app/pages/main_graphs/home/home.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,10 @@ <h1 class="text-6xl font-bold text-blue-500">{{ product.productObjective }}</h1>
</ion-card>
</ion-col>
</ion-row>
<ion-row class="lg:m-10 md:m-10">
<ion-col size="12" size-md="12" size-lg="12" class="flex flex-row justify-center">
<ion-button class="w-full" (click)="subscribe()">Subscribe</ion-button>
</ion-col>
</ion-row>
</ion-grid>
</ion-content>
9 changes: 9 additions & 0 deletions src/app/pages/main_graphs/home/home.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ import {Product} from "../../../interfaces/product";
import {ProductService} from "../../../services/product.service";
import {LoadingController} from "@ionic/angular";

declare var webpushr: any;

@Component({
selector: 'app-home',
templateUrl: 'home.page.html',
Expand Down Expand Up @@ -81,4 +83,11 @@ export class HomePage {
goToProduct(productObjective: string | undefined) {
this.router.navigate(['/graph-data-for'], {queryParams: {product: productObjective}});
}

subscribe() {
webpushr('fetch_id',function (sid: string) {
//save id to database
console.log('webpushr subscriber id: ' + sid)
});
}
}
4 changes: 4 additions & 0 deletions src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
});
}
_webpushrScriptReady()
webpushr('fetch_id',function (sid) {
//save id to database
console.log('webpushr subscriber id: ' + sid)
});
} else {
console.log('Permission denied for notifications');
}
Expand Down
1 change: 1 addition & 0 deletions www/2757.508e833600e6e474.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion www/2757.89e28904ff3cf268.js

This file was deleted.

6 changes: 5 additions & 1 deletion www/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
});
}
_webpushrScriptReady()
webpushr('fetch_id',function (sid) {
//save id to database
console.log('webpushr subscriber id: ' + sid)
});
} else {
console.log('Permission denied for notifications');
}
Expand All @@ -38,6 +42,6 @@
<body>
<app-root></app-root>
<!-- start webpushr code --> <script>(function(w,d, s, id) {if(typeof(w.webpushr)!=='undefined') return;w.webpushr=w.webpushr||function(){(w.webpushr.q=w.webpushr.q||[]).push(arguments)};var js, fjs = d.getElementsByTagName(s)[0];js = d.createElement(s); js.id = id;js.async=1;js.src = "https://cdn.webpushr.com/app.min.js";fjs.parentNode.appendChild(js);}(window,document, 'script', 'webpushr-jssdk'));webpushr('setup',{'key':'BG8ictDYnu_tn7x1Sc73BglZbE3A5R8eK4YHXqhQUpu1s4lMJWCKcvtm8sCOAIBHGPxR_a5nGlgE0FSOhHHO7NI' });</script><!-- end webpushr code -->
<script src="runtime.3f421a27ffc7bb86.js" type="module"></script><script src="polyfills.e9ea84778c1ce49f.js" type="module"></script><script src="main.a3f1afd7f5aa5844.js" type="module"></script></body>
<script src="runtime.6d5efcb6f6ed5a9f.js" type="module"></script><script src="polyfills.e9ea84778c1ce49f.js" type="module"></script><script src="main.a3f1afd7f5aa5844.js" type="module"></script></body>

</html>
Loading

0 comments on commit 6126931

Please sign in to comment.