提交 9a1746cb 编写于 作者: zhentian.jia's avatar zhentian.jia

时间段导出查看

上级 3a13d02c
......@@ -46,7 +46,6 @@ export function recordOption(legendData, xAxisData, seriesData) {
tooltip: {
trigger: "axis",
axisPointer: {
// 坐标轴指示器,坐标轴触发有效
type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
shadowStyle: {
shadowColor: '#E3EFED',
......@@ -123,11 +122,18 @@ export function certificateOption(xAxisData, seriesJoin, seriesCert, seriesRate)
},
tooltip: {
trigger: "axis",
// axisPointer: {
// type: "cross",
// crossStyle: {
// color: "#999"
// }
// },
axisPointer: {
type: "cross",
crossStyle: {
color: "#999"
}
type: "shadow", // 默认为直线,可选为:'line' | 'shadow'
shadowStyle: {
shadowColor: '#E3EFED',
width: 36,
},
},
backgroundColor: 'rgba(0,0,0,0.7)',
formatter: function (params) {
......@@ -285,13 +291,25 @@ export function durationOption(xAxisData, seriesData) {
data: xAxisData,
axisTick: {
alignWithLabel: true
}
},
axisLine: { //隐藏轴线
show: false
},
axisTick: { // 隐藏刻度
show: false
},
}
],
yAxis: [
{
type: "value",
name: "完成时长 (天)"
name: "完成时长 (天)",
axisLine: { //隐藏轴线
show: false
},
axisTick: { // 隐藏刻度
show: false
},
}
],
series: [
......@@ -532,9 +550,6 @@ export function examTimes(xAxisData, seriesData) {
},
xAxis: [
{
// splitLine: {
// show: false
// },
axisLabel: {
interval: 0,
},
......@@ -542,7 +557,13 @@ export function examTimes(xAxisData, seriesData) {
data: xAxisData,
axisTick: {
alignWithLabel: true
}
},
axisLine: { //隐藏轴线
show: false
},
axisTick: { // 隐藏刻度
show: false
},
}
],
yAxis: [
......@@ -551,7 +572,13 @@ export function examTimes(xAxisData, seriesData) {
show: true
},
type: "value",
name: "人数 (名)"
name: "人数 (名)",
axisLine: { //隐藏轴线
show: false
},
axisTick: { // 隐藏刻度
show: false
},
}
],
series: [
......@@ -599,9 +626,6 @@ export function examScore(xAxisData, seriesData) {
},
xAxis: [
{
// splitLine: {
// show: false
// },
axisLabel: {
interval: 0,
},
......@@ -609,7 +633,13 @@ export function examScore(xAxisData, seriesData) {
data: xAxisData,
axisTick: {
alignWithLabel: true
}
},
axisLine: { //隐藏轴线
show: false
},
axisTick: { // 隐藏刻度
show: false
},
}
],
yAxis: [
......@@ -618,7 +648,13 @@ export function examScore(xAxisData, seriesData) {
show: true
},
type: "value",
name: "人数 (名)"
name: "人数 (名)",
axisLine: { //隐藏轴线
show: false
},
axisTick: { // 隐藏刻度
show: false
},
}
],
series: [
......@@ -639,10 +675,10 @@ export function examScore(xAxisData, seriesData) {
};
return option;
}
export function ringOption(num , color) {
export function ringOption(num, color) {
let option = {
title: {
text: num+'%',
text: num + '%',
x: 'center',
y: 'center',
textStyle: {
......
......@@ -4,8 +4,8 @@
<div class="component-content screenSet" id="screenSet">
<div class="p-title">任务列表</div>
<el-tabs v-model="listType" type="card" @tab-click="handleClick">
<el-tab-pane label="查看报告" name="1"></el-tab-pane>
<el-tab-pane label="导出列表" name="2"></el-tab-pane>
<el-tab-pane label="查看报告" name="2"></el-tab-pane>
<el-tab-pane label="导出列表" name="1"></el-tab-pane>
</el-tabs>
<el-table :data="tableData" class="table-export" style="width: 100%">
<el-table-column
......@@ -20,7 +20,7 @@
</el-table-column>
<el-table-column prop="status" label="状态" align="left" min-width="30">
<template slot-scope="scope">
<span class="logo"></span>
<span class="logo" v-bind:class="{ 'logo_0': scope.row.status == 0, 'logo_1': scope.row.status == 1, 'logo_2': scope.row.status == 2 }"></span>
<span class="text">{{ scope.row.status | exportStatus }}</span>
</template>
</el-table-column>
......@@ -30,8 +30,10 @@
:disabled="scope.row.buttonStatus"
size="small"
type="text"
v-if="scope.row.status != 2"
@click="update(scope.row)"
>{{ scope.row.buttonText }}</el-button>
<div v-if="scope.row.status == 2">-</div>
</template>
</el-table-column>
<div slot="empty">
......@@ -69,7 +71,7 @@ export default {
data() {
return {
curmbFirst: "学情报告",
curmbSecond: "导出下载",
curmbSecond: "任务列表",
projectId: "",
tableData: [],
param: {
......@@ -79,7 +81,7 @@ export default {
totalRows: 0,
totalTime: 3,
queryData: {},
listType: "1"
listType: "2"
// buttonText: "刷新",
// buttonStatus: false,
};
......@@ -89,7 +91,7 @@ export default {
this.projectId = vm.getUrlSearch(window.location.href, "projectId");
let listType = vm.getUrlSearch(window.location.href, "listType");
if(listType == null) {
vm.listType = '1';
vm.listType = '2';
} else {
vm.listType = listType;
}
......@@ -107,7 +109,11 @@ export default {
for (let i = 0; i < vm.tableData.length; i++) {
vm.tableData[i].index = i;
if (vm.tableData[i].status == 1) {
vm.tableData[i].buttonText = "下载";
if(vm.listType == '2') {
vm.tableData[i].buttonText = "查看报告";
} else if(vm.listType == '1') {
vm.tableData[i].buttonText = "下载";
}
vm.tableData[i].buttonStatus = false;
} else if (vm.tableData[i].status == 0) {
vm.tableData[i].buttonText = "刷新";
......@@ -138,11 +144,6 @@ export default {
}
});
},
downLoad(row) {
setTimeout(() => {
window.open(row.fileUrl);
}, 500);
},
getDownLoadStatus(row) {
// let req = {
// id: row.id
......@@ -165,7 +166,12 @@ export default {
// console.log('res.data.data',res.data.data);
if (updateStatus == 1) {
vm.tableData[row.index].title = vm.tableData[row.index].title + " ";
vm.tableData[row.index].buttonText = "下载";
// vm.tableData[row.index].buttonText = "下载";
if(vm.listType == '2') {
vm.tableData[row.index].buttonText = "查看报告";
} else if(vm.listType == '1') {
vm.tableData[row.index].buttonText = "下载";
}
vm.tableData[row.index].fileUrl = res.data.list[0].url;
} else if (updateStatus == 0) {
vm.tableData[row.index].title = vm.tableData[row.index].title + " ";
......@@ -182,9 +188,22 @@ export default {
}
});
},
downLoad(row) {
setTimeout(() => {
window.open(row.fileUrl);
}, 500);
},
exportTime(row) {
vm.$router.push("item-list?downloadId="+row.id);
},
update(row) {
if (vm.tableData[row.index].status == 1) {
vm.downLoad(row);
// vm.downLoad(row);
if(vm.listType == '2') {
vm.exportTime(row);
} else if(vm.listType == '1') {
vm.downLoad(row);
}
} else {
this.$nextTick(function() {
console.log(vm.tableData[row.index]);
......@@ -217,7 +236,7 @@ export default {
},
// 换页
handleCurrentChange(val) {
vm.param.pageNo = value;
vm.param.pageNo = val;
vm.search();
}
}
......@@ -247,8 +266,16 @@ export default {
width: 6px;
height: 6px;
border-radius: 50%;
}
.logo_0 {
background: #1890ff;
}
.logo_1 {
background: #52C41A;
}
.logo_2 {
background: #F5222D;
}
.text {
float: left;
}
......
......@@ -333,7 +333,7 @@ export default {
vm.dataType = 0;
}
}
console.log('vm.hospitalCnt',vm.hospitalCnt);
// console.log('vm.hospitalCnt',vm.hospitalCnt);
if(vm.dataType == 0) {
vm.checkRange = "1";
vm.checkTime = "1",
......
此差异已折叠。
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册