Compare commits
	
		
			3 Commits
		
	
	
		
			21e3f97891
			...
			a84ddd9f03
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| a84ddd9f03 | |||
| 54278bb753 | |||
| 291df2525b | 
@ -1,11 +1,8 @@
 | 
			
		||||
<div>
 | 
			
		||||
  <p-table
 | 
			
		||||
    #dt2
 | 
			
		||||
    dataKey="id"
 | 
			
		||||
    [value]="appointments"
 | 
			
		||||
    [paginator]="true"
 | 
			
		||||
    [rows]="10"
 | 
			
		||||
    [rowsPerPageOptions]="[10, 20, 50]"
 | 
			
		||||
  <p-table #dt2 dataKey="id" [value]="appointments" [paginator]="true" [rows]="10" [totalRecords]="totalRecords"
 | 
			
		||||
  [lazy]="true" (onLazyLoad)="loadappointments($event)" [rowsPerPageOptions]="[10, 20, 50]"
 | 
			
		||||
  [responsiveLayout]="'scroll'" [globalFilterFields]="['id', 'name', 'status']"
 | 
			
		||||
  [filters]="{ global: { value: '', matchMode: 'contains' } }" class="table table-striped"
 | 
			
		||||
  >
 | 
			
		||||
    <ng-template pTemplate="caption">
 | 
			
		||||
      <div class="flex align-items-center justify-content-between mb-3 gap-3">
 | 
			
		||||
@ -14,7 +11,7 @@
 | 
			
		||||
 | 
			
		||||
        <!-- Center: Search Bar with Icon Inside -->
 | 
			
		||||
        <div class="flex-grow-1 flex justify-content-center">
 | 
			
		||||
          <span class="p-input-icon-left w-50">
 | 
			
		||||
          <span class="p-input-icon-left w-100">
 | 
			
		||||
            <i class="pi pi-search"></i>
 | 
			
		||||
            <input
 | 
			
		||||
              pInputText
 | 
			
		||||
@ -26,30 +23,36 @@
 | 
			
		||||
            />
 | 
			
		||||
          </span>
 | 
			
		||||
        </div>
 | 
			
		||||
 | 
			
		||||
        <!-- Right: Add Button -->
 | 
			
		||||
        <div>
 | 
			
		||||
            <button pButton class="p-button-rounded p-button-secondary ml-2" (click)="loadappointments($event)">
 | 
			
		||||
                <i class="pi pi-refresh"></i>
 | 
			
		||||
            </button>
 | 
			
		||||
          <button
 | 
			
		||||
            *ngIf="createPermission"
 | 
			
		||||
            pButton
 | 
			
		||||
            class="p-button-rounded p-button-success"
 | 
			
		||||
            class="p-button-rounded p-button-success ml-2"
 | 
			
		||||
            (click)="openNewAppointmentDialog()"
 | 
			
		||||
            pTooltip="Add Appointment"
 | 
			
		||||
            tooltipPosition="left"
 | 
			
		||||
          >
 | 
			
		||||
            <i class="pi pi-plus-circle"></i>
 | 
			
		||||
          </button>
 | 
			
		||||
          <button pButton class="p-button-rounded p-button-warning ml-2" (click)="exportPatient()">
 | 
			
		||||
            <i class="pi pi-download"></i>
 | 
			
		||||
        </button>
 | 
			
		||||
        </div>
 | 
			
		||||
      </div>
 | 
			
		||||
    </ng-template>
 | 
			
		||||
 | 
			
		||||
    <ng-template pTemplate="header">
 | 
			
		||||
      <tr>
 | 
			
		||||
        <th pSortableColumn="name">Name <p-sortIcon field="name" /></th>
 | 
			
		||||
        <th pSortableColumn="firstName">Name <p-sortIcon field="firstName" /></th>
 | 
			
		||||
        <th pSortableColumn="doctor">Doctor <p-sortIcon field="doctor" /></th>
 | 
			
		||||
        <th pSortableColumn="date">Date <p-sortIcon field="date" /></th>
 | 
			
		||||
        <th pSortableColumn="Time">Time<p-sortIcon field="Time" /></th>
 | 
			
		||||
        <th pSortableColumn="mobile">Mobile No<p-sortIcon field="mobile" /></th>
 | 
			
		||||
        <th pSortableColumn="gender">gender <p-sortIcon field="gender" /></th>
 | 
			
		||||
        <th pSortableColumn="dateOfAppointment">Date <p-sortIcon field="dateOfAppointment" /></th>
 | 
			
		||||
        <th pSortableColumn="timeOfAppointment">Time<p-sortIcon field="timeOfAppointment" /></th>
 | 
			
		||||
        <th>Mobile No</th>
 | 
			
		||||
        <th>Email</th>
 | 
			
		||||
        <th pSortableColumn="status">Appointment Status<p-sortIcon field="status" /></th>
 | 
			
		||||
        <th pSortableColumn="visitType">Visit Type<p-sortIcon field="visitType" /></th>
 | 
			
		||||
        <th>Actions</th>
 | 
			
		||||
@ -58,11 +61,13 @@
 | 
			
		||||
 | 
			
		||||
    <ng-template pTemplate="body" let-appointment>
 | 
			
		||||
      <tr>
 | 
			
		||||
        <td>{{ appointment.name }}</td>
 | 
			
		||||
        <td>{{ appointment.firstName }} {{ appointment.lastName }}</td>
 | 
			
		||||
        <td>{{ appointment.doctor }}</td>
 | 
			
		||||
        <td>{{ appointment.date | date }}</td>
 | 
			
		||||
        <td>{{ appointment.time }}</td>
 | 
			
		||||
        <td></td>
 | 
			
		||||
        <td>{{ appointment.dateOfAppointment | date }}</td>
 | 
			
		||||
        <td><i class="pi pi-clock"></i> {{ appointment.timeOfAppointment }}</td>
 | 
			
		||||
        <td>{{ appointment.mobile }}</td>
 | 
			
		||||
        <td>{{ appointment.email }}</td>
 | 
			
		||||
        <td>{{ appointment.status }}</td>
 | 
			
		||||
        <td>{{ appointment.visitType }}</td>
 | 
			
		||||
        <td>
 | 
			
		||||
@ -89,7 +94,7 @@
 | 
			
		||||
        <label for="fname">First Name</label>
 | 
			
		||||
        <span class="p-input-icon-left">
 | 
			
		||||
          <i class="pi pi-user"></i>
 | 
			
		||||
          <input pInputText id="fname" name="fname" [(ngModel)]="appointment.firstname" required />
 | 
			
		||||
          <input pInputText id="fname" name="fname" [(ngModel)]="appointment.firstName" required />
 | 
			
		||||
        </span>
 | 
			
		||||
      </div>
 | 
			
		||||
      <div class="field col-md-1"></div>
 | 
			
		||||
