This commit is contained in:
2025-08-05 14:49:37 +08:00
parent a7c1cb61e1
commit bb2ffd967d
6 changed files with 2845 additions and 208 deletions

View File

@@ -84,6 +84,7 @@ const mainRoutes = {
{ path: '/mergeList', component: _import('modules/certificate/mergeList'), name: 'mergeList', meta: { title: '小班、自考证书', isTab: true } }, { path: '/mergeList', component: _import('modules/certificate/mergeList'), name: 'mergeList', meta: { title: '小班、自考证书', isTab: true } },
{ path: '/medicalrecords-medicalList', component: _import('modules/medicalrecords/medicalList'), name: 'medicalrecords-medicalList', meta: { title: '医案列表', isTab: true } }, { path: '/medicalrecords-medicalList', component: _import('modules/medicalrecords/medicalList'), name: 'medicalrecords-medicalList', meta: { title: '医案列表', isTab: true } },
{ path: '/medicalrecords-userList', component: _import('modules/medicalrecords/userList'), name: 'medicalrecords-userList', meta: { title: '审核人员列表', isTab: true } },
], ],
beforeEnter (to, from, next) { beforeEnter (to, from, next) {

View File

@@ -1,17 +1,31 @@
<template> <template>
<div class="tree_box"> <div class="tree_box">
<div style="overflow: hidden" v-if="source == 'tags'"> <div style="overflow: hidden" v-if="source == 'tags'&&!isborrow">
<p <p
class="info_bg" class="info_bg"
style="overflow: hidden; white-space: nowrap; text-overflow: ellipsis" style="overflow: hidden; white-space: nowrap; text-overflow: ellipsis"
> >
当前{{currentNode&&['wait','false','all','success'].includes(currentNode.data.id)?'状态':'标签' }}<span style="color: #17b3a3; font-weight: 600" 当前{{
:style="`${currentNode&&currentNode.data.color?`color: ${currentNode.data.color}`:''}`" currentNode &&
>{{ ["wait", "false", "all", "success"].includes(currentNode.data.id)
currentNode ? currentNode.data.title : "" ? "状态"
}}</span> : "标签"
}}<span
style="color: #17b3a3; font-weight: 600"
:style="
`${
currentNode && currentNode.data.color
? `color: ${currentNode.data.color}`
: ''
}`
"
>{{ currentNode ? currentNode.data.title : "" }}</span
>
</p> </p>
<el-button v-if="currentNode&&!['wait','false','all'].includes(currentNode.data.id)" <el-button
v-if="
currentNode && !['wait', 'false', 'all'].includes(currentNode.data.id)
"
type="primary" type="primary"
@click="addOrUpdateHandle()" @click="addOrUpdateHandle()"
style="float: right" style="float: right"
@@ -36,7 +50,7 @@
<!-- show-checkbox --> <!-- show-checkbox -->
<!-- :allow-drop="allowDrop" --> <!-- :allow-drop="allowDrop" -->
<div class="custom-tree-container"> <div class="custom-tree-container">
<el-tree <el-tree style="background-color: transparent;"
:draggable="false" :draggable="false"
:allow-drop="false" :allow-drop="false"
:highlight-current="true" :highlight-current="true"
@@ -47,7 +61,6 @@
default-expand-all default-expand-all
:filter-node-method="filterNode" :filter-node-method="filterNode"
ref="tree" ref="tree"
@node-click="handleNodeClick" @node-click="handleNodeClick"
:expand-on-click-node="false" :expand-on-click-node="false"
> >
@@ -59,7 +72,13 @@
:class=" :class="
`${currentNode && currentNode.data.id == data.id ? `isSelect` : ''}` `${currentNode && currentNode.data.id == data.id ? `isSelect` : ''}`
" "
:style="`${currentNode && currentNode.data.id == data.id&&data.bgcolor ? `background-image: linear-gradient(-45deg, #fff, ${data.bgcolor});` : ''}`" :style="
`${
currentNode && currentNode.data.id == data.id && data.bgcolor
? `background-image: linear-gradient(-45deg, #fff, ${data.bgcolor});`
: ''
}`
"
style=" padding-left: 5px; style=" padding-left: 5px;
box-sizing: border-box;" box-sizing: border-box;"
> >
@@ -68,10 +87,15 @@
><el-checkbox ><el-checkbox
@change="selectShop(data)" @change="selectShop(data)"
:value="selectArr.includes(data.id)" :value="selectArr.includes(data.id)"
v-if="data.isLast == 1 && source == 'shop'" v-if="data.isLast == 1 && source == 'shop'&&!isborrow"
style="margin-right: 10px" style="margin-right: 10px"
></el-checkbox ></el-checkbox
><span :style="`${data.color?`color:${data.color};font-weight:bold`:''}`">{{ node.label }}</span></span ><span
:style="
`${data.color ? `color:${data.color};font-weight:bold` : ''}`
"
>{{ node.label }}</span
></span
> >
<span v-if="source == 'tags'"> <span v-if="source == 'tags'">
<!-- v-if="node.level <= 1" --> <!-- v-if="node.level <= 1" -->
@@ -79,7 +103,9 @@
type="text" type="text"
size="mini" size="mini"
@click.stop="handleClickNodes(node, data, 'addChildren')" @click.stop="handleClickNodes(node, data, 'addChildren')"
v-if="data.isLast != 1&&!disableAddChild&&!data.isDisableAddChild" v-if="
data.isLast != 1 && !disableAddChild && !data.isDisableAddChild&&!isborrow
"
> >
添加下级 添加下级
</el-button> </el-button>
@@ -92,7 +118,8 @@
</el-button> --> </el-button> -->
<!-- v-if="node.childNodes.length == 0" --> <!-- v-if="node.childNodes.length == 0" -->
<el-button v-if="!data.disabled" <el-button
v-if="!data.disabled&&!isborrow"
type="text" type="text"
size="mini" size="mini"
@click.stop="remove(data)" @click.stop="remove(data)"
@@ -120,6 +147,8 @@ export default {
"axiosType", "axiosType",
"axiosResultKey", "axiosResultKey",
"disableAddChild", "disableAddChild",
"isborrow",
], ],
data() { data() {
return { return {
@@ -414,7 +443,7 @@ export default {
children: [], children: [],
delFlag: 0, delFlag: 0,
isLast: 0, isLast: 0,
icon:'', icon: "",
pid: data.id, pid: data.id,
sort: 0, sort: 0,
title: "" title: ""
@@ -441,7 +470,7 @@ export default {
children: [], children: [],
delFlag: 0, delFlag: 0,
isLast: 0, isLast: 0,
content:'', content: "",
pid: 0, pid: 0,
sort: 0, sort: 0,
title: "" title: ""
@@ -860,6 +889,7 @@ export default {
height: 100%; height: 100%;
float: left; float: left;
border: 1px solid #bababa; border: 1px solid #bababa;
background-color: #fff;
border-radius: 10px; border-radius: 10px;
padding: 15px; padding: 15px;
box-sizing: border-box; box-sizing: border-box;

View File

@@ -481,12 +481,12 @@
alt="" alt=""
/> />
<span class="el-upload-list__item-actions"> <span class="el-upload-list__item-actions">
<!-- <span <span
class="el-upload-list__item-preview" class="el-upload-list__item-preview"
@click="handlePictureCardPreview(file)" @click="handlePictureCardPreview(file)"
> >
<i class="el-icon-zoom-in"></i> <i class="el-icon-zoom-in"></i>
</span> --> </span>
<span <span
v-if="!disabled" v-if="!disabled"
@@ -630,6 +630,13 @@
> >
</span> </span>
</el-dialog> </el-dialog>
<el-dialog :visible.sync="dialogVisibleImg" :append-to-body="true">
<img
width="100%"
:src="dataForm.productImages"
alt=""
/>
</el-dialog>
</div> </div>
</template> </template>
@@ -677,6 +684,7 @@ export default {
props: ["data", "pageType", "dataInfo", "labelId", "currentNode"], props: ["data", "pageType", "dataInfo", "labelId", "currentNode"],
data() { data() {
return { return {
dataForm:{},
isShowWord: false, isShowWord: false,
imagePreviews: false, imagePreviews: false,
record: {}, record: {},
@@ -1610,7 +1618,8 @@ this.addCertificateForm.mark=''
// this.getCate(val) // this.getCate(val)
}, },
handlePictureCardPreview(file) { handlePictureCardPreview(file) {
// 图片预览逻辑 this.dataForm.productImages = file.url;
this.dialogVisibleImg = true;
}, },
handleClose(done) { handleClose(done) {
done(); done();
@@ -1646,17 +1655,17 @@ this.addCertificateForm.mark=''
margin-bottom: 10px !important; margin-bottom: 10px !important;
} }
/deep/.custom-upload { /deep/.custom-upload {
min-height: 60px !important; min-height: 120px !important;
} }
/deep/.custom-upload .el-upload--picture-card { /deep/.custom-upload .el-upload--picture-card {
width: 60px !important; width:80px !important;
height: 60px !important; height:80px !important;
line-height: 70px !important; line-height:80px !important;
} }
/deep/.custom-upload .el-upload-list--picture-card .el-upload-list__item { /deep/.custom-upload .el-upload-list--picture-card .el-upload-list__item {
width: 60px !important; width:80px !important;
height: 60px !important; height:80px !important;
line-height: 60px !important; line-height:80px !important;
} }
/deep/.custom-upload-box .el-form-item__label { /deep/.custom-upload-box .el-form-item__label {
line-height: 60px !important; line-height: 60px !important;

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -6,11 +6,7 @@
@keyup.enter.native="getDataList()" @keyup.enter.native="getDataList()"
> >
<el-form-item label="姓名"> <el-form-item label="姓名">
<el-input <el-input v-model="dataForm.name" placeholder="请输入姓名" clearable>
v-model="dataForm.name"
placeholder="请输入姓名"
clearable
>
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item label="所属地域"> <el-form-item label="所属地域">
@@ -29,11 +25,7 @@
" "
>查询</el-button >查询</el-button
> >
<el-button <el-button type="primary" @click="addHandle()">新增</el-button>
type="primary"
@click="addHandle()"
>新增</el-button
>
</el-form-item> </el-form-item>
</el-form> </el-form>
<el-table <el-table
@@ -42,18 +34,19 @@
v-loading="dataListLoading" v-loading="dataListLoading"
style="width: 100%" style="width: 100%"
> >
<el-table-column <el-table-column label="序号" type="index" align="center" width="60">
label="序号"
type="index"
align="center"
width="60">
</el-table-column> </el-table-column>
<el-table-column label="姓名" align="center" width="120"> <el-table-column label="姓名" align="center" width="120">
<template slot-scope="scope">{{ scope.row.name }}</template> <template slot-scope="scope">{{ scope.row.name }}</template>
</el-table-column> </el-table-column>
<el-table-column label="头像" align="center" width="120"> <el-table-column label="头像" align="center" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<img width="50px" :src="scope.row.icon" v-if="scope.row.icon" alt="" /> <img
width="50px"
:src="scope.row.icon"
v-if="scope.row.icon"
alt=""
/>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="职称" align="center" width="140"> <el-table-column label="职称" align="center" width="140">
@@ -87,21 +80,14 @@
query: { id: scope.row.id } query: { id: scope.row.id }
}" }"
> >
<el-button <el-button type="text" size="small">查看课程</el-button>
type="text"
size="small"
>查看课程</el-button>
</router-link> </router-link>
<el-button <el-button type="text" size="small" @click="editHandle(scope.row)"
type="text" >修改</el-button
size="small" >
@click="editHandle(scope.row)" <el-button type="text" size="small" @click="deleteHandle(scope.row)"
>修改</el-button> >删除</el-button
<el-button >
type="text"
size="small"
@click="deleteHandle(scope.row)"
>删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -141,9 +127,7 @@
<template #default="{ item }"> <template #default="{ item }">
<div class="custom-item"> <div class="custom-item">
<span>{{ item.tel ? item.tel : item.email }}</span> <span>{{ item.tel ? item.tel : item.email }}</span>
<span <span style="color: gray; margin-left: 10px;" v-if="item.name"
style="color: gray; margin-left: 10px;"
v-if="item.name"
>({{ item.name }})</span >({{ item.name }})</span
> >
</div> </div>
@@ -162,20 +146,41 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="科室" prop="department"> <el-form-item label="科室" prop="department">
<el-select v-model="addForm.department" placeholder="请选择"> <el-cascader
:options="departmentList"
:show-all-levels="false"
v-model="addForm.department"
placeholder="请选择"
:props="{
value: 'id',
label: 'title'
}"
></el-cascader>
<!-- <el-select v-model="addForm.department" placeholder="请选择">
<el-option <el-option
v-for="item in departmentList" v-for="item in departmentList"
:key="item.value" :key="item.id"
:label="item.label" :label="item.title"
:value="item.label"> :value="item.id"
>
</el-option> </el-option>
</el-select> </el-select> -->
</el-form-item> </el-form-item>
<el-form-item label="所属地域" prop="region" v-if="!changeStatus"> <el-form-item label="所属地域" prop="region" v-if="!changeStatus">
<div class="el-select"> <div class="el-select">
<el-input v-model="addForm.region" disabled class="el-input el-input--suffix"></el-input> <el-input
v-model="addForm.region"
disabled
class="el-input el-input--suffix"
></el-input>
</div> </div>
<el-button size="mini" type="default" class="editBtn" @click="changeCountry">修改</el-button> <el-button
size="mini"
type="default"
class="editBtn"
@click="changeCountry"
>修改</el-button
>
</el-form-item> </el-form-item>
<el-form-item label="所属地域" v-if="changeStatus"> <el-form-item label="所属地域" v-if="changeStatus">
@@ -226,17 +231,30 @@
</el-form-item> </el-form-item>
<el-form-item label="业务专长" prop="specialty"> <el-form-item label="业务专长" prop="specialty">
<el-input v-model="addForm.specialty" placeholder="请输入业务专长"></el-input> <el-input
v-model="addForm.specialty"
placeholder="请输入业务专长"
></el-input>
</el-form-item> </el-form-item>
<el-form-item label="预约信息" prop="reservation"> <el-form-item label="预约信息" prop="reservation">
<el-input v-model="addForm.reservation" placeholder="请输入预约信息"></el-input> <el-input
v-model="addForm.reservation"
placeholder="请输入预约信息"
></el-input>
</el-form-item> </el-form-item>
<el-form-item label="出诊信息" prop="clinic"> <el-form-item label="出诊信息" prop="clinic">
<el-input v-model="addForm.clinic" placeholder="请输入出诊信息"></el-input> <el-input
v-model="addForm.clinic"
placeholder="请输入出诊信息"
></el-input>
</el-form-item> </el-form-item>
<el-form-item label="介绍" prop="introduce"> <el-form-item label="介绍" prop="introduce">
<el-input type="textarea" v-model="addForm.introduce" placeholder="请输入介绍"></el-input> <el-input
type="textarea"
v-model="addForm.introduce"
placeholder="请输入介绍"
></el-input>
</el-form-item> </el-form-item>
<el-form-item label="上传头像" prop="icon"> <el-form-item label="上传头像" prop="icon">
<el-upload <el-upload
@@ -281,7 +299,7 @@ export default {
userId: "", userId: "",
id: "", //新增不传 id: "", //新增不传
name: "", name: "",
department: '', department: "",
title: "", title: "",
specialty: "", specialty: "",
region: "", region: "",
@@ -290,45 +308,20 @@ export default {
clinic: "", clinic: "",
icon: "" icon: ""
}, },
departmentList: [ departmentList: [],
{
value: '1',
label: '消化专科'
},
{
value: '2',
label: '呼吸专科'
},
{
value: '3',
label: '风湿免疫专科'
},
{
value: '4',
label: '肿瘤专科'
},
{
value: '5',
label: '妇科专科'
},
{
value: '6',
label: '全科医生'
}
],
editId: "", editId: "",
addFormRule: { addFormRule: {
tel: [ tel: [
{ {
required: true, required: true,
message: "请输入手机号/邮箱", message: "请输入手机号/邮箱"
}, }
], ],
name: [ name: [
{ {
required: true, required: true,
message: "请输入姓名", message: "请输入姓名"
}, }
] ]
}, },
dataList: [], dataList: [],
@@ -340,15 +333,15 @@ export default {
dialogVisible: false, dialogVisible: false,
dataListLoading: false, dataListLoading: false,
addOrUpdateVisible: false, addOrUpdateVisible: false,
titlesub: '', titlesub: "",
current: 1, current: 1,
limit: 10, limit: 10,
// 选择的值 // 选择的值
selectedCountry: '', selectedCountry: "",
selectedProvince: '', selectedProvince: "",
selectedCity: '', selectedCity: "",
// 加载状态 // 加载状态
countryLoading: false, countryLoading: false,
@@ -367,18 +360,37 @@ export default {
saveShop: "/master/taihuTalent/bindCourseAndTalent", saveShop: "/master/taihuTalent/bindCourseAndTalent",
hasBindProductList: "/master/taihuTalent/getCourseListForTalent", hasBindProductList: "/master/taihuTalent/getCourseListForTalent",
CanBindProductList: "/master/taihuTalent/getCourseListCanTalent" CanBindProductList: "/master/taihuTalent/getCourseListCanTalent"
}, }
}; };
}, },
components: { components: {},
},
activated() { activated() {
this.getDepartmentList();
this.getDataList(); this.getDataList();
this.loadCountries(); this.loadCountries();
}, },
mounted() {
this.getDepartmentList();
},
methods: { methods: {
// 获取数据列表 // 获取数据列表
getDepartmentList() {
// this.dataListLoading = true;
this.$http({
url: this.$http.adornUrl(
"/master/medicalRecords/getMedicalRecordsLabelList"
),
method: "post",
data: this.$http.adornData({})
}).then(({ data }) => {
if (data && data.code === 0) {
this.departmentList = data.Medicals;
} else {
this.departmentList = [];
}
});
},
getDataList() { getDataList() {
this.dataListLoading = true; this.dataListLoading = true;
this.$http({ this.$http({
@@ -389,7 +401,7 @@ export default {
limit: this.pageSize, limit: this.pageSize,
name: this.dataForm.name, name: this.dataForm.name,
region: this.dataForm.region region: this.dataForm.region
}), })
}).then(({ data }) => { }).then(({ data }) => {
if (data && data.code === 0) { if (data && data.code === 0) {
this.dataList = data.pageRes.records; this.dataList = data.pageRes.records;
@@ -428,32 +440,32 @@ export default {
//新增 //新增
addHandle() { addHandle() {
this.addOrUpdateVisible = true; this.addOrUpdateVisible = true;
this.titlesub = '新增'; this.titlesub = "新增";
this.statusType = 0; //新增 this.statusType = 0; //新增
this.changeStatus = true; this.changeStatus = true;
this.chinaStatus = false; this.chinaStatus = false;
this.selectCode = null; this.selectCode = null;
this.selectedProvId = null; this.selectedProvId = null;
this.selectedCity = ''; this.selectedCity = "";
this.selectCode = null; this.selectCode = null;
this.selectedProvId = null; this.selectedProvId = null;
this.selectedCity = ''; this.selectedCity = "";
this.fileList = []; this.fileList = [];
this.stopLoad = false; this.stopLoad = false;
this.addForm = { this.addForm = {
tel: '', tel: "",
name: "", name: "",
title: "", title: "",
department: '', department: "",
specialty: "", specialty: "",
region: "", region: "",
reservation: "", reservation: "",
introduce: "", introduce: "",
clinic: "", clinic: "",
icon: "" icon: ""
} };
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.addFormRef.clearValidate(); this.$refs.addFormRef.clearValidate();
}); });
@@ -468,30 +480,36 @@ export default {
type: "warning" type: "warning"
}); });
return return;
} }
} }
if(this.statusType==0){ //如果是新增 if (this.statusType == 0) {
//如果是新增
this.addCate(); this.addCate();
}else if(this.statusType==1){ //如果是修改 } else if (this.statusType == 1) {
//如果是修改
this.editCate(this.addForm); this.editCate(this.addForm);
} }
}, },
addCate() { addCate() {
console.log("this.addForm at line 490:", this.addForm);
this.$refs["addFormRef"].validate(valid => { this.$refs["addFormRef"].validate(valid => {
if (valid) { if (valid) {
var icon = ''; var icon = "";
var region = ''; var region = "";
if (this.fileList && this.fileList.length > 0) { if (this.fileList && this.fileList.length > 0) {
icon = this.fileList[0].url icon = this.fileList[0].url;
} }
if (this.selectedCountry) { if (this.selectedCountry) {
if (!this.selectedProvince) { if (!this.selectedProvince) {
region = this.selectedCountry region = this.selectedCountry;
} else { } else {
region = this.selectedProvince + this.selectedCity; region = this.selectedProvince + this.selectedCity;
} }
} }
const department = Array.isArray(this.addForm.department)
? this.addForm.department[this.addForm.department.length - 1]
: this.addForm.department;
this.$http({ this.$http({
url: this.$http.adornUrl("/master/taihuTalent/addTaihuTalent"), url: this.$http.adornUrl("/master/taihuTalent/addTaihuTalent"),
method: "post", method: "post",
@@ -499,14 +517,14 @@ export default {
userId: this.addForm.userId, userId: this.addForm.userId,
name: this.addForm.name, name: this.addForm.name,
title: this.addForm.title, title: this.addForm.title,
department: this.addForm.department, department: department,
specialty: this.addForm.specialty, specialty: this.addForm.specialty,
region: region, region: region,
reservation: this.addForm.reservation, reservation: this.addForm.reservation,
introduce: this.addForm.introduce, introduce: this.addForm.introduce,
clinic: this.addForm.clinic, clinic: this.addForm.clinic,
icon: icon icon: icon
}), })
}).then(({ data }) => { }).then(({ data }) => {
if (data && data.code === 0) { if (data && data.code === 0) {
this.$message({ this.$message({
@@ -519,25 +537,28 @@ export default {
} }
}); });
} }
}) });
}, },
editCate(data) { editCate(data) {
console.log('data at line 524:', data) console.log("data at line 524:", data);
this.$refs["addFormRef"].validate(valid => { this.$refs["addFormRef"].validate(valid => {
if (valid) { if (valid) {
var icon = ''; var icon = "";
var region = ''; var region = "";
if (this.fileList && this.fileList.length > 0) { if (this.fileList && this.fileList.length > 0) {
icon = this.fileList[0].url icon = this.fileList[0].url;
} }
if (this.selectedCountry) { if (this.selectedCountry) {
if (!this.selectedProvince) { if (!this.selectedProvince) {
region = this.selectedCountry region = this.selectedCountry;
} else { } else {
region = this.selectedProvince + this.selectedCity; region = this.selectedProvince + this.selectedCity;
} }
} }
const department = Array.isArray(data.department)
? data.department[data.department.length - 1]
: data.department;
this.$http({ this.$http({
url: this.$http.adornUrl("/master/taihuTalent/updateTaihuTalent"), url: this.$http.adornUrl("/master/taihuTalent/updateTaihuTalent"),
method: "post", method: "post",
@@ -545,14 +566,14 @@ export default {
id: data.id, id: data.id,
name: data.name, name: data.name,
title: data.title, title: data.title,
department: data.department, department: department,
specialty: data.specialty, specialty: data.specialty,
region: region ? region : data.region, region: region ? region : data.region,
reservation: data.reservation, reservation: data.reservation,
introduce: data.introduce, introduce: data.introduce,
clinic: data.clinic, clinic: data.clinic,
icon: icon icon: icon
}), })
}).then(({ data }) => { }).then(({ data }) => {
if (data && data.code === 0) { if (data && data.code === 0) {
this.$message({ this.$message({
@@ -565,7 +586,7 @@ export default {
} }
}); });
} }
}) });
}, },
//修改地域 //修改地域
changeCountry() { changeCountry() {
@@ -595,7 +616,7 @@ export default {
editHandle(data) { editHandle(data) {
this.fileList = []; this.fileList = [];
this.addOrUpdateVisible = true; this.addOrUpdateVisible = true;
this.titlesub = '修改'; this.titlesub = "修改";
this.statusType = 1; //修改 this.statusType = 1; //修改
this.changeStatus = false; this.changeStatus = false;
@@ -678,7 +699,7 @@ export default {
this.$http({ this.$http({
url: this.$http.adornUrl("/common/baseArea/getAllBaseArea"), url: this.$http.adornUrl("/common/baseArea/getAllBaseArea"),
method: "post", method: "post",
data: this.$http.adornData({}), data: this.$http.adornData({})
}).then(({ data }) => { }).then(({ data }) => {
if (data && data.code === 0) { if (data && data.code === 0) {
if (data.baseAreas && data.baseAreas.length > 0) { if (data.baseAreas && data.baseAreas.length > 0) {
@@ -695,7 +716,7 @@ export default {
this.$http({ this.$http({
url: this.$http.adornUrl("/common/province/getProvinceList"), url: this.$http.adornUrl("/common/province/getProvinceList"),
method: "post", method: "post",
data: this.$http.adornData({}), data: this.$http.adornData({})
}).then(({ data }) => { }).then(({ data }) => {
if (data && data.code === 0) { if (data && data.code === 0) {
if (data.provinceList && data.provinceList.length > 0) { if (data.provinceList && data.provinceList.length > 0) {
@@ -708,31 +729,33 @@ export default {
//选择国家 //选择国家
handleCountryChange(code) { handleCountryChange(code) {
if(code=='86'){ if (code == "86") {
this.chinaStatus = true; this.chinaStatus = true;
} else { } else {
this.chinaStatus = false; this.chinaStatus = false;
} }
const data = this.countries.find(country => country.code === code); const data = this.countries.find(country => country.code === code);
this.selectedCountry = data.title; this.selectedCountry = data.title;
this.selectedProvince = ''; this.selectedProvince = "";
this.selectedCity = ''; this.selectedCity = "";
this.selectedProvId = null; this.selectedProvId = null;
this.provinces = []; this.provinces = [];
this.cities = []; this.cities = [];
console.log('所选国家-', this.selectedCountry) console.log("所选国家-", this.selectedCountry);
}, },
//选择省份 //选择省份
handleProvinceChange(provId) { handleProvinceChange(provId) {
this.cityLoading = true; this.cityLoading = true;
const data = this.provinces.find(prov => prov.provId === provId); const data = this.provinces.find(prov => prov.provId === provId);
this.selectedProvince = data.provName; this.selectedProvince = data.provName;
this.selectedCity = ''; this.selectedCity = "";
this.$http({ this.$http({
url: this.$http.adornUrl("/common/province/getCityList?provId="+ provId), url: this.$http.adornUrl(
"/common/province/getCityList?provId=" + provId
),
method: "post", method: "post",
data: this.$http.adornData({}), data: this.$http.adornData({})
}).then(({ data }) => { }).then(({ data }) => {
if (data && data.code === 0) { if (data && data.code === 0) {
if (data.prov && data.prov.length > 0) { if (data.prov && data.prov.length > 0) {
@@ -742,15 +765,15 @@ export default {
} }
}); });
console.log('所选省份-', this.selectedProvince) console.log("所选省份-", this.selectedProvince);
}, },
//选择城市 //选择城市
handleCityChange(val) { handleCityChange(val) {
this.selectedCity = val; this.selectedCity = val;
console.log('所选城市-', this.selectedCity) console.log("所选城市-", this.selectedCity);
}, }
}, }
}; };
</script> </script>
@@ -824,8 +847,8 @@ export default {
.editBtn { .editBtn {
margin-left: 10px; margin-left: 10px;
width: 70px; width: 70px;
border-color: #17B3A3; border-color: #17b3a3;
color: #17B3A3; color: #17b3a3;
} }
.addFormBox { .addFormBox {