parent
35401bf86f
commit
25ef8ebfc2
@ -1,7 +1,324 @@
|
|||||||
<template></template>
|
<template>
|
||||||
|
<main-app :showTree="false" listTitle="填报列表">
|
||||||
|
<template v-slot:search>
|
||||||
|
<el-form
|
||||||
|
:model="formInline"
|
||||||
|
ref="queryForm"
|
||||||
|
size="small"
|
||||||
|
:inline="true"
|
||||||
|
label-width="88px"
|
||||||
|
>
|
||||||
|
<el-form-item label="资产名称:" prop="name">
|
||||||
|
<el-input v-model="formInline.name" placeholder="请输入"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="所属单位:" prop="dwmc">
|
||||||
|
<el-input v-model="formInline.dwmc" placeholder="请输入"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="审核状态:" prop="auditState">
|
||||||
|
<el-select
|
||||||
|
v-model="formInline.auditState"
|
||||||
|
placeholder="请选择审核状态"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
v-for="dict in dict.type.tc_tb_state"
|
||||||
|
>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-search"
|
||||||
|
size="mini"
|
||||||
|
@click="handleQuery"
|
||||||
|
>搜索</el-button
|
||||||
|
>
|
||||||
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
|
||||||
|
>重置</el-button
|
||||||
|
>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
</template>
|
||||||
|
<template v-slot:tablec>
|
||||||
|
<div class="table-type">
|
||||||
|
<div
|
||||||
|
:class="currentIndex == index ? 'activeType' : ''"
|
||||||
|
v-for="(item, index) in tableTypeList"
|
||||||
|
:key="index"
|
||||||
|
@click="changeType(index, item.value)"
|
||||||
|
>
|
||||||
|
{{ item.label }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<template v-slot:table>
|
||||||
|
<el-table
|
||||||
|
v-loading="loading"
|
||||||
|
:data="tableData"
|
||||||
|
:height="tabHeader"
|
||||||
|
:row-class-name="tableRowClassName"
|
||||||
|
>
|
||||||
|
<el-table-column type="index" width="50" label="序号" align="center" />
|
||||||
|
<el-table-column
|
||||||
|
label="资产名称"
|
||||||
|
prop="xtmc"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex == 0"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="所属单位"
|
||||||
|
prop="dwmc"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex == 0"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="资产名称"
|
||||||
|
prop="xcxmc"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex == 1"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="资产名称"
|
||||||
|
prop="gzhmc"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex == 2"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="资产名称"
|
||||||
|
prop="dzyxhz"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex == 3"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="资产名称"
|
||||||
|
prop="appName"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex == 4"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="所属单位"
|
||||||
|
prop="ssdw"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex != 0"
|
||||||
|
/>
|
||||||
|
<el-table-column
|
||||||
|
label="平台类型"
|
||||||
|
prop="ptlx"
|
||||||
|
align="center"
|
||||||
|
v-if="currentIndex == 2"
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag
|
||||||
|
:options="dict.type.sys_ptlx_type"
|
||||||
|
:value="scope.row.ptlx"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="审核状态" prop="auditState" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag
|
||||||
|
:options="dict.type.tc_tb_state"
|
||||||
|
:value="scope.row.auditState"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
<!-- <template slot-scope="scope">
|
||||||
|
<span v-if="scope.row.auditState == 1" style="color: #F58A0C;">
|
||||||
|
待审核
|
||||||
|
</span>
|
||||||
|
<span v-if="scope.row.auditState == 2" style="color: #16B771;">
|
||||||
|
审批通过
|
||||||
|
</span>
|
||||||
|
<span v-if="scope.row.auditState == 3" style="color: #F50C0C;">
|
||||||
|
审批驳回
|
||||||
|
</span>
|
||||||
|
</template> -->
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="操作"
|
||||||
|
prop="userId"
|
||||||
|
class-name="table-operation"
|
||||||
|
align="center"
|
||||||
|
>
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button type="primary" size="mini" plain icon="el-icon-view"
|
||||||
|
>查看</el-button
|
||||||
|
>
|
||||||
|
<el-button
|
||||||
|
type="warning"
|
||||||
|
size="mini"
|
||||||
|
plain
|
||||||
|
icon="el-icon-edit-outline"
|
||||||
|
>审批</el-button
|
||||||
|
>
|
||||||
|
<el-button type="danger" size="mini" plain icon="el-icon-delete"
|
||||||
|
>驳回原因</el-button
|
||||||
|
>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<pagination
|
||||||
|
prev-text="上页"
|
||||||
|
next-text="下页"
|
||||||
|
v-show="total > 0"
|
||||||
|
:total="total"
|
||||||
|
:page-sizes="[10, 20, 40, 80, 100]"
|
||||||
|
:page.sync="formInline.current"
|
||||||
|
:limit.sync="formInline.size"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</main-app>
|
||||||
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {};
|
import {
|
||||||
|
getAuditList,
|
||||||
|
miniProgramsGetAuditList,
|
||||||
|
gzhGetAuditList,
|
||||||
|
EmailList,
|
||||||
|
AppList,
|
||||||
|
} from "@/api/auditPagesApi/index.js";
|
||||||
|
export default {
|
||||||
|
dicts: ["sys_ptlx_type", "tc_tb_state"],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
loading: false,
|
||||||
|
tableData: [],
|
||||||
|
tabHeader: 585,
|
||||||
|
total: 0,
|
||||||
|
formInline: {
|
||||||
|
current: 1,
|
||||||
|
size: 20,
|
||||||
|
name: "",
|
||||||
|
dwmc: "",
|
||||||
|
auditState: "",
|
||||||
|
},
|
||||||
|
currentIndex: 0,
|
||||||
|
tableTypeList: [
|
||||||
|
{
|
||||||
|
label: "web资产",
|
||||||
|
value: "web",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "小程序",
|
||||||
|
value: "xcx",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "公众号",
|
||||||
|
value: "gzh",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "电子邮件",
|
||||||
|
value: "emil",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "移动应用系统",
|
||||||
|
value: "app",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/**
|
||||||
|
* 类型变化
|
||||||
|
*/
|
||||||
|
|
||||||
|
changeType(index, value) {
|
||||||
|
if (this.currentIndex == index) return;
|
||||||
|
this.currentIndex = index;
|
||||||
|
this.handleQuery();
|
||||||
|
},
|
||||||
|
// 修改table背景色
|
||||||
|
tableRowClassName({ row, rowIndex }) {
|
||||||
|
if (rowIndex % 2 !== 0) {
|
||||||
|
return "evenNumber-row";
|
||||||
|
}
|
||||||
|
return "";
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 重置
|
||||||
|
*/
|
||||||
|
resetQuery() {
|
||||||
|
this.resetForm("queryForm");
|
||||||
|
this.handleQuery();
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 搜索
|
||||||
|
*/
|
||||||
|
handleQuery() {
|
||||||
|
this.formInline.current = 1;
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
/**
|
||||||
|
* 获取列表
|
||||||
|
*/
|
||||||
|
getList() {
|
||||||
|
this.loading = true;
|
||||||
|
if (this.currentIndex == 0) {
|
||||||
|
getAuditList(this.formInline).then((res) => {
|
||||||
|
this.sameList(res.data.total, res.data.records);
|
||||||
|
});
|
||||||
|
} else if (this.currentIndex == 1) {
|
||||||
|
miniProgramsGetAuditList(this.formInline).then((res) => {
|
||||||
|
this.sameList(res.data.total, res.data.records);
|
||||||
|
});
|
||||||
|
} else if (this.currentIndex == 2) {
|
||||||
|
gzhGetAuditList(this.formInline).then((res) => {
|
||||||
|
this.sameList(res.data.total, res.data.records);
|
||||||
|
});
|
||||||
|
} else if (this.currentIndex == 3) {
|
||||||
|
EmailList(this.formInline).then((res) => {
|
||||||
|
this.sameList(res.data.total, res.data.records);
|
||||||
|
});
|
||||||
|
} else if (this.currentIndex == 4) {
|
||||||
|
AppList(this.formInline).then((res) => {
|
||||||
|
this.sameList(res.data.total, res.data.records);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
sameList(total, list) {
|
||||||
|
this.total = total;
|
||||||
|
this.tableData = list;
|
||||||
|
this.loading = false;
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style></style>
|
<style lang="scss" scoped>
|
||||||
|
::v-deep .el-form-item__content {
|
||||||
|
width: 280px;
|
||||||
|
.el-select,
|
||||||
|
.el-date-editor {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.table-type {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
div {
|
||||||
|
cursor: pointer;
|
||||||
|
margin-left: 10px;
|
||||||
|
font-size: 14px;
|
||||||
|
color: #192733;
|
||||||
|
background: #f5f5f5;
|
||||||
|
border: 1px solid #e1e3e6;
|
||||||
|
padding: 4px 14px;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
.activeType {
|
||||||
|
color: #fff;
|
||||||
|
background: #1485ef;
|
||||||
|
border: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
Loading…
Reference in new issue