Commit 23a9406c authored by 王亚晖's avatar 王亚晖
parents bf4fe6f3 f174c38f
......@@ -77,9 +77,9 @@
<el-table v-show="isHisData" :data="tableInfo.tableData" :height="tableHeight" v-loading="loading"
:cell-style="setCellStyle" border highlight-current-row :header-cell-style="setHeaderCellStyle"
:header-cell-class-name="handleHeadAddClass" @sort-change="sortMethod">
:header-cell-class-name="handleHeadAddClass" @sort-change="sortMethod" >
<el-table-column v-for="(item, i) in tableInfo.title.frozenList" :prop="item.field" :label="item.title"
:width="item.width" fixed />
:width="item.width" fixed sortable/>
<template v-for="(item, i) in tableInfo.title.otherList">
<el-table-column :prop="item.enName" :label="item.alias" :width="item.width">
</el-table-column>
......@@ -622,9 +622,9 @@ function sortMethod({ order, prop }) {
// }
// console.log(sortname)
if (sortnames === "") {
sortnames = sortnames + sortname + " " + direction;
sortnames = sortnames + i + " " + direction;
} else {
sortnames = sortnames + "," + sortname + " " + direction;
sortnames = sortnames + "," + i + " " + direction;
}
DataInfo.sort = sortnames;
}
......
......@@ -70,16 +70,16 @@
<el-table-column v-for="(item, i) in tableInfo.title.frozenList" :prop="item.field" :label="item.title"
:width="item.width" sortable fixed />
<template v-for="(item, i) in tableInfo.title.otherList">
<el-table-column :prop="item.enName" :label="item.alias" :width="item.width" sortable>
<el-table-column :prop="item.enName" :label="item.alias" :width="item.width" >
</el-table-column>
</template>
</el-table>
<el-table v-show="isHisData" :data="tableInfo.tableData" :height="tableHeight" v-loading="loading"
:cell-style="setCellStyle" border highlight-current-row :header-cell-style="setHeaderCellStyle"
:header-cell-class-name="handleHeadAddClass" @sort-change="sortMethod">
:header-cell-class-name="handleHeadAddClass" @sort-change="sortMethod" sortable>
<el-table-column v-for="(item, i) in tableInfo.title.frozenList" :prop="item.field" :label="item.title"
:width="item.width" fixed />
:width="item.width" fixed sortable />
<template v-for="(item, i) in tableInfo.title.otherList">
<el-table-column :prop="item.enName" :label="item.alias" :width="item.width">
</el-table-column>
......@@ -285,7 +285,7 @@ if(!startTimeValue){
}
var endTimeValue = sessionStorage.getItem("DeviceQueryEnd");
if(!endTimeValue){
endTimeValue = year + "-" + (dateArr[0]-1) + "-" + dateArr[1] + " " + dateArr[2] + ":" + dateArr[3] + ":" + dateArr[4];
endTimeValue = (year-1) + "-" + dateArr[0] + "-" + dateArr[1] + " " + dateArr[2] + ":" + dateArr[3] + ":" + dateArr[4];
sessionStorage.setItem("DeviceQueryEnd", endTimeValue);
}
......@@ -625,9 +625,9 @@ function sortMethod({ order, prop }) {
// }
// console.log(sortname)
if (sortnames === "") {
sortnames = sortnames + sortname + " " + direction;
sortnames = sortnames + i + " " + direction;
} else {
sortnames = sortnames + "," + sortname + " " + direction;
sortnames = sortnames + "," + i + " " + direction;
}
DataInfo.sort = sortnames;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment