notification starter
This commit is contained in:
@@ -23,11 +23,11 @@
|
||||
</ion-header>
|
||||
|
||||
<ion-content class="ion-padding">
|
||||
<div class="flex" *ngFor="let item of [1,2,3,4,5,6,7]">
|
||||
<div class="bg_image back_image" [style.backgroundImage]="'url(assets/images/check.png)'"></div>
|
||||
<div class="flex" *ngFor="let item of notificationData">
|
||||
<div class="bg_image back_image" [style.backgroundImage]="'url(assets/images/notifications/'+item.icon+')'"></div>
|
||||
<div class="text">
|
||||
<ion-label class="bold_text">Payment Successful</ion-label>
|
||||
<ion-label class="grey_text">Parking booking Successful</ion-label>
|
||||
<ion-label class="bold_text">{{item.date}}</ion-label>
|
||||
<ion-label class="grey_text">{{item.title}}</ion-label>
|
||||
</div>
|
||||
</div>
|
||||
</ion-content>
|
||||
|
||||
@@ -1,13 +1,8 @@
|
||||
/*
|
||||
Authors : initappz (Rahul Jograna)
|
||||
Website : https://initappz.com/
|
||||
App Name : E-Learning App Template
|
||||
This App Template Source code is licensed as per the
|
||||
terms found in the Website https://initappz.com/license
|
||||
Copyright and Good Faith Purchasers © 2021-present initappz.
|
||||
*/
|
||||
import { NavController } from '@ionic/angular';
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
import {NavController} from "@ionic/angular";
|
||||
import {Router} from "@angular/router";
|
||||
import { WrenchService } from 'src/app/services/wrench.service';
|
||||
import {SessionDataProviderService} from "../../store/session-data-provider.service";
|
||||
|
||||
@Component({
|
||||
selector: 'app-notification',
|
||||
@@ -17,14 +12,44 @@ import { Component, OnInit } from '@angular/core';
|
||||
export class NotificationPage implements OnInit {
|
||||
|
||||
constructor(
|
||||
private navctr: NavController
|
||||
) { }
|
||||
private navctr: NavController,
|
||||
private router: Router,
|
||||
public sessionDataProviderService: SessionDataProviderService,
|
||||
private wrenchService: WrenchService
|
||||
) {
|
||||
|
||||
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.getNotificationData();
|
||||
}
|
||||
|
||||
onBack() {
|
||||
this.navctr.back();
|
||||
}
|
||||
usrData: {
|
||||
action:11205, member_id: number, uid: string, sessionid: string, limit:20, page:1
|
||||
};
|
||||
notificationTotalData:any;
|
||||
notificationData: [];
|
||||
getNotificationData(){
|
||||
this.usrData = {action:11205,
|
||||
member_id: this.sessionDataProviderService.member_id,
|
||||
uid: this.sessionDataProviderService.member_uid,
|
||||
sessionid: this.sessionDataProviderService.session ,
|
||||
limit:20, page:1}
|
||||
|
||||
this.wrenchService.getMyNotifications(this.usrData).subscribe(
|
||||
notificationTotalData => {
|
||||
this.notificationTotalData = notificationTotalData;
|
||||
console.log("NOTIFICATION RETURN->", this.notificationTotalData);
|
||||
this.notificationData = this.notificationTotalData.result_list;
|
||||
// debugger;
|
||||
console.log("JOBS RETURN DATA->", this.notificationData);
|
||||
}
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -24,6 +24,10 @@ export class WrenchService {
|
||||
);
|
||||
}
|
||||
|
||||
getMyNotifications(usrData) {
|
||||
return this.getPostData('mynotifications',usrData);
|
||||
}
|
||||
|
||||
loginUser(loginData) {
|
||||
return this.getPostData('userlogin',loginData);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user