Files
FE_CPONE/test/vuex/one-test-physic/components/oneTestPhysicForm.vue
2026-04-27 10:13:31 +07:00

1708 lines
97 KiB
Vue

<template>
<div>
<v-dialog v-model="xdialogaction" persistent max-width="350">
<v-card>
<v-card-title color="warning" class="headline">Konfirmasi</v-card-title>
<v-card-text v-html="xmsgaction">
</v-card-text>
<v-card-actions>
<v-spacer></v-spacer>
<v-btn color="primary darken-1" flat @click="closeDialogAction()">Ya</v-btn>
<v-btn color="error darken-1" flat @click="xdialogaction = false">Tutup</v-btn>
</v-card-actions>
</v-card>
</v-dialog>
<v-layout row mb-2 wrap>
<v-flex xs12 pr-1>
<v-card >
<v-layout align-center fill-height pt-1 pb-1 row>
<v-flex pt-1 pb-1 pl-2 pr-2 xs6>
<h5 v-if="status === 'NEW'" class="headline font-weight-black"><v-icon color="black" large left>accessibility</v-icon>PEMERIKSAAN FISIK</h5>
<h5 v-if="status === 'VER'" class="headline warning--text font-weight-bold"><v-icon color="warning" large left>accessibility</v-icon>PEMERIKSAAN FISIK</h5>
<h5 v-if="status === 'VAL'" class="headline success--text font-weight-bold"><v-icon color="success" large left>accessibility</v-icon>PEMERIKSAAN FISIK</h5>
</v-flex>
<v-flex class="text-xs-right" pt-1 pb-1 pl-2 pr-2 xs6>
<v-btn dark @click="save('ver')" tile v-if="status === 'NEW'" color="warning" :disabled="save_status === 1" >VERIFIKASI</v-btn>
<v-btn dark @click="save('unver')" tile v-if="status === 'VER'" color="warning" :disabled="save_status === 1" outline >BATAL VERIFIKASI</v-btn>
<v-btn dark @click="save('val')" tile v-if="status === 'VER'" color="success" :disabled="save_status === 1" >VALIDASI</v-btn>
<v-btn dark @click="save('unval')" tile v-if="status === 'VAL'" color="success" :disabled="save_status === 1" outline >BATAL VALIDASI</v-btn>
<v-btn dark @click="save('save')" :disabled="save_status === 1" tile v-if="status === 'NEW'" color="info" >SIMPAN</v-btn>
</v-flex>
</v-layout>
<v-divider></v-divider>
<v-layout style="background:#90caf9" justify-center row>
<v-flex xs3 pr-3 pt-3 pb-3 shrink>
<v-card class="pa-2 right" width="200">
<v-img
height="200"
width="100%"
src="https://anggrek.aplikasi.web.id/one-media/one-image-nonlab/L-190723002-3-GsNkx.jpeg"
></v-img>
</v-card>
</v-flex>
<v-flex pt-3 pr-3 pb-3 xs8>
<v-card
class="mx-auto"
flat
>
<v-layout pl-2 pr-2 row>
<v-flex xs5>
<v-text-field
single-line
hide-details
readonly
value="NO LAB"
></v-text-field>
</v-flex>
<v-flex justify-right xs7>
<v-text-field
single-line
hide-details
readonly
v-model="patient.ordernumber"
></v-text-field>
</v-flex>
</v-layout>
<v-layout pl-2 pr-2 row>
<v-flex xs5>
<v-text-field
single-line
readonly
hide-details
value="NAMA"
></v-text-field>
</v-flex>
<v-flex justify-right xs7>
<v-text-field
single-line
hide-details
readonly
v-model="patient.patient_fullname"
></v-text-field>
</v-flex>
</v-layout>
<v-layout pl-2 pr-2 row>
<v-flex xs5>
<v-text-field
single-line
hide-details
readonly
value="UMUR"
></v-text-field>
</v-flex>
<v-flex justify-right xs7>
<v-text-field
single-line
hide-details
readonly
v-model="patient.umur"
></v-text-field>
</v-flex>
</v-layout>
<v-layout pl-2 pr-2 row>
<v-flex xs5>
<v-text-field
single-line
hide-details
readonly
value="JENIS KELAMIN"
></v-text-field>
</v-flex>
<v-flex justify-right xs7>
<v-text-field
single-line
hide-details
readonly
v-model="patient.sexname"
></v-text-field>
</v-flex>
</v-layout>
<v-layout pr-2 pl-2 row>
<v-flex xs5>
<v-text-field
single-line
hide-details
readonly
value="INSTANSI"
></v-text-field>
</v-flex>
<v-flex justify-right xs7>
<v-text-field
single-line
hide-details
readonly
v-model="patient.companyname"
></v-text-field>
</v-flex>
</v-layout>
<v-layout pr-2 pl-2 row>
<v-flex xs5>
<v-text-field
single-line
hide-details
value="ALAMAT"
></v-text-field>
</v-flex>
<v-flex justify-right xs7>
<v-text-field
single-line
hide-details
readonly
v-model="patient.companyaddress"
></v-text-field>
</v-flex>
</v-layout>
<v-layout pr-2 pl-2 pb-4 row>
<v-flex xs5>
<v-text-field
single-line
hide-details
readonly
value="TANGGAL PEMERIKSAAN"
></v-text-field>
</v-flex>
<v-flex justify-right xs7>
<v-text-field
single-line
hide-details
readonly
v-model="patient.orderdate"
></v-text-field>
</v-flex>
</v-layout>
</v-card>
</v-flex>
</v-layout>
<v-layout row>
<v-flex d-flex><v-divider></v-divider></v-flex>
</v-layout>
<v-layout row>
<v-flex d-flex>
<v-btn @click="changeTab()" v-if="tabnow === 'pasien'" depressed class="depressed" dark color="#f44336">PANEL PASIEN</v-btn>
<v-btn @click="changeTab()" v-if="tabnow === 'doctor'" flat style="background:#ff000026" color="red">PANEL PASIEN</v-btn>
<v-btn @click="changeTab()" v-if="tabnow === 'pasien'" flat style="background:#ff980029" color="orange">PANEL DOKTER</v-btn>
<v-btn @click="changeTab()" v-if="tabnow === 'doctor'" depressed dark color="orange">PANEL DOKTER</v-btn>
</v-flex>
</v-layout>
<v-layout row>
<v-flex d-flex><v-divider></v-divider></v-flex>
</v-layout>
<div v-if="tabnow === 'pasien'">
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#f44336;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>KELUHAN SAAT INI</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout align-space-around row>
<v-flex pl-2 pt-3 pb-3 pr-2 shrink xs12>
<v-textarea
outline
hide-details
single-line
:readonly="status !== 'NEW'"
v-model="xdetails.complaint"
@change="changeValueComplaint(xdetails.complaint)"
label="Isi keluhan di sini"
></v-textarea>
</v-flex>
</v-layout>
<v-layout row>
<v-flex d-flex><v-divider></v-divider></v-flex>
</v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#f44336;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>RIWAYAT BAHAYA LINGKUNGAN KERJA</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout v-for="(workplacehazards,index) in xdetails.workplacehazards" row>
<v-layout style="background:#503c3ae8;color:#fff;font-size:20px;border-bottom: 1px solid #fff" pt-2 pb-2 align-center row>
<v-flex xs1 class="text-xs-center">
<v-icon dark>assignment</v-icon>
</v-flex>
<v-flex xs5>
<h5 class="mono">{{workplacehazards.label}}</h5>
</v-flex>
<v-flex xs5>
<h5 dark class="mono">:
<input :readonly="status !== 'NEW'"
@change="changeWorkPlaceHazardsValHour(workplacehazards,index)"
v-model="workplacehazards.val_hour"
class="white-placeholder input-custom-mini"
placeholder="...." type="text"/> jam/hari,
selama
<input :readonly="status !== 'NEW'"
@change="changeWorkPlaceHazardsValHour(workplacehazards,index)"
v-model="workplacehazards.val_year"
class="white-placeholder input-custom-mini"
placeholder="...."
type="text"/> tahun</h5>
</v-flex>
</v-layout>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#f44336;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>RIWAYAT KECELAKAAN KERJA</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th width="40%" class="text-xs-left">Jenis Kecelakaan</th>
<th width="10%" class="text-xs-center">Tahun</th>
<th width="40%" class="text-xs-left">Jenis Kecelakaan</th>
<th width="10%" class="text-xs-center">Tahun</th>
</tr>
<tr v-for="(workplaceaccident,index) in xdetails.workplaceaccident">
<td>{{workplaceaccident[0].label}}</td>
<td style="vertical-align:middle">
<v-text-field
style="padding:0px;margin-top:0px"
hide-details
single-line
:readonly="status !== 'NEW'"
@change="changeWorkPlaceAccidentValue(workplaceaccident,index,0)"
v-model="workplaceaccident[0].value"
></v-text-field>
</td>
<td>{{workplaceaccident[1].label}}</td>
<td style="vertical-align:middle">
<v-text-field
style="padding:0px;margin-top:0px"
hide-details
single-line
:readonly="status !== 'NEW'"
@change="changeWorkPlaceAccidentValue(workplaceaccident,index,1)"
v-model="workplaceaccident[1].value"
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#f44336;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>RIWAYAT KESEHATAN</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout pt-2 pb-2 align-center row>
<v-flex pt-1 pb-1 style="background:#f44336;color:#fff" xs12>
<h3 class="title text-xs-center">PERNAHKAH ATAU ANDA SEDANG MENDERITA PENYAKIT DI BAWAH INI ?</h3>
</v-flex>
</v-layout>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th width="35%" class="text-xs-center">Keluhan / Penyakit</th>
<th width="9%" class="text-xs-center">Ya</th>
<th width="9%" class="text-xs-center">Tidak</th>
<th class="text-xs-center">Keterangan</th>
<th width="35%" class="text-xs-center">Keluhan / Penyakit</th>
<th width="9%" class="text-xs-center">Ya</th>
<th width="9%" class="text-xs-center">Tidak</th>
<th class="text-xs-center">Keterangan</th>
</tr>
<tr v-for="(medicalhistory,index) in xdetails.medicalhistory">
<td>{{medicalhistory[0].label}}</td>
<td>
<v-btn @click="changeCheckYMedicalHistory(medicalhistory,index,0)" v-if="medicalhistory[0].cbxY === 'N'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckYMedicalHistory(medicalhistory,index,0)" v-if="medicalhistory[0].cbxY === 'Y'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td>
<v-btn @click="changeCheckTMedicalHistory(medicalhistory,index,0)" v-if="medicalhistory[0].cbxT === 'N'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckTMedicalHistory(medicalhistory,index,0)" v-if="medicalhistory[0].cbxT === 'Y'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="medicalhistory[0].cbxT === 'N'"
style="padding:0px;margin-top:0px"
hide-details
single-line
:readonly="status !== 'NEW'"
@change="changeMedicalHistoryValue(medicalhistory,index,0)"
v-model="medicalhistory[0].value"
></v-text-field>
</td>
<td>{{medicalhistory[1].label}}</td>
<td>
<v-btn @click="changeCheckYMedicalHistory(medicalhistory,index,1)" v-if="medicalhistory[1].cbxY === 'N'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckYMedicalHistory(medicalhistory,index,1)" v-if="medicalhistory[1].cbxY === 'Y'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td>
<v-btn @click="changeCheckTMedicalHistory(medicalhistory,index,1)" v-if="medicalhistory[1].cbxT === 'N'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckTMedicalHistory(medicalhistory,index,1)" v-if="medicalhistory[1].cbxT === 'Y'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="medicalhistory[1].cbxT === 'N'"
style="padding:0px;margin-top:0px"
hide-details
single-line
:readonly="status !== 'NEW'"
@change="changeMedicalHistoryValue(medicalhistory,index,1)"
v-model="medicalhistory[1].value"
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#f44336;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>RIWAYAT ALERGI</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th width="35%" class="text-xs-center">Penyebab Alergi</th>
<th class="text-xs-center">Ya</th>
<th class="text-xs-center">Tidak</th>
<th class="text-xs-center">Bila Ya, Sebutkan</th>
</tr>
<tr v-for="(allergy,index) in xdetails.allergy ">
<td>{{allergy.label}}</td>
<td class="text-xs-center">
<v-btn @click="changeCheckAllergy(allergy,index)" v-if="allergy.cbx === 'N'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckAllergy(allergy,index)" v-if="allergy.cbx === 'Y'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td class="text-xs-center">
<v-btn @click="changeCheckAllergy(allergy,index)" v-if="allergy.cbx === 'Y'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckAllergy(allergy,index)" v-if="allergy.cbx === 'N'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="allergy.cbx === 'Y'"
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
@change="changeValueAllergy(allergy,index)"
v-model="allergy.value"
single-line
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#f44336;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>RIWAYAT KONSUMSI OBAT TERATUR</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th width="35%" class="text-xs-center">Jenis obat-obatan</th>
<th width="15%" class="text-xs-center">Dosis</th>
<th class="text-xs-center">Lama konsumsi obat</th>
</tr>
<tr v-for="(drugconsumption,index) in xdetails.drugconsumption">
<td>{{drugconsumption.label}}</td>
<td style="vertical-align:middle">
<v-text-field
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
@change="changeDoseDrugConsumption(drugconsumption,index)"
v-model="drugconsumption.dose"
single-line
></v-text-field>
</td>
<td style="vertical-align:middle">
<v-text-field
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
@change="changeValueDrugConsumption(drugconsumption,index)"
v-model="drugconsumption.value"
single-line
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#f44336;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>GAYA HIDUP</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th width="35%" class="text-xs-center">Jenis / Kebiasaan</th>
<th class="text-xs-center">Ya</th>
<th class="text-xs-center">Tidak</th>
<th class="text-xs-center">Jumlah</th>
</tr>
<tr v-for="(lifestyle, index) in xdetails.lifestyle">
<td>{{lifestyle.label}}</td>
<td class="text-xs-center">
<v-btn @click="changeCheckLifestyle(lifestyle,index)" v-if="lifestyle.cbx === 'N'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckLifestyle(lifestyle,index)" v-if="lifestyle.cbx === 'Y'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td class="text-xs-center">
<v-btn @click="changeCheckLifestyle(lifestyle,index)" v-if="lifestyle.cbx === 'Y'" flat style="min-width:45px;margin:0" dark color="red">
<v-icon>close</v-icon>
</v-btn>
<v-btn @click="changeCheckLifestyle(lifestyle,index)" v-if="lifestyle.cbx === 'N'" flat style="min-width:45px;margin:0" dark color="info">
<v-icon>check</v-icon>
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="lifestyle.cbx === 'Y'"
:readonly="status !== 'NEW'"
style="padding:0px;margin-top:0px"
hide-details
v-model="lifestyle.value"
@change="changeValueLifestyle(lifestyle,index)"
single-line
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
</div>
<div v-if="tabnow === 'doctor'">
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>TANDA - TANDA VITAL</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr v-for="(vitalsign,index) in xdetails.vitalsign ">
<td width="20%">{{vitalsign[0].label}}</td>
<td width="34%" style="vertical-align:middle">
<v-text-field
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
@change="changeValueVitalSign(vitalsign,index,0)"
v-model="vitalsign[0].value"
single-line
></v-text-field>
</td>
<td width="20%">{{vitalsign[1].label}}</td>
<td width="13%">
<v-btn flat @click="changeCheck1VitalSign(vitalsign,index,0)" v-if="vitalsign[1].cbx1 === 'N'" style="min-width:45px;margin:0" dark color="red">
<v-icon left>close</v-icon> {{vitalsign[1].labelcbx1}}
</v-btn>
<v-btn flat @click="changeCheck1VitalSign(vitalsign,index,0)" v-if="vitalsign[1].cbx1 === 'Y'" style="min-width:45px;margin:0" dark color="info">
<v-icon left>check</v-icon> {{vitalsign[1].labelcbx1}}
</v-btn>
</td>
<td width="13%">
<v-btn flat @click="changeCheck2VitalSign(vitalsign,index,1)" v-if="vitalsign[1].cbx2 === 'N'" style="min-width:45px;margin:0" dark color="red">
<v-icon left>close</v-icon> {{vitalsign[1].labelcbx2}}
</v-btn>
<v-btn flat @click="changeCheck2VitalSign(vitalsign,index,1)" v-if="vitalsign[1].cbx2 === 'Y'" style="min-width:45px;margin:0" dark color="info">
<v-icon left>check</v-icon> {{vitalsign[1].labelcbx2}}
</v-btn>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>KEADAAN UMUM</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th class="text-xs-center" width="30%">Keadaan Umum</th>
<th colspan="3" width="70%" class="text-xs-center" style="vertical-align:middle">
Keterangan
</th>
</tr>
<tr v-for="(generalcondition,index) in xdetails.generalcondition">
<td width="30%">{{generalcondition.label}}</td>
<td class="text-xs-center">
<v-btn @click="changeCheckYGeneralCondition(generalcondition,index)"
v-if="generalcondition.cbxY === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> NORMAL
</v-btn>
<v-btn @click="changeCheckYGeneralCondition(generalcondition,index)"
v-if="generalcondition.cbxY === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> NORMAL
</v-btn>
</td>
<td class="text-xs-center">
<v-btn @click="changeCheckTGeneralCondition(generalcondition,index)"
v-if="generalcondition.cbxT === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> TIDAK
</v-btn>
<v-btn @click="changeCheckTGeneralCondition(generalcondition,index)"
v-if="generalcondition.cbxT === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> TIDAK
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="generalcondition.cbxT === 'Y'"
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
v-model="generalcondition.value"
@change="changeValueGeneralCondition(generalcondition,index)"
single-line
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>MATA</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th class="text-xs-center" width="30%">Mata</th>
<th colspan="3" class="text-xs-center" style="vertical-align:middle">
Keterangan
</th>
</tr>
<tr v-for="(eyes,index) in xdetails.eyes">
<td width="30%">{{eyes.label}}</td>
<td width="15%">
<v-btn @click="changeCheckNEyes(eyes,index)"
v-if="eyes.cbxN === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> NORMAL
</v-btn>
<v-btn @click="changeCheckNEyes(eyes,index)"
v-if="eyes.cbxN === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> NORMAL
</v-btn>
</td>
<td width="15%">
<v-btn @click="changeCheckTEyes(eyes,index)"
v-if="eyes.cbxT === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> TIDAK
</v-btn>
<v-btn @click="changeCheckTEyes(eyes,index)"
v-if="eyes.cbxT === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> TIDAK
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="eyes.cbxT === 'Y'"
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
v-model="eyes.value"
@change="changeValueEyes(eyes,index)"
single-line
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>GIGI</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table>
<tr>
<th colspan="18">Gigi Geligi</th>
</tr>
<tr class="bggrey">
<th></th>
<th class="text-xs-center"colspan="8">GIGI KIRI</th>
<th class="text-xs-center"colspan="8">GIGI KANAN</th>
<th></th>
</tr>
<tr>
<th>KODE</th>
<th v-for="(tooth,index) in xdetails.tooth" v-if="tooth.xorder === 0 || tooth.xorder === '0'" class="thgigi">
<input
@change="changeValueTooth(tooth,index)"
v-model="tooth.value"
:readonly="status !== 'NEW'"
v-bind:class="{'background-black':tooth.value.toUpperCase() === 'X','background-teal':tooth.value.toUpperCase() === 'C','background-brown':tooth.value.toUpperCase() === 'R','background-red':tooth.value.toUpperCase() === 'O','background-yellow-accent-4':tooth.value.toUpperCase() === 'A'}"
type="text" class="input_gigi"/>
</th>
<th>KODE</th>
</tr>
<tr class="bggrey">
<th>ATAS</th>
<th class="thgigi">
8
</th>
<th class="thgigi">
7
</th>
<th class="thgigi">
6
</th>
<th class="thgigi">
5
</th>
<th class="thgigi">
4
</th>
<th class="thgigi">
3
</th>
<th class="thgigi">
2
</th>
<th class="thgigi">
1
</th>
<th class="thgigi">
1
</th>
<th class="thgigi">
2
</th>
<th class="thgigi">
3
</th>
<th class="thgigi">
4
</th>
<th class="thgigi">
5
</th>
<th class="thgigi">
6
</th>
<th class="thgigi">
7
</th>
<th class="thgigi">
8
</th>
<th>ATAS</th>
</tr>
<tr class="bggrey">
<th>BAWAH</th>
<th class="thgigi">
8
</th>
<th class="thgigi">
7
</th>
<th class="thgigi">
6
</th>
<th class="thgigi">
5
</th>
<th class="thgigi">
4
</th>
<th class="thgigi">
3
</th>
<th class="thgigi">
2
</th>
<th class="thgigi">
1
</th>
<th class="thgigi">
1
</th>
<th class="thgigi">
2
</th>
<th class="thgigi">
3
</th>
<th class="thgigi">
4
</th>
<th class="thgigi">
5
</th>
<th class="thgigi">
6
</th>
<th class="thgigi">
7
</th>
<th class="thgigi">
8
</th>
<th>BAWAH</th>
</tr>
<tr>
<th>KODE</th>
<th v-for="(tooth,index) in xdetails.tooth" v-if="tooth.xorder === 1 || tooth.xorder === '1'" class="thgigi">
<input
@change="changeValueTooth(tooth,index)"
v-model="tooth.value"
:readonly="status !== 'NEW'"
v-bind:class="{'background-black':tooth.value.toUpperCase() === 'X','background-teal':tooth.value.toUpperCase() === 'C','background-brown':tooth.value.toUpperCase() === 'R','background-red':tooth.value.toUpperCase() === 'O','background-yellow-accent-4':tooth.value.toUpperCase() === 'A'}"
type="text" class="input_gigi"/>
</th>
<th>KODE</th>
</tr>
<tr class="bggrey">
<th></th>
<th class="text-xs-center"colspan="8">GIGI KIRI</th>
<th class="text-xs-center"colspan="8">GIGI KANAN</th>
<th></th>
</tr>
</table>
</v-flex>
</v-layout>
<v-layout align-center pt-4 pl-3 row>
<v-flex d-flex><h3>KETERANGAN KODE :</h3></v-flex>
</v-layout>
<v-layout align-center pt-3 pl-3 pb-3 row>
<v-flex xs2>
<v-layout align-center row>
<v-flex xs4>
<v-btn small style="min-width:45px;margin:0" dark color="black">
X
</v-btn>
</v-flex>
<v-flex xs8>
<h5>: BERLUBANG</h5>
</v-flex>
</v-flex>
<v-flex xs2>
<v-layout align-center row>
<v-flex xs4>
<v-btn small style="min-width:45px;margin:0" dark color="teal">
C
</v-btn>
</v-flex>
<v-flex xs8>
<h5>: TAMBALAN</h5>
</v-flex>
</v-flex>
<v-flex xs2>
<v-layout align-center row>
<v-flex xs4>
<v-btn small style="min-width:45px;margin:0" dark color="red">
O
</v-btn>
</v-flex>
<v-flex xs8>
<h5>: TANGGAL</h5>
</v-flex>
</v-flex>
<v-flex xs2>
<v-layout align-center row>
<v-flex xs4>
<v-btn small style="min-width:45px;margin:0" dark color="brown">
R
</v-btn>
</v-flex>
<v-flex xs8>
<h5>: SISA AKAR</h5>
</v-flex>
</v-flex>
<v-flex xs2>
<v-layout align-center row>
<v-flex xs4>
<v-btn small style="min-width:45px;margin:0" dark color="yellow accent-4">
A
</v-btn>
</v-flex>
<v-flex xs8>
<h5>: GIGI PALSU</h5>
</v-flex>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>THT</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th class="text-xs-center" width="30%">THT</th>
<th colspan="3" class="text-xs-center" style="vertical-align:middle">
Keterangan
</th>
</tr>
<tr v-for="(tht,index) in xdetails.tht">
<td width="30%">{{tht.label}}</td>
<td width="15%">
<v-btn @click="changeCheckNTHT(tht,index)"
v-if="tht.cbxN === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> NORMAL
</v-btn>
<v-btn @click="changeCheckNTHT(tht,index)"
v-if="tht.cbxN === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> NORMAL
</v-btn>
</td>
<td width="15%">
<v-btn @click="changeCheckNTHT(tht,index)"
v-if="tht.cbxT === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> TIDAK
</v-btn>
<v-btn @click="changeCheckNTHT(tht,index)"
v-if="tht.cbxT === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> TIDAK
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="tht.cbxT === 'Y'"
style="padding:0px;margin-top:0px"
hide-details
single-line
:readonly="status !== 'NEW'"
v-model="tht.value"
@change="changeValueTHT(tht,index)"
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>DADA DAN PERUT</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th class="text-xs-center" width="30%">Dada dan Perut</th>
<th colspan="3" class="text-xs-center" style="vertical-align:middle">
Keterangan
</th>
</tr>
<tr v-for="(ca,index) in xdetails.chestabdomen">
<td width="30%">{{ca.label}}</td>
<td width="15%">
<v-btn @click="changeCheckNCA(ca,index)"
v-if="ca.cbxN === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> NORMAL
</v-btn>
<v-btn @click="changeCheckNCA(ca,index)"
v-if="ca.cbxN === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> NORMAL
</v-btn>
</td>
<td width="15%">
<v-btn @click="changeCheckTCA(ca,index)"
v-if="ca.cbxT === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> TIDAK
</v-btn>
<v-btn @click="changeCheckTCA(ca,index)"
v-if="ca.cbxT === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> TIDAK
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="ca.cbxT === 'Y'"
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
v-model="ca.value"
@change="changeValueCA(ca,index)"
single-line
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>SISTEM PERSYARAFAN</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout wrap>
<v-flex pl-2 pt-2 pb-2 pr-2 shrink xs12>
<v-layout row>
<v-flex xs12>
<table class="tform">
<tr>
<th class="text-xs-center" width="30%">Sistem Persyafan</th>
<th colspan="3" class="text-xs-center" style="vertical-align:middle">
Keterangan
</th>
</tr>
<tr v-for="(nerve,index) in xdetails.nerve">
<td width="30%">{{nerve.label}}</td>
<td width="15%">
<v-btn @click="changeCheckNNerve(nerve,index)"
v-if="nerve.cbxN === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> NORMAL
</v-btn>
<v-btn @click="changeCheckNNerve(nerve,index)"
v-if="nerve.cbxN === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> NORMAL
</v-btn>
</td>
<td width="15%">
<v-btn @click="changeCheckNNerve(nerve,index)"
v-if="nerve.cbxT === 'N'" flat style="min-width:45px;margin:0" dark
color="red">
<v-icon left>close</v-icon> TIDAK
</v-btn>
<v-btn @click="changeCheckNNerve(nerve,index)"
v-if="nerve.cbxT === 'Y'" flat style="min-width:45px;margin:0" dark
color="info">
<v-icon left>check</v-icon> TIDAK
</v-btn>
</td>
<td style="vertical-align:middle">
<v-text-field
v-if="nerve.cbxT === 'Y'"
style="padding:0px;margin-top:0px"
hide-details
:readonly="status !== 'NEW'"
v-model="nerve.value"
@change="changeValueNerve(nerve,index)"
single-line
></v-text-field>
</td>
</tr>
</table>
</v-flex>
</v-layout>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>KESIMPULAN FISIK</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout align-space-around row>
<v-flex pl-2 pt-3 pb-3 pr-2 shrink xs12>
<v-textarea
outline
:readonly="status !== 'NEW'"
hide-details
single-line
label="Isi kesimpulan di sini"
v-model="xdetails.conslusion"
@change="changeValueConclusion(xdetails.conslusion)"
></v-textarea>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout pt-2 pb-1 align-center row>
<v-flex style="background:#ff9800;" pl-2 pt-2 pb-2 shrink xs1>
</v-flex>
<v-flex pl-2 pt-2 pb-2 xs4>
<h4>SARAN FISIK</h4>
</v-flex>
</v-layout>
<v-layout align-center row><v-divider></v-divider></v-layout>
<v-layout align-space-around row>
<v-flex pl-2 pt-3 pb-3 pr-2 shrink xs12>
<v-textarea
outline
:readonly="status !== 'NEW'"
hide-details
single-line
label="Isi saran di sini"
@change="changeValueSuggestion(xdetails.suggestion)"
v-model="xdetails.suggestion"
></v-textarea>
</v-flex>
</v-layout>
</div>
</v-card>
</v-flex>
</v-layout>
</div>
</template>
<style scoped>
.white-placeholder::placeholder { /* Most modern browsers support this now. */
color: #fff;
}
table {
width:100%;
}
table, td, th {
border: 1px solid black;
border-collapse: collapse;
}
th, td {
padding-left: 15px;
padding-right: 15px;
padding-top: 10px;
padding-bottom: 10px;
text-align: left;
}
table.tform tr:nth-child(even) {
background-color: #eee;
}
table.tform tr:nth-child(odd) {
background-color: #fff;
}
.thgigi{
width:50px!important;
padding:5px!important;
text-align:center;
}
.input_gigi{
width:100%;
border:1px solid grey;
font-size:14px;
text-align:center;
line-height: 2;
text-transform: uppercase;
}
.bggrey{
background:#eee!important;
}
.background-black{
background:black;
color:#fff;
}
.background-teal{
background:#009688;
color:#fff;
}
.background-red{
background:#f44336;
color:#fff;
}
.background-brown{
background:#795548;
color:#fff;
}
.background-yellow-accent-4{
background:#ffeb3b;
color:#fff;
}
</style>
<script>
module.exports = {
data: () => ({
labels: ['SU', 'MO', 'TU', 'WED', 'TH', 'FR', 'SA'],
time: 0,
forecast: [
{ day: 'Tuesday', icon: 'mdi-white-balance-sunny', temp: '24\xB0/12\xB0' },
{ day: 'Wednesday', icon: 'mdi-white-balance-sunny', temp: '22\xB0/14\xB0' },
{ day: 'Thursday', icon: 'mdi-cloud', temp: '25\xB0/15\xB0' },
],
}),
computed: {
tabnow:{
get() {
return this.$store.state.physic.tab_now
},
set(val) {
this.$store.commit("physic/update_tab_now",val)
}
},
status(){
if(_.isEmpty(this.$store.state.physic.selected_transaction)){
return 'xxxx'
}
else{
return this.$store.state.physic.selected_transaction.status
}
},
save_status(){
return this.$store.state.physic.save_status
},
xdialogaction:{
get() {
return this.$store.state.physic.dialog_action
},
set(val) {
this.$store.commit("physic/update_dialog_action",val)
}
},
xmsgaction:{
get() {
return this.$store.state.physic.msg_action
},
set(val) {
this.$store.commit("physic/update_msg_action",val)
}
},
xdetails(){
return this.$store.state.physic.details
},
xlangs(){
return this.$store.state.physic.langs
},
patient(){
return this.$store.state.physic.selected_transaction
},
curr_page: {
get() {
return this.$store.state.physic.current_page
},
set(val) {
this.$store.commit("physic/update_current_page",val)
this.$store.dispatch("physic/search",{
startdate:this.$store.state.physic.start_date,
enddate: this.$store.state.physic.end_date,
search:this.$store.state.physic.name_lab,
stationid:this.$store.state.physic.selected_station.id,
current_page:1,
lastid:-1
})
}
},
xtotal_page: {
get() {
return this.$store.state.physic.total_doctor
},
set(val) {
this.$store.commit("physic/update_total_doctor",val)
}
},
},
methods : {
changeWorkPlaceHazardsValHour(workplacehazard,idx){
var nowval = workplacehazard.val_hour
var arr = this.$store.state.physic.details
arr['workplacehazard'][idx].val_hour = nowval
this.$store.commit("physic/update_details",arr)
},
changeWorkPlaceHazardsValYear(workplacehazard,idx){
var nowval = workplacehazard.val_year
var arr = this.$store.state.physic.details
arr['workplacehazard'][idx].val_year = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheckYMedicalHistory(medicalhistory,idx,i){
if(this.status === 'NEW'){
var nowval = medicalhistory[i].cbxY === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['medicalhistory'][idx][i].cbxY = nowval
arr['medicalhistory'][idx][i].cbxT = otherval
if(nowval === 'Y')
arr['medicalhistory'][idx][i].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeCheckTMedicalHistory(medicalhistory,idx,i){
if(this.status === 'NEW'){
var nowval = medicalhistory[i].cbxT === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['medicalhistory'][idx][i].cbxT = nowval
arr['medicalhistory'][idx][i].cbxY = otherval
if(nowval === 'N')
arr['medicalhistory'][idx][i].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeMedicalHistoryValue(medicalhistory,idx,i){
var nowval = medicalhistory[i].value
var arr = this.$store.state.physic.details
arr['medicalhistory'][idx][i].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeWorkPlaceAccidentValue(workplaceaccident,idx,i){
var nowval = workplaceaccident[i].value
var arr = this.$store.state.physic.details
arr['workplaceaccident'][idx][i].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheckAllergy(allergy,idx){
if(this.status === 'NEW'){
var nowval = allergy.cbx === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['allergy'][idx].cbx = nowval
if(nowval === 'Y')
arr['allergy'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeValueAllergy(allergy,idx){
var nowval = allergy.value
var arr = this.$store.state.physic.details
arr['allergy'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeDoseDrugConsumption(drugconsumption,idx){
console.log(idx)
var nowval = drugconsumption.dose
console.log(nowval)
var arr = this.$store.state.physic.details
arr['drugconsumption'][idx].dose = nowval
this.$store.commit("physic/update_details",arr)
},
changeValueDrugConsumption(drugconsumption,idx){
var nowval = drugconsumption.value
var arr = this.$store.state.physic.details
arr['drugconsumption'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheckLifestyle(lifestyle,idx){
if(this.status === 'NEW'){
var nowval = lifestyle.cbx === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['lifestyle'][idx].cbx = nowval
if(nowval === 'N')
arr['lifestyle'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeValueLifestyle(lifestyle,idx){
var nowval = lifestyle.value
var arr = this.$store.state.physic.details
arr['lifestyle'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeValueVitalSign(vitalsign,idx,i){
var nowval = vitalsign[i].value
var arr = this.$store.state.physic.details
arr['vitalsign'][idx][i].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheck1VitalSign(vitalsign,idx,i){
if(this.status === 'NEW'){
var nowval = vitalsign[1].cbx1 === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
console.log(nowval)
console.log(otherval)
var arr = this.$store.state.physic.details
arr['vitalsign'][idx][1].cbx1 = nowval
arr['vitalsign'][idx][1].cbx2 = otherval
this.$store.commit("physic/update_details",arr)
}
},
changeCheck2VitalSign(vitalsign,idx,i){
if(this.status === 'NEW'){
var nowval = vitalsign[1].cbx2 === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['vitalsign'][idx][1].cbx2 = nowval
arr['vitalsign'][idx][1].cbx1 = otherval
this.$store.commit("physic/update_details",arr)
}
},
changeCheckYGeneralCondition(generalcondition,idx){
if(this.status === 'NEW'){
var nowval = generalcondition.cbxY === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['generalcondition'][idx].cbxY = nowval
arr['generalcondition'][idx].cbxT = otherval
if(nowval === 'Y')
arr['generalcondition'][idx][i].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeCheckTGeneralCondition(generalcondition,idx){
if(this.status === 'NEW'){
var nowval = generalcondition.cbxT === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['generalcondition'][idx].cbxT = nowval
arr['generalcondition'][idx].cbxY = otherval
if(nowval === 'N')
arr['generalcondition'][idx][i].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeValueGeneralCondition(generalcondition,idx){
var nowval = generalcondition.value
var arr = this.$store.state.physic.details
arr['generalcondition'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheckNEyes(eyes,idx){
if(this.status === 'NEW'){
var nowval = eyes.cbxN === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['eyes'][idx].cbxN = nowval
arr['eyes'][idx].cbxT = otherval
if(nowval === 'Y')
arr['eyes'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeCheckTEyes(eyes,idx){
if(this.status === 'NEW'){
var nowval = eyes.cbxT === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['eyes'][idx].cbxT = nowval
arr['eyes'][idx].cbxN = otherval
if(nowval === 'N')
arr['eyes'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeValueEyes(eyes,idx){
var nowval = eyes.value
var arr = this.$store.state.physic.details
arr['eyes'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheckNTHT(tht,idx){
if(this.status === 'NEW'){
var nowval = tht.cbxN === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['tht'][idx].cbxN = nowval
arr['tht'][idx].cbxT = otherval
if(nowval === 'Y')
arr['tht'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeCheckTTHT(tht,idx){
if(this.status === 'NEW'){
var nowval = tht.cbxT === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['tht'][idx].cbxT = nowval
arr['tht'][idx].cbxN = otherval
if(nowval === 'N')
arr['tht'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeValueTHT(tht,idx){
var nowval = tht.value
var arr = this.$store.state.physic.details
arr['tht'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheckNCA(chestabdomen,idx){
if(this.status === 'NEW'){
var nowval = chestabdomen.cbxN === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['chestabdomen'][idx].cbxN = nowval
arr['chestabdomen'][idx].cbxT = otherval
if(nowval === 'Y')
arr['chestabdomen'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeCheckTCA(chestabdomen,idx){
if(this.status === 'NEW'){
var nowval = chestabdomen.cbxT === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['chestabdomen'][idx].cbxT = nowval
arr['chestabdomen'][idx].cbxN = otherval
if(nowval === 'N')
arr['chestabdomen'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeValueCA(chestabdomen,idx){
var nowval = chestabdomen.value
var arr = this.$store.state.physic.details
arr['chestabdomen'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeCheckNNerve(nerve,idx){
if(this.status === 'NEW'){
var nowval = nerve.cbxN === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['nerve'][idx].cbxN = nowval
arr['nerve'][idx].cbxT = otherval
if(nowval === 'Y')
arr['nerve'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeCheckTNerve(nerve,idx){
if(this.status === 'NEW'){
var nowval = nerve.cbxT === 'N'?'Y':'N'
var otherval = nowval === 'N'?'Y':'N'
var arr = this.$store.state.physic.details
arr['nerve'][idx].cbxT = nowval
arr['nerve'][idx].cbxN = otherval
if(nowval === 'N')
arr['nerve'][idx].value = ''
this.$store.commit("physic/update_details",arr)
}
},
changeValueNerve(nerve,idx){
var nowval = nerve.value
var arr = this.$store.state.physic.details
arr['nerve'][idx].value = nowval
this.$store.commit("physic/update_details",arr)
},
changeValueTooth(tooth,idx){
var nowval = tooth.value
var arr = this.$store.state.physic.details
arr['tooth'][idx].value = nowval.toUpperCase()
this.$store.commit("physic/update_details",arr)
},
changeValueComplaint(value){
var arr = this.$store.state.physic.details
arr.complaint = value
this.$store.commit("physic/update_details",arr)
},
changeValueConclusion(value){
var arr = this.$store.state.physic.details
arr.conslusion = value
this.$store.commit("physic/update_details",arr)
},
changeValueSuggestion(value){
var arr = this.$store.state.physic.details
arr.suggestion = value
this.$store.commit("physic/update_details",arr)
},
save(xact){
this.$store.commit("physic/update_act",xact)
var msg = ''
var trx = this.$store.state.physic.selected_transaction
if(xact === 'ver'){
msg = "Anda yakin akan melakukan verifikasi pemeriksaan fisik dari pasien "+trx.patient_fullname+" ? "
}
if(xact === 'unver'){
msg = "Anda yakin akan membatalkan verifikasi pemeriksaan fisik dari pasien "+trx.patient_fullname+" ? "
}
if(xact === 'val'){
msg = "Anda yakin akan melakukan validasi pemeriksaan fisik dari pasien "+trx.patient_fullname+" ? "
}
if(xact === 'unval'){
msg = "Anda yakin akan membatalkan validasi pemeriksaan fisik dari pasien "+trx.patient_fullname+" ? "
}
if(xact !== 'save'){
this.$store.commit("physic/update_msg_action",msg)
this.$store.commit("physic/update_dialog_action",true)
}
else{
this.doSave()
}
},
doSave(){
var act = this.$store.state.physic.act
var details = this.$store.state.physic.details
var trxs = this.$store.state.physic.transactions
var trx = this.$store.state.physic.selected_transaction
var idx = _.findIndex(trxs, item => item.T_OrderHeaderID === trx.trx_id)
this.$store.dispatch("physic/doaction",{
act:act,
details:details,
trx:trx,
startdate:this.$store.state.physic.start_date,
enddate: this.$store.state.physic.end_date,
search:this.$store.state.physic.name_lab,
stationid:this.$store.state.physic.selected_station.id,
current_page:this.$store.state.physic.current_page,
lastid:-1
})
},
closeDialogAction(){
this.doSave()
},
changeTab(){
console.log(this.tabnow)
var val = this.tabnow === 'doctor'?'pasien':'doctor'
this.$store.commit("physic/update_tab_now",val)
}
}
}
</script>