NurseStationUI/src/views/system/order/index.vue

801 lines
26 KiB
Vue
Raw Normal View History

<template>
<div class="app-container">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="100px"
>
2022-11-11 15:34:09 +08:00
<el-form-item label="所属护理站" prop="nurseStationName">
2023-03-13 13:40:12 +08:00
<el-select v-model="queryParams.nurseStationId" placeholder="请选择护理站" @change="handleQuery">
2022-11-11 15:34:09 +08:00
<el-option
2022-11-17 10:38:57 +08:00
v-for="item in handstationlist"
2022-11-11 15:34:09 +08:00
:key="item.id"
:label="item.nurseStationName"
:value="item.id"
2023-03-13 13:40:12 +08:00
></el-option>
2022-11-11 15:34:09 +08:00
</el-select>
</el-form-item>
2022-09-20 10:35:10 +08:00
<el-form-item label="订单编号" prop="orderNo">
<el-input
2022-09-20 10:35:10 +08:00
v-model="queryParams.orderNo"
placeholder="请输入订单编号"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="订单状态" prop="orderStatus">
2023-03-13 13:40:12 +08:00
<el-select v-model="queryParams.orderStatus" placeholder="请选择订单状态">
2022-09-20 10:35:10 +08:00
<el-option
v-for="item in orderStatuslist"
:key="item.value"
:label="item.label"
:value="item.value"
2023-03-13 13:40:12 +08:00
></el-option>
2022-09-20 10:35:10 +08:00
</el-select>
</el-form-item>
2022-11-21 10:01:02 +08:00
<el-form-item label="会员名称" prop="patientName">
<el-input
v-model="queryParams.patientName"
placeholder="请输入会员名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
2023-03-13 13:40:12 +08:00
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
</el-form-item>
</el-form>
<el-table
v-loading="loading"
:data="OrderDetailsList"
@selection-change="handleSelectionChange"
>
2023-03-13 13:40:12 +08:00
<el-table-column label="所属护理站" align="center" prop="nurseStationName" />
<el-table-column label="订单编号" align="center" prop="orderNo" />
2023-03-13 13:40:12 +08:00
<el-table-column label="护理项目名称" align="center" prop="nurseItemName" />
2022-11-11 15:34:09 +08:00
<el-table-column label="订单总金额" align="center" prop="totalPrice" />
<el-table-column label="订单状态" align="center" prop="orderStatus">
<template slot-scope="scope">
2023-03-13 13:40:12 +08:00
<el-button v-if="scope.row.orderStatus == 'WAIT_PAY'">待付款</el-button>
<el-button type="primary" v-if="scope.row.orderStatus == 'PAY'">已付款</el-button>
<el-button type="primary" v-if="scope.row.orderStatus == 'WAIT_DISPATCH'">待派单</el-button>
<el-button type="primary" v-if="scope.row.orderStatus == 'NOT_FINISH'">未完成</el-button>
<el-button type="primary" v-if="scope.row.orderStatus == 'COMPLETE'">待评价</el-button>
<el-button type="success" v-if="scope.row.orderStatus == 'EVALUATED'">服务完成</el-button>
<el-button type="warning" v-if="scope.row.orderStatus == 'WAIT_REFUND'">退款中</el-button>
<el-button type="warning" v-if="scope.row.orderStatus == 'REFUNDED'">退款成功</el-button>
<el-button type="danger" v-if="scope.row.orderStatus == 'CANCEL'">已取消</el-button>
</template>
</el-table-column>
2022-11-04 14:00:14 +08:00
<el-table-column label="下单时间" align="center" prop="createTime" />
2022-11-21 10:01:02 +08:00
<el-table-column label="会员名称" align="center" prop="patientName" />
2023-01-12 15:22:36 +08:00
<el-table-column label="护理员" align="center" prop="nursePersonName" />
2023-03-13 13:40:12 +08:00
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
2022-11-04 17:42:19 +08:00
icon="el-icon-zoom-in"
@click="seeLook(scope.row)"
2022-11-08 13:36:52 +08:00
v-hasPermi="['system:appointmentOrder:query']"
2023-03-13 13:40:12 +08:00
>查看</el-button>
2022-11-04 14:00:14 +08:00
<el-button
size="mini"
type="text"
2022-11-04 17:42:19 +08:00
icon="el-icon-s-promotion"
2022-11-04 14:00:14 +08:00
@click="dispatch(scope.row)"
2022-11-08 13:36:52 +08:00
v-hasPermi="['system:appointmentOrder:dispatch']"
2022-11-11 15:34:09 +08:00
v-if="scope.row.orderStatus == 'WAIT_DISPATCH'"
2023-03-13 13:40:12 +08:00
>派单</el-button>
2022-11-04 14:00:14 +08:00
<el-button
size="mini"
type="text"
2022-11-04 17:42:19 +08:00
icon="el-icon-error"
2022-11-11 15:34:09 +08:00
v-if="scope.row.orderStatus == 'WAIT_REFUND'"
@click="cencel(scope.row)"
v-hasPermi="['system:appointmentOrder:confirmCancel']"
2023-03-13 13:40:12 +08:00
>取消预约</el-button>
2022-11-15 16:41:45 +08:00
<!-- <el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['system:nurseType:remove']"
>删除</el-button
2023-03-13 13:40:12 +08:00
>-->
</template>
</el-table-column>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
2022-11-04 14:00:14 +08:00
<!-- 查看弹框 -->
2023-03-13 13:40:12 +08:00
<el-dialog title="查看预约订单信息" :visible.sync="innerVisible4" append-to-body width="1280px">
<el-form :inline="true" ref="form" :model="query" :rules="rules" label-width="130px">
2022-11-11 15:34:09 +08:00
<el-form-item label="订单编号" prop="orderNo">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.orderNo}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
<el-form-item label="订单状态" prop="orderStatus">
2023-04-06 17:05:18 +08:00
<div class="text">{{switchOrderStatus(query.orderStatus)}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
2022-11-14 16:48:37 +08:00
<el-form-item label="订单总金额" prop="totalPrice">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.totalPrice}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
<el-form-item label="订单数量" prop="orderCount">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.orderCount}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
<el-form-item label="护理项目名称" prop="nurseItemName">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.nurseItemName}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
2023-04-06 17:22:54 +08:00
<!-- <el-form-item label="护理员名称" prop="nursePersonName">
<div class="text">{{query.nursePersonName}}</div>
</el-form-item> -->
<el-form-item label="评价星级" prop="compositeScore">
<div class="text">{{query.compositeScore}}</div>
</el-form-item>
2022-11-11 15:34:09 +08:00
<el-form-item label="服务时间" prop="time">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.time}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
<el-form-item label="护理项目时长" prop="itemServeDurationUnit">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.itemServeDurationUnit}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
2022-11-14 16:48:37 +08:00
<el-form-item label="护理站名称" prop="nurseStationName">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.nurseStationName}}</div>
2022-11-11 15:34:09 +08:00
</el-form-item>
<el-form-item label="服务地址" prop="serviceAddress">
2023-04-06 17:05:18 +08:00
<div
class="text"
style="height:100px;line-height:26px;overflow: scroll"
>{{query.serviceAddress}}</div>
2023-03-31 10:26:56 +08:00
</el-form-item>
<el-form-item label="是否失能" prop="disablingCondition">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.disablingCondition}}</div>
2023-03-31 10:26:56 +08:00
</el-form-item>
<el-form-item label="失能情况" prop="disablingReason">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.disablingReason}}</div>
2023-03-31 10:26:56 +08:00
</el-form-item>
<el-form-item label="健康状况" prop="diseaseName">
2023-04-06 17:05:18 +08:00
<div class="text">{{query.diseaseName}}</div>
2022-11-18 12:49:07 +08:00
</el-form-item>
2022-11-21 09:45:14 +08:00
<el-form-item
label="服务到岗照片"
prop="onDutyPictureUrl"
2022-11-21 10:01:02 +08:00
v-if="
query.orderStatus == 'COMPLETE' || query.orderStatus == 'EVALUATED'
"
2022-11-21 09:45:14 +08:00
>
2023-03-13 13:40:12 +08:00
<img class="img" :src="baseurl + query.onDutyPictureUrl" alt />
2022-11-18 12:49:07 +08:00
</el-form-item>
2022-11-21 09:45:14 +08:00
<el-form-item
label="服务结束照片"
prop="serviceEndPictureUrl"
2022-11-21 10:01:02 +08:00
v-if="
query.orderStatus == 'COMPLETE' || query.orderStatus == 'EVALUATED'
"
2022-11-21 09:45:14 +08:00
>
2023-03-13 13:40:12 +08:00
<img class="img" :src="baseurl + query.serviceEndPictureUrl" alt />
2022-11-18 12:49:07 +08:00
</el-form-item>
2022-11-21 09:45:14 +08:00
<el-form-item
label="用户确认签名"
prop="userSignaturePictureUrl"
2022-11-21 10:01:02 +08:00
v-if="
query.orderStatus == 'COMPLETE' || query.orderStatus == 'EVALUATED'
"
2022-11-21 09:45:14 +08:00
>
2023-03-13 13:40:12 +08:00
<img class="img" :src="baseurl + query.userSignaturePictureUrl" alt />
2022-11-11 15:34:09 +08:00
</el-form-item>
2022-11-21 09:45:14 +08:00
<el-form-item
label="评价满意度"
prop="evaluateSatisfaction"
v-if="query.orderStatus == 'EVALUATED'"
>
2023-03-13 13:40:12 +08:00
<el-input v-model="query.evaluateSatisfaction" disabled style="width: 250px" />
2022-11-21 09:45:14 +08:00
</el-form-item>
2022-11-11 15:34:09 +08:00
<el-table
:data="query.appointmentOrderConsumableList"
align="center"
style="margin: 10px 0 20px 0; padding-bottom: 20px"
>
2023-03-13 13:40:12 +08:00
<el-table-column prop="orderConsumableName" label="耗材包名称" align="center"></el-table-column>
<el-table-column prop="orderConsumableCount" label="耗材包数量" align="center"></el-table-column>
<el-table-column prop="orderConsumablePrice" label="耗材包价格" align="center"></el-table-column>
2022-11-11 15:34:09 +08:00
</el-table>
2022-12-01 11:06:09 +08:00
<el-form-item
label="预约服务位置"
v-if="
query.orderStatus == 'COMPLETE' || query.orderStatus == 'EVALUATED'
"
>
2023-03-13 13:40:12 +08:00
<el-input v-model="query.serviceLocationName" disabled style="width: 250px" />
2022-12-01 11:06:09 +08:00
</el-form-item>
</el-form>
2022-12-01 11:06:09 +08:00
<div
id="container"
v-if="
this.query.orderStatus == 'COMPLETE' ||
this.query.orderStatus == 'EVALUATED'
"
></div>
</el-dialog>
2022-11-04 14:00:14 +08:00
<!-- 派单弹框 -->
2023-03-13 13:40:12 +08:00
<el-dialog title="派单" :visible.sync="innerdispatch" append-to-body width="500px" height="100px">
2022-11-11 15:34:09 +08:00
<el-form ref="form" :model="form" :rules="rules" label-width="130px">
2022-11-04 14:00:14 +08:00
<el-form-item label="护理员姓名" prop="nursePersonName">
<el-button
2023-03-13 13:40:12 +08:00
type
2022-11-04 14:00:14 +08:00
v-if="nurseName == '请选择护理员'"
2022-11-11 15:34:09 +08:00
style="width: 300px; text-align: left; height: 36px; color: #c0c4cc"
2022-11-04 14:00:14 +08:00
@click="clicknursePersonName()"
2023-03-13 13:40:12 +08:00
>{{ nurseName }}</el-button>
2022-11-04 14:00:14 +08:00
<el-button
2023-03-13 13:40:12 +08:00
type
2022-11-04 14:00:14 +08:00
@click="clicknursePersonName()"
v-else
style="
2022-11-11 15:34:09 +08:00
width: 300px;
2022-11-04 14:00:14 +08:00
text-align: left;
height: 36px;
padding-left: -10px;
"
2023-03-13 13:40:12 +08:00
>{{ nurseName }}</el-button>
2022-11-04 14:00:14 +08:00
</el-form-item>
<!-- <el-button
type=""
@click="departclick(item, index)"
v-else
style="
width: 200px;
text-align: left;
height: 36px;
padding-left: -10px;
"
>{{ item.departmentName }}</el-button
2023-03-13 13:40:12 +08:00
>-->
2022-11-04 14:00:14 +08:00
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<!-- <el-button @click="cancel"> </el-button> -->
</div>
</el-dialog>
2022-11-11 15:34:09 +08:00
<!-- 取消预约弹框 -->
2023-03-13 13:40:12 +08:00
<el-dialog title="取消预约" :visible.sync="innerrefund" append-to-body width="500px">
2022-11-11 15:34:09 +08:00
<el-form :inline="true" :rules="rules" label-width="120px">
<el-form-item label="订单编号" prop="orderNo">
2023-03-13 13:40:12 +08:00
<el-input style="width: 260px" v-model="query.orderNo" clearable :disabled="true" />
2022-11-11 15:34:09 +08:00
</el-form-item>
<el-form-item label="服务项目" prop="nurseItemName">
2023-03-13 13:40:12 +08:00
<el-input v-model="query.nurseItemName" style="width: 260px" clearable :disabled="true" />
2022-11-11 15:34:09 +08:00
</el-form-item>
2022-11-14 17:13:59 +08:00
<el-form-item label="会员姓名" prop="patientName">
2023-03-13 13:40:12 +08:00
<el-input v-model="query.patientName" style="width: 260px" clearable :disabled="true" />
2022-11-11 15:34:09 +08:00
</el-form-item>
<el-form-item label="退款原因" prop="cancelAppointmentReason">
<el-input
style="width: 260px"
v-model="query.cancelAppointmentReason"
2023-03-13 13:40:12 +08:00
placeholder
2022-11-11 15:34:09 +08:00
clearable
type="textarea"
:rows="5"
disabled
/>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cencelbtn"> </el-button>
<el-button type="primary" @click="ordercacenl"> </el-button>
</div>
</el-dialog>
2022-11-04 14:00:14 +08:00
<!-- 姓名弹框 -->
2023-03-13 13:40:12 +08:00
<el-dialog :visible.sync="nursePersonNameinfo" width="1000px" append-to-body>
2022-11-04 14:00:14 +08:00
<el-form
ref="queryForm"
2022-11-04 17:42:19 +08:00
:model="querynursePersonname"
2022-11-04 14:00:14 +08:00
:rules="rules"
label-width="80px"
:inline="true"
>
<el-form-item label="姓名" prop="nursePersonName" label-width="120">
2023-03-13 13:40:12 +08:00
<el-input v-model="querynursePersonname.nursePersonName" placeholder="请输入姓名" clearable />
2022-11-04 14:00:14 +08:00
</el-form-item>
2022-11-11 15:34:09 +08:00
2022-11-04 14:00:14 +08:00
<el-form-item>
2023-03-13 13:40:12 +08:00
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery2">搜索</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery2">重置</el-button>
2022-11-04 14:00:14 +08:00
</el-form-item>
</el-form>
2022-11-11 15:34:09 +08:00
<el-table :data="dispatchlist" @cell-dblclick="nursePersonclick">
2022-11-04 14:00:14 +08:00
<el-table-column label="请选择" width="70" align="center">
<template slot-scope="scope">
<el-button
2022-11-11 15:34:09 +08:00
type="primary"
2022-11-04 14:00:14 +08:00
style="width: 15px; height: 15px; overflow: hidden"
2022-11-04 17:42:19 +08:00
v-if="nursePersonid == scope.row.nurseStationPersonId"
2022-11-04 14:00:14 +08:00
circle
@click="nursePersonclick(scope.row)"
></el-button>
<el-button
v-else
style="width: 15px; height: 15px; overflow: hidden"
circle
@click="nursePersonclick(scope.row)"
></el-button>
</template>
</el-table-column>
2023-03-13 13:40:12 +08:00
<el-table-column property="nursePersonCode" label="护理员编号" width="150" align="center"></el-table-column>
<el-table-column property="nursePersonName" label="护理站人员姓名" width="150" align="center"></el-table-column>
<el-table-column property="nursePersonType" label="护理站人员类型" width="150" align="center">
2022-11-04 14:00:14 +08:00
<template slot-scope="scope">
{{ scope.row.nursePersonType == "NURSE" ? "护士" : "" }}
{{ scope.row.nursePersonType == "NURSE_TEACHER" ? "护理师" : "" }}
</template>
</el-table-column>
2023-03-13 13:40:12 +08:00
<el-table-column property="phone" label="手机号" width="150" align="center"></el-table-column>
2022-11-04 14:00:14 +08:00
<el-table-column label="性别" align="center" prop="sex">
<template slot-scope="scope">
{{ scope.row.sex == "MALE" ? "男" : "" }}
{{ scope.row.sex == "FEMALE" ? "女" : "" }}
</template>
</el-table-column>
</el-table>
2022-11-04 17:42:19 +08:00
<pagination
2022-11-04 14:00:14 +08:00
v-show="total2 > 0"
:total="total2"
2022-11-04 17:42:19 +08:00
:page.sync="querynursePersonname.pageNum"
:limit.sync="querynursePersonname.pageSize"
2022-11-04 14:00:14 +08:00
@pagination="handleQuery2"
2022-11-04 17:42:19 +08:00
/>
2022-11-04 14:00:14 +08:00
</el-dialog>
</div>
</template>
<script>
2022-09-20 10:35:10 +08:00
import {
appointmentOrderDetailsList,
Detailed,
deldetailed,
2022-11-04 14:00:14 +08:00
getPerson,
dispatchsubmit,
2022-11-11 15:34:09 +08:00
xylWeChatRefundNotify,
2023-03-13 13:40:12 +08:00
appointmentOrderDetails
2022-09-20 10:35:10 +08:00
} from "@/api/system/order";
2022-11-11 15:34:09 +08:00
import { getListByUser } from "@/api/system/userlist.js";
2022-11-21 09:45:14 +08:00
import baseurl from "@/api/baseurl.js";
2022-11-30 16:21:59 +08:00
export default {
name: "order",
data() {
return {
2022-12-01 11:06:09 +08:00
map: null,
2022-11-21 09:45:14 +08:00
baseurl: null,
2022-11-14 16:48:37 +08:00
orderStatuslist: [
2022-09-20 10:35:10 +08:00
{
value: "WAIT_PAY",
2023-03-13 13:40:12 +08:00
label: "待付款"
2022-09-20 10:35:10 +08:00
},
2022-11-11 15:34:09 +08:00
{
value: "PAY",
2023-03-13 13:40:12 +08:00
label: "已付款"
2022-11-11 15:34:09 +08:00
},
2022-09-20 10:35:10 +08:00
{
value: "WAIT_DISPATCH",
2023-03-13 13:40:12 +08:00
label: "待派单"
2022-09-20 10:35:10 +08:00
},
2022-11-15 15:08:08 +08:00
{
2022-11-21 10:01:02 +08:00
value: "NOT_FINISH",
2023-03-13 13:40:12 +08:00
label: "未完成"
2022-11-11 15:34:09 +08:00
},
2022-09-20 10:35:10 +08:00
{
value: "COMPLETE",
2023-03-13 13:40:12 +08:00
label: "待评价"
2022-11-21 09:45:14 +08:00
},
{
value: "EVALUATED",
2023-03-13 13:40:12 +08:00
label: "服务完成"
2022-09-20 10:35:10 +08:00
},
2022-11-14 16:48:37 +08:00
{
2022-11-21 10:01:02 +08:00
value: "WAIT_REFUND",
2023-03-13 13:40:12 +08:00
label: "退款中"
2022-11-21 10:01:02 +08:00
},
{
value: "REFUNDED",
2023-03-13 13:40:12 +08:00
label: "退款成功"
2022-11-21 10:01:02 +08:00
},
{
value: "CANCEL",
2023-03-13 13:40:12 +08:00
label: "已取消"
}
2022-09-20 10:35:10 +08:00
],
value: "",
// 遮罩层
loading: true,
2022-11-04 14:00:14 +08:00
innerVisible4: false,
2022-11-11 15:34:09 +08:00
innerrefund: false,
2022-11-04 14:00:14 +08:00
// 派单弹框
innerdispatch: false,
// 姓名弹框
nursePersonNameinfo: false,
// 选中数组
ids: [],
// 非单个禁用
single: true,
// 非多个禁用
multiple: true,
// 显示搜索条件
showSearch: true,
input: "",
// 总条数
total: 0,
// 护理类型信息表格数据
OrderDetailsList: [],
2022-11-17 10:38:57 +08:00
handstationlist: [], //页面搜索list
2022-11-04 14:00:14 +08:00
dispatchlist: [],
nurseName: "请选择护理员",
nursePersonid: "",
2022-11-04 17:42:19 +08:00
// querynursecencel:{
// appointmentOrderId:"",
// },
2022-11-11 15:34:09 +08:00
appointmentOrderId: "",
nurseStationPersonId: "",
2022-11-04 17:42:19 +08:00
total2: 0,
2022-11-11 15:34:09 +08:00
nurseStationlist: [],
// 弹出层标题
title: "",
// 是否显示弹出层
open: false,
open2: false,
// 查询参数
queryParams: {
patientName: null,
orderNo: null,
2022-11-11 15:34:09 +08:00
nurseStationId: null,
// orderStatus: null,
orderStatus: "",
pageNum: 1,
2023-03-13 13:40:12 +08:00
pageSize: 10
},
2022-11-04 14:00:14 +08:00
querynursePersonname: {
2022-11-11 15:34:09 +08:00
orderNo: "",
nursePersonName: null,
2022-11-04 14:00:14 +08:00
nursePersonType: null,
departmentName: null,
2022-11-04 17:42:19 +08:00
pageNum: 1,
2023-03-13 13:40:12 +08:00
pageSize: 10
2022-11-04 14:00:14 +08:00
},
2022-09-20 10:35:10 +08:00
query: [],
// 表单参数
form: {},
// 表单校验
2023-03-13 13:40:12 +08:00
rules: {}
};
},
created() {
2022-11-21 09:45:14 +08:00
this.baseurl = baseurl;
2022-11-14 16:48:37 +08:00
this.info();
2022-11-17 10:38:57 +08:00
this.infos();
},
methods: {
2022-12-01 11:06:09 +08:00
init(query) {
this.map = new AMap.Map("container", {
resizeEnable: true, //设置地图可缩放
zoom: 18, //设置地图的层级
2023-03-13 13:40:12 +08:00
center: [query.serveLocationLongitude, query.serveLocationLatitude] //设置地图中心点 更多配置项参照高德官网的配置
2022-12-01 11:06:09 +08:00
});
var layer = new AMap.LabelsLayer({
zooms: [3, 20],
zIndex: 1000,
// 开启标注避让默认为开启v1.4.15 新增属性
collision: true,
// 开启标注淡入动画默认为开启v1.4.15 新增属性
2023-03-13 13:40:12 +08:00
animation: true
2022-12-01 11:06:09 +08:00
});
this.map.add(layer);
var labelMarker = new AMap.LabelMarker({
name: "",
position: [query.serveLocationLongitude, query.serveLocationLatitude],
icon: {
type: "image",
image: "https://a.amap.com/jsapi_demos/static/images/poi-marker.png",
clipOrigin: [280, 8],
clipSize: [50, 68],
size: [25, 34],
anchor: "bottom-center",
angel: 0,
2023-03-13 13:40:12 +08:00
retina: true
2022-12-01 11:06:09 +08:00
},
text: {
2022-12-06 09:50:52 +08:00
content: query.serviceLocationName,
2022-12-01 11:06:09 +08:00
direction: "top",
offset: [0, 0],
style: {
fontSize: 13,
fontWeight: "normal",
fillColor: "#fff",
padding: "2, 5",
2023-03-13 13:40:12 +08:00
backgroundColor: "#22884f"
}
}
2022-12-01 11:06:09 +08:00
});
layer.add(labelMarker);
},
2022-11-11 15:34:09 +08:00
//取消预约确定按钮
ordercacenl() {
var obj = {
orderNo: this.query.orderNo,
refundPrice: this.query.totalPrice,
2023-03-13 13:40:12 +08:00
refundReason: this.query.cancelAppointmentReason
2022-11-11 15:34:09 +08:00
};
2023-03-13 13:40:12 +08:00
xylWeChatRefundNotify(obj).then(res => {
2022-11-11 15:34:09 +08:00
if (res.code == 200) {
this.$modal.msgSuccess("退款有延迟,请耐心等待");
}
this.getList();
2022-11-14 16:48:37 +08:00
this.innerrefund = false;
2022-11-11 15:34:09 +08:00
console.log(res);
});
},
// 取消按钮
2022-11-14 16:48:37 +08:00
cencelbtn() {
this.innerrefund = false;
2022-11-11 15:34:09 +08:00
},
2022-09-20 10:35:10 +08:00
switchOrderStatus(orderStatus) {
switch (orderStatus) {
case "WAIT_PAY":
return "待付款";
2022-11-21 10:01:02 +08:00
case "PAY":
return "已付款";
2022-09-20 10:35:10 +08:00
case "WAIT_DISPATCH":
return "待派单";
case "NOT_FINISH":
return "未完成";
case "COMPLETE":
2022-11-21 10:01:02 +08:00
return "待评价";
case "EVALUATED":
return "服务完成";
2022-11-14 16:48:37 +08:00
case "WAIT_REFUND":
return "退款中";
2022-11-21 10:01:02 +08:00
case "REFUNDED":
return "退款成功";
2022-11-14 16:48:37 +08:00
case "CANCEL":
return "已取消";
2022-09-20 10:35:10 +08:00
default:
break;
}
},
2022-11-04 14:00:14 +08:00
// 查看
seeLook(row) {
2022-11-21 09:45:14 +08:00
this.loading = true;
const id = row.orderNo;
2022-12-01 11:06:09 +08:00
this.map = null;
2023-03-13 13:40:12 +08:00
appointmentOrderDetails(id).then(res => {
2023-03-31 10:26:56 +08:00
res.data.time = res.data.serviceDate + "-" + res.data.serviceStartTime;
this.query = res.data;
2023-04-03 16:13:38 +08:00
res.data.disablingCondition == "DISABLED"
? (res.data.disablingCondition = "失能")
: "";
res.data.disablingCondition == "NOT_DISABLED"
? (res.data.disablingCondition = "未失能")
: "";
2022-11-21 09:45:14 +08:00
if (row.orderStatus == "EVALUATED") {
2022-12-01 11:06:09 +08:00
if (res.data) {
2023-04-03 16:13:38 +08:00
if (res.data.evaluateSatisfaction == "COMMONLY") {
2022-12-01 11:06:09 +08:00
this.query.evaluateSatisfaction = "一般";
2023-04-03 16:13:38 +08:00
} else if (res.data.evaluateSatisfaction == "SATISFIED") {
2022-12-01 11:06:09 +08:00
this.query.evaluateSatisfaction = "满意";
2023-04-03 16:13:38 +08:00
} else if (res.data.evaluateSatisfaction == "DISSATISFIED") {
2022-12-01 11:06:09 +08:00
this.query.evaluateSatisfaction = "不满意";
2022-11-21 09:45:14 +08:00
}
2022-12-01 11:06:09 +08:00
this.loading = false;
this.innerVisible4 = true;
setTimeout(() => {
this.init(this.query);
}, 500);
} else {
this.loading = false;
this.innerVisible4 = true;
setTimeout(() => {
this.init(this.query);
}, 500);
}
} else if (row.orderStatus == "COMPLETE") {
this.loading = false;
this.innerVisible4 = true;
setTimeout(() => {
this.init(this.query);
}, 500);
2022-11-21 09:45:14 +08:00
} else {
this.loading = false;
this.innerVisible4 = true;
}
});
},
2022-11-04 14:00:14 +08:00
// 派单
dispatch(row) {
2022-11-11 15:34:09 +08:00
this.querynursePersonname.orderNo = row.orderNo;
2022-11-04 14:00:14 +08:00
this.nurseName = "请选择护理员";
this.innerdispatch = true;
2022-11-11 15:34:09 +08:00
this.nursePersonid = "";
2022-11-04 14:00:14 +08:00
},
// 姓名弹框
clicknursePersonName() {
2023-03-13 13:40:12 +08:00
getPerson(this.querynursePersonname).then(res => {
2022-11-04 14:00:14 +08:00
this.dispatchlist = res.rows;
2022-11-04 17:42:19 +08:00
this.total2 = res.total;
2022-11-04 14:00:14 +08:00
console.log(this.dispatchlist);
this.nursePersonNameinfo = true;
});
},
// 姓名弹框确定按钮
submitForm() {
2022-11-11 15:34:09 +08:00
let params = {
nurseStationPersonId: this.nursePersonid,
2023-03-13 13:40:12 +08:00
orderNo: this.querynursePersonname.orderNo
2022-11-11 15:34:09 +08:00
};
2023-03-13 13:40:12 +08:00
dispatchsubmit(params).then(res => {
2022-11-11 15:34:09 +08:00
if (res.code == 200) {
2022-11-04 17:42:19 +08:00
this.$modal.msgSuccess("派单成功");
}
2022-11-04 14:00:14 +08:00
this.innerdispatch = false;
2022-11-11 15:34:09 +08:00
this.getList();
this.nurseName = "请选择护理员";
});
2022-11-04 14:00:14 +08:00
},
// 选择姓名按钮
nursePersonclick(row) {
2022-11-11 15:34:09 +08:00
this.nursePersonid = row.nurseStationPersonId;
this.nurseName = row.nursePersonName;
2022-11-04 14:00:14 +08:00
this.nursePersonNameinfo = false;
2022-11-11 15:34:09 +08:00
console.log(row);
},
// 确认取消预约
cencel(row) {
2023-03-13 13:40:12 +08:00
Detailed(row.orderNo).then(res => {
2022-11-11 15:34:09 +08:00
this.query = res.data;
this.innerrefund = true;
});
2022-11-04 14:00:14 +08:00
},
/** 查询护理类型信息列表 */
getList() {
this.loading = true;
2023-03-13 13:40:12 +08:00
appointmentOrderDetailsList(this.queryParams).then(response => {
this.OrderDetailsList = response.rows;
this.total = response.total;
this.loading = false;
});
},
// 取消按钮
cancel() {
this.open = false;
this.reset();
},
// 表单重置
reset() {
this.form = {
patientName: "",
orderNo: "",
orderStatus: "",
2023-03-13 13:40:12 +08:00
createTime: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
2022-11-04 14:00:14 +08:00
handleQuery2() {
2023-03-13 13:40:12 +08:00
getPerson(this.querynursePersonname).then(res => {
2022-11-04 17:42:19 +08:00
this.dispatchlist = res.rows;
console.log(this.querynursePersonname);
// this.innerdispatch = true;
2022-11-04 14:00:14 +08:00
});
},
/** 重置按钮操作 */
resetQuery() {
2022-11-18 12:49:07 +08:00
if (this.nurseStationlist[0]) {
this.queryParams.pageNum = 1;
this.queryParams.pageSize = 10;
this.queryParams.patientName = null;
this.queryParams.orderNo = null;
this.queryParams.orderStatus = null;
}
// this.queryParams = {
// pageNum: 1,
// pageSize: 10,
// // nurseStationId:null,
// patientName:null,
// orderNo:null,
// orderStatus:null,
// };
this.handleQuery();
2022-11-04 17:42:19 +08:00
},
2022-11-14 16:48:37 +08:00
//权限列表
info() {
2023-03-13 13:40:12 +08:00
getListByUser(this.queryParams).then(res => {
2022-11-18 12:49:07 +08:00
this.total = res.total;
this.nurseStationlist = res.rows;
this.queryParams.nurseStationId = res.rows[0].id;
this.getList();
// this.handleQuery();
2022-11-11 15:34:09 +08:00
});
},
2022-11-18 12:49:07 +08:00
infos() {
2022-11-17 10:38:57 +08:00
var queryFor = {
pageNum: 1,
2023-03-13 13:40:12 +08:00
pageSize: 9999
2022-11-17 10:38:57 +08:00
};
2023-03-13 13:40:12 +08:00
getListByUser(queryFor).then(res => {
2022-11-18 12:49:07 +08:00
console.log(res);
2022-11-17 10:38:57 +08:00
this.handstationlist = res.rows;
});
2022-11-11 15:34:09 +08:00
},
resetQuery2() {
2022-11-04 17:42:19 +08:00
this.resetForm("queryForm");
this.handleQuery2();
},
// 多选框选中数据
handleSelectionChange(selection) {
2023-03-13 13:40:12 +08:00
this.ids = selection.map(item => item.id);
this.single = selection.length !== 1;
this.multiple = !selection.length;
},
/** 删除按钮操作 */
handleDelete(row) {
2022-09-26 11:37:58 +08:00
// console.log('row :>> ', row);
2022-11-11 15:34:09 +08:00
this.$confirm("是否确认删除订单信息的数据项?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
2023-03-13 13:40:12 +08:00
type: "warning"
2022-11-11 15:34:09 +08:00
})
.then(() => {
2023-03-13 13:40:12 +08:00
deldetailed(row.appointmentOrderId).then(res => {
2022-09-20 10:35:10 +08:00
this.$message.success("删除成功");
this.getList();
});
})
.catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download(
"system/nurseType/export",
{
2023-03-13 13:40:12 +08:00
...this.queryParams
},
`nurseType_${new Date().getTime()}.xlsx`
);
2023-03-13 13:40:12 +08:00
}
}
};
</script>
2022-11-11 15:34:09 +08:00
<style scoped>
2022-11-18 12:49:07 +08:00
.img {
width: 250px;
height: 250px;
2022-11-08 14:44:07 +08:00
}
2022-12-01 11:06:09 +08:00
#container {
width: 100%;
height: 600px;
}
2023-04-06 17:05:18 +08:00
.text {
width: 250px;
height: 36px;
line-height: 36px;
padding-left: 15px;
font-size: 14px;
border-radius: 4px;
padding: 0 15px;
border: 1px solid #e6ebf5;
}
2022-09-26 11:37:58 +08:00
</style>
2022-11-11 15:34:09 +08:00