Commit 6d5232d0 by kevin

25/06/2019extrapagesadded

parent f011757e
...@@ -29,7 +29,18 @@ const routes: Routes = [ ...@@ -29,7 +29,18 @@ const routes: Routes = [
}, },
{ path: 'medicalauthorization/:id', { path: 'medicalauthorization/:id',
loadChildren: './medicalauthorization/medicalauthorization.module#MedicalauthorizationPageModule' loadChildren: './medicalauthorization/medicalauthorization.module#MedicalauthorizationPageModule'
} },
{ path: 'studentsprofile/:id', loadChildren: './studentsprofile/studentsprofile.module#StudentsprofilePageModule' },
{ path: 'healthcareforum/:id', loadChildren: './healthcareforum/healthcareforum.module#HealthcareforumPageModule' },
{ path: 'treatmentauthorization/:id', loadChildren: './treatmentauthorization/treatmentauthorization.module#TreatmentauthorizationPageModule' },
{ path: 'medicationtracking/:id', loadChildren: './medicationtracking/medicationtracking.module#MedicationtrackingPageModule' },
{ path: 'treatmenttrackings/:id', loadChildren: './treatmenttrackings/treatmenttrackings.module#TreatmenttrackingsPageModule' },
{ path: 'screenings/:id', loadChildren: './screenings/screenings.module#ScreeningsPageModule' },
{ path: 'chartvisits/:id', loadChildren: './chartvisits/chartvisits.module#ChartvisitsPageModule' },
{ path: 'immunizations/:id', loadChildren: './immunizations/immunizations.module#ImmunizationsPageModule' },
{ path: 'medicalhistory/:id', loadChildren: './medicalhistory/medicalhistory.module#MedicalhistoryPageModule' },
{ path: 'healthhistory/:id', loadChildren: './healthhistory/healthhistory.module#HealthhistoryPageModule' }
]; ];
......
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { ChartvisitsPage } from './chartvisits.page';
const routes: Routes = [
{
path: '',
component: ChartvisitsPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [ChartvisitsPage]
})
export class ChartvisitsPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Chart Visits</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul *ngIf="chart_details">
<li *ngFor="let chart_data of chart_details; let i= index">
<div class="list_main" (click)="toggleGroup(i)" [ngClass]="{active:isGroupShown(i)}">
<div class="col floatLeft">
<p>Office Vist Type</p>
<h3><strong>{{chart_data.office_vist_type}}</strong></h3>
</div>
<!-- <div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div> -->
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(i)">
<div class="list_bar">
<div class="col floatLeft">
<p>Issue Visit Reason</p>
<h3>{{chart_data.issue_visit_reason}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Provider Name</p>
<h3>{{chart_data.provider_name}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Time In</p>
<h3>{{chart_data.date_in}} {{chart_data.time_in}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Time Out</p>
<h3>{{chart_data.date_out}} {{chart_data.time_out}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Contact with Parent</p>
<h3>{{chart_data.contact_with_parent}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Visit Outcome</p>
<h3>{{chart_data.visit_outcome}}</h3>
</div>
<div class="clear"></div>
</div>
<!-- <div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="clear"></div>
</div> -->
</div>
<!-- </li>
<li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li> -->
</ul>
</div>
</ion-content>
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { ChartvisitsPage } from './chartvisits.page';
describe('ChartvisitsPage', () => {
let component: ChartvisitsPage;
let fixture: ComponentFixture<ChartvisitsPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ ChartvisitsPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(ChartvisitsPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
import {MyserviceService} from '../myservice.service'
@Component({
selector: 'app-chartvisits',
templateUrl: './chartvisits.page.html',
styleUrls: ['./chartvisits.page.scss'],
})
export class ChartvisitsPage implements OnInit {
shownGroup = null;
chart_details : any
constructor(private myservice : MyserviceService) {
this.shownGroup = 0;
this.chart_details= {
"message":"success",
"data" : [
{
"office_vist_type":"Random Checkup",
"issue_visit_reason":"Migrine",
"provider_name":"Admin Nuvento",
"time_in":"15:49:00",
"date_in":"12/6/2019",
"time_out":"16:30:00",
"date_out":"12/6/2019",
"contact_with_parent":"no",
"visit_outcome":"Relief",
},
{
"office_vist_type":"General Checkup",
"issue_visit_reason":"Fever",
"provider_name":"Admin Nuvento",
"time_in":"15:49:00",
"date_in":"12/7/2019 ",
"time_out":"11:00:00",
"date_out":"06/13/2019 ",
"contact_with_parent":"yes",
"visit_outcome":"test",
}
]
};
this.get_chartDetails();
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_chartDetails() {
this.chart_details = this.myservice.ObjArray(this.chart_details.data);
}
}
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
<div *ngIf ="student_details"> <div *ngIf ="student_details">
<div class="detail_circle_img"> <div class="detail_circle_img">
<img src="../../assets/imgs/asset_img1.png"> <img [src]="student_details.img_src">
</div> </div>
<h4>{{student_details.first_name}} {{student_details.last_name}}</h4> <h4>{{student_details.first_name}} {{student_details.last_name}}</h4>
<div class="detail_grid"> <div class="detail_grid">
...@@ -51,11 +51,11 @@ ...@@ -51,11 +51,11 @@
</div> </div>
<div class="detail_listing"> <div class="detail_listing">
<ul> <ul>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('studentsprofile')">
<img src="../../assets/imgs/m1.png" > <img src="../../assets/imgs/m1.png" >
<p>Students<br> Profile</p> <p>Students<br> Profile</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('healthcareforum')">
<img src="../../assets/imgs/m2.png"> <img src="../../assets/imgs/m2.png">
<p>Health care<br> form</p> <p>Health care<br> form</p>
</li> </li>
...@@ -63,35 +63,35 @@ ...@@ -63,35 +63,35 @@
<img src="../../assets/imgs/m3.png"> <img src="../../assets/imgs/m3.png">
<p>Medication <br>Authorization</p> <p>Medication <br>Authorization</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('treatmentauthorization')">
<img src="../../assets/imgs/m4.png"> <img src="../../assets/imgs/m4.png">
<p>Treatment<br> Authorization</p> <p>Treatment<br> Authorization</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('medicationtracking')">
<img src="../../assets/imgs/m5.png"> <img src="../../assets/imgs/m5.png">
<p>Medication<br>Trackings</p> <p>Medication<br>Trackings</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('treatmenttrackings')">
<img src="../../assets/imgs/m6.png"> <img src="../../assets/imgs/m6.png">
<p>Treatment<br>Trackings</p> <p>Treatment<br>Trackings</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('screenings')">
<img src="../../assets/imgs/m7.png"> <img src="../../assets/imgs/m7.png">
<p>Screenings</p> <p>Screenings</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('chartvisits')">
<img src="../../assets/imgs/m1.png"> <img src="../../assets/imgs/m1.png">
<p>Chart Visits</p> <p>Chart Visits</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('immunizations')">
<img src="../../assets/imgs/m8.png"> <img src="../../assets/imgs/m8.png">
<p>Immunizations</p> <p>Immunizations</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('medicalhistory')">
<img src="../../assets/imgs/m9.png"> <img src="../../assets/imgs/m9.png">
<p>Medical History</p> <p>Medical History</p>
</li> </li>
<li (click)="goToPage('medicalauthorization')"> <li (click)="goToPage('healthhistory')">
<img src="../../assets/imgs/m10.png"> <img src="../../assets/imgs/m10.png">
<p>Health History</p> <p>Health History</p>
</li> </li>
......
...@@ -44,6 +44,7 @@ export class DetailsPage implements OnInit { ...@@ -44,6 +44,7 @@ export class DetailsPage implements OnInit {
this.myservice.load_get('student_details/id/'+this.id).subscribe(resp => this.myservice.load_get('student_details/id/'+this.id).subscribe(resp =>
{ {
console.log(resp); console.log(resp);
This.myservice.dismissLoader(); This.myservice.dismissLoader();
this.student_details=resp; this.student_details=resp;
...@@ -51,7 +52,7 @@ export class DetailsPage implements OnInit { ...@@ -51,7 +52,7 @@ export class DetailsPage implements OnInit {
} }
goToPage(path,data=null){ goToPage(path,data=null){
this.router.navigateByUrl('/medicalauthorization/'+this.id); this.router.navigateByUrl('/'+path+'/'+this.id);
document.body.scrollTop = document.documentElement.scrollTop = 0; document.body.scrollTop = document.documentElement.scrollTop = 0;
} }
...@@ -59,4 +60,22 @@ export class DetailsPage implements OnInit { ...@@ -59,4 +60,22 @@ export class DetailsPage implements OnInit {
popToggle(){ popToggle(){
this.isToggle = !this.isToggle; this.isToggle = !this.isToggle;
} }
getimage() {
console.log('Student number',this.student_details.student_no)
if(this.student_details.student_no = 1)
{
console.log('check')
var img1 ="../../assets/imgs/asset_img1.png";
return img1;
}
if(this.student_details.student_id = 2) {
var img2 = "../../assets/imgs/asset_img2.png";
return img2;
}
if(this.student_details.student_id = 3) {
var img3 = "../../assets/imgs/asset_img3.png";
return img3;
}
}
} }
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { HealthcareforumPage } from './healthcareforum.page';
const routes: Routes = [
{
path: '',
component: HealthcareforumPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [HealthcareforumPage]
})
export class HealthcareforumPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Health Form</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul>
<li *ngIf="health_formData">
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>{{health_formData.name}}</strong></h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(0)">
<div class="list_bar">
<div class="col floatLeft">
<p>Uploaded By</p>
<h3>{{health_formData.uploaded_by}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Uploaded</p>
<h3>{{health_formData.uploaded}} {{health_formData.uploaded_time}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Uploaded By</p>
<h3>{{health_formData.school_year}}</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li>
<!-- <li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li> -->
</ul>
</div>
</ion-content>
\ No newline at end of file
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { HealthcareforumPage } from './healthcareforum.page';
describe('HealthcareforumPage', () => {
let component: HealthcareforumPage;
let fixture: ComponentFixture<HealthcareforumPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ HealthcareforumPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(HealthcareforumPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
@Component({
selector: 'app-healthcareforum',
templateUrl: './healthcareforum.page.html',
styleUrls: ['./healthcareforum.page.scss'],
})
export class HealthcareforumPage implements OnInit {
shownGroup = null;
health_formData:any
constructor() {
this.shownGroup = 0;
this.health_formData = {
"message":"success",
"name":"healthform201951012103181",
"school_year":"2016-2017",
"uploaded_by":"Admin Nuvento",
"uploaded":"10/6/19",
"uploaded_time":"12:10:00"
}
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_healthformData() {
}
}
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { HealthhistoryPage } from './healthhistory.page';
const routes: Routes = [
{
path: '',
component: HealthhistoryPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [HealthhistoryPage]
})
export class HealthhistoryPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Medical Authorizations</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul>
<li>
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(0)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li>
<li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li>
</ul>
</div>
</ion-content>
\ No newline at end of file
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { HealthhistoryPage } from './healthhistory.page';
describe('HealthhistoryPage', () => {
let component: HealthhistoryPage;
let fixture: ComponentFixture<HealthhistoryPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ HealthhistoryPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(HealthhistoryPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-healthhistory',
templateUrl: './healthhistory.page.html',
styleUrls: ['./healthhistory.page.scss'],
})
export class HealthhistoryPage implements OnInit {
shownGroup = null;
constructor() {
this.shownGroup = 0;
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
}
...@@ -12,6 +12,7 @@ ...@@ -12,6 +12,7 @@
<ul *ngIf="student_data"> <ul *ngIf="student_data">
<li (click)="goToPage('details','1')"> <li (click)="goToPage('details','1')">
<div class="image_div"> <div class="image_div">
<img src="../../assets/imgs/asset_img1.png"> <img src="../../assets/imgs/asset_img1.png">
</div> </div>
<div class="other_details"> <div class="other_details">
......
...@@ -40,4 +40,5 @@ get_students_data(){ ...@@ -40,4 +40,5 @@ get_students_data(){
this.router.navigateByUrl('/login',{replaceUrl: true}); this.router.navigateByUrl('/login',{replaceUrl: true});
document.body.scrollTop = document.documentElement.scrollTop = 0; document.body.scrollTop = document.documentElement.scrollTop = 0;
} }
} }
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { ImmunizationsPage } from './immunizations.page';
const routes: Routes = [
{
path: '',
component: ImmunizationsPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [ImmunizationsPage]
})
export class ImmunizationsPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Add Immunization</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul *ngIf="immunization_data">
<li *ngFor="let immunization of immunization_data; let i=index ">
<div class="list_main" (click)="toggleGroup(i)" [ngClass]="{active:isGroupShown(i)}">
<div class="col floatLeft">
<p>Type</p>
<h3><strong>{{immunization.type}}</strong></h3>
</div>
<!-- <div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div> -->
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(i)">
<div class="list_bar">
<div class="col floatLeft">
<p>Last Administered Date</p>
<h3>{{immunization.last_adminstered_date}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Status</p>
<h3>{{immunization.status}}</h3>
</div>
<div class="clear"></div>
</div>
<!-- <div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div> -->
</div>
</li>
<!-- <li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li> -->
</ul>
</div>
</ion-content>
\ No newline at end of file
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { ImmunizationsPage } from './immunizations.page';
describe('ImmunizationsPage', () => {
let component: ImmunizationsPage;
let fixture: ComponentFixture<ImmunizationsPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ ImmunizationsPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(ImmunizationsPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
import {MyserviceService} from '../myservice.service'
@Component({
selector: 'app-immunizations',
templateUrl: './immunizations.page.html',
styleUrls: ['./immunizations.page.scss'],
})
export class ImmunizationsPage implements OnInit {
shownGroup= null;
immunization_data:any;
constructor(private myservice:MyserviceService) {
this.shownGroup = 0;
this.immunization_data = {
"message":"success",
"data" : [
{
"type":"HIB",
"last_adminstered_date":"05/14/2019",
"status":"Deficient",
},
{
"type":"MMR",
"last_adminstered_date":"05/14/2019",
"status":"Deficient",
}
]
};
this.get_immunization();
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_immunization() {
this.immunization_data = this.myservice.ObjArray(this.immunization_data.data);
}
}
...@@ -10,39 +10,39 @@ ...@@ -10,39 +10,39 @@
</ion-header> </ion-header>
<ion-content *ngIf="medicalresp"> <ion-content *ngIf="medicalresp">
<div class="list_wrapper"> <div class="list_wrapper">
<ul> <ul >
<li> <li *ngFor="let medical_data of medicalresp; let i = index" >
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}"> <div class="list_main" (click)="toggleGroup(i)" [ngClass]="{active:isGroupShown(i)}">
<div class="col floatLeft"> <div class="col floatLeft">
<p>Name</p> <p>Name</p>
<h3><strong>Medication Authorizations</strong></h3> <h3><strong>Medication Authorizations</strong></h3>
</div> </div>
<div class="col floatLeft borderNone"> <div class="col floatLeft borderNone">
<p>Expiry Date</p> <p>Expiry Date</p>
<h3>{{medicalresp.expiry_date}}</h3> <h3>{{medical_data.expiry_date}}</h3>
</div> </div>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<div class="list_sub" *ngIf="isGroupShown(0)"> <div class="list_sub" *ngIf="isGroupShown(i)">
<div class="list_bar"> <div class="list_bar">
<div class="col floatLeft"> <div class="col floatLeft">
<p>Name of medicine</p> <p>Name of medicine</p>
<h3>{{medicalresp.name_medicine}}</h3> <h3>{{medical_data.name_medicine}}</h3>
</div> </div>
<div class="col floatLeft borderNone"> <div class="col floatLeft borderNone">
<p>Times Per Day</p> <p>Times Per Day</p>
<h3>{{medicalresp.time_perday}}</h3> <h3>{{medical_data.time_perday}}</h3>
</div> </div>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
<div class="list_bar"> <div class="list_bar">
<div class="col floatLeft"> <div class="col floatLeft">
<p>Tme of first medication</p> <p>Tme of first medication</p>
<h3>{{medicalresp.date_first_medicine}}{{medicalresp.time_first_medicine}}</h3> <h3>{{medical_data.date_first_medicine}}{{medical_data.time_first_medicine}}</h3>
</div> </div>
<div class="col floatLeft borderNone"> <div class="col floatLeft borderNone">
<p>Quantity Available</p> <p>Quantity Available</p>
<h3>{{medicalresp.quantity_available}}</h3> <h3>{{medical_data.quantity_available}}</h3>
</div> </div>
<div class="clear"></div> <div class="clear"></div>
</div> </div>
......
...@@ -37,9 +37,9 @@ export class MedicalauthorizationPage implements OnInit { ...@@ -37,9 +37,9 @@ export class MedicalauthorizationPage implements OnInit {
this.myservice.presentLoader(); this.myservice.presentLoader();
this.myservice.load_get('get_medicalauthorization/id/'+this.id).subscribe(resp =>{ this.myservice.load_get('get_medicalauthorization/id/'+this.id).subscribe(resp =>{
this.myservice.dismissLoader(); this.myservice.dismissLoader();
console.log('Response',resp); this.medicalresp = this.myservice.ObjArray(resp.data);
this.medicalresp= resp; console.log('Medical', this.medicalresp)
}) });
} }
......
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { MedicalhistoryPage } from './medicalhistory.page';
const routes: Routes = [
{
path: '',
component: MedicalhistoryPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [MedicalhistoryPage]
})
export class MedicalhistoryPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Medical Authorizations</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul>
<li>
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(0)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li>
<li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li>
</ul>
</div>
</ion-content>
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { MedicalhistoryPage } from './medicalhistory.page';
describe('MedicalhistoryPage', () => {
let component: MedicalhistoryPage;
let fixture: ComponentFixture<MedicalhistoryPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ MedicalhistoryPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(MedicalhistoryPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-medicalhistory',
templateUrl: './medicalhistory.page.html',
styleUrls: ['./medicalhistory.page.scss'],
})
export class MedicalhistoryPage implements OnInit {
shownGroup= null;
constructor() {
this.shownGroup = 0;
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
}
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { MedicationtrackingPage } from './medicationtracking.page';
const routes: Routes = [
{
path: '',
component: MedicationtrackingPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [MedicationtrackingPage]
})
export class MedicationtrackingPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Medication Tracking</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul>
<li>
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}">
<div class="col-10 floatLeft">
<h3><strong>Medication schedule -Open</strong></h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(0)">
<div class="list_sub_inner" *ngFor = "let medical of medicalschedule_open ">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of Medicine</p>
<h3>{{medical.name_medicine}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Dosage Units</p>
<h3>{{medical.dosage_unit}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Times Per Day</p>
<h3>{{medical.time_per_day}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>Test</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<h3></h3>
</div>
<div class="clear"></div>
</div>
</div>
<hr>
<!-- <div class="list_sub_inner">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of Medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>TDosage Units</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Times Per Day</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="clear"></div>
</div>
</div> -->
</div>
</li>
<li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col-10 floatLeft">
<h3><strong>Medication Distribution Transaction-Log</strong></h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_sub_inner" *ngFor = "let medical_log of medicalschedule_log ">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>{{medical_log.name_medicine}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Dosage Units</p>
<h3>{{medical_log.dossage_units}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Units Provided</p>
<h3>{{medical_log.units_provided}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Date Medication Received</p>
<h3>{{medical_log.date_medication_received}} {{medical_log.time_medication}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Notes</p>
<h3>{{medical_log.notes}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Given By</p>
<h3>{{medical_log.given_by}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Missed Medication</p>
<h3>{{medical_log.missed_medication}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Action</p>
<h3></h3>
</div>
<div class="clear"></div>
</div>
</div>
<hr>
</div>
</li>
</ul>
</div>
</ion-content>
\ No newline at end of file
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 45%;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 45%;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_sub_inner{
border-bottom: 1px solid #fff;
}
hr{
border-top:none;
height:0px;
}
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { MedicationtrackingPage } from './medicationtracking.page';
describe('MedicationtrackingPage', () => {
let component: MedicationtrackingPage;
let fixture: ComponentFixture<MedicationtrackingPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ MedicationtrackingPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(MedicationtrackingPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
@Component({
selector: 'app-medicationtracking',
templateUrl: './medicationtracking.page.html',
styleUrls: ['./medicationtracking.page.scss'],
})
export class MedicationtrackingPage implements OnInit {
medicalschedule_open:any
shownGroup = null;
medicalschedule_log:any;
constructor() {
this.shownGroup = 0;
this.get_medicalSchedule();
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_medicalSchedule() {
var mediocalschedule = {
"data" :[
{
"name_medicine":"Hydrochlorothiazide",
"dosage_unit":"5",
"time_per_day":"3",
},
{
"name_medicine":"Hydrochlorothiazide",
"dosage_unit":"5",
"time_per_day":"3",
},
{
"name_medicine":"Hydrochlorothiazide",
"dosage_unit":"5",
"time_per_day":"3",
},
{
"name_medicine":"Potassium Chloride",
"dosage_unit":"5",
"time_per_day":"2",
},
]
};
this.medicalschedule_open = mediocalschedule.data;
console.log(this.medicalschedule_open);
var medication_transaction_log = {
data :[
{
"name_medicine":"Potassium Chloride",
"dossage_units":"5",
"units_provided":"22",
"date_medication_received":"06/14/2019",
"time_medication":"03:01 PM",
"notes":"test",
"given_by":"Admin Nuvento",
"missed_medication":"no"
},
{
"name_medicine":"Amoxicillin",
"dossage_units":"1",
"units_provided":"3",
"date_medication_received":"12/6/2019 ",
"time_medication":"13:04:00",
"notes":"test",
"given_by":"Admin Nuvento",
"missed_medication":"no"
},
{
"name_medicine":"Amlodipine",
"dossage_units":"10",
"units_provided":"15",
"date_medication_received":"12/6/2019 ",
"time_medication":"12:02:00",
"notes":"test",
"given_by":"Admin Nuvento",
"missed_medication":"no"
}
]
};
this.medicalschedule_log = medication_transaction_log.data;
}
}
...@@ -60,4 +60,15 @@ export class MyserviceService { ...@@ -60,4 +60,15 @@ export class MyserviceService {
}); });
toast.present(); toast.present();
} }
ObjArray(data: any) {
if (data instanceof Array !== true) {
if (data !== undefined) {
return new Array(data);
} else {
return undefined;
}
} else {
return data;
}
}
} }
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { ScreeningsPage } from './screenings.page';
const routes: Routes = [
{
path: '',
component: ScreeningsPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [ScreeningsPage]
})
export class ScreeningsPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Screenings</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul>
<li>
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}">
<div class="col-10 floatLeft">
<h3><strong>Scoliosis Screenings</strong></h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(0)">
<div class="list_sub_inner" *ngFor = "let medical of scoliosis_screenings_data ">
<div class="list_bar">
<div class="col floatLeft">
<p>Student Number</p>
<h3>{{medical.student_number}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Date Screening Provided</p>
<h3>{{medical.date}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Screening Outcome</p>
<h3>{{medical.outcome}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Note</p>
<h3>Test</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<h3></h3>
</div>
<div class="clear"></div>
</div>
</div>
<hr>
<!-- <div class="list_sub_inner">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of Medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>TDosage Units</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Times Per Day</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="clear"></div>
</div>
</div> -->
</div>
</li>
<li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col-10 floatLeft">
<h3><strong>Vision Screenings</strong></h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_sub_inner" *ngFor = "let medical_log of vision_screenings_data ">
<div class="list_bar">
<div class="col floatLeft">
<p>Student Number</p>
<h3>{{medical_log.student_number}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Vision Aid</p>
<h3>{{medical_log.vison}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Left Eye Result</p>
<h3>{{medical_log.left_eye_result}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Right Eye Result</p>
<h3>{{medical_log.right_eye_result}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Screenig Outcome</p>
<h3>{{medical_log.outcome}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Note</p>
<h3>Test</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<!-- <h3></h3> -->
</div>
<!-- <div class="col floatLeft borderNone">
<p>Action</p>
<h3></h3>
</div> -->
<div class="clear"></div>
</div>
</div>
<hr>
</div>
</li>
</ul>
</div>
</ion-content>
\ No newline at end of file
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 45%;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 45%;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_sub_inner{
border-bottom: 1px solid #fff;
}
hr{
border-top:none;
height:0px;
}
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { ScreeningsPage } from './screenings.page';
describe('ScreeningsPage', () => {
let component: ScreeningsPage;
let fixture: ComponentFixture<ScreeningsPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ ScreeningsPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(ScreeningsPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
@Component({
selector: 'app-screenings',
templateUrl: './screenings.page.html',
styleUrls: ['./screenings.page.scss'],
})
export class ScreeningsPage implements OnInit {
shownGroup = null;
scoliosis_screenings_data:any
vision_screenings_data:any
constructor() {
this.shownGroup = 0;
this.get_screeningsData();
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_screeningsData()
{
var scoliosis_screenings= {
data :[
{
"student_number":"33393",
"date":"12/06/2019",
"outcome":"Doctor Intervention Required"
},
{
"student_number":"33393",
"date":"05/21/2019",
"outcome":"Doctor Intervention Required"
}
]};
this.scoliosis_screenings_data= scoliosis_screenings.data;
var vision_screenings =
{
"data":[
{
"student_number":"33393",
"vison":"Yes",
"left_eye_result":"pass",
"right_eye_result":"No",
"outcome":"Spectacled Needed"
},
{
"student_number":"33393",
"vison":"No",
"left_eye_result":"pass",
"right_eye_result":"pass",
"outcome":"No Concerns"
},
]
};
this.vision_screenings_data = vision_screenings.data;
}
}
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { StudentsprofilePage } from './studentsprofile.page';
const routes: Routes = [
{
path: '',
component: StudentsprofilePage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [StudentsprofilePage]
})
export class StudentsprofilePageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Student Profile</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul>
<li *ngIf="student_data">
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Student Health</strong></h3>
</div>
<!-- <div class="col floatLeft borderNone">
<p>Condition</p>
<h3>Notes</h3>
</div> -->
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(0)">
<div class="list_bar">
<div class="col floatLeft">
<p>Condition</p>
<h3>{{student_data.condition}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Physician</p>
<h3>{{student_data.Physician}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Broken Bones</p>
<h3>{{student_data.broken_bones}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Mental Problems</p>
<h3>{{student_data.mental_problems}}</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li>
<li>
<!-- <div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div> -->
<!-- <div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div> -->
</li>
</ul>
</div>
</ion-content>
\ No newline at end of file
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { StudentsprofilePage } from './studentsprofile.page';
describe('StudentsprofilePage', () => {
let component: StudentsprofilePage;
let fixture: ComponentFixture<StudentsprofilePage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ StudentsprofilePage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(StudentsprofilePage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
@Component({
selector: 'app-studentsprofile',
templateUrl: './studentsprofile.page.html',
styleUrls: ['./studentsprofile.page.scss'],
})
export class StudentsprofilePage implements OnInit {
shownGroup = null;
student_data :any
constructor() {
this.shownGroup = 0;
this.get_studentsData();
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_studentsData() {
this.student_data= {
"condition":"notes",
"Physician":"Stewart Smith",
"broken_bones" :"no",
"mental_problems" :"no"
}
}
}
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { TreatmentauthorizationPage } from './treatmentauthorization.page';
const routes: Routes = [
{
path: '',
component: TreatmentauthorizationPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [TreatmentauthorizationPage]
})
export class TreatmentauthorizationPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Treatment Authorizations</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul *ngIf = "treatment_authorization">
<li *ngFor= "let treatment_details of treatment_authorization ; let i=index">
<div class="list_main" (click)="toggleGroup(i)" [ngClass]="{active:isGroupShown(i)}">
<div class="col-10 floatLeft">
<p>Name</p>
<h3><strong>{{treatment_details.name}}</strong></h3>
</div>
<!-- <div class="col floatLeft borderNone">
<p></p>
<h3>06/12/2019</h3>
</div> -->
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(i)">
<div class="list_bar">
<div class="col floatLeft">
<p>Treatment Description</p>
<h3>Test</h3>
</div>
<div class="col floatLeft borderNone">
<p>Treatment Type</p>
<h3>{{treatment_details.treatment_type}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Times Per Day</p>
<h3>{{treatment_details.times_per_day}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Time of First Treatment</p>
<h3>{{treatment_details.dte_of_first_treat}} {{treatment_details.time_of_first_treat}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Expiry Date</p>
<h3>{{treatment_details.expiry_date}}</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li>
<!-- <li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col floatLeft">
<p>Name</p>
<h3><strong>Medication Authorizations</strong></h3>
</div>
<div class="col floatLeft borderNone">
<p>Expiry Date</p>
<h3>06/12/2019</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Tme of first medication</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Quantity Available</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
</div>
</li> -->
</ul>
</div>
</ion-content>
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 17px;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { TreatmentauthorizationPage } from './treatmentauthorization.page';
describe('TreatmentauthorizationPage', () => {
let component: TreatmentauthorizationPage;
let fixture: ComponentFixture<TreatmentauthorizationPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ TreatmentauthorizationPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(TreatmentauthorizationPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
import {MyserviceService} from '../myservice.service'
@Component({
selector: 'app-treatmentauthorization',
templateUrl: './treatmentauthorization.page.html',
styleUrls: ['./treatmentauthorization.page.scss'],
})
export class TreatmentauthorizationPage implements OnInit {
shownGroup = null;
treatment_authorization:any;
constructor(public myservice : MyserviceService) {
this.shownGroup = 0;
this.treatment_authorization = {
"message":"success",
"data" :[
{
"name":"TreatmentAuthorizations2019511114723687",
"treatment_type":"Tube feeding",
"treatment_description":"test",
"expiry_date":"06/21/2019",
"times_per_day":"2",
"time_of_first_treat":"11:47:00",
"dte_of_first_treat":"11/6/2019"
},
{
"name":"TreatmentAuthorizations201951014481192",
"treatment_type":"Radiation therapy",
"treatment_description":"test",
"expiry_date":"06/21/2019",
"times_per_day":"2",
"time_of_first_treat":"14:48",
"dte_of_first_treat":"10/6/2019"
},
{
"name":"TreatmentAuthorizations2019510121528700",
"treatment_type":"Vaccine therapy",
"treatment_description":"test",
"expiry_date":"06/21/2019",
"times_per_day":"2",
"time_of_first_treat":"14:48:00",
"dte_of_first_treat":"10/6/2019"
},
{
"name":"TreatmentAuthorizations20195714285491",
"treatment_type":"Inhalation",
"treatment_description":"test",
"expiry_date":"06/21/2019",
"times_per_day":"2",
"time_of_first_treat":"14:29:00",
"dte_of_first_treat":"7/6/2019"
},
{
"name":"TreatmentAuthorizations20195713131612",
"treatment_type":"Chemotherapy",
"treatment_description":"test",
"expiry_date":"06/20/2019",
"times_per_day":"3",
"time_of_first_treat":"13:01:00",
"dte_of_first_treat":"7/6/2019 "
}
]
}
this.get_treatmentAuthorizationDetails();
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_treatmentAuthorizationDetails() {
this.treatment_authorization = this.myservice.ObjArray(this.treatment_authorization.data);
console.log(this.treatment_authorization);
}
}
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';
import { IonicModule } from '@ionic/angular';
import { TreatmenttrackingsPage } from './treatmenttrackings.page';
const routes: Routes = [
{
path: '',
component: TreatmenttrackingsPage
}
];
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
RouterModule.forChild(routes)
],
declarations: [TreatmenttrackingsPage]
})
export class TreatmenttrackingsPageModule {}
<ion-header>
<button class="nav_btn nav_back floatLeft">
<ion-back-button>
</ion-back-button>
</button>
<div class="nav_title floatLeft">
<h4>Treatment Tracking</h4>
</div>
<div class="clear"></div>
</ion-header>
<ion-content>
<div class="list_wrapper">
<ul>
<li>
<div class="list_main" (click)="toggleGroup(0)" [ngClass]="{active:isGroupShown(0)}">
<div class="col-10 floatLeft">
<h3><strong>Treatment Schedule -Open</strong></h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(0)">
<div class="list_sub_inner" *ngIf="treatment_schedule_open">
<div class="list_bar">
<div class="col floatLeft">
<p>Treatment Type</p>
<h3>{{treatment_schedule_open.treatment_type}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>{{treatment_schedule_open.times_perday}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<!-- <h3>{{medical.time_per_day}}</h3> -->
</div>
<!-- <div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>Test</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<h3></h3>
</div>
<div class="clear"></div>
</div> -->
</div>
<hr>
<!-- <div class="list_sub_inner">
<div class="list_bar">
<div class="col floatLeft">
<p>Name of Medicine</p>
<h3>Potassium Chloride</h3>
</div>
<div class="col floatLeft borderNone">
<p>TDosage Units</p>
<h3>2 Days</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Times Per Day</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="col floatLeft borderNone">
<p>Times Per Day</p>
<h3>20</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Action</p>
<h3>06/11/2019 11:00 AM</h3>
</div>
<div class="clear"></div>
</div> -->
</div>
</div>
</li>
<li>
<div class="list_main" (click)="toggleGroup(1)" [ngClass]="{active:isGroupShown(1)}">
<div class="col-10 floatLeft">
<h3><strong>Medication Distribution Transaction-Log</strong></h3>
</div>
<div class="clear"></div>
</div>
<div class="list_sub" *ngIf="isGroupShown(1)">
<div class="list_sub_inner" *ngFor = "let medical_log of treatment_distribution_log ">
<div class="list_bar">
<div class="col floatLeft">
<p>Treatment Type</p>
<h3>{{medical_log.treatment_type}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Treatment Description</p>
<h3>{{medical_log.treatment_description}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Date Treatment Received</p>
<h3>{{medical_log.date_treatment_received}} {{medical_log.time_treatment_received}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Notes</p>
<h3>{{medical_log.notes}}</h3>
</div>
<div class="clear"></div>
</div>
<div class="list_bar">
<div class="col floatLeft">
<p>Given By</p>
<h3>Admin Nuvento</h3>
</div>
<div class="col floatLeft borderNone">
<p>Action</p>
<h3></h3>
</div>
<div class="clear"></div>
</div>
<!-- <div class="list_bar">
<div class="col floatLeft">
<p>Missed Medication</p>
<h3>{{medical_log.missed_medication}}</h3>
</div>
<div class="col floatLeft borderNone">
<p>Action</p>
<h3></h3>
</div>
<div class="clear"></div>
</div> -->
</div>
<hr>
</div>
</li>
</ul>
</div>
</ion-content>
\ No newline at end of file
.nav_title{
width: calc(100% - 50px);
padding-left: 0px;
}
.list_wrapper{
ul{
margin:0px;
padding:10px;
li{
list-style: none;
margin-bottom: 10px;
.list_main{
padding: 10px;
background-color: #e8effa !important;
border-left:3px solid #1b4077;
background-image: url("../../assets/imgs/asset_drop_btn_right.png");
background-position: right 15px top 45%;
background-repeat: no-repeat;
background-size: 20px;
padding-right: 40px;
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
margin-right: 10px;
border-right:1px solid #686868;
}
}
.active{
background: url("../../assets/imgs/asset_drop_btn.png");
background-position: right 15px top 45%;
background-repeat: no-repeat;
background-size: 20px;
}
.list_sub{
padding: 10px;
background: #e8effa;
border-left:3px solid #1b4077;
border-top: 1px solid #c7c7c7;
.list_sub_inner{
border-bottom: 1px solid #fff;
}
hr{
border-top:none;
height:0px;
}
.list_bar{
padding-bottom: 10px;
}
p{
margin:0px;
padding:0px;
color: #0d0d0d;
font-weight: 300;
padding-bottom: 5px;
font-size: 13px;
}
h3{
margin:0px;
padding:0px;
color: #0d0d0d;
font-size: 14px;
font-weight: 400;
}
.col{
padding-right: 10px;
width: calc(50% - 10px);
margin-right: 10px;
border-right:1px solid #686868;
}
}
}
}
}
\ No newline at end of file
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { TreatmenttrackingsPage } from './treatmenttrackings.page';
describe('TreatmenttrackingsPage', () => {
let component: TreatmenttrackingsPage;
let fixture: ComponentFixture<TreatmenttrackingsPage>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ TreatmenttrackingsPage ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(TreatmenttrackingsPage);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import {Component,OnInit, ElementRef, NgZone, ViewChild} from '@angular/core';
import { trigger, transition, animate, style } from '@angular/animations';
@Component({
selector: 'app-treatmenttrackings',
templateUrl: './treatmenttrackings.page.html',
styleUrls: ['./treatmenttrackings.page.scss'],
})
export class TreatmenttrackingsPage implements OnInit {
shownGroup = null;
treatment_schedule_open:any;
treatment_distribution_log:any
constructor() {
this.shownGroup = 0;
this.get_treattrackings();
}
ngOnInit() {
}
isGroupShown(group) {
return this.shownGroup === group;
}
toggleGroup(group) {
if (this.isGroupShown(group)) {
this.shownGroup = null;
} else {
this.shownGroup = group;
}
}
get_treattrackings()
{
this.treatment_schedule_open= {
"treatment_type":"Tube feeding",
"times_perday":"2",
"Action":"approve"
};
var log = {
data:[
{
"treatment_type":"Inhalation",
"treatment_description":"test",
"date_treatment_received":"6/7/2019",
"time_treatment_received":"6:30:00",
"notes":"test"
},
{
"treatment_type":"Tube feeding",
"treatment_description":"test",
"date_treatment_received":"06/14/2019",
"time_treatment_received":"03.10.00",
"notes":"test",
}]
}
this.treatment_distribution_log =log.data;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment