From ad7c86c760b2a9495787f7187a8142f8121ec1d9 Mon Sep 17 00:00:00 2001 From: Tcsm <1377977403@qq.com> Date: 星期三, 03 五月 2023 10:23:21 +0800 Subject: [PATCH] 1.通讯录详情中的0,1转为具体文字 2.家庭小医生显示查看详情按钮 3.成长经历阅历修改样式等 --- ruoyi-ui/src/views/collection/index.vue | 78 +++++++++++++++++++++++++++++++++----- 1 files changed, 67 insertions(+), 11 deletions(-) diff --git a/ruoyi-ui/src/views/collection/index.vue b/ruoyi-ui/src/views/collection/index.vue index 4a1c8c7..9040293 100644 --- a/ruoyi-ui/src/views/collection/index.vue +++ b/ruoyi-ui/src/views/collection/index.vue @@ -151,12 +151,37 @@ v-hasPermi="['family:note:export']" >瀵煎嚭</el-button> </el-col> + <el-col :span="1.5"> + <el-button + type="warning" + plain + icon="el-icon-download" + size="mini" + @click="handleExport" + v-hasPermi="['family:note:export']" + >瀵煎叆妯℃澘涓嬭浇</el-button> + </el-col> + <el-col :span="1.2"> + + <el-upload + action="" + + class="upload-demo" + :show-file-list="false" + :http-request="handleEnport" + > + <el-button size="mini" type="primary" + plain + icon="el-icon-plus" >瀵煎叆</el-button> + + </el-upload> + </el-col> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> </el-row> </div> <el-table v-loading="loading" :data="collectionList" @selection-change="handleSelectionChange" @row-click="handleCheck" :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="搴忓彿" prop="id" sortable width="80" />--> + <el-table-column label="搴忓彿" sortable type="index" :index="(queryParams.pageNum-1)*queryParams.pageSize+1" width="60"/> <el-table-column label="鑾峰緱鏃堕棿" prop="happenTime" sortable width="100" align="center"> <template slot-scope="scope">{{scope.row.happenTime? scope.row.happenTime: '鈥斺�斺�斺��'}}</template> </el-table-column> @@ -178,10 +203,24 @@ <el-table-column label="瀛樻斁浣嶇疆" prop="location" sortable width="130" align="center"> <template slot-scope="scope">{{scope.row.location? scope.row.location: '鈥斺�斺�斺��'}}</template> </el-table-column> - <el-table-column label="鐢靛瓙鏂囦欢" prop="url" align="center" sortable width="110" > - <template slot-scope="scope"> - <span v-if= "scope.row.url == ','" ><img src="../../assets/images/鏂囦欢澶�-0.png" /></span> - <span v-else><img src="../../assets/images/鏂囦欢澶�-1.png" /></span> + <el-table-column label="鐢靛瓙鏂囦欢" prop="url" width="80" > + <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 === ','" + > </template> </el-table-column> @@ -208,12 +247,12 @@ size="mini" @command="(command) => handleCommand(command, scope.row)" v-hasPermi="['system:role:edit']"> -<!-- <el-button--> -<!-- size="mini"--> -<!-- type="text"--> -<!-- icon="el-icon-d-arrow-right"--> -<!-- @click="handleCheck(scope.row)"--> -<!-- >鏌ョ湅璇︽儏</el-button>--> + <el-button + size="mini" + type="text" + icon="el-icon-d-arrow-right" + @click="handleCheck(scope.row)" + >鏌ョ湅璇︽儏</el-button> </el-dropdown> </template> @@ -225,6 +264,7 @@ :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" + style="background: #FEF7FC;" @pagination="getList" /> @@ -344,6 +384,8 @@ //瀵煎叆鎺ュ彛鍑芥暟 import {listCollection, getCollection, addCollection,updateCollection, delCollection,uploadPic} from "@/api/collection/index"; +import {enload} from "@/api/doctor"; +import {Message} from "element-ui"; export default { @@ -674,6 +716,20 @@ this.download('zfCollection/export', { ...this.queryParams }, `zfCollection_${new Date().getTime()}.xlsx`) + }, + /** 瀵煎叆鎿嶄綔*/ + handleEnport(params){ + var file = params.file; + var formData = new FormData(); + formData.append('excelImport', file); + let _this = this + + enload(formData).then(response => { + _this.getList(); + Message({ message: "瀵煎叆鎴愬姛", type: 'warning' }) + + }).catch(() => { Message({ message: "瀵煎叆澶辫触", type: 'error' })}); + } } }; -- Gitblit v1.9.1