From 2eb0cfea5b267d45163b5ba632ca6160912e9cf5 Mon Sep 17 00:00:00 2001
From: linwenling <3256558519@qq.com>
Date: 星期二, 01 八月 2023 21:21:48 +0800
Subject: [PATCH] 旅游修改
---
ruoyi-ui/src/views/doctor/index.vue | 173 +++++++++++++++++++++++++++++++++++++++------------------
1 files changed, 119 insertions(+), 54 deletions(-)
diff --git a/ruoyi-ui/src/views/doctor/index.vue b/ruoyi-ui/src/views/doctor/index.vue
index 42e32df..5ca2704 100644
--- a/ruoyi-ui/src/views/doctor/index.vue
+++ b/ruoyi-ui/src/views/doctor/index.vue
@@ -51,16 +51,21 @@
-->
</el-form-item>
- <el-form-item label="绫诲瀷" prop="type" >
- <el-input
+ <el-form-item label="绫诲埆" prop="type">
+ <el-select
v-model="queryParams.type"
- placeholder="璇疯緭鍏ョ被鍨�"
+ placeholder="鎵�鏈夌被鍒�"
clearable
style="width: 240px"
- @keyup.enter.native="handleQuery">
- <i slot="prefix" class="el-input__icon el-icon-search"></i>
- </el-input>
-
+ @keyup.enter.native="handleQuery"
+ >
+ <el-option
+ v-for="item in typeOptions"
+ :key="item.value"
+ :label="item.label"
+ :value="item.value"
+ />
+ </el-select>
</el-form-item>
<el-form-item label="鐥囩姸" prop="symptom">
@@ -115,14 +120,14 @@
</el-form-item>
</el-form>
<div>
- <div style="width: 100px;
- height: 24px;
- font-size: 18px;
- font-family: Microsoft YaHei-Regular, Microsoft YaHei;
- font-weight: 400;
- color: #000000;
- line-height: 21px;
- ">瀹跺涵灏忓尰鐢�</div>
+<!-- <div style="width: 100px;-->
+<!-- height: 24px;-->
+<!-- font-size: 18px;-->
+<!-- font-family: Microsoft YaHei-Regular, Microsoft YaHei;-->
+<!-- font-weight: 400;-->
+<!-- color: #000000;-->
+<!-- line-height: 21px;-->
+<!-- ">瀹跺涵灏忓尰鐢�</div>-->
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
@@ -163,7 +168,7 @@
plain
icon="el-icon-download"
size="mini"
- @click="handleExport"
+ @click="handleExportTemplate"
v-hasPermi="['family:note:export']"
>瀵煎叆妯℃澘涓嬭浇</el-button>
</el-col>
@@ -185,11 +190,13 @@
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
</div>
- <el-table v-loading="loading" :data="doctorList" @selection-change="handleSelectionChange" :row-class-name="tableRowClassName" style="background: #FFEFF2; border-radius: 14px 14px 14px 14px;">
- <el-table-column type="selection" width="25" align="center" />
- <el-table-column label="搴忓彿" sortable type="index" align="center" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="60"/>
- <el-table-column label="绫诲瀷" prop="type" sortable width="120" align="center">
- <template slot-scope="scope">{{scope.row.type? scope.row.type: '鈥斺�斺�斺��'}}</template>
+
+ <el-table v-loading="loading" :data="doctorList" :row-key="getRowId" ref="multipleTable" @selection-change="handleSelectionChange" :row-class-name="tableRowClassName" style="background: #FFEFF2; border-radius: 14px 14px 14px 14px;">
+ <el-table-column type="selection" :reserve-selection="true" width="25" align="center" />
+ <el-table-column fixed label="搴忓彿" sortable type="index" align="center" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="60"/>
+ <el-table-column label="绫诲瀷" prop="type" sortable width="80" align="center">
+ <template slot-scope="scope">{{ getSrc(scope.row.type) }}</template>
+<!-- <template slot-scope="scope">{{scope.row.type? scope.row.type: '鈥斺�斺�斺��'}}</template>-->
</el-table-column>
<el-table-column label="鐥囩姸" prop="symptom" sortable :show-overflow-tooltip="true" width="120" align="center" >
<template slot-scope="scope">{{scope.row.symptom? scope.row.symptom: '鈥斺�斺�斺��'}}</template>
@@ -216,22 +223,24 @@
</el-table-column>
<el-table-column label="鐢靛瓙鏂囦欢" prop="url" width="160" align="center">
<template slot-scope="scope" >
- <img
- class="el-upload-list__item-thumbnail"
- src="../../assets/images/deviceLis.png"
- alt=""
- style="width: 35px; height: 35px;"
- fit="cover"
- v-if="scope.row.url !== ','"
- >
- <img
- class="el-upload-list__item-thumbnail"
- src="../../assets/images/deviceA.png"
- alt=""
- style="width: 35px; height: 35px;"
- fit="cover"
- v-if="scope.row.url ===',' "
- >
+ <div @click="handleCheck(scope.row)">
+ <img
+ class="el-upload-list__item-thumbnail"
+ src="../../assets/images/deviceLis.png"
+ alt=""
+ style="width: 35px; height: 35px;"
+ fit="cover"
+ v-if="!(scope.row.url === '' || scope.row.url === ',' || scope.row.url === null)"
+ >
+ <img
+ v-else
+ class="el-upload-list__item-thumbnail"
+ src="../../assets/images/deviceA.png"
+ alt=""
+ style="width: 35px; height: 35px;"
+ fit="cover"
+
+ ></div>
</template>
</el-table-column>
@@ -277,8 +286,10 @@
<el-form ref="elForm" :model="formDat" :rules="rules" size="medium" label-width="100px">
<el-form-item label="绫诲瀷" prop="type">
- <el-input v-model="formDat.type" placeholder="璇疯緭鍏ョ被鍨�" clearable :style="{width: '100%'}" >
- </el-input>
+ <el-select v-model="formDat.type" placeholder="璇烽�夋嫨绫诲埆" clearable :style="{width: '100%'}" >
+ <el-option v-for="(item, index) in typeOptions" :key="index" :label="item.label" :value="item.value"
+ ></el-option>
+ </el-select>
</el-form-item>
<el-form-item label="鐥囩姸" prop="symptom">
@@ -354,7 +365,7 @@
class="upload-demo"
multiple
- :on-remove="handleRemove"
+ :on-remove="handleRemoveFile"
:http-request="requestUpload"
:show-file-list="true"
>
@@ -519,12 +530,21 @@
trigger: 'blur'
}],
},
- typeOptions: [],
+ typeOptions: [{
+ value:'绁炵粡绉�',
+ label:'绁炵粡绉�'
+ },{
+ value:'鐗欑',
+ label:'鐗欑'
+ },{
+ value:'鍐呯',
+ label:'鍐呯'
+ }],
};
},
created() {
this.getList();
- // this.getCateInfor()
+ this.getCateInfor()
// for (let i = 0; i < this.contactList.length; i++) {
// this.formDat[i] = this.contactList[i];
// }
@@ -560,24 +580,50 @@
);
},
/** 鏌ヨ绫诲埆淇℃伅 */
- // getCateInfor()
- // {
- // let _this = this
- // getCategory().then(response=>{
- //
- // response.data.itemValues.replace("{","").replace("}","").split(",").map(elem=>{
- // _this.typeOptions.push({"label":elem.split(":")[0], "value":elem.split(":")[0]})
- // })
- // })
- // },
+ getCateInfor()
+ {
+ let _this = this
+ getCategory().then(response=>{
+ response.data.itemValues.replace("{","").replace("}","").split(",").map(elem=>{
+ _this.typeOptions.push({"label":elem.split(":")[0], "value":elem.split(":")[0]})
+ })
+ })
+ },
+//绫诲埆閫夋嫨
+ getSrc(type) {
+ if (type === '绁炵粡绉�'){
+ return '绁炵粡绉�'
+ }else if(type === '鐗欑'){
+ return '鐗欑'
+ }else if(type === '鍐呯'){
+ return '鍐呯'
+ }else {
+ return '鍏跺畠'
+ }
+ },
handleRemove(file) {
- alert(323)
+ for(let i = 0; i < this.fileList.length; i++)
+ {
+ if(this.fileList[i].url==file.url)
+ this.$delete(this.fileList,i);
+ }
+ },
+ handleRemoveFile(file) {
+ for(let i = 0; i < this.fileListOther.length; i++)
+ {
+ if(this.fileListOther[i].url==file.url)
+ this.$delete(this.fileListOther,i);
+ }
},
// 鍙栨秷鎸夐挳
cancel() {
this.open = false;
this.reset();
+ },
+ getRowId(row)
+ {
+ return row.id
},
// 鍙栨秷鎸夐挳锛堟暟鎹潈闄愶級
cancelDataScope() {
@@ -683,6 +729,10 @@
});
}
});
+ // 娓呯┖formDat瀵硅薄鐨勬暟鎹�
+ Object.keys(this.formDat).forEach(key => {
+ this.formDat[key] = '';
+ });
},
requestUpload(params)
{
@@ -719,9 +769,24 @@
},
/** 瀵煎嚭鎸夐挳鎿嶄綔 */
handleExport() {
- this.download('zfDoctor/export', {
+ const Ids = this.ids;
+
+ if(Ids.length==0)
+ {
+ this.download('/zfDoctor/export', {
...this.queryParams
}, `zfDoctor_${new Date().getTime()}.xlsx`)
+ }else{
+ this.download('/zfDoctor/export1/'+Ids, {
+
+ }, `zfDoctor_${new Date().getTime()}.xlsx`)
+ }
+ },
+
+ handleExportTemplate(){
+ this.download('/zfDoctor/model', {
+
+ }, `zfDoctor_${new Date().getTime()}.xlsx`)
},
/** 瀵煎叆鎿嶄綔*/
handleEnport(params){
--
Gitblit v1.9.1