Initial import

This commit is contained in:
sas.fajri
2026-05-25 20:01:37 +07:00
commit 710d7c1b97
10371 changed files with 2381698 additions and 0 deletions

View File

@@ -0,0 +1,271 @@
<template>
<v-layout>
<template>
<v-dialog max-width="30%">
<v-card>
</v-card>
</v-dialog>
</template>
<v-flex xs12>
<v-card>
<v-toolbar color="blue lighten-3" dark height="50px">
<v-toolbar-title>DOKTER</v-toolbar-title>
<v-spacer></v-spacer>
</v-toolbar>
<v-layout row style="background:white;padding-top:5px;" justify-left>
<v-text-field class=" xs4 ma-1" label="Cari"
placeholder="Ketikkan Dokter atau Nama Agreement atau Perusahaan" outline v-model="xsearch"
hide-details></v-text-field>
</v-layout>
<v-divider></v-divider>
<div>
<v-layout row class="scroll-container" style="max-height:600px;overflow: auto;">
<v-flex xs12 pl-2 pr-2 pt-2 pb-2>
<v-data-table :headers="headers" :items="vdoctor" :loading="isLoading" hide-actions
class="elevation-1">
<template slot="items" slot-scope="props">
<td class="text-xs-left pa-2" v-bind:class="{ 'amber lighten-4': isSelected(props.item) }"
@click="selectMe(props.item)">{{ props.item.doctorName }}</td>
<td class="text-xs-left pa-2" v-bind:class="{ 'amber lighten-4': isSelected(props.item) }"
@click="selectMe(props.item)">{{ props.item.M_MouName }}</td>
<td class="text-xs-left pa-2" v-bind:class="{ 'amber lighten-4': isSelected(props.item) }"
@click="selectMe(props.item)">{{ props.item.M_CompanyName }}</td>
</template>
</v-data-table>
</v-flex>
</v-layout>
<v-divider></v-divider>
<v-flex xs12 class="text-xs-left pt-3 pb-3">
<v-pagination v-model="curr_page" :length="xtotal_page"></v-pagination>
</v-flex>
</div>
</v-card>
</v-flex>
</v-layout>
</template>
<style scoped>
.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;
}
.textinput {
-webkit-transition: width 0.4s ease-in-out;
transition: width 0.4s ease-in-out;
background-color: white;
background-position: 10px 10px;
background-repeat: no-repeat;
padding-left: 40px;
width: 100%;
padding: 8px 10px;
margin-bottom: 5px;
box-sizing: border-box;
border: 1px solid #607d8b;
}
.textinput:focus {
width: 100%;
}
.textinput:focus::-webkit-input-placeholder {
color: transparent;
}
.textinput:focus::-moz-placeholder {
color: transparent;
}
.textinput:-moz-placeholder {
color: transparent;
}
.boxoutline {
color: red;
border: 1px solid red;
justify-content: center;
height: 45px;
line-height: 45px;
padding-left: 10px;
background: #ffffff;
font-size: 14px;
font-weight: 500;
border-radius: 1px
}
.boxoutline:hover {
background: rgba(0, 0, 0, 0.07) !important;
font-size: 15px;
font-weight: 700;
}
.boxsolid {
color: #ffffff;
border: 1px solid #ffffff;
justify-content: center;
height: 45px;
line-height: 45px;
padding-left: 10px;
background: #f44336;
font-size: 14px;
font-weight: 500;
border-radius: 1px
}
.boxsolid:hover {
background: #f44336de;
font-size: 15px;
font-weight: 700;
}
.scroll-container {
scroll-padding: 50px 0 0 50px;
}
::-webkit-scrollbar {
width: 7px;
}
/* this targets the default scrollbar (compulsory) */
::-webkit-scrollbar-track {
background-color: #73baf3;
}
/* the new scrollbar will have a flat appearance with the set background color */
::-webkit-scrollbar-thumb {
background-color: #2196f3;
}
/* this will style the thumb, ignoring the track */
::-webkit-scrollbar-button {
background-color: #0079da;
}
/* optionally, you can style the top and the bottom buttons (left and right for horizontal bars) */
::-webkit-scrollbar-corner {
background-color: black;
}
/* if both the vertical and the horizontal bars appear, then perhaps the right bottom corner also needs to be styled */
</style>
<script>
module.exports = {
data() {
return {
headers: [{
text: "DOKTER",
align: "left",
sortable: false,
value: "mr",
width: "15%",
class: "pa-2 blue lighten-3 white--text"
},
{
text: "NAMA AGREEMENT",
align: "left",
sortable: false,
value: "mr",
width: "15%",
class: "pa-2 blue lighten-3 white--text"
},
{
text: "NAMA PERUSAHAAN",
align: "left",
sortable: false,
value: "mr",
width: "15%",
class: "pa-2 blue lighten-3 white--text"
}
]
};
},
mounted() {
this.$store.dispatch("doctor/lookup")
},
computed: {
vdoctor() {
return this.$store.state.doctor.doctors
},
isLoading() {
return this.$store.state.doctor.lookup_status == 1
},
curr_page: {
get() {
return this.$store.state.doctor.current_page
},
set(val) {
this.$store.commit("doctor/update_current_page", val)
this.$store.dispatch("doctor/lookup")
}
},
xtotal_page: {
get() {
return this.$store.state.doctor.total_doctors
},
set(val) {
this.$store.commit("doctor/update_total_doctors", val)
}
},
xsearch: {
get() {
return this.$store.state.doctor.x_search
},
set(val) {
this.$store.commit("doctor/update_x_search", val)
}
},
selected_doctor() {
return this.$store.state.doctor.selected_doctor
}
},
methods: {
isSelected(p) {
return p.doctor_id == this.$store.state.doctor.selected_doctor.doctor_id
},
selectMe(selected) {
this.$store.commit("doctor/update_selected_doctor", selected)
this.$store.commit("doctortest/update_selected_doctor_id", selected.doctor_id)
this.$store.commit("doctortest/update_selected_mou_id", selected.M_UserM_MouID)
},
thr_search: _.debounce(function () {
this.$store.dispatch("doctor/lookup")
}, 1000)
},
watch: {
xsearch(val, old) {
this.xsearch = val
this.thr_search()
},
selected_doctor(val, old) {
this.$store.commit("doctortest/update_selected_doctor_id", val.doctor_id)
}
}
}
</script>

