0.2.1 • Published 8 years ago

@mycure/vu-doctor v0.2.1

Weekly downloads
1
License
ISC
Repository
-
Last release
8 years ago

js-semistandard-style

MYCURE Vue Doctor module

Installation and Usage

$ yarn add @mycure/vu-doctor
  • use as a vue plugin
import Vue from 'vue';
import { firebaseApp } from './firebase';
import McDoctor from '@mycure/vu-doctor';

Vue.use(McDoctor, { firebaseApp })
  • above will do the ff:
    • describe side effects here
    • sample side effects:
      • attach a global method/attribute
      • attach an instance method/attribute
      • add components
// create sample use here

API

getWebsiteDetailsOfDoctorWithURL(url: string): Promise<DoctorWebsite>
getWebsiteDetailsOfDoctorWithUid(uid: string): Promise<DoctorWebsite>
searchDoctor(searchString: string): Observable<Doctor[]>

Model

Common

interface Country {
  alpha2: string;
  name: string;
}

interface Address {
  lat: number;
  lng: number;
  country: Country;
}

Doctor

enum Sex {
  male
  female
}

enum Practitioner {
  physician
}

interface Name {
  firstName: string;
  middleName: string;
  lastName: string;
  suffix: string;
  title: string;
}

interface Profession {
  description: string;
  suffix: string;
}

interface Education {
  degree: string;
  school: string;
  from: string;
  to: string;
}

interface Doctor {
  uid: string;
  sex: Sex;
  PTRNumber: string;
  email: string;
  thumbURL: string;
  picURL: string;
  name: Name;
  HMO: string[];
  affiliations: string[];
  PRCLicence: string;
  practicingSince: string;
  practitionerType: Practitioner;
  professions: Profession[];
  specializations: string[];
  education: Education[];
  facilities: Facility[];
}

interface DoctorWebsite extends Doctor {
  bg: string;
  shortDescription: string;
  url: string;
  bio: string;
}

Facility

interface FacilitySocialMedia {
  facebook: string;
  linkedin: string;
  twitter: string;
}

interface FacilityContact {
  email: string[];
  phone: string[];
  socialMedia: FacilitySocialMedia;
}

interface FacilitySchedule {
  day: string; // day of the week
  close: timestamp;
  open: timestamp;
}

interface Facility {
  coverPicURL: string;
  picURL: string;
  description: string;
  name: string;
  address: Address;
  contacts: FacilityContact;
  schedules: FacilitySchedule[];
}
0.2.1

8 years ago

0.2.0

8 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago