Flatten nested repos
This commit is contained in:
@@ -0,0 +1,695 @@
|
||||
<template>
|
||||
<v-layout class="fill-height flex-card" column>
|
||||
<v-card class="fill-height">
|
||||
<!-- <v-subheader>
|
||||
<h3 class="title">DAFTAR PASIEN</h3>
|
||||
</v-subheader> -->
|
||||
<hr style="border-top:0px solid #c8c8c8;" />
|
||||
<v-data-table :headers="headers" :items="pxs" :loading="isLoading" hide-actions class="xelevation-1">
|
||||
|
||||
<template slot="items" slot-scope="props">
|
||||
<td class="text-xs-left pt-2 pb-2 pr-2 green--text"
|
||||
v-bind:class="[margin_left(props.item), validation_color(props.item)]"
|
||||
@click="select(props.index, props.item)" v-if="props.item.is_result == 'N'" colspan="8">
|
||||
{{ props.item.t_testname }}
|
||||
</td>
|
||||
|
||||
<td class="text-xs-left pt-2 pb-2 pr-2 green--text"
|
||||
v-bind:class="[margin_left(props.item), validation_color(props.item)]"
|
||||
@click="select(props.index, props.item)" v-if="props.item.is_result == 'Y'">
|
||||
{{ props.item.t_testname }}
|
||||
</td>
|
||||
|
||||
<td class="text-xs-left pa-2" v-bind:class="[is_selected(props.item), validation_color(props.item)]"
|
||||
@click="select(props.index, props.item)" v-if="props.item.is_result == 'Y'"
|
||||
style="position: relative">
|
||||
<span v-if="props.item.ResultGroupName === 'LAB'" class="body-1">{{ init_result(props.item) }}
|
||||
<v-btn style="width: 28px;padding-bottom: 10px;"
|
||||
v-if="props.item.is_quantitative == 'Y' && props.item.result_instrument_n > 0"
|
||||
color="blue lighten-2" class="btn_rerun" icon flat small
|
||||
@click="rerun_me(props.index, props.item)">
|
||||
<v-img :src="icon_info" aspect-ratio="1" height="15" contain></v-img>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'FNA'" class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogFNA(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'Preparasi Sperma'"
|
||||
class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogPreparasiSperma(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'Cytologi'" class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogCytologi(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'Patologi Anatomi'"
|
||||
class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogPatologiAnatomy(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'Papsmear'" class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogPapsmear(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'Pap Smear (Liquid C Prep)'"
|
||||
class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogLcprep(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'Mikro'" class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogMikro(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span v-if="props.item.ResultGroupName === 'DFI'" class="body-1">{{ init_result(props.item) }}
|
||||
|
||||
<v-btn fab v-if="props.item.result === null || props.item.result === ''" small color="grey"
|
||||
class="ma-0 ml-2">
|
||||
<v-icon>description</v-icon>
|
||||
</v-btn>
|
||||
<v-btn fab v-if="props.item.result !== null && props.item.result !== ''" dark small color="#26c6da"
|
||||
class="ma-0 ml-2" @click="openDialogDNAFRagmentasi(props.item)">
|
||||
<v-icon small>description</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
<span>
|
||||
<v-btn v-if="props.item.nattest_id === selected_flagbloodtype.FlagBloodTypeNat_TestID" style="min-width: 25px; height: 25px; margin: 0;"
|
||||
small class="ml-1 text-xs-right"
|
||||
title="View image golongan darah"
|
||||
color="red"
|
||||
@click="openDialogGolonganDarah(props.item)"
|
||||
>
|
||||
<v-icon small color="white">add</v-icon>
|
||||
</v-btn>
|
||||
</span>
|
||||
</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="[is_selected(props.item), validation_color(props.item)]"
|
||||
@click="select(props.index, props.item)" v-if="props.item.is_result == 'Y'">
|
||||
<span v-if="props.item.is_result == 'Y'" class="one-critical-value" :data-detail-id="props.item.id"
|
||||
style="margin-right:20px"></span>
|
||||
|
||||
{{ !init_blank(props.item) ? props.item.result_flag : "" }}
|
||||
</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="[is_selected(props.item), validation_color(props.item)]"
|
||||
@click="select(props.index, props.item)" v-if="props.item.is_result == 'Y'">
|
||||
{{ !init_blank(props.item) ? props.item.normal_note : "" }}
|
||||
</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="[is_selected(props.item), validation_color(props.item)]"
|
||||
@click="select(props.index, props.item)" v-if="props.item.is_result == 'Y'">
|
||||
{{ !init_blank(props.item) ? props.item.methode_name : "" }}
|
||||
|
||||
|
||||
</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="[is_selected(props.item), validation_color(props.item)]"
|
||||
@click="select(props.index, props.item)" v-if="props.item.is_result == 'Y'">
|
||||
<span class="body-1">{{ !init_blank(props.item) ? props.item.note : "" }}</span>
|
||||
</td>
|
||||
|
||||
<td class="text-xs-center pa-1" v-if="props.item.is_result == 'Y'"
|
||||
v-bind:class="[validation_color(props.item)]" @click="select(props.index, props.item)">
|
||||
<div class="text-xs-center" v-if="parseInt(props.item.IsRefer) > 0">
|
||||
<div class="text-xs-center">
|
||||
<v-btn v-if="props.item.has_critical_value == 'N'" fab :dark="props.item.validation_old != 'Y'" :disabled="props.item.validation_old == 'Y'"
|
||||
small color="red" class="ma-0 float-left" @click="reject(props.item)"
|
||||
v-show="props.item.verification == 'Y'">
|
||||
<v-icon>clear</v-icon>
|
||||
</v-btn>
|
||||
|
||||
<v-btn v-if="props.item.has_critical_value == 'N'" fab dark small :color="props.item.validation == 'Y' ? 'green' : 'grey'"
|
||||
class="ml-1 ma-0 float-left" @click="validation_y(props.index)"
|
||||
v-show="props.item.verification == 'Y'">
|
||||
<v-icon>done</v-icon>
|
||||
</v-btn>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</td>
|
||||
|
||||
<td class="text-xs-center pa-1" v-if="props.item.is_result == 'Y'"
|
||||
v-bind:class="[validation_color(props.item)]">
|
||||
<v-btn dark fab v-if="props.item.has_critical_value == 'Y'" small color="red" class="ma-0 float-left">
|
||||
<v-icon dark>warning</v-icon>
|
||||
</v-btn>
|
||||
<!--<div class="text-xs-center">
|
||||
<div class="text-xs-center">
|
||||
<div style="position:relative;display:inline-block;min-width:80px;padding:0px;"
|
||||
v-if="show_critical(props.item)" class="one-auto-vv"
|
||||
:data-header-id="selected_patient.T_OrderHeaderID" :data-detail-id="props.item.id"> </div>
|
||||
</div>
|
||||
</div>-->
|
||||
|
||||
</td>
|
||||
</template>
|
||||
|
||||
</v-data-table>
|
||||
|
||||
</v-card>
|
||||
|
||||
<one-process-re-rerun-result></one-process-re-rerun-result>
|
||||
<one-process-re-history></one-process-re-history>
|
||||
<v-snackbar v-model="snackbar" :timeout="5000" bottom right>
|
||||
{{ save_text }}
|
||||
<v-btn color="pink" flat @click="snackbar = false">
|
||||
Close
|
||||
</v-btn>
|
||||
</v-snackbar>
|
||||
|
||||
<v-snackbar v-model="snackbar_err" :timeout="5000" bottom right color="red">
|
||||
{{ err_text }}
|
||||
<v-btn color="pink" flat @click="snackbar_err = false">
|
||||
Close
|
||||
</v-btn>
|
||||
</v-snackbar>
|
||||
|
||||
<one-process-rv-dialog-trend></one-process-rv-dialog-trend>
|
||||
<one-process-rv-dialog-mr></one-process-rv-dialog-mr>
|
||||
<one-process-rv-dialog-unval></one-process-rv-dialog-unval>
|
||||
<one-process-re-fna></one-process-re-fna>
|
||||
<one-process-re-cytologi></one-process-re-cytologi>
|
||||
<one-process-re-papsmear></one-process-re-papsmear>
|
||||
<one-process-re-lcprep></one-process-re-lcprep>
|
||||
<one-process-re-mikro></one-process-re-mikro>
|
||||
<one-process-re-preparasi-sperma></one-process-re-preparasi-sperma>
|
||||
<one-process-re-dnafragmentasi></one-process-re-dnafragmentasi>
|
||||
<one-process-re-patologianatomy></one-process-re-patologianatomy>
|
||||
<one-process-re-golongandarah></one-process-re-golongandarah>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
div.v-table__overflow {
|
||||
height: 640px !important;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
.searchbox .v-input.v-text-field .v-input__slot {
|
||||
min-height: 60px;
|
||||
}
|
||||
|
||||
.searchbox .v-btn {
|
||||
min-height: 60px;
|
||||
}
|
||||
|
||||
table.v-table tbody td,
|
||||
table.v-table tbody th {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
table.v-table thead tr {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
.btn_rerun {
|
||||
position: absolute;
|
||||
top: 10px;
|
||||
right: 2px
|
||||
}
|
||||
|
||||
.flex-card {
|
||||
min-height: -webkit-min-content;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.v-text-field.v-text-field--solo .v-input__control {
|
||||
min-height: 40px;
|
||||
}
|
||||
|
||||
.v-textarea.v-text-field--box.v-text-field--single-line .v-text-field__prefix,
|
||||
.v-textarea.v-text-field--box.v-text-field--single-line textarea,
|
||||
.v-textarea.v-text-field--enclosed.v-text-field--single-line .v-text-field__prefix,
|
||||
.v-textarea.v-text-field--enclosed.v-text-field--single-line textarea {
|
||||
margin-top: 6px;
|
||||
}
|
||||
|
||||
.v-btn--floating {
|
||||
border-radius: 0%;
|
||||
}
|
||||
|
||||
/* .cb-auto-ver {
|
||||
float: left;
|
||||
} */
|
||||
|
||||
.cb-auto-ver .v-icon {
|
||||
font-size: 40px;
|
||||
}
|
||||
|
||||
.cb-auto-ver label {
|
||||
color: transparent;
|
||||
}
|
||||
|
||||
.v-btn--floating.v-btn--small {
|
||||
height: 30px;
|
||||
width: 30px;
|
||||
}
|
||||
|
||||
.v-input--selection-controls__ripple {
|
||||
position: relative !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
let ts = '?ts=' + moment().format('YYMMDDhhmmss')
|
||||
module.exports = {
|
||||
components: {
|
||||
'one-process-re-rerun-result': httpVueLoader('./oneProcessReRerunResult.vue' + ts),
|
||||
'one-process-re-history': httpVueLoader('./oneProcessReHistory.vue' + ts),
|
||||
'one-process-rv-dialog-mr': httpVueLoader('./oneProcessRvDialogMr.vue' + ts),
|
||||
'one-process-rv-dialog-trend': httpVueLoader('./oneProcessRvDialogTrend.vue' + ts),
|
||||
'one-process-rv-dialog-unval': httpVueLoader('./oneProcessRvDialogUnval.vue' + ts),
|
||||
'one-process-re-fna': httpVueLoader('./oneResultFNA.vue' + ts),
|
||||
'one-process-re-cytologi': httpVueLoader('./oneResultCytologi.vue' + ts),
|
||||
'one-process-re-papsmear': httpVueLoader('./oneResultPapsmear.vue' + ts),
|
||||
'one-process-re-lcprep': httpVueLoader('./oneResultLcprep.vue' + ts),
|
||||
'one-process-re-mikro': httpVueLoader('./oneResultMikro.vue' + ts),
|
||||
'one-process-re-preparasi-sperma': httpVueLoader('./oneResultPreparasiSperma.vue' + ts),
|
||||
'one-process-re-dnafragmentasi': httpVueLoader('./oneResultDNAFragmentasi.vue' + ts),
|
||||
'one-process-re-patologianatomy': httpVueLoader('./oneResultPatologyAnatomy.vue' + ts),
|
||||
'one-process-re-golongandarah':httpVueLoader('./openDialogGolonganDarah.vue' + ts )
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
query: "",
|
||||
save_text: "Data berhasil dikonfirmasi.",
|
||||
err_text: "Tidak ada data yang perlu dikonfirmasi !",
|
||||
items: [],
|
||||
headers: [
|
||||
{
|
||||
text: "NAMA PEMERIKSAAN",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "HASIL",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "FLAG",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "10%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NILAI NORMAL",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
// {
|
||||
// text: "UNIT",
|
||||
// align: "left",
|
||||
// sortable: false,
|
||||
// value: "mr",
|
||||
// width: "10%",
|
||||
// class: "pa-2 blue lighten-3 white--text"
|
||||
// },
|
||||
{
|
||||
text: "METODE",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "CATATAN",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "10%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "VALIDASI",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "8%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "MR",
|
||||
align: "center",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "20%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
}
|
||||
],
|
||||
|
||||
};
|
||||
},
|
||||
|
||||
methods: {
|
||||
show_critical(item) {
|
||||
return item.is_result == "Y" && (item.verification == "Y" || item.old_validation == "Y");
|
||||
},
|
||||
openDialogDNAFRagmentasi(value) {
|
||||
|
||||
this.$store.dispatch("re_dnafragmentasi/get_dnafragmentasiresult", value)
|
||||
},
|
||||
openDialogCytologi(value) {
|
||||
this.$store.dispatch("re_cytologi/get_cytologiresult", value)
|
||||
|
||||
},
|
||||
openDialogMikro(value) {
|
||||
this.$store.commit("re_mikro/update_selected_mikro", value)
|
||||
this.$store.dispatch("re_mikro/get_mikroresult", value)
|
||||
},
|
||||
openDialogFNA(value) {
|
||||
this.$store.dispatch("re_fna/get_fnaresult", value)
|
||||
},
|
||||
openDialogPatologiAnatomy(value) {
|
||||
//this.$store.commit("re_patologianatomy/update_selected_patologi_anatomy",value)
|
||||
console.log('ini pa')
|
||||
this.$store.dispatch("re_patologianatomy/get_patologianatomyresult", value)
|
||||
},
|
||||
openDialogPreparasiSperma(value) {
|
||||
this.$store.dispatch("re_preparasisperma/get_preparasispermaresult", value)
|
||||
},
|
||||
openDialogPapsmear(value) {
|
||||
this.$store.dispatch("re_papsmear/get_papsmearresult", value)
|
||||
},
|
||||
openDialogLcprep(value) {
|
||||
console.log(value)
|
||||
//this.$store.commit("re_lcprep/update_selected_lcprep",value)
|
||||
this.$store.dispatch("re_lcprep/get_lcprepresult", value)
|
||||
},
|
||||
openDialogGolonganDarah(value){
|
||||
this.$store.commit("re_golongandarah/update_selected_golongandarah", value)
|
||||
this.$store.commit("re_golongandarah/update_dialog_golongandarah", true)
|
||||
this.$store.dispatch("re_golongandarah/get_golongandarah",value)
|
||||
},
|
||||
oneMoment: function (d) {
|
||||
return window.oneMoment(d)
|
||||
},
|
||||
|
||||
select(idx, item) {
|
||||
this.$store.commit('re_px/update_selected_px', item)
|
||||
this.$store.commit('re_px/update_selected_px_idx', idx)
|
||||
// this.$store.commit('ver_validation/update_selected_sent_sample', item)
|
||||
},
|
||||
|
||||
is_selected(item) {
|
||||
|
||||
return ''
|
||||
},
|
||||
|
||||
margin_left(item) {
|
||||
if (item.level == 3 || item.level == 2)
|
||||
return 'pl-5'
|
||||
|
||||
return 'pl-2'
|
||||
},
|
||||
|
||||
rerun_me(idx, item) {
|
||||
this.select(idx, item)
|
||||
this.$store.commit('re_px/update_dialog_rerun', true)
|
||||
},
|
||||
|
||||
update_result(idx, result) {
|
||||
|
||||
let x = this.$store.state.re_px.pxs
|
||||
x[idx]['result'] = result
|
||||
|
||||
this.$store.commit('re_px/update_pxs', { records: x })
|
||||
},
|
||||
|
||||
update_note(idx, note) {
|
||||
|
||||
let x = this.$store.state.re_px.pxs
|
||||
x[idx]['note'] = note
|
||||
|
||||
this.$store.commit('re_px/update_pxs', { records: x })
|
||||
},
|
||||
|
||||
validation(i) {
|
||||
if (i.validation == "N" || i.validation == "Y")
|
||||
return i.validation
|
||||
|
||||
if (i.sample_handling_perfect != "Y")
|
||||
return "N"
|
||||
|
||||
if (i.mr_state == "N")
|
||||
return "N"
|
||||
|
||||
return "Y"
|
||||
},
|
||||
|
||||
_old_validation_y(idx) {
|
||||
|
||||
let x = this.$store.state.re_px.pxs
|
||||
let e = x[idx].validation
|
||||
x[idx].validation = e == 'Y' ? 'N' : 'Y'
|
||||
this.$store.commit("re_px/update_pxs", { records: x })
|
||||
},
|
||||
async validation_y(idx) {
|
||||
let x = this.$store.state.re_px.pxs
|
||||
let e = x[idx].validation
|
||||
|
||||
if (e == 'Y') {
|
||||
return
|
||||
}
|
||||
|
||||
// hanya N -> Y
|
||||
x[idx].validation = 'Y'
|
||||
|
||||
let prm = { order_id: x[idx].id, validation: x[idx].validation }
|
||||
await this.$store.dispatch("re_px/single_validation", prm)
|
||||
|
||||
x[idx].validation_old = 'Y'
|
||||
this.$store.commit("re_px/update_pxs", { records: x })
|
||||
|
||||
let have_val = false
|
||||
for (let i = 0; i < x.length; i++) {
|
||||
if (x[i].validation == 'Y') have_val = true
|
||||
}
|
||||
this.$store.commit('re_px/update_contain_val', have_val)
|
||||
|
||||
if (have_val) {
|
||||
let patient = this.$store.state.re_patient.selected_patient
|
||||
if (patient.T_OrderHeaderAddOnValidationDone == 'N') {
|
||||
patient.T_OrderHeaderAddOnValidationDone = 'P'
|
||||
}
|
||||
let patients = this.$store.state.re_patient.patients
|
||||
for (let i = 0; i < patients.length; i++) {
|
||||
if (patients[i].M_PatientID == patient.M_PatientID) {
|
||||
patients[i] = patient
|
||||
}
|
||||
}
|
||||
let dt = { records: patients, total_page: 1, total: patients.length }
|
||||
this.$store.commit("re_patient/update_patients", dt)
|
||||
} else {
|
||||
let patient = this.$store.state.re_patient.selected_patient
|
||||
patient.T_OrderHeaderAddOnValidationDone = 'N'
|
||||
let patients = this.$store.state.re_patient.patients
|
||||
for (let i = 0; i < patients.length; i++) {
|
||||
if (patients[i].M_PatientID == patient.M_PatientID) {
|
||||
patients[i] = patient
|
||||
}
|
||||
}
|
||||
let dt = { records: patients, total_page: 1, total: patients.length }
|
||||
this.$store.commit("re_patient/update_patients", dt)
|
||||
}
|
||||
},
|
||||
|
||||
mr(x) {
|
||||
this.$store.commit('re_px/update_selected_mr', x)
|
||||
this.$store.commit('re_px/update_dialog_mr', true)
|
||||
console.log('do mr')
|
||||
},
|
||||
|
||||
validation_color(i) {
|
||||
if (i.validation_old == "Y")
|
||||
return "green lighten-4"
|
||||
|
||||
return ""
|
||||
},
|
||||
|
||||
mr_color(x) {
|
||||
if (x.sample_handling_perfect == "N")
|
||||
return "grey"
|
||||
|
||||
if ((x.mr_state[3]) && x.mr_state[3].overlimit) return "red"
|
||||
if (x.mr_state[0] == "N") return "red"
|
||||
if (x.mr_state[0] == "X") return "grey"
|
||||
|
||||
return "green"
|
||||
},
|
||||
|
||||
delta_color_2(x) {
|
||||
if (x.sample_handling_perfect == "N")
|
||||
return "grey"
|
||||
|
||||
if (x.delta_check == "N")
|
||||
return "red"
|
||||
|
||||
return "green"
|
||||
},
|
||||
|
||||
init_result(x) {
|
||||
if (x.validation_old == "Y" || x.verification == "Y")
|
||||
return x.result
|
||||
|
||||
if (x.sample_receive != 'Y')
|
||||
return "Bahan Belum"
|
||||
if (x.sample_receive == 'Y' && !x.pre_analytic)
|
||||
return ""
|
||||
if (x.sample_receive == 'Y' && x.pre_analytic) {
|
||||
if (x.sample_worklist_receive == "Y")
|
||||
return x.result
|
||||
else
|
||||
return ""
|
||||
}
|
||||
},
|
||||
|
||||
init_blank(x) {
|
||||
if (x.validation_old == "Y" || x.verification == "Y")
|
||||
return false
|
||||
|
||||
if (x.sample_receive == "Y" &&
|
||||
x.sample_worklist_receive == "Y" &&
|
||||
!!x.pre_analytic &&
|
||||
x.result != "" &&
|
||||
x.result != null) return false
|
||||
return true
|
||||
},
|
||||
|
||||
trend(x) {
|
||||
// this.$store.commit('re_px/update_dialog_trend', true)
|
||||
},
|
||||
|
||||
delta(x) {
|
||||
this.$store.commit('re_px/update_dialog_trend', true)
|
||||
},
|
||||
|
||||
reject(x) {
|
||||
this.$store.commit('re_px/update_dialog_unval', true)
|
||||
}
|
||||
},
|
||||
|
||||
computed: {
|
||||
isLoading() {
|
||||
return this.$store.state.re_px.search_status == 1
|
||||
},
|
||||
pxs() {
|
||||
return this.$store.state.re_px.pxs
|
||||
},
|
||||
|
||||
icon_info() {
|
||||
return window.BASE_URL + '/one-ui/apps/image/info.png'
|
||||
},
|
||||
|
||||
snackbar: {
|
||||
get() { return this.$store.state.re_px.snackbar },
|
||||
set(v) { this.$store.commit('re_px/update_snackbar', v) }
|
||||
},
|
||||
|
||||
snackbar_err: {
|
||||
get() { return this.$store.state.re_px.snackbar_err },
|
||||
set(v) { this.$store.commit('re_px/update_snackbar_err', v) }
|
||||
},
|
||||
selected_patient() {
|
||||
return this.$store.state.re_patient.selected_patient;
|
||||
},
|
||||
selected_flagbloodtype() {
|
||||
return this.$store.state.re_px.selected_flagbloodtype
|
||||
}
|
||||
|
||||
},
|
||||
watch: {
|
||||
selected_patient(n, o) {
|
||||
/*
|
||||
let cv_itv_retry = 0;
|
||||
let me = this;
|
||||
let cv_itv = setInterval(function () {
|
||||
if (window.render_one_critical_value != undefined && window.render_one_critical_value_header != undefined) {
|
||||
clearInterval(cv_itv);
|
||||
window.render_one_critical_value();
|
||||
window.render_one_critical_value_header();
|
||||
} else {
|
||||
cv_itv_retry++;
|
||||
}
|
||||
}, 800);
|
||||
|
||||
// auto vv
|
||||
let autovv_retry = 0;
|
||||
let autovv_itv = setInterval(function () {
|
||||
if (window.oneAutoVvRender != undefined && window.oneAutoVvStatusRender != undefined) {
|
||||
clearInterval(autovv_itv);
|
||||
console.log("AutoVV Retry", autovv_retry);
|
||||
window.oneAutoVvStatusRender();
|
||||
window.oneAutoVvRender();
|
||||
} else {
|
||||
autovv_retry++;
|
||||
}
|
||||
}, 1100);
|
||||
*/
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
// this.$store.dispatch('re_patient/search')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user