123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847 |
- <template>
- <div style="background-color: #f0f2f5; padding-bottom: 20px; min-height: 100%; " >
- <div style="padding: 20px; background-color: #fff;">
- 订单详情
- </div>
- <div class="contentx" v-if="item!=null">
- <div class="desct">
- </div>
- <div class="order-status" v-if="item!=null" >
- <el-steps :active="item.status==4?item.status:item.status-1" align-center finish-status="success">
- <el-step :title="item.dictLabel" v-for="(item,index) in inquiryStatusOptions" v-if="index<4"></el-step>
- </el-steps>
- </div>
- <el-card shadow="never" style="margin-top: 15px">
- <div class="operate-container" v-if="item!=null">
- <span style="margin-left: 20px" class="color-danger">订单状态:
- <el-tag prop="status" v-for="(ite, index) in inquiryStatusOptions" v-if="item.status==ite.dictValue">{{ite.dictLabel}}</el-tag>
- </span>
- <div class="operate-button-container" >
- <el-button size="mini" @click="cancelorder()" v-if="item.status==2 && item.packageOrderId==null">取消订单</el-button>
- </div>
- <div class="operate-button-container" >
- <el-button size="mini" @click="refundorder()" v-if="item.status<1" v-hasPermi="['his:inquiryOrder:refundOrder']" >退款</el-button>
- </div>
- <div class="operate-button-container" >
- <el-button size="mini" @click="editStatus()" v-hasPermi="['his:inquiryOrder:editStatus']">修改订单</el-button>
- </div>
- <div class="operate-button-container" >
- <el-button size="mini" @click="sendInquiryMsg()" v-if="item.status==3" v-hasPermi="['his:inquiryOrder:sendMsg']">发送消息</el-button>
- </div>
- <div class="operate-button-container" >
- <el-button size="mini" @click="handledetails()" v-hasPermi="['his:inquiryOrderReport:query']">咨询报告</el-button>
- </div>
- <div class="operate-button-container" >
- <el-button size="mini" @click="handlePatient()" v-hasPermi="['his:inquiryOrderReport:query']">患者诊断数据</el-button>
- </div>
- </div>
- <div class="desct">
- 基本信息
- </div>
- <el-descriptions title="" :column="3" border>
- <el-descriptions-item label="订单号" ><span v-if="item!=null">{{item.orderSn}}</span></el-descriptions-item>
- <el-descriptions-item label="订单类型" ><dict-tag :options="inquiryTypeOptions" :value="item.inquiryType"/></el-descriptions-item>
- <el-descriptions-item label="优惠金额" ><span v-if="item!=null">{{item.discountMoney}}</span></el-descriptions-item>
- <el-descriptions-item label="订单金额" ><span v-if="item!=null">{{item.money}}</span></el-descriptions-item>
- <el-descriptions-item label="支付金额" ><span v-if="item!=null">{{item.payMoney}}</span></el-descriptions-item>
- <el-descriptions-item label="支付类型" ><span v-if="item!=null">{{item.payType}}</span></el-descriptions-item>
- <el-descriptions-item label="是否支付" ><dict-tag :options="orOptions" :value="item.isPay"/></el-descriptions-item>
- <el-descriptions-item label="支付时间" ><span v-if="item!=null">{{item.payTime}}</span></el-descriptions-item>
- <el-descriptions-item label="状态" ><dict-tag :options="inquiryStatusOptions" :value="item.status"/></el-descriptions-item>
- <el-descriptions-item label="创建时间" ><span v-if="item!=null">{{item.createTime}}</span></el-descriptions-item>
- <el-descriptions-item :label="item.inquiryType==1?'问诊标题':'咨询标题'" ><span v-if="item!=null">{{item.title}}</span></el-descriptions-item>
- <el-descriptions-item label="患者姓名" ><span v-if="item!=null">{{item.patientName}}</span></el-descriptions-item>
- <el-descriptions-item label="科室" ><span v-if="item!=null">{{item.deptName}}</span></el-descriptions-item>
- <el-descriptions-item label="优惠劵发送人" ><span v-if="item!=null">{{item.sendName}}</span></el-descriptions-item>
- <el-descriptions-item label="咨询类型" ><dict-tag :options="inquiryTypeOptions" :value="item.inquiryType"/></el-descriptions-item>
- <el-descriptions-item label="审核人" ><span v-if="item!=null">{{item.userName}}</span></el-descriptions-item>
- <el-descriptions-item label="审核时间" ><span v-if="item!=null">{{item.auditTime}}</span></el-descriptions-item>
- <el-descriptions-item label="咨询开始时间" ><span v-if="item!=null">{{item.startTime}}</span></el-descriptions-item>
- <el-descriptions-item label="结束时间" ><span v-if="item!=null">{{item.finishTime}}</span></el-descriptions-item>
- <el-descriptions-item label="备注" ><span v-if="item!=null">{{item.companyUserRemark}}</span></el-descriptions-item>
- </el-descriptions>
- </el-card>
- <el-dialog
- title="聊天记录"
- :visible.sync="dialogVisible"
- width="80%"
- :before-close="handleClose1" append-to-body >
- <msgDetails ref="msgDetails" :msgDialogClose="msgDialogClose" />
- <span slot="footer" class="dialog-footer">
- <el-button @click="dialogVisible = false">取 消</el-button>
- <el-button type="primary" @click="dialogVisible = false">确 定</el-button>
- </span>
- </el-dialog>
- <el-dialog
- title="处方单"
- :visible.sync="editStatusOpen"
- width="60%"
- append-to-body >
- <el-form ref="form" :model="statusForm" label-width="120px">
- <el-form-item label="订单状态" prop="status">
- <el-select v-model="statusForm.status" placeholder="订单状态">
- <el-option
- v-for="dict in inquiryStatusOptions"
- :key="dict.dictValue"
- :label="dict.dictLabel"
- :value="parseInt(dict.dictValue)"
- />
- </el-select>
- </el-form-item>
- </el-form>
- <span slot="footer" class="dialog-footer">
- <el-button @click="editStatusOpen = false">取 消</el-button>
- <el-button type="primary" @click="editStatusOpenOk">确 定</el-button>
- </span>
- </el-dialog>
- <el-dialog
- title="患者问诊数据"
- :visible.sync="patientOpen"
- width="1000px"
- append-to-body>
- <el-form ref="patientForm" :model="patientForm" label-width="110px" >
- <el-row>
- <el-col :span="12">
- <el-form-item label="患者姓名" prop="patientName">
- <el-input disabled v-model="item.patientName"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="患者性别" prop="sex">
- <el-select disabled v-model="JSON.parse(item.patientJson).sex">
- <el-option label="男" :value = "1"></el-option>
- <el-option label="女" :value = "0"></el-option>
- </el-select>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <el-form-item label="患者年龄" prop="age">
- <el-input disabled v-model="JSON.parse(item.patientJson).age"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="患者电话" prop="mobile">
- <el-input disabled v-model="JSON.parse(item.patientJson).mobile"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <el-form-item label="患者会员电话" prop="userPhone">
- <el-input disabled v-model="patientForm.userPhone"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="客户标签" prop="tag">
- <el-input v-model="patientForm.tag"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <el-form-item label="客服姓名" prop="companyUserName">
- <el-input disabled v-model="patientForm.companyUserName"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="课程档期" prop="courseName">
- <el-input v-model="patientForm.courseName"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <el-form-item label="预约医生" prop="doctorName">
- <el-input disabled v-model="item.doctorName"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="会诊时间" prop="subTime">
- <el-date-picker
- v-model="patientForm.subTime"
- type="date"
- value-format="yyyy-MM-dd"
- placeholder="选择日期">
- </el-date-picker>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <el-form-item label="就诊状态" prop="sex">
- <el-select v-model="patientForm.diagnosisStatus">
- <el-option label="初诊" :value = "1"></el-option>
- <el-option label="复诊" :value = "2"></el-option>
- </el-select>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="部门负责人" prop="deptManager">
- <el-input v-model="patientForm.deptManager"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-form-item label="患者病情主诉">
- <el-input
- type="textarea"
- placeholder="请输入内容"
- v-model="patientForm.patientCondition">
- </el-input>
- </el-form-item>
- <div class="contentx">
- <div class="desct">
- 医生建议及处置
- </div>
- </div>
- <el-form-item label="诊断">
- <el-input
- type="textarea"
- placeholder="请输入内容"
- v-model="patientForm.doctorAdviceJson.diagnosis">
- </el-input>
- </el-form-item>
- <el-form-item label="饮食方面">
- <el-input
- type="textarea"
- placeholder="请输入内容"
- v-model="patientForm.doctorAdviceJson.foodAdvice">
- </el-input>
- </el-form-item>
- <el-form-item label="运动方面">
- <el-input
- type="textarea"
- placeholder="请输入内容"
- v-model="patientForm.doctorAdviceJson.sportAdvice">
- </el-input>
- </el-form-item>
- <el-form-item label="保健方面">
- <el-input
- type="textarea"
- placeholder="请输入内容"
- v-model="patientForm.doctorAdviceJson.healthAdvice">
- </el-input>
- </el-form-item>
- <el-form-item label="注意禁忌">
- <el-input
- type="textarea"
- placeholder="请输入内容"
- v-model="patientForm.taboo">
- </el-input>
- </el-form-item>
- <el-form-item label="客户需求">
- <el-input v-model="patientForm.customerRequire"></el-input>
- </el-form-item>
- <el-row>
- <el-col :span="12">
- <el-form-item label="职业医师" prop="age">
- <el-input v-model="patientForm.professionalDoctor"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="医生助理" prop="mobile">
- <el-input v-model="patientForm.assistantDoctor"></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <div class="contentx">
- <div class="desct">
- 治疗方面
- </div>
- </div>
- <div v-for="(i,index) in patientForm.doctorAdviceJson.treatmentAdvice" :key="index">
- <el-row>
- <el-col :span="8">
- <el-form-item label="诊断内容" prop="content">
- <el-input v-model="i.content"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="建议治疗" prop="advice">
- <el-input v-model="i.advice"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-button style="margin: 5px;" v-if="index+1 == patientForm.doctorAdviceJson.treatmentAdvice.length" @click="addItem(patientForm.doctorAdviceJson.treatmentAdvice.length)" type="primary" size="mini">+</el-button>
- <el-button style="margin: 5px;" v-if="index !== 0" type="danger" size="mini" @click="delItem(i,index)">-</el-button>
- </el-col>
-
- </el-row>
- </div>
- </el-form>
- <span slot="footer" class="dialog-footer">
- <el-button @click="patientOpen = false">取 消</el-button>
- <el-button type="primary" @click="patientInquirySubmit">确 定</el-button>
- </span>
- </el-dialog>
- </div>
- <div class="contentx" v-if="item!=null">
- <div class="desct">
- 咨询内容
- </div>
- <el-descriptions title="" :column="3" border>
- <el-descriptions-item label="患者姓名" ><span v-if="item!=null">{{JSON.parse(item.patientJson).patientName}}</span></el-descriptions-item>
- <el-descriptions-item label="患者年龄" ><span v-if="item!=null">{{JSON.parse(item.patientJson).age}}</span></el-descriptions-item>
- <el-descriptions-item label="患者性别" ><span >{{JSON.parse(item.patientJson).sex==1?'男':'女'}}</span></el-descriptions-item>
- <el-descriptions-item label="身份证号" ><span >{{JSON.parse(item.patientJson).idCard}}</span></el-descriptions-item>
- <el-descriptions-item label="是否就诊" > <span >就诊过</span></el-descriptions-item>
- <el-descriptions-item label="电话" ><span v-if="item!=null">{{JSON.parse(item.patientJson).mobile}}</span></el-descriptions-item>
- <el-descriptions-item label="学习周期" ><span v-if="item!=null">{{JSON.parse(item.patientJson).study}}</span></el-descriptions-item>
- <el-descriptions-item label="期望咨询方式" ><span >语音咨询</span></el-descriptions-item>
- <el-descriptions-item label="用药情况" ><span v-if="item!=null">{{JSON.parse(item.patientJson).medication}}</span></el-descriptions-item>
- <el-descriptions-item label="咨询时间" ><span v-if="item!=null">{{item.startTime}}</span></el-descriptions-item>
- <el-descriptions-item :label="item.inquiryType==1?'主诉':'咨询问题'" span="3"><span v-if="item!=null">{{JSON.parse(item.patientJson).title}}</span></el-descriptions-item>
- <el-descriptions-item label="面部照片" span="3">
- <el-image v-if="faceImages!=null&&faceImages!=''" v-for="img in faceImages" :key="img.id"
- style="width: 100px"
- :src="img"
- :preview-src-list="[img]">
- </el-image>
- </el-descriptions-item>
- <el-descriptions-item label="舌苔照片" span="3">
- <el-image v-if="tongueImages!=null&&tongueImages!=''" v-for="img in tongueImages" :key="img.id"
- style="width: 100px"
- :src="img"
- :preview-src-list="[img]">
- </el-image>
- </el-descriptions-item>
- <el-descriptions-item label="检测报告或患病证书" span="3">
- <el-image v-if="imgs!=null&&imgs!=''" v-for="img in imgs" :key="img.id"
- style="width: 100px"
- :src="img"
- :preview-src-list="[img]">
- </el-image>
- </el-descriptions-item>
- </el-descriptions>
- </div>
- <div class="contentx" v-if="item!=null">
- <div class="desct">
- 评价信息
- </div>
- <el-descriptions title="" :column="3" border>
- <el-descriptions-item label="患者姓名" >
- <span v-if="item!=null">{{item.patientName}}</span>
- </el-descriptions-item>
- <el-descriptions-item label="是否评价" >
- <dict-tag :options="orOptions" :value="item.isPing"/>
- </el-descriptions-item>
- <el-descriptions-item label="评分" >
- <el-rate v-if="item.pingStar!=null"
- v-model="item.pingStar"
- disabled
- show-score
- text-color="#ff9900"
- score-template="{value}">
- </el-rate>
- </el-descriptions-item>
- <el-descriptions-item label="聊天记录" >
- <el-link type="primary" @click="getSerivceMsg" :underline="false" v-if="item.title=='服务问诊'">查看聊天记录</el-link>
- <el-link type="primary" disabled :underline="false" v-if="(msg==null || msg=='')&&item.title!='服务问诊' ">无聊天记录</el-link>
- <el-link type="primary" @click="getMsg" :underline="false" v-if="msg!=null && msg!='' ">查看聊天记录</el-link>
- </el-descriptions-item>
- <el-descriptions-item label="评价内容" >
- <span v-if="item!=null">{{item.pingContent}}</span>
- </el-descriptions-item>
- <el-descriptions-item label="医生回复" >
- <span v-if="item!=null">{{item.replyContent}}</span>
- </el-descriptions-item>
- </el-descriptions>
- </div>
- <div class="contentx" v-if="item!=null">
- <div class="desct">
- {{item.inquiryType==3?'药师信息':'医生信息'}}
- </div>
- <el-descriptions title="" :column="3" border >
- <el-descriptions-item :label="item.inquiryType==3?'药师姓名':'医生姓名'" >
- <span v-if="doctor!=null">{{doctor.doctorName}}</span>
- </el-descriptions-item>
- <el-descriptions-item label="工作照" >
- <el-popover v-if="doctor.avatar!=null"
- placement="right"
- title=""
- trigger="hover">
- <img slot="reference" :src="doctor.avatar" width="50px">
- <img :src="doctor.avatar" style="max-width: 150px;">
- </el-popover>
- </el-descriptions-item>
- <el-descriptions-item label="所属医院" >
- <span v-if="doctor!=null">{{doctor.hospitalName}}</span>
- </el-descriptions-item>
- <el-descriptions-item label="科室名称" >
- <span v-if="doctor!=null">{{doctor.deptName}}</span>
- </el-descriptions-item>
- <el-descriptions-item label="职务" >
- <span v-if="doctor!=null"><dict-tag :options="positionOptions" :value="doctor.position"/></span>
- </el-descriptions-item>
- <el-descriptions-item label="评分" >
- <span v-if="doctor!=null">
- <el-rate
- v-model="doctor.pingStar"
- disabled
- show-score
- text-color="#ff9900"
- score-template="{value}">
- </el-rate>
- </span>
- </el-descriptions-item>
- <el-descriptions-item label="平均响应速度" >
- <span v-if="doctor!=null">{{doctor.speed}}</span>
- </el-descriptions-item>
- <el-descriptions-item label="性别" >
- <dict-tag :options="sexOptions" :value="doctor.sex"/>
- </el-descriptions-item>
- <el-descriptions-item label="是否专家" >
- <dict-tag :options="orOptions" :value="doctor.isExpert"/>
- </el-descriptions-item>
- <el-descriptions-item :label="item.inquiryType==3?'药师简介':'医生简介'" >
- <span v-if="doctor!=null">{{doctor.introduction}}</span>
- </el-descriptions-item>
- </el-descriptions>
- </div>
- <div class="contentx" v-if="item!=null">
- <div class="desct">
- 操作信息
- </div>
- <el-table style="margin-top: 20px;width: 100%"
- ref="orderHistoryTable"
- :data="logs" border>
- <el-table-column label="操作时间" width="160" align="center">
- <template slot-scope="scope">
- {{scope.row.changeTime}}
- </template>
- </el-table-column>
- <el-table-column label="备注" align="center">
- <template slot-scope="scope">
- {{scope.row.changeMessage}}
- </template>
- </el-table-column>
- </el-table>
- </div>
- <el-drawer
- :with-header="false"
- :append-to-body="true"
- size="75%"
- :title="show.title" :visible.sync="show.open">
- <inquiryOrderReportDetails ref="Details" />
- </el-drawer>
- <el-dialog title="聊天记录" :visible.sync="msgServiceDetails.open" width="80%" append-to-body >
- <msgServiceDetails ref="msgServiceDetails" :msgServiceDetailsClose="msgServiceDetailsClose" />
- <span slot="footer" class="dialog-footer">
- <el-button @click="msgServiceDetailsClose">取 消</el-button>
- <el-button type="primary" @click="msgServiceDetailsClose">确 定</el-button>
- </span>
- </el-dialog>
- </div>
- </template>
- <script>
- import { msglist, sendMsg,listinquiryOrder,editStatus, logList,getinquiryOrder, delinquiryOrder, addinquiryOrder, updateinquiryOrder, exportinquiryOrder ,cancelOrder,refundOrder} from "@/api/his/inquiryOrder";
- import {addinquiryPatient, updateinquiryPatient, detail} from "@/api/his/inquiryPatient";
- import {getReportId} from "@/api/his/inquiryOrderReport";
- import msgDetails from '../../components/his/msgDetails.vue';
- import msgServiceDetails from '../../components/his/msgServiceDetails.vue';
- import {getDoctor} from '../../../api/his/doctor.js';
- import { getPatient } from "@/api/his/patient";
- import {getUser} from "@/api/his/user";
- import inquiryOrderReportDetails from '../../components/his/inquiryOrderReportDetails.vue';
- import {getPrescribe,getDrugInfo} from "@/api/his/prescribe";
- import { js } from "js-beautify";
- export default {
- name: "user",
- components: { inquiryOrderReportDetails,msgDetails ,msgServiceDetails},
- data() {
- return {
- patientOpen: false,
- logs:[],
- editStatusOpen:false,
- usageJson:{},
- show:{
- open:false,
- },
- prescribeItem:{},
- prod:[],
- prescribeDialog:false,
- imgs:[],
- msgForm:{
- pageNum: 1,
- pageSize: 10,
- orderId:null,
- },
- statusForm:{
- orderId: null,
- status: null,
- },
- msgServiceDetails:{
- title:"",
- open:false
- },
- // 总条数
- total: 0,
- faceImages:[],
- tongueImages:[],
- dialogVisible:false,
- msg:[],
- positionOptions: [],
- inquiryStatusOptions:[],
- inquiryTypeOptions:[],
- inquiryPayOptions:[],
- inquiryOrderOptions:[],
- orOptions:[],
- item:null,
- patient:[],
- doctor:[],
- user:[],
- sexOptions: [],
- patientForm: {
- doctorAdviceJson: {
- diagnosis: '',
- foodAdvice: '',
- sportAdvice: '',
- healthAdvice: '',
- treatmentAdvice: [
- //默认一条
- {
- content: '',
- advice: '',
- }
- ]
- }
- },
- }
- },
- created() {
- this.getDicts("sys_sex").then(response => {
- this.sexOptions = response.data;
- });
- this.getDicts("sys_doc_position").then(response => {
- this.positionOptions = response.data;
- });
- this.getDicts("sys_inquiry_status").then(response => {
- this.inquiryStatusOptions = response.data;
- });
- this.getDicts("sys_inquiry_type").then(response => {
- this.inquiryTypeOptions = response.data;
- });
- this.getDicts("sys_inquiry_pay").then(response => {
- this.inquiryPayOptions = response.data;
- });
- this.getDicts("sys_inquiry_order_type").then(response => {
- this.inquiryOrderOptions = response.data;
- });
- this.getDicts("sys_company_or").then(response => {
- this.orOptions = response.data;
- });
- },
- methods: {
- addItem(length){
- this.patientForm.doctorAdviceJson.treatmentAdvice.push({
- content:'',
- advice:'',
- })
- let ak = this.patientForm.doctorAdviceJson.treatmentAdvice.filter(obj => obj.content != '');
- },
- delItem(item,index){
- this.patientForm.doctorAdviceJson.treatmentAdvice.splice(index,1)
- },
- handlePatient(){
- this.patientOpen = true;
- detail(this.item.orderId).then(res => {
- this.patientForm = res.data;
- if(!this.patientForm.doctorAdviceJson) {
- this.patientForm.doctorAdviceJson = {
- diagnosis: '',
- foodAdvice: '',
- sportAdvice: '',
- healthAdvice: '',
- treatmentAdvice: [
- //默认一条
- {
- content: '',
- advice: '',
- }
- ]
- }
- }
- })
- },
- cancelorder(){
- var that=this;
- this.$confirm('是否确认取消订单?', "警告", {
- confirmButtonText: "确定",
- cancelButtonText: "取消",
- type: "warning"
- }).then(function() {
- var data={
- orderId:that.item.orderId
- }
- return cancelOrder(data);
- }).then(() => {
- this.msgSuccess("操作成功");
- getinquiryOrder(this.item.orderId).then(response => {
- this.item = response.data;
- this.getlogList(this.item.orderId);
- });
- }).catch(function() {});
- },
- editStatusOpenOk(){
- editStatus(this.statusForm).then(response => {
- this.msgSuccess("操作成功");
- getinquiryOrder(this.item.orderId).then(response => {
- this.item = response.data;
- this.getlogList(this.item.orderId);
- });
- });
- },
- patientInquirySubmit(){
- this.patientForm.patientId = this.item.patientId;
- this.patientForm.companyUserId = this.item.companyUserId;
- this.patientForm.userId = this.item.userId;
- this.patientForm.inquiryOrderId = this.item.orderId;
- this.patientForm.subDoctorId = this.item.doctorId;
- console.log(this.patientForm);
- if(this.patientForm.id != null) {
- updateinquiryPatient(this.patientForm).then(res => {
- this.msgSuccess("更新成功");
- this.patientOpen = false;
- })
- } else {
- addinquiryPatient(this.patientForm).then(res => {
- this.msgSuccess("添加成功");
- this.patientOpen = false;
- })
- }
- },
- msgServiceDetailsClose(){
- this.msgServiceDetails.open = false;
- },
- handledetails(row){
- getReportId(this.item.orderId).then(response => {
- var id = response.data
- if(id!=null){
- this.show.open=true;
- setTimeout(() => {
- this.$refs.Details.getDetails(id);
- }, 1);
- }else{
- this.$message('订单没有报告');
- }
- });
- },
- getMsg(row){
- const orderId = this.item.orderId;
- const doctorName = this.item.doctorName;
- const patientName = this.item.patientName;
- setTimeout(() => {
- this.$refs.msgDetails.getDetails(orderId,doctorName,patientName);
- }, 500);
- this.dialogVisible = true;
- },
- getSerivceMsg(){
- const doctorName = this.item.doctorName;
- const patientName = this.item.patientName;
- this.msgServiceDetails.open = true;
- setTimeout(() => {
- this.$refs.msgServiceDetails.getDetails(doctorName,patientName);
- }, 500);
- },
- msgDialogClose(){
- this.dialogVisible = false;
- },
- editStatus(){
- this.editStatusOpen=true;
- this.statusForm.status=this.item.status;
- this.statusForm.orderId=this.item.orderId;
- },
- prescribe(row){
- this.prescribeDialog=true;
- getPrescribe(row).then(response => {
- this.prescribeItem = response.data;
- this.usageJson=JSON.parse(this.prescribeItem.usageJson)
- });
- getDrugInfo(row).then(response => {
- this.prod = response.data;
- });
- },
- refundorder(){
- var that=this;
- this.$confirm('是否确认退款?', "警告", {
- confirmButtonText: "确定",
- cancelButtonText: "取消",
- type: "warning"
- }).then(function() {
- var data={
- orderId:that.item.orderId
- }
- return refundOrder(data);
- }).then(() => {
- this.msgSuccess("操作成功");
- getinquiryOrder(this.item.orderId).then(response => {
- this.item = response.data;
- this.getlogList(this.item.orderId);
- });
- }).catch(function() {});
- },
- sendInquiryMsg(){
- var that=this;
- this.$confirm('是否确认发送消息?', "警告", {
- confirmButtonText: "确定",
- cancelButtonText: "取消",
- type: "warning"
- }).then(function() {
- return sendMsg(that.item.orderId);
- }).then(() => {
- this.msgSuccess("操作成功");
- }).catch(function() {});
- },
- handleClose1(){
- this.dialogVisible=false;
- },
- handleClose2(){
- this.prescribeDialog=false;
- },
- getDetails(orderId) {
- this.imgs=null;
- this.tongueImages=null;
- this.faceImages=null;
- var that=this
- this.item=null;
- //获取问诊信息
- getinquiryOrder(orderId).then(response => {
- this.item = response.data;
- //获取医生信息
- if(this.item.doctorId!=null){
- getDoctor(this.item.doctorId).then(response => {
- this.doctor = response.data;
- });
- }
- this.msgForm.orderId=this.item.orderId;
- this.msgList();
- this.getlogList(this.item.orderId);
- var json=JSON.parse(this.item.patientJson);
- if(json!=null&&json!=""){
- if(json.reportImages!=null&&json.reportImages!=""){
- this.imgs= (json.reportImages).split(",");
- }
- if(json.tongueImages!=null&&json.tongueImages!=""){
- this.tongueImages=json.tongueImages.split(",")
- }
- if(json.faceImages!=null&&json.faceImages!=""){
- this.faceImages=json.faceImages.split(",")
- }
- }
- });
- },
- msgList(){
- msglist(this.msgForm).then(response => {
- this.msg = response.rows;
- this.total = response.total;
- });
- },
- getlogList(orderId){
- logList(orderId).then(response => {
- this.logs = response.rows;
- });
- },
- }
- }
- </script>
- <style>
- .contentx{
- height: 100%;
- background-color: #fff;
- padding: 0px 20px 20px;
- margin: 20px;
- }
- .el-descriptions-item__label.is-bordered-label{
- font-weight: normal;
- }
- .el-descriptions-item__content {
- max-width: 150px;
- min-width: 100px;
- }
- .desct{
- padding-top: 20px;
- padding-bottom: 20px;
- color: #524b4a;
- font-weight: bold;
- }
- </style>
- <style scoped>
- .chat-records {
- overflow-y: auto;
- }
- .timestamp {
- font-size: 12px;
- color: #A9A9A9;
- }
- .chat-record {
- margin: 10px;
- flex-direction: column;
- align-items: flex-start;
- }
- .sent {
- background-color: #fbfdff;
- color: #000839;
- }
- .right{
- float: right;
- }
- .received {
- background-color: #fbfdff;
- color: #000000;
- }
- .el-descriptions-item__content {
- max-width: 150px;
- min-width: 100px;
- }
- </style>
- <style scoped>
- .order-content{
- margin: 10px;
- }
- .operate-container {
- background: #F2F6FC;
- height: 60px;
- margin: -20px -20px 0;
- line-height: 60px;
- }
- .operate-button-container {
- float: right;
- margin-right: 20px
- }
- </style>
|