Browse Source

parsIcCardtoLocal

master
pengjun 5 months ago
parent
commit
cea96cd124
  1. 40
      src/components/webBooking/WebBooking.vue
  2. 63
      src/components/webBooking/WebBookingMzak.vue

40
src/components/webBooking/WebBooking.vue

@ -60,8 +60,8 @@
</el-table> </el-table>
<el-table :data="tableDataDetails" border style="width: 100%" row-key="id" height="300" highlight-current-row <el-table :data="tableDataDetails" border style="width: 100%" row-key="id" height="300" highlight-current-row
:summary-method="getSummaries" show-summary size="small" ref="webBookingDetaills">
<el-table-column label="序号" width="40" type="index"/>
:summary-method="getSummaries" show-summary size="small" ref="webBookingDetaills">
<el-table-column label="序号" width="40" type="index" />
<el-table-column label="已选组合项目" min-width="150" prop="asbitemName"> <el-table-column label="已选组合项目" min-width="150" prop="asbitemName">
<template slot-scope="scope"> <template slot-scope="scope">
<div> <div>
@ -76,17 +76,17 @@
<el-table-column label="标准价格" prop="standardPrice" min-width="70" align="center" /> <el-table-column label="标准价格" prop="standardPrice" min-width="70" align="center" />
<el-table-column label="折扣" prop="discount" min-width="60"> <el-table-column label="折扣" prop="discount" min-width="60">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input type="number" v-model="scope.row.discount" size="small" disabled/>
<el-input type="number" v-model="scope.row.discount" size="small" disabled />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="数量" prop="amount" min-width="50"> <el-table-column label="数量" prop="amount" min-width="50">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input type="number" v-model="scope.row.amount" size="small" disabled/>
<el-input type="number" v-model="scope.row.amount" size="small" disabled />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="实收价格" prop="chargePrice" min-width="70"> <el-table-column label="实收价格" prop="chargePrice" min-width="70">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input type="number" v-model="scope.row.chargePrice" size="small" disabled/>
<el-input type="number" v-model="scope.row.chargePrice" size="small" disabled />
<!--立即触发保存 @blur="onSubmit('')" --> <!--立即触发保存 @blur="onSubmit('')" -->
</template> </template>
</el-table-column> </el-table-column>
@ -118,7 +118,7 @@
<script> <script>
import { mapState } from "vuex"; import { mapState } from "vuex";
import { getapi, postapi, putapi, deletapi } from "@/api/api"; import { getapi, postapi, putapi, deletapi } from "@/api/api";
import { dddw, deepCopy } from "../../utlis/proFunc";
import { dddw, deepCopy, parsIcCardtoLocal } from "../../utlis/proFunc";
import moment from "moment"; import moment from "moment";
@ -303,14 +303,14 @@ export default {
async rowClick(row) { async rowClick(row) {
// chargeFlag string 0- 1- 2-退 // chargeFlag string 0- 1- 2-退
this.currRowData = Object.assign({},row)
this.currRowData = Object.assign({}, row)
this.tableDataDetails = [] this.tableDataDetails = []
let sysParmId = "small_program_individual_appointment_mandatory_fee" let sysParmId = "small_program_individual_appointment_mandatory_fee"
let sysParam = await postapi('/api/app/SysParmValue/GetSysParmValueBySysParmId', { sysParmId }) let sysParam = await postapi('/api/app/SysParmValue/GetSysParmValueBySysParmId', { sysParmId })
// //
if (sysParam.data == '1'){
if(row.chargeFlag != '1'){
if (sysParam.data == '1') {
if (row.chargeFlag != '1') {
this.$message.warning({ showClose: true, message: "该预约未缴费,不可进行登记" }) this.$message.warning({ showClose: true, message: "该预约未缴费,不可进行登记" })
this.currRowData = {} this.currRowData = {}
return return
@ -324,17 +324,17 @@ export default {
}).then(res => { }).then(res => {
if (res.code > -1) { if (res.code > -1) {
res.data.forEach(e => { res.data.forEach(e => {
e.discount = e.standardPrice == 0 ? 100: Math.floor(e.chargePrice * 10000/e.standardPrice)/100
if(!e.isBelongGroupPackage){
e.isBelongGroupPackage = e.isInMedicalPackage
}
// e.standTotal = e.amount * e.standardPrice
if(this.currRowData.chargeFlag == '1'){
e.isCharge = 'Y'
e.chargeSourceFlag = '1' // 0-1-2-HIS
}
e.total = e.amount * e.chargePrice
});
e.discount = e.standardPrice == 0 ? 100 : Math.floor(e.chargePrice * 10000 / e.standardPrice) / 100
if (!e.isBelongGroupPackage) {
e.isBelongGroupPackage = e.isInMedicalPackage
}
// e.standTotal = e.amount * e.standardPrice
if (this.currRowData.chargeFlag == '1') {
e.isCharge = 'Y'
e.chargeSourceFlag = '1' // 0-1-2-HIS
}
e.total = e.amount * e.chargePrice
});
this.tableDataDetails = res.data this.tableDataDetails = res.data
} }

63
src/components/webBooking/WebBookingMzak.vue

@ -9,11 +9,11 @@
<el-option v-for="item in thirdInterfaces" :key="item.id" :label="item.displayName" :value="item.id" /> <el-option v-for="item in thirdInterfaces" :key="item.id" :label="item.displayName" :value="item.id" />
</el-select> </el-select>
--> -->
<el-date-picker v-model="query.startDate" type="date" placeholder="起始日期" size="small"
style="width:90px;" value-format="yyyy-MM-dd" :picker-options="{disabledDate:false,shortcuts:pickerOptions.shortcuts}" />
<el-date-picker v-model="query.startDate" type="date" placeholder="起始日期" size="small" style="width:90px;"
value-format="yyyy-MM-dd" :picker-options="{ disabledDate: false, shortcuts: pickerOptions.shortcuts }" />
<span class="spanClass"></span> <span class="spanClass"></span>
<el-date-picker v-model="query.endDate" type="date" placeholder="截止日期" size="small"
style="width:90px;" value-format="yyyy-MM-dd" :picker-options="{disabledDate:false,shortcuts:pickerOptions.shortcuts}"/>
<el-date-picker v-model="query.endDate" type="date" placeholder="截止日期" size="small" style="width:90px;"
value-format="yyyy-MM-dd" :picker-options="{ disabledDate: false, shortcuts: pickerOptions.shortcuts }" />
</div> </div>
<div class="query"> <div class="query">
<span class="spanClass">检索关键字</span> <span class="spanClass">检索关键字</span>
@ -22,22 +22,24 @@
<div class="query"> <div class="query">
<span class="spanClass">状态</span> <span class="spanClass">状态</span>
<el-select v-model="query.medicalStatus" placeholder="请选择" clearable style="width: 80px" size="small"> <el-select v-model="query.medicalStatus" placeholder="请选择" clearable style="width: 80px" size="small">
<el-option v-for="item in localDict.medicalStatus" :key="item.value" :label="item.label" :value="item.value">
<el-option v-for="item in localDict.medicalStatus" :key="item.value" :label="item.label"
:value="item.value">
</el-option> </el-option>
</el-select> </el-select>
</div> </div>
</div> </div>
<div style="margin-top: -38px;width: 160px;"> <div style="margin-top: -38px;width: 160px;">
<div> <div>
<el-button @click="peopleIcCard" size="small" class="commonbutton" style="width:160px;font-size: 14px;">读身份证</el-button>
<el-button @click="peopleIcCard" size="small" class="commonbutton"
style="width:160px;font-size: 14px;">读身份证</el-button>
</div> </div>
<div style="display: flex;"> <div style="display: flex;">
<el-button size="small" class="commonbutton" @click="btnQuery" style="margin-top: 6px; width:60px;">查询</el-button>
<el-button size="small" class="commonbutton" @click="btnQuery"
style="margin-top: 6px; width:60px;">查询</el-button>
<el-button @click="handleExport" size="small" class="commonbutton" style="margin-top: 6px; width:100px;"
>导出excel</el-button
>
</div>
<el-button @click="handleExport" size="small" class="commonbutton"
style="margin-top: 6px; width:100px;">导出excel</el-button>
</div>
</div> </div>
</div> </div>
<div> <div>
@ -62,9 +64,9 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="预约编号" width="120" prop="thirdBookingId" align="center" /> <el-table-column label="预约编号" width="120" prop="thirdBookingId" align="center" />
<el-table-column label="状态" width="50" prop="medicalStatus" align="center" >
<el-table-column label="状态" width="50" prop="medicalStatus" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ dddw(localDict.medicalStatus,'value',scope.row.medicalStatus,'label') }}
{{ dddw(localDict.medicalStatus, 'value', scope.row.medicalStatus, 'label') }}
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -87,10 +89,11 @@
<script> <script>
import { mapState } from "vuex"; import { mapState } from "vuex";
import { getapi, postapi, putapi, deletapi } from "@/api/api"; import { getapi, postapi, putapi, deletapi } from "@/api/api";
import { dddw, deepCopy } from "../../utlis/proFunc";
import { dddw, deepCopy, parsIcCardtoLocal } from "../../utlis/proFunc";
import moment from "moment"; import moment from "moment";
import { exportToExcel } from "../../utlis/Export2Excel"; import { exportToExcel } from "../../utlis/Export2Excel";
export default { export default {
components: { components: {
@ -108,17 +111,17 @@ export default {
appointStartDate: "", appointStartDate: "",
appointStopDate: "", appointStopDate: "",
completeFlag: "0", completeFlag: "0",
keyWord:'',
startDate:'',
endDate:'',
medicalStatus:'0'
keyWord: '',
startDate: '',
endDate: '',
medicalStatus: '0'
}, },
asbDesc: '', // asbDesc: '', //
localDict:{
medicalStatus:[
{label:'未开始',value:'0'}, // 0 1 2
{label:'已登记',value:'1'},
{label:'已完成',value:'2'},
localDict: {
medicalStatus: [
{ label: '未开始', value: '0' }, // 0 1 2
{ label: '已登记', value: '1' },
{ label: '已完成', value: '2' },
] ]
} }
}; };
@ -157,9 +160,9 @@ export default {
dddw, dddw,
funMounted() { funMounted() {
this.dictInit() this.dictInit()
// .then(res => {
// //this.btnQuery()
// })
// .then(res => {
// //this.btnQuery()
// })
}, },
// //
@ -311,7 +314,7 @@ export default {
this.dialogWin.WebBookingMzak = false this.dialogWin.WebBookingMzak = false
}, },
dataTrans(curRow){
dataTrans(curRow) {
// { // // { //
// "appointPatientRegisterId": "string", // "appointPatientRegisterId": "string",
// "personId": "string", // "personId": "string",
@ -353,9 +356,9 @@ export default {
// "customerOrgRegisterId": "3fa85f64-5717-4562-b3fc-2c963f66afa6", // "customerOrgRegisterId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
// "customerOrgId": "3fa85f64-5717-4562-b3fc-2c963f66afa6" // "customerOrgId": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
// } // }
let ret = Object.assign({},curRow,{
mobileTelephone:curRow.phone,
personName:curRow.patientName
let ret = Object.assign({}, curRow, {
mobileTelephone: curRow.phone,
personName: curRow.patientName
}) })
return ret return ret

Loading…
Cancel
Save