Flatten nested repos
This commit is contained in:
20
test/vuex/one-fo-verification-simple-barcode/api/delivery.js
Normal file
20
test/vuex/one-fo-verification-simple-barcode/api/delivery.js
Normal file
@@ -0,0 +1,20 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function lookup(token) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'delivery/lookup',{token:token});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch(e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
100
test/vuex/one-fo-verification-simple-barcode/api/done.js
Normal file
100
test/vuex/one-fo-verification-simple-barcode/api/done.js
Normal file
@@ -0,0 +1,100 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function search(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'done/search', prm);
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
export async function getalmaries(token) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'done/getalmaries',{token:token});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
export async function getracks(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'done/getracks',prm);
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
export async function save(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'done/save',prm);
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
export async function checkbarcode(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'done/checkbarcode',prm);
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
107
test/vuex/one-fo-verification-simple-barcode/api/patient.js
Normal file
107
test/vuex/one-fo-verification-simple-barcode/api/patient.js
Normal file
@@ -0,0 +1,107 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function search(token, nolab, nama, status) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'patient/search', {
|
||||
token:token,
|
||||
nolab: nolab,
|
||||
nama: nama,
|
||||
status: status
|
||||
});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
export async function lookup_barcodes(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'patient/lookup_barcodes',prm);
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
export async function addnewlabel(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'patient/addnewlabel',prm);
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
export async function save(token, patient, status) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'patient/save', {
|
||||
token:token,
|
||||
patient: patient,
|
||||
status: status
|
||||
});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
export async function verify(prm) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'patient/verify', prm);
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
20
test/vuex/one-fo-verification-simple-barcode/api/px.js
Normal file
20
test/vuex/one-fo-verification-simple-barcode/api/px.js
Normal file
@@ -0,0 +1,20 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function search(search,companyid,mouid,orderdate,cito) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'px/search',{search:search,companyid:companyid,mouid:mouid,orderdate:orderdate,cito:cito});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch(e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
20
test/vuex/one-fo-verification-simple-barcode/api/status.js
Normal file
20
test/vuex/one-fo-verification-simple-barcode/api/status.js
Normal file
@@ -0,0 +1,20 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function lookup() {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'status/lookup');
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch(e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
25
test/vuex/one-fo-verification-simple-barcode/api/supplies.js
Normal file
25
test/vuex/one-fo-verification-simple-barcode/api/supplies.js
Normal file
@@ -0,0 +1,25 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function save(token, orderid, supplies, barcode) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'supplies/save', {
|
||||
token:token,
|
||||
orderid: orderid,
|
||||
supplies: supplies,
|
||||
barcode: barcode
|
||||
});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch (e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function lookup() {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'verificationdoctor/lookup');
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch(e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
20
test/vuex/one-fo-verification-simple-barcode/api/vilage.js
Normal file
20
test/vuex/one-fo-verification-simple-barcode/api/vilage.js
Normal file
@@ -0,0 +1,20 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function search(search) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'vilage/search',{search:search});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch(e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
20
test/vuex/one-fo-verification-simple-barcode/api/vilages.js
Normal file
20
test/vuex/one-fo-verification-simple-barcode/api/vilages.js
Normal file
@@ -0,0 +1,20 @@
|
||||
const URL = "/one-api/mockup/fo/verification/";
|
||||
|
||||
export async function search(search) {
|
||||
try {
|
||||
var resp = await axios.post(URL + 'vilage/search',{search:search});
|
||||
if (resp.status != 200) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: resp.statusText
|
||||
};
|
||||
}
|
||||
let data = resp.data;
|
||||
return data;
|
||||
} catch(e) {
|
||||
return {
|
||||
status: "ERR",
|
||||
message: e.message
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,302 @@
|
||||
<template>
|
||||
<v-layout fil-height column>
|
||||
<v-card class="mb-2">
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
|
||||
<v-layout>
|
||||
<v-flex xs3 pa-2>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-img
|
||||
src="https://www.sgm-inc.com/wp-content/uploads/2014/06/no-profile-male-img.gif"
|
||||
aspect-ratio="1"
|
||||
class="grey lighten-2 elevation-2"
|
||||
>
|
||||
</v-flex>
|
||||
|
||||
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs9>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="RM"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientNoReg)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12 pa-1>
|
||||
<v-textarea
|
||||
auto-grow
|
||||
label="Alamat"
|
||||
rows="2"
|
||||
:value="getAddress(patient)"
|
||||
readonly
|
||||
></v-textarea>
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Telephon / HP"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientHP)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Jenis Kelamin"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_SexName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Tanggal Lahir"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientDOB)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Umur"
|
||||
placeholder=""
|
||||
:value="patient_age"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="vpatientname.check"
|
||||
:label="vpatientname.label"
|
||||
:value="vpatientname.check"
|
||||
:note="vpatientname.note"
|
||||
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="No RM sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Alamat sudah sesuai"
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="No HP sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="DOB sudah sesuai"
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Umur sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
</v-card>
|
||||
|
||||
<v-card >
|
||||
<v-subheader>
|
||||
DATA DOKTER
|
||||
</v-subheader>
|
||||
<!--
|
||||
<v-divider></v-divider>
|
||||
<v-flex xs12 pa-3>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12 pa-3>
|
||||
<v-text-field
|
||||
label="Alamat Dokter"
|
||||
placeholder=""
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
-->
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Nama DOkter sudah sesuai"
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Alamat Dokter sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-testing-component-2
|
||||
:xdatalabel="xtestingObj.label"
|
||||
:xdatacbx="xtestingObj.check"
|
||||
:xdatatxt="xtestingObj.note"
|
||||
@update-data-txt="updateDataTxt"
|
||||
@update-data-cbx="updateDataCbx"
|
||||
></one-testing-component-2>
|
||||
</v-flex>
|
||||
|
||||
</v-card>
|
||||
|
||||
|
||||
</v-layout>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.1.vue'),
|
||||
'one-testing-component':httpVueLoader('../../common/oneTestingComponent.vue'),
|
||||
'one-testing-component-2':httpVueLoader('../../common/oneTestingComponent2.vue')
|
||||
|
||||
},
|
||||
computed: {
|
||||
patient_age() {
|
||||
if ( this.patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
return window.calculate_age(this.patient.M_PatientDOB)
|
||||
},
|
||||
patient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vpatientname() {
|
||||
return this.$store.state.verification.verification_patient_name
|
||||
},
|
||||
updateparent(val) {
|
||||
this.$store.commit("verification/update_patient_name",val)
|
||||
},
|
||||
xtesting(){
|
||||
return this.$store.state.verification.testing
|
||||
},
|
||||
xtestinginput(){
|
||||
return this.$store.state.verification.testing
|
||||
},
|
||||
xtestingObj(){
|
||||
return this.$store.state.verification.testingObj
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
getAddress(patient) {
|
||||
if ( patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
if (patient.address == undefined ) return ''
|
||||
if (patient.address.length == 0) return ''
|
||||
return patient.address[0]
|
||||
},
|
||||
getField(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
getError(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
updateDataX(e) {
|
||||
this.$store.commit("verification/update_testing",e)
|
||||
},
|
||||
updateDataObj(e) {
|
||||
this.$store.commit("verification/update_testing_obj",e)
|
||||
},
|
||||
updateDataTxt(val) {
|
||||
this.$store.commit("verification/update_testing_txt",val)
|
||||
},
|
||||
updateDataCbx(val) {
|
||||
this.$store.commit("verification/update_testing_cbx",val)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,302 @@
|
||||
<template>
|
||||
<v-layout fil-height column>
|
||||
<v-card class="mb-2">
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
|
||||
<v-layout>
|
||||
<v-flex xs3 pa-2>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-img
|
||||
src="https://www.sgm-inc.com/wp-content/uploads/2014/06/no-profile-male-img.gif"
|
||||
aspect-ratio="1"
|
||||
class="grey lighten-2 elevation-2"
|
||||
>
|
||||
</v-flex>
|
||||
|
||||
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs9>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="RM"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientNoReg)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12 pa-1>
|
||||
<v-textarea
|
||||
auto-grow
|
||||
label="Alamat"
|
||||
rows="2"
|
||||
:value="getAddress(patient)"
|
||||
readonly
|
||||
></v-textarea>
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Telephon / HP"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientHP)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Jenis Kelamin"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_SexName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Tanggal Lahir"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientDOB)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Umur"
|
||||
placeholder=""
|
||||
:value="patient_age"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="vpatientname.check"
|
||||
:label="vpatientname.label"
|
||||
:value="vpatientname.check"
|
||||
:note="vpatientname.note"
|
||||
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="No RM sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Alamat sudah sesuai"
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="No HP sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="DOB sudah sesuai"
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Umur sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
</v-card>
|
||||
|
||||
<v-card >
|
||||
<v-subheader>
|
||||
DATA DOKTER
|
||||
</v-subheader>
|
||||
<!--
|
||||
<v-divider></v-divider>
|
||||
<v-flex xs12 pa-3>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12 pa-3>
|
||||
<v-text-field
|
||||
label="Alamat Dokter"
|
||||
placeholder=""
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
-->
|
||||
<v-flex xs12 >
|
||||
<v-layout>
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Nama DOkter sudah sesuai"
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Alamat Dokter sudah sesuai "
|
||||
value=false
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-2>
|
||||
<one-testing-component-2
|
||||
:xdatalabel="xtestingObj.label"
|
||||
:xdatacbx="xtestingObj.check"
|
||||
:xdatatxt="xtestingObj.note"
|
||||
@update-data-txt="updateDataTxt"
|
||||
@update-data-cbx="updateDataCbx"
|
||||
></one-testing-component-2>
|
||||
</v-flex>
|
||||
|
||||
</v-card>
|
||||
|
||||
|
||||
</v-layout>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.1.vue'),
|
||||
'one-testing-component':httpVueLoader('../../common/oneTestingComponent.vue'),
|
||||
'one-testing-component-2':httpVueLoader('../../common/oneTestingComponent2.vue')
|
||||
|
||||
},
|
||||
computed: {
|
||||
patient_age() {
|
||||
if ( this.patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
return window.calculate_age(this.patient.M_PatientDOB)
|
||||
},
|
||||
patient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vpatientname() {
|
||||
return this.$store.state.verification.verification_patient_name
|
||||
},
|
||||
updateparent(val) {
|
||||
this.$store.commit("verification/update_patient_name",val)
|
||||
},
|
||||
xtesting(){
|
||||
return this.$store.state.verification.testing
|
||||
},
|
||||
xtestinginput(){
|
||||
return this.$store.state.verification.testing
|
||||
},
|
||||
xtestingObj(){
|
||||
return this.$store.state.verification.testingObj
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
getAddress(patient) {
|
||||
if ( patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
if (patient.address == undefined ) return ''
|
||||
if (patient.address.length == 0) return ''
|
||||
return patient.address[0]
|
||||
},
|
||||
getField(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
getError(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
updateDataX(e) {
|
||||
this.$store.commit("verification/update_testing",e)
|
||||
},
|
||||
updateDataObj(e) {
|
||||
this.$store.commit("verification/update_testing_obj",e)
|
||||
},
|
||||
updateDataTxt(val) {
|
||||
this.$store.commit("verification/update_testing_txt",val)
|
||||
},
|
||||
updateDataCbx(val) {
|
||||
this.$store.commit("verification/update_testing_cbx",val)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,217 @@
|
||||
<template>
|
||||
<v-layout fil-height column>
|
||||
<v-card class="mb-2">
|
||||
<v-subheader>
|
||||
DATA PASIEN
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs3 pa-2>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-img
|
||||
src="https://www.sgm-inc.com/wp-content/uploads/2014/06/no-profile-male-img.gif"
|
||||
aspect-ratio="1"
|
||||
class="grey lighten-2 elevation-2"
|
||||
>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
<v-flex xs9>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="RM"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientNoReg)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12 pa-1>
|
||||
<v-textarea
|
||||
auto-grow
|
||||
label="Alamat"
|
||||
rows="2"
|
||||
:value="getAddress(patient)"
|
||||
readonly
|
||||
></v-textarea>
|
||||
</v-flex>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Telephon / HP"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientHP)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Jenis Kelamin"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_SexName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Tanggal Lahir"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientDOB)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Umur"
|
||||
placeholder=""
|
||||
:value="patient_age"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 pa-2 v-for="(vp,idx) in vpatient" :key="vp.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vp.label"
|
||||
:xdatacbx="vp.check"
|
||||
:xdatatxt="vp.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentPatient(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentPatient(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
|
||||
<v-card >
|
||||
<v-subheader>
|
||||
DATA DOKTER
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-flex pt-2 xs12>
|
||||
<v-layout>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_DoctorName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="Alamat"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_DoctorAddress)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12 >
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 pa-2 v-for="(vp,idx) in vdoctor" :key="vp.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vp.label"
|
||||
:xdatacbx="vp.check"
|
||||
:xdatatxt="vp.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentDoctor(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentDoctor(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.1.vue'),
|
||||
'one-testing-component':httpVueLoader('../../common/oneTestingComponent.vue'),
|
||||
'one-field-verification-patient-doctor':httpVueLoader('../../common/oneFieldVerificationPatientDoctor.vue')
|
||||
},
|
||||
computed: {
|
||||
patient_age() {
|
||||
if ( this.patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
return window.calculate_age(this.patient.M_PatientDOB)
|
||||
},
|
||||
patient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vpatient() {
|
||||
return this.$store.state.verification.verification_patient
|
||||
},
|
||||
vdoctor() {
|
||||
return this.$store.state.verificationdoctor.verification
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
getAddress(patient) {
|
||||
if ( patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
if (patient.address == undefined ) return ''
|
||||
if (patient.address.length == 0) return ''
|
||||
return patient.address[0]
|
||||
},
|
||||
getField(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
getError(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
updateDataTxtParentPatient(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_patient",prm)
|
||||
},
|
||||
updateDataCbxParentPatient(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_patient",prm)
|
||||
},
|
||||
updateDataTxtParentDoctor(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_doctor",prm)
|
||||
},
|
||||
updateDataCbxParentDoctor(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_doctor",prm)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,222 @@
|
||||
<template>
|
||||
<v-layout fil-height column>
|
||||
<v-card class="mb-2">
|
||||
<v-subheader>
|
||||
DATA PASIEN
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs3 pa-2>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-img
|
||||
src="https://www.sgm-inc.com/wp-content/uploads/2014/06/no-profile-male-img.gif"
|
||||
aspect-ratio="1"
|
||||
class="grey lighten-2 elevation-2"
|
||||
>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
<v-flex xs9>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="RM"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientNoReg)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12 pa-1>
|
||||
<v-textarea
|
||||
auto-grow
|
||||
label="Alamat"
|
||||
rows="2"
|
||||
:value="getAddress(patient)"
|
||||
readonly
|
||||
></v-textarea>
|
||||
</v-flex>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Telephon / HP"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientHP)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Jenis Kelamin"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_SexName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Tanggal Lahir"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientDOB)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Umur"
|
||||
placeholder=""
|
||||
:value="patient_age"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 pa-2 v-for="(vp,idx) in vpatient" :key="vp.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vp.label"
|
||||
:xdatacbx="vp.check"
|
||||
:xdatatxt="vp.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentPatient(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentPatient(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
|
||||
<v-card >
|
||||
<v-subheader>
|
||||
DATA DOKTER
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-flex pt-2 xs12>
|
||||
<v-layout>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_DoctorName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="Alamat"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_DoctorAddress)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12 >
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 pa-2 v-for="(vp,idx) in vdoctor" :key="vp.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vp.label"
|
||||
:xdatacbx="vp.check"
|
||||
:xdatatxt="vp.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentDoctor(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentDoctor(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.1.vue'),
|
||||
'one-testing-component':httpVueLoader('../../common/oneTestingComponent.vue'),
|
||||
'one-field-verification-patient-doctor':httpVueLoader('../../common/oneFieldVerificationPatientDoctor.vue')
|
||||
},
|
||||
mounted() {
|
||||
this.$store.dispatch("verificationdoctor/lookup",{
|
||||
ohid:this.$store.state.patient.selected_patient.ohid
|
||||
})
|
||||
},
|
||||
computed: {
|
||||
patient_age() {
|
||||
if ( this.patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
return window.calculate_age(this.patient.M_PatientDOB)
|
||||
},
|
||||
patient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vpatient() {
|
||||
return this.$store.state.verification.verification_patient
|
||||
},
|
||||
vdoctor() {
|
||||
return this.$store.state.verificationdoctor.verifications
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
getAddress(patient) {
|
||||
if ( patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
if (patient.address == undefined ) return ''
|
||||
if (patient.address.length == 0) return ''
|
||||
return patient.address[0]
|
||||
},
|
||||
getField(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
getError(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
updateDataTxtParentPatient(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_patient",prm)
|
||||
},
|
||||
updateDataCbxParentPatient(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_patient",prm)
|
||||
},
|
||||
updateDataTxtParentDoctor(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verificationdoctor/update_txt_verication_doctor",prm)
|
||||
},
|
||||
updateDataCbxParentDoctor(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verificationdoctor/update_cbx_verification_doctor",prm)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,221 @@
|
||||
<template>
|
||||
<v-layout fil-height column>
|
||||
<v-card class="mb-2">
|
||||
<v-subheader>
|
||||
DATA PASIEN
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs3 pa-2>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12>
|
||||
<v-img
|
||||
src="https://www.sgm-inc.com/wp-content/uploads/2014/06/no-profile-male-img.gif"
|
||||
aspect-ratio="1"
|
||||
class="grey lighten-2 elevation-2"
|
||||
>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
<v-flex xs9>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="RM"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientNoReg)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12 pa-1>
|
||||
<v-textarea
|
||||
auto-grow
|
||||
label="Alamat"
|
||||
rows="2"
|
||||
:value="getAddress(patient)"
|
||||
readonly
|
||||
></v-textarea>
|
||||
</v-flex>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Telephon / HP"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientHP)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Jenis Kelamin"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_SexName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12>
|
||||
<v-layout>
|
||||
<v-flex xs7 pa-1>
|
||||
<v-text-field
|
||||
label="Tanggal Lahir"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_PatientDOB)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs5 pa-1>
|
||||
<v-text-field
|
||||
label="Umur"
|
||||
placeholder=""
|
||||
:value="getField(patient.T_OrderHeaderM_PatientAge)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-layout class="pb-3" row wrap>
|
||||
<v-flex xs6 pa-2 v-for="(vp,idx) in vpatient" :key="vp.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vp.label"
|
||||
:xdatacbx="vp.chex"
|
||||
:xdatatxt="vp.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentPatient(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentPatient(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
|
||||
<v-card >
|
||||
<v-subheader>
|
||||
DATA DOKTER
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-flex pt-2 xs12>
|
||||
<v-layout>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_DoctorName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="Alamat"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_DoctorAddress)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex pb-3 xs12 >
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 pa-2 v-for="(vp,idx) in vdoctor" :key="vp.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vp.label"
|
||||
:xdatacbx="vp.chex"
|
||||
:xdatatxt="vp.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentDoctor(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentDoctor(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.1.vue'),
|
||||
'one-testing-component':httpVueLoader('../../common/oneTestingComponent.vue'),
|
||||
'one-field-verification-patient-doctor':httpVueLoader('../../common/oneFieldVerificationPatientDoctor.vue')
|
||||
},
|
||||
computed: {
|
||||
patient_age() {
|
||||
if ( this.patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
return window.calculate_age(this.patient.M_PatientDOB)
|
||||
},
|
||||
patient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vpatient() {
|
||||
return this.$store.state.verification.verification_patient
|
||||
},
|
||||
vdoctor() {
|
||||
return this.$store.state.verification.verification_doctor
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
getAddress(patient) {
|
||||
if ( patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
if (patient.address == undefined ) return ''
|
||||
if (patient.address.length == 0) return ''
|
||||
return patient.address[0]
|
||||
},
|
||||
getField(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
getError(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
updateDataTxtParentPatient(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_patient",prm)
|
||||
},
|
||||
updateDataCbxParentPatient(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_patient",prm)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
updateDataTxtParentDoctor(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_doctor",prm)
|
||||
},
|
||||
updateDataCbxParentDoctor(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_doctor",prm)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,89 @@
|
||||
<template>
|
||||
<v-layout>
|
||||
|
||||
<v-checkbox
|
||||
v-model="x_value"
|
||||
@change="$emit('x_change',{x_value,x_note})"
|
||||
hide-details class="shrink mr-2"
|
||||
></v-checkbox>
|
||||
|
||||
|
||||
<v-text-field
|
||||
:label="__label"
|
||||
placeholder="Alasan"
|
||||
outline
|
||||
:disabled="x_disabled"
|
||||
:error-messages="is_error ? x_error_messages : ''"
|
||||
:error_count="is_error ? x_error_count : 0 "
|
||||
:error=is_error
|
||||
:hide-details=!x_error
|
||||
v-model="x_note"
|
||||
></v-text-field>
|
||||
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
props : ['label', 'value', 'is_error'],
|
||||
|
||||
data () {
|
||||
return {
|
||||
x_value : false,
|
||||
x_note : ""
|
||||
}
|
||||
|
||||
},
|
||||
computed : {
|
||||
__label () {
|
||||
if (this.label)
|
||||
return this.label;
|
||||
|
||||
return "";
|
||||
},
|
||||
|
||||
x_disabled () {
|
||||
return this.x_value;
|
||||
},
|
||||
|
||||
x_error () {
|
||||
|
||||
if (!this.x_value && this.x_note.length < 1)
|
||||
return true;
|
||||
|
||||
else {
|
||||
this.x_note = "";
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
},
|
||||
|
||||
x_error_count () {
|
||||
// return 0;
|
||||
if (this.x_error)
|
||||
return 1;
|
||||
|
||||
return 0;
|
||||
},
|
||||
|
||||
x_error_messages () {
|
||||
if (this.x_error)
|
||||
return ["Harus diisi"];
|
||||
|
||||
return [];
|
||||
},
|
||||
|
||||
// x_note : {
|
||||
// set (newval) {
|
||||
// return newval;
|
||||
// },
|
||||
|
||||
// get () {
|
||||
// return "";
|
||||
// }
|
||||
|
||||
// }
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,50 @@
|
||||
<template>
|
||||
|
||||
<v-dialog
|
||||
v-model="dialog"
|
||||
full-width
|
||||
>
|
||||
<v-card>
|
||||
<v-card-title
|
||||
class="headline grey lighten-2 pt-2 pb-2"
|
||||
primary-title
|
||||
>
|
||||
Data Pasien X
|
||||
</v-card-title>
|
||||
<v-card-text class="pt-2 pb-2">
|
||||
|
||||
</v-card-text>
|
||||
<v-divider></v-divider>
|
||||
|
||||
<v-card-actions>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn
|
||||
color="primary"
|
||||
flat
|
||||
@click="dialog = false"
|
||||
>
|
||||
Tutup
|
||||
</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
computed : {
|
||||
dialog: {
|
||||
get() {
|
||||
return this.$store.state.patient.search_dialog_is_active;
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit('patient/update_search_dialog_is_active',val);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,78 @@
|
||||
<template>
|
||||
|
||||
<v-dialog
|
||||
v-model="dialog"
|
||||
max-width="30%"
|
||||
>
|
||||
<v-card>
|
||||
<v-card-title
|
||||
class="headline grey lighten-2 pt-2 pb-2"
|
||||
primary-title
|
||||
>
|
||||
Peringatan !
|
||||
</v-card-title>
|
||||
<v-card-text class="pt-2 pb-2">
|
||||
<v-layout row>
|
||||
<v-flex xs12 d-flex>
|
||||
<v-layout row>
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 pr-2 xs12>
|
||||
{{msg}}
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</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 = false"
|
||||
>
|
||||
Tutup
|
||||
</v-btn>
|
||||
<v-btn
|
||||
color="primary"
|
||||
flat
|
||||
@click="closeAlert()"
|
||||
>
|
||||
Tambahkan
|
||||
</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
props : ['status', 'msg']
|
||||
computed : {
|
||||
msg() {
|
||||
return this.msg
|
||||
},
|
||||
dialog: {
|
||||
get() {
|
||||
return this.status
|
||||
},
|
||||
set(val) {
|
||||
this.status = val
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
closeAlert() {
|
||||
this.dialog = false
|
||||
this.$emit('close-alert',true)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,192 @@
|
||||
<template>
|
||||
<v-layout column >
|
||||
<v-card>
|
||||
<v-layout row>
|
||||
<v-flex xs12>
|
||||
<v-subheader red--text text--lighten-1> BARCODE
|
||||
<v-flex text-md-right>
|
||||
<v-btn v-if="vshowprint" small @click="printBarcode()" color="primary">Print</v-btn>
|
||||
|
||||
</v-flex>
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12 pt-2 pl-4 pr-4 pb-4>
|
||||
<v-layout row v-for="(vbar,idx) in vbarcode" :key="vbar.id">
|
||||
<v-flex xs12 mb-2>
|
||||
<div class="body-2">
|
||||
{{vbar.name}}
|
||||
<v-btn small @click="addBarcode(idx,vbar)" style="min-width:25px" color="primary">+</v-btn>
|
||||
<!--<v-btn small @click="delBarcode(idx,vbar)" style="min-width:25px" color="error">x</v-btn>-->
|
||||
</div>
|
||||
<v-layout row>
|
||||
<v-flex xs12 v-for="vbarchil in vbar.children">
|
||||
<v-checkbox
|
||||
v-model="vbarchil.chex"
|
||||
readonly="readonly"
|
||||
color="green"
|
||||
>
|
||||
<template v-slot:label>
|
||||
{{vbarchil.barcodenumber}}
|
||||
</template>
|
||||
</v-checkbox>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
table, td, th {
|
||||
border: 1px solid #ddd;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
table {
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
th, td {
|
||||
padding-top: 5px;
|
||||
padding-bottom: 5px;
|
||||
padding-left: 8px;
|
||||
padding-right: 5px;
|
||||
}
|
||||
|
||||
.mini-input .v-input{
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
.mini-input .v-input, .mini-input .v-input--selection-controls,.mini-input .v-input__slot{
|
||||
margin-top: 0px;
|
||||
margin-bottom:0px;
|
||||
margin-left:3px;
|
||||
}
|
||||
.mini-input .v-messages{
|
||||
min-height:0px;
|
||||
}
|
||||
input.fhm-input{
|
||||
border: 1px solid black;
|
||||
border-radius: 2px;
|
||||
-webkit-box-shadow:
|
||||
inset 0 0 2px rgba(0,0,0,0.1),
|
||||
0 0 4px rgba(0,0,0,0.1);
|
||||
-moz-box-shadow:
|
||||
inset 0 0 2px rgba(0,0,0,0.1),
|
||||
0 0 4px rgba(0,0,0,0.1);
|
||||
box-shadow:
|
||||
inset 0 0 2px rgba(0,0,0,0.1),
|
||||
0 0 4px rgba(0,0,0,0.1);
|
||||
padding: 2px 4px;
|
||||
background: rgba(255,255,255,0.5);
|
||||
margin: 0 0 1px 0;
|
||||
width:30px;
|
||||
text-align:center;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
data: () => ({
|
||||
items: [
|
||||
{
|
||||
id: 1,
|
||||
name: 'Applications',
|
||||
children: [
|
||||
{ id: 2, name: 'Calendar : app' },
|
||||
{ id: 3, name: 'Chrome : app' },
|
||||
{ id: 4, name: 'Webstorm : app' }
|
||||
]
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
name: 'fasfsafsafasf',
|
||||
children: [
|
||||
{ id: 2, name: 'Calendar : app' },
|
||||
{ id: 3, name: 'Chrome : app' },
|
||||
{ id: 4, name: 'Webstorm : app' }
|
||||
]
|
||||
}
|
||||
]
|
||||
}),
|
||||
computed: {
|
||||
vbarcode() {
|
||||
return this.$store.state.verification.verification_barcode
|
||||
},
|
||||
vshowprint(){
|
||||
var xdt = this.$store.state.verification.verification_barcode
|
||||
var xx = _.findIndex(xdt, function(o) { return o.xid == 0 })
|
||||
var rst = (xx == -1)?true:false
|
||||
return rst
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
updateDataQtyParentBarcode(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_qty_parent_barcode",prm)
|
||||
},
|
||||
updateDataCbxParentBarcode(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_barcode",prm)
|
||||
},
|
||||
addBarcode(idx,varx){
|
||||
let vpar = varx
|
||||
let lght = vpar.children.length
|
||||
let childx = Object.assign({}, vpar.children[lght - 1])
|
||||
let oldbarcode = childx.barcodenumber
|
||||
let oldcount = oldbarcode.split(".")
|
||||
var newcount = parseInt(oldcount[2]) + 1
|
||||
var newbarcodex = oldcount[0]+'.'+oldcount[1]+'.'+newcount
|
||||
childx.barcodenumber = newbarcodex
|
||||
childx.xid = 0
|
||||
vpar.children.push(childx)
|
||||
|
||||
var oldArr = this.$store.state.patient.selected_patient
|
||||
oldArr.verification_barcode[idx] = vpar
|
||||
this.$store.commit("patient/update_selected_patient",oldArr)
|
||||
|
||||
|
||||
},
|
||||
delBarcode(idx,varx){
|
||||
let vpar = varx
|
||||
let lght = vpar.children.length
|
||||
if(lght > 1){
|
||||
var inx = parseInt(idx);
|
||||
var oldArr = this.$store.state.patient.selected_patient
|
||||
oldArr.verification_barcode[idx].children.splice(lght-1,1)
|
||||
|
||||
this.$store.commit("verification/update_verification_barcode",oldArr.verification_barcode)
|
||||
this.$store.commit("patient/update_selected_patient",oldArr)
|
||||
}
|
||||
},
|
||||
printBarcode(){
|
||||
var xarr = []
|
||||
var selpat = this.$store.state.patient.selected_patient
|
||||
var barcodes = this.$store.state.verification.verification_barcode
|
||||
barcodes.forEach(function(barcode) {
|
||||
var xbarcode = barcode
|
||||
xbarcode.M_PatientName = selpat.M_PatientName
|
||||
xbarcode.M_PatientDOB = selpat.M_PatientDOB
|
||||
xbarcode.T_OrderHeaderLabNumber = selpat.T_OrderHeaderLabNumber
|
||||
xbarcode.T_OrderHeaderDate = selpat.T_OrderHeaderDate
|
||||
xbarcode.M_PatientNoReg = selpat.M_PatientNoReg
|
||||
xbarcode.M_DoctorName = selpat.M_DoctorName
|
||||
xbarcode.M_CompanyName = selpat.M_CompanyName
|
||||
xbarcode.M_PatientAddress = selpat.M_PatientAddress
|
||||
xbarcode.CityUtama = selpat.CityUtama
|
||||
xbarcode.M_SexName = selpat.M_SexName
|
||||
xarr.push(xbarcode)
|
||||
});
|
||||
console.log(xarr)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,102 @@
|
||||
<template>
|
||||
<v-layout column class="fill-height">
|
||||
<v-card class="mb-2">
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12 >
|
||||
<v-subheader red--text text--lighten-1> DATA PENGIRIMAN
|
||||
<v-flex text-md-right>
|
||||
<v-btn small color="primary">Tambah Data</v-btn>
|
||||
</v-flex>
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row>
|
||||
<v-flex xs12 pa-1>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Email ke Dokter : sms.sipe@gmail.com"
|
||||
@x_change="emailChange"
|
||||
value=""
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row>
|
||||
<v-flex xs12 pa-1>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Kirim ke Pasien : Jl. Tegal Raya No. 1"
|
||||
@x_change="emailChange"
|
||||
value=""
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row>
|
||||
<v-flex xs9 pa-1 class="indigo lighten-5">
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Email ke Dokter : sms.sipe@gmail.com"
|
||||
@x_change="emailChange"
|
||||
value=""
|
||||
></one-field-verification>
|
||||
</v-flex>
|
||||
<v-flex class="indigo lighten-5" pt-3 xs3>
|
||||
<v-layout align-center justify-center row>
|
||||
<v-icon large color="red">delete</v-icon>
|
||||
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
<v-card>
|
||||
<v-layout row>
|
||||
<v-flex xs12>
|
||||
<v-subheader red--text text--lighten-1> DATA PEMBAYARAN</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row>
|
||||
<v-flex xs12 pa-2>
|
||||
<one-field-verification
|
||||
:is_error="true"
|
||||
label="Minimum pembayaran terpenuhi (Rp 50.000)"
|
||||
@x_change="emailChange"
|
||||
value=""
|
||||
></one-field-verification>
|
||||
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.vue'),
|
||||
'one-field-verification-delivery-payment' : httpVueLoader('../../common/oneFieldVerificationDeliveryPayment.vue')
|
||||
},
|
||||
|
||||
data () {
|
||||
return {
|
||||
email: 'sms@fajrihm.gmail.com"',
|
||||
_email: true,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
emailChange : function(val) {
|
||||
console.log(val);
|
||||
}
|
||||
},
|
||||
computed : {
|
||||
_email () {
|
||||
return this.$data._email;
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,228 @@
|
||||
<template>
|
||||
<v-layout column class="fill-height">
|
||||
<v-card v-if="vdelivery.length > 0" class="mb-2">
|
||||
<v-layout class="pb-3" row wrap>
|
||||
<v-flex xs12 >
|
||||
<v-subheader red--text text--lighten-1> DATA PENGIRIMAN
|
||||
<v-flex text-md-right>
|
||||
<v-btn small v-if="vlaststatus === '2'" @click="openDialogDelivery()" color="primary">Tambah Pengiriman</v-btn>
|
||||
<one-verification-dialog-delivery @add-data-delivery="(cval) => updateDataParentDelivery(cval)"></one-verification-dialog-delivery>
|
||||
</v-flex>
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row wrap>
|
||||
<v-flex v-for="(vd,index) in vdelivery" xs12 pa-1>
|
||||
<one-field-verification-delivery-payment
|
||||
:xdatalabel="vd.label"
|
||||
:xdatacbx="vd.chex"
|
||||
:xdatatxt="vd.note"
|
||||
:xdatatype="vd.type"
|
||||
@update-data-txt="(val) => updateDataTxtParentDelivery(index,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentDelivery(index,val)"
|
||||
@update-data-delete="(val) => deleteDataParentDelivery(index,val)"
|
||||
></one-field-verification-delivery-payment>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
<v-card v-if="vpayment.length > 0">
|
||||
<v-layout class="pb-3" row>
|
||||
<v-flex pb-3 xs12>
|
||||
<v-subheader red--text text--lighten-1> DATA PEMBAYARAN</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row>
|
||||
<v-flex class="text-xs-center" xs12 pa-3>
|
||||
<v-layout row>
|
||||
<v-flex xs3><b class="indigo--text">{{vselpatient.texttagihan}}</b></v-flex>
|
||||
<v-flex xs7><b>Total Tagihan</b> <kbd>{{convertMoney(vselpatient.T_OrderHeaderTotal)}}</kbd> <b>Pembayaran</b> <kbd>{{convertMoney(vselpatient.paid)}}</kbd> | <span>{{persen(vselpatient.T_OrderHeaderTotal,vselpatient.paid)}}</span>%</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<one-field-verification-delivery-payment
|
||||
v-for="(vp,idx) in vpayment" :key="vp.id"
|
||||
:xdatalabel="vp.label"
|
||||
:xdatacbx="vp.chex"
|
||||
:xdatatxt="vp.note"
|
||||
:xdatatype="vp.type"
|
||||
@update-data-txt="(val) => updateDataTxtParentPayment(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentPayment(idx,val)"
|
||||
></one-field-verification-delivery-payment>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
<v-card v-if="vpayment.length > 0" class="mt-2" >
|
||||
<v-subheader>
|
||||
CATATAN VERIFIKASI
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-flex xs12 class="pl-4 pr-4 pt-2 pb-2 mt-2">
|
||||
<v-textarea
|
||||
label="Tulis catatan di sini"
|
||||
rows="3"
|
||||
v-model="verification_note"
|
||||
outline
|
||||
></v-textarea>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
<v-card v-if="vpayment.length > 0" v-if="vlaststatus === '2'" class="mt-2">
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 pa-2 >
|
||||
<v-btn large block @click="saveVerification('N')" color="error">Tolak</v-btn>
|
||||
</v-flex>
|
||||
<v-flex xs6 pa-2 >
|
||||
<v-btn large block @click="saveVerification('Y')" color="primary">Verifikasi</v-btn>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
<v-dialog v-model="dialogvalidation" persistent width="500">
|
||||
<v-card>
|
||||
<v-card-title class="headline">Peringatan !</v-card-title>
|
||||
<v-card-text>
|
||||
<v-alert v-for="item in msgdialogvalidation"
|
||||
:value="true"
|
||||
type="error"
|
||||
>
|
||||
{{item}} [ Belum ada alasan ]
|
||||
</v-alert>
|
||||
</v-card-text>
|
||||
<v-card-actions>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn color="green darken-1" flat @click="dialogvalidation = false">OK</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
data () {
|
||||
return {
|
||||
dialogvalidation: false,
|
||||
msgdialogvalidation:[]
|
||||
}
|
||||
},
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.vue'),
|
||||
'one-field-verification-delivery-payment' : httpVueLoader('../../common/oneFieldVerificationDeliveryPayment.vue'),
|
||||
'one-verification-dialog-delivery' : httpVueLoader('./oneVerificationDialogDelivery.vue')
|
||||
},
|
||||
computed: {
|
||||
vselpatient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vlaststatus() {
|
||||
return this.$store.state.patient.selected_patient.check_status
|
||||
},
|
||||
vdelivery() {
|
||||
return this.$store.state.verification.verification_delivery
|
||||
},
|
||||
vpayment() {
|
||||
return this.$store.state.verification.verification_payment
|
||||
},
|
||||
verification_note: {
|
||||
get() {
|
||||
return this.$store.state.patient.selected_patient.verification_note
|
||||
},
|
||||
set(val) {
|
||||
var oldArr = this.$store.state.patient.selected_patient
|
||||
oldArr.verification_note = val
|
||||
this.$store.commit("patient/update_selected_patient",oldArr)
|
||||
}
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
updateDataTxtParentDelivery(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_delivery",prm)
|
||||
},
|
||||
updateDataCbxParentDelivery(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_delivery",prm)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
updateDataTxtParentPayment(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_payment",prm)
|
||||
},
|
||||
updateDataCbxParentPayment(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_payment",prm)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
deleteDataParentDelivery(idx,val){
|
||||
var inx = parseInt(idx);
|
||||
var oldArr = this.$store.state.patient.selected_patient
|
||||
oldArr.verification_delivery.splice(inx,1)
|
||||
|
||||
this.$store.commit("patient/update_selected_patient",oldArr)
|
||||
},
|
||||
openDialogDelivery(){
|
||||
var oldArr = this.$store.state.delivery.deliveries
|
||||
this.$store.commit("delivery/update_selected_delivery",oldArr[0])
|
||||
this.$store.commit('verification/update_dialog_delivery_is_active',true)
|
||||
},
|
||||
updateDataParentDelivery(valx){
|
||||
var oldArr = this.$store.state.patient.selected_patient
|
||||
oldArr.verification_delivery.push(valx)
|
||||
this.$store.commit("patient/update_selected_patient",oldArr)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
convertMoney(money){
|
||||
return one_money(money)
|
||||
},
|
||||
persen(total,paid){
|
||||
return ((paid/total)*100).toFixed(2)
|
||||
},
|
||||
saveVerification(status){
|
||||
var xerrors = []
|
||||
var allArr = this.$store.state.patient.selected_patient
|
||||
allArr.verification_patient.forEach(function(value) {
|
||||
if(value.chex === false && value.note === "")
|
||||
xerrors.push(value.label);
|
||||
});
|
||||
allArr.verification_doctor.forEach(function(value) {
|
||||
if(value.chex === false && value.note === "")
|
||||
xerrors.push(value.label);
|
||||
});
|
||||
allArr.verification_companymou.forEach(function(value) {
|
||||
if(value.chex === false && value.note === "")
|
||||
xerrors.push(value.label);
|
||||
});
|
||||
allArr.verification_delivery.forEach(function(value) {
|
||||
if(value.chex === false && value.note === "")
|
||||
xerrors.push(value.label);
|
||||
});
|
||||
allArr.verification_info.forEach(function(value) {
|
||||
if(value.chex === false && value.note === "")
|
||||
xerrors.push(value.label);
|
||||
});
|
||||
allArr.verification_payment.forEach(function(value) {
|
||||
if(value.chex === false && value.note === "")
|
||||
xerrors.push(value.label);
|
||||
});
|
||||
if(xerrors.length === 0){
|
||||
var prm = {patient: this.$store.state.patient.selected_patient, status : status}
|
||||
this.$store.dispatch("patient/save",prm)
|
||||
}
|
||||
else{
|
||||
var msg = ""
|
||||
xerrors.forEach(function(value) {
|
||||
msg += '<v-alert :value="true" type="error">'+value+'</v-alert>'
|
||||
});
|
||||
this.msgdialogvalidation = xerrors
|
||||
this.dialogvalidation = true
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,141 @@
|
||||
<template>
|
||||
|
||||
<v-dialog
|
||||
v-model="dialog"
|
||||
max-width="30%"
|
||||
>
|
||||
<v-card>
|
||||
<v-card-title
|
||||
class="headline grey lighten-2 pt-2 pb-2"
|
||||
primary-title
|
||||
>
|
||||
Form Pemeriksaan
|
||||
</v-card-title>
|
||||
<v-card-text class="pt-2 pb-2">
|
||||
<v-layout>
|
||||
<v-flex style="padding-bottom:0" xs12>
|
||||
<v-checkbox
|
||||
v-model="cito"
|
||||
label="Cito"
|
||||
>Cito</v-checkbox>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row>
|
||||
<v-flex pr-2 xs12>
|
||||
<v-autocomplete
|
||||
label="Pemeriksaan"
|
||||
v-model="xselected_px"
|
||||
:items="xpxs"
|
||||
:search-input.sync="search"
|
||||
auto-select-first
|
||||
no-filter
|
||||
return-object
|
||||
item-text="pxname"
|
||||
:loading="is_loading"
|
||||
no-data-text="Pilih Pemeriksaan"
|
||||
>
|
||||
<template
|
||||
slot="item"
|
||||
slot-scope="{ item }"
|
||||
>
|
||||
<v-list-tile-content>
|
||||
<v-list-tile-title v-text="item.pxname"></v-list-tile-title>
|
||||
</v-list-tile-content>
|
||||
</template>
|
||||
|
||||
</v-autocomplete>
|
||||
</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 = false"
|
||||
>
|
||||
Tutup
|
||||
</v-btn>
|
||||
<v-btn
|
||||
color="primary"
|
||||
flat
|
||||
@click="addPx()"
|
||||
>
|
||||
Tambahkan
|
||||
</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
data(){
|
||||
return {
|
||||
datatext : '',
|
||||
search : '',
|
||||
cito:false
|
||||
}
|
||||
},
|
||||
computed : {
|
||||
vtext : {
|
||||
get() {
|
||||
return this.datatext
|
||||
},
|
||||
set(val) {
|
||||
this.datatext = val
|
||||
}
|
||||
},
|
||||
dialog: {
|
||||
get() {
|
||||
return this.$store.state.px.dialog_px_is_active
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit('px/update_dialog_px_is_active',val)
|
||||
}
|
||||
},
|
||||
xselected_px: {
|
||||
get() {
|
||||
this.$store.state.px.selected_px
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("px/update_selected_px",val)
|
||||
}
|
||||
},
|
||||
xpxs() {
|
||||
return this.$store.state.px.pxs
|
||||
},
|
||||
is_loading() {
|
||||
return this.$store.state.px.search_status == 1
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
addPx() {
|
||||
this.dialog = false
|
||||
var prm = {'id':0,'chex':false,'pxid':this.$store.state.px.selected_px.id,'flagcito':this.$store.state.px.selected_px.flagcito,'pxname':this.$store.state.px.selected_px.pxname,'bruto':this.$store.state.px.selected_px.bruto,'discount':this.$store.state.px.selected_px.discount,'total':this.$store.state.px.selected_px.total,'addon':true}
|
||||
this.cito = false
|
||||
this.search = ''
|
||||
this.datatext = ''
|
||||
this.$emit('add-data-px', prm)
|
||||
},
|
||||
thr_search: _.debounce( function () {
|
||||
this.$store.dispatch("px/search",this.cito)
|
||||
},2000)
|
||||
},
|
||||
watch: {
|
||||
search(val,old) {
|
||||
if (val == old ) return
|
||||
if (! val) return
|
||||
if (val.length < 1 ) return
|
||||
if (this.$store.state.px.search_status == 1 ) return
|
||||
this.$store.commit("px/update_search",val)
|
||||
this.thr_search()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,173 @@
|
||||
<template>
|
||||
<v-layout class="fill-height" column>
|
||||
<v-card class="mb-2 pa-2 searchbox">
|
||||
<v-layout >
|
||||
|
||||
<v-text-field class="xs3 ma-1"
|
||||
placeholder="No Lab"
|
||||
single-line
|
||||
outline
|
||||
v-model="nolab"
|
||||
hide-details
|
||||
></v-text-field>
|
||||
|
||||
<v-text-field class="xs6 ma-1"
|
||||
label=""
|
||||
placeholder="Nama"
|
||||
single-line
|
||||
outline
|
||||
v-model="name"
|
||||
hide-details
|
||||
></v-text-field>
|
||||
|
||||
<v-select class="xs6 ma-1" :items="statuses"
|
||||
item-text="name"
|
||||
return-object
|
||||
v-model="status"
|
||||
label="Status" outline hide-details></v-select>
|
||||
|
||||
|
||||
|
||||
<v-btn class="xs3 ma-1" color="success" @click="searchPatient" >Search</v-btn>
|
||||
|
||||
|
||||
</v-layout>
|
||||
</v-card>
|
||||
|
||||
|
||||
<v-card class="grow">
|
||||
|
||||
<v-data-table
|
||||
:headers="headers"
|
||||
:items="patients"
|
||||
: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.M_PatientNoReg }}</td>
|
||||
<td class="pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item)}" @click="selectMe(props.item)">{{ props.item.T_OrderHeaderLabNumber}}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item)}" @click="selectMe(props.item)">{{ props.item.M_PatientName}}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item)}" @click="selectMe(props.item)">{{ props.item.M_StatusName}}</td>
|
||||
</template>
|
||||
|
||||
</v-data-table>
|
||||
|
||||
</v-card>
|
||||
</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;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
mounted() {
|
||||
this.$store.dispatch("status/lookup")
|
||||
this.$store.dispatch("patient/search",{
|
||||
name:this.name,
|
||||
nolab: this.nolab,
|
||||
status: this.status.code
|
||||
})
|
||||
},
|
||||
methods : {
|
||||
isSelected(p) {
|
||||
return p.T_OrderHeaderID == this.$store.state.patient.selected_patient.T_OrderHeaderID
|
||||
},
|
||||
searchPatient() {
|
||||
this.$store.dispatch("patient/search",{
|
||||
name:this.name,
|
||||
nolab: this.nolab,
|
||||
status: this.status.code
|
||||
})
|
||||
},
|
||||
selectMe(pat) {
|
||||
this.$store.commit("patient/update_selected_patient",pat)
|
||||
this.$store.commit("verification/update_verification_patient",pat)
|
||||
this.$store.commit("verification/update_verification_doctor",pat)
|
||||
this.$store.commit("verification/update_verification_delivery",pat)
|
||||
this.$store.commit("verification/update_verification_payment",pat)
|
||||
this.$store.commit("verification/update_verification_supplies",pat)
|
||||
this.$store.commit("verification/update_verification_barcode",pat)
|
||||
this.$store.commit("verification/update_verification_company_mou",pat)
|
||||
this.$store.commit("verification/update_verification_px",pat)
|
||||
this.$store.dispatch("verificationdoctor/lookup",{
|
||||
ohid:this.$store.state.patient.selected_patient.ohid
|
||||
})
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
statuses() {
|
||||
return this.$store.state.status.statuses
|
||||
},
|
||||
status: {
|
||||
get() {
|
||||
return this.$store.state.status.selected_status
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("status/update_selected_status",val)
|
||||
}
|
||||
},
|
||||
isLoading() {
|
||||
return this.$store.state.patient.search_status == 1
|
||||
},
|
||||
patients() {
|
||||
return this.$store.state.patient.patients
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
items: [],
|
||||
name: '',
|
||||
nolab: '',
|
||||
headers: [
|
||||
{
|
||||
text: "NO REG",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NO LAB",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "lab",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NAMA",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "name",
|
||||
width: "25%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
|
||||
{
|
||||
text: "STATUS",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "status",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
}
|
||||
],
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,328 @@
|
||||
<template>
|
||||
<v-layout class="fill-height" column>
|
||||
<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()">OK</v-btn>
|
||||
<v-btn color="error darken-1" flat @click="xdialogaction = false">Tutup</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
<v-snackbar
|
||||
v-model="snackbar.value"
|
||||
:timeout="snackbar.timeout"
|
||||
>
|
||||
{{ snackbar.text }}
|
||||
<v-btn
|
||||
color="blue"
|
||||
text
|
||||
@click="snackbar.value = false"
|
||||
>
|
||||
Tutup
|
||||
</v-btn>
|
||||
</v-snackbar>
|
||||
<v-card class="mb-2 pa-2 searchbox">
|
||||
<v-layout row>
|
||||
<v-flex xs4 mt-1 pr-2>
|
||||
<v-text-field
|
||||
label="No Reg"
|
||||
outline
|
||||
v-model="nolab"
|
||||
hide-details
|
||||
v-on:keyup.enter="searchPatient"
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs4 mt-1 pr-2>
|
||||
<v-text-field
|
||||
label="Nama"
|
||||
outline
|
||||
v-model="name"
|
||||
v-on:keyup.enter="searchPatient"
|
||||
hide-details
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
<v-card >
|
||||
<v-layout row>
|
||||
<v-flex xs12 pl-2 pr-2 pt-2 pb-2>
|
||||
<v-data-table
|
||||
:headers="headers"
|
||||
:items="patients"
|
||||
: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),'amber':props.item.iscito === 'Y'}" @click="selectMe(props.item)">{{ format_date(props.item.T_OrderHeaderDate) }}</td>
|
||||
<td class="pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item),'amber':props.item.iscito === 'Y'}" @click="selectMe(props.item)">
|
||||
<span style="color:brick">{{ props.item.T_OrderHeaderLabNumberExt}}</span> <br/>
|
||||
{{ props.item.T_OrderHeaderLabNumber}}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item),'amber':props.item.iscito === 'Y'}" @click="selectMe(props.item)">{{ props.item.M_CompanyName}}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item),'amber':props.item.iscito === 'Y'}" @click="selectMe(props.item)">{{ props.item.M_PatientName}}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item),'amber':props.item.iscito === 'Y'}" @click="selectMe(props.item)">
|
||||
<div v-if="status.code === 'FO.Verification' && props.item.check_status === '2'">
|
||||
<span v-if="btnsaveseen" @click="verify(props.item,'N')" class="icon-medium-fill-base white--text error"><v-icon dark>close</v-icon></span>
|
||||
<span v-if="btnsaveseen" @click="verify(props.item,'Y')" class="icon-medium-fill-base white--text success"><v-icon dark>check</v-icon></span>
|
||||
|
||||
</div>
|
||||
</td>
|
||||
</template>
|
||||
</v-data-table>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
<one-dialog-alert :status="openalertverification" :msg="msgalertverification" @forget-dialog-alert="forgetAlertVerification()" @close-dialog-alert="closeAlertVerification()"></one-dialog-alert>
|
||||
<one-dialog-info :status="opendialogverification" :msg="msginfoverification" @close-dialog-info="closeInfoVerification()"></one-dialog-info>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.searchbox .v-input.v-text-field .v-input__slot{
|
||||
min-height:40px;
|
||||
}
|
||||
.searchbox .v-btn {
|
||||
min-height:40px;
|
||||
}
|
||||
table.v-table tbody td,table.v-table tbody th {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
table.v-table thead tr {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-dialog-info':httpVueLoader('../../common/oneDialogInfo.vue'),
|
||||
'one-dialog-alert':httpVueLoader('../../common/oneDialogAlert.vue')
|
||||
},
|
||||
mounted() {
|
||||
this.$store.dispatch("status/lookup")
|
||||
this.$store.dispatch("delivery/lookup")
|
||||
this.$store.dispatch("patient/search",{
|
||||
name:this.name,
|
||||
nolab: this.nolab,
|
||||
//status: this.status.id
|
||||
})
|
||||
},
|
||||
methods : {
|
||||
format_date(p) {
|
||||
return moment(p).format("DD.MM.YYYY")
|
||||
},
|
||||
isSelected(p) {
|
||||
if(p.iscito === 'Y')
|
||||
return false
|
||||
else
|
||||
return p.T_OrderHeaderID == this.$store.state.patient.selected_patient.T_OrderHeaderID
|
||||
|
||||
},
|
||||
searchPatient() {
|
||||
if(this.status.code === 'FO.Verification'){
|
||||
this.$store.commit("patient/update_show_right",'N')
|
||||
}
|
||||
else{
|
||||
this.$store.commit("patient/update_show_right",'Y')
|
||||
}
|
||||
this.$store.dispatch("patient/search",{
|
||||
name:this.name,
|
||||
nolab: this.nolab,
|
||||
// status: this.status.id
|
||||
})
|
||||
},
|
||||
selectMe(pat) {
|
||||
this.$store.commit("patient/update_selected_patient",pat)
|
||||
|
||||
},
|
||||
closeInfoVerification(){
|
||||
this.$store.commit("patient/update_open_dialog_verification",false)
|
||||
this.searchPatient()
|
||||
},
|
||||
closeAlertVerification(){
|
||||
this.$store.commit("patient/update_open_alert_verification",false)
|
||||
},
|
||||
forgetAlertVerification(){
|
||||
this.$store.commit("patient/update_no_save",0)
|
||||
this.$store.commit("patient/update_open_alert_verification",false)
|
||||
},
|
||||
verify(value,act){
|
||||
this.$store.commit("patient/update_selected_patient",value)
|
||||
value.act = act
|
||||
this.$store.commit("patient/update_now_prm",value)
|
||||
if(act === 'Y'){
|
||||
var prm = this.$store.state.patient.now_prm
|
||||
prm.name = this.name
|
||||
prm.nolab = this.nolab
|
||||
this.$store.commit("done/update_current_page",1)
|
||||
prm.done_search = {
|
||||
startdate:this.$store.state.done.start_date,
|
||||
enddate:this.$store.state.done.end_date,
|
||||
search:this.$store.state.done.search,
|
||||
current_page:1,
|
||||
lastid:-1
|
||||
|
||||
}
|
||||
this.$store.dispatch("patient/verify",prm)
|
||||
}
|
||||
else{
|
||||
var xxver = value.verifications
|
||||
|
||||
xxver.forEach((el)=>{el.chex = true})
|
||||
this.$store.commit("patient/update_verifications",xxver)
|
||||
this.$store.commit("patient/update_dialoglist",true)
|
||||
this.$store.commit("patient/update_btn_save_seen",false)
|
||||
}
|
||||
},
|
||||
closeDialogAction(){
|
||||
var prm = this.$store.state.patient.now_prm
|
||||
this.$store.dispatch("patient/verify",prm)
|
||||
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
statuses() {
|
||||
return this.$store.state.status.statuses
|
||||
},
|
||||
snackbar: {
|
||||
get() {
|
||||
return this.$store.state.patient.snackbar
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_snackbar",val)
|
||||
}
|
||||
},
|
||||
name: {
|
||||
get() {
|
||||
return this.$store.state.patient.name
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_name",val)
|
||||
}
|
||||
},
|
||||
nolab: {
|
||||
get() {
|
||||
return this.$store.state.patient.nolab
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_nolab",val)
|
||||
}
|
||||
},
|
||||
status: {
|
||||
get() {
|
||||
return this.$store.state.status.selected_status
|
||||
},
|
||||
set(val) {
|
||||
if(val.code === 'FO.Verification'){
|
||||
this.$store.commit("patient/update_show_right",'N')
|
||||
}
|
||||
this.$store.commit("status/update_selected_status",val)
|
||||
}
|
||||
},
|
||||
isLoading() {
|
||||
return this.$store.state.patient.search_status == 1
|
||||
},
|
||||
patients() {
|
||||
return this.$store.state.patient.patients
|
||||
},
|
||||
opendialogverification: {
|
||||
get() {
|
||||
return this.$store.state.patient.open_dialog_verification
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_open_dialog_verification",false)
|
||||
}
|
||||
},
|
||||
msginfoverification(){
|
||||
return this.$store.state.patient.msg_info_verification
|
||||
},
|
||||
openalertverification: {
|
||||
get() {
|
||||
return this.$store.state.patient.open_alert_verification
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/open_alert_verification",false)
|
||||
}
|
||||
},
|
||||
msgalertverification(){
|
||||
return this.$store.state.patient.msg_alert_verification
|
||||
},
|
||||
xdialogaction:{
|
||||
get() {
|
||||
return this.$store.state.patient.dialog_action
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_dialog_action",val)
|
||||
}
|
||||
},
|
||||
xmsgaction:{
|
||||
get() {
|
||||
return this.$store.state.patient.msg_action
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_msg_action",val)
|
||||
}
|
||||
},
|
||||
btnsaveseen:{
|
||||
get() {
|
||||
return this.$store.state.patient.btn_save_seen
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_btn_save_seen",val)
|
||||
}
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
items: [],
|
||||
headers: [
|
||||
{
|
||||
text: "TANGGAL",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "10%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NO REG",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "lab",
|
||||
width: "12%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "KEL PELANGGAN",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "lab",
|
||||
width: "12%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NAMA",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "name",
|
||||
width: "20%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "VERIFIKASI",
|
||||
align: "center",
|
||||
sortable: false,
|
||||
value: "status",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
}
|
||||
],
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,250 @@
|
||||
<template>
|
||||
<div>
|
||||
<v-layout row>
|
||||
<v-flex xs12 pb-2>
|
||||
<v-card >
|
||||
<v-subheader>
|
||||
DATA COMPANY MOU
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-flex pt-2 xs12>
|
||||
<v-layout>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="Nama Company"
|
||||
placeholder=""
|
||||
:value="getField(patient.M_CompanyName)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs6 pl-5 pr-3>
|
||||
<v-text-field
|
||||
label="MOU"
|
||||
placeholder=""
|
||||
:value="getField(patient.mou)"
|
||||
readonly
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
<v-flex xs12 pb-2>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 pa-2 v-for="(vcm,idx) in vcompanymou" :key="vcm.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vcm.label"
|
||||
:xdatacbx="vcm.chex"
|
||||
:xdatatxt="vcm.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentCompanyMou(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentCompanyMou(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout class="fill-height" row>
|
||||
<v-flex xs12>
|
||||
<v-card class="pa-1 grow">
|
||||
<v-subheader red--text text--lighten-1> DATA PEMERIKSAAN
|
||||
<v-flex text-md-right>
|
||||
<v-btn v-if="vlaststatus === '2'" small @click="openDialogPx()" color="primary">Tambah Pemeriksaan</v-btn>
|
||||
<one-verification-dialog-px @add-data-px="(cval) => updateDataParentPx(cval)"></one-verification-dialog-px>
|
||||
</v-flex>
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12 class="pt-2">
|
||||
<v-layout row wrap>
|
||||
<v-flex class="border-bottom-dashed" xs12 pt-2 pl-4 pr-4 pb-4>
|
||||
<table>
|
||||
<tr>
|
||||
<th width="5%" class="text-md-center pt-2 pb-2">#</th>
|
||||
<th width="8%" class="text-md-center pt-2 pb-2"> CITO </th>
|
||||
<th class="text-md-center pt-2 pb-2">PEMERIKSAAN</th>
|
||||
<th class="text-md-center pt-2 pb-2">BRUTO</th>
|
||||
<th class="text-md-center pt-2 pb-2">DISKON</th>
|
||||
<th class="text-md-center pt-2 pb-2">TOTAL</th>
|
||||
</tr>
|
||||
<tr class="mini-input" v-for="(vpx,idx) in vtest">
|
||||
<td style="text-align:center;vertical-align:center;" align="center">
|
||||
|
||||
<v-checkbox v-if="vpx.addon == false"
|
||||
v-model="vpx.chex"
|
||||
@change="updateDataCbxParentPx(idx,vpx.chex)"
|
||||
class="pa-0" >
|
||||
</v-checkbox>
|
||||
<v-icon v-else-if="vpx.addon == true" color="red" @click="deleteDataParentPx(idx)">delete</v-icon>
|
||||
</td>
|
||||
<td style="text-align:center;vertical-align:center;" align="center" > <v-icon v-if="vpx.flagcito == 'Y'" large color="green darken-2">check</v-icon></td>
|
||||
<td class="text-md-left pl-3">{{vpx.pxname}}</td>
|
||||
<td class="text-md-right pr-2">{{convertMoney(vpx.bruto)}}</td>
|
||||
<td class="text-md-right pr-2">{{convertMoney(vpx.discount)}}</td>
|
||||
<td class="text-md-right pr-2">{{convertMoney(vpx.total)}}</td>
|
||||
</tr>
|
||||
</table>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs12 class="pl-4 pr-4 pt-2">
|
||||
<v-layout row wrap>
|
||||
<v-flex xs12 pl-2 pt-2 pb-2 v-for="(vi,idx) in vinfo" :key="vi.id">
|
||||
<one-field-verification-patient-doctor
|
||||
:xdatalabel="vi.label"
|
||||
:xdatacbx="vi.chex"
|
||||
:xdatatxt="vi.note"
|
||||
@update-data-txt="(val) => updateDataTxtParentInfo(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentInfo(idx,val)"
|
||||
></one-field-verification-patient-doctor>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
|
||||
<one-dialog-info :status="xdialoginfo" :msg="msginfo" @close-dialog-info="closeInfo()"></one-dialog-info>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
table {
|
||||
font-family: arial, sans-serif;
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
background:white;
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
th, td {
|
||||
border: 1px solid black;
|
||||
border-collapse: collapse;
|
||||
padding-top: 2px;
|
||||
padding-bottom: 2px;
|
||||
}
|
||||
table>tr>td {
|
||||
padding: 8px;
|
||||
}
|
||||
table>tr>td:first {
|
||||
padding-left:15px!important;
|
||||
}
|
||||
.mini-input .v-input{
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
.mini-input .v-input, .mini-input .v-input--selection-controls,.mini-input .v-input__slot{
|
||||
margin-top: 0px;
|
||||
margin-bottom:0px;
|
||||
margin-left:3px;
|
||||
}
|
||||
.mini-input .v-messages{
|
||||
min-height:0px;
|
||||
}
|
||||
|
||||
.border-bottom-dashed{
|
||||
border-bottom : 1px dashed rgba(0,0,0,.12);
|
||||
}
|
||||
</style>
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-fo-verification-mou-px-curr-order' : httpVueLoader('./oneFoVerificationMouPxCurrOrder.vue'),
|
||||
'one-fo-verification-mou-px-add-order' : httpVueLoader('./oneFoVerificationMouPxAddOrder.vue'),
|
||||
'one-field-verification' : httpVueLoader('./oneFieldVerification.vue'),
|
||||
'one-field-verification-patient-doctor':httpVueLoader('../../common/oneFieldVerificationPatientDoctor.vue'),
|
||||
'one-verification-dialog-px' : httpVueLoader('./oneFoVerificationDialogPx.vue')
|
||||
},
|
||||
methods: {
|
||||
getField(inp) {
|
||||
if ( this.patient != undefined) {
|
||||
return inp
|
||||
}
|
||||
return ''
|
||||
},
|
||||
updateDataTxtParentCompanyMou(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_company_mou",prm)
|
||||
},
|
||||
updateDataCbxParentCompanyMou(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_company_mou",prm)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
updateDataTxtParentInfo(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_info",prm)
|
||||
},
|
||||
updateDataCbxParentInfo(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_info",prm)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
updateDataCbxParentPx(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_cbx_parent_px",prm)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
deleteDataParentPx(idx){
|
||||
var inx = parseInt(idx);
|
||||
var oldArr = this.$store.state.patient.selected_patient
|
||||
oldArr.verification_px.splice(inx,1)
|
||||
|
||||
this.$store.commit("patient/update_selected_patient",oldArr)
|
||||
},
|
||||
openDialogPx(){
|
||||
this.$store.commit('px/update_dialog_px_is_active',true)
|
||||
},
|
||||
updateDataParentPx(valx){
|
||||
//console.log(valx)
|
||||
var oldArr = this.$store.state.patient.selected_patient
|
||||
oldArr.verification_px.push(valx)
|
||||
this.$store.commit("patient/update_selected_patient",oldArr)
|
||||
this.$store.commit("px/update_search","")
|
||||
this.$store.commit("px/update_pxs",{})
|
||||
this.$store.commit("px/update_selected_px",{})
|
||||
this.$store.commit("px/update_search_status",0)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
companyChange : function(val) {
|
||||
if (val == true)
|
||||
this.n_company_false = "";
|
||||
console.log(val)
|
||||
|
||||
},
|
||||
convertMoney(money){
|
||||
return one_money(money)
|
||||
}
|
||||
},
|
||||
computed : {
|
||||
vlaststatus() {
|
||||
return this.$store.state.patient.selected_patient.check_status
|
||||
},
|
||||
patient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vcompanymou() {
|
||||
return this.$store.state.verification.verification_companymou
|
||||
},
|
||||
vtest() {
|
||||
return this.$store.state.verification.verification_px
|
||||
},
|
||||
vinfo() {
|
||||
return this.$store.state.verification.verification_info
|
||||
},
|
||||
__company () {
|
||||
return this.$data._company;
|
||||
},
|
||||
|
||||
__mou () {
|
||||
return this.$data._mou;
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,88 @@
|
||||
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-data-table :headers="headers" :items="orders"
|
||||
:loading="isLoading"
|
||||
hide-actions class="elevation-1">
|
||||
<template slot="items" slot-scope="props">
|
||||
<td class="text-xs-left pa-2" >
|
||||
<v-btn color="red" dark class="pt-0 pb-0 pl-1 pr-1 mt-0 mb-0 mr-2 ml-0" small>
|
||||
<v-icon dark>delete</v-icon>
|
||||
</v-btn>
|
||||
{{ props.item.px }}</td>
|
||||
<td class="text-xs-right pa-2" >{{ props.item.bruto }}</td>
|
||||
<td class="text-xs-right pa-2">{{ props.item.disc }}</td>
|
||||
<td class="text-xs-right pa-2">{{ props.item.total }}</td>
|
||||
</template>
|
||||
|
||||
</v-data-table>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
table.v-table tbody td,table.v-table tbody th {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
table.v-table thead tr {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
.v-btn {
|
||||
min-width: auto;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
data () {
|
||||
return {
|
||||
headers: [
|
||||
{
|
||||
text: "PEMERIKSAAN",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "px",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "BRUTO",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "bruto",
|
||||
width: "25%",
|
||||
class: "text-xs-right pa-2 blue lighten-3 white--text",
|
||||
width: "15%"
|
||||
},
|
||||
{
|
||||
text: "DISKON",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "disc",
|
||||
class: "text-xs-right pa-2 blue lighten-3 white--text",
|
||||
width: "15%"
|
||||
},
|
||||
{
|
||||
text: "TOTAL",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "total",
|
||||
class: "text-xs-right pa-2 blue lighten-3 white--text",
|
||||
width: "15%"
|
||||
}
|
||||
],
|
||||
query : "",
|
||||
|
||||
isLoading: true,
|
||||
orders: [
|
||||
// {"px":"Hemoglobin", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
// {"px":"Trombosit", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
// {"px":"Eritrosit", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
{"px":"SGOT", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
{"px":"SGPT", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
{"px":"Urine Lengkap", "bruto":"30,000", "disc":"10,000", "total":"20,000"}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,83 @@
|
||||
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-data-table :headers="headers" :items="orders"
|
||||
:loading="isLoading"
|
||||
hide-actions class="elevation-1">
|
||||
<template slot="items" slot-scope="props">
|
||||
<td class="text-xs-left pa-2" >
|
||||
|
||||
<v-checkbox :label="`${props.item.px}`"></v-checkbox>
|
||||
</td>
|
||||
<td class="text-xs-right pa-2" >{{ props.item.bruto }}</td>
|
||||
<td class="text-xs-right pa-2">{{ props.item.disc }}</td>
|
||||
<td class="text-xs-right pa-2">{{ props.item.total }}</td>
|
||||
</template>
|
||||
|
||||
</v-data-table>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
table.v-table tbody td,table.v-table tbody th {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
table.v-table thead tr {
|
||||
height: 40px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
data () {
|
||||
return {
|
||||
headers: [
|
||||
{
|
||||
text: "PEMERIKSAAN",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "px",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "BRUTO",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "bruto",
|
||||
width: "25%",
|
||||
class: "text-xs-right pa-2 blue lighten-3 white--text",
|
||||
width: "15%"
|
||||
},
|
||||
{
|
||||
text: "DISKON",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "disc",
|
||||
class: "text-xs-right pa-2 blue lighten-3 white--text",
|
||||
width: "15%"
|
||||
},
|
||||
{
|
||||
text: "TOTAL",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "total",
|
||||
class: "text-xs-right pa-2 blue lighten-3 white--text",
|
||||
width: "15%"
|
||||
}
|
||||
],
|
||||
query : "",
|
||||
|
||||
isLoading: true,
|
||||
orders: [
|
||||
{"px":"Hemoglobin", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
{"px":"Trombosit", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
{"px":"Eritrosit", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
// {"px":"SGOT", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
// {"px":"SGPT", "bruto":"30,000", "disc":"10,000", "total":"20,000"},
|
||||
// {"px":"Urine Lengkap", "bruto":"30,000", "disc":"10,000", "total":"20,000"}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,558 @@
|
||||
<template>
|
||||
<v-layout class="fill-height" column>
|
||||
<v-dialog v-model="dialogsuccess" persistent max-width="450">
|
||||
<v-card>
|
||||
<v-card-title color="success" class="headline">Berhasil !</v-card-title>
|
||||
<v-card-text>
|
||||
{{msgsuccess}}
|
||||
</v-card-text>
|
||||
<v-card-actions>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn color="green darken-1" flat @click="closeDialogSuccess">OK</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
<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()">OK</v-btn>
|
||||
<v-btn color="error darken-1" flat @click="xdialogaction = false">Tutup</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
<v-dialog v-model="dialogbarcode" persistent max-width="490">
|
||||
<v-card>
|
||||
<v-card-title style="color:#fff" class="headline grey darken-1">Cetak Barcode</v-card-title>
|
||||
<v-card-text>
|
||||
<v-layout pa-2 class="grey lighten-2" row>
|
||||
<v-flex xs1>
|
||||
<v-checkbox style="padding-top:0;margin-top:0"
|
||||
hide-details
|
||||
color="grey darken-1"
|
||||
:indeterminate="indeterminatex"
|
||||
@change="changeCbxAll(bar_chx_all)"
|
||||
v-model="bar_chx_all"
|
||||
></v-checkbox>
|
||||
</v-flex>
|
||||
<v-flex xs5>
|
||||
SPECIMEN
|
||||
</v-flex>
|
||||
<v-flex xs4>
|
||||
BARCODE
|
||||
</v-flex>
|
||||
<v-flex xs2>
|
||||
CETAK
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout align-center pa-2 v-for="(vs,idx) in barcodes" :key="vs.id" class="grey lighten-4" row>
|
||||
|
||||
<v-flex xs1>
|
||||
<v-checkbox style="padding-top:0;margin-top:0"
|
||||
color="grey darken-1"
|
||||
hide-details
|
||||
v-model="vs.chex"
|
||||
@change="checkTop()"
|
||||
></v-checkbox>
|
||||
</v-flex>
|
||||
<v-flex class="text-xs-left" xs1>
|
||||
<v-btn @click="addNewLabel(vs)" small style="margin:0;min-width:15px" class="white--text" color="grey darken-1"><v-icon small>add</v-icon></v-btn>
|
||||
</v-flex>
|
||||
<v-flex xs4>
|
||||
{{vs.T_SampleTypeName}}
|
||||
</v-flex>
|
||||
<v-flex xs4>
|
||||
{{vs.T_BarcodeLabBarcode}}
|
||||
</v-flex>
|
||||
<v-flex xs2>
|
||||
<span @click="printSingleBarcode(vs)" class="icon-medium-fill-base-small xs1 white--text grey darken-1 ml-1 icon-print"></span>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card-text>
|
||||
<v-card-actions>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn color="grey darken-1" flat @click="dialogbarcode = false">Tutup</v-btn>
|
||||
<v-btn dark color="grey darken-3" @click="printRobo">Cetak Robo </v-btn>
|
||||
<v-btn dark color="grey darken-1" @click="printMultipleBarcode">Cetak terpilih [ {{selected_barcode.length}} ]</v-btn>
|
||||
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
<v-card class="mb-2 pa-2 searchbox">
|
||||
<v-layout row >
|
||||
<v-flex xs4 pr-2>
|
||||
<v-menu
|
||||
v-model="menufilterdatestart"
|
||||
:close-on-content-click="false"
|
||||
:nudge-right="40"
|
||||
lazy
|
||||
transition="scale-transition"
|
||||
offset-y
|
||||
full-width
|
||||
max-width="290px"
|
||||
min-width="290px"
|
||||
>
|
||||
<template v-slot:activator="{ on }">
|
||||
<v-text-field
|
||||
class="mt-1"
|
||||
v-model="filterComputedDateFormattedStart"
|
||||
label="Tanggal Awal"
|
||||
outline
|
||||
hide-details
|
||||
readonly
|
||||
v-on="on"
|
||||
@blur="date = deFormatedDate(filterComputedDateFormattedStart)"
|
||||
></v-text-field>
|
||||
</template>
|
||||
<v-date-picker v-model="xdatestart" no-title @input="menufilterdatestart = false"></v-date-picker>
|
||||
</v-menu>
|
||||
</v-flex>
|
||||
<v-flex xs4 pr-2>
|
||||
<v-menu
|
||||
v-model="menufilterdateend"
|
||||
:close-on-content-click="false"
|
||||
:nudge-right="40"
|
||||
lazy
|
||||
transition="scale-transition"
|
||||
offset-y
|
||||
full-width
|
||||
max-width="290px"
|
||||
min-width="290px"
|
||||
>
|
||||
<template v-slot:activator="{ on }">
|
||||
<v-text-field
|
||||
class="mt-1"
|
||||
v-model="filterComputedDateFormattedEnd"
|
||||
label="Tanggal Akhir"
|
||||
outline
|
||||
readonly
|
||||
hide-details
|
||||
v-on="on"
|
||||
@blur="date = deFormatedDate(filterComputedDateFormattedEnd)"
|
||||
></v-text-field>
|
||||
</template>
|
||||
<v-date-picker v-model="xdateend" no-title @input="menufilterdateend = false"></v-date-picker>
|
||||
</v-menu>
|
||||
</v-flex>
|
||||
<v-flex xs4 mt-1>
|
||||
<v-text-field
|
||||
|
||||
label="No Reg / Nama"
|
||||
outline
|
||||
v-on:keyup.enter="searchTransaction"
|
||||
v-model="search"
|
||||
hide-details
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<!--<span @click="searchTransaction" class="icon-medium-fill-base xs1 white--text success iconsearch-search"></span>-->
|
||||
|
||||
</v-layout>
|
||||
</v-card>
|
||||
<v-card >
|
||||
<v-layout row>
|
||||
<v-flex xs12 pl-2 pr-2 pt-2 pb-2>
|
||||
<v-data-table
|
||||
:headers="headers"
|
||||
:items="xtransactions"
|
||||
: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.M_PatientNoReg }}</td>
|
||||
<td class="pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item)}" @click="selectMe(props.item)">{{ props.item.T_OrderHeaderLabNumber}}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item)}" @click="selectMe(props.item)">{{ props.item.M_PatientName}}</td>
|
||||
<td class="text-xs-center pa-2" v-bind:class="{'amber lighten-4':isSelected(props.item)}" @click="selectMe(props.item)">
|
||||
<v-btn dark color="grey darken-1" small @click="openbarcodeprint(props.item)">Cetak Barcode</v-btn>
|
||||
</td>
|
||||
</template>
|
||||
</v-data-table>
|
||||
<v-divider></v-divider>
|
||||
<v-pagination
|
||||
style="margin-top:10px;margin-bottom:10px"
|
||||
v-model="curr_page"
|
||||
:length="xtotal_page"
|
||||
|
||||
|
||||
></v-pagination>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
<one-dialog-alert :status="openalertconfirmation" :msg="msgalertconfirmation" @forget-dialog-alert="forgetAlertConfirmation()" @close-dialog-alert="closeAlertConfirmation()"></one-dialog-alert>
|
||||
<one-dialog-info :status="opendialoginfo" :msg="msginfo" @close-dialog-info="closeDialogInfo()"></one-dialog-info>
|
||||
</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;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-dialog-info':httpVueLoader('../../common/oneDialogInfo.vue'),
|
||||
'one-dialog-alert':httpVueLoader('../../common/oneDialogAlert.vue')
|
||||
},
|
||||
mounted() {
|
||||
//this.$store.dispatch("form/getalmaries")
|
||||
this.$store.dispatch("done/search",{
|
||||
startdate:this.xdatestart,
|
||||
enddate: this.xdateend,
|
||||
search:this.search,
|
||||
current_page:1,
|
||||
lastid:-1
|
||||
})
|
||||
},
|
||||
methods : {
|
||||
addNewLabel(sampletype){
|
||||
this.$store.commit("done/update_selected_sampletype",sampletype)
|
||||
var sample = sampletype.T_SampleTypeName
|
||||
var patient = this.$store.state.done.selected_transaction
|
||||
console.log(patient)
|
||||
var msg = "Anda yakin akan melakukan penambahan label spesimen "+sample+" untuk pasien "+patient.M_PatientName+" ? "
|
||||
this.$store.commit("done/update_msg_action",msg)
|
||||
this.$store.commit("done/update_dialog_action",true)
|
||||
},
|
||||
changeCbxAll(value){
|
||||
var arr = this.barcodes
|
||||
this.indeterminatex = false
|
||||
arr.forEach((el)=>{el.chex = value})
|
||||
var selected = _.filter(arr, function(o) { return o.chex; })
|
||||
this.selected_barcode = selected
|
||||
},
|
||||
printSingleBarcode(value){
|
||||
var label = value.T_BarcodeLabBarcode
|
||||
if(value.type === 'barcode')
|
||||
one_print_barcode_pk(label)
|
||||
else
|
||||
one_print_barcode_formulir(value.id)
|
||||
},
|
||||
printRobo() {
|
||||
var arr = this.barcodes
|
||||
var xarrtojoin = []
|
||||
_.forEach(arr, function(value) {
|
||||
if( value.type === 'barcode'){
|
||||
xarrtojoin.push(value.T_BarcodeLabBarcode)
|
||||
}
|
||||
})
|
||||
if(xarrtojoin.length > 0 ){
|
||||
one_print_robo(xarrtojoin.join(','))
|
||||
}
|
||||
},
|
||||
printMultipleBarcode(){
|
||||
var arr = this.barcodes
|
||||
var xarrtojoin = []
|
||||
var xformulir = {}
|
||||
_.forEach(arr, function(value) {
|
||||
//console.log(value)
|
||||
if(value.chex && value.type === 'barcode'){
|
||||
xarrtojoin.push(value.T_BarcodeLabBarcode)
|
||||
}
|
||||
if(value.chex && value.type === 'formulir'){
|
||||
xformulir = value
|
||||
}
|
||||
})
|
||||
if(xarrtojoin.length > 0 ){
|
||||
one_print_barcode_pk(xarrtojoin.join(','))
|
||||
}
|
||||
|
||||
if(!_.isEmpty(xformulir)){
|
||||
//console.log("oeoeooeoe")
|
||||
one_print_barcode_formulir(xformulir.id)
|
||||
}
|
||||
|
||||
},
|
||||
formatDate (date) {
|
||||
if (!date) return null
|
||||
|
||||
const [year, month, day] = date.split('-')
|
||||
return `${day}-${month}-${year}`
|
||||
},
|
||||
deFormatedDate (date) {
|
||||
if (!date) return null
|
||||
|
||||
const [ day,month, year] = date.split('-')
|
||||
return `${year}-${month.padStart(2, '0')}-${day.padStart(2, '0')}`
|
||||
},
|
||||
isSelected(p) {
|
||||
return p.ohid == this.$store.state.done.selected_transaction.ohid
|
||||
},
|
||||
searchTransaction() {
|
||||
this.$store.dispatch("done/search",{
|
||||
startdate:this.xdatestart,
|
||||
enddate: this.xdateend,
|
||||
search:this.search,
|
||||
current_page:1,
|
||||
lastid:-1
|
||||
})
|
||||
},
|
||||
selectMe(trx) {
|
||||
if(this.$store.state.done.no_save == 0 ){
|
||||
console.log(trx)
|
||||
this.$store.commit("done/update_selected_transaction",trx)
|
||||
this.$store.commit("done/update_act",'edit')
|
||||
|
||||
}else{
|
||||
this.$store.commit("done/update_open_alert_confirmation",true)
|
||||
}
|
||||
},
|
||||
closeAlertConfirmation(){
|
||||
this.$store.commit("done/update_open_alert_confirmation",false)
|
||||
},
|
||||
forgetAlertConfirmation(){
|
||||
this.$store.commit("done/update_no_save",0)
|
||||
this.$store.commit("done/update_open_alert_confirmation",false)
|
||||
},
|
||||
updateAlert_success(val){
|
||||
this.$store.commit("done/update_alert_success",val)
|
||||
},
|
||||
setNewTransaction(){
|
||||
this.$store.commit("done/update_selected_transaction",{})
|
||||
this.$store.commit("done/update_act",'new')
|
||||
|
||||
},
|
||||
closeDialogSuccess(){
|
||||
let arrtrx = this.$store.state.done.transactions
|
||||
var idx = _.findIndex(arrtrx, item => item.T_SampleStorageID === this.$store.state.done.last_id)
|
||||
console.log(idx)
|
||||
this.$store.dispatch("done/search",{
|
||||
startdate:this.xdatestart,
|
||||
enddate: this.xdateend,
|
||||
search:this.search,
|
||||
current_page:1,
|
||||
lastid: idx
|
||||
})
|
||||
this.$store.commit("done/update_dialog_success",false)
|
||||
},
|
||||
closeDialogInfo(){
|
||||
this.$store.commit("done/update_open_dialog_info",false)
|
||||
},
|
||||
openbarcodeprint(value){
|
||||
this.bar_chx_all = false
|
||||
this.indeterminatex = false
|
||||
this.dialogbarcode = true
|
||||
this.selected_barcode = []
|
||||
this.$store.dispatch("patient/lookup_barcodes",value)
|
||||
},
|
||||
checkTop(){
|
||||
var barcodes = this.barcodes
|
||||
var selected = _.filter(barcodes, function(o) { return o.chex; })
|
||||
this.bar_chx_all = false
|
||||
this.indeterminatex = false
|
||||
if(selected.length > 0 && barcodes.length === selected.length){
|
||||
this.bar_chx_all = true
|
||||
this.indeterminatex = false
|
||||
}
|
||||
if(selected.length > 0 && barcodes.length > selected.length){
|
||||
this.bar_chx_all = false
|
||||
this.indeterminatex = true
|
||||
}
|
||||
this.selected_barcode = selected
|
||||
|
||||
},
|
||||
closeDialogAction(){
|
||||
var prm = this.$store.state.done.selected_sampletype
|
||||
this.$store.dispatch("patient/addnewlabel",prm)
|
||||
|
||||
},
|
||||
|
||||
},
|
||||
computed: {
|
||||
xdialogaction:{
|
||||
get() {
|
||||
return this.$store.state.done.dialog_action
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_dialog_action",val)
|
||||
}
|
||||
},
|
||||
xmsgaction:{
|
||||
get() {
|
||||
return this.$store.state.done.msg_action
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_msg_action",val)
|
||||
}
|
||||
},
|
||||
search: {
|
||||
get() {
|
||||
return this.$store.state.done.search
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_search",val)
|
||||
}
|
||||
},
|
||||
dialogsuccess: {
|
||||
get() {
|
||||
return this.$store.state.done.dialog_success
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_dialog_success",val)
|
||||
}
|
||||
},
|
||||
msgsuccess(){
|
||||
return this.$store.state.done.msg_success
|
||||
},
|
||||
snackbar: {
|
||||
get() {
|
||||
return this.$store.state.done.alert_success
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_alert_success",val)
|
||||
}
|
||||
},
|
||||
barcodes: {
|
||||
get() {
|
||||
return this.$store.state.patient.barcodes
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_patient_barcodes",val)
|
||||
}
|
||||
},
|
||||
isLoading() {
|
||||
return this.$store.state.done.search_status == 1
|
||||
},
|
||||
xdatestart : {
|
||||
get() {
|
||||
return this.$store.state.done.start_date
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_start_date",val)
|
||||
this.searchTransaction()
|
||||
}
|
||||
},
|
||||
xdateend : {
|
||||
get() {
|
||||
return this.$store.state.done.end_date
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_end_date",val)
|
||||
this.searchTransaction()
|
||||
}
|
||||
},
|
||||
filterComputedDateFormattedStart () {
|
||||
return this.formatDate(this.xdatestart)
|
||||
},
|
||||
filterComputedDateFormattedEnd () {
|
||||
return this.formatDate(this.xdateend)
|
||||
},
|
||||
xtransactions() {
|
||||
console.log(this.$store.state.done.transactions)
|
||||
return this.$store.state.done.transactions
|
||||
},
|
||||
openalertconfirmation: {
|
||||
get() {
|
||||
return this.$store.state.done.open_alert_confirmation
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_open_alert_confirmation",val)
|
||||
}
|
||||
},
|
||||
opendialoginfo: {
|
||||
get() {
|
||||
return this.$store.state.done.open_dialog_info
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_open_dialog_info",false)
|
||||
}
|
||||
},
|
||||
msginfo(){
|
||||
return this.$store.state.done.msg_info
|
||||
},
|
||||
curr_page: {
|
||||
get() {
|
||||
return this.$store.state.done.current_page
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_current_page",val)
|
||||
this.$store.dispatch("done/search",{
|
||||
startdate:this.xdatestart,
|
||||
enddate: this.xdateend,
|
||||
current_page:val,
|
||||
lastid:-1
|
||||
})
|
||||
}
|
||||
},
|
||||
xtotal_page: {
|
||||
get() {
|
||||
return this.$store.state.done.total_page
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("done/update_total_page",val)
|
||||
}
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
msgalertconfirmation:"Perubahan yang telah dilakukan belum disimpan dong !",
|
||||
menufilterdatestart:false,
|
||||
menufilterdateend:false,
|
||||
dialogbarcode:false,
|
||||
date: new Date().toISOString().substr(0, 10),
|
||||
items: [],
|
||||
name: '',
|
||||
page:1,
|
||||
indeterminatex:false,
|
||||
checkednotall:false,
|
||||
bar_chx_all:false,
|
||||
selected_barcode:[],
|
||||
headers: [
|
||||
{
|
||||
text: "PID",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "10%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NO REG",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "lab",
|
||||
width: "12%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NAMA",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "name",
|
||||
width: "20%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "AKSI",
|
||||
align: "center",
|
||||
sortable: false,
|
||||
value: "status",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
}
|
||||
],
|
||||
pagination:{
|
||||
descending: false,
|
||||
page: 1,
|
||||
rowsPerPage: 5,
|
||||
sortBy: 'T_SampleStorageDate',
|
||||
totalItems: this.$store.state.done.total_transactions
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,177 @@
|
||||
<template>
|
||||
<v-layout fil-height column>
|
||||
<v-dialog v-model="dialogvalidation" persistent width="300">
|
||||
<v-card>
|
||||
<v-card-title class="headline">Peringatan !</v-card-title>
|
||||
<v-card-text>
|
||||
<v-alert v-for="item in msgdialogvalidation"
|
||||
:value="true"
|
||||
type="error"
|
||||
>
|
||||
{{item}} [ Belum ada alasan ]
|
||||
</v-alert>
|
||||
</v-card-text>
|
||||
<v-card-actions>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn color="green darken-1" flat @click="dialogvalidation = false">OK</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
<v-dialog v-model="dialoglist" persistent width="350">
|
||||
<v-card>
|
||||
<v-card-title style="font-size: 18px;padding-left: 12px;padding-top: 8px">Pilih data yang belum sesuai</v-card-title>
|
||||
<v-card-text>
|
||||
<v-layout wrap>
|
||||
<v-flex xs12 pa-2 v-for="(vp,idx) in vdoctor" :key="vp.id">
|
||||
<v-layout pl-2 row>
|
||||
<v-flex xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-1 xs2>
|
||||
<span @click="changeCheck(vp.chex,idx)" v-if="vp.chex === true" style="background: rgb(252, 252, 252);border: 2px solid #767575;" class="icon-medium-fill-base-small white--text"></span>
|
||||
<span @click="changeCheck(vp.chex,idx)" v-if="vp.chex === false" style="background:#9e9e9e7a" class="icon-medium-fill-base-small white--text red"><v-icon dark>close</v-icon></span>
|
||||
</v-flex>
|
||||
<v-flex xs12>
|
||||
<v-text-field
|
||||
:label="vp.label"
|
||||
hide-details
|
||||
placeholder="Isikan alasan di sini"
|
||||
v-model="vp.note"
|
||||
outline
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card-text>
|
||||
<v-card-actions>
|
||||
<v-spacer></v-spacer>
|
||||
<v-btn color="black" flat @click="closeDialogTolak()">Tutup</v-btn>
|
||||
<v-btn v-if="seen_button" color="primary darken-1" flat @click="tolak()">Simpan</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification' : httpVueLoader('../../common/oneFieldVerification.1.vue'),
|
||||
'one-testing-component':httpVueLoader('../../common/oneTestingComponent.vue'),
|
||||
'one-field-verification-patient-doctor':httpVueLoader('../../common/oneFieldVerificationPatientDoctor.vue')
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
dialogvalidation: false,
|
||||
msgdialogvalidation:[]
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
patient_age() {
|
||||
if ( this.patient == undefined) {
|
||||
return ''
|
||||
}
|
||||
return window.calculate_age(this.patient.M_PatientDOB)
|
||||
},
|
||||
xshow() {
|
||||
return this.$store.state.patient.show_right
|
||||
},
|
||||
patient() {
|
||||
return this.$store.state.patient.selected_patient
|
||||
},
|
||||
vpatient() {
|
||||
return this.$store.state.verification.verification_patient
|
||||
},
|
||||
vdoctor() {
|
||||
return this.$store.state.patient.verifications
|
||||
},
|
||||
status(){
|
||||
return this.$store.state.status.selected_status
|
||||
},
|
||||
seen_button: {
|
||||
get() {
|
||||
return this.$store.state.patient.btn_save_seen
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_btn_save_seen",val)
|
||||
}
|
||||
},
|
||||
dialoglist: {
|
||||
get() {
|
||||
return this.$store.state.patient.dialoglist
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("patient/update_dialoglist",val)
|
||||
}
|
||||
},
|
||||
},
|
||||
methods : {
|
||||
closeDialogTolak(){
|
||||
this.dialoglist = false
|
||||
this.seen_button = true
|
||||
},
|
||||
changeCheck(val,idx){
|
||||
this.seen_button = false
|
||||
var xxx = this.$store.state.patient.verifications
|
||||
var xnew = val === true ?false:true
|
||||
xxx[idx].chex = xnew
|
||||
this.$store.commit("patient/update_verifications",xxx)
|
||||
var xtolak = _.filter(xxx, function(o) { return !o.chex })
|
||||
if(xtolak.length > 0)
|
||||
this.seen_button = true
|
||||
},
|
||||
updateDataTxtParentDoctor(idx, val) {
|
||||
var verifications = this.$store.state.patient.verifications
|
||||
verifications[idx].note = val
|
||||
this.$store.commit("patient/update_verifications",verifications)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
updateDataCbxParentDoctor(idx, val) {
|
||||
var verifications = this.$store.state.patient.verifications
|
||||
verifications[idx].chex = val
|
||||
this.$store.commit("patient/update_verifications",verifications)
|
||||
var xcount = this.$store.state.patient.no_save + 1
|
||||
this.$store.commit("patient/update_no_save",xcount)
|
||||
},
|
||||
tolak(){
|
||||
var xerrors = []
|
||||
var allArr = this.$store.state.patient.selected_patient
|
||||
allArr.verifications.forEach(function(value) {
|
||||
if(value.chex === false && value.note === "")
|
||||
xerrors.push(value.label);
|
||||
});
|
||||
|
||||
if(xerrors.length === 0){
|
||||
var prm = this.$store.state.patient.selected_patient
|
||||
prm.act = 'N'
|
||||
prm.name = this.$store.state.patient.name
|
||||
prm.nolab = this.$store.state.patient.nolab
|
||||
this.$store.commit("done/update_current_page",1)
|
||||
prm.done_search = {
|
||||
startdate:this.$store.state.done.start_date,
|
||||
enddate:this.$store.state.done.end_date,
|
||||
search:this.$store.state.done.search,
|
||||
current_page:1,
|
||||
lastid:-1
|
||||
}
|
||||
this.$store.dispatch("patient/verify",prm)
|
||||
}
|
||||
else{
|
||||
var msg = ""
|
||||
xerrors.forEach(function(value) {
|
||||
msg += '<v-alert :value="true" type="error">'+value+'</v-alert>'
|
||||
});
|
||||
this.msgdialogvalidation = xerrors
|
||||
this.dialogvalidation = true
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,43 @@
|
||||
<template>
|
||||
|
||||
<div>
|
||||
<v-card>
|
||||
<v-btn class= "button parallelogram" color="success">Pasien Dokter</v-btn>
|
||||
<v-btn class= "button parallelogram" color="warning">MOU </v-btn>
|
||||
<v-btn class= "button parallelogram" color="error">Kirim Hasil </v-btn>
|
||||
<v-btn class= "button parallelogram" color="info"> Barcode</v-btn>
|
||||
</v-card>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
|
||||
.v-card{
|
||||
text-align: center;
|
||||
}
|
||||
.v-btn__content{
|
||||
margin-top : -10px;
|
||||
}
|
||||
.button {
|
||||
|
||||
padding: 30px 16px;
|
||||
width : 20%;
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
.parallelogram{
|
||||
transform: skew(-20deg);
|
||||
|
||||
}
|
||||
|
||||
.v-btn {
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
</style>
|
||||
<script>
|
||||
module.exports = {
|
||||
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,55 @@
|
||||
<template>
|
||||
<v-layout column mb-2 >
|
||||
<v-card>
|
||||
<v-layout row>
|
||||
<v-flex xs12>
|
||||
<v-subheader red--text text--lighten-1> SUPPLIES</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout class="layout-supplies" row wrap>
|
||||
<v-flex v-for="supply in supplies" xs3 pa-1 pt-0>
|
||||
<one-field-verification-supply
|
||||
:label="supply.name"
|
||||
:value="supply.checked"
|
||||
@x_change="cbxChange"
|
||||
:note="1"
|
||||
></one-field-verification-supply>
|
||||
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-flex>
|
||||
</v-card>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.v-messages, .v-text-field__details{
|
||||
min-height:0px!important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification-supply' : httpVueLoader('../../common/oneFieldVerificationSupply.vue')
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
supplies :[
|
||||
{"id":"1","name":"Sedotan Tinja","qty":0,"checked":false},
|
||||
{"id":"2","name":"Jarum Suntik","qty":0,"checked":false}
|
||||
]
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
cbxChange : function(val) {
|
||||
console.log(val);
|
||||
}
|
||||
},
|
||||
computed : {
|
||||
_email () {
|
||||
return this.$data._email;
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,88 @@
|
||||
<template>
|
||||
<v-layout column mb-2 >
|
||||
<v-card>
|
||||
<v-subheader>
|
||||
DATA SUPPLIES
|
||||
<v-flex text-md-right>
|
||||
<v-btn v-if="btnsaveseen" small @click="saveSupplies()" color="primary">Simpan</v-btn>
|
||||
<v-progress-linear v-if="pgrssave" :indeterminate="true"></v-progress-linear>
|
||||
<one-dialog-alert :status="openalertsupplies" :msg="msgalertsupplies" @forget-dialog-alert="forgetAlertSupplies()" @close-dialog-alert="closeAlertSupplies()"></one-dialog-alert>
|
||||
</v-flex>
|
||||
</v-subheader>
|
||||
<v-divider></v-divider>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs4 pa-2 v-for="(vs,idx) in vsupplies" :key="vs.id">
|
||||
<one-field-verification-supply
|
||||
:xdatalabel="vs.name"
|
||||
:xdatacbx="vs.chex"
|
||||
:xdatatxt="vs.qty"
|
||||
@update-data-txt="(val) => updateDataTxtParentSupplies(idx,val)"
|
||||
@update-data-cbx="(val) => updateDataCbxParentSupplies(idx,val)"
|
||||
></one-field-verification-supply>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
</v-layout>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.v-messages, .v-text-field__details{
|
||||
min-height:0px!important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'one-field-verification-supply':httpVueLoader('../../common/oneFieldVerificationSupply.vue'),
|
||||
'one-dialog-alert':httpVueLoader('../../common/oneDialogAlert.vue')
|
||||
},
|
||||
computed: {
|
||||
vsupplies() {
|
||||
return this.$store.state.verification.verification_supplies
|
||||
},
|
||||
openalertsupplies: {
|
||||
get() {
|
||||
return this.$store.state.supplies.open_alert_supplies
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("supplies/open_alert_supplies",false)
|
||||
}
|
||||
},
|
||||
msgalertsupplies(){
|
||||
return this.$store.state.supplies.msg_alert_supplies
|
||||
},
|
||||
btnsaveseen(){
|
||||
return this.$store.state.supplies.btn_save_seen
|
||||
},
|
||||
pgrssave(){
|
||||
return this.$store.state.supplies.pgrs_save
|
||||
}
|
||||
},
|
||||
methods : {
|
||||
updateDataTxtParentSupplies(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
this.$store.commit("verification/update_testing_txt_parent_supplies",prm)
|
||||
},
|
||||
updateDataCbxParentSupplies(idx, val) {
|
||||
var prm = {idx:idx,val:val}
|
||||
var xcount = this.$store.state.supplies.no_save + 1
|
||||
this.$store.commit("verification/update_testing_cbx_parent_supplies",prm)
|
||||
this.$store.commit("supplies/update_no_save",xcount)
|
||||
},
|
||||
saveSupplies(){
|
||||
var orderid = this.$store.state.patient.selected_patient.T_OrderHeaderID
|
||||
var prm = {orderid: orderid, supplies:this.$store.state.verification.verification_supplies,barcode:this.$store.state.verification.verification_barcode}
|
||||
console.log(prm)
|
||||
this.$store.dispatch("supplies/save",prm)
|
||||
},
|
||||
closeAlertSupplies(){
|
||||
this.$store.commit("supplies/update_open_alert_supplies",false)
|
||||
},
|
||||
forgetAlertSupplies(){
|
||||
this.$store.commit("supplies/update_no_save",0)
|
||||
this.$store.commit("supplies/update_open_alert_supplies",false)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,76 @@
|
||||
<template>
|
||||
<v-card class="mb-2 one-fo-tab">
|
||||
<v-layout justify-center class="tab-container">
|
||||
<v-btn @click="changeTo('pasien-dokter')" justify-center multi-line class= "buttonkiri active" color="success">
|
||||
Pasien <br/> Dokter
|
||||
<v-icon v-if="tab_selected('pasien-dokter')" right dark>verified_user</v-icon>
|
||||
</v-btn>
|
||||
<v-btn @click="changeTo('mou-px')" justify-center multi-line class= "buttonnew" color="error">MOU <br/> Pemeriksaan
|
||||
<v-icon v-if="tab_selected('mou-px')" right dark>verified_user</v-icon>
|
||||
</v-btn>
|
||||
<v-btn @click="changeTo('delivery-payment')" justify-center multi-line class= "buttonnew" color="warning">Kirim Hasil <br/> Payment
|
||||
<v-icon v-if="tab_selected('delivery-payment')" right dark>verified_user</v-icon>
|
||||
</v-btn>
|
||||
<v-btn @click="changeTo('barcode-supplies')" justify-center multi-line class= "buttonkanan" color="info">
|
||||
<v-icon v-if="tab_selected('barcode-supplies')" left dark>verified_user</v-icon>
|
||||
Supplies <br/> Barcode
|
||||
</v-btn>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
|
||||
.one-fo-tab {
|
||||
min-height:84px;
|
||||
}
|
||||
.layout.tab-container .v-btn {
|
||||
min-height:64px;
|
||||
margin-top:10px;
|
||||
}
|
||||
.v-card{
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.v-btn__content{
|
||||
margin-top : 0px;
|
||||
}
|
||||
|
||||
.buttonnew {
|
||||
width : 20%;
|
||||
text-decoration:none;
|
||||
}
|
||||
|
||||
.buttonkiri {
|
||||
width : 20%;
|
||||
text-decoration:none;
|
||||
border-top-left-radius: 50px;
|
||||
border-bottom-left-radius: 50px;
|
||||
}
|
||||
|
||||
.buttonkanan {
|
||||
width : 20%;
|
||||
text-decoration:none;
|
||||
border-top-right-radius: 50px;
|
||||
border-bottom-right-radius: 50px;
|
||||
}
|
||||
.active{
|
||||
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
methods: {
|
||||
tab_selected : function(tab) {
|
||||
return this.$store.state.tab_selected == tab
|
||||
},
|
||||
changeTo : function(tab) {
|
||||
this.$store.dispatch('change_tab',tab)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -0,0 +1,58 @@
|
||||
<template>
|
||||
<v-card class="mb-2 one-fo-tab">
|
||||
|
||||
<v-layout style="border-top: 0.6px solid red;" justify-center >
|
||||
<div class="btn-group">
|
||||
<button @click="changeTo('pasien-dokter')" class="button" v-bind:class="{ 'active': tab_selected('pasien-dokter')}">Pasien <br/> Dokter</button>
|
||||
<button @click="changeTo('mou-px')" class="button" v-bind:class="{ 'active': tab_selected('mou-px')}">MOU <br/> Pemeriksaan</button>
|
||||
<button @click="changeTo('delivery-payment')" class="button" v-bind:class="{ 'active': tab_selected('delivery-payment')}">Kirim Hasil <br/> Pembayaran</button>
|
||||
<button @click="changeTo('barcode-supplies')" class="button" v-bind:class="{ 'active': tab_selected('barcode-supplies')}">Supplies <br/> Barcode</button>
|
||||
</div>
|
||||
</v-layout>
|
||||
</v-card>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.btn-group .button {
|
||||
text-transform: uppercase;
|
||||
border: 1px solid #ffff;
|
||||
color: black;
|
||||
height:83px;
|
||||
width:150px;
|
||||
text-align: center;
|
||||
text-decoration: none;
|
||||
display: inline-block;
|
||||
font-size: 16px;
|
||||
font-weight:500;
|
||||
cursor: pointer;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.btn-group .button:hover {
|
||||
background-color: #E0F7FA;
|
||||
border-bottom: 2px solid #ff1604;
|
||||
|
||||
}
|
||||
|
||||
.btn-group .button.active {
|
||||
border-bottom: 2px solid #ff1604;
|
||||
}
|
||||
|
||||
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
methods: {
|
||||
tab_selected : function(tab) {
|
||||
return this.$store.state.tab_selected == tab
|
||||
},
|
||||
changeTo : function(tab) {
|
||||
this.$store.dispatch('change_tab',tab)
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -0,0 +1,312 @@
|
||||
<template>
|
||||
|
||||
<v-dialog
|
||||
v-model="dialog"
|
||||
max-width="40%"
|
||||
>
|
||||
<v-card>
|
||||
<v-card-title
|
||||
class="headline grey lighten-2 pt-2 pb-2"
|
||||
primary-title
|
||||
>
|
||||
Form Pengiriman
|
||||
</v-card-title>
|
||||
<v-card-text class="pt-2 pb-2">
|
||||
<v-layout row>
|
||||
<v-flex xs12 d-flex>
|
||||
<v-select
|
||||
v-model="selected_type_delivery"
|
||||
:items="type_delivery"
|
||||
item-text = "name"
|
||||
return-object
|
||||
label="Type Delivery"
|
||||
>
|
||||
<template
|
||||
slot="item"
|
||||
slot-scope="{ item }"
|
||||
>
|
||||
<v-list-tile-content>
|
||||
<v-list-tile-title v-text="item.name"></v-list-tile-title>
|
||||
</v-list-tile-content>
|
||||
</template>
|
||||
</v-select>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row>
|
||||
<v-flex xs12 d-flex>
|
||||
<v-layout row v-if="selected_type_delivery.type == 'EMAIL'">
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 xs12 >
|
||||
<v-text-field
|
||||
v-model="vtext"
|
||||
label="Alamat email"
|
||||
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row v-if="selected_type_delivery.type == 'WHATSAPP' && selected_type_delivery.source == 'PATIENT'">
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 xs12 >
|
||||
<v-text-field
|
||||
:value="xhp_patient"
|
||||
label="Nomor Whatsapp"
|
||||
readonly="true"
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row v-if="selected_type_delivery.type == 'WHATSAPP' && selected_type_delivery.source == 'DOCTOR'">
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 xs12 >
|
||||
<v-text-field
|
||||
:value="xhp_doctor"
|
||||
label="Nomor Whatsapp"
|
||||
readonly="true"
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row v-if="selected_type_delivery.type == 'TELEGRAM' && selected_type_delivery.source == 'DOCTOR'">
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 xs12 >
|
||||
<v-text-field
|
||||
:value="xhp_doctor"
|
||||
label="Nomor Whatsapp"
|
||||
readonly="true"
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row v-if="selected_type_delivery.type == 'TELEGRAM' && selected_type_delivery.source == 'PATIENT'">
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 xs12 >
|
||||
<v-text-field
|
||||
:value="xhp_patient"
|
||||
label="Nomor Whatsapp"
|
||||
readonly="true"
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row v-else-if="selected_type_delivery.id== 2">
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 pr-2 xs12>
|
||||
<v-select
|
||||
item-text="description"
|
||||
return-object
|
||||
:items="xaddress_patient"
|
||||
v-model="xselected_patient_address"
|
||||
label="Alamat Pasien"
|
||||
></v-select>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
<v-layout row v-else-if="selected_type_delivery.id == 4">
|
||||
<v-flex pb-1 xs12>
|
||||
<v-layout row>
|
||||
<v-flex pt-2 pr-2 xs12>
|
||||
<v-select
|
||||
item-text="description"
|
||||
return-object
|
||||
:items="xaddress_doctor"
|
||||
v-model="xselected_doctor_address"
|
||||
label="Alamat Dokter"
|
||||
></v-select>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</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 = false"
|
||||
>
|
||||
Tutup
|
||||
</v-btn>
|
||||
<v-btn
|
||||
color="primary"
|
||||
flat
|
||||
@click="addDelivery()"
|
||||
>
|
||||
Tambahkan
|
||||
</v-btn>
|
||||
</v-card-actions>
|
||||
</v-card>
|
||||
</v-dialog>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
data(){
|
||||
return {
|
||||
vilageid:0,
|
||||
datatext : '',
|
||||
search : '',
|
||||
selected_patient_address:{},
|
||||
selected_doctor_address:{},
|
||||
opt_address :[{name:'Patient',value:'patient'},{name:'Doctor',value:'doctor'}],
|
||||
selected_address_type:''
|
||||
}
|
||||
},
|
||||
computed : {
|
||||
type_delivery() {
|
||||
return this.$store.state.delivery.deliveries
|
||||
},
|
||||
xaddress_patient() {
|
||||
return this.$store.state.delivery.address_patient
|
||||
},
|
||||
xhp_patient() {
|
||||
return this.$store.state.delivery.hp_patient
|
||||
},
|
||||
xaddress_doctor() {
|
||||
return this.$store.state.delivery.address_doctor
|
||||
},
|
||||
xhp_doctor() {
|
||||
return this.$store.state.delivery.hp_doctor
|
||||
},
|
||||
selected_type_delivery : {
|
||||
get() {
|
||||
return this.$store.state.delivery.selected_delivery
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("delivery/update_selected_delivery",val)
|
||||
}
|
||||
},
|
||||
xselected_patient_address : {
|
||||
get() {
|
||||
return this.selected_patient_address
|
||||
},
|
||||
set(val) {
|
||||
this.selected_patient_address = val
|
||||
}
|
||||
},
|
||||
xselected_doctor_address : {
|
||||
get() {
|
||||
return this.selected_doctor_address
|
||||
},
|
||||
set(val) {
|
||||
this.selected_doctor_address = val
|
||||
}
|
||||
},
|
||||
vtext : {
|
||||
get() {
|
||||
return this.datatext
|
||||
},
|
||||
set(val) {
|
||||
this.datatext = val
|
||||
}
|
||||
},
|
||||
dialog: {
|
||||
get() {
|
||||
return this.$store.state.verification.dialog_delivery_is_active
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit('verification/update_dialog_delivery_is_active',val)
|
||||
}
|
||||
},
|
||||
xselected_vilage: {
|
||||
get() {
|
||||
this.$store.state.vilage.selected_vilage
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit("vilage/update_selected_vilage",val)
|
||||
}
|
||||
},
|
||||
xvilages() {
|
||||
return this.$store.state.vilage.vilages
|
||||
},
|
||||
is_loading() {
|
||||
return this.$store.state.vilage.search_status == 1
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
addDelivery() {
|
||||
this.dialog = false
|
||||
var vid = 0
|
||||
var destination = this.datatext
|
||||
var xcode = this.selected_type_delivery.code
|
||||
this.datatext = ''
|
||||
var addressid = 0
|
||||
var vilageid = 0
|
||||
if(this.selected_type_delivery.id === '2' || this.selected_type_delivery.id === 2){
|
||||
var addr = this.selected_patient_address
|
||||
addressid = addr.id
|
||||
vilageid = addr.vilageid
|
||||
//destination = addr.description
|
||||
}
|
||||
else if(this.selected_type_delivery.id === '4' || this.selected_type_delivery.id === 4){
|
||||
var addr = this.selected_doctor_address
|
||||
addressid = addr.id
|
||||
vilageid = addr.vilageid
|
||||
destination = addr.description
|
||||
}
|
||||
else if(this.selected_type_delivery.id === '6' || this.selected_type_delivery.id === 6){
|
||||
addressid = 0
|
||||
vilageid = 0
|
||||
destination = this.xhp_patient
|
||||
}
|
||||
else if(this.selected_type_delivery.id === '8' || this.selected_type_delivery.id === 8){
|
||||
addressid = 0
|
||||
vilageid = 0
|
||||
destination = this.xhp_patient
|
||||
}
|
||||
else if(this.selected_type_delivery.id === '7' || this.selected_type_delivery.id === 7){
|
||||
addressid = 0
|
||||
vilageid = 0
|
||||
destination = this.xhp_doctor
|
||||
}
|
||||
else if(this.selected_type_delivery.id === '9' || this.selected_type_delivery.id === 9){
|
||||
addressid = 0
|
||||
vilageid = 0
|
||||
destination = this.xhp_doctor
|
||||
}
|
||||
|
||||
if(this.selected_type_delivery.type == 'PICKUP')
|
||||
var xlabel = this.selected_type_delivery.name
|
||||
else
|
||||
var xlabel = this.selected_type_delivery.name+' : '+destination
|
||||
|
||||
var prm = {
|
||||
id:vid,
|
||||
xid:0,
|
||||
code:xcode,
|
||||
chex:true,
|
||||
deliveryid:this.selected_type_delivery.id,
|
||||
typedeliveryid:this.selected_type_delivery.typeid,
|
||||
addressid:addressid,
|
||||
vilageid:vilageid,
|
||||
note:'',
|
||||
type:'indigo',
|
||||
label:xlabel,
|
||||
destination:destination
|
||||
}
|
||||
|
||||
this.$store.commit("vilage/update_selected_vilage",{})
|
||||
this.$emit('add-data-delivery', prm)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,28 @@
|
||||
<template>
|
||||
<v-layout row wrap>
|
||||
<v-flex xs6 class="left">
|
||||
<v-layout column wrap fill-height>
|
||||
<search-box></search-box>
|
||||
<v-flex grow class="searchresult">
|
||||
search result
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.searchresult {
|
||||
background-color:red;
|
||||
}
|
||||
</style>
|
||||
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
components : {
|
||||
'search-box' : httpVueLoader('./searchBoxV3.vue')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,102 @@
|
||||
<template>
|
||||
<v-card class="fill-height ">
|
||||
<v-layout>
|
||||
<v-flex xs3 pa-1>
|
||||
<v-text-field
|
||||
label="Search"
|
||||
placeholder="No Lab"
|
||||
single-line
|
||||
@change="nolab"
|
||||
outline
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
<v-flex xs6 pa-1>
|
||||
<v-text-field
|
||||
label=""
|
||||
placeholder="Nama"
|
||||
v-model="name"
|
||||
single-line
|
||||
outline
|
||||
></v-text-field>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 pa-1>
|
||||
<v-select
|
||||
:items="items"
|
||||
label="Status"
|
||||
v-model="status"
|
||||
outline
|
||||
></v-select>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs3>
|
||||
<v-btn @click="searchPasien()" color="success" class="mr-1 ml-1">Search</v-btn>
|
||||
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
|
||||
</v-card>
|
||||
</template>
|
||||
<style scoped>
|
||||
.v-btn {
|
||||
min-width: auto;
|
||||
}
|
||||
|
||||
.v-input__slot {
|
||||
margin-bottom: 0px !important;
|
||||
}
|
||||
|
||||
.v-messages {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.v-text-field--box>.v-input__control>.v-input__slot,.v-text-field--full-width>.v-input__control>.v-input__slot,.v-text-field--outline>.v-input__control>.v-input__slot {
|
||||
min-height: 44px;
|
||||
}
|
||||
|
||||
.v-text-field--box.v-text-field--single-line input,.v-text-field--full-width.v-text-field--single-line input,.v-text-field--outline.v-text-field--single-line input {
|
||||
margin-top: 6px;
|
||||
}
|
||||
|
||||
.v-input__control{
|
||||
height: 10px;
|
||||
}
|
||||
.v-btn {
|
||||
margin : 10px
|
||||
|
||||
}
|
||||
</style>
|
||||
<script>
|
||||
module.exports = {
|
||||
methods: {
|
||||
searchPasien() {
|
||||
this.$store.dispatch('patient/search')
|
||||
},
|
||||
nolab(val) {
|
||||
this.$store.commit("patient/update_nolab",val)
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
|
||||
name: {
|
||||
get() {
|
||||
return this.$store.state.patient.name
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit('patient/update_name',val)
|
||||
}
|
||||
},
|
||||
status: {
|
||||
get() {
|
||||
return this.$store.state.patient.status
|
||||
},
|
||||
set(val) {
|
||||
this.$store.commit('patient/update_status',val)
|
||||
}
|
||||
}
|
||||
},
|
||||
components : {
|
||||
'patient-search-dialog': httpVueLoader('./patientSearchDialog.vue')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,86 @@
|
||||
<template>
|
||||
<v-card class="fill-height " >
|
||||
|
||||
<v-data-table :headers="headers" :items="patients"
|
||||
: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':props.item.selected}" @click="selectMe(props.item)">{{ props.item.mr }}</td>
|
||||
<td class="pa-2" v-bind:class="{'amber lighten-4':props.item.selected}" @click="selectMe(props.item)">{{ props.item.lab}}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':props.item.selected}" @click="selectMe(props.item)">{{ props.item.name }}</td>
|
||||
<td class="text-xs-left pa-2" v-bind:class="{'amber lighten-4':props.item.selected}" @click="selectMe(props.item)">{{ props.item.status }}</td>
|
||||
</template>
|
||||
|
||||
</v-data-table>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
table.v-table tbody td,table.v-table tbody th {
|
||||
height: 40px;
|
||||
}
|
||||
|
||||
table.v-table thead tr {
|
||||
height: 40px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
module.exports = {
|
||||
data() {
|
||||
return {
|
||||
query: "",
|
||||
headers: [
|
||||
{
|
||||
text: "NO REG",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "mr",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NO LAB",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "lab",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
{
|
||||
text: "NAMA",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "name",
|
||||
width: "25%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
},
|
||||
|
||||
{
|
||||
text: "STATUS",
|
||||
align: "left",
|
||||
sortable: false,
|
||||
value: "status",
|
||||
width: "15%",
|
||||
class: "pa-2 blue lighten-3 white--text"
|
||||
}
|
||||
],
|
||||
|
||||
|
||||
isLoading: true,
|
||||
patients: [
|
||||
{"status":"Data Verified","lab":"08000198909", "mr": "MR-18107237", "name": "Pasien Umum", "sex": "Perempuan", "address": "Klero\r\nKabupaten Semarang", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Payment Verified","lab":"08000198111", "mr": "MR-18107238", "name": "Heri Suryawan", "sex": "Laki - laki", "address": "Ampel", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Payment Verified","lab":"08000198222", "mr": "MR-18107239", "name": "LUKA MODRIC", "sex": "Laki - laki", "address": "Jl. Raya No 1", "action":"", "dob":"19-09-1992", "selected":true},
|
||||
{"status":"Data Verified","lab":"08000198121", "mr": "MR-18107247", "name": "Tyas Medika Pranandita", "sex": "Laki - laki", "address": "KP. Karangpanas", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Data & Payment Verified","lab":"08000198131", "mr": "MR-18107248", "name": "Astrid", "sex": "Perempuan", "address": "Jl. Ketintang Raya No.81", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Data & Payment Verified","lab":"08000198123", "mr": "MR-18107249", "name": "Happy", "sex": "Perempuan", "address": "Karangpanas", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Data Verified","lab":"08000198111", "mr": "MR-18107251", "name": "Juan Alexis Sukir", "sex": "Laki - laki", "address": "Jl. Sawi", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Data & Payment Verified","lab":"08000198555", "mr": "MR-18107252", "name": "Alexander Wang", "sex": "Laki - laki", "address": "Jl. Mangga Muda No. 7", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Payment Verified","lab":"08000198444", "mr": "MR-18107253", "name": "CILA CILANI", "sex": "Perempuan", "address": "Jl. Duren PInang No. 67", "action":"", "dob":"19-09-1992", "selected":false},
|
||||
{"status":"Data & Payment Verified","lab":"08000198123", "mr": "MR-18107254", "name": "Untung Suropati", "sex": "Laki - laki", "address": "Pasar Kapling Semarang", "action":"", "dob":"19-09-1992", "selected":false}
|
||||
]
|
||||
};
|
||||
}
|
||||
}
|
||||
</script>
|
||||
126
test/vuex/one-fo-verification-simple-barcode/index.php
Normal file
126
test/vuex/one-fo-verification-simple-barcode/index.php
Normal file
@@ -0,0 +1,126 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||
<title>One</title>
|
||||
<link rel="stylesheet" href="../../../libs/vendor/css/google-fonts.css">
|
||||
<link rel="stylesheet" href="../../../libs/vendor/css/icomoon-fonts.css">
|
||||
<link rel="stylesheet" href="../../../libs/vendor/css/vuetify.min.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div v-cloak id="app">
|
||||
<v-app id="smartApp" >
|
||||
<one-navbar></one-navbar>
|
||||
<v-content style="background:#F5E8DF!important" >
|
||||
<v-container fluid fill-height class="pl-1 pr-1 pt-2 pb-2">
|
||||
<v-layout row wrap >
|
||||
<v-flex xs6 class="left" fill-height pa-1>
|
||||
<one-fo-verification-list></one-fo-verification-list>
|
||||
</v-flex>
|
||||
|
||||
<v-flex xs6 class="right" fill-height pa-1>
|
||||
<!-- komponen kanan -->
|
||||
<one-fo-verification-simple-right></one-fo-verification-simple-right>
|
||||
|
||||
<one-fo-verification-list-right></one-fo-verification-list-right>
|
||||
|
||||
</v-flex>
|
||||
</v-layout>
|
||||
</v-container>
|
||||
</v-content>
|
||||
<one-footer> </one-footer>
|
||||
</v-app>
|
||||
</div>
|
||||
|
||||
<!-- Vendor -->
|
||||
<script src="../../../libs/vendor/moment.min.js"></script>
|
||||
<script src="../../../libs/vendor/numeral.min.js"></script>
|
||||
<script src="../../../libs/vendor/moment-locale-id.js"></script>
|
||||
<script src="../../../libs/vendor/lodash.js"></script>
|
||||
<script src="../../../libs/vendor/axios.min.js"></script>
|
||||
<script src="../../../libs/vendor/vue.js"></script>
|
||||
<script src="../../../libs/vendor/vuex.js"></script>
|
||||
<script src="../../../libs/vendor/vuetify.js"></script>
|
||||
<script src="../../../libs/vendor/httpVueLoader.js"></script>
|
||||
<script src="../../../libs/one_global.js"></script>
|
||||
<script src="../../../libs/one_print_barcode.js"></script>
|
||||
<script src="../../../libs/one_print_robo.js"></script>
|
||||
<script src="../../../libs/vendor/socket.io.js"></script>
|
||||
<!-- App Script -->
|
||||
<?php
|
||||
$ts = "?ts=" . Date("ymdhis");
|
||||
?>
|
||||
<script type="module">
|
||||
window.calculate_age = function (inp_dob) {
|
||||
var now = moment(new Date())
|
||||
var dob = moment(new Date(inp_dob))
|
||||
var year = now.diff(dob,'years')
|
||||
dob.add(year,'years')
|
||||
var month = now.diff(dob,'months')
|
||||
dob.add(month,'months')
|
||||
var day = now.diff(dob,'days')
|
||||
if (isNaN(year)) return ''
|
||||
return `${year} tahun ${month} bulan ${day} hari`
|
||||
}
|
||||
|
||||
|
||||
import { store } from './store.js<?php echo $ts ?>';
|
||||
var socketIoUrl = "http://" + window.location.host + ":9090/";
|
||||
|
||||
//for testing
|
||||
window.store = store;
|
||||
new Vue({
|
||||
store,
|
||||
el: '#app',
|
||||
methods: {
|
||||
tab_selected : function(tab) {
|
||||
return this.$store.state.tab_selected == tab
|
||||
}
|
||||
},
|
||||
data : {
|
||||
socket : io.connect(socketIoUrl,{forceNew:false})
|
||||
},
|
||||
mounted() {
|
||||
let self = this;
|
||||
this.socket.on("notification", function(msg) {
|
||||
switch(msg.type) {
|
||||
case "fo-verification-x" :
|
||||
case "fo-verification-y" :
|
||||
case "fo-register" :
|
||||
//search patient
|
||||
let name = self.$store.state.patient.name
|
||||
let nolab= self.$store.state.patient.nolab
|
||||
store.dispatch("patient/search",{
|
||||
name : name,
|
||||
nolab : nolab
|
||||
})
|
||||
break;
|
||||
}
|
||||
});
|
||||
},
|
||||
components: {
|
||||
'one-navbar': httpVueLoader('../../../apps/components/oneNavbarComponent.vue'),
|
||||
'one-footer': httpVueLoader('../../../apps/components/oneFooter.vue'),
|
||||
'one-fo-verification-list': httpVueLoader('./components/oneFoVerificationList.vue'),
|
||||
'one-fo-verification-simple-right' : httpVueLoader('./components/oneFoVerificationSimpleRight.vue'),
|
||||
'one-fo-verification-list-right' : httpVueLoader('./components/oneFoVerificationRightList.vue'),
|
||||
|
||||
}
|
||||
})
|
||||
</script>
|
||||
<style>
|
||||
[v-cloak] {
|
||||
display: none
|
||||
}
|
||||
.left {
|
||||
}
|
||||
.right {
|
||||
}
|
||||
</style>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
59
test/vuex/one-fo-verification-simple-barcode/index0.php
Normal file
59
test/vuex/one-fo-verification-simple-barcode/index0.php
Normal file
@@ -0,0 +1,59 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||
<title>One</title>
|
||||
<link rel="stylesheet" href="../../../libs/vendor/css/google-fonts.css">
|
||||
<link rel="stylesheet" href="../../../libs/vendor/css/vuetify.min.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div v-cloak id="app">
|
||||
<v-app id="smartApp" >
|
||||
<one-navbar></one-navbar>
|
||||
<v-content class="blue lighten-5" >
|
||||
<v-container fluid fill-height>
|
||||
|
||||
<one-fo-verification-list> <one-fo-verification-list>
|
||||
|
||||
</v-container>
|
||||
</v-content>
|
||||
<one-footer> </one-footer>
|
||||
</v-app>
|
||||
</div>
|
||||
|
||||
<!-- Vendor -->
|
||||
<script src="../../../libs/vendor/axios.min.js"></script>
|
||||
<script src="../../../libs/vendor/vue.js"></script>
|
||||
<script src="../../../libs/vendor/vuex.js"></script>
|
||||
<script src="../../../libs/vendor/vuetify.js"></script>
|
||||
<script src="../../../libs/vendor/httpVueLoader.js"></script>
|
||||
<!-- App Script -->
|
||||
<?php
|
||||
$ts = "?ts=" . Date("ymdhis");
|
||||
?>
|
||||
<script type="module">
|
||||
import { store } from './store.js<?php echo $ts ?>';
|
||||
//for testing
|
||||
// window.store = store;
|
||||
new Vue({
|
||||
store,
|
||||
el: '#app',
|
||||
components: {
|
||||
'one-navbar': httpVueLoader('../../../apps/components/oneNavbarComponent.vue'),
|
||||
'one-footer': httpVueLoader('../../../apps/components/oneFooter.vue'),
|
||||
'one-fo-verification-list': httpVueLoader('./components/foVerificationList.vue'),
|
||||
}
|
||||
})
|
||||
</script>
|
||||
<style>
|
||||
[v-cloak] {
|
||||
display: none
|
||||
}
|
||||
</style>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Binary file not shown.
@@ -0,0 +1,69 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/delivery.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
lookup_delivery:0,
|
||||
lookup_error_message:'',
|
||||
deliveries: [],
|
||||
total_delivery: 0,
|
||||
selected_delivery: {},
|
||||
address_patient:[],
|
||||
address_doctor:[],
|
||||
hp_patient:'',
|
||||
hp_doctor:''
|
||||
},
|
||||
mutations: {
|
||||
update_lookup_error_message(state,status) {
|
||||
state.search_error_message = status
|
||||
},
|
||||
update_lookup_delivery(state,status) {
|
||||
state.lookup_delivery = status
|
||||
},
|
||||
update_deliveries(state,data) {
|
||||
state.deliveries= data.records
|
||||
state.total_delivery= data.total
|
||||
},
|
||||
update_selected_delivery(state,val) {
|
||||
state.selected_delivery=val
|
||||
},
|
||||
update_address_patient(state,val) {
|
||||
state.address_patient=val
|
||||
},
|
||||
update_address_doctor(state,val) {
|
||||
state.address_doctor=val
|
||||
},
|
||||
update_hp_patient(state,val) {
|
||||
state.hp_patient = val
|
||||
},
|
||||
update_hp_doctor(state,val) {
|
||||
state.hp_doctor = val
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
async lookup(context) {
|
||||
context.commit("update_lookup_delivery",1)
|
||||
try {
|
||||
let resp= await api.lookup(one_token())
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_lookup_delivery",3)
|
||||
context.commit("update_lookup_error_message",resp.message)
|
||||
} else {
|
||||
context.commit("update_lookup_delivery",2)
|
||||
context.commit("update_lookup_error_message","")
|
||||
let data = {
|
||||
records : resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
context.commit("update_deliveries",data)
|
||||
}
|
||||
} catch(e) {
|
||||
context.commit("update_lookup_delivery",3)
|
||||
context.commit("update_lookup_error_message",e.message )
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
//import * as api from "../api/patient.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
verification_delivery:[
|
||||
{'id':1,'check':false,'note':'','label':'Email ke Dokter : emaildoctor@email.com'},
|
||||
{'id':2,'check':false,'note':'','label':'Kirim ke Pasien : Jl. Padepokan Rindu No. 99 Tegal Barat'}
|
||||
],
|
||||
verification_payment:[
|
||||
{'id':1,'check':false,'note':'','label':'Minimum pembayaran terpenuhi'}
|
||||
]
|
||||
|
||||
},
|
||||
mutations: {
|
||||
update_testing_txt_parent_patient(state,data) {
|
||||
state.verification_patient[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_patient(state,data) {
|
||||
state.verification_patient[data.idx].check = data.val
|
||||
},
|
||||
update_verification_patient(state,data){
|
||||
state.verification_patient = data.verification_patient
|
||||
},
|
||||
update_verification_doctor(state,data){
|
||||
state.verification_doctor = data.verification_doctor
|
||||
},
|
||||
update_testing_txt_parent_doctor(state,data) {
|
||||
state.verification_doctor[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_doctor(state,data) {
|
||||
state.verification_doctor[data.idx].check = data.val
|
||||
}
|
||||
|
||||
},
|
||||
actions: {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
190
test/vuex/one-fo-verification-simple-barcode/modules/done.js
Normal file
190
test/vuex/one-fo-verification-simple-barcode/modules/done.js
Normal file
@@ -0,0 +1,190 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/done.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
last_id:-1,
|
||||
last_saved_id:-1,
|
||||
x_addr_id:0,
|
||||
act:'new',
|
||||
act_addr:'new',
|
||||
get_data_status:0,
|
||||
search_trx: 0,
|
||||
search_status: 0,
|
||||
search_error_message: '',
|
||||
start_date:moment(new Date()).format('YYYY-MM-DD'),
|
||||
end_date:moment(new Date()).format('YYYY-MM-DD'),
|
||||
total_transaction: 0,
|
||||
transactions:[],
|
||||
selected_transaction: {},
|
||||
save_status: 0,
|
||||
btn_save_seen: true,
|
||||
pgrs_save: false,
|
||||
save_error_message: '',
|
||||
no_save: 0,
|
||||
open_alert_confirmation:false,
|
||||
alert_success: false,
|
||||
msg_success: "",
|
||||
dialog_success: false,
|
||||
dialog_confirmation_delete: false,
|
||||
msg_confirmation_delete: "",
|
||||
autocomplete_status:0,
|
||||
dialog_form_address: false,
|
||||
errors:[],
|
||||
open_dialog_info:false,
|
||||
msg_info:'',
|
||||
current_page:1,
|
||||
total_page:1,
|
||||
total_transactions:0,
|
||||
search:'',
|
||||
selected_sampletype:{},
|
||||
msg_action:'',
|
||||
dialog_action:false,
|
||||
},
|
||||
mutations: {
|
||||
update_dialog_action(state, val) {
|
||||
state.dialog_action = val
|
||||
},
|
||||
update_msg_action(state, val) {
|
||||
state.msg_action = val
|
||||
},
|
||||
update_selected_sampletype(state, val) {
|
||||
state.selected_sampletype = val
|
||||
},
|
||||
update_search(state, val) {
|
||||
state.search = val
|
||||
},
|
||||
update_total_page(state, val) {
|
||||
state.total_page = val
|
||||
},
|
||||
update_current_page(state, val) {
|
||||
state.current_page = val
|
||||
},
|
||||
update_x_addr_id(state, val) {
|
||||
state.x_addr_id = val
|
||||
},
|
||||
update_last_id(state, val) {
|
||||
state.last_id = val
|
||||
},
|
||||
update_last_saved_id(state, val) {
|
||||
state.last_saved_id = val
|
||||
},
|
||||
update_act(state, val) {
|
||||
state.act = val
|
||||
},
|
||||
update_start_date(state, val) {
|
||||
state.start_date = val
|
||||
},
|
||||
update_end_date(state, val) {
|
||||
state.end_date = val
|
||||
},
|
||||
update_act_addr(state, val) {
|
||||
state.act_addr = val
|
||||
},
|
||||
update_get_data_status(state, val) {
|
||||
state.get_data_status = val
|
||||
},
|
||||
update_search_error_message(state, patient) {
|
||||
state.search_error_message = patient
|
||||
},
|
||||
update_search_transaction(state, val) {
|
||||
state.search_transaction = val
|
||||
},
|
||||
update_transactions(state, data) {
|
||||
state.transactions = data
|
||||
},
|
||||
update_selected_transaction(state, val) {
|
||||
state.selected_transaction = val
|
||||
},
|
||||
update_save_status(state, val) {
|
||||
state.save_status = val
|
||||
},
|
||||
update_btn_save_seen(state, val) {
|
||||
state.btn_save_seen = val
|
||||
},
|
||||
update_pgrs_save(state, val) {
|
||||
state.pgrs_save = val
|
||||
},
|
||||
update_save_error_message(state, msg) {
|
||||
state.save_error_message = ''
|
||||
},
|
||||
update_no_save(state, val) {
|
||||
state.no_save = val
|
||||
},
|
||||
update_open_alert_confirmation(state, val) {
|
||||
state.open_alert_confirmation = val
|
||||
},
|
||||
update_alert_success(state, val) {
|
||||
state.alert_success = val
|
||||
},
|
||||
update_msg_success(state, val) {
|
||||
state.msg_success = val
|
||||
},
|
||||
update_dialog_success(state, val) {
|
||||
state.dialog_success = val
|
||||
},
|
||||
update_dialog_confirmation_delete(state, val) {
|
||||
state.dialog_confirmation_delete = val
|
||||
},
|
||||
update_msg_confirmation_delete(state, val) {
|
||||
state.msg_confirmation_delete = val
|
||||
},
|
||||
update_search_status(state, val) {
|
||||
state.search_status = val
|
||||
},
|
||||
update_errors(state, val) {
|
||||
state.errors = val
|
||||
},
|
||||
update_total_transactions(state, val) {
|
||||
state.total_transactions = val
|
||||
},
|
||||
update_open_dialog_info(state, val) {
|
||||
state.open_dialog_info = val
|
||||
},
|
||||
update_msg_info(state, val) {
|
||||
state.msg_info = val
|
||||
},
|
||||
},
|
||||
actions: {
|
||||
async search(context, prm) {
|
||||
context.commit("update_search_transaction", 1)
|
||||
try {
|
||||
prm.token = one_token()
|
||||
let resp = await api.search(prm)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_search_transaction", 3)
|
||||
context.commit("update_search_error_message", resp.message)
|
||||
} else {
|
||||
context.commit("update_search_transaction", 2)
|
||||
context.commit("update_search_error_message", "")
|
||||
let data = {
|
||||
records: resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
context.commit("update_transactions", data.records)
|
||||
context.commit("update_total_transactions", data.total)
|
||||
context.commit("update_total_page", data.total)
|
||||
context.commit("update_no_save", 0)
|
||||
/*if(prm.lastid === -1){
|
||||
context.commit("update_selected_transaction", data.records[0])
|
||||
var doc = data.records[0]
|
||||
|
||||
}
|
||||
else{
|
||||
context.commit("update_selected_transaction", data.records[prm.lastid])
|
||||
var doc = data.records[prm.lastid]
|
||||
|
||||
}*/
|
||||
|
||||
}
|
||||
} catch (e) {
|
||||
context.commit("update_search_transaction", 3)
|
||||
context.commit("update_search_error_message", e.message)
|
||||
console.log(e)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
263
test/vuex/one-fo-verification-simple-barcode/modules/patient.js
Normal file
263
test/vuex/one-fo-verification-simple-barcode/modules/patient.js
Normal file
@@ -0,0 +1,263 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/patient.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
search_patient: 0,
|
||||
search_error_message: '',
|
||||
patients: [],
|
||||
patient_address: [],
|
||||
doctor_address: [],
|
||||
total_patient: 0,
|
||||
selected_patient: {},
|
||||
now_prm:{},
|
||||
save_status: 0,
|
||||
btn_save_seen: true,
|
||||
pgrs_save: false,
|
||||
save_error_message: '',
|
||||
open_dialog_verification: false,
|
||||
msg_info_verification: "",
|
||||
no_save: 0,
|
||||
open_alert_verification: false,
|
||||
msg_alert_verification: "Yakin, belum disimpan lhoooo ?",
|
||||
msg_action:'',
|
||||
dialog_action:false,
|
||||
show_right:'N',
|
||||
verifications:[],
|
||||
snackbar:{value:false,timeout:4000,text:''},
|
||||
name:'',
|
||||
nolab:'',
|
||||
disabled_button:false,
|
||||
dialoglist:false,
|
||||
lookup:0,
|
||||
barcodes:[]
|
||||
},
|
||||
mutations: {
|
||||
update_barcodes(state, data) {
|
||||
state.barcodes = data
|
||||
},
|
||||
update_lookup(state, data) {
|
||||
state.lookup = data
|
||||
},
|
||||
update_dialoglist(state, data) {
|
||||
state.dialoglist = data
|
||||
},
|
||||
update_disabled_button(state, data) {
|
||||
state.disabled_button = data
|
||||
},
|
||||
update_name(state, val) {
|
||||
state.name = val
|
||||
},
|
||||
update_nolab(state, val) {
|
||||
state.nolab = val
|
||||
},
|
||||
update_snackbar(state, patient) {
|
||||
state.snackbar = patient
|
||||
},
|
||||
update_now_prm(state, patient) {
|
||||
state.now_prm = patient
|
||||
},
|
||||
update_search_error_message(state, patient) {
|
||||
state.search_error_message = patient
|
||||
},
|
||||
update_search_patient(state, patient) {
|
||||
state.search_patient = patient
|
||||
},
|
||||
update_patients(state, data) {
|
||||
state.patients = data.records
|
||||
state.total_patient = data.total
|
||||
},
|
||||
update_selected_patient(state, val) {
|
||||
state.selected_patient = val
|
||||
},
|
||||
update_save_status(state, val) {
|
||||
state.save_status = val
|
||||
},
|
||||
update_btn_save_seen(state, val) {
|
||||
state.btn_save_seen = val
|
||||
},
|
||||
update_pgrs_save(state, val) {
|
||||
state.pgrs_save = val
|
||||
},
|
||||
update_dialog_action(state, val) {
|
||||
state.dialog_action = val },
|
||||
update_msg_action(state, val) {
|
||||
state.msg_action = val
|
||||
},
|
||||
update_save_error_message(state, msg) {
|
||||
state.save_error_message = ''
|
||||
},
|
||||
update_open_dialog_verification(state, val) {
|
||||
state.open_dialog_verification = val
|
||||
},
|
||||
update_msg_info_verification(state, val) {
|
||||
state.msg_info_verification = val
|
||||
},
|
||||
update_no_save(state, val) {
|
||||
state.no_save = val
|
||||
},
|
||||
update_open_alert_verification(state, val) {
|
||||
state.open_alert_verification = val
|
||||
},
|
||||
update_msg_alert_verification(state, val) {
|
||||
state.msg_alert_verification = val
|
||||
},
|
||||
update_show_right(state, patient) {
|
||||
state.show_right = patient
|
||||
},
|
||||
update_verifications(state, value) {
|
||||
state.verifications = value
|
||||
},
|
||||
},
|
||||
actions: {
|
||||
async search(context, prm) {
|
||||
context.commit("update_search_patient", 1)
|
||||
try {
|
||||
let resp = await api.search(one_token(), prm.nolab, prm.name, prm.status)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_search_patient", 3)
|
||||
context.commit("update_search_error_message", resp.message)
|
||||
} else {
|
||||
context.commit("update_search_patient", 2)
|
||||
context.commit("update_search_error_message", "")
|
||||
let data = {
|
||||
records: resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
context.commit("update_patients", data)
|
||||
context.commit("update_selected_patient", data.records[0])
|
||||
var pat = data.records[0]
|
||||
context.commit("update_show_right","N")
|
||||
if(pat.check_status !== '2'){
|
||||
context.commit("update_show_right","Y")
|
||||
context.commit("update_verifications",pat.verifications)
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
context.commit("update_search_patient", 3)
|
||||
context.commit("update_search_error_message", e.message)
|
||||
console.log(e)
|
||||
}
|
||||
},
|
||||
async lookup_barcodes(context,prm) {
|
||||
context.commit("update_lookup",1)
|
||||
try {
|
||||
prm.token = one_token()
|
||||
let resp= await api.lookup_barcodes(prm)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_lookup",3)
|
||||
} else {
|
||||
context.commit("update_lookup",2)
|
||||
let data = {
|
||||
records : resp.data.records
|
||||
}
|
||||
context.commit("update_barcodes",data.records)
|
||||
}
|
||||
} catch(e) {
|
||||
context.commit("update_lookup",3)
|
||||
console.log(e)
|
||||
}
|
||||
|
||||
},
|
||||
async addnewlabel(context, prm) {
|
||||
context.commit("update_save_status", 1)
|
||||
try {
|
||||
prm.token = one_token()
|
||||
let resp = await api.addnewlabel(prm)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
} else {
|
||||
context.commit("update_save_status", 2)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
|
||||
context.dispatch("lookup_barcodes",{ohid:prm.orderid})
|
||||
context.commit("done/update_dialog_action",false,{root:true})
|
||||
}
|
||||
} catch (e) {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_save_error_message", e.message)
|
||||
console.log(e)
|
||||
}
|
||||
},
|
||||
async save(context, prm) {
|
||||
context.commit("update_save_status", 1)
|
||||
context.commit("update_btn_save_seen", false)
|
||||
context.commit("update_pgrs_save", true)
|
||||
try {
|
||||
let resp = await api.save(one_token(),prm.patient, prm.status)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
} else {
|
||||
context.commit("update_save_status", 2)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
context.commit("update_no_save", 0)
|
||||
context.commit("update_btn_save_seen", true)
|
||||
context.commit("update_pgrs_save", false)
|
||||
let data = {
|
||||
records: resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
let msg = data.records.message
|
||||
|
||||
context.commit("update_msg_info_verification", msg)
|
||||
context.commit("update_open_dialog_verification", true)
|
||||
|
||||
}
|
||||
} catch (e) {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_save_error_message", e.message)
|
||||
console.log(e)
|
||||
}
|
||||
},
|
||||
async verify(context, prm) {
|
||||
context.commit("update_save_status", 1)
|
||||
context.commit("update_btn_save_seen", false)
|
||||
context.commit("update_pgrs_save", true)
|
||||
try {
|
||||
prm.token = one_token()
|
||||
let resp = await api.verify(prm)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_btn_save_seen", true)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
} else {
|
||||
context.commit("update_save_status", 2)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
context.commit("update_no_save", 0)
|
||||
context.commit("update_btn_save_seen", true)
|
||||
context.commit("update_pgrs_save", false)
|
||||
context.commit("disabled_button", false)
|
||||
let data = {
|
||||
records: resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
let msg = data.records.message
|
||||
if(prm.act === 'Y')
|
||||
context.commit("update_dialog_action", false)
|
||||
else
|
||||
context.commit("update_dialoglist", false)
|
||||
|
||||
var snackbar = {value:true,timeout:4000,text:msg}
|
||||
context.commit("update_snackbar",snackbar)
|
||||
var xprm = {
|
||||
name:prm.name,
|
||||
nolab: prm.nolab,
|
||||
//status: prm.status
|
||||
}
|
||||
context.dispatch("search",xprm)
|
||||
context.dispatch("done/search",prm.done_search,{root:true})
|
||||
}
|
||||
} catch (e) {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_btn_save_seen", true)
|
||||
context.commit("update_save_error_message", e.message)
|
||||
console.log(e)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
65
test/vuex/one-fo-verification-simple-barcode/modules/px.js
Normal file
65
test/vuex/one-fo-verification-simple-barcode/modules/px.js
Normal file
@@ -0,0 +1,65 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/px.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
dialog_px_is_active: false,
|
||||
search_status : 0,
|
||||
pxs:[],
|
||||
total_px: 0,
|
||||
search:'',
|
||||
selected_px: {},
|
||||
moucompany:{}
|
||||
},
|
||||
mutations: {
|
||||
update_dialog_px_is_active(state,status) {
|
||||
state.dialog_px_is_active = status
|
||||
},
|
||||
update_search_error_message(state,status) {
|
||||
state.search_error_message = status
|
||||
},
|
||||
update_search(state,val) {
|
||||
state.search=val
|
||||
},
|
||||
update_search_status(state,status) {
|
||||
state.search_status = status
|
||||
},
|
||||
update_pxs(state,data) {
|
||||
state.pxs= data.records
|
||||
state.total_px= data.total
|
||||
},
|
||||
update_selected_px(state,val) {
|
||||
state.selected_px=val
|
||||
},
|
||||
update_moucompany(state,val) {
|
||||
state.moucompany={companyid:val.T_OrderHeaderM_CompanyID,mouid:val.T_OrderHeaderM_MouID,orderdate:val.orderdate}
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
async search(context,prm) {
|
||||
context.commit("update_search_status",1)
|
||||
try {
|
||||
let resp= await api.search(context.state.search, context.state.moucompany.companyid,context.state.moucompany.mouid,context.state.moucompany.orderdate,prm)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_search_status",3)
|
||||
context.commit("update_search_error_message",resp.message)
|
||||
} else {
|
||||
context.commit("update_search_status",2)
|
||||
context.commit("update_search_error_message","")
|
||||
let data = {
|
||||
records : resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
context.commit("update_pxs",data)
|
||||
}
|
||||
} catch(e) {
|
||||
context.commit("update_search_status",3)
|
||||
context.commit("update_search_error_message",e.message )
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/status.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
lookup_status:0,
|
||||
lookup_error_message:'',
|
||||
statuses: [],
|
||||
total_status: 0,
|
||||
selected_status: {"id":2,"code":"FO.Verification","name":"Baru"}
|
||||
},
|
||||
mutations: {
|
||||
update_lookup_error_message(state,status) {
|
||||
state.search_error_message = status
|
||||
},
|
||||
update_lookup_status(state,status) {
|
||||
state.search_status = status
|
||||
},
|
||||
update_statuses(state,data) {
|
||||
state.statuses= data.records
|
||||
state.total_status= data.total
|
||||
},
|
||||
update_selected_status(state,val) {
|
||||
state.selected_status=val
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
async lookup(context) {
|
||||
context.commit("update_lookup_status",1)
|
||||
try {
|
||||
let resp= await api.lookup()
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_lookup_status",3)
|
||||
context.commit("update_lookup_error_message",resp.message)
|
||||
} else {
|
||||
context.commit("update_lookup_status",2)
|
||||
context.commit("update_lookup_error_message","")
|
||||
let data = {
|
||||
records : resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
context.commit("update_statuses",data)
|
||||
}
|
||||
} catch(e) {
|
||||
context.commit("update_lookup_status",3)
|
||||
context.commit("update_lookup_error_message",e.message )
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/supplies.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
save_status: 0,
|
||||
save_error_message: '',
|
||||
no_save: 0,
|
||||
btn_save_seen: true,
|
||||
pgrs_save: false,
|
||||
open_alert_supplies: false,
|
||||
msg_alert_supplies: "Yakin, belum disimpan lhoooo ?"
|
||||
},
|
||||
mutations: {
|
||||
update_save_status(state, val) {
|
||||
state.save_status = val
|
||||
},
|
||||
update_btn_save_seen(state, val) {
|
||||
state.btn_save_seen = val
|
||||
},
|
||||
update_pgrs_save(state, val) {
|
||||
state.pgrs_save = val
|
||||
},
|
||||
update_save_error_message(state, val) {
|
||||
state.save_error_message = val
|
||||
},
|
||||
update_no_save(state, val) {
|
||||
state.no_save = val
|
||||
},
|
||||
update_open_alert_supplies(state, val) {
|
||||
state.open_alert_supplies = val
|
||||
},
|
||||
update_msg_alert_supplies(state, val) {
|
||||
state.msg_alert_supplies = val
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
async save(context, prm) {
|
||||
context.commit("update_save_status", 1)
|
||||
context.commit("update_btn_save_seen", false)
|
||||
context.commit("update_pgrs_save", true)
|
||||
try {
|
||||
let resp = await api.save(one_token(),prm.orderid, prm.supplies,prm.barcode)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
} else {
|
||||
context.commit("update_save_status", 2)
|
||||
context.commit("update_save_error_message", resp.message)
|
||||
context.commit("update_no_save", 0)
|
||||
context.commit("update_btn_save_seen", true)
|
||||
context.commit("update_pgrs_save", false)
|
||||
let data = {
|
||||
records: resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
context.commit("verification/update_verification_supplies", data.records.supplies, { root: true })
|
||||
context.commit("verification/update_verification_barcode", data.records.barcode, { root: true })
|
||||
|
||||
}
|
||||
} catch (e) {
|
||||
context.commit("update_save_status", 3)
|
||||
context.commit("update_save_error_message", e.message)
|
||||
console.log(e)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
//import * as api from "../api/patient.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
supplies:[],
|
||||
barcodes:[]
|
||||
},
|
||||
mutations: {
|
||||
|
||||
},
|
||||
actions: {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
//import * as api from "../api/patient.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
verification_patient_name :{check:false,note:'',label:'Nama x sudah sesuai'},
|
||||
testing:'fajri ganteng',
|
||||
testingObj:{check:true,note:'sdvsdvds',label:'nama ne udah bener 1 ?'}
|
||||
},
|
||||
mutations: {
|
||||
update_patient_name(state,data) {
|
||||
state.verification_patient_name = data
|
||||
},
|
||||
update_testing(state,data) {
|
||||
state.testing = data
|
||||
},
|
||||
update_testing_obj(state,data) {
|
||||
state.testingObj = data
|
||||
},
|
||||
update_testing_txt(state,data) {
|
||||
state.testingObj.note = data
|
||||
},
|
||||
update_testing_cbx(state,data) {
|
||||
state.testingObj.check = data
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,132 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
//import * as api from "../api/patient.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
dialog_delivery_is_active: false,
|
||||
verification_patient: [
|
||||
{ 'id': 1, 'chex': false, 'note': '', 'label': 'Nama sudah sesuai' },
|
||||
{ 'id': 2, 'chex': false, 'note': '', 'label': 'No RM sudah sesuai' },
|
||||
{ 'id': 3, 'chex': false, 'note': '', 'label': 'Alamat sudah sesuai' },
|
||||
{ 'id': 4, 'chex': false, 'note': '', 'label': 'No HP sudah sesuai' },
|
||||
{ 'id': 5, 'chex': false, 'note': '', 'label': 'DOB sudah sesuai' },
|
||||
{ 'id': 6, 'chex': false, 'note': '', 'label': 'Umur sudah sesuai' }
|
||||
],
|
||||
verification_doctor: [
|
||||
{ 'id': 1, 'chex': false, 'note': '', 'label': 'Nama dokter sudah sesuai' },
|
||||
{ 'id': 2, 'chex': false, 'note': '', 'label': 'Alamat sudah sesuai' }
|
||||
],
|
||||
verification_delivery: [
|
||||
{ 'id': 1, 'chex': false, 'note': '', 'vilageid': 0, 'type': 'reguler', 'label': 'Email ke Dokter : emaildoctor@email.com' },
|
||||
{ 'id': 2, 'chex': false, 'note': '', 'vilageid': 2, 'type': 'indigo', 'label': 'Kirim ke Pasien : Jl. Padepokan Rindu No. 99 Tegal Barat' }
|
||||
],
|
||||
verification_payment: [
|
||||
{ 'id': 1, 'chex': false, 'note': '', 'type': 'reguler', 'label': 'Minimum pembayaran terpenuhi' }
|
||||
],
|
||||
verification_supplies: [
|
||||
{ 'id': 1, 'chex': false, 'qty': '', 'name': '-' }
|
||||
],
|
||||
verification_barcode: [
|
||||
{ 'id': 1, 'chex': false, 'qty': '', 'samplename': '-', 'barcodenumber': '-', 'qty': 1 }
|
||||
],
|
||||
verification_companymou: [
|
||||
{ 'id': 1, 'chex': false, 'note': '', 'label': 'Nama comany sudah sesuai' },
|
||||
{ 'id': 2, 'chex': false, 'note': '', 'label': 'Mou sudah sesuai' }
|
||||
],
|
||||
verification_px: [
|
||||
{ 'id': 1, 'chex': false, 'pxname': '', 'bruto': '-', 'discount': '-', 'total': 1, 'addon': false }
|
||||
],
|
||||
verification_info: [
|
||||
{ 'id': 6, 'chex': false, 'note': '', 'label': 'Receive sample only' }
|
||||
]
|
||||
},
|
||||
mutations: {
|
||||
update_dialog_delivery_is_active(state, status) {
|
||||
state.dialog_delivery_is_active = status
|
||||
},
|
||||
update_testing_txt_parent_patient(state, data) {
|
||||
state.verification_patient[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_patient(state, data) {
|
||||
state.verification_patient[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_patient(state, data) {
|
||||
state.verification_patient = data
|
||||
},
|
||||
update_verification_doctor(state, data) {
|
||||
state.verification_doctor = data
|
||||
},
|
||||
update_testing_txt_parent_doctor(state, data) {
|
||||
state.verification_doctor[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_doctor(state, data) {
|
||||
state.verification_doctor[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_delivery(state, data) {
|
||||
state.verification_delivery = data
|
||||
},
|
||||
update_testing_txt_parent_delivery(state, data) {
|
||||
state.verification_delivery[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_delivery(state, data) {
|
||||
state.verification_delivery[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_payment(state, data) {
|
||||
state.verification_payment = data
|
||||
},
|
||||
update_testing_txt_parent_payment(state, data) {
|
||||
state.verification_payment[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_payment(state, data) {
|
||||
state.verification_payment[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_supplies(state, data) {
|
||||
state.verification_supplies = data
|
||||
},
|
||||
update_testing_txt_parent_supplies(state, data) {
|
||||
state.verification_supplies[data.idx].qty = data.val
|
||||
},
|
||||
update_testing_cbx_parent_supplies(state, data) {
|
||||
state.verification_supplies[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_barcode(state, data) {
|
||||
state.verification_barcode = data
|
||||
},
|
||||
update_testing_qty_parent_barcode(state, data) {
|
||||
state.verification_barcode[data.idx].qty = data.val
|
||||
},
|
||||
update_testing_cbx_parent_barcode(state, data) {
|
||||
state.verification_barcode[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_company_mou(state, data) {
|
||||
state.verification_companymou = data
|
||||
},
|
||||
update_testing_txt_parent_company_mou(state, data) {
|
||||
state.verification_companymou[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_company_mou(state, data) {
|
||||
state.verification_companymou[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_px(state, data) {
|
||||
state.verification_px = data
|
||||
},
|
||||
update_testing_cbx_parent_px(state, data) {
|
||||
state.verification_px[data.idx].chex = data.val
|
||||
},
|
||||
update_verification_info(state, data) {
|
||||
state.verification_info = data
|
||||
},
|
||||
update_testing_txt_parent_info(state, data) {
|
||||
state.verification_info[data.idx].note = data.val
|
||||
},
|
||||
update_testing_cbx_parent_info(state, data) {
|
||||
state.verification_info[data.idx].chex = data.val
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/verificationdoctor.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
ohid:0,
|
||||
lookup_verification_doctor:0,
|
||||
lookup_error_message:'',
|
||||
verifications:[]
|
||||
},
|
||||
mutations: {
|
||||
update_ohid(state,val) {
|
||||
state.ohid = val
|
||||
},
|
||||
update_lookup_error_message(state,msg) {
|
||||
state.lookup_error_message = msg
|
||||
},
|
||||
update_lookup_verification_doctor(state,status) {
|
||||
state.lookup_verification_doctor = status
|
||||
},
|
||||
update_verifications(state,data) {
|
||||
state.verifications = data.records
|
||||
},
|
||||
update_txt_verication_doctor(state,data) {
|
||||
state.verifications[data.idx].note = data.val
|
||||
},
|
||||
update_cbx_verification_doctor(state,data) {
|
||||
state.verifications[data.idx].check = data.val
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
async lookup(context,prm) {
|
||||
if(context.state.ohid !== prm.ohid){
|
||||
context.commit("update_lookup_verification_doctor",1)
|
||||
try {
|
||||
let resp= await api.lookup(prm.ohid)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_lookup_verification_doctor",3)
|
||||
context.commit("update_lookup_error_message",resp.message)
|
||||
} else {
|
||||
context.commit("update_lookup_verification_doctor",2)
|
||||
context.commit("update_lookup_error_message","")
|
||||
let data = {
|
||||
records : resp.data.records
|
||||
}
|
||||
context.commit("update_verifications",data)
|
||||
context.commit("update_ohid",prm.ohid)
|
||||
}
|
||||
} catch(e) {
|
||||
context.commit("lookup_verification_doctor",3)
|
||||
context.commit("update_lookup_error_message",e.message )
|
||||
console.log(e)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
// 1 => LOADING
|
||||
// 2 => DONE
|
||||
// 3 => ERROR
|
||||
import * as api from "../api/vilage.js"
|
||||
|
||||
export default {
|
||||
namespaced: true,
|
||||
state: {
|
||||
search_status : 0,
|
||||
vilages:[],
|
||||
total_vilages: 0,
|
||||
selected_vilage: {}
|
||||
},
|
||||
mutations: {
|
||||
update_search_error_message(state,status) {
|
||||
state.search_error_message = status
|
||||
},
|
||||
update_search(state,val) {
|
||||
state.search=val
|
||||
},
|
||||
update_search_status(state,status) {
|
||||
state.search_status = status
|
||||
},
|
||||
update_vilages(state,data) {
|
||||
state.vilages= data.records
|
||||
state.total_vilages= data.total
|
||||
},
|
||||
update_selected_vilage(state,val) {
|
||||
state.selected_vilage=val
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
async search(context,prm) {
|
||||
context.commit("update_search_status",1)
|
||||
try {
|
||||
let resp= await api.search(context.state.search)
|
||||
if (resp.status != "OK") {
|
||||
context.commit("update_search_status",3)
|
||||
context.commit("update_search_error_message",resp.message)
|
||||
} else {
|
||||
context.commit("update_search_status",2)
|
||||
context.commit("update_search_error_message","")
|
||||
let data = {
|
||||
records : resp.data.records,
|
||||
total: resp.data.total
|
||||
}
|
||||
context.commit("update_vilages",data)
|
||||
}
|
||||
} catch(e) {
|
||||
context.commit("update_search_status",3)
|
||||
context.commit("update_search_error_message",e.message )
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
43
test/vuex/one-fo-verification-simple-barcode/store.js
Normal file
43
test/vuex/one-fo-verification-simple-barcode/store.js
Normal file
@@ -0,0 +1,43 @@
|
||||
// State
|
||||
// data ...
|
||||
// Mutations
|
||||
//
|
||||
//
|
||||
// Actions
|
||||
import status from "./modules/status.js";
|
||||
import patient from "./modules/patient.js";
|
||||
import verification from "./modules/verification.js";
|
||||
import verificationdoctor from "./modules/verificationdoctor.js";
|
||||
import vilage from "./modules/vilage.js";
|
||||
import px from "./modules/px.js";
|
||||
import delivery from "./modules/delivery.js";
|
||||
import supplies from "./modules/supplies.js";
|
||||
import system from "../../../apps/modules/system/system.js";
|
||||
import done from "./modules/done.js";
|
||||
export const store = new Vuex.Store({
|
||||
modules: {
|
||||
status: status,
|
||||
patient: patient,
|
||||
verification: verification,
|
||||
verificationdoctor: verificationdoctor,
|
||||
vilage: vilage,
|
||||
px: px,
|
||||
delivery: delivery,
|
||||
supplies: supplies,
|
||||
system: system,
|
||||
done:done
|
||||
},
|
||||
state: {
|
||||
tab_selected: 'pasien-dokter'
|
||||
},
|
||||
mutations: {
|
||||
change_tab(state, ntab) {
|
||||
state.tab_selected = ntab
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
change_tab(context, ntab) {
|
||||
context.commit('change_tab', ntab)
|
||||
}
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user