@ -98,16 +103,16 @@
 | 
			
		||||
        <label for="lname">Last Name</label>
 | 
			
		||||
        <span class="p-input-icon-left">
 | 
			
		||||
          <i class="pi pi-user"></i>
 | 
			
		||||
          <input pInputText id="lname" name="lname" [(ngModel)]="appointment.lastname" required />
 | 
			
		||||
          <input pInputText id="lname" name="lname" [(ngModel)]="appointment.lastName" required />
 | 
			
		||||
        </span>
 | 
			
		||||
      </div>
 | 
			
		||||
 | 
			
		||||
      <div class="field col-md-5">
 | 
			
		||||
        <label>Gender</label>
 | 
			
		||||
        <div class="flex align-items-center">
 | 
			
		||||
          <p-radioButton name="gender" value="Male" [(ngModel)]="appointment.gender" inputId="male" required></p-radioButton>
 | 
			
		||||
          <p-radioButton name="gender" value="1" [(ngModel)]="appointment.gender" inputId="male" required></p-radioButton>
 | 
			
		||||
          <label for="male" class="ml-2 mr-3">Male</label>
 | 
			
		||||
          <p-radioButton name="gender" value="Female" [(ngModel)]="appointment.gender" inputId="female" required></p-radioButton>
 | 
			
		||||
          <p-radioButton name="gender" value="2" [(ngModel)]="appointment.gender" inputId="female" required></p-radioButton>
 | 
			
		||||
          <label for="female" class="ml-2">Female</label>
 | 
			
		||||
        </div>
 | 
			
		||||
      </div>
 | 
			
		||||
@ -119,53 +124,59 @@
 | 
			
		||||
          <i class="pi pi-phone"></i>
 | 
			
		||||
          <input pInputText id="mobile" name="mobile" [(ngModel)]="appointment.mobile" required />
 | 
			
		||||
        </span>
 | 
			
		||||
        <small class="p-error" *ngIf="appointmentForm.controls.mobile?.invalid && appointmentForm.controls.mobile?.touched">Mobile number Required</small>
 | 
			
		||||
      </div>
 | 
			
		||||
      <div class="field col-md-11">
 | 
			
		||||
        <label for="mobile">Address</label>
 | 
			
		||||
        <span class="p-input-icon-left">
 | 
			
		||||
          <i class="pi pi-map-marker"></i>
 | 
			
		||||
          <input pInputText id="Address" name="Address" [(ngModel)]="appointment.Address" required />
 | 
			
		||||
          <input pInputText id="Address" name="Address" [(ngModel)]="appointment.address" required />
 | 
			
		||||
        </span>
 | 
			
		||||
      </div>
 | 
			
		||||
  
 | 
			
		||||
      <div class="field col-md-5">
 | 
			
		||||
        <label for="email">Email ID</label>
 | 
			
		||||
        <span class="p-input-icon-left">
 | 
			
		||||
          <i class="pi pi-envelope"></i>
 | 
			
		||||
          <input pInputText id="email" name="email" [(ngModel)]="appointment.email" required email />
 | 
			
		||||
          <input pInputText id="email" name="email" [(ngModel)]="appointment.email" required/>
 | 
			
		||||
        </span>
 | 
			
		||||
        <small class="p-error" *ngIf="appointmentForm.controls.email?.invalid && appointmentForm.controls.email?.touched">Email address Required</small>
 | 
			
		||||
      </div>
 | 
			
		||||
<!--       
 | 
			
		||||
      <div class="field col-md-1"></div>
 | 
			
		||||
      
 | 
			
		||||
      <div class="field col-md-5">
 | 
			
		||||
        <label for="dob">Date of Birth</label>
 | 
			
		||||
        <p-calendar id="dob" name="dob" [(ngModel)]="appointment.dob" [showIcon]="true" required></p-calendar>
 | 
			
		||||
      </div> -->
 | 
			
		||||
      <div class="field col-md-1"></div>
 | 
			
		||||
        <p-calendar id="dob" required name="dob" [(ngModel)]="appointment.dob" [showIcon]="true" required></p-calendar>
 | 
			
		||||
        <small class="p-error" *ngIf="appointmentForm.controls.dob?.invalid && appointmentForm.controls.dob?.touched">DOB Required</small>
 | 
			
		||||
      
 | 
			
		||||
    </div>
 | 
			
		||||
      
 | 
			
		||||
      <div class="field col-md-5">
 | 
			
		||||
        <label for="doctor">Consulting Doctor</label>
 | 
			
		||||
        <p-dropdown id="doctor" name="doctor" [(ngModel)]="appointment.doctor" [options]="doctorOptions" placeholder="Select Doctor" optionLabel="label" optionValue="value" required></p-dropdown>
 | 
			
		||||
        <p-dropdown id="doctor" name="doctor" [(ngModel)]="appointment.doctorId" [options]="doctorOptions" placeholder="Select Doctor" optionLabel="label" optionValue="value" required></p-dropdown>
 | 
			
		||||
      </div>
 | 
			
		||||
      <div class="field col-md-1"></div>
 | 
			
		||||
      
 | 
			
		||||
      <div class="field col-md-5">
 | 
			
		||||
        <label for="date">Date of Appointment</label>
 | 
			
		||||
        <p-calendar id="date" name="date" [(ngModel)]="appointment.date" [showIcon]="true" required></p-calendar>
 | 
			
		||||
        <p-calendar id="date" name="date" [(ngModel)]="appointment.dateOfAppointment" [showIcon]="true" required></p-calendar>
 | 
			
		||||
      </div>
 | 
			
		||||
      <div class="field col-md-1"></div>
 | 
			
		||||
      
 | 
			
		||||
      <div class="field col-md-5">
 | 
			
		||||
        <label for="time">Time Of Appointment</label>
 | 
			
		||||
        <span class="p-input-icon-left">
 | 
			
		||||
          <i class="pi pi-clock"></i>
 | 
			
		||||
          <input pInputText id="time" name="time" type="time" [(ngModel)]="appointment.time" required />
 | 
			
		||||
          <input pInputText id="time" name="time" type="time" [(ngModel)]="appointment.timeOfAppointment" required />
 | 
			
		||||
        </span>
 | 
			
		||||
      </div>
 | 
			
		||||
      <div class="field col-md-1"></div>
 | 
			
		||||
 | 
			
		||||
      <!-- Injury (Full Width) -->
 | 
			
		||||
      <div class="field col-11">
 | 
			
		||||
      <div class="field col-md-5">
 | 
			
		||||
        <label for="injury">Injury/Condition</label>
 | 
			
		||||
        <span class="p-input-icon-left">
 | 
			
		||||
          <i class="pi pi-exclamation-triangle"></i>
 | 
			
		||||
          <input pInputText id="injury" name="injury" [(ngModel)]="appointment.injury" />
 | 
			
		||||
          <input pInputText id="injury" name="injury" [(ngModel)]="appointment.injuryORContion" />
 | 
			
		||||
        </span>
 | 
			
		||||
      </div>
 | 
			
		||||
<!-- 
 | 
			
		||||
@ -195,7 +206,7 @@
 | 
			
		||||
      <!-- Notes (Full Width) -->
 | 
			
		||||
      <div class="field col-11">
 | 
			
		||||
        <label for="notes">Notes</label>
 | 
			
		||||
        <textarea id="notes" name="notes" [(ngModel)]="appointment.notes" rows="5"cols="30"pInputTextarea></textarea>
 | 
			
		||||
        <textarea id="notes" name="notes" [(ngModel)]="appointment.note" rows="5"cols="30"pInputTextarea></textarea>
 | 
			
		||||
      
 | 
			
		||||
 | 
			
		||||
    </div>
 | 
			
		||||
 | 
			
		||||
@ -1,6 +1,11 @@
 | 
			
		||||