View File

@@ -0,0 +1,456 @@
<template>
<v-layout>
<!-- ERROR DIALOG -->
<v-dialog v-model="dialog_error" max-width="500px">
<v-card>
<v-card-title>
<span>ERROR !</span>
<v-spacer></v-spacer>
</v-card-title>
<v-divider></v-divider>
<div class="ma-3 red--text">{{ msgError }}</div>
<v-divider></v-divider>
<v-card-actions>
<v-spacer></v-spacer>
<v-btn color="primary" flat @click="dialog_error = false">Close</v-btn>
</v-card-actions>
</v-card>
</v-dialog>
<!-- END ERROR DIALOG -->
<!-- Snackbar -->
<v-snackbar v-model="snackbar" :timeout="5000" :multi-line="false" :vertical="false" :top="true" :color="clr"
:value="snackbar">
{{ msgsnackbar }}
<v-btn flat @click="snackbar = false"> Tutup </v-btn>
</v-snackbar>
<!-- End Snackbar -->
<!-- dialog dokter -->
<v-dialog v-model="dialog_form" persistent width="50%">
<v-card>
<v-card-title>
<span class="title">Form Dokter</span>
</v-card-title>
<v-divider></v-divider>
<v-progress-linear v-if="loading_save" :indeterminate="true"></v-progress-linear>
<v-card-text class="pt-3 pb-0">
<v-layout row wrap>
<v-flex xs12>
<v-select v-model="xdoctors" autocomplete :items="doctorss" item-text="doctorName"
item-value="doctor_id" return-object label="Pilih Nama Dokter"
:error="error_doctor_message !== ''" :error-messages="error_doctor_message"
@blur="doctorValidation" required>
</v-select>
</v-flex>
</v-layout>
</v-card-text>
<v-divider></v-divider>
<v-card-actions>
<v-spacer></v-spacer>
<v-btn color="primary" flat @click="dialog_form = false" :disabled="loading_save">Tutup</v-btn>
<v-btn color="primary" flat :disabled="loading_save" @click="saveAdd()">Pilih Dokter</v-btn>
</v-card-actions>
</v-card>
</v-dialog>
<!-- end dialog dokter -->
<v-flex xs12>
<v-card class="mb-2" color="white">
<v-toolbar color="blue lighten-3" dark height="50px">
<v-toolbar-title>PEMERIKSAAN</v-toolbar-title>
<v-spacer></v-spacer>
<div>
<v-btn small @click="openFormDoctor()">COPY FROM DOCTOR</v-btn>
</div>
</v-toolbar>
<v-layout row style="background:white">
<v-layout row justify-space-between>
<v-flex xs4>
<v-text-field class="ma-1" label="Cari" placeholder="Ketikkan Kode atau Pemeriksaan" outline
v-model="xsearch" hide-details></v-text-field>
</v-flex>
<v-flex xs3>
<v-select item-text="M_StatusName" return-object :items="f_statuss" style="font-size:14px"
class="mini-select ma-1" v-model="selected_filter_status" outline hide-details
label="Status"></v-select>
</v-flex>
</v-layout>
</v-layout>
<v-divider></v-divider>
<v-layout row wrap class="scroll-container" style="max-height:600px;overflow: auto;">
<v-flex xs12 pl-2 pr-2 pt-2 pb-2>
<v-data-table :headers="headers" :items="vdoctortest" :loading="isLoading" hide-actions
class="elevation-1">
<template slot="items" slot-scope="props">
<td class="text-xs-left pa-2" v-html="props.item.T_TestSasCode">
</td>
<td class="text-xs-left pa-2" v-html="props.item.T_TestName">
</td>
<td class="text-xs-left pa-2">
<div>
<v-btn @click="changeBtn(props.item)" v-if="props.item.status === 'N'" small
color="error">
<v-icon left>close</v-icon> Belum dipilih</v-btn>
<v-btn @click="changeBtn(props.item)" v-if="props.item.status === 'Y'" small
color="success">
<v-icon left>check</v-icon> Sudah terpilih</v-btn>
</div>
</td>
</template>
</v-data-table>
</v-flex>
</v-layout>
<v-divider></v-divider>
<v-pagination style="margin-top:10px;margin-bottom:10px" v-model="curr_page"
:length="xtotal_page"></v-pagination>
</v-card>
</v-flex>
</v-layout>
</template>
<style scoped>
.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;
}
.textinput {
-webkit-transition: width 0.4s ease-in-out;
transition: width 0.4s ease-in-out;
background-color: white;
background-position: 10px 10px;
background-repeat: no-repeat;
padding-left: 40px;
width: 100%;
padding: 8px 10px;
margin-bottom: 5px;
box-sizing: border-box;
border: 1px solid #607d8b;
}
.textinput:focus {
width: 100%;
}
.textinput:focus::-webkit-input-placeholder {
color: transparent;
}
.textinput:focus::-moz-placeholder {
color: transparent;
}
.textinput:-moz-placeholder {
color: transparent;
}
.boxoutline {
color: red;
border: 1px solid red;
justify-content: center;
height: 45px;
line-height: 45px;
padding-left: 10px;
background: #ffffff;
font-size: 14px;
font-weight: 500;
border-radius: 1px
}
.boxoutline:hover {
background: rgba(0, 0, 0, 0.07) !important;
font-size: 15px;
font-weight: 700;
}
.boxsolid {
color: #ffffff;
border: 1px solid #ffffff;
justify-content: center;
height: 45px;
line-height: 45px;
padding-left: 10px;
background: #f44336;
font-size: 14px;
font-weight: 500;
border-radius: 1px
}
.boxsolid:hover {
background: #f44336de;
font-size: 15px;
font-weight: 700;
}
.scroll-container {
scroll-padding: 50px 0 0 50px;
}
::-webkit-scrollbar {
width: 7px;
}
/* this targets the default scrollbar (compulsory) */
::-webkit-scrollbar-track {
background-color: #73baf3;
}
/* the new scrollbar will have a flat appearance with the set background color */
::-webkit-scrollbar-thumb {
background-color: #2196f3;
}
/* this will style the thumb, ignoring the track */
::-webkit-scrollbar-button {
background-color: #0079da;
}
/* optionally, you can style the top and the bottom buttons (left and right for horizontal bars) */
::-webkit-scrollbar-corner {
background-color: black;
}
/* if both the vertical and the horizontal bars appear, then perhaps the right bottom corner also needs to be styled */
</style>
<script>
module.exports = {
data() {
return {
clr: "success",
xdoctors: 0,
error_doctor_message: "",
headers: [
{
text: "KODE",
align: "left",
sortable: false,
value: "mr",
width: "20%",
class: "blue lighten-3 white--text"
},
{
text: "PEMERIKSAAN",
align: "left",
sortable: false,
value: "mr",
width: "30%",
class: "blue lighten-3 white--text"
},
{
text: "STATUS",
align: "left",
sortable: false,
value: "mr",
width: "10%",
class: "blue lighten-3 white--text"
}
]
};
},
mounted() {
this.$store.dispatch("doctortest/getstatus")
},
computed: {
selected_filter_status: {
get() {
return this.$store.state.doctortest.selected_filter_status
},
set(val) {
this.$store.commit("doctortest/update_selected_filter_status", val)
}
},
f_statuss: {
get() {
return this.$store.state.doctortest.f_statuss
},
set(val) {
this.$store.commit("doctortest/update_f_statuss", val)
}
},
vdoctortest() {
return this.$store.state.doctortest.doctortests
},
xdoctor() {
return this.$store.state.doctor.selected_doctor
},
isLoading() {
return this.$store.state.doctortest.lookup_status == 1
},
curr_page: {
get() {
return this.$store.state.doctortest.current_page
},
set(val) {
this.$store.commit("doctortest/update_current_page", val)
this.$store.commit("doctortest/update_last_id", -1)
this.$store.dispatch("doctortest/lookuptest")
}
},
xtotal_page: {
get() {
return this.$store.state.doctortest.total_doctortests
},
set(val) {
this.$store.commit("doctortest/update_total_doctortests", val)
}
},
xsearch: {
get() {
return this.$store.state.doctortest.x_search
},
set(val) {
this.$store.commit("doctortest/update_x_search", val)
}
},
selected_doctor_id() {
return this.$store.state.doctortest.selected_doctor_id
},
snackbar: {
get() {
return this.$store.state.doctortest.alert_success;
},
set(val) {
this.$store.commit("doctortest/update_alert_success", val);
}
},
msgsnackbar() {
return this.$store.state.doctortest.msg_success;
},
msgError() {
return this.$store.state.doctortest.save_error_message;
},
dialog_error: {
get() {
return this.$store.state.doctortest.alert_error;
},
set(val) {
this.$store.commit("doctortest/update_alert_error", val);
},
},
loading_save: {
get() {
return this.$store.state.doctortest.loading_save
},
set(val) {
this.$store.commit("doctortest/update_loading_save", val)
},
},
dialog_form: {
get() {
return this.$store.state.doctortest.dialog_form
},
set(val) {
this.$store.commit("doctortest/update_dialog_form", val)
},
},
// dropdown doctor
doctorss() {
return this.$store.state.doctortest.doctors
},
xdoctorr() {
return this.$store.state.doctor.selected_doctor
},
xact: {
get() {
return this.$store.state.doctortest.act
},
set(val) {
this.$store.commit("doctortest/update_act", val)
}
},
},
methods: {
thr_search: _.debounce(function () {
this.$store.dispatch("doctortest/lookuptest")
}, 1000),
thr_search_doctor: _.debounce(function () {
this.$store.dispatch("doctortest/lookuptest")
}, 300),
thr_search_doctor_mou: _.debounce(function () {
this.$store.dispatch("doctortest/getdoctor")
}, 1000),
changeBtn(value) {
var prm = {
doctor_id: this.$store.state.doctortest.selected_doctor_id,
test_id: value.testid,
status: value.status === 'N' ? 'Y' : 'N',
T_TestName: value.T_TestName
}
this.$store.dispatch("doctortest/saveeditstatus", prm)
},
doctorValidation() {
if (_.isEmpty(this.xdoctors)) {
this.error_doctor_message = 'Anda belum mengisi'
}
if (this.xdoctors) {
this.error_doctor_message = ""
}
},
resetAllInput() {
this.xdoctors = ""
this.error_doctor_message = ""
},
openFormDoctor() {
this.dialog_form = true
this.$store.commit("doctortest/update_act", "add")
this.xdoctors = ""
this.resetAllInput()
this.$store.commit("doctortest/update_last_id", -1)
},
saveAdd() {
this.doctorValidation()
if (this.error_doctor_message === "") {
var prm = {
doctor_name: this.xdoctors.doctorName,
doctoridfrom: this.xdoctors.doctor_id,
doctoridto: this.$store.state.doctor.selected_doctor.doctor_id
}
this.$store.dispatch("doctortest/copyfromdoctor", prm)
this.dialog_form = false
}
}
},
watch: {
xsearch(val, old) {
this.xsearch = val
this.thr_search()
},
xdoctor(val, old) {
this.thr_search_doctor()
},
selected_doctor_id(val, old) {
this.thr_search_doctor()
},
selected_filter_status(val, old) {
if (this.$store.state.doctortest.selected_doctor_id === 0) {
return
}
this.thr_search()
},
xdoctorr(val, old) {
this.thr_search_doctor_mou()
}
}
}
</script>