Commit d704e7b7 by 李少勇

导出excel联调

parent fcf70036
import Api from "~/service/Api";
import getSubtyp from '~/page/Frontend/Rcvsel/event/getSubtyp.js';
import exportExcel from '~/page/Frontend/Rcvsel/event/exportExcel.js';
import moment from "moment";
import Msgrtm from "../model";
import Utils from "~/utils";
export default {
mixins: [getSubtyp],
mixins: [getSubtyp, exportExcel],
methods: {
async handleSearch() {
let rcvdatsta = this.model.sndp.rcvdatsta;
......@@ -36,15 +37,6 @@ export default {
this.load = false;
this.stmData.data = [];
const { list } = rtnmsg.data;
const { codes: { sta1 } } = this;
list.forEach(v => {
for (let i in sta1) {
if (sta1[i].value == v.sta) {
v.sta = sta1[i].label;
}
}
})
this.stmData.data = list;
this.pagination = {
pageNum: rtnmsg.data.pageNum || 1,
......@@ -77,6 +69,17 @@ export default {
},
handleSelectionChange(val) {
this.multipleSelection = val;
},
exportToExcel() {
let codeKeysMap = {
sta: 'stacod'
};
let params = {
...this.model.sndp,
dir: ">",
querytyp: "rtm",
};
this.exportExcel(this.stmData.columns, '/frontend/msgsel/exportExcel', params, codeKeysMap, '人工清分');
}
},
};
......@@ -120,7 +120,7 @@
</c-col>
<c-col :span="8">
<el-form-item label="处理状态" prop="sta" style="width: 100%">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.sta1">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.stacod">
</c-select>
</el-form-item>
</c-col>
......@@ -136,7 +136,7 @@
<c-button :disabled="isRoutingDisable" class="medium_bcs" size="medium" style="margin-left: 20" type="primary">
ReRouting
</c-button>
<c-button class="medium_bcs" size="medium" style="margin-left: 20" type="primary">
<c-button class="medium_bcs" size="medium" style="margin-left: 20" type="primary" @click="exportToExcel">
{{ $t('public.导出Excel') }}
</c-button>
</el-col>
......
......@@ -97,7 +97,7 @@
<c-col :span="24">
<c-col :span="8">
<el-form-item label="处理状态" prop="" style="width: 100%">
<c-select :code="codes.sta1" :filterKey="['V']" disabled v-model="model.sndp.sta"
<c-select :code="codes.stacod" :filterKey="['V']" disabled v-model="model.sndp.sta"
style="width: 100%" />
</el-form-item>
</c-col>
......
import Api from "@/service/Api";
import getSubtyp from '~/page/Frontend/Rcvsel/event/getSubtyp.js';
import exportExcel from '~/page/Frontend/Rcvsel/event/exportExcel.js';
import moment from "moment";
import Msgsep from "../model";
import Utils from "~/utils";
export default {
mixins: [getSubtyp],
mixins: [getSubtyp, exportExcel],
methods: {
async handleSearch() {
let rcvdatsta = this.model.sndp.rcvdatsta;
......@@ -36,15 +37,6 @@ export default {
this.load = false;
this.stmData.data = [];
const { list } = rtnmsg.data;
const { codes: { sta1 } } = this;
list.forEach(v => {
for (let i in sta1) {
if (sta1[i].value == v.sta) {
v.sta = sta1[i].label;
}
}
})
this.stmData.data = list;
this.pagination = {
pageNum: rtnmsg.data.pageNum || 1,
......@@ -77,6 +69,17 @@ export default {
},
handleSelectionChange(val) {
this.multipleSelection = val;
},
exportToExcel() {
let codeKeysMap = {
sta: 'stacod'
};
let params = {
...this.model.sndp,
dir: "<",
querytyp: "sep",
};
this.exportExcel(this.stmData.columns, '/frontend/msgsel/exportExcel', params, codeKeysMap, '报文失败处理');
}
},
};
......@@ -120,7 +120,7 @@
</c-col>
<c-col :span="8">
<el-form-item label="处理状态" prop="sndp.sta" style="width: 100%">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.sta1">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.stacod">
</c-select>
</el-form-item>
</c-col>
......@@ -136,7 +136,7 @@
<c-button :disabled="isRoutingDisable" class="medium_bcs" size="medium" style="margin-left: 20" type="primary">
ReRouting
</c-button>
<c-button class="medium_bcs" size="medium" style="margin-left: 20" type="primary">
<c-button class="medium_bcs" size="medium" style="margin-left: 20" type="primary" @click="exportToExcel">
{{ $t('public.导出Excel') }}
</c-button>
</el-col>
......
......@@ -37,15 +37,6 @@ export default {
this.load = false;
this.stmData.data = [];
const { list } = rtnmsg.data;
const { codes: { sta1 } } = this;
list.forEach(v => {
for (let i in sta1) {
if (sta1[i].value == v.sta) {
v.sta = sta1[i].label;
}
}
})
this.stmData.data = list;
this.pagination = {
pageNum: rtnmsg.data.pageNum || 1,
......
......@@ -127,7 +127,7 @@
<c-col :span="8">
<el-form-item label="处理状态" prop="sta" style="width: 100%">
<c-select v-model="model.rcvp.sta" style="width: 100%" placeholder="请选择处理状态"
:code="codes.sta1">
:code="codes.stacod">
</c-select>
</el-form-item>
</c-col>
......
......@@ -72,7 +72,7 @@ export default {
},
exportToExcel() {
let codeKeysMap = {
sta: 'sta1'
sta: 'stacod'
};
let params = {
...this.model.rcvp,
......
......@@ -127,7 +127,7 @@
<c-col :span="8">
<el-form-item label="处理状态" prop="sta" style="width: 100%">
<c-select v-model="model.rcvp.sta" style="width: 100%" placeholder="请选择处理状态"
:code="codes.sta1">
:code="codes.stacod">
</c-select>
</el-form-item>
</c-col>
......@@ -166,7 +166,7 @@
<el-table-column v-for="(item, key) in stmData.columns" :key="key" :label="item.label" :prop="item.prop"
:min-width="item.width">
<template slot-scope="scope">
<c-select-value-to-label v-if="item.prop == 'sta'" v-model="scope.row.sta" :code="codes.sta1"></c-select-value-to-label>
<c-select-value-to-label v-if="item.prop == 'sta'" v-model="scope.row.sta" :code="codes.stacod"></c-select-value-to-label>
<span v-else-if="item.prop == 'amt'">{{ moneyFormat(scope.row.amt, scope.row.cur) }}</span>
<span v-else>{{ scope.row[item.prop] }}</span>
</template>
......
......@@ -127,7 +127,7 @@
<c-col :span="8">
<el-form-item label="处理状态" prop="sta" style="width: 100%">
<c-select v-model="model.rcvp.sta" style="width: 100%" placeholder="请选择处理状态"
:code="codes.sta1">
:code="codes.stacod">
</c-select>
</el-form-item>
</c-col>
......
......@@ -72,7 +72,7 @@ export default {
},
exportToExcel() {
let codeKeysMap = {
sta: 'sta1'
sta: 'stacod'
};
let params = {
...this.model.sndp,
......
......@@ -120,7 +120,7 @@
</c-col>
<c-col :span="8">
<el-form-item label="处理状态" prop="sta" style="width: 100%">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.sta1">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.stacod">
</c-select>
</el-form-item>
</c-col>
......@@ -157,7 +157,7 @@
<el-table-column v-for="(item, key) in stmData.columns" :key="key" :label="item.label" :prop="item.prop"
:min-width="item.width">
<template slot-scope="scope">
<c-select-value-to-label v-if="item.prop == 'sta'" v-model="scope.row.sta" :code="codes.sta1"></c-select-value-to-label>
<c-select-value-to-label v-if="item.prop == 'sta'" v-model="scope.row.sta" :code="codes.stacod"></c-select-value-to-label>
<span v-else-if="item.prop == 'amt'">{{ moneyFormat(scope.row.amt, scope.row.cur) }}</span>
<span v-else>{{ scope.row[item.prop] }}</span>
</template>
......
......@@ -73,7 +73,7 @@ export default {
},
exportToExcel() {
let codeKeysMap = {
sta: 'sta1'
sta: 'stacod'
};
let params = {
...this.model.sndp,
......
......@@ -119,7 +119,7 @@
</c-col>
<c-col :span="8">
<el-form-item label="处理状态" prop="sta" style="width: 100%">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.sta1">
<c-select v-model="model.sndp.sta" style="width: 100%" placeholder="请选择处理状态" :code="codes.stacod">
</c-select>
</el-form-item>
</c-col>
......@@ -156,7 +156,7 @@
<el-table-column v-for="(item, key) in stmData.columns" :key="key" :label="item.label" :prop="item.prop"
:min-width="item.width">
<template slot-scope="scope">
<c-select-value-to-label v-if="item.prop == 'sta'" v-model="scope.row.sta" :code="codes.sta1"></c-select-value-to-label>
<c-select-value-to-label v-if="item.prop == 'sta'" v-model="scope.row.sta" :code="codes.stacod"></c-select-value-to-label>
<span v-else-if="item.prop == 'amt'">{{ moneyFormat(scope.row.amt, scope.row.cur) }}</span>
<span v-else>{{ scope.row[item.prop] }}</span>
</template>
......
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