import { ConfirmationService, ToasterService } from '@abp/ng.theme.shared';
 | 
			
		||||
import { HttpClient } from '@angular/common/http';
 | 
			
		||||
import { Component } from '@angular/core';
 | 
			
		||||
import { NgForm } from '@angular/forms';
 | 
			
		||||
import { AppointmentDto } from '@proxy/appoinments/dto';
 | 
			
		||||
import { AppointmentService } from '@proxy/appointments';
 | 
			
		||||
import { DoctorService } from '@proxy/doctors';
 | 
			
		||||
import { PagingSortResultDto } from '@proxy/dto';
 | 
			
		||||
import { Gender } from '@proxy/global-enum';
 | 
			
		||||
 | 
			
		||||
@Component({
 | 
			
		||||
@ -17,69 +22,28 @@ export class ViewAppointmentComponent {
 | 
			
		||||
  appointmentDialog = false;
 | 
			
		||||
  genders = Gender;
 | 
			
		||||
  isEditMode: boolean = false;
 | 
			
		||||
  loading: boolean = false;
 | 
			
		||||
  params: PagingSortResultDto;
 | 
			
		||||
 | 
			
		||||
  appointment = {
 | 
			
		||||
    firstname: '',
 | 
			
		||||
    lastname: '',
 | 
			
		||||
  appointment: AppointmentDto = {
 | 
			
		||||
    id: '',
 | 
			
		||||
    firstName: '',
 | 
			
		||||
    lastName: '',
 | 
			
		||||
    email: '',
 | 
			
		||||
    gender: Gender.Male,
 | 
			
		||||
    date: '',
 | 
			
		||||
    dob:'',
 | 
			
		||||
    time: '',
 | 
			
		||||
    mobile: '',
 | 
			
		||||
    injury: '',
 | 
			
		||||
    insuranceProvider: '',
 | 
			
		||||
    notes: '',
 | 
			
		||||
    doctor: '',
 | 
			
		||||
    status: '',
 | 
			
		||||
    visitType: '',
 | 
			
		||||
    paymentStatus: '',
 | 
			
		||||
    Address:''
 | 
			
		||||
    address: '',
 | 
			
		||||
    dob: '',
 | 
			
		||||
    doctorId: '',
 | 
			
		||||
    dateOfAppointment: '',
 | 
			
		||||
    timeOfAppointment: '',
 | 
			
		||||
    injuryORContion: '',
 | 
			
		||||
    note: '',
 | 
			
		||||
  };
 | 
			
		||||
  appointments = [
 | 
			
		||||
    {
 | 
			
		||||
      id: 1,
 | 
			
		||||
      firstname: 'John',
 | 
			
		||||
      lastname: 'Doe',
 | 
			
		||||
      doctor: 'Dr. Smith',
 | 
			
		||||
      gender: 1,
 | 
			
		||||
      date: new Date(),
 | 
			
		||||
      time: '10:00 AM',
 | 
			
		||||
      mobile: '1234567890',
 | 
			
		||||
      email: 'john@example.com',
 | 
			
		||||
      status: 1,
 | 
			
		||||
      visitType: 'Consultation',
 | 
			
		||||
    },
 | 
			
		||||
    {
 | 
			
		||||
      id: 2,
 | 
			
		||||
      firstname: 'Jane',
 | 
			
		||||
      lastname: 'Smith',
 | 
			
		||||
      doctor: 'Dr. Johnson',
 | 
			
		||||
      gender: 0,
 | 
			
		||||
      date: new Date(),
 | 
			
		||||
      time: '2:00 PM',
 | 
			
		||||
      mobile: '0987654321',
 | 
			
		||||
      email: 'jane@example.com',
 | 
			
		||||
      status: 2,
 | 
			
		||||
      visitType: 'Follow-up',
 | 
			
		||||
    },
 | 
			
		||||
    {
 | 
			
		||||
      id: 3,
 | 
			
		||||
      firstname: 'Mike',
 | 
			
		||||
      lastname: 'Johnson',
 | 
			
		||||
      doctor: 'Dr. Brown',
 | 
			
		||||
      gender: 1,
 | 
			
		||||
      date: new Date(),
 | 
			
		||||
      time: '4:30 PM',
 | 
			
		||||
      mobile: '1112223333',
 | 
			
		||||
      email: 'mike@example.com',
 | 
			
		||||
      status: 1,
 | 
			
		||||
      visitType: 'Surgery',
 | 
			
		||||
    },
 | 
			
		||||
  ];
 | 
			
		||||
 | 
			
		||||
  appointments = [];
 | 
			
		||||
  // status = { 1: 'Scheduled', 2: 'Completed', 3: 'Canceled' };
 | 
			
		||||
 
 | 
			
		||||
  
 | 
			
		||||
 | 
			
		||||
  doctors = [];
 | 
			
		||||
  doctorOptions = [];
 | 
			
		||||
  appointmentStatuses = [
 | 
			
		||||
@ -100,32 +64,59 @@ export class ViewAppointmentComponent {
 | 
			
		||||
  createPermission = true;
 | 
			
		||||
  editPermission = true;
 | 
			
		||||
  deletePermission = true;
 | 
			
		||||
  constructor(private DoctorService: DoctorService) {}
 | 
			
		||||
  constructor(
 | 
			
		||||
    private DoctorService: DoctorService,
 | 
			
		||||
    private AppointmentService: AppointmentService,
 | 
			
		||||
    private http: HttpClient,
 | 
			
		||||
    private confirmation: ConfirmationService,
 | 
			
		||||
    private toaster: ToasterService
 | 
			
		||||
  ) {}
 | 
			
		||||
 | 
			
		||||
  ngOnInit(): void {
 | 
			
		||||
    this.getdoctorlist();
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
    this.loadappointments({
 | 
			
		||||
      first: 0,
 | 
			
		||||
      rows: 10,
 | 
			
		||||
      sortField: 'id',
 | 
			
		||||
      sortOrder: 1,
 | 
			
		||||
      globalFilter: null,
 | 
			
		||||
    });
 | 
			
		||||
  }
 | 
			
		||||
  loadappointments(event: any) {
 | 
			
		||||
    this.loading = true;
 | 
			
		||||
    let order = event.sortOrder == 1 ? ' asc' : ' desc';
 | 
			
		||||
    event.sortField = event.sortField == undefined ? 'id' : event.sortField;
 | 
			
		||||
    this.params = {
 | 
			
		||||
      skipCount: event.first,
 | 
			
		||||
      maxResultCount: event.rows,
 | 
			
		||||
      sorting: event.sortField + order,
 | 
			
		||||
      search: event.globalFilter == null ? '' : event.globalFilter,
 | 
			
		||||
    };
 | 
			
		||||
 | 
			
		||||
    this.AppointmentService.getAppointmentList(this.params).subscribe(data => {
 | 
			
		||||
      this.appointments = data.items;
 | 
			
		||||
      debugger
 | 
			
		||||
      this.totalRecords = data.totalCount;
 | 
			
		||||
      this.loading = false;
 | 
			
		||||
    });
 | 
			
		||||
  }
 | 
			
		||||
  openNewAppointmentDialog() {
 | 
			
		||||
    this.isEditing = false;
 | 
			
		||||
    this.appointmentDialog = true;
 | 
			
		||||
    this.appointment = {
 | 
			
		||||
      firstname: '',
 | 
			
		||||
      lastname: '',
 | 
			
		||||
      firstName: '',
 | 
			
		||||
      lastName: '',
 | 
			
		||||
      email: '',
 | 
			
		||||
      gender: Gender.Male,
 | 
			
		||||
      date: '',
 | 
			
		||||
      dob:'',
 | 
			
		||||
      time: '',
 | 
			
		||||
      dateOfAppointment: '',
 | 
			
		||||
      dob: '',
 | 
			
		||||
      timeOfAppointment: '',
 | 
			
		||||
      mobile: '',
 | 
			
		||||
      injury: '',
 | 
			
		||||
      insuranceProvider: '',
 | 
			
		||||
      notes: '',
 | 
			
		||||
      doctor: '',
 | 
			
		||||
      status: '',
 | 
			
		||||
      visitType: '',
 | 
			
		||||
      paymentStatus: '',
 | 
			
		||||
      Address:''
 | 
			
		||||
      injuryORContion: '',
 | 
			
		||||
      note: '',
 | 
			
		||||
      doctorId: '',
 | 
			
		||||
      address: '',
 | 
			
		||||
    };
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
@ -141,14 +132,50 @@ export class ViewAppointmentComponent {
 | 
			
		||||
    console.log('Deleting appointment with ID', id);
 | 
			
		||||
  }
 | 
			
		||||
  saveAppointment(form: NgForm) {
 | 
			
		||||
    debugger
 | 
			
		||||
     console.log(form.controls);
 | 
			
		||||
     if (form.invalid) {
 | 
			
		||||
       Object.values(form.controls).forEach(control => control.markAsTouched());
 | 
			
		||||
       return;
 | 
			
		||||
     }
 | 
			
		||||
 | 
			
		||||
   }
 | 
			
		||||
    debugger;
 | 
			
		||||
    console.log(form.controls);
 | 
			
		||||
    if (form.invalid) {
 | 
			
		||||
      Object.values(form.controls).forEach(control => control.markAsTouched());
 | 
			
		||||
      return;
 | 
			
		||||
    }
 | 
			
		||||
    if (this.isEditMode) {
 | 
			
		||||
      this.AppointmentService.createAppointment(this.appointment).subscribe(
 | 
			
		||||
        () => {
 | 
			
		||||
          this.toaster.success('Appointment updated successfully', 'Success');
 | 
			
		||||
          this.AppointmentDialog = false;
 | 
			
		||||
          // this.loadPatient({
 | 
			
		||||
          //   first: 0,
 | 
			
		||||
          //   rows: 10,
 | 
			
		||||
          //   sortField: 'id',
 | 
			
		||||
          //   sortOrder: 1,
 | 
			
		||||
          //   globalFilter: null,
 | 
			
		||||
          // });
 | 
			
		||||
        },
 | 
			
		||||
        error => {
 | 
			
		||||
          console.log(error);
 | 
			
		||||
          this.closeDialog();
 | 
			
		||||
        }
 | 
			
		||||
      );
 | 
			
		||||
    } else {
 | 
			
		||||
      this.AppointmentService.createAppointment(this.appointment).subscribe(
 | 
			
		||||
        () => {
 | 
			
		||||
          this.toaster.success('Appointment created successfully', 'Success');
 | 
			
		||||
          this.AppointmentDialog = false;
 | 
			
		||||
          // this.loadPatient({
 | 
			
		||||
          //   first: 0,
 | 
			
		||||
          //   rows: 10,
 | 
			
		||||
          //   sortField: 'id',
 | 
			
		||||
          //   sortOrder: 1,
 | 
			
		||||
          //   globalFilter: null,
 | 
			
		||||
          // });
 | 
			
		||||
        },
 | 
			
		||||
        error => {
 | 
			
		||||
          console.log(error);
 | 
			
		||||
          this.closeDialog();
 | 
			
		||||
        }
 | 
			
		||||
      );
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  closeDialog() {
 | 
			
		||||
    this.appointmentDialog = false;
 | 
			
		||||
 | 
			
		||||
@ -4,7 +4,7 @@ import { HttpClient } from '@angular/common/http';
 | 
			
		||||
import { Component, OnInit } from '@angular/core';
 | 
			
		||||
import { NgForm } from '@angular/forms';
 | 
			
		||||
import { Router } from '@angular/router';
 | 
			
		||||
import { PagingSortPatientResultDto } from '@proxy/dto';
 | 
			
		||||
import { PagingSortResultDto } from '@proxy/dto';
 | 
			
		||||
import { Gender, Status } from '@proxy/global-enum';
 | 
			
		||||
import { PatientService } from '@proxy/patients';
 | 
			
		||||
import { PatientDto, CreateUpdatePatientDto } from '@proxy/patients/dto';
 | 
			
		||||
@ -24,7 +24,7 @@ export class AllPatientsComponent implements OnInit {
 | 
			
		||||
  selectedPatient: CreateUpdatePatientDto;
 | 
			
		||||
  isEditMode: boolean = false;
 | 
			
		||||
  patientDialogTitle: string = '';
 | 
			
		||||
  params: PagingSortPatientResultDto;
 | 
			
		||||
  params: PagingSortResultDto;
 | 
			
		||||
  status: any;
 | 
			
		||||
  gender: any;
 | 
			
		||||
  statuslist: any;
 | 
			
		||||
 | 
			
		||||
@ -1,6 +1,6 @@
 | 
			
		||||
import { Component, OnInit } from '@angular/core';
 | 
			
		||||
import { NgForm } from '@angular/forms';
 | 
			
		||||
import { PagingSortPatientResultDto } from '@proxy/dto';
 | 
			
		||||
import { PagingSortResultDto } from '@proxy/dto';
 | 
			
		||||
import { Gender, Status } from '@proxy/global-enum';
 | 
			
		||||
import { PatientService } from '@proxy/patients';
 | 
			
		||||
import { CreateUpdatePatientRecordDto, PatientDto, PatientRecordDto } from '@proxy/patients/dto';
 | 
			
		||||
@ -25,7 +25,7 @@ export class PatientRecordComponent implements OnInit {
 | 
			
		||||
  patientdto: PatientDto;
 | 
			
		||||
  isEditMode: boolean = false;
 | 
			
		||||
  patientDialogTitle: string = '';
 | 
			
		||||
  params: PagingSortPatientResultDto;
 | 
			
		||||
  params: PagingSortResultDto;
 | 
			
		||||
  status: any;
 | 
			
		||||
  gender: any;
 | 
			
		||||
  statuslist: any;
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										2
									
								
								angular/src/app/proxy/abp/application/index.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								angular/src/app/proxy/abp/application/index.ts
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,2 @@
 | 
			
		||||
import * as Services from './services';
 | 
			
		||||
export { Services };
 | 
			
		||||
@ -0,0 +1 @@
 | 
			
		||||
export * from './models';
 | 
			
		||||
@ -0,0 +1,8 @@
 | 
			
		||||
 | 
			
		||||
export interface ListResultDto<T> {
 | 
			
		||||
  items: T[];
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export interface PagedResultDto<T> extends ListResultDto<T> {
 | 
			
		||||
  totalCount: number;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										2
									
								
								angular/src/app/proxy/abp/application/services/index.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								angular/src/app/proxy/abp/application/services/index.ts
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,2 @@
 | 
			
		||||
import * as Dto from './dto';
 | 
			
		||||
export { Dto };
 | 
			
		||||
							
								
								
									
										2
									
								
								angular/src/app/proxy/abp/index.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								angular/src/app/proxy/abp/index.ts
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,2 @@
 | 
			
		||||
import * as Application from './application';
 | 
			
		||||
export { Application };
 | 
			
		||||
							
								
								
									
										1
									
								
								angular/src/app/proxy/appoinments/dto/index.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								angular/src/app/proxy/appoinments/dto/index.ts
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1 @@
 | 
			
		||||
export * from './models';
 | 
			
		||||
							
								
								
									
										33
									
								
								angular/src/app/proxy/appoinments/dto/models.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								angular/src/app/proxy/appoinments/dto/models.ts
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,33 @@
 | 
			
		||||
import type { Gender } from '../../global-enum/gender.enum';
 | 
			
		||||
 | 
			
		||||
export interface AppointmentDto {
 | 
			
		||||
  id?: string;
 | 
			
		||||
  firstName?: string;
 | 
			
		||||
  lastName?: string;
 | 
			
		||||
  gender: Gender;
 | 
			
		||||
  mobile?: string;
 | 
			
		||||
  address?: string;
 | 
			
		||||
  email?: string;
 | 
			
		||||
  dob?: string;
 | 
			
		||||
  doctorId?: string;
 | 
			
		||||
  dateOfAppointment?: string;
 | 
			
		||||
  timeOfAppointment?: string;
 | 
			
		||||
  injuryORContion?: string;
 | 
			
		||||
  note?: string;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export interface CreateOrUpdateAppointmentDto {
 | 
			
		||||
  id?: string;
 | 
			
		||||
  firstName?: string;
 | 
			
		||||
  lastName?: string;
 | 
			
		||||
  gender: Gender;
 | 
			
		||||
  mobile?: string;
 | 
			
		||||
  address?: string;
 | 
			
		||||
  email?: string;
 | 
			
		||||
  dob?: string;
 | 
			
		||||
  doctorId?: string;
 | 
			
		||||
  dateOfAppointment?: string;
 | 
			
		||||
  timeOfAppointment?: string;
 | 
			
		||||
  injuryORContion?: string;
 | 
			
		||||
  note?: string;
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										2
									
								
								angular/src/app/proxy/appoinments/index.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								angular/src/app/proxy/appoinments/index.ts
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,2 @@
 | 
			
		||||
import * as Dto from './dto';
 | 
			
		||||
export { Dto };
 | 
			
		||||
@ -1,5 +1,9 @@
 | 
			
		||||
import { RestService, Rest } from '@abp/ng.core';
 | 
			
		||||
import { Injectable } from '@angular/core';
 | 
			
		||||
import type { PagedResultDto } from '../abp/application/services/dto/models';
 | 
			
		||||
import type { AppointmentDto, CreateOrUpdateAppointmentDto } from '../appoinments/dto/models';
 | 
			
		||||
import type { PagingSortResultDto } from '../dto/models';
 | 
			
		||||
import type { PatientRecordDto } from '../patients/dto/models';
 | 
			
		||||
 | 
			
		||||
@Injectable({
 | 
			
		||||
  providedIn: 'root',
 | 
			
		||||
@ -8,6 +12,15 @@ export class AppointmentService {
 | 
			
		||||
  apiName = 'Default';
 | 
			
		||||
  
 | 
			
		||||
 | 
			
		||||
  createAppointment = (input: CreateOrUpdateAppointmentDto, config?: Partial<Rest.Config>) =>
 | 
			
		||||
    this.restService.request<any, AppointmentDto>({
 | 
			
		||||
      method: 'POST',
 | 
			
		||||
      url: '/api/app/appointment/appointment',
 | 
			
		||||
      body: input,
 | 
			
		||||
    },
 | 
			
		||||
    { apiName: this.apiName,...config });
 | 
			
		||||
  
 | 
			
		||||
 | 
			
		||||
  get = (config?: Partial<Rest.Config>) =>
 | 
			
		||||
    this.restService.request<any, string>({
 | 
			
		||||
      method: 'GET',
 | 
			
		||||
@ -15,6 +28,24 @@ export class AppointmentService {
 | 
			
		||||
      url: '/api/app/appointment',
 | 
			
		||||
    },
 | 
			
		||||
    { apiName: this.apiName,...config });
 | 
			
		||||
  
 | 
			
		||||
 | 
			
		||||
  getAppointmentList = (input: PagingSortResultDto, config?: Partial<Rest.Config>) =>
 | 
			
		||||
    this.restService.request<any, PagedResultDto<AppointmentDto>>({
 | 
			
		||||
      method: 'GET',
 | 
			
		||||
      url: '/api/app/appointment/appointment-list',
 | 
			
		||||
      params: { search: input.search, sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },
 | 
			
		||||
    },
 | 
			
		||||
    { apiName: this.apiName,...config });
 | 
			
		||||
  
 | 
			
		||||
 | 
			
		||||
  updateAppointment = (id: string, input: CreateOrUpdateAppointmentDto, config?: Partial<Rest.Config>) =>
 | 
			
		||||
    this.restService.request<any, PatientRecordDto>({
 | 
			
		||||
      method: 'PUT',
 | 
			
		||||
      url: `/api/app/appointment/${id}/appointment`,
 | 
			
		||||
      body: input,
 | 
			
		||||
    },
 | 
			
		||||
    { apiName: this.apiName,...config });
 | 
			
		||||
 | 
			
		||||
  constructor(private restService: RestService) {}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -10,6 +10,6 @@ export interface FileDownloadDto {
 | 
			
		||||
  fileContent?: string;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export interface PagingSortPatientResultDto extends PagedAndSortedResultRequestDto {
 | 
			
		||||
export interface PagingSortResultDto extends PagedAndSortedResultRequestDto {
 | 
			
		||||
  search?: string;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -911,6 +911,173 @@
 | 
			
		||||
              },
 | 
			
		||||
              "allowAnonymous": null,
 | 
			
		||||
              "implementFrom": "HospitalManagementSystem.Appointments.IAppointmentAppService"
 | 
			
		||||
            },
 | 
			
		||||
            "GetAppointmentListAsyncByInput": {
 | 
			
		||||
              "uniqueName": "GetAppointmentListAsyncByInput",
 | 
			
		||||
              "name": "GetAppointmentListAsync",
 | 
			
		||||
              "httpMethod": "GET",
 | 
			
		||||
              "url": "api/app/appointment/appointment-list",
 | 
			
		||||
              "supportedVersions": [],
 | 
			
		||||
              "parametersOnMethod": [
 | 
			
		||||
                {
 | 
			
		||||
                  "name": "input",
 | 
			
		||||
                  "typeAsString": "HospitalManagementSystem.Dto.PagingSortResultDto, HospitalManagementSystem.Domain.Shared",
 | 
			
		||||
                  "type": "HospitalManagementSystem.Dto.PagingSortResultDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Dto.PagingSortResultDto",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null
 | 
			
		||||
                }
 | 
			
		||||
              ],
 | 
			
		||||
              "parameters": [
 | 
			
		||||
                {
 | 
			
		||||
                  "nameOnMethod": "input",
 | 
			
		||||
                  "name": "Search",
 | 
			
		||||
                  "jsonName": null,
 | 
			
		||||
                  "type": "System.String",
 | 
			
		||||
                  "typeSimple": "string",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null,
 | 
			
		||||
                  "constraintTypes": null,
 | 
			
		||||
                  "bindingSourceId": "ModelBinding",
 | 
			
		||||
                  "descriptorName": "input"
 | 
			
		||||
                },
 | 
			
		||||
                {
 | 
			
		||||
                  "nameOnMethod": "input",
 | 
			
		||||
                  "name": "Sorting",
 | 
			
		||||
                  "jsonName": null,
 | 
			
		||||
                  "type": "System.String",
 | 
			
		||||
                  "typeSimple": "string",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null,
 | 
			
		||||
                  "constraintTypes": null,
 | 
			
		||||
                  "bindingSourceId": "ModelBinding",
 | 
			
		||||
                  "descriptorName": "input"
 | 
			
		||||
                },
 | 
			
		||||
                {
 | 
			
		||||
                  "nameOnMethod": "input",
 | 
			
		||||
                  "name": "SkipCount",
 | 
			
		||||
                  "jsonName": null,
 | 
			
		||||
                  "type": "System.Int32",
 | 
			
		||||
                  "typeSimple": "number",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null,
 | 
			
		||||
                  "constraintTypes": null,
 | 
			
		||||
                  "bindingSourceId": "ModelBinding",
 | 
			
		||||
                  "descriptorName": "input"
 | 
			
		||||
                },
 | 
			
		||||
                {
 | 
			
		||||
                  "nameOnMethod": "input",
 | 
			
		||||
                  "name": "MaxResultCount",
 | 
			
		||||
                  "jsonName": null,
 | 
			
		||||
                  "type": "System.Int32",
 | 
			
		||||
                  "typeSimple": "number",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null,
 | 
			
		||||
                  "constraintTypes": null,
 | 
			
		||||
                  "bindingSourceId": "ModelBinding",
 | 
			
		||||
                  "descriptorName": "input"
 | 
			
		||||
                }
 | 
			
		||||
              ],
 | 
			
		||||
              "returnValue": {
 | 
			
		||||
                "type": "Abp.Application.Services.Dto.PagedResultDto<HospitalManagementSystem.Appoinments.Dto.AppointmentDto>",
 | 
			
		||||
                "typeSimple": "Abp.Application.Services.Dto.PagedResultDto<HospitalManagementSystem.Appoinments.Dto.AppointmentDto>"
 | 
			
		||||
              },
 | 
			
		||||
              "allowAnonymous": null,
 | 
			
		||||
              "implementFrom": "HospitalManagementSystem.Appointments.AppointmentAppService"
 | 
			
		||||
            },
 | 
			
		||||
            "CreateAppointmentAsyncByInput": {
 | 
			
		||||
              "uniqueName": "CreateAppointmentAsyncByInput",
 | 
			
		||||
              "name": "CreateAppointmentAsync",
 | 
			
		||||
              "httpMethod": "POST",
 | 
			
		||||
              "url": "api/app/appointment/appointment",
 | 
			
		||||
              "supportedVersions": [],
 | 
			
		||||
              "parametersOnMethod": [
 | 
			
		||||
                {
 | 
			
		||||
                  "name": "input",
 | 
			
		||||
                  "typeAsString": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto, HospitalManagementSystem.Application.Contracts",
 | 
			
		||||
                  "type": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null
 | 
			
		||||
                }
 | 
			
		||||
              ],
 | 
			
		||||
              "parameters": [
 | 
			
		||||
                {
 | 
			
		||||
                  "nameOnMethod": "input",
 | 
			
		||||
                  "name": "input",
 | 
			
		||||
                  "jsonName": null,
 | 
			
		||||
                  "type": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null,
 | 
			
		||||
                  "constraintTypes": null,
 | 
			
		||||
                  "bindingSourceId": "Body",
 | 
			
		||||
                  "descriptorName": ""
 | 
			
		||||
                }
 | 
			
		||||
              ],
 | 
			
		||||
              "returnValue": {
 | 
			
		||||
                "type": "HospitalManagementSystem.Appoinments.Dto.AppointmentDto",
 | 
			
		||||
                "typeSimple": "HospitalManagementSystem.Appoinments.Dto.AppointmentDto"
 | 
			
		||||
              },
 | 
			
		||||
              "allowAnonymous": null,
 | 
			
		||||
              "implementFrom": "HospitalManagementSystem.Appointments.AppointmentAppService"
 | 
			
		||||
            },
 | 
			
		||||
            "UpdateAppointmentAsyncByIdAndInput": {
 | 
			
		||||
              "uniqueName": "UpdateAppointmentAsyncByIdAndInput",
 | 
			
		||||
              "name": "UpdateAppointmentAsync",
 | 
			
		||||
              "httpMethod": "PUT",
 | 
			
		||||
              "url": "api/app/appointment/{id}/appointment",
 | 
			
		||||
              "supportedVersions": [],
 | 
			
		||||
              "parametersOnMethod": [
 | 
			
		||||
                {
 | 
			
		||||
                  "name": "id",
 | 
			
		||||
                  "typeAsString": "System.Guid, System.Private.CoreLib",
 | 
			
		||||
                  "type": "System.Guid",
 | 
			
		||||
                  "typeSimple": "string",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null
 | 
			
		||||
                },
 | 
			
		||||
                {
 | 
			
		||||
                  "name": "input",
 | 
			
		||||
                  "typeAsString": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto, HospitalManagementSystem.Application.Contracts",
 | 
			
		||||
                  "type": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null
 | 
			
		||||
                }
 | 
			
		||||
              ],
 | 
			
		||||
              "parameters": [
 | 
			
		||||
                {
 | 
			
		||||
                  "nameOnMethod": "id",
 | 
			
		||||
                  "name": "id",
 | 
			
		||||
                  "jsonName": null,
 | 
			
		||||
                  "type": "System.Guid",
 | 
			
		||||
                  "typeSimple": "string",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null,
 | 
			
		||||
                  "constraintTypes": [],
 | 
			
		||||
                  "bindingSourceId": "Path",
 | 
			
		||||
                  "descriptorName": ""
 | 
			
		||||
                },
 | 
			
		||||
                {
 | 
			
		||||
                  "nameOnMethod": "input",
 | 
			
		||||
                  "name": "input",
 | 
			
		||||
                  "jsonName": null,
 | 
			
		||||
                  "type": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null,
 | 
			
		||||
                  "constraintTypes": null,
 | 
			
		||||
                  "bindingSourceId": "Body",
 | 
			
		||||
                  "descriptorName": ""
 | 
			
		||||
                }
 | 
			
		||||
              ],
 | 
			
		||||
              "returnValue": {
 | 
			
		||||
                "type": "HospitalManagementSystem.Patients.Dto.PatientRecordDto",
 | 
			
		||||
                "typeSimple": "HospitalManagementSystem.Patients.Dto.PatientRecordDto"
 | 
			
		||||
              },
 | 
			
		||||
              "allowAnonymous": null,
 | 
			
		||||
              "implementFrom": "HospitalManagementSystem.Appointments.AppointmentAppService"
 | 
			
		||||
            }
 | 
			
		||||
          }
 | 
			
		||||
        },
 | 
			
		||||
@ -1105,9 +1272,9 @@
 | 
			
		||||
              "parametersOnMethod": [
 | 
			
		||||
                {
 | 
			
		||||
                  "name": "input",
 | 
			
		||||
                  "typeAsString": "HospitalManagementSystem.Dto.PagingSortPatientResultDto, HospitalManagementSystem.Domain.Shared",
 | 
			
		||||
                  "type": "HospitalManagementSystem.Dto.PagingSortPatientResultDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Dto.PagingSortPatientResultDto",
 | 
			
		||||
                  "typeAsString": "HospitalManagementSystem.Dto.PagingSortResultDto, HospitalManagementSystem.Domain.Shared",
 | 
			
		||||
                  "type": "HospitalManagementSystem.Dto.PagingSortResultDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Dto.PagingSortResultDto",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null
 | 
			
		||||
                },
 | 
			
		||||
@ -1381,9 +1548,9 @@
 | 
			
		||||
              "parametersOnMethod": [
 | 
			
		||||
                {
 | 
			
		||||
                  "name": "input",
 | 
			
		||||
                  "typeAsString": "HospitalManagementSystem.Dto.PagingSortPatientResultDto, HospitalManagementSystem.Domain.Shared",
 | 
			
		||||
                  "type": "HospitalManagementSystem.Dto.PagingSortPatientResultDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Dto.PagingSortPatientResultDto",
 | 
			
		||||
                  "typeAsString": "HospitalManagementSystem.Dto.PagingSortResultDto, HospitalManagementSystem.Domain.Shared",
 | 
			
		||||
                  "type": "HospitalManagementSystem.Dto.PagingSortResultDto",
 | 
			
		||||
                  "typeSimple": "HospitalManagementSystem.Dto.PagingSortResultDto",
 | 
			
		||||
                  "isOptional": false,
 | 
			
		||||
                  "defaultValue": null
 | 
			
		||||
                }
 | 
			
		||||
@ -4424,6 +4591,382 @@
 | 
			
		||||
    }
 | 
			
		||||
  },
 | 
			
		||||
  "types": {
 | 
			
		||||
    "Abp.Application.Services.Dto.ListResultDto<T0>": {
 | 
			
		||||
      "baseType": null,
 | 
			
		||||
      "isEnum": false,
 | 
			
		||||
      "enumNames": null,
 | 
			
		||||
      "enumValues": null,
 | 
			
		||||
      "genericArguments": [
 | 
			
		||||
        "T"
 | 
			
		||||
      ],
 | 
			
		||||
      "properties": [
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Items",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "[T]",
 | 
			
		||||
          "typeSimple": "[T]",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        }
 | 
			
		||||
      ]
 | 
			
		||||
    },
 | 
			
		||||
    "Abp.Application.Services.Dto.PagedResultDto<T0>": {
 | 
			
		||||
      "baseType": "Abp.Application.Services.Dto.ListResultDto<T>",
 | 
			
		||||
      "isEnum": false,
 | 
			
		||||
      "enumNames": null,
 | 
			
		||||
      "enumValues": null,
 | 
			
		||||
      "genericArguments": [
 | 
			
		||||
        "T"
 | 
			
		||||
      ],
 | 
			
		||||
      "properties": [
 | 
			
		||||
        {
 | 
			
		||||
          "name": "TotalCount",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.Int32",
 | 
			
		||||
          "typeSimple": "number",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        }
 | 
			
		||||
      ]
 | 
			
		||||
    },
 | 
			
		||||
    "HospitalManagementSystem.Appoinments.Dto.AppointmentDto": {
 | 
			
		||||
      "baseType": null,
 | 
			
		||||
      "isEnum": false,
 | 
			
		||||
      "enumNames": null,
 | 
			
		||||
      "enumValues": null,
 | 
			
		||||
      "genericArguments": null,
 | 
			
		||||
      "properties": [
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Id",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.Guid",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "FirstName",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "LastName",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Gender",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "HospitalManagementSystem.GlobalEnum.Gender",
 | 
			
		||||
          "typeSimple": "HospitalManagementSystem.GlobalEnum.Gender",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Mobile",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Address",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Email",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "DOB",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "DoctorId",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.Guid?",
 | 
			
		||||
          "typeSimple": "string?",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "DateOfAppointment",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.DateTime?",
 | 
			
		||||
          "typeSimple": "string?",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "TimeOfAppointment",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "InjuryORContion",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Note",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        }
 | 
			
		||||
      ]
 | 
			
		||||
    },
 | 
			
		||||
    "HospitalManagementSystem.Appoinments.Dto.CreateOrUpdateAppointmentDto": {
 | 
			
		||||
      "baseType": null,
 | 
			
		||||
      "isEnum": false,
 | 
			
		||||
      "enumNames": null,
 | 
			
		||||
      "enumValues": null,
 | 
			
		||||
      "genericArguments": null,
 | 
			
		||||
      "properties": [
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Id",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.Guid",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "FirstName",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "LastName",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Gender",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "HospitalManagementSystem.GlobalEnum.Gender",
 | 
			
		||||
          "typeSimple": "HospitalManagementSystem.GlobalEnum.Gender",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Mobile",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Address",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Email",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "DOB",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "DoctorId",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.Guid?",
 | 
			
		||||
          "typeSimple": "string?",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "DateOfAppointment",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.DateTime?",
 | 
			
		||||
          "typeSimple": "string?",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "TimeOfAppointment",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "InjuryORContion",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        },
 | 
			
		||||
        {
 | 
			
		||||
          "name": "Note",
 | 
			
		||||
          "jsonName": null,
 | 
			
		||||
          "type": "System.String",
 | 
			
		||||
          "typeSimple": "string",
 | 
			
		||||
          "isRequired": false,
 | 
			
		||||
          "minLength": null,
 | 
			
		||||
          "maxLength": null,
 | 
			
		||||
          "minimum": null,
 | 
			
		||||
          "maximum": null,
 | 
			
		||||
          "regex": null
 | 
			
		||||
        }
 | 
			
		||||
      ]
 | 
			
		||||
    },
 | 
			
		||||
    "HospitalManagementSystem.Documents.EntityDocument": {
 | 
			
		||||
      "baseType": "Volo.Abp.Domain.Entities.Auditing.AuditedAggregateRoot<System.Guid>",
 | 
			
		||||
      "isEnum": false,
 | 
			
		||||
@ -4583,7 +5126,7 @@
 | 
			
		||||
        }
 | 
			
		||||
      ]
 | 
			
		||||
    },
 | 
			
		||||
    "HospitalManagementSystem.Dto.PagingSortPatientResultDto": {
 | 
			
		||||
    "HospitalManagementSystem.Dto.PagingSortResultDto": {
 | 
			
		||||
      "baseType": "Volo.Abp.Application.Dtos.PagedAndSortedResultRequestDto",
 | 
			
		||||
      "isEnum": false,
 | 
			
		||||
      "enumNames": null,
 | 
			
		||||
 | 
			
		||||
@ -1,3 +1,5 @@
 | 
			
		||||
import * as Abp from './abp';
 | 
			
		||||
import * as Appoinments from './appoinments';
 | 
			
		||||
import * as Appointments from './appointments';
 | 
			
		||||
import * as Departments from './departments';
 | 
			
		||||
import * as Doctors from './doctors';
 | 
			
		||||
@ -7,4 +9,4 @@ import * as Dtos from './dtos';
 | 
			
		||||
import * as GlobalEnum from './global-enum';
 | 
			
		||||
import * as Patients from './patients';
 | 
			
		||||
import * as Volo from './volo';
 | 
			
		||||
export { Appointments, Departments, Doctors, Documents, Dto, Dtos, GlobalEnum, Patients, Volo };
 | 
			
		||||
export { Abp, Appoinments, Appointments, Departments, Doctors, Documents, Dto, Dtos, GlobalEnum, Patients, Volo };
 | 
			
		||||
 | 
			
		||||
@ -1,38 +1,6 @@
 | 
			
		||||
import type { Gender } from '../../global-enum/gender.enum';
 | 
			
		||||
import type { Status } from '../../global-enum/status.enum';
 | 
			
		||||
 | 
			
		||||
export interface CreateUpdatePatientDto {
 | 
			
		||||
  id?: string;
 | 
			
		||||
  name?: string;
 | 
			
		||||
  gender: Gender;
 | 
			
		||||
  mobile?: string;
 | 
			
		||||
  email?: string;
 | 
			
		||||
  age: number;
 | 
			
		||||
  treatment?: string;
 | 
			
		||||
  doctorAssigned?: string;
 | 
			
		||||
  address?: string;
 | 
			
		||||
  bloodGroup?: string;
 | 
			
		||||
  admissionDate?: string;
 | 
			
		||||
  dischargeDate?: string;
 | 
			
		||||
  status: Status;
 | 
			
		||||
  imageID?: string;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export interface CreateUpdatePatientRecordDto {
 | 
			
		||||
  id?: string;
 | 
			
		||||
  patientId?: string;
 | 
			
		||||
  dateOfAdmission?: string;
 | 
			
		||||
  labReportUrlID?: string;
 | 
			
		||||
  medicationUrlID?: string;
 | 
			
		||||
  medicationHistoryUrlID?: string;
 | 
			
		||||
  nextFollowUp?: string;
 | 
			
		||||
  diagnosis?: string;
 | 
			
		||||
  treatmentPlan?: string;
 | 
			
		||||
  doctorNotes?: string;
 | 
			
		||||
  insuranceProvider?: string;
 | 
			
		||||
  status: Status;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export interface PatientDto {
 | 
			
		||||
  id?: string;
 | 
			
		||||
  name?: string;
 | 
			
		||||
@ -65,3 +33,35 @@ export interface PatientRecordDto {
 | 
			
		||||
  insuranceProvider?: string;
 | 
			
		||||
  status: Status;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export interface CreateUpdatePatientDto {
 | 
			
		||||
  id?: string;
 | 
			
		||||
  name?: string;
 | 
			
		||||
  gender: Gender;
 | 
			
		||||
  mobile?: string;
 | 
			
		||||
  email?: string;
 | 
			
		||||
  age: number;
 | 
			
		||||
  treatment?: string;
 | 
			
		||||
  doctorAssigned?: string;
 | 
			
		||||
  address?: string;
 | 
			
		||||
  bloodGroup?: string;
 | 
			
		||||
  admissionDate?: string;
 | 
			
		||||
  dischargeDate?: string;
 | 
			
		||||
  status: Status;
 | 
			
		||||
  imageID?: string;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
export interface CreateUpdatePatientRecordDto {
 | 
			
		||||
  id?: string;
 | 
			
		||||
  patientId?: string;
 | 
			
		||||
  dateOfAdmission?: string;
 | 
			
		||||
  labReportUrlID?: string;
 | 
			
		||||
  medicationUrlID?: string;
 | 
			
		||||
  medicationHistoryUrlID?: string;
 | 
			
		||||
  nextFollowUp?: string;
 | 
			
		||||
  diagnosis?: string;
 | 
			
		||||
  treatmentPlan?: string;
 | 
			
		||||
  doctorNotes?: string;
 | 
			
		||||
  insuranceProvider?: string;
 | 
			
		||||
  status: Status;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -4,7 +4,7 @@ import { RestService, Rest } from '@abp/ng.core';
 | 
			
		||||
import type { PagedResultDto } from '@abp/ng.core';
 | 
			
		||||
import { Injectable } from '@angular/core';
 | 
			
		||||
import type { EntityDocument } from '../documents/models';
 | 
			
		||||
import type { DropDownItems, FileDownloadDto, PagingSortPatientResultDto } from '../dto/models';
 | 
			
		||||
import type { DropDownItems, FileDownloadDto, PagingSortResultDto } from '../dto/models';
 | 
			
		||||
 | 
			
		||||
@Injectable({
 | 
			
		||||
  providedIn: 'root',
 | 
			
		||||
@ -71,7 +71,7 @@ export class PatientService {
 | 
			
		||||
    { apiName: this.apiName,...config });
 | 
			
		||||
  
 | 
			
		||||
 | 
			
		||||
  getPatientList = (input: PagingSortPatientResultDto, config?: Partial<Rest.Config>) =>
 | 
			
		||||
  getPatientList = (input: PagingSortResultDto, config?: Partial<Rest.Config>) =>
 | 
			
		||||
    this.restService.request<any, PagedResultDto<PatientDto>>({
 | 
			
		||||
      method: 'GET',
 | 
			
		||||
      url: '/api/app/patient/patient-list',
 | 
			
		||||
@ -88,7 +88,7 @@ export class PatientService {
 | 
			
		||||
    { apiName: this.apiName,...config });
 | 
			
		||||
  
 | 
			
		||||
 | 
			
		||||
  getPatientRecordList = (input: PagingSortPatientResultDto, Id: string, config?: Partial<Rest.Config>) =>
 | 
			
		||||
  getPatientRecordList = (input: PagingSortResultDto, Id: string, config?: Partial<Rest.Config>) =>
 | 
			
		||||
    this.restService.request<any, PagedResultDto<PatientRecordDto>>({
 | 
			
		||||
      method: 'GET',
 | 
			
		||||
      url: `/api/app/patient/patient-record-list/${Id}`,
 | 
			
		||||
 | 
			
		||||
@ -39,13 +39,12 @@ namespace HospitalManagementSystem.Appointments
 | 
			
		||||
            return _currentUser.Name + " checking done.";
 | 
			
		||||
        }
 | 
			
		||||
        #region Get Patient List with Paging and Searching
 | 
			
		||||
        public async Task<PagedResultDto<AppointmentDto>> GetAppointmentListAsync(PagingSortResultDto input, Guid Id)
 | 
			
		||||
        public async Task<PagedResultDto<AppointmentDto>> GetAppointmentListAsync(PagingSortResultDto input)
 | 
			
		||||
        {
 | 
			
		||||
            var queryable = await _appointmentsRepository.GetQueryableAsync();
 | 
			
		||||
 | 
			
		||||
            var filteredQuery = queryable
 | 
			
		||||
                .WhereIf(!string.IsNullOrEmpty(input.Search), x => x.FirstName.ToLower().Contains(input.Search.ToLower()) || x.LastName.ToLower().Contains(input.Search.ToLower()))
 | 
			
		||||
                .Where(x => x.Id == Id);
 | 
			
		||||
                .WhereIf(!string.IsNullOrEmpty(input.Search), x => x.FirstName.ToLower().Contains(input.Search.ToLower()) || x.LastName.ToLower().Contains(input.Search.ToLower()));
 | 
			
		||||
 | 
			
		||||
            var totalCount = await filteredQuery.CountAsync();
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user