标准预警导出功能
This commit is contained in:
@@ -113,6 +113,9 @@
|
|||||||
</el-row>
|
</el-row>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
|
<div style="float: right;margin: 0 3% 10px 0">
|
||||||
|
<el-button type="primary" size="mini" @click="exportExcelBtn">导出Excel</el-button>
|
||||||
|
</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<!-- <el-divider content-position="left" class="dynamic-child-title">实施日期预警</el-divider>-->
|
<!-- <el-divider content-position="left" class="dynamic-child-title">实施日期预警</el-divider>-->
|
||||||
<el-table
|
<el-table
|
||||||
@@ -123,7 +126,13 @@
|
|||||||
:resizable="false"
|
:resizable="false"
|
||||||
:header-cell-style="{background: '#f8f8f9', color: '#515a6e'}"
|
:header-cell-style="{background: '#f8f8f9', color: '#515a6e'}"
|
||||||
v-loading="warningTableLoading"
|
v-loading="warningTableLoading"
|
||||||
|
@selection-change="selectChange"
|
||||||
>
|
>
|
||||||
|
<el-table-column
|
||||||
|
type="selection"
|
||||||
|
width="55"
|
||||||
|
align="center">
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="standType" label="类型" width="100" align="center">
|
<el-table-column prop="standType" label="类型" width="100" align="center">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<div v-if="scope.row.sortName === 'BUSINESS_STAND'">企业标准</div>
|
<div v-if="scope.row.sortName === 'BUSINESS_STAND'">企业标准</div>
|
||||||
@@ -199,17 +208,33 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<adc-back-top scroll-bind="dynamicInformation"></adc-back-top>
|
<adc-back-top scroll-bind="dynamicInformation"></adc-back-top>
|
||||||
|
<!--导出模态框区域-->
|
||||||
|
<el-dialog :visible.sync="exportModelFlag" title="导出文件" width="300px">
|
||||||
|
<el-form :inline="true" class="label-input-form search-area">
|
||||||
|
<el-form-item label="导出名称" class="search-item">
|
||||||
|
<el-input v-model="exportName" placeholder="请输入导出文件名称" :maxlength="30" clearable label="导出名称"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<span slot="footer" class="demo-drawer-footer">
|
||||||
|
<el-button size="mini" class="common-button-default" icon="el-icon-close" @click="cancal">取消</el-button>
|
||||||
|
<el-button type="primary" size="mini" class="common-button-primary" icon="el-icon-check"
|
||||||
|
@click="exportExcel">提交</el-button>
|
||||||
|
</span>
|
||||||
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {mapMutations} from "vuex";
|
import {mapMutations} from "vuex";
|
||||||
|
import {interfaceUrl} from "@/sysConfig";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "standardWarning",
|
name: "standardWarning",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
//
|
selectedList: [],
|
||||||
|
exportName: '',
|
||||||
|
exportModelFlag: false,
|
||||||
warningTableDatas:[],
|
warningTableDatas:[],
|
||||||
warningTableHeight: '',
|
warningTableHeight: '',
|
||||||
applyArcticOptions: [], // 适用车型下拉框
|
applyArcticOptions: [], // 适用车型下拉框
|
||||||
@@ -259,6 +284,31 @@ export default {
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
//取消导出
|
||||||
|
cancal() {
|
||||||
|
this.exportModelFlag = false
|
||||||
|
},
|
||||||
|
//确认导出
|
||||||
|
exportExcel() {
|
||||||
|
console.log('293',this.selectedList)
|
||||||
|
const exportURL = interfaceUrl + 'sys/EarlyWarning/exportWarning?' +
|
||||||
|
'&ids=' + this.selectedList.join(',') + '&exportName=' + this.exportName
|
||||||
|
window.open(exportURL)
|
||||||
|
this.$message.success('导出信息成功')
|
||||||
|
this.exportModelFlag = false
|
||||||
|
},
|
||||||
|
exportExcelBtn(){
|
||||||
|
console.log('302',this.selectedList)
|
||||||
|
this.exportName = ''
|
||||||
|
this.exportModelFlag = true
|
||||||
|
},
|
||||||
|
selectChange(alldata){
|
||||||
|
console.log('307',alldata)
|
||||||
|
this.selectedList = []
|
||||||
|
for (let i = 0; i < alldata.length; i++) {
|
||||||
|
this.selectedList.push(alldata[i]['id'])
|
||||||
|
}
|
||||||
|
},
|
||||||
// 获取标准预警数据 (type用于区别分页器切换)
|
// 获取标准预警数据 (type用于区别分页器切换)
|
||||||
getEarlyDate() {
|
getEarlyDate() {
|
||||||
this.warningTableLoading = true
|
this.warningTableLoading = true
|
||||||
|
|||||||
Reference in New Issue
Block a user