Merge remote-tracking branch 'origin/dev'

This commit is contained in:
纪寒 2023-04-13 16:15:05 +08:00
commit cff6465746
24 changed files with 1548 additions and 1391 deletions

View File

@ -69,3 +69,12 @@ export function confirmCancel(appointmentOrderId) {
method: 'post' method: 'post'
}) })
} }
//派单点击护理员获取信息
export function getPersonInfo(nurseStationPersonId) {
return request({
url: `/system/appointmentOrder/getPersonInfo?nurseStationPersonId=${nurseStationPersonId}`,
method: 'get'
})
}

View File

@ -3,7 +3,7 @@ import request from '@/utils/request'
// 查询护理站人员信息列表 // 查询护理站人员信息列表
export function listPerson(query) { export function listPerson(query) {
return request({ return request({
url: 'system/person/getNurseStationPersonList', url: '/system/person/getNurseStationPersonList',
method: 'get', method: 'get',
params: query params: query
}) })
@ -11,7 +11,7 @@ export function listPerson(query) {
// 查询护理站名称 // 查询护理站名称
export function stationList(query) { export function stationList(query) {
return request({ return request({
url: 'system/station/list', url: '/system/station/list',
method: 'get', method: 'get',
params: query params: query
}) })
@ -20,7 +20,7 @@ export function stationList(query) {
// 查询所属科室 // 查询所属科室
export function StationDepartmentList(query) { export function StationDepartmentList(query) {
return request({ return request({
url: 'system/StationDepartment/list', url: '/system/StationDepartment/list',
method: 'get', method: 'get',
params: query params: query
}) })
@ -36,7 +36,7 @@ export function getPerson(id) {
// 新增护理站人员信息 // 新增护理站人员信息
export function addPerson(data) { export function addPerson(data) {
return request({ return request({
url: 'system/person/add', url: '/system/person/add',
method: 'post', method: 'post',
data: data data: data
}) })
@ -45,7 +45,7 @@ export function addPerson(data) {
// 修改护理站人员信息 // 修改护理站人员信息
export function updatePerson(data) { export function updatePerson(data) {
return request({ return request({
url: 'system/person/edit', url: '/system/person/edit',
method: 'post', method: 'post',
data: data data: data
}) })
@ -58,3 +58,21 @@ export function delPerson(id) {
method: 'delete' method: 'delete'
}) })
} }
// 审核接口根据id查询护理站人员信息以及未审核的证书
export function getNurseStationPersonCheck(id) {
return request({
url: '/system/person/getNurseStationPersonCheck/' + id,
method: 'get'
})
}
//审核确定接口
export function updateNurseStationPersonChecks(data) {
return request({
url: '/system/person/updateNurseStationPersonChecks',
method: 'post',
data: data
})
}

44
src/api/system/revenue.js Normal file
View File

@ -0,0 +1,44 @@
import request from '@/utils/request'
// 查询护理员订单佣金收益信息列表
export function listRevenue(query) {
return request({
url: '/system/revenue/list',
method: 'get',
params: query
})
}
// 查询护理员订单佣金收益信息详细
export function getRevenue(id) {
return request({
url: '/system/revenue/' + id,
method: 'get'
})
}
// 新增护理员订单佣金收益信息
export function addRevenue(data) {
return request({
url: '/system/revenue',
method: 'post',
data: data
})
}
// 修改护理员订单佣金收益信息
export function updateRevenue(data) {
return request({
url: '/system/revenue',
method: 'put',
data: data
})
}
// 删除护理员订单佣金收益信息
export function delRevenue(id) {
return request({
url: '/system/revenue/' + id,
method: 'delete'
})
}

View File

@ -383,7 +383,6 @@ export default {
if (response.data.goodAttributeDetailsLists) { if (response.data.goodAttributeDetailsLists) {
this.goodDetailsLists = response.data.goodAttributeDetailsLists; this.goodDetailsLists = response.data.goodAttributeDetailsLists;
} }
// console.log(this.form.parentIdList)
// this.form.goodsCategoryId = this.form.goodsCategoryName // this.form.goodsCategoryId = this.form.goodsCategoryName
// this.form.value = this.form.goodsCategoryId // this.form.value = this.form.goodsCategoryId
// this.form.label = this.form.goodsCategoryName // this.form.label = this.form.goodsCategoryName

View File

@ -718,7 +718,6 @@ export default {
this.form.nurseStationDepartmentList[0].nurseStationName; this.form.nurseStationDepartmentList[0].nurseStationName;
this.form.phone = this.form.nurseStationDepartmentList[0].phone; this.form.phone = this.form.nurseStationDepartmentList[0].phone;
} }
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {

View File

@ -535,7 +535,6 @@ export default {
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const ids = row.id || this.ids; const ids = row.id || this.ids;
console.log(row);
this.$modal this.$modal
.confirm("是否确认删除?") .confirm("是否确认删除?")
.then(function() { .then(function() {

View File

@ -25,19 +25,14 @@
/> />
</el-form-item>--> </el-form-item>-->
<el-form-item label="所属区域" prop="areaCode"> <el-form-item label="所属区域" prop="areaCode">
<el-select <el-select v-model="queryParams.province" clearable placeholder="请选择省">
v-model="queryParams.province"
clearable
placeholder="请选择省"
>
<el-option <el-option
v-for="item in arealist" v-for="item in arealist"
:key="item.id" :key="item.id"
:label="item.areaName" :label="item.areaName"
:value="item.id" :value="item.id"
@click.native="province(item)" @click.native="province(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select
@ -52,8 +47,7 @@
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickcity(item)" @click.native="clickcity(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select
v-model="queryParams.area" v-model="queryParams.area"
@ -67,8 +61,7 @@
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickarea(item)" @click.native="clickarea(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select
v-model="queryParams.areaCode" v-model="queryParams.areaCode"
@ -82,15 +75,10 @@
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickstreet(item)" @click.native="clickstreet(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item <el-form-item label="社区名称" prop="communityName" style="margin-left: 20px">
label="社区名称"
prop="communityName"
style="margin-left: 20px"
>
<el-input <el-input
v-model="queryParams.communityName" v-model="queryParams.communityName"
placeholder="请输入社区名称" placeholder="请输入社区名称"
@ -100,16 +88,8 @@
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
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-item>
</el-form> </el-form>
@ -122,8 +102,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['system:communityInfo:add']" v-hasPermi="['system:communityInfo:add']"
>新增</el-button >新增</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -134,8 +113,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['system:communityInfo:edit']" v-hasPermi="['system:communityInfo:edit']"
>修改</el-button >修改</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -146,8 +124,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['system:communityInfo:remove']" v-hasPermi="['system:communityInfo:remove']"
>删除</el-button >删除</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -157,13 +134,9 @@
size="mini" size="mini"
@click="handleExport" @click="handleExport"
v-hasPermi="['system:communityInfo:export']" v-hasPermi="['system:communityInfo:export']"
>导出</el-button >导出</el-button>
>
</el-col> </el-col>
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-table <el-table
@ -177,21 +150,9 @@
<el-table-column label="社区编码" align="center" prop="communityCode" />--> <el-table-column label="社区编码" align="center" prop="communityCode" />-->
<el-table-column label="所属区域" align="center" prop="area" width="300" /> <el-table-column label="所属区域" align="center" prop="area" width="300" />
<el-table-column label="社区名称" align="center" prop="communityName" /> <el-table-column label="社区名称" align="center" prop="communityName" />
<el-table-column <el-table-column label="社区经度" align="center" prop="communityLongitude" />
label="社区经度" <el-table-column label="社区纬度" align="center" prop="communityLatitude" />
align="center" <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
prop="communityLongitude"
/>
<el-table-column
label="社区纬度"
align="center"
prop="communityLatitude"
/>
<el-table-column
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
@ -199,16 +160,14 @@
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['system:communityInfo:edit']" v-hasPermi="['system:communityInfo:edit']"
>修改</el-button >修改</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="handleDelete(scope.row)" @click="handleDelete(scope.row)"
v-hasPermi="['system:communityInfo:remove']" v-hasPermi="['system:communityInfo:remove']"
>删除</el-button >删除</el-button>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -221,19 +180,8 @@
@pagination="liststationinfo" @pagination="liststationinfo"
/> />
<!-- 添加居住社区信息对话框 --> <!-- 添加居住社区信息对话框 -->
<el-dialog <el-dialog :title="title" :visible.sync="open2" width="1060px" append-to-body>
:title="title" <el-form ref="form" :model="form" :rules="rules" label-width="80px" :inline="true">
:visible.sync="open2"
width="1060px"
append-to-body
>
<el-form
ref="form"
:model="form"
:rules="rules"
label-width="80px"
:inline="true"
>
<div <div
v-for="(item, index) in form.communityInfoList" v-for="(item, index) in form.communityInfoList"
:key="index" :key="index"
@ -251,54 +199,35 @@
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="province2(item, index)" @click.native="province2(item, index)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select v-model="item.city" clearable placeholder="请选择市" style="margin-left: 10px">
v-model="item.city"
clearable
placeholder="请选择市"
style="margin-left: 10px"
>
<el-option <el-option
v-for="item in citylist" v-for="item in citylist"
:key="item.areaCode" :key="item.areaCode"
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickcity2(item, index)" @click.native="clickcity2(item, index)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select v-model="item.area" clearable placeholder="请选择区" style="margin-left: 10px">
v-model="item.area"
clearable
placeholder="请选择区"
style="margin-left: 10px"
>
<el-option <el-option
v-for="item in arealists" v-for="item in arealists"
:key="item.areaCode" :key="item.areaCode"
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickarea2(item, index)" @click.native="clickarea2(item, index)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select v-model="item.code" clearable placeholder="请选择街道" style="margin-left: 10px">
v-model="item.code"
clearable
placeholder="请选择街道"
style="margin-left: 10px"
>
<el-option <el-option
v-for="item in streetlist" v-for="item in streetlist"
:key="item.areaCode" :key="item.areaCode"
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickcode(item, index)" @click.native="clickcode(item, index)"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item <el-form-item
@ -306,11 +235,7 @@
:rules="rules.communityInfoList.communityName" :rules="rules.communityInfoList.communityName"
:prop="`communityInfoList.${index}.communityName`" :prop="`communityInfoList.${index}.communityName`"
> >
<el-input <el-input v-model="item.communityName" placeholder="请输入社区名称" maxlength="30" />
v-model="item.communityName"
placeholder="请输入社区名称"
maxlength="30"
/>
</el-form-item> </el-form-item>
<el-form-item <el-form-item
label="社区经度" label="社区经度"
@ -366,19 +291,8 @@
</el-dialog> </el-dialog>
<!-- 修改居住社区信息对话框 --> <!-- 修改居住社区信息对话框 -->
<el-dialog <el-dialog :title="title" :visible.sync="open" width="1060px" append-to-body>
:title="title" <el-form ref="form" :model="form" :rules="rules" label-width="80px" :inline="true">
:visible.sync="open"
width="1060px"
append-to-body
>
<el-form
ref="form"
:model="form"
:rules="rules"
label-width="80px"
:inline="true"
>
<!-- <el-form-item label="所属区域" prop="areaCode"> <!-- <el-form-item label="所属区域" prop="areaCode">
<el-input <el-input
v-model="form.areaName" v-model="form.areaName"
@ -394,54 +308,35 @@
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="province3(item)" @click.native="province3(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select v-model="form.city" clearable placeholder="请选择市" style="margin-left: 10px">
v-model="form.city"
clearable
placeholder="请选择市"
style="margin-left: 10px"
>
<el-option <el-option
v-for="item in citylist" v-for="item in citylist"
:key="item.areaCode" :key="item.areaCode"
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickcity3(item)" @click.native="clickcity3(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select v-model="form.area" clearable placeholder="请选择区" style="margin-left: 10px">
v-model="form.area"
clearable
placeholder="请选择区"
style="margin-left: 10px"
>
<el-option <el-option
v-for="item in arealists" v-for="item in arealists"
:key="item.areaCode" :key="item.areaCode"
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native="clickarea3(item)" @click.native="clickarea3(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
<el-select <el-select v-model="form.code" clearable placeholder="请选择街道" style="margin-left: 10px">
v-model="form.code"
clearable
placeholder="请选择街道"
style="margin-left: 10px"
>
<el-option <el-option
v-for="item in streetlist" v-for="item in streetlist"
:key="item.areaCode" :key="item.areaCode"
:label="item.areaName" :label="item.areaName"
:value="item.areaCode" :value="item.areaCode"
@click.native='clickcode2(item)' @click.native="clickcode2(item)"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="社区名称" prop="communityName"> <el-form-item label="社区名称" prop="communityName">
@ -490,7 +385,7 @@ import {
updateCommunityInfo, updateCommunityInfo,
FirstLevels, FirstLevels,
SecondaryLevelInfo, SecondaryLevelInfo,
SubordinateRegions, SubordinateRegions
} from "@/api/system/communityInfo"; } from "@/api/system/communityInfo";
export default { export default {
@ -518,10 +413,10 @@ export default {
{ {
provinceName: null, provinceName: null,
cityName: null, cityName: null,
streetName: null, streetName: null
}, }
], ]
}, }
], ],
// //
arealist: [], arealist: [],
@ -547,7 +442,7 @@ export default {
city: "", city: "",
area: "", area: "",
areaCode: "", areaCode: "",
province: "", province: ""
// areaCode: null, // areaCode: null,
// communityCode: null, // communityCode: null,
// communityName: null, // communityName: null,
@ -557,7 +452,7 @@ export default {
getProvincequeryParams: { getProvincequeryParams: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
pageNum: 1, pageNum: 1
// pageSize: 10, // pageSize: 10,
// searchValue: null, // searchValue: null,
// createBy: null, // createBy: null,
@ -573,7 +468,7 @@ export default {
getProvincequeryParams2: { getProvincequeryParams2: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
pageNum: 1, pageNum: 1
// pageSize: 10, // pageSize: 10,
// searchValue: null, // searchValue: null,
// createBy: null, // createBy: null,
@ -593,12 +488,12 @@ export default {
areaCode: { areaCode: {
required: true, required: true,
message: "所属区域不能为空", message: "所属区域不能为空",
trigger: "blur", trigger: "blur"
}, },
communityName: { communityName: {
required: true, required: true,
message: "社区名称不能为空", message: "社区名称不能为空",
trigger: "blur", trigger: "blur"
}, },
// communityLongitude: { // communityLongitude: {
// required: true, // required: true,
@ -614,13 +509,13 @@ export default {
areaCode: { areaCode: {
required: true, required: true,
message: "所属区域不能为空", message: "所属区域不能为空",
trigger: "blur", trigger: "blur"
}, },
communityName: { communityName: {
required: true, required: true,
message: "社区名称不能为空", message: "社区名称不能为空",
trigger: "blur", trigger: "blur"
}, }
// communityLongitude: { // communityLongitude: {
// required: true, // required: true,
// message: "", // message: "",
@ -631,8 +526,8 @@ export default {
// message: "", // message: "",
// trigger: "blur", // trigger: "blur",
// }, // },
}, }
}, }
}; };
}, },
created() { created() {
@ -642,28 +537,20 @@ export default {
methods: { methods: {
clickcode2(item) { clickcode2(item) {
this.form.areaCode = Number(item.areaCode); this.form.areaCode = Number(item.areaCode);
console.log(this.form); this.$forceUpdate();
this.$forceUpdate()
}, },
clickcode(item, index) { clickcode(item, index) {
console.log(item);
this.form.communityInfoList[index].areaCode = Number(item.areaCode); this.form.communityInfoList[index].areaCode = Number(item.areaCode);
// this.form.communityInfoList[index].areaCode = Number(this.form.communityInfoList[index].areaCode); // this.form.communityInfoList[index].areaCode = Number(this.form.communityInfoList[index].areaCode);
console.log(this.form);
}, },
// //
province(item) { province(item) {
// this.form.xxx[index].code='' // this.form.xxx[index].code=''
console.log(item);
this.queryParams.city = ""; this.queryParams.city = "";
this.queryParams.area = ""; this.queryParams.area = "";
this.queryParams.areaCode = ""; this.queryParams.areaCode = "";
SecondaryLevelInfo(item.id).then((res) => { SecondaryLevelInfo(item.id).then(res => {
console.log(res);
// this.SecondaryLevelInfolist = res.data; // this.SecondaryLevelInfolist = res.data;
// console.log(this.SecondaryLevelInfolist);
this.citylist = res.data; this.citylist = res.data;
}); });
}, },
@ -672,35 +559,27 @@ export default {
this.form.communityInfoList[index].city = ""; this.form.communityInfoList[index].city = "";
this.form.communityInfoList[index].area = ""; this.form.communityInfoList[index].area = "";
this.form.communityInfoList[index].areaCode = ""; this.form.communityInfoList[index].areaCode = "";
console.log(item); SecondaryLevelInfo(item.id).then(res => {
SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
// this.SecondaryLevelInfolist = res.data; // this.SecondaryLevelInfolist = res.data;
// console.log(this.SecondaryLevelInfolist);
this.citylist = res.data; this.citylist = res.data;
}); });
}, },
// //
province3(item) { province3(item) {
// this.form.xxx[index].code='' // this.form.xxx[index].code=''
console.log(item);
this.form.city = ""; this.form.city = "";
this.form.area = ""; this.form.area = "";
this.form.code = ""; this.form.code = "";
SecondaryLevelInfo(item.id).then((res) => { SecondaryLevelInfo(item.id).then(res => {
console.log(res);
// this.SecondaryLevelInfolist = res.data; // this.SecondaryLevelInfolist = res.data;
// console.log(this.SecondaryLevelInfolist);
this.citylist = res.data; this.citylist = res.data;
}); });
}, },
// //
clickcity(item) { clickcity(item) {
console.log(item); SecondaryLevelInfo(item.id).then(res => {
SecondaryLevelInfo(item.id).then((res) => {
this.queryParams.area = ""; this.queryParams.area = "";
this.queryParams.areaCode = ""; this.queryParams.areaCode = "";
console.log(res);
this.arealists = res.data; this.arealists = res.data;
}); });
}, },
@ -712,19 +591,15 @@ export default {
// this.value3 = ""; // this.value3 = "";
this.form.communityInfoList[index].area = ""; this.form.communityInfoList[index].area = "";
this.form.communityInfoList[index].areaCode = ""; this.form.communityInfoList[index].areaCode = "";
console.log(item); SecondaryLevelInfo(item.id).then(res => {
SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
this.arealists = res.data; this.arealists = res.data;
}); });
}, },
// //
clickcity3(item) { clickcity3(item) {
console.log(item); SecondaryLevelInfo(item.id).then(res => {
SecondaryLevelInfo(item.id).then((res) => {
this.form.area = ""; this.form.area = "";
this.form.code = ""; this.form.code = "";
console.log(res);
this.arealists = res.data; this.arealists = res.data;
}); });
}, },
@ -733,9 +608,7 @@ export default {
this.queryParams.areaCode = ""; this.queryParams.areaCode = "";
// this.queryParams.areaCode = ""; // this.queryParams.areaCode = "";
// this.value3 = ""; // this.value3 = "";
console.log(item); SecondaryLevelInfo(item.id).then(res => {
SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
this.streetlist = res.data; this.streetlist = res.data;
}); });
}, },
@ -745,9 +618,7 @@ export default {
// this.value3 = ""; // this.value3 = "";
this.form.communityInfoList[index].areaCode = ""; this.form.communityInfoList[index].areaCode = "";
console.log(item); SecondaryLevelInfo(item.id).then(res => {
SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
this.streetlist = res.data; this.streetlist = res.data;
}); });
}, },
@ -756,53 +627,42 @@ export default {
this.form.code = ""; this.form.code = "";
// this.queryParams.areaCode = ""; // this.queryParams.areaCode = "";
// this.value3 = ""; // this.value3 = "";
console.log(item); SecondaryLevelInfo(item.id).then(res => {
SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
this.streetlist = res.data; this.streetlist = res.data;
}); });
}, },
// //
clickstreet(item) { clickstreet(item) {
this.form.areaCode = item.areaCode; this.form.areaCode = item.areaCode;
console.log(this.form);
}, },
// clickstreet3(item) { // clickstreet3(item) {
// this.form.areaCode = item.areaCode; // this.form.areaCode = item.areaCode;
// // console.log(this.queryParams);
// }, // },
// //
loadMore() { loadMore() {
console.log("1");
var a = Math.ceil(this.total2 / 10); var a = Math.ceil(this.total2 / 10);
console.log(this.arealist.length);
if (this.arealist.length + 1 >= this.total2) { if (this.arealist.length + 1 >= this.total2) {
} else { } else {
if (this.getProvincequeryParams.pageNum >= a) { if (this.getProvincequeryParams.pageNum >= a) {
} else { } else {
this.getProvincequeryParams.pageNum++; this.getProvincequeryParams.pageNum++;
FirstLevels(this.getProvincequeryParams).then((res) => { FirstLevels(this.getProvincequeryParams).then(res => {
console.log(res); res.rows.forEach(e => {
res.rows.forEach((e) => {
this.arealist.push(e); this.arealist.push(e);
console.log(this.arealist);
}); });
}); });
} }
} }
}, },
Provincelist() { Provincelist() {
FirstLevels(this.getProvincequeryParams).then((res) => { FirstLevels(this.getProvincequeryParams).then(res => {
console.log(res);
this.arealist = res.data; this.arealist = res.data;
this.total2 = res.total; this.total2 = res.total;
console.log(this.arealist);
}); });
}, },
//delcommunity //delcommunity
delcommunity(index) { delcommunity(index) {
this.form.communityInfoList.splice(index, 1); this.form.communityInfoList.splice(index, 1);
console.log(this.form.communityInfoList);
}, },
//addcommunity //addcommunity
addcommunity() { addcommunity() {
@ -811,7 +671,7 @@ export default {
communityCode: "", communityCode: "",
communityName: "", communityName: "",
communityLongitude: "", communityLongitude: "",
communityLatitude: "", communityLatitude: ""
// diseaseName: "", // diseaseName: "",
// description: "", // description: "",
// sort: "", // sort: "",
@ -852,16 +712,16 @@ export default {
communityCode: "", communityCode: "",
communityName: "", communityName: "",
communityLongitude: "", communityLongitude: "",
communityLatitude: "", communityLatitude: ""
}, }
], ]
}; };
this.resetForm("form"); this.resetForm("form");
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
liststationinfo() { liststationinfo() {
listCommunityInfo(this.queryParams).then((response) => { listCommunityInfo(this.queryParams).then(response => {
response.rows.forEach((e) => { response.rows.forEach(e => {
if (e.sysAreaVOList == []) { if (e.sysAreaVOList == []) {
} else if (e.sysAreaVOList == null) { } else if (e.sysAreaVOList == null) {
} else if (!e.sysAreaVOList) { } else if (!e.sysAreaVOList) {
@ -924,13 +784,13 @@ export default {
area: null, area: null,
areaCode: null, areaCode: null,
areaName: null, areaName: null,
areaLevel: null, areaLevel: null
}; };
this.handleQuery(); this.handleQuery();
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id); this.ids = selection.map(item => item.id);
this.single = selection.length !== 1; this.single = selection.length !== 1;
this.multiple = !selection.length; this.multiple = !selection.length;
}, },
@ -944,16 +804,13 @@ export default {
/** 修改按钮操作 */ /** 修改按钮操作 */
handleUpdate(row) { handleUpdate(row) {
this.reset(); this.reset();
console.log(row);
const id = row.id || this.ids; const id = row.id || this.ids;
getCommunityInfo(id).then((response) => { getCommunityInfo(id).then(response => {
this.form = response.data; this.form = response.data;
this.title = "修改居住社区信息"; this.title = "修改居住社区信息";
this.form.code = null; this.form.code = null;
console.log(1); SubordinateRegions(response.data.areaCode).then(res => {
SubordinateRegions(response.data.areaCode).then((res) => {
console.log(res);
if (res.data !== null) { if (res.data !== null) {
this.form.province = String(res.data.provinceCode); this.form.province = String(res.data.provinceCode);
// this.form.province = res.data.provinceCode; // this.form.province = res.data.provinceCode;
@ -961,7 +818,6 @@ export default {
this.form.area = res.data.regionName; this.form.area = res.data.regionName;
// this.form.areaCode = res.data.streetName; // this.form.areaCode = res.data.streetName;
this.form.code = res.data.streetName; this.form.code = res.data.streetName;
console.log(this.form);
this.open = true; this.open = true;
} }
}); });
@ -969,13 +825,13 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
this.$refs["form"].validate((valid) => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
// let newStr = JSON.stringify(this.form.areaCode); // let newStr = JSON.stringify(this.form.areaCode);
// let newObj = JSON.parse(newStr); // let newObj = JSON.parse(newStr);
if (this.form.id != null) { if (this.form.id != null) {
updateCommunityInfo(this.form).then((response) => { updateCommunityInfo(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open2 = false; this.open2 = false;
this.open = false; this.open = false;
@ -983,7 +839,7 @@ export default {
this.getList(); this.getList();
}); });
} else { } else {
addCommunityInfo(this.form).then((response) => { addCommunityInfo(this.form).then(response => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
this.open2 = false; this.open2 = false;
@ -1012,11 +868,11 @@ export default {
this.download( this.download(
"system/communityInfo/export", "system/communityInfo/export",
{ {
...this.queryParams, ...this.queryParams
}, },
`communityInfo_${new Date().getTime()}.xlsx` `communityInfo_${new Date().getTime()}.xlsx`
); );
}, }
}, }
}; };
</script> </script>

View File

@ -321,7 +321,6 @@ export default {
//deldisease //deldisease
deldisease(index) { deldisease(index) {
this.form.diseaseInfoList.splice(index, 1); this.form.diseaseInfoList.splice(index, 1);
console.log(this.form.diseaseInfoList);
}, },
//adddisease //adddisease
adddisease() { adddisease() {

View File

@ -57,16 +57,8 @@
/> />
</el-form-item>--> </el-form-item>-->
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
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-item>
</el-form> </el-form>
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
@ -78,8 +70,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['system:goodsCategory:add']" v-hasPermi="['system:goodsCategory:add']"
>新增</el-button >新增</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -90,8 +81,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['system:goodsCategory:edit']" v-hasPermi="['system:goodsCategory:edit']"
>修改</el-button >修改</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -102,8 +92,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['system:goodsCategory:remove']" v-hasPermi="['system:goodsCategory:remove']"
>删除</el-button >删除</el-button>
>
</el-col> </el-col>
<!-- <el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
@ -116,10 +105,7 @@
>导出</el-button >导出</el-button
> >
</el-col>--> </el-col>-->
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> </el-row>
<el-table <el-table
@ -134,11 +120,7 @@
align="center" align="center"
prop="goodsCategoryName" prop="goodsCategoryName"
/> />
<el-table-column <el-table-column label="商品分类编码" align="center" prop="goodsCategoryCode" />
label="商品分类编码"
align="center"
prop="goodsCategoryCode"
/>
<!-- <el-table-column label="商品分类图片地址" align="center" prop="goodsCategoryPicture" /> --> <!-- <el-table-column label="商品分类图片地址" align="center" prop="goodsCategoryPicture" /> -->
<el-table-column <el-table-column
label="分类概述" label="分类概述"
@ -147,11 +129,7 @@
:show-overflow-tooltip="true" :show-overflow-tooltip="true"
/> />
<el-table-column label="显示顺序" align="center" prop="sort" /> <el-table-column label="显示顺序" align="center" prop="sort" />
<el-table-column <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
label="操作"
align="center"
class-name="small-padding fixed-width"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
size="mini" size="mini"
@ -159,16 +137,14 @@
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['system:goodsCategory:edit']" v-hasPermi="['system:goodsCategory:edit']"
>修改</el-button >修改</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="handleDelete(scope.row)" @click="handleDelete(scope.row)"
v-hasPermi="['system:goodsCategory:remove']" v-hasPermi="['system:goodsCategory:remove']"
>删除</el-button >删除</el-button>
>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -192,12 +168,7 @@
:before-close="cancel" :before-close="cancel"
> >
<el-form ref="form" :model="form" :rules="rules" label-width="120px"> <el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-form-item <el-form-item label="父级分类名称" prop="parentName" :required="true" v-if="form.parentId">
label="父级分类名称"
prop="parentName"
:required="true"
v-if="form.parentId"
>
<el-cascader <el-cascader
:props="treeOption" :props="treeOption"
@change="change" @change="change"
@ -206,8 +177,7 @@
ref="cascader" ref="cascader"
:key="isResouceShow" :key="isResouceShow"
:placeholder="form.parentName ? form.parentName : ''" :placeholder="form.parentName ? form.parentName : ''"
> ></el-cascader>
</el-cascader>
<!-- <el-input <!-- <el-input
v-model="form.parentName" v-model="form.parentName"
placeholder="请输入父级分类名称" placeholder="请输入父级分类名称"
@ -216,11 +186,7 @@
/>--> />-->
</el-form-item> </el-form-item>
<el-form-item label="商品分类名称" prop="goodsCategoryName"> <el-form-item label="商品分类名称" prop="goodsCategoryName">
<el-input <el-input v-model="form.goodsCategoryName" placeholder="请输入商品分类名称" maxlength="10" />
v-model="form.goodsCategoryName"
placeholder="请输入商品分类名称"
maxlength="10"
/>
</el-form-item> </el-form-item>
<!-- <el-form-item label="商品分类编码" prop="goodsCategoryCode"> <!-- <el-form-item label="商品分类编码" prop="goodsCategoryCode">
<el-input <el-input
@ -238,11 +204,7 @@
<!-- <img :src="form.goodsCategoryPicture" alt="" /> --> <!-- <img :src="form.goodsCategoryPicture" alt="" /> -->
</el-form-item> </el-form-item>
<el-form-item label="分类概述" prop="categoryRemark"> <el-form-item label="分类概述" prop="categoryRemark">
<el-input <el-input v-model="form.categoryRemark" placeholder="请输入分类概述" maxlength="300" />
v-model="form.categoryRemark"
placeholder="请输入分类概述"
maxlength="300"
/>
</el-form-item> </el-form-item>
<el-form-item label="显示顺序" prop="sort"> <el-form-item label="显示顺序" prop="sort">
<el-input <el-input
@ -269,7 +231,7 @@ import {
updatePicture, updatePicture,
addGoodsCategory, addGoodsCategory,
updateGoodsCategory, updateGoodsCategory,
getStationCategoryList, getStationCategoryList
} from "@/api/system/goodsCategory"; } from "@/api/system/goodsCategory";
import stationAcatar from "../stationAvatar/index.vue"; import stationAcatar from "../stationAvatar/index.vue";
import baseurl from "@/api/baseurl"; import baseurl from "@/api/baseurl";
@ -286,22 +248,22 @@ export default {
lazyLoad(node, resolve) { lazyLoad(node, resolve) {
const id = node.level === 0 ? 0 : node.data.id; const id = node.level === 0 ? 0 : node.data.id;
setTimeout(() => { setTimeout(() => {
getStationCategoryList(id).then((res) => { getStationCategoryList(id).then(res => {
// //
res.data.forEach((e) => { res.data.forEach(e => {
e.value = e.id; e.value = e.id;
e.label = e.goodsCategoryName; e.label = e.goodsCategoryName;
}); });
resolve( resolve(
res.data.map((item) => { res.data.map(item => {
return { return {
...item, ...item
}; };
}) })
); );
}); });
}, 300); }, 300);
}, }
}, },
imgone: "", imgone: "",
baseurl: "", baseurl: "",
@ -333,35 +295,33 @@ export default {
categoryRemark: null, categoryRemark: null,
sort: null, sort: null,
parentId: 0, parentId: 0,
parentName: "", parentName: ""
}, },
// //
form: {}, form: {},
// //
rules: { rules: {
goodsCategoryName: [ goodsCategoryName: [
{ required: true, message: "商品分类名称不能为空", trigger: "blur" }, { required: true, message: "商品分类名称不能为空", trigger: "blur" }
], ],
goodsCategoryCode: [ goodsCategoryCode: [
{ required: true, message: "商品分类编码不能为空", trigger: "blur" }, { required: true, message: "商品分类编码不能为空", trigger: "blur" }
], ],
goodsCategoryPicture: [ goodsCategoryPicture: [
{ required: true, message: "商品分类图片不能为空", trigger: "blur" }, { required: true, message: "商品分类图片不能为空", trigger: "blur" }
], ],
categoryRemark: [ categoryRemark: [
{ required: true, message: "分类概述不能为空", trigger: "blur" }, { required: true, message: "分类概述不能为空", trigger: "blur" }
],
sort: [
{ required: true, message: "显示顺序不能为空", trigger: "blur" },
], ],
sort: [{ required: true, message: "显示顺序不能为空", trigger: "blur" }]
}, },
// //
deptOptions: undefined, deptOptions: undefined,
categoryLevel: null, categoryLevel: null,
defaultProps: { defaultProps: {
children: "children", children: "children",
label: "goodsCategoryName", label: "goodsCategoryName"
}, }
}; };
}, },
@ -383,12 +343,12 @@ export default {
this.queryParams.parentName = data.goodsCategoryName; this.queryParams.parentName = data.goodsCategoryName;
// this.categoryLevel = data.categoryLevel; // this.categoryLevel = data.categoryLevel;
this.handleQuery(); this.handleQuery();
getStationCategoryList(data.id).then((res) => { getStationCategoryList(data.id).then(res => {
res.data.forEach((e) => { res.data.forEach(e => {
e.children = [ e.children = [
{ {
goodsCategoryName: "", goodsCategoryName: ""
}, }
]; ];
}); });
this.loading = false; this.loading = false;
@ -398,20 +358,20 @@ export default {
/** 查询商品分类信息列表 */ /** 查询商品分类信息列表 */
info() { info() {
this.loading = true; this.loading = true;
getStationCategoryList(0).then((res) => { getStationCategoryList(0).then(res => {
res.data.forEach((e) => { res.data.forEach(e => {
e.children = [ e.children = [
{ {
goodsCategoryName: "", goodsCategoryName: ""
}, }
]; ];
}); });
var obj = [ var obj = [
{ {
goodsCategoryName: "商品分类名称", goodsCategoryName: "商品分类名称",
children: res.data, children: res.data,
id: 0, id: 0
}, }
]; ];
this.deptOptions = obj; this.deptOptions = obj;
this.loading = false; this.loading = false;
@ -419,7 +379,7 @@ export default {
}, },
getList() { getList() {
this.loading = true; this.loading = true;
listGoodsCategory(this.queryParams).then((response) => { listGoodsCategory(this.queryParams).then(response => {
this.goodsCategoryList = response.rows; this.goodsCategoryList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
@ -433,7 +393,7 @@ export default {
obj.pictureUrlList.push(this.form.goodsCategoryPicture); obj.pictureUrlList.push(this.form.goodsCategoryPicture);
} }
if (obj.pictureUrlList.length > 0) { if (obj.pictureUrlList.length > 0) {
updatePicture(obj).then((res) => {}); updatePicture(obj).then(res => {});
} }
this.open = false; this.open = false;
this.reset(); this.reset();
@ -452,7 +412,7 @@ export default {
updateBy: null, updateBy: null,
updateTime: null, updateTime: null,
parentId: null, parentId: null,
parentName: null, parentName: null
}; };
this.resetForm("form"); this.resetForm("form");
}, },
@ -466,14 +426,14 @@ export default {
this.queryParams = { this.queryParams = {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
parentId: 0, parentId: 0
}; };
this.resetForm("queryForm"); this.resetForm("queryForm");
this.handleQuery(); this.handleQuery();
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id); this.ids = selection.map(item => item.id);
this.single = selection.length !== 1; this.single = selection.length !== 1;
this.multiple = !selection.length; this.multiple = !selection.length;
}, },
@ -482,7 +442,6 @@ export default {
this.reset(); this.reset();
this.open = true; this.open = true;
this.title = "添加商品分类信息"; this.title = "添加商品分类信息";
console.log(this.queryParams);
// if (this.queryParams.parentId != 0) { // if (this.queryParams.parentId != 0) {
this.form.parentId = this.queryParams.parentId; this.form.parentId = this.queryParams.parentId;
// } // }
@ -493,26 +452,25 @@ export default {
handleUpdate(row) { handleUpdate(row) {
this.reset(); this.reset();
const id = row.id || this.ids; const id = row.id || this.ids;
getGoodsCategory(id).then((response) => { getGoodsCategory(id).then(response => {
this.form = response.data; this.form = response.data;
this.imgone = this.form.goodsCategoryPicture; this.imgone = this.form.goodsCategoryPicture;
this.open = true; this.open = true;
this.title = "修改商品分类信息"; this.title = "修改商品分类信息";
console.log(this.form);
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
this.$refs["form"].validate((valid) => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {
updateGoodsCategory(this.form).then((response) => { updateGoodsCategory(this.form).then(response => {
var obj = { pictureUrlList: [] }; var obj = { pictureUrlList: [] };
if (this.imgone != this.form.goodsCategoryPicture) { if (this.imgone != this.form.goodsCategoryPicture) {
obj.pictureUrlList.push(this.imgone); obj.pictureUrlList.push(this.imgone);
} }
if (obj.pictureUrlList.length > 0) { if (obj.pictureUrlList.length > 0) {
updatePicture(obj).then((res) => {}); updatePicture(obj).then(res => {});
} }
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
++this.isResouceShow; ++this.isResouceShow;
@ -521,7 +479,7 @@ export default {
this.info(); this.info();
}); });
} else { } else {
addGoodsCategory(this.form).then((response) => { addGoodsCategory(this.form).then(response => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
++this.isResouceShow; ++this.isResouceShow;
this.open = false; this.open = false;
@ -534,7 +492,6 @@ export default {
}, },
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
console.log(row);
const ids = row.id || this.ids; const ids = row.id || this.ids;
this.$modal this.$modal
.confirm("是否确认删除?") .confirm("是否确认删除?")
@ -545,9 +502,7 @@ export default {
var obj = { pictureUrlList: [] }; var obj = { pictureUrlList: [] };
obj.pictureUrlList.push(row.goodsCategoryPicture); obj.pictureUrlList.push(row.goodsCategoryPicture);
if (obj.pictureUrlList.length > 0) { if (obj.pictureUrlList.length > 0) {
updatePicture(obj).then((res) => { updatePicture(obj).then(res => {});
console.log(res);
});
} }
this.getList(); this.getList();
this.$modal.msgSuccess("删除成功"); this.$modal.msgSuccess("删除成功");
@ -559,15 +514,15 @@ export default {
this.download( this.download(
"system/goodsCategory/export", "system/goodsCategory/export",
{ {
...this.queryParams, ...this.queryParams
}, },
`goodsCategory_${new Date().getTime()}.xlsx` `goodsCategory_${new Date().getTime()}.xlsx`
); );
}, },
imgUrl(imgUrl) { imgUrl(imgUrl) {
this.form.goodsCategoryPicture = imgUrl; this.form.goodsCategoryPicture = imgUrl;
}, }
}, }
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>

View File

@ -210,7 +210,6 @@ export default {
}, },
// //
uploadImg() { uploadImg() {
// console.log(this.types);
this.$refs.cropper.getCropBlob((data) => { this.$refs.cropper.getCropBlob((data) => {
let formData = new FormData(); let formData = new FormData();
formData.append("file", data); formData.append("file", data);

View File

@ -73,8 +73,7 @@ export default {
label: "是", label: "是",
}, },
], ],
integraloption: [ integraloption: [{
{
value: 0, value: 0,
label: "否", label: "否",
}, },
@ -183,7 +182,6 @@ export default {
this.imgsurl.pictureUrlList.push(item); this.imgsurl.pictureUrlList.push(item);
}, },
upwhetherShelf(row) { upwhetherShelf(row) {
console.log(row);
if (row.whetherShelf == false) { if (row.whetherShelf == false) {
var obj = { var obj = {
id: row.goodsInfoId, id: row.goodsInfoId,
@ -196,7 +194,6 @@ export default {
}; };
} }
editGoodsWhetherShelf(obj).then((res) => { editGoodsWhetherShelf(obj).then((res) => {
console.log(obj);
if (obj.whetherShelf == 0) { if (obj.whetherShelf == 0) {
this.$modal.msgSuccess("已修改上架状态为未上架"); this.$modal.msgSuccess("已修改上架状态为未上架");
} else { } else {
@ -217,14 +214,12 @@ export default {
} }
}); });
this.goodsInfoList = response.rows; this.goodsInfoList = response.rows;
console.log(this.goodsInfoList);
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
}); });
}, },
// 添加 // 添加
addgoodAttributeDetail() { addgoodAttributeDetail() {
console.log(this.goodDetailsLists);
if (this.goodDetailsLists.length == 5) { if (this.goodDetailsLists.length == 5) {
this.$message.error("最多只能5条"); this.$message.error("最多只能5条");
} else { } else {
@ -270,9 +265,7 @@ export default {
obj.pictureUrlList.push(this.form.goodsPictureUrl); obj.pictureUrlList.push(this.form.goodsPictureUrl);
} }
if (obj.pictureUrlList.length > 0) { if (obj.pictureUrlList.length > 0) {
updatePicture(obj).then((res) => { updatePicture(obj).then((res) => {});
console.log(res);
});
} }
if (this.imgsurl.pictureUrlList.length > 0) { if (this.imgsurl.pictureUrlList.length > 0) {
updatePicture(this.imgsurl).then((res) => {}); updatePicture(this.imgsurl).then((res) => {});
@ -367,7 +360,6 @@ export default {
}, },
// 多选框选中数据 // 多选框选中数据
handleSelectionChange(selection) { handleSelectionChange(selection) {
console.log(selection);
this.ids = selection.map((item) => item.goodsInfoId); this.ids = selection.map((item) => item.goodsInfoId);
this.single = selection.length !== 1; this.single = selection.length !== 1;
this.multiple = !selection.length; this.multiple = !selection.length;
@ -396,7 +388,6 @@ export default {
// this.reset(); // this.reset();
const id = row.goodsInfoId || this.ids; const id = row.goodsInfoId || this.ids;
getGoodsInfo(id).then((response) => { getGoodsInfo(id).then((response) => {
console.log(response);
this.form = response.data; this.form = response.data;
this.form.nurseStationName = row.nurseStationName; this.form.nurseStationName = row.nurseStationName;
this.imgone = this.form.goodsPictureUrl; this.imgone = this.form.goodsPictureUrl;
@ -409,8 +400,6 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
console.log(this.form);
console.log(this.goodDetailsLists);
this.form.goodAttributeDetailsLists = []; this.form.goodAttributeDetailsLists = [];
this.form.goodDetailsLists = this.goodDetailsLists; this.form.goodDetailsLists = this.goodDetailsLists;
if (!this.form.goodDetailsLists.integralExchangeFlag) { if (!this.form.goodDetailsLists.integralExchangeFlag) {
@ -423,7 +412,6 @@ export default {
if (this.form.goodDetailsLists.integralExchangeCount == "") { if (this.form.goodDetailsLists.integralExchangeCount == "") {
this.form.goodDetailsLists.integralExchangeCount = null this.form.goodDetailsLists.integralExchangeCount = null
} }
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.goodsInfoId != null) { if (this.form.goodsInfoId != null) {
@ -437,9 +425,7 @@ export default {
obj.pictureUrlList.push(this.imgone); obj.pictureUrlList.push(this.imgone);
} }
if (obj.pictureUrlList.length > 0) { if (obj.pictureUrlList.length > 0) {
updatePicture(obj).then((res) => { updatePicture(obj).then((res) => {});
console.log(res);
});
} }
this.imgsurl = { pictureUrlList: [] }; this.imgsurl = { pictureUrlList: [] };
++this.isResouceShow; ++this.isResouceShow;
@ -464,7 +450,6 @@ export default {
}, },
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
console.log("row :>> ", row);
this.$confirm("是否确认删除订单信息的数据项?", "提示", { this.$confirm("是否确认删除订单信息的数据项?", "提示", {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
@ -473,14 +458,11 @@ export default {
.then(() => { .then(() => {
var obj = { pictureUrlList: [] }; var obj = { pictureUrlList: [] };
obj.pictureUrlList.push(row.goodsPictureUrl); obj.pictureUrlList.push(row.goodsPictureUrl);
updatePicture(obj).then((res) => { updatePicture(obj).then((res) => {});
console.log(res);
});
delGoodsInfo(row.goodsInfoId).then((res) => { delGoodsInfo(row.goodsInfoId).then((res) => {
this.$message.success("删除成功"); this.$message.success("删除成功");
this.getList(); this.getList();
// console.log('this.OrderDetailsList :>> ', this.OrderDetailsList);
}); });
}) })
.catch(() => {}); .catch(() => {});
@ -509,11 +491,9 @@ export default {
// ); // );
// }, // },
imgUrl(imgUrl) { imgUrl(imgUrl) {
console.log(imgUrl);
this.form.goodsPictureUrl = imgUrl; this.form.goodsPictureUrl = imgUrl;
}, },
attributePitureUrl(imgUrl) { attributePitureUrl(imgUrl) {
console.log(imgUrl);
// this.form.attributePitureUrl = imgUrl; // this.form.attributePitureUrl = imgUrl;
}, },
attributePitureitem(item) { attributePitureitem(item) {
@ -535,12 +515,9 @@ export default {
//权限列表 //权限列表
info() { info() {
goodsCategory().then((res) => { goodsCategory().then((res) => {
console.log(res);
console.log(this.form);
this.goodsCategorylist = res.rows; this.goodsCategorylist = res.rows;
}); });
getListByUser(this.getListByUserquery).then((res) => { getListByUser(this.getListByUserquery).then((res) => {
console.log(res);
this.total2 = res.total; this.total2 = res.total;
this.nurseStationlist = res.rows; this.nurseStationlist = res.rows;
this.queryParams.nurseStationId = res.rows[0].id; this.queryParams.nurseStationId = res.rows[0].id;
@ -558,7 +535,6 @@ export default {
pageSize: 9999, pageSize: 9999,
}; };
getListByUser(queryFor).then((res) => { getListByUser(queryFor).then((res) => {
console.log(res)
this.handstationlist = res.rows; this.handstationlist = res.rows;
}); });
}, },

View File

@ -708,14 +708,12 @@ export default {
}, },
// //
seelogistics(row) { seelogistics(row) {
// console.log(id);
// this.queryexpressNo.id = row.id; // this.queryexpressNo.id = row.id;
this.queryexpressNo = JSON.parse(JSON.stringify(row)); this.queryexpressNo = JSON.parse(JSON.stringify(row));
this.innerlogistics = true; this.innerlogistics = true;
}, },
// //
searchlogistics() { searchlogistics() {
console.log(this.queryexpressNo);
editExpressNo(this.queryexpressNo).then(res => { editExpressNo(this.queryexpressNo).then(res => {
if (res.code == 200) { if (res.code == 200) {
this.$modal.msgSuccess("录入成功"); this.$modal.msgSuccess("录入成功");
@ -732,10 +730,8 @@ export default {
}, },
// 退 // 退
refund(id) { refund(id) {
console.log(id);
goodsOrderRefundinfo(id).then(res => { goodsOrderRefundinfo(id).then(res => {
this.refundlist = res.data; this.refundlist = res.data;
console.log(this.refundlist);
this.innerrefund = true; this.innerrefund = true;
// this.getList(); // this.getList();
}); });
@ -758,7 +754,6 @@ export default {
}); });
}, },
// refund(id){ // refund(id){
// console.log(id);
// this.$confirm('退?', '', { // this.$confirm('退?', '', {
// confirmButtonText: '', // confirmButtonText: '',
// cancelButtonText: '', // cancelButtonText: '',
@ -937,7 +932,6 @@ export default {
pageSize: 9999 pageSize: 9999
}; };
getListByUser(queryFor).then(res => { getListByUser(queryFor).then(res => {
console.log(res);
this.handstationlist = res.rows; this.handstationlist = res.rows;
}); });
} }

View File

@ -284,7 +284,6 @@ export default {
//deldisease //deldisease
deldisease(index) { deldisease(index) {
this.form.nurseTypeList.splice(index, 1); this.form.nurseTypeList.splice(index, 1);
console.log(this.form.nurseTypeList);
}, },
adddisease() { adddisease() {
var obj = { var obj = {

View File

@ -63,6 +63,7 @@
<el-button v-if="scope.row.orderStatus == 'WAIT_PAY'">待付款</el-button> <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 == '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 == 'WAIT_DISPATCH'">待派单</el-button>
<el-button type="primary" v-if="scope.row.orderStatus == 'WAIT_RECEIVE'">待接单</el-button>
<el-button type="primary" v-if="scope.row.orderStatus == 'NOT_FINISH'">未完成</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="primary" v-if="scope.row.orderStatus == 'COMPLETE'">待评价</el-button>
<el-button type="success" v-if="scope.row.orderStatus == 'EVALUATED'">服务完成</el-button> <el-button type="success" v-if="scope.row.orderStatus == 'EVALUATED'">服务完成</el-button>
@ -121,31 +122,62 @@
<el-dialog title="查看预约订单信息" :visible.sync="innerVisible4" append-to-body width="1280px"> <el-dialog title="查看预约订单信息" :visible.sync="innerVisible4" append-to-body width="1280px">
<el-form :inline="true" ref="form" :model="query" :rules="rules" label-width="130px"> <el-form :inline="true" ref="form" :model="query" :rules="rules" label-width="130px">
<el-form-item label="订单编号" prop="orderNo"> <el-form-item label="订单编号" prop="orderNo">
<el-input v-model="query.orderNo" disabled style="width: 250px" /> <div class="text">{{query.orderNo}}</div>
</el-form-item> </el-form-item>
<el-form-item label="订单状态" prop="orderStatus"> <el-form-item label="订单状态" prop="orderStatus">
<el-input :value="switchOrderStatus(query.orderStatus)" style="width: 250px" disabled></el-input> <div class="text">{{switchOrderStatus(query.orderStatus)}}</div>
</el-form-item> </el-form-item>
<el-form-item label="订单总金额" prop="totalPrice"> <el-form-item label="订单总金额" prop="totalPrice">
<el-input v-model="query.totalPrice" disabled style="width: 250px" /> <div class="text">{{query.totalPrice}}</div>
</el-form-item> </el-form-item>
<el-form-item label="订单数量" prop="orderCount"> <el-form-item label="订单数量" prop="orderCount">
<el-input v-model="query.orderCount" disabled style="width: 250px" /> <div class="text">{{query.orderCount}}</div>
</el-form-item>
<el-form-item label="佣金金额" prop="orderCount">
<div class="text">{{query.orderCommissionAmount}}</div>
</el-form-item> </el-form-item>
<el-form-item label="护理项目名称" prop="nurseItemName"> <el-form-item label="护理项目名称" prop="nurseItemName">
<el-input v-model="query.nurseItemName" disabled style="width: 250px" /> <div class="text">{{query.nurseItemName}}</div>
</el-form-item> </el-form-item>
<!-- <el-form-item label="护理员名称" prop="nursePersonName">
<div class="text">{{query.nursePersonName}}</div>
</el-form-item>-->
<el-form-item label="服务时间" prop="time"> <el-form-item label="服务时间" prop="time">
<el-input v-model="query.time" disabled style="width: 250px" /> <div class="text">{{query.time}}</div>
</el-form-item> </el-form-item>
<el-form-item label="护理项目时长" prop="itemServeDurationUnit"> <el-form-item label="护理项目时长" prop="itemServeDurationUnit">
<el-input v-model="query.itemServeDurationUnit" disabled style="width: 250px" /> <div class="text">{{query.itemServeDurationUnit}}</div>
</el-form-item> </el-form-item>
<el-form-item label="护理站名称" prop="nurseStationName"> <el-form-item label="护理站名称" prop="nurseStationName">
<el-input v-model="query.nurseStationName" disabled style="width: 250px" /> <div class="text">{{query.nurseStationName}}</div>
</el-form-item>
<el-form-item label="评价星级" prop="compositeScore" v-if="query.orderStatus =='EVALUATED'">
<div class="text">{{query.compositeScore}}</div>
</el-form-item>
<el-form-item
label="评价满意度"
prop="evaluateSatisfaction"
v-if="query.orderStatus == 'EVALUATED'"
>
<div class="text">{{query.evaluateSatisfaction}}</div>
</el-form-item>
<el-form-item label="是否失能" prop="disablingCondition">
<div class="text">{{query.disablingCondition}}</div>
</el-form-item>
<el-form-item label="失能情况" prop="disablingReason">
<div class="text">{{query.disablingReason}}</div>
</el-form-item>
<el-form-item label="健康状况" prop="diseaseName">
<div
class="text"
style="height:100px;line-height:26px;overflow: scroll"
>{{query.diseaseName}}</div>
</el-form-item> </el-form-item>
<el-form-item label="服务地址" prop="serviceAddress"> <el-form-item label="服务地址" prop="serviceAddress">
<el-input v-model="query.serviceAddress" disabled style="width: 250px" /> <div
class="text"
style="height:100px;line-height:26px;overflow: scroll"
>{{query.serviceAddress}}</div>
</el-form-item> </el-form-item>
<el-form-item <el-form-item
label="服务到岗照片" label="服务到岗照片"
@ -174,13 +206,6 @@
> >
<img class="img" :src="baseurl + query.userSignaturePictureUrl" alt /> <img class="img" :src="baseurl + query.userSignaturePictureUrl" alt />
</el-form-item> </el-form-item>
<el-form-item
label="评价满意度"
prop="evaluateSatisfaction"
v-if="query.orderStatus == 'EVALUATED'"
>
<el-input v-model="query.evaluateSatisfaction" disabled style="width: 250px" />
</el-form-item>
<el-table <el-table
:data="query.appointmentOrderConsumableList" :data="query.appointmentOrderConsumableList"
align="center" align="center"
@ -207,46 +232,6 @@
" "
></div> ></div>
</el-dialog> </el-dialog>
<!-- 派单弹框 -->
<el-dialog title="派单" :visible.sync="innerdispatch" append-to-body width="500px" height="100px">
<el-form ref="form" :model="form" :rules="rules" label-width="130px">
<el-form-item label="护理员姓名" prop="nursePersonName">
<el-button
type
v-if="nurseName == '请选择护理员'"
style="width: 300px; text-align: left; height: 36px; color: #c0c4cc"
@click="clicknursePersonName()"
>{{ nurseName }}</el-button>
<el-button
type
@click="clicknursePersonName()"
v-else
style="
width: 300px;
text-align: left;
height: 36px;
padding-left: -10px;
"
>{{ nurseName }}</el-button>
</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
>-->
</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>
<!-- 取消预约弹框 --> <!-- 取消预约弹框 -->
<el-dialog title="取消预约" :visible.sync="innerrefund" append-to-body width="500px"> <el-dialog title="取消预约" :visible.sync="innerrefund" append-to-body width="500px">
<el-form :inline="true" :rules="rules" label-width="120px"> <el-form :inline="true" :rules="rules" label-width="120px">
@ -276,8 +261,8 @@
<el-button type="primary" @click="ordercacenl"> </el-button> <el-button type="primary" @click="ordercacenl"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
<!-- 姓名弹框 --> <!-- 派单护理员弹框 -->
<el-dialog :visible.sync="nursePersonNameinfo" width="1000px" append-to-body> <el-dialog :visible.sync="nursePersonNameinfo" width="1300px" append-to-body title="派单">
<el-form <el-form
ref="queryForm" ref="queryForm"
:model="querynursePersonname" :model="querynursePersonname"
@ -285,49 +270,87 @@
label-width="80px" label-width="80px"
:inline="true" :inline="true"
> >
<el-form-item label="姓名" prop="nursePersonName" label-width="120"> <el-form-item label="护理人员姓名" prop="nursePersonName" label-width="120">
<el-input v-model="querynursePersonname.nursePersonName" placeholder="请输入姓名" clearable /> <el-input
v-model="querynursePersonname.nursePersonName"
placeholder="请输入护理人员姓名"
clearable
/>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery2">搜索</el-button> <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> <el-button icon="el-icon-refresh" size="mini" @click="resetQuery2">重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table :data="dispatchlist" @cell-dblclick="nursePersonclick"> <el-table :data="dispatchlist" @cell-dblclick="submitForm">
<el-table-column label="请选择" width="70" align="center"> <el-table-column label="请选择" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
type="primary" type="primary"
style="width: 15px; height: 15px; overflow: hidden" style="width: 15px; height: 15px; overflow: hidden"
v-if="nursePersonid == scope.row.nurseStationPersonId" v-if="nursePersonlist.nurseStationPersonId == scope.row.nurseStationPersonId"
circle circle
@click="nursePersonclick(scope.row)" @click="submitForm(scope.row)"
></el-button> ></el-button>
<el-button <el-button
v-else v-else
style="width: 15px; height: 15px; overflow: hidden" style="width: 15px; height: 15px; overflow: hidden"
circle circle
@click="nursePersonclick(scope.row)" @click="submitForm(scope.row)"
></el-button> ></el-button>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column property="nursePersonCode" label="护理员编号" width="150" align="center"></el-table-column> <el-table-column property="nurseStationName" label="所属护理站" align="center"></el-table-column>
<el-table-column property="nursePersonName" label="护理站人员姓名" width="150" align="center"></el-table-column> <!-- <el-table-column property="nursePersonCode" label="护理员编号" align="center"></el-table-column> -->
<el-table-column property="nursePersonType" label="护理站人员类型" width="150" align="center"> <el-table-column property="nursePersonName" label="护理人员姓名" align="center"></el-table-column>
<el-table-column property="workStatus" label="在线状态" align="center">
<template slot-scope="scope">
<el-button v-if="scope.row.workStatus == 'ONLINE'" type="success">在线</el-button>
<el-button v-if="scope.row.workStatus == 'BE_BUSY'" type="warning">忙碌</el-button>
<el-button v-if="scope.row.workStatus == 'OFFLINE'" type="info">离线</el-button>
</template>
</el-table-column>
<el-table-column property="evaluateStarCount" label="星级评价" align="center" width="180">
<template slot-scope="scope">
<el-rate :value="scope.row.evaluateStarCount" disabled></el-rate>
</template>
</el-table-column>
<el-table-column property="nursePersonType" label="护理人员类型" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.nursePersonType == "NURSE" ? "护士" : "" }} {{ scope.row.nursePersonType == "NURSE" ? "护士" : "" }}
{{ scope.row.nursePersonType == "NURSE_TEACHER" ? "护理师" : "" }} {{ scope.row.nursePersonType == "NURSE_TEACHER" ? "护理师" : "" }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column property="phone" label="手机号" width="150" align="center"></el-table-column> <el-table-column property="positionalTitleLevel" label="职称级别" align="center">
<template slot-scope="scope">
{{ scope.row.positionalTitleLevel == "PRIMARY_LEVEL" ? "初级" : "" }}
{{ scope.row.positionalTitleLevel == "MIDDLE_LEVEL" ? "中级" : "" }}
{{ scope.row.positionalTitleLevel == "HIGH_LEVEL" ? "高级" : "" }}
</template>
</el-table-column>
<el-table-column property="phone" label="手机号" align="center"></el-table-column>
<el-table-column label="性别" align="center" prop="sex"> <el-table-column label="性别" align="center" prop="sex">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.sex == "MALE" ? "男" : "" }} {{ scope.row.sex == "MALE" ? "男" : "" }}
{{ scope.row.sex == "FEMALE" ? "女" : "" }} {{ scope.row.sex == "FEMALE" ? "女" : "" }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column property="nursePersonName" label="查看证书" align="center">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-zoom-in"
@click="nursePersonclick(scope.row)"
v-hasPermi="['system:appointmentOrder:query']"
>查看</el-button>
</template>
</el-table-column>
</el-table> </el-table>
<div slot="footer" class="dialog-footer">
<el-button @click="nursePersonNameinfocancel"> </el-button>
<el-button type="primary" @click="submitFormclick"> </el-button>
</div>
<pagination <pagination
v-show="total2 > 0" v-show="total2 > 0"
:total="total2" :total="total2"
@ -336,6 +359,20 @@
@pagination="handleQuery2" @pagination="handleQuery2"
/> />
</el-dialog> </el-dialog>
<!-- 查看证书 -->
<el-dialog :visible.sync="certificateshow" width="1000px" append-to-body title="查看证书">
<el-table :data="PersonChecksrcList">
<el-table-column property="certificateUrl" label="证书图片" align="center">
<template slot-scope="scope">
<img :src="baseurl+scope.row.certificateUrl" alt style="width:100px;height:100px" />
</template>
</el-table-column>
<el-table-column property="certificateName" label="证书名称" align="center"></el-table-column>
</el-table>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="certificateshow=false"> </el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
@ -346,7 +383,8 @@ import {
getPerson, getPerson,
dispatchsubmit, dispatchsubmit,
xylWeChatRefundNotify, xylWeChatRefundNotify,
appointmentOrderDetails appointmentOrderDetails,
getPersonInfo
} from "@/api/system/order"; } from "@/api/system/order";
import { getListByUser } from "@/api/system/userlist.js"; import { getListByUser } from "@/api/system/userlist.js";
import baseurl from "@/api/baseurl.js"; import baseurl from "@/api/baseurl.js";
@ -402,8 +440,12 @@ export default {
innerrefund: false, innerrefund: false,
// //
innerdispatch: false, innerdispatch: false,
// //
nursePersonNameinfo: false, nursePersonNameinfo: false,
certificateshow: false,
//list
nursePersonlist: {},
PersonChecksrcList: [],
// //
ids: [], ids: [],
// //
@ -521,7 +563,6 @@ export default {
} }
this.getList(); this.getList();
this.innerrefund = false; this.innerrefund = false;
console.log(res);
}); });
}, },
// //
@ -538,6 +579,8 @@ export default {
return "待派单"; return "待派单";
case "NOT_FINISH": case "NOT_FINISH":
return "未完成"; return "未完成";
case "WAIT_RECEIVE":
return "待接单";
case "COMPLETE": case "COMPLETE":
return "待评价"; return "待评价";
case "EVALUATED": case "EVALUATED":
@ -558,20 +601,77 @@ export default {
const id = row.orderNo; const id = row.orderNo;
this.map = null; this.map = null;
appointmentOrderDetails(id).then(res => { appointmentOrderDetails(id).then(res => {
res.data.forEach(e => { res.data.time = res.data.serviceDate + "-" + res.data.serviceStartTime;
if (e.serviceDate) { this.query = res.data;
e.time = e.serviceDate + "-" + e.serviceStartTime; res.data.disablingCondition == "DISABLED"
} ? (res.data.disablingCondition = "是")
}); : "";
this.query = res.data[0]; res.data.disablingCondition == "NOT_DISABLED"
? (res.data.disablingCondition = "否")
: "";
if (row.orderStatus == "EVALUATED") { if (row.orderStatus == "EVALUATED") {
if (res.data) { if (res.data) {
if (res.data[0].evaluateSatisfaction == "COMMONLY") { if (res.data.evaluateSatisfaction == "COMMONLY") {
this.query.evaluateSatisfaction = "一般"; this.query.evaluateSatisfaction = "一般";
} else if (res.data[0].evaluateSatisfaction == "SATISFIED") { } else if (res.data.evaluateSatisfaction == "SATISFIED") {
this.query.evaluateSatisfaction = "满意"; this.query.evaluateSatisfaction = "满意";
} else if (res.data[0].evaluateSatisfaction == "DISSATISFIED") { } else if (res.data.evaluateSatisfaction == "DISSATISFIED") {
this.query.evaluateSatisfaction = "不满意"; this.query.evaluateSatisfaction = "不满意";
} else if (res.data.evaluateSatisfaction == "VERYSATISFIED") {
this.query.evaluateSatisfaction = "非常满意";
} else if (res.data.evaluateSatisfaction == "VERYDISSATISFIED") {
this.query.evaluateSatisfaction = "非常不满意";
}
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);
} else {
this.loading = false;
this.innerVisible4 = true;
}
});
},
//
seeLook(row) {
this.loading = true;
const id = row.orderNo;
this.map = null;
appointmentOrderDetails(id).then(res => {
res.data.time = res.data.serviceDate + "-" + res.data.serviceStartTime;
this.query = res.data;
res.data.disablingCondition == "DISABLED"
? (res.data.disablingCondition = "是")
: "";
res.data.disablingCondition == "NOT_DISABLED"
? (res.data.disablingCondition = "否")
: "";
if (row.orderStatus == "EVALUATED") {
if (res.data) {
if (res.data.evaluateSatisfaction == "COMMONLY") {
this.query.evaluateSatisfaction = "一般";
} else if (res.data.evaluateSatisfaction == "SATISFIED") {
this.query.evaluateSatisfaction = "满意";
} else if (res.data.evaluateSatisfaction == "DISSATISFIED") {
this.query.evaluateSatisfaction = "不满意";
} else if (res.data.evaluateSatisfaction == "VERYSATISFIED") {
this.query.evaluateSatisfaction = "非常满意";
} else if (res.data.evaluateSatisfaction == "VERYDISSATISFIED") {
this.query.evaluateSatisfaction = "非常不满意";
} }
this.loading = false; this.loading = false;
this.innerVisible4 = true; this.innerVisible4 = true;
@ -600,40 +700,41 @@ export default {
// //
dispatch(row) { dispatch(row) {
this.querynursePersonname.orderNo = row.orderNo; this.querynursePersonname.orderNo = row.orderNo;
this.nurseName = "请选择护理员";
this.innerdispatch = true;
this.nursePersonid = "";
},
//
clicknursePersonName() {
getPerson(this.querynursePersonname).then(res => { getPerson(this.querynursePersonname).then(res => {
this.dispatchlist = res.rows; this.dispatchlist = res.rows;
this.total2 = res.total; this.total2 = res.total;
console.log(this.dispatchlist);
this.nursePersonNameinfo = true; this.nursePersonNameinfo = true;
}); });
}, },
// //
submitForm() { nursePersonNameinfocancel() {
this.nursePersonNameinfo = false;
this.nursePersonlist = {};
},
//
submitFormclick() {
let params = { let params = {
nurseStationPersonId: this.nursePersonid, nurseStationPersonId: this.nursePersonlist.nurseStationPersonId,
orderNo: this.querynursePersonname.orderNo orderNo: this.querynursePersonname.orderNo
}; };
dispatchsubmit(params).then(res => { dispatchsubmit(params).then(res => {
if (res.code == 200) { if (res.code == 200) {
this.$modal.msgSuccess("派单成功"); this.$modal.msgSuccess("派单成功");
} }
this.innerdispatch = false; this.nursePersonNameinfo = false;
this.getList(); this.getList();
this.nurseName = "请选择护理员";
}); });
}, },
// submitForm(row) {
this.nursePersonlist = row;
},
//
nursePersonclick(row) { nursePersonclick(row) {
this.nursePersonid = row.nurseStationPersonId; this.PersonChecksrcList = [];
this.nurseName = row.nursePersonName; getPersonInfo(row.nurseStationPersonId).then(res => {
this.nursePersonNameinfo = false; this.PersonChecksrcList = res.data;
console.log(row); this.certificateshow = true;
});
}, },
// //
cencel(row) { cencel(row) {
@ -674,7 +775,6 @@ export default {
handleQuery2() { handleQuery2() {
getPerson(this.querynursePersonname).then(res => { getPerson(this.querynursePersonname).then(res => {
this.dispatchlist = res.rows; this.dispatchlist = res.rows;
console.log(this.querynursePersonname);
// this.innerdispatch = true; // this.innerdispatch = true;
}); });
}, },
@ -713,7 +813,6 @@ export default {
pageSize: 9999 pageSize: 9999
}; };
getListByUser(queryFor).then(res => { getListByUser(queryFor).then(res => {
console.log(res);
this.handstationlist = res.rows; this.handstationlist = res.rows;
}); });
}, },
@ -729,7 +828,6 @@ export default {
}, },
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
// console.log('row :>> ', row);
this.$confirm("是否确认删除订单信息的数据项?", "提示", { this.$confirm("是否确认删除订单信息的数据项?", "提示", {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
@ -766,5 +864,21 @@ export default {
width: 100%; width: 100%;
height: 600px; height: 600px;
} }
.text {
width: 250px;
height: 36px;
line-height: 36px;
padding-left: 15px;
font-size: 14px;
border-radius: 4px;
padding: 0 15px;
border: 1px solid #e6ebf5;
}
::v-deep .el-dialog {
margin-top: 30px !important;
}
::v-deep .el-dialog__body {
padding: 0 20px 20px !important;
}
</style> </style>

View File

@ -602,9 +602,7 @@ export default {
methods: { methods: {
// //
handleResetPwd(row) { handleResetPwd(row) {
console.log(row)
const id= row.id const id= row.id
console.log(id)
// const id=row.userId // const id=row.userId
this.$prompt('请输入新的密码', "提示", { this.$prompt('请输入新的密码', "提示", {
confirmButtonText: "确定", confirmButtonText: "确定",
@ -614,7 +612,6 @@ export default {
inputErrorMessage: "用户密码长度必须介于 5 和 20 之间", inputErrorMessage: "用户密码长度必须介于 5 和 20 之间",
}) })
.then((res) => { .then((res) => {
console.log(res)
const params = { const params = {
id, id,
password: res.value password: res.value
@ -627,7 +624,6 @@ export default {
}, },
// //
province(item) { province(item) {
console.log(item);
this.queryParams.city = ""; this.queryParams.city = "";
this.queryParams.area = ""; this.queryParams.area = "";
this.queryParams.areaCode = ""; this.queryParams.areaCode = "";
@ -635,9 +631,7 @@ export default {
// this.value2 = ""; // this.value2 = "";
// this.value3 = ""; // this.value3 = "";
SecondaryLevelInfo(item.id).then((res) => { SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
this.SecondaryLevelInfolist = res.data; this.SecondaryLevelInfolist = res.data;
// console.log(this.SecondaryLevelInfolist);
this.citylist = res.data; this.citylist = res.data;
}); });
}, },
@ -647,41 +641,32 @@ export default {
this.queryParams.areaCode = ""; this.queryParams.areaCode = "";
// this.value2 = ""; // this.value2 = "";
// this.value3 = ""; // this.value3 = "";
console.log(item);
SecondaryLevelInfo(item.id).then((res) => { SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
this.arealists = res.data; this.arealists = res.data;
}); });
}, },
// //
clickarea(item) { clickarea(item) {
// this.value3 = ""; // this.value3 = "";
console.log(item);
SecondaryLevelInfo(item.id).then((res) => { SecondaryLevelInfo(item.id).then((res) => {
console.log(res);
this.streetlist = res.data; this.streetlist = res.data;
}); });
}, },
// //
clickstreet(item) { clickstreet(item) {
this.form.areaCode = item.areaCode; this.form.areaCode = item.areaCode;
console.log(this.form);
}, },
// //
loadMore() { loadMore() {
console.log("1");
var a = Math.ceil(this.total2 / 10); var a = Math.ceil(this.total2 / 10);
console.log(this.arealist.length);
if (this.arealist.length + 1 >= this.total2) { if (this.arealist.length + 1 >= this.total2) {
} else { } else {
if (this.getProvincequeryParams.pageNum >= a) { if (this.getProvincequeryParams.pageNum >= a) {
} else { } else {
this.getProvincequeryParams.pageNum++; this.getProvincequeryParams.pageNum++;
FirstLevel(this.getProvincequeryParams).then((res) => { FirstLevel(this.getProvincequeryParams).then((res) => {
console.log(res);
res.rows.forEach((e) => { res.rows.forEach((e) => {
this.arealist.push(e); this.arealist.push(e);
console.log(this.arealist);
}); });
}); });
} }
@ -689,10 +674,8 @@ export default {
}, },
Provincelist() { Provincelist() {
FirstLevel(this.getProvincequeryParams).then((res) => { FirstLevel(this.getProvincequeryParams).then((res) => {
console.log(res);
this.arealist = res.data; this.arealist = res.data;
this.total2 = res.total; this.total2 = res.total;
console.log(this.arealist);
}); });
}, },
/** 查询被护理人基本信息列表 */ /** 查询被护理人基本信息列表 */

File diff suppressed because it is too large Load Diff

View File

@ -6,11 +6,15 @@ import {
updatePerson, updatePerson,
stationList, stationList,
StationDepartmentList, StationDepartmentList,
getNurseStationPersonCheck,
updateNurseStationPersonChecks
} from "@/api/system/person"; } from "@/api/system/person";
import { getToken } from "@/utils/auth"; import { getToken } from "@/utils/auth";
import { getListByUser } from "@/api/system/userlist.js"; import { getListByUser } from "@/api/system/userlist.js";
import stationAcatar from "../stationAvatar/index.vue";
import baseurl from '@/api/baseurl'
export default { export default {
components: { stationAcatar },
name: "Person", name: "Person",
data() { data() {
// 验证手机号的规则 // 验证手机号的规则
@ -34,7 +38,25 @@ export default {
cb(new Error("请输入正确的联系电话")); cb(new Error("请输入正确的联系电话"));
}; };
return { return {
baseurl: null,
//男女选择 //男女选择
positionalTitleLevellist: [{
label: "初级",
value: "PRIMARY_LEVEL",
}, {
label: "中级",
value: "MIDDLE_LEVEL",
}, {
label: "高级",
value: "HIGH_LEVEL",
}],
modifyCheckStatuslist: [{
label: "已审核",
value: "CHECKED",
}, {
label: "未审核",
value: "NOT_CHECK",
}],
sexs: [{ sexs: [{
label: "男", label: "男",
value: "MALE", value: "MALE",
@ -53,15 +75,12 @@ export default {
value: "NURSE_TEACHER", value: "NURSE_TEACHER",
}, },
], ],
innerVisible: false, innerVisible: false,
innerVisible2: false, innerVisible2: false,
innerVisiblexg: false, innerVisiblexg: false,
innerVisiblexg2: false, innerVisiblexg2: false,
// 遮罩层 // 遮罩层
loading: true, loading: true,
// 用户导入参数 // 用户导入参数
upload: { upload: {
// 是否显示弹出层(用户导入) // 是否显示弹出层(用户导入)
@ -107,8 +126,8 @@ export default {
title3: "", title3: "",
// 修改弹出层 // 修改弹出层
open: false, open: false,
templeopen: false,
// 添加弹出层 // 添加弹出层
open2: false,
//权限查询 //权限查询
// 查询参数 // 查询参数
queryParams: { queryParams: {
@ -132,7 +151,6 @@ export default {
id: null, id: null,
nurseStationId: null, nurseStationId: null,
}, },
queryParams3: { queryParams3: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
@ -150,12 +168,21 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
}, },
// 表单参数 // 表单参数
form: {}, form: {},
index: "", index: "",
idd: 1,
// 表单校验 // 表单校验
rules: { rules: {
geniusItem: [
{ required: true, message: "请输入擅长项目", trigger: "blur" },
],
birthDate: [
{ required: true, message: "请选择出生日期", trigger: "blur" },
],
positionalTitleLevel: [
{ required: true, message: "请选择职称级别", trigger: "blur" },
],
nurseStationId: [ nurseStationId: [
{ required: true, message: "请选择所属护理站", trigger: "blur" }, { required: true, message: "请选择所属护理站", trigger: "blur" },
], ],
@ -179,48 +206,60 @@ export default {
address: [ address: [
{ required: true, message: "居住地址不能为空", trigger: "blur" }, { required: true, message: "居住地址不能为空", trigger: "blur" },
], ],
nurseStationPersonList: {
nursePersonName: [{
required: true,
message: "请选择所属护理站",
trigger: "blur",
}, ],
departmentCode: [
{ required: true, message: "所属科室不能为空", trigger: "blur" },
],
nurseStationId: [
{ required: true, message: "请选择所属护理站", trigger: "blur" },
],
nursePersonName: [
{ required: true, message: "护理人姓名不能为空", trigger: "blur" },
],
nursePersonType: [
{ required: true, message: "护理人职称不能为空", trigger: "blur" },
],
sex: [{ required: true, message: "性别不能为空", trigger: "blur" }],
phone: [{
required: true,
validator: checkMobile,
message: "",
trigger: "blur",
}, ],
address: [
{ required: true, message: "居住地址不能为空", trigger: "blur" },
],
},
}, },
}; };
}, },
created() { created() {
this.baseurl = baseurl
this.infos(); this.infos();
this.info(); this.info();
}, },
methods: { methods: {
//删除Certificate
delCertificate(index) {
if (this.form.nurseStationPersonCertificateList.length == 1) {
this.$message.error("不可全部删除");
} else {
this.form.nurseStationPersonCertificateList.splice(index, 1);
}
},
//添加Certificate
addCertificate() {
this.idd++;
var obj = {
certificateName: null,
certificateUrl: null,
sort: null,
idd: this.idd
};
if (this.form.nurseStationPersonCertificateList.length == 5) {
this.$message.error("最多只能5条");
} else {
this.form.nurseStationPersonCertificateList.push(obj);
}
},
imgUrl(imgUrl) {},
//接收图片所属的item
imgclassifyItem(item) {
let items = JSON.parse(item);
if (items.idd && !items.id) {
this.form.nurseStationPersonCertificateList.forEach((e) => {
if (e.idd == items.idd) {
e.certificateUrl = items.certificateUrl;
}
});
} else if (!items.idd && items.id) {
this.form.nurseStationPersonCertificateList.forEach((e) => {
if (e.id == items.id) {
e.certificateUrl = items.certificateUrl;
}
});
}
},
// // 新增所属科室按钮 // // 新增所属科室按钮
departclick(item, index) { departclick(item, index) {
if (this.form.nurseStationId != null) { if (this.form.nurseStationId != null) {
this.getList3(); this.getList3();
console.log(item);
this.departid = item.departmentCode; this.departid = item.departmentCode;
this.innerVisible2 = true; this.innerVisible2 = true;
this.index = index; this.index = index;
@ -231,7 +270,6 @@ export default {
}, },
// // 修改所属科室按钮 // // 修改所属科室按钮
departclick2() { departclick2() {
console.log(this.form.nurseStationId);
if (this.form.nurseStationId != null) { if (this.form.nurseStationId != null) {
this.getList3(); this.getList3();
this.departid2 = this.form.departmentCode; this.departid2 = this.form.departmentCode;
@ -257,7 +295,6 @@ export default {
}, },
// 修改护理站 // 修改护理站
nurseclick2(row) { nurseclick2(row) {
console.log(row);
this.nurseStationName = row.nurseStationName; this.nurseStationName = row.nurseStationName;
this.stationid2 = row.id; this.stationid2 = row.id;
this.form.nurseStationId = row.id; this.form.nurseStationId = row.id;
@ -265,7 +302,6 @@ export default {
this.innerVisiblexg = false; this.innerVisiblexg = false;
this.form.nursename = row.nurseStationName; this.form.nursename = row.nurseStationName;
}, },
// 护理站名称 // 护理站名称
nurseclick(row) { nurseclick(row) {
this.nursename = row.nurseStationName; this.nursename = row.nurseStationName;
@ -278,13 +314,10 @@ export default {
row.nurseStationName; row.nurseStationName;
this.form.nurseStationPersonList[this.index].nurseStationId = row.id; this.form.nurseStationPersonList[this.index].nurseStationId = row.id;
}, },
// 所属科室 // 所属科室
StationDepartmentclick(row) { StationDepartmentclick(row) {
console.log(row);
this.departname = row.departmentName; this.departname = row.departmentName;
this.departid = row.departmentCode; this.departid = row.departmentCode;
console.log(this.departid);
this.departmentCode = row.departmentCode; this.departmentCode = row.departmentCode;
// this.form.nurseStationId = row.id; // this.form.nurseStationId = row.id;
this.innerVisible2 = false; this.innerVisible2 = false;
@ -293,11 +326,9 @@ export default {
row.departmentName; row.departmentName;
this.form.nurseStationPersonList[this.index].departmentCode = this.form.nurseStationPersonList[this.index].departmentCode =
row.departmentCode; row.departmentCode;
console.log(this.form);
}, },
// 修改科室 // 修改科室
StationDepartmentclick2(row) { StationDepartmentclick2(row) {
console.log(row);
this.departmentName = row.departmentName; this.departmentName = row.departmentName;
this.form.departmentCode = row.departmentCode; this.form.departmentCode = row.departmentCode;
this.departid2 = row.departmentCode; this.departid2 = row.departmentCode;
@ -314,7 +345,6 @@ export default {
this.loading = false; this.loading = false;
}); });
}, },
getList3() { getList3() {
this.loading = true; this.loading = true;
StationDepartmentList(this.queryParams3).then((res) => { StationDepartmentList(this.queryParams3).then((res) => {
@ -326,7 +356,6 @@ export default {
// 取消按钮 // 取消按钮
cancel() { cancel() {
this.open = false; this.open = false;
this.open2 = false;
this.nurseStationName = "请选择所属护理站"; this.nurseStationName = "请选择所属护理站";
this.departmentName = "请选择所属科室"; this.departmentName = "请选择所属科室";
// this.upload.open=false; // this.upload.open=false;
@ -335,9 +364,10 @@ export default {
// 表单重置 // 表单重置
reset() { reset() {
this.form = { this.form = {
geniusItem: null,
birthDate: null,
id: null, id: null,
pageNum: 1, nurseStationId: null,
pageSize: 10,
departmentCode: null, departmentCode: null,
userId: null, userId: null,
nursePersonCode: null, nursePersonCode: null,
@ -351,19 +381,12 @@ export default {
updateTime: null, updateTime: null,
nurseStationName: "请选择所属护理站", nurseStationName: "请选择所属护理站",
departmentName: "请选择所属科室", departmentName: "请选择所属科室",
nurseStationPersonList: [{ nurseStationPersonCertificateList: [{
id: "", certificateName: null,
nurseStationId: "", certificateUrl: null,
departmentCode: "", sort: null,
nursePersonCode: "", idd: this.idd
nursePersonName: "", }]
nursePersonType: "",
nurseStationName: "请选择所属护理站",
phone: "",
address: "",
sex: "",
departmentName: "请选择所属科室",
}, ],
}; };
this.resetForm("form"); this.resetForm("form");
}, },
@ -421,12 +444,14 @@ export default {
this.handleQuery3(); this.handleQuery3();
}, },
resetQuery() { resetQuery() {
if (this.nurseStationlist[0]) { if (this.nurseStationlist[0]) {
this.queryParams.pageNum = 1; this.queryParams.pageNum = 1;
this.queryParams.pageSize = 10; this.queryParams.pageSize = 10;
this.queryParams.departmentName = null; this.queryParams.departmentName = null;
this.queryParams.phone = null;
this.queryParams.nursePersonName = null; this.queryParams.nursePersonName = null;
this.queryParams.positionalTitleLevel = null;
this.queryParams.modifyCheckStatus = null;
} }
this.handleQuery(); this.handleQuery();
}, },
@ -438,9 +463,9 @@ export default {
}, },
/** 新增按钮操作 */ /** 新增按钮操作 */
handleAdd() { handleAdd() {
this.queryParams3.nurseStationId = null; this.queryParams3.nurseStationId = null
this.reset(); this.reset();
this.open2 = true; this.open = true;
this.title = "添加护理站人员信息"; this.title = "添加护理站人员信息";
this.title2 = "请选择所属护理站"; this.title2 = "请选择所属护理站";
this.title3 = "请选择科室"; this.title3 = "请选择科室";
@ -449,10 +474,18 @@ export default {
handleUpdate(row) { handleUpdate(row) {
const id = row.id || this.ids; const id = row.id || this.ids;
getPerson(id).then((response) => { getPerson(id).then((response) => {
console.log(response);
this.departmentName = response.data.departmentName; this.departmentName = response.data.departmentName;
this.nurseStationName = response.data.nurseStationName; this.nurseStationName = response.data.nurseStationName;
this.form = response.data; this.form = response.data;
var obj = {
certificateName: null,
certificateUrl: null,
sort: null,
idd: this.idd
};
if (this.form.nurseStationPersonCertificateList.length == 0) {
this.form.nurseStationPersonCertificateList.push(obj);
}
this.queryParams3.nurseStationId = response.data.nurseStationId; this.queryParams3.nurseStationId = response.data.nurseStationId;
this.open = true; this.open = true;
this.title = "修改护理站人员信息"; this.title = "修改护理站人员信息";
@ -465,18 +498,15 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
if (this.form.id == null) {
this.form.nursePersonName = this.form.nurseStationPersonList[0].nursePersonName
this.form.nursePersonType = this.form.nurseStationPersonList[0].nursePersonType
this.form.sex = this.form.nurseStationPersonList[0].sex
this.form.address = this.form.nurseStationPersonList[0].address
this.form.departmentCode = this.form.nurseStationPersonList[0].departmentCode
this.form.departmentName = this.form.nurseStationPersonList[0].departmentName
this.form.phone = this.form.nurseStationPersonList[0].phone
}
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.nurseStationPersonCertificateList.length > 0) {
this.form.nurseStationPersonCertificateList.forEach(e => {
if (!e.certificateName && !e.certificateUrl && !e.sort) {
this.form.nurseStationPersonCertificateList = this.form.nurseStationPersonCertificateList.filter(el => el != e)
}
})
}
if (this.form.id != null) { if (this.form.id != null) {
updatePerson(this.form).then((response) => { updatePerson(this.form).then((response) => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
@ -486,7 +516,7 @@ export default {
} else { } else {
addPerson(this.form).then((response) => { addPerson(this.form).then((response) => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open2 = false; this.open = false;
this.getList(); this.getList();
this.nurseStationName = "请选择所属护理站"; this.nurseStationName = "请选择所属护理站";
this.departmentName = "请选择所属科室"; this.departmentName = "请选择所属科室";
@ -495,6 +525,26 @@ export default {
} }
}); });
}, },
// 审核
handshenhe(row) {
getNurseStationPersonCheck(row.id).then(res => {
this.form = res.data;
this.templeopen = true;
})
},
// 审核提交
templesubmit() {
this.form.positionalTitleLevel = this.form.positionalTitleLevelCheck
this.form.geniusItem = this.form.geniusItemCheck
updateNurseStationPersonChecks(this.form).then(res => {
this.$modal.msgSuccess("审核成功");
this.getList();
this.templeopen = false
})
},
templeopenfalse() {
this.templeopen = false
},
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const ids = row.id || this.ids; const ids = row.id || this.ids;

View File

@ -0,0 +1,514 @@
<template>
<div class="app-container">
<el-form
:model="queryParams"
ref="queryForm"
size="small"
:inline="true"
v-show="showSearch"
label-width="100px"
>
<el-form-item label="护理站" prop="nurseStationId">
<el-select
v-model="queryParams.nurseStationId"
placeholder="请选择护理站"
@keyup.enter.native="handleQuery"
@change="handleQuery"
>
<el-option
v-for="item in nurseStationlist"
:key="item.id"
:label="item.nurseStationName"
:value="item.id"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="护理人员名称" prop="nursePersonName">
<el-button type class="stationbtn" @click="nursePersonNameclick(true)">
{{
queryParams.nursePersonName
}}
</el-button>
<!-- <el-input
v-model="queryParams.nursePersonName"
placeholder="请输入护理人员名称"
clearable
@keyup.enter.native="handleQuery"
/>-->
</el-form-item>
<el-form-item label="选择日期区间" prop="monthStartTime">
<el-date-picker
v-model="valuetime"
type="daterange"
align="right"
@change="monthStartEndTimechange"
unlink-panels
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
:picker-options="pickerOptions"
></el-date-picker>
</el-form-item>
<el-form-item label="选择月份" prop="monthTime">
<el-date-picker
v-model="queryParams.monthTime"
type="month"
placeholder="选择月份"
@change="monthtimechange"
></el-date-picker>
</el-form-item>
<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>
<!-- <el-row :gutter="10" class="mb8">
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>-->
<el-table v-loading="loading" :data="revenueList" @selection-change="handleSelectionChange">
<el-table-column label="护理站名称" align="center" prop="nurseStationName" />
<el-table-column label="护理人员名称" align="center" prop="nursePersonName" />
<el-table-column label="总订单" align="center" prop="orderCount" />
<el-table-column label="总收益" align="center" prop="orderTotalPrice" />
<el-table-column label="本月订单" align="center" prop="monthOrderCount" />
<el-table-column label="本月订单收益" align="center" prop="monthOrderTotalPrice" />
<el-table-column label="今日订单" align="center" prop="todayOrderCount" />
<el-table-column label="今日订单收益" align="center" prop="todayOrderPrice" />
<!-- <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['system:revenue:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['system:revenue:remove']"
>删除</el-button>
</template>
</el-table-column>-->
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改护理员订单佣金收益信息对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="护理站人员表id" prop="nurseStationPersonId">
<el-input v-model="form.nurseStationPersonId" placeholder="请输入护理站人员表id" />
</el-form-item>
<el-form-item label="预约订单表id" prop="appointmentOrderId">
<el-input v-model="form.appointmentOrderId" placeholder="请输入预约订单表id" />
</el-form-item>
<el-form-item label="收益金额" prop="revenueAmount">
<el-input v-model="form.revenueAmount" placeholder="请输入收益金额" />
</el-form-item>
<el-form-item label="预约订单完成时间" prop="finishOrderTime">
<el-date-picker
clearable
v-model="form.finishOrderTime"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择预约订单完成时间"
></el-date-picker>
</el-form-item>
</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>
<!-- // -->
<el-dialog
title="选择护理站"
:visible.sync="nursePersonshow"
width="1000px"
append-to-body
:before-close="nursePersoncancel"
>
<el-form ref="queryForm" :model="nursePersonqueryParams" :inline="true">
<el-form-item label="护理人员名称" prop="nursePersonName" label-width="120">
<el-input
v-model="nursePersonqueryParams.nursePersonName"
placeholder="请输入护理人员名称"
clearable
/>
</el-form-item>
<!-- <el-form-item label="护理人员编号" prop="nursePersonCode" label-width="120">
<el-input
v-model="nursePersonqueryParams.nursePersonCode"
placeholder="请输入护理人员编号"
clearable
/>
</el-form-item>-->
<el-form-item>
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="nursePersonhandleQuery"
>搜索</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="nursePersonreset">重置</el-button>
</el-form-item>
</el-form>
<el-table :data="nursePersonlist" @cell-dblclick="nursePersonclick">
<el-table-column label="请选择" width="100" align="center">
<template slot-scope="scope">
<el-button
type="primary"
style="width: 15px; height: 15px"
v-if="nursePersonid == scope.row.id"
circle
@click="nursePersonclick(scope.row)"
></el-button>
<el-button
v-else
style="width: 15px; height: 15px"
circle
@click="nursePersonclick(scope.row)"
></el-button>
</template>
</el-table-column>
<el-table-column property="nurseStationName" label="所属护理站" align="center"></el-table-column>
<el-table-column property="nursePersonCode" label="护理人员编号" align="center"></el-table-column>
<el-table-column property="nursePersonName" label="护理人员名称" align="center"></el-table-column>
<el-table-column property="phone" label="联系电话" align="center"></el-table-column>
<el-table-column property="address" label="护理站地址" align="center"></el-table-column>
</el-table>
<pagination
v-show="nursePersontotal > 0"
:total="nursePersontotal"
:page.sync="nursePersonqueryParams.pageNum"
:limit.sync="nursePersonqueryParams.pageSize"
@pagination="nursePersoninfo"
/>
</el-dialog>
</div>
</template>
<script>
import {
listRevenue,
getRevenue,
delRevenue,
addRevenue,
updateRevenue
} from "@/api/system/revenue.js";
import { getListByUser } from "@/api/system/userlist.js";
import { listPerson } from "@/api/system/person";
export default {
name: "Revenue",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
revenueList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
nurseStationPersonId: null,
appointmentOrderId: null,
revenueAmount: null,
finishOrderTime: null,
monthTime: null,
monthStartTime: null, //
monthEndTime: null //
},
//
nurseStationqueryParams: {
pageNum: 1,
pageSize: 10
},
//
nursePersonqueryParams: {
pageNum: 1,
pageSize: 10
},
//
form: {},
//
rules: {},
//
nursePersonshow: false,
//list
nurseStationlist: [],
//
nursePersonshow: false,
//list
nursePersonlist: [],
nursePersontotal: 0,
nursePersonid: null,
pickerOptions: {
shortcuts: [
{
text: "最近一周",
onClick(picker) {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
picker.$emit("pick", [start, end]);
}
},
{
text: "最近一个月",
onClick(picker) {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
picker.$emit("pick", [start, end]);
}
},
{
text: "最近三个月",
onClick(picker) {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
picker.$emit("pick", [start, end]);
}
}
]
},
valuetime: ""
};
},
created() {
this.nurseStationinfo();
this.nursePersoninfo();
},
methods: {
//
monthStartEndTimechange(e) {
if (!this.queryParams.monthTime) {
this.queryParams.monthStartTime = this.formatDate(
new Date(e[0]).getTime()
);
this.queryParams.monthEndTime = this.formatDate(
new Date(e[1]).getTime()
);
} else {
this.queryParams.monthStartTime = null;
this.queryParams.monthEndTime = null;
this.valuetime = "";
}
},
//
monthtimechange(e) {
if (!this.queryParams.monthStartTime) {
this.queryParams.monthTime = this.formatDate(new Date(e).getTime());
} else {
this.queryParams.monthTime = "";
}
},
formatDate(time, timetype) {
let date = new Date(time); //13
//let date = new Date(parseInt(time) * 1000); //10
let y = date.getFullYear();
let MM = date.getMonth() + 1;
MM = MM < 10 ? "0" + MM : MM;
let d = date.getDate();
d = d < 10 ? "0" + d : d;
return y + "-" + MM + "-" + d;
},
/** 查询护理员订单佣金收益信息列表 */
getList() {
this.loading = true;
listRevenue(this.queryParams).then(response => {
this.revenueList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: null,
nurseStationPersonId: null,
appointmentOrderId: null,
revenueAmount: null,
finishOrderTime: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.queryParams.pageNum = 1;
this.queryParams.pageSize = 10;
this.queryParams.nursePersonName = null;
this.queryParams.nurseStationPersonId = null;
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id);
this.single = selection.length !== 1;
this.multiple = !selection.length;
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加护理员订单佣金收益信息";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id || this.ids;
getRevenue(id).then(response => {
this.form = response.data;
this.open = true;
this.title = "修改护理员订单佣金收益信息";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
if (this.form.id != null) {
updateRevenue(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
});
} else {
addRevenue(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal
.confirm(
'是否确认删除护理员订单佣金收益信息编号为"' + ids + '"的数据项?'
)
.then(function() {
return delRevenue(ids);
})
.then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
})
.catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
this.download(
"system/revenue/export",
{
...this.queryParams
},
`revenue_${new Date().getTime()}.xlsx`
);
},
//
nurseStationinfo() {
getListByUser(this.nurseStationqueryParams).then(res => {
this.nurseStationlist = res.rows;
this.nurseStationtotal = res.total;
this.queryParams.nurseStationId = res.rows[0].id;
this.queryParams.nurseStationName = res.rows[0].nurseStationName;
this.getList();
});
},
/** 护理人员重置按钮操作 */
nursePersoncancel() {
this.nursePersonshow = false;
this.nursePersonreset();
},
//
nursePersonreset() {
this.nursePersonqueryParams = {
pageNum: 1,
pageSize: 10
};
this.nursePersoninfo();
},
//
nursePersoninfo() {
listPerson(this.nursePersonqueryParams).then(res => {
res.rows.forEach(e => {
if (e.modifyCheckStatus == "CHECKED") {
e.modifyCheckStatus = true;
} else {
e.modifyCheckStatus = false;
}
});
this.nursePersonlist = res.rows;
this.nursePersontotal = res.total;
});
},
//
nursePersonhandleQuery() {
this.nursePersonqueryParams.pageNum = 1;
this.nursePersoninfo();
},
//click
nursePersonclick(row) {
this.nursePersonid = row.id;
this.queryParams.nursePersonName = row.nursePersonName;
this.queryParams.nurseStationPersonId = row.id;
this.nursePersonshow = false;
},
//form
nursePersonNameclick() {
this.nursePersonid = this.queryParams.nurseStationPersonId;
this.nursePersonshow = true;
}
}
};
</script>
<style scoped>
.stationbtn {
width: 208px;
text-align: left;
height: 32px;
overflow: hidden;
font-size: 14px;
}
</style>

View File

@ -804,8 +804,6 @@ export default {
this.form.stationIntroducePcitureUrl = imgUrl; this.form.stationIntroducePcitureUrl = imgUrl;
}, },
delnurseStationLabelList(index, item) { delnurseStationLabelList(index, item) {
console.log(index, item);
console.log();
// this.looknurseStationLabel.splice(index,1) // this.looknurseStationLabel.splice(index,1)
if (this.looknurseStationLabel.length === 1) { if (this.looknurseStationLabel.length === 1) {
this.looknurseStationLabel = [{ this.looknurseStationLabel = [{
@ -833,7 +831,6 @@ export default {
// //
clickstreet(item) { clickstreet(item) {
this.form.areaCode = item.areaCode; this.form.areaCode = item.areaCode;
console.log(item, this.form);
}, },
// //
clickarea(item) { clickarea(item) {
@ -1056,7 +1053,6 @@ export default {
this.looknurseStationLabel = response.data.nurseStationLabel; this.looknurseStationLabel = response.data.nurseStationLabel;
this.open = true; this.open = true;
this.loading = false; this.loading = false;
console.log(this.form);
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */

View File

@ -1,19 +1,13 @@
<template> <template>
<div> <div>
<div <div class="user-info-head" :class="video.VideoPath ? 'wihi' : ''" @click="editCropper()">
class="user-info-head"
:class="video.VideoPath ? 'wihi' : ''"
@click="editCropper()"
>
<video <video
style="width: 208px; height: 208px" style="width: 208px; height: 208px"
v-if="video.VideoPath" v-if="video.VideoPath"
v-bind:src="video.VideoPath" v-bind:src="video.VideoPath"
class="avatar video-avatar" class="avatar video-avatar"
controls="controls" controls="controls"
> >您的浏览器不支持视频播放</video>
您的浏览器不支持视频播放
</video>
<img <img
v-if="options.img" v-if="options.img"
v-bind:src="options.img" v-bind:src="options.img"
@ -62,19 +56,14 @@
v-bind:src="videoForm.showVideoPath" v-bind:src="videoForm.showVideoPath"
class="avatar video-avatar" class="avatar video-avatar"
controls="controls" controls="controls"
> >您的浏览器不支持视频播放</video>
您的浏览器不支持视频播放 <img style="width: 100%; height: 100%" v-if="previews.url" :src="previews.url" />
</video>
<img
style="width: 100%; height: 100%"
v-if="previews.url"
:src="previews.url"
/>
<div v-else></div> <div v-else></div>
</div> </div>
<div class="title" v-if="types != 'posterVideoUrl'&&types!='posterPictureUrl'"> <div
请上传图片为800x800px的正方形 class="title"
</div> v-if="types != 'posterVideoUrl'&&types!='posterPictureUrl'"
>请上传图片为800x800px的正方形</div>
</el-col> </el-col>
</el-row> </el-row>
<br /> <br />
@ -121,9 +110,7 @@
></el-button> ></el-button>
</el-col>--> </el-col>-->
<el-col :lg="{ span: 2, offset: 20 }" :md="2"> <el-col :lg="{ span: 2, offset: 20 }" :md="2">
<el-button type="primary" size="small" @click="uploadImg()" <el-button type="primary" size="small" @click="uploadImg()"> </el-button>
> </el-button
>
</el-col> </el-col>
</el-row> </el-row>
</el-dialog> </el-dialog>
@ -136,7 +123,7 @@ import baseurl from "@/api/baseurl.js";
import { import {
updateNurseStationHeads, updateNurseStationHeads,
posts, posts,
updatePoserHeads, updatePoserHeads
} from "@/api/system/stationAvatar.js"; } from "@/api/system/stationAvatar.js";
export default { export default {
@ -158,17 +145,17 @@ export default {
autoCrop: true, // autoCrop: true, //
autoCropWidth: 300, // autoCropWidth: 300, //
autoCropHeight: 300, // autoCropHeight: 300, //
fixedBox: true, // fixedBox: true //
}, },
previews: {}, previews: {},
items: {}, items: {},
// //
videoForm: { videoForm: {
showVideoPath: null, // showVideoPath: null //
}, },
video: { video: {
VideoPath: null, // VideoPath: null //
}, }
}; };
}, },
created() { created() {
@ -181,7 +168,6 @@ export default {
} else { } else {
this.video.VideoPath = baseurl + this.tovideo; this.video.VideoPath = baseurl + this.tovideo;
} }
console.log(this.video);
if (this.img == null) { if (this.img == null) {
this.options.img = null; this.options.img = null;
} else if (this.img == "") { } else if (this.img == "") {
@ -197,12 +183,12 @@ export default {
}, },
watch: { watch: {
tovideo: { tovideo: {
handler(newimg, oldimg) {}, handler(newimg, oldimg) {}
}, },
item: { item: {
handler(newimg, oldimg) { handler(newimg, oldimg) {
this.items = this.item; this.items = this.item;
}, }
}, },
img: { img: {
handler(newimg, oldimg) { handler(newimg, oldimg) {
@ -213,13 +199,13 @@ export default {
} else { } else {
this.options.img = baseurl + this.img; this.options.img = baseurl + this.img;
} }
}, }
}, },
type: { type: {
handler(newimg, oldimg) { handler(newimg, oldimg) {
this.types = this.type; this.types = this.type;
}, }
}, }
}, },
methods: { methods: {
// //
@ -279,13 +265,13 @@ export default {
formData.append("file", this.previews.data); formData.append("file", this.previews.data);
formData.append("type", this.types); formData.append("type", this.types);
if (this.types == "posterVideoUrl") { if (this.types == "posterVideoUrl") {
updatePoserHeads(formData).then((response) => { updatePoserHeads(formData).then(response => {
this.video.VideoPath = baseurl + response.imgUrl; this.video.VideoPath = baseurl + response.imgUrl;
this.$emit("imgUrl", response.imgUrl); this.$emit("imgUrl", response.imgUrl);
this.openimg = false; this.openimg = false;
}); });
} else { } else {
updateNurseStationHeads(formData).then((response) => { updateNurseStationHeads(formData).then(response => {
this.options.img = baseurl + response.imgUrl; this.options.img = baseurl + response.imgUrl;
this.$emit("imgUrl", response.imgUrl); this.$emit("imgUrl", response.imgUrl);
if (this.types == "attributePitureUrl") { if (this.types == "attributePitureUrl") {
@ -304,6 +290,14 @@ export default {
this.items.posterPictureUrl = response.imgUrl; this.items.posterPictureUrl = response.imgUrl;
this.$emit("item", JSON.stringify(this.items)); this.$emit("item", JSON.stringify(this.items));
} }
if (this.types == "certificateUrl") {
this.items.certificateUrl = response.imgUrl;
this.$emit("item", JSON.stringify(this.items));
}
if (this.types == "personCertificateUrl") {
this.items.certificateUrl = response.imgUrl;
this.$emit("item", JSON.stringify(this.items));
}
this.openimg = false; this.openimg = false;
}); });
} }
@ -319,8 +313,8 @@ export default {
closeDialog() { closeDialog() {
this.imgs = ""; this.imgs = "";
this.visible = false; this.visible = false;
}, }
}, }
}; };
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">

View File

@ -496,7 +496,6 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm() { submitForm() {
console.log(this.form);
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.form.id != null) { if (this.form.id != null) {

View File

@ -290,9 +290,14 @@
<el-table <el-table
ref="nurseStationItemPrices" ref="nurseStationItemPrices"
:data="form.nurseStationItemPrices" :data="form.nurseStationItemPrices"
style="margin-top: 20px; width: 900px" style="margin-top: 20px; width: 1050px"
>
<el-table-column
property="serveDurationUnit"
label="服务时长和单位"
align="center"
width="120"
> >
<el-table-column property="serveDurationUnit" label="服务时长和单位" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-input v-model="scope.row.serveDurationUnit" maxlength="6"></el-input> <el-input v-model="scope.row.serveDurationUnit" maxlength="6"></el-input>
</template> </template>
@ -313,15 +318,39 @@
<el-input v-model="scope.row.description" maxlength="300"></el-input> <el-input v-model="scope.row.description" maxlength="300"></el-input>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" align="center"> <el-table-column property="description" label="佣金金额" align="center">
<template slot-scope="scope">
<el-input
v-model="scope.row.commissionAmount"
placeholder="最多小数点后两位(元)"
@focus="commissionAmountinput(scope.row)"
type="number"
min="0"
oninput="if (value.indexOf('.') > 0) { value = value.slice(0, value.indexOf('.') + 3)} if (value.length > 8) { value = value.slice(0,8) }"
></el-input>
</template>
</el-table-column>
<el-table-column property="description" label="佣金比例(%)" align="center">
<template slot-scope="scope">
<el-input
v-model="scope.row.commissionRate"
@focus="commissionRateoninput(scope.row)"
placeholder="最多小数点后两位(%)"
type="number"
min="0"
oninput="if (value.indexOf('.') > 0) { value = value.slice(0, value.indexOf('.') + 3)} if (value.length > 5) { value = value.slice(0,5) }"
></el-input>
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button size="mini" type="text" @click="addnurseStationItemPrices">新增</el-button> <el-button size="mini" type="text" @click="addnurseStationItemPrices">新增</el-button>
<el-button size="mini" type="text" @click="delnurseStationItemPrices(scope.row)">删除</el-button> <el-button size="mini" type="text" @click="delnurseStationItemPrices(scope.row)">删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div style="float:right;font-weight:600">:佣金金额 = 佣金比例 x 价格</div>
</el-form-item> </el-form-item>
<el-form-item label="护理项目耗材"> <el-form-item label="护理项目耗材">
<el-button type="primary" size="small" plain @click="listStationConsumableinfo">添加护理项目耗材</el-button> <el-button type="primary" size="small" plain @click="listStationConsumableinfo">添加护理项目耗材</el-button>
<el-table <el-table
@ -774,6 +803,12 @@ export default {
this.classifylistInfo(); this.classifylistInfo();
}, },
methods: { methods: {
commissionAmountinput(e) {
e.commissionRate = "";
},
commissionRateoninput(e) {
e.commissionAmount = "";
},
// //
upwhetherShelf(row) { upwhetherShelf(row) {
let shelfStatus = null; let shelfStatus = null;
@ -999,7 +1034,9 @@ export default {
serveDurationUnit: "", serveDurationUnit: "",
price: "", price: "",
description: "", description: "",
idd: this.idd idd: this.idd,
commissionAmount: "",
commissionRate: ""
}; };
this.form.nurseStationItemPrices.push(obj); this.form.nurseStationItemPrices.push(obj);
} }
@ -1050,7 +1087,9 @@ export default {
serveDurationUnit: null, serveDurationUnit: null,
price: null, price: null,
description: null, description: null,
idd: this.idd idd: this.idd,
commissionAmount: "",
commissionRate: ""
} }
] ]
}; };
@ -1106,7 +1145,9 @@ export default {
serveDurationUnit: "", serveDurationUnit: "",
price: "", price: "",
description: "", description: "",
idd: this.idd idd: this.idd,
commissionAmount: "",
commissionRate: ""
}; };
this.form.nurseStationItemPrices.push(obj); this.form.nurseStationItemPrices.push(obj);
} }
@ -1119,10 +1160,26 @@ export default {
if (!this.form.nurseStationItem.appointmentLimitCount) { if (!this.form.nurseStationItem.appointmentLimitCount) {
this.form.nurseStationItem.appointmentLimitCount = null; this.form.nurseStationItem.appointmentLimitCount = null;
} }
if (this.form.nurseStationItemConsumables.length > 0) {
this.form.nurseStationItemConsumables.forEach(e => { this.form.nurseStationItemConsumables.forEach(e => {
e.nurseStationConsumableId = e.id; e.nurseStationConsumableId = e.id;
e.consumableCount = Number(e.consumableCount); e.consumableCount = Number(e.consumableCount);
}); });
}
if (this.form.nurseStationItemPrices.length > 0) {
this.form.nurseStationItemPrices.forEach(e => {
if (!e.commissionAmount || e.commissionAmount == "") {
e.commissionAmount = null;
} else {
e.commissionAmount = Number(e.commissionAmount);
}
if (!e.commissionRate || e.commissionRate == "") {
e.commissionRate = null;
} else {
e.commissionRate = Number(e.commissionRate);
}
});
}
this.form.nurseStationItem.nurseTypeId = this.form.nurseTypeId; this.form.nurseStationItem.nurseTypeId = this.form.nurseTypeId;
this.$refs["form"].validate(valid => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {

View File

@ -81,16 +81,8 @@
></el-date-picker> ></el-date-picker>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
type="primary" <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
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-item>
</el-form> </el-form>
@ -103,8 +95,7 @@
size="mini" size="mini"
@click="handleAdd" @click="handleAdd"
v-hasPermi="['system:user:add']" v-hasPermi="['system:user:add']"
>新增</el-button >新增</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -115,8 +106,7 @@
:disabled="single" :disabled="single"
@click="handleUpdate" @click="handleUpdate"
v-hasPermi="['system:user:edit']" v-hasPermi="['system:user:edit']"
>修改</el-button >修改</el-button>
>
</el-col> </el-col>
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
@ -127,8 +117,7 @@
:disabled="multiple" :disabled="multiple"
@click="handleDelete" @click="handleDelete"
v-hasPermi="['system:user:remove']" v-hasPermi="['system:user:remove']"
>删除</el-button >删除</el-button>
>
</el-col> </el-col>
<!-- <el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
@ -150,18 +139,10 @@
v-hasPermi="['system:user:export']" v-hasPermi="['system:user:export']"
>导出</el-button> >导出</el-button>
</el-col>--> </el-col>-->
<right-toolbar <right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar>
:showSearch.sync="showSearch"
@queryTable="getList"
:columns="columns"
></right-toolbar>
</el-row> </el-row>
<el-table <el-table v-loading="loading" :data="userList" @selection-change="handleSelectionChange">
v-loading="loading"
:data="userList"
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="50" align="center" /> <el-table-column type="selection" width="50" align="center" />
<el-table-column <el-table-column
label="用户编号" label="用户编号"
@ -195,12 +176,7 @@
v-if="columns[4].visible" v-if="columns[4].visible"
width="120" width="120"
/> />
<el-table-column <el-table-column label="状态" align="center" key="status" v-if="columns[5].visible">
label="状态"
align="center"
key="status"
v-if="columns[5].visible"
>
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch <el-switch
v-model="scope.row.status" v-model="scope.row.status"
@ -234,16 +210,14 @@
icon="el-icon-edit" icon="el-icon-edit"
@click="handleUpdate(scope.row)" @click="handleUpdate(scope.row)"
v-hasPermi="['system:user:edit']" v-hasPermi="['system:user:edit']"
>修改</el-button >修改</el-button>
>
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-delete"
@click="handleDelete(scope.row)" @click="handleDelete(scope.row)"
v-hasPermi="['system:user:remove']" v-hasPermi="['system:user:remove']"
>删除</el-button >删除</el-button>
>
<el-dropdown <el-dropdown
size="mini" size="mini"
@command="(command) => handleCommand(command, scope.row)" @command="(command) => handleCommand(command, scope.row)"
@ -257,14 +231,12 @@
command="handleResetPwd" command="handleResetPwd"
icon="el-icon-key" icon="el-icon-key"
v-hasPermi="['system:user:resetPwd']" v-hasPermi="['system:user:resetPwd']"
>重置密码</el-dropdown-item >重置密码</el-dropdown-item>
>
<el-dropdown-item <el-dropdown-item
command="handleAuthRole" command="handleAuthRole"
icon="el-icon-circle-check" icon="el-icon-circle-check"
v-hasPermi="['system:user:edit']" v-hasPermi="['system:user:edit']"
>分配角色</el-dropdown-item >分配角色</el-dropdown-item>
>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>
</template> </template>
@ -287,11 +259,7 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="用户昵称" prop="nickName"> <el-form-item label="用户昵称" prop="nickName">
<el-input <el-input v-model="form.nickName" placeholder="请输入用户昵称" maxlength="30" />
v-model="form.nickName"
placeholder="请输入用户昵称"
maxlength="30"
/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
@ -315,43 +283,23 @@
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="手机号码" prop="phonenumber"> <el-form-item label="手机号码" prop="phonenumber">
<el-input <el-input v-model="form.phonenumber" placeholder="请输入手机号码" maxlength="11" />
v-model="form.phonenumber"
placeholder="请输入手机号码"
maxlength="11"
/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="邮箱" prop="email"> <el-form-item label="邮箱" prop="email">
<el-input <el-input v-model="form.email" placeholder="请输入邮箱" maxlength="50" />
v-model="form.email"
placeholder="请输入邮箱"
maxlength="50"
/>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item <el-form-item v-if="form.userId == undefined" label="用户名称" prop="userName">
v-if="form.userId == undefined" <el-input v-model="form.userName" placeholder="请输入用户名称" maxlength="30" />
label="用户名称"
prop="userName"
>
<el-input
v-model="form.userName"
placeholder="请输入用户名称"
maxlength="30"
/>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item <el-form-item v-if="form.userId == undefined" label="用户密码" prop="password">
v-if="form.userId == undefined"
label="用户密码"
prop="password"
>
<el-input <el-input
v-model="form.password" v-model="form.password"
placeholder="请输入用户密码" placeholder="请输入用户密码"
@ -366,18 +314,13 @@
<el-col :span="12"> <el-col :span="12">
<!-- multiple --> <!-- multiple -->
<el-form-item label="护理站" prop="nurseStationIds"> <el-form-item label="护理站" prop="nurseStationIds">
<el-select <el-select v-model="form.nurseStationIds" placeholder="请选择护理站" v-loadmore="loadMore">
v-model="form.nurseStationIds"
placeholder="请选择护理站"
v-loadmore="loadMore"
>
<el-option <el-option
v-for="item in nurseStationlist" v-for="item in nurseStationlist"
:key="item.id" :key="item.id"
:label="item.nurseStationName" :label="item.nurseStationName"
:value="item.id" :value="item.id"
> ></el-option>
</el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
@ -388,8 +331,7 @@
v-for="dict in dict.type.sys_normal_disable" v-for="dict in dict.type.sys_normal_disable"
:key="dict.value" :key="dict.value"
:label="dict.value" :label="dict.value"
>{{ dict.label }}</el-radio >{{ dict.label }}</el-radio>
>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-col> </el-col>
@ -410,11 +352,7 @@
</el-col>--> </el-col>-->
<el-col :span="12"> <el-col :span="12">
<el-form-item label="角色"> <el-form-item label="角色">
<el-select <el-select v-model="form.roleIds" multiple placeholder="请选择角色">
v-model="form.roleIds"
multiple
placeholder="请选择角色"
>
<el-option <el-option
v-for="item in roleOptions" v-for="item in roleOptions"
:key="item.roleId" :key="item.roleId"
@ -429,11 +367,7 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item label="备注"> <el-form-item label="备注">
<el-input <el-input v-model="form.remark" type="textarea" placeholder="请输入内容"></el-input>
v-model="form.remark"
type="textarea"
placeholder="请输入内容"
></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
@ -445,12 +379,7 @@
</el-dialog> </el-dialog>
<!-- 用户导入对话框 --> <!-- 用户导入对话框 -->
<el-dialog <el-dialog :title="upload.title" :visible.sync="upload.open" width="400px" append-to-body>
:title="upload.title"
:visible.sync="upload.open"
width="400px"
append-to-body
>
<el-upload <el-upload
ref="upload" ref="upload"
:limit="1" :limit="1"
@ -464,11 +393,13 @@
drag drag
> >
<i class="el-icon-upload"></i> <i class="el-icon-upload"></i>
<div class="el-upload__text">将文件拖到此处<em>点击上传</em></div> <div class="el-upload__text">
将文件拖到此处
<em>点击上传</em>
</div>
<div class="el-upload__tip text-center" slot="tip"> <div class="el-upload__tip text-center" slot="tip">
<div class="el-upload__tip" slot="tip"> <div class="el-upload__tip" slot="tip">
<el-checkbox v-model="upload.updateSupport" /> <el-checkbox v-model="upload.updateSupport" />是否更新已经存在的用户数据
是否更新已经存在的用户数据
</div> </div>
<span>仅允许导入xlsxlsx格式文件</span> <span>仅允许导入xlsxlsx格式文件</span>
<el-link <el-link
@ -476,8 +407,7 @@
:underline="false" :underline="false"
style="font-size: 12px; vertical-align: baseline" style="font-size: 12px; vertical-align: baseline"
@click="importTemplate" @click="importTemplate"
>下载模板</el-link >下载模板</el-link>
>
</div> </div>
</el-upload> </el-upload>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
@ -496,7 +426,7 @@ import {
addUser, addUser,
updateUser, updateUser,
resetUserPwd, resetUserPwd,
changeUserStatus, changeUserStatus
} from "@/api/system/user"; } from "@/api/system/user";
import { getToken } from "@/utils/auth"; import { getToken } from "@/utils/auth";
import { treeselect } from "@/api/system/dept"; import { treeselect } from "@/api/system/dept";
@ -545,7 +475,7 @@ export default {
form: {}, form: {},
defaultProps: { defaultProps: {
children: "children", children: "children",
label: "label", label: "label"
}, },
// //
upload: { upload: {
@ -560,7 +490,7 @@ export default {
// //
headers: { Authorization: "Bearer " + getToken() }, headers: { Authorization: "Bearer " + getToken() },
// //
url: process.env.VUE_APP_BASE_API + "/system/user/importData", url: process.env.VUE_APP_BASE_API + "/system/user/importData"
}, },
// //
queryParams: { queryParams: {
@ -569,7 +499,7 @@ export default {
userName: undefined, userName: undefined,
phonenumber: undefined, phonenumber: undefined,
status: undefined, status: undefined,
deptId: undefined, deptId: undefined
}, },
// //
nurseStationqueryParams: { nurseStationqueryParams: {
@ -589,7 +519,7 @@ export default {
dutyPerson: null, dutyPerson: null,
dutyPhone: null, dutyPhone: null,
stationPictureUrl: null, stationPictureUrl: null,
sort: null, sort: null
}, },
// //
columns: [ columns: [
@ -599,7 +529,7 @@ export default {
{ key: 3, label: `部门`, visible: true }, { key: 3, label: `部门`, visible: true },
{ key: 4, label: `手机号码`, visible: true }, { key: 4, label: `手机号码`, visible: true },
{ key: 5, label: `状态`, visible: true }, { key: 5, label: `状态`, visible: true },
{ key: 6, label: `创建时间`, visible: true }, { key: 6, label: `创建时间`, visible: true }
], ],
// //
rules: { rules: {
@ -609,14 +539,14 @@ export default {
min: 2, min: 2,
max: 20, max: 20,
message: "用户名称长度必须介于 2 和 20 之间", message: "用户名称长度必须介于 2 和 20 之间",
trigger: "blur", trigger: "blur"
}, }
], ],
// nurseStationIds: [ // nurseStationIds: [
// { required: true, message: "", trigger: "blur" }, // { required: true, message: "", trigger: "blur" },
// ], // ],
nickName: [ nickName: [
{ required: true, message: "用户昵称不能为空", trigger: "blur" }, { required: true, message: "用户昵称不能为空", trigger: "blur" }
], ],
password: [ password: [
{ required: true, message: "用户密码不能为空", trigger: "blur" }, { required: true, message: "用户密码不能为空", trigger: "blur" },
@ -624,59 +554,56 @@ export default {
min: 5, min: 5,
max: 20, max: 20,
message: "用户密码长度必须介于 5 和 20 之间", message: "用户密码长度必须介于 5 和 20 之间",
trigger: "blur", trigger: "blur"
}, }
], ],
email: [ email: [
{ {
type: "email", type: "email",
message: "请输入正确的邮箱地址", message: "请输入正确的邮箱地址",
trigger: ["blur", "change"], trigger: ["blur", "change"]
}, }
], ],
phonenumber: [ phonenumber: [
{ {
pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/, pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/,
message: "请输入正确的手机号码", message: "请输入正确的手机号码",
trigger: "blur", trigger: "blur"
}, }
], ]
}, }
}; };
}, },
watch: { watch: {
// //
deptName(val) { deptName(val) {
this.$refs.tree.filter(val); this.$refs.tree.filter(val);
}, }
}, },
created() { created() {
this.getList(); this.getList();
this.getTreeselect(); this.getTreeselect();
this.listinfo(); this.listinfo();
this.getConfigKey("sys.user.initPassword").then((response) => { this.getConfigKey("sys.user.initPassword").then(response => {
this.initPassword = response.msg; this.initPassword = response.msg;
}); });
}, },
methods: { methods: {
listinfo() { listinfo() {
list(this.nurseStationqueryParams).then((res) => { list(this.nurseStationqueryParams).then(res => {
console.log(res);
this.nurseStationlist = res.rows; this.nurseStationlist = res.rows;
this.total2 = res.total; this.total2 = res.total;
}); });
}, },
loadMore() { loadMore() {
var a = Math.ceil(this.total2 / 10); var a = Math.ceil(this.total2 / 10);
console.log(this.nurseStationlist.length);
if (this.nurseStationlist.length + 1 >= this.total2) { if (this.nurseStationlist.length + 1 >= this.total2) {
} else { } else {
if (this.nurseStationqueryParams.pageNum >= a) { if (this.nurseStationqueryParams.pageNum >= a) {
} else { } else {
this.nurseStationqueryParams.pageNum++; this.nurseStationqueryParams.pageNum++;
list(this.nurseStationqueryParams).then((res) => { list(this.nurseStationqueryParams).then(res => {
console.log(res); res.rows.forEach(e => {
res.rows.forEach((e) => {
this.nurseStationlist.push(e); this.nurseStationlist.push(e);
}); });
}); });
@ -687,7 +614,7 @@ export default {
getList() { getList() {
this.loading = true; this.loading = true;
listUser(this.addDateRange(this.queryParams, this.dateRange)).then( listUser(this.addDateRange(this.queryParams, this.dateRange)).then(
(response) => { response => {
this.userList = response.rows; this.userList = response.rows;
this.total = response.total; this.total = response.total;
this.loading = false; this.loading = false;
@ -696,7 +623,7 @@ export default {
}, },
/** 查询部门下拉树结构 */ /** 查询部门下拉树结构 */
getTreeselect() { getTreeselect() {
treeselect().then((response) => { treeselect().then(response => {
this.deptOptions = response.data; this.deptOptions = response.data;
}); });
}, },
@ -744,7 +671,7 @@ export default {
status: "0", status: "0",
remark: undefined, remark: undefined,
postIds: [], postIds: [],
roleIds: [], roleIds: []
}; };
this.resetForm("form"); this.resetForm("form");
}, },
@ -761,7 +688,7 @@ export default {
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
this.ids = selection.map((item) => item.userId); this.ids = selection.map(item => item.userId);
this.single = selection.length != 1; this.single = selection.length != 1;
this.multiple = !selection.length; this.multiple = !selection.length;
}, },
@ -782,7 +709,7 @@ export default {
handleAdd() { handleAdd() {
this.reset(); this.reset();
this.getTreeselect(); this.getTreeselect();
getUser().then((response) => { getUser().then(response => {
this.postOptions = response.posts; this.postOptions = response.posts;
this.roleOptions = response.roles; this.roleOptions = response.roles;
this.open = true; this.open = true;
@ -795,13 +722,12 @@ export default {
this.reset(); this.reset();
this.getTreeselect(); this.getTreeselect();
const userId = row.userId || this.ids; const userId = row.userId || this.ids;
getUser(userId).then((response) => { getUser(userId).then(response => {
this.form = response.data; this.form = response.data;
if (!this.form.nurseStationIds) { if (!this.form.nurseStationIds) {
this.form.nurseStationIds = '' this.form.nurseStationIds = "";
} else { } else {
this.form.nurseStationIds = Number(this.form.nurseStationIds); this.form.nurseStationIds = Number(this.form.nurseStationIds);
} }
// if ( // if (
// !this.form.nurseStationIds || // !this.form.nurseStationIds ||
@ -814,8 +740,6 @@ export default {
// return (e = Number(e)); // return (e = Number(e));
// }); // });
// } // }
console.log(this.form);
this.postOptions = response.posts; this.postOptions = response.posts;
this.roleOptions = response.roles; this.roleOptions = response.roles;
this.form.postIds = response.postIds; this.form.postIds = response.postIds;
@ -827,16 +751,15 @@ export default {
}, },
/** 重置密码按钮操作 */ /** 重置密码按钮操作 */
handleResetPwd(row) { handleResetPwd(row) {
this.$prompt('请输入"' + row.userName + '"的新密码', "提示", { this.$prompt('请输入"' + row.userName + '"的新密码', "提示", {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
closeOnClickModal: false, closeOnClickModal: false,
inputPattern: /^.{5,20}$/, inputPattern: /^.{5,20}$/,
inputErrorMessage: "用户密码长度必须介于 5 和 20 之间", inputErrorMessage: "用户密码长度必须介于 5 和 20 之间"
}) })
.then(({ value }) => { .then(({ value }) => {
resetUserPwd(row.userId, value).then((response) => { resetUserPwd(row.userId, value).then(response => {
this.$modal.msgSuccess("修改成功,新密码是:" + value); this.$modal.msgSuccess("修改成功,新密码是:" + value);
}); });
}) })
@ -849,36 +772,31 @@ export default {
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm: function() { submitForm: function() {
this.$refs["form"].validate((valid) => { this.$refs["form"].validate(valid => {
if (valid) { if (valid) {
// this.form.nurseStationIds = this.form.nurseStationIds.join(","); // this.form.nurseStationIds = this.form.nurseStationIds.join(",");
// this.form.nurseStationIds = JSON.stringify(this.form.nurseStationIds); // this.form.nurseStationIds = JSON.stringify(this.form.nurseStationIds);
// var obj = []; // var obj = [];
// obj.push(this.form.nurseStationIds); // obj.push(this.form.nurseStationIds);
// console.log(obj)
// this.form.nurseStationIds = obj; // this.form.nurseStationIds = obj;
if (this.form.userId != undefined) { if (this.form.userId != undefined) {
if (!this.form.nurseStationIds) { if (!this.form.nurseStationIds) {
this.form.nurseStationIds = null this.form.nurseStationIds = null;
updateUser(this.form).then((response) => { updateUser(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open = false; this.open = false;
this.getList(); this.getList();
// console.log('bbb',this.form)
}); });
} else { } else {
this.form.nurseStationIds = Number(this.form.nurseStationIds); this.form.nurseStationIds = Number(this.form.nurseStationIds);
updateUser(this.form).then((response) => { updateUser(this.form).then(response => {
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open = false; this.open = false;
this.getList(); this.getList();
// console.log('bbb',this.form)
}); });
} }
} else { } else {
addUser(this.form).then((response) => { addUser(this.form).then(response => {
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
this.getList(); this.getList();
@ -906,7 +824,7 @@ export default {
this.download( this.download(
"system/user/export", "system/user/export",
{ {
...this.queryParams, ...this.queryParams
}, },
`user_${new Date().getTime()}.xlsx` `user_${new Date().getTime()}.xlsx`
); );
@ -945,7 +863,7 @@ export default {
// //
submitFileForm() { submitFileForm() {
this.$refs.upload.submit(); this.$refs.upload.submit();
}, }
}, }
}; };
</script> </script>

View File

@ -12,15 +12,13 @@ export default {
}, },
methods: { methods: {
info() { info() {
getListByUser().then((res) => { getListByUser().then(res => {
console.log(res);
if (res.rows[0].isAdmin == "1") { if (res.rows[0].isAdmin == "1") {
console.log(true);
} else { } else {
this.$emit("itemlist", res.rows); this.$emit("itemlist", res.rows);
} }
}); });
}, }
}, }
}; };
</script> </script>