<template>
|
<div class="finance-del">
|
<div class="nav">
|
<span>居家隔离统计</span>
|
<el-button type="primary" size="medium" @click="$router.go(-1)">返回</el-button>
|
</div>
|
<el-form :inline="true" class="demo-form-inline">
|
<el-form-item>
|
<div class="block">
|
<span class="demonstration">关键词:</span>
|
<el-input style="width: 250px" v-model="keyword" placeholder="请输入关键词"></el-input>
|
<span class="demonstration">登记日期:</span>
|
<el-date-picker
|
v-model="time"
|
@change="changeTime"
|
type="daterange"
|
format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
range-separator="至"
|
:clearable="false"
|
start-placeholder="开始日期"
|
end-placeholder="结束日期"
|
></el-date-picker>
|
<!-- <span class="demonstration">来攀/离攀开始时间:</span>
|
<el-date-picker
|
format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
v-model="beginTime"
|
type="date"
|
:clearable="false"
|
placeholder="选择来攀/离攀开始时间"
|
>
|
</el-date-picker>
|
<span class="demonstration">来攀/离攀结束时间:</span>
|
<el-date-picker
|
format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
v-model="stopTime"
|
type="date"
|
:clearable="false"
|
placeholder="选择来攀/离攀结束时间"
|
>
|
</el-date-picker>-->
|
<button class="m_btn bgc_primary min-width" @click.prevent="searchHandle">搜 索</button>
|
<button class="m_btn bgc_primary min-width" @click.prevent="Reset">重 置</button>
|
</div>
|
</el-form-item>
|
|
<!-- <button class="m_btn bgc_primary" v-loading.fullscreen.lock="fullscreenLoading" @click="exports()">导出</button> -->
|
<div>
|
<el-button type="primary" @click="exports()">导出</el-button>
|
</div>
|
</el-form>
|
|
<!-- <div
|
class="Tips"
|
v-show="Change"
|
>
|
<i
|
style="color: #409EFF"
|
class="el-icon-info"
|
></i>
|
<div class="Tips-cont">已选择<span>{{ids.length}}</span>项</div>
|
<el-button
|
type="text"
|
@click="cancel"
|
>取消</el-button>
|
</div>-->
|
<div v-if="sentimentData.length">
|
<div class="tab">
|
<el-table :data="sentimentData" style="width: 100%">
|
<el-table-column
|
v-for="(item, index) in areaName"
|
:key="index"
|
:prop="item.id"
|
:label="item.content"
|
align="center"
|
:show-overflow-tooltip="true"
|
>
|
<template slot="header" v-if="item.content != ''">
|
<div>
|
<el-tooltip :content="item.content" placement="top">
|
<div class="long_title">
|
<span ref="rFollowUpEntityList">{{ item.content }}</span>
|
</div>
|
</el-tooltip>
|
</div>
|
</template>
|
|
<template slot-scope="scope">
|
<div v-if="item.type == 11" class="image-list">
|
<span class="img-cover">
|
<img :src="scope.row[item.id]" @click="onScaleImage(scope.row[item.id])" />
|
</span>
|
<a :href="scope.row[item.id]" target="_blank" download="image">下载图片</a>
|
</div>
|
<div v-if="item.type == 12" class="image-list">
|
<span class="img-cover">
|
<img :src="scope.row[item.id]" @click="onScaleImage(scope.row[item.id])" />
|
</span>
|
<a :href="scope.row[item.id]" target="_blank" download="image">下载图片</a>
|
</div>
|
<span v-else>{{ scope.row[item.id] }}</span>
|
</template>
|
</el-table-column>
|
|
<el-table-column prop="name" label="隔离体温情况" :show-overflow-tooltip="true">
|
<template slot-scope="scope">
|
<div v-html="scope.row.isolation"></div>
|
</template>
|
</el-table-column>
|
<!-- <el-table-column fixed="right" prop="name" label="操作" width="100">
|
<template slot-scope="scope">
|
<span class="look" @click="see(scope.row)">查看</span>
|
</template>
|
</el-table-column>-->
|
</el-table>
|
</div>
|
<v-tool-page :item="paged" @on-page="onPage"></v-tool-page>
|
</div>
|
<div class="nodata" v-else>不好意思,暂无数据!</div>
|
</div>
|
</template>
|
<script>
|
export default {
|
props: [],
|
components: {},
|
data() {
|
return {
|
paged: { page: 0, total: 0, r: 0, limit: 10 },
|
totalNum: "",
|
Change: true,
|
ids: [], //选中的id集合
|
alls: false, //全选状态
|
areaName: [],
|
sentimentData: [],
|
time: [],
|
startTime: "",
|
endTime: "",
|
keyUrl: [],
|
url: [],
|
beginTime: "",
|
stopTime: "",
|
keyword: "",
|
};
|
},
|
|
mounted() {
|
this.tableHeade();
|
this.tebleContent();
|
},
|
|
methods: {
|
onScaleImage(i) {
|
this.$store.dispatch("setImage", {
|
time: Date.now(),
|
title: "[大图]",
|
foot: 1,
|
tool: 1,
|
pic: i,
|
});
|
},
|
toSisPage() {
|
this.$router.pish('/quarantine')
|
},
|
see(row) {
|
this.$router.push("/act_registerviewDetails/" + row.id);
|
},
|
searchHandle() {
|
this.paged.page = 1;
|
this.tebleContent();
|
},
|
Reset() {
|
this.time = "";
|
this.startTime = "";
|
this.endTime = "";
|
this.stopTime = "";
|
this.beginTime = "";
|
this.keyword = "";
|
this.tebleContent();
|
},
|
|
// 分页点击
|
onPage(v) {
|
if (v.page === this.paged.page && v.page && !v.reset) {
|
return 0;
|
}
|
this.paged.page = v.page;
|
this.paged.limit = v.limit;
|
// this.init();
|
this.tableHeade();
|
this.tebleContent();
|
},
|
|
init() {
|
let params = {
|
advertType: 0,
|
endTime: this.endTime,
|
ids: [],
|
keyword: this.keyword,
|
pageNum: this.paged.page,
|
pageSize: this.paged.limit,
|
reserveId: +this.$route.query.id,
|
startTime: this.startTime,
|
status: 0,
|
type: [1],
|
beginTime: this.beginTime,
|
stopTime: this.stopTime,
|
};
|
this.$api.post("reserve/make/page", params, (e) => {
|
this.paged.total = e.total;
|
this.paged.r++;
|
this.tds = (e.records || []).map((v) => {
|
this.$set(v, "che", false);
|
return v;
|
});
|
});
|
},
|
|
tableHeade() {
|
let params = {
|
reserveId: +this.$route.query.id,
|
};
|
this.$api.get("reserve/subject/list", params, (e) => {
|
this.areaName = [];
|
e.forEach(item => {
|
if (item.content != '今日上午体温(℃)' && item.content != '今日下午体温(℃)' && item.content != '今日隔离情况简述' && item.content != '用户昵称' && item.content != '登记流水') {
|
this.areaName.push(item)
|
}
|
})
|
e.forEach((d) => {
|
if (d.type == 11) {
|
this.keyUrl.push(d.id);
|
}
|
});
|
console.log(this.keyUrl)
|
});
|
},
|
|
release() {
|
let params = {
|
id: +this.$route.query.id,
|
type: 1,
|
};
|
this.$api.post("reserve/edit/status", params, (e) => {
|
demo.toast("取消预约成功");
|
});
|
},
|
|
tebleContent() {
|
let params = {
|
advertType: 0,
|
endTime: this.endTime,
|
ids: [],
|
keyword: this.keyword,
|
pageNum: this.paged.page,
|
pageSize: this.paged.limit,
|
reserveId: +this.$route.query.id,
|
startTime: this.startTime,
|
status: 0,
|
type: [2],
|
beginTime: this.beginTime,
|
stopTime: this.stopTime,
|
};
|
this.$api.post("reserve/register/homeQuarantine/page", params, (e) => {
|
console.log(e)
|
// this.sentimentData = e.records;
|
this.paged.total = e.total;
|
this.paged.r++;
|
this.sentimentData = (e.records || []).map((v) => {
|
this.$set(v, "che", false);
|
return v;
|
});
|
});
|
},
|
|
changeTime() {
|
this.startTime = this.time[0];
|
this.endTime = this.time[1];
|
// this.init();
|
this.tableHeade();
|
this.tebleContent();
|
},
|
//导出
|
exports(v) {
|
this.$api.post(
|
"reserve/register/list/export/homeQuarantine",
|
{
|
reserveId: +this.$route.query.id,
|
beginTime: this.beginTime,
|
stopTime: this.stopTime,
|
keyword: this.keyword,
|
startTime: this.startTime,
|
endTime: this.endTime,
|
type: [2]
|
},
|
(e) => {
|
window.location.href = e;
|
}
|
);
|
},
|
|
cheAll() {
|
// this.Change = !this.Change
|
//全选
|
this.tds.map((item) => {
|
item.che = this.alls;
|
});
|
this.change();
|
},
|
|
change() {
|
//单个选择
|
this.ids = [];
|
this.tds.map((item) => {
|
if (item.che) {
|
this.ids.push(item.id);
|
} else {
|
this.alls = false;
|
}
|
});
|
},
|
|
cancel() {
|
//取消
|
// this.Change = false;
|
this.alls = false;
|
this.tds.map((item) => {
|
item.che = false;
|
});
|
},
|
},
|
watch: {},
|
};
|
</script>
|
<style scoped lang="less">
|
.finance-del {
|
overflow: scroll;
|
}
|
.long_title {
|
width: 100px;
|
overflow: hidden;
|
text-overflow: ellipsis;
|
white-space: nowrap;
|
}
|
.nodata {
|
width: 100%;
|
height: 150px;
|
line-height: 150px;
|
color: #888;
|
font-size: 16px;
|
text-align: center;
|
}
|
.nav {
|
padding: 20px 0;
|
span {
|
font-size: 18px;
|
height: 40px;
|
line-height: 40px;
|
font-weight: 700;
|
margin-right: 30px;
|
}
|
}
|
.add {
|
text-align: right;
|
}
|
.look {
|
color: #229ffd;
|
cursor: pointer;
|
}
|
.image-list {
|
text-align: center;
|
width: 75px;
|
font-size: 13px;
|
a {
|
color: #229ffd;
|
cursor: pointer;
|
}
|
}
|
.Tips {
|
margin: 10px 0;
|
box-sizing: border-box;
|
width: 100%;
|
display: flex;
|
align-items: center;
|
background: #e6f7ff;
|
border: #bae7ff 1px solid;
|
border-radius: 6px;
|
height: 40px;
|
padding: 0 20px;
|
}
|
.Tips-cont {
|
padding: 0 10px;
|
font-size: 16px;
|
color: #606266;
|
}
|
.Tips-cont > span {
|
padding: 0 4px;
|
color: #409eff;
|
font-weight: 600;
|
}
|
.bgc_primary {
|
margin-bottom: 15px;
|
}
|
.img-cover {
|
width: 75px;
|
height: 70px;
|
display: inline-block;
|
overflow: hidden;
|
img {
|
width: 100%;
|
height: 100%;
|
object-fit: cover;
|
max-height: none !important;
|
}
|
}
|
</style>
|