Compare commits

..

No commits in common. "60261c9aaccbe940a9c89f1e348091155e5a18e4" and "37b851f3a2c6f3f768c7dc3cf625a37c217bf8a8" have entirely different histories.

4 changed files with 26 additions and 38 deletions

View File

@ -344,9 +344,7 @@ export default {
} }
const res = await infoApi.getCom(parm); const res = await infoApi.getCom(parm);
if (res.code == 0) { if (res.code == 0) {
state.comArr = res.data.sort((a,b) => { state.comArr = res.data;
return (a.name > b.name ? 1 : -1)
});
state.form2.com_name = state.comArr[0].name; state.form2.com_name = state.comArr[0].name;
} }
}; };

View File

@ -63,13 +63,13 @@ export default {
iconName: 'Management', iconName: 'Management',
children: [], children: [],
}, },
// { {
// id: 2, id: 2,
// name: "", name: "规则引擎",
// index: "/rules", index: "/rules",
// iconName: 'Management', iconName: 'Management',
// children: [], children: [],
// }, },
// { // {
// id: 4, // id: 4,
// name: "", // name: "",
@ -98,11 +98,11 @@ export default {
// name: "", // name: "",
// index: "/data", // index: "/data",
// }, // },
// { {
// id: 3 - 3, id: 3 - 3,
// name: "", name: "上报管理",
// index: "/report", index: "/report",
// }, },
], ],
}, },
], ],

View File

@ -4,7 +4,7 @@
<div class="top-div"> <div class="top-div">
<el-button type="primary" @click="addData"></el-button> <el-button type="primary" @click="addData"></el-button>
</div> </div>
<el-table :data="tableData" height="760" style="width: 100%" border stripe <el-table :data="tableData" height="730" style="width: 100%" border stripe
:header-cell-style="{ background: '#F6F7FC' }"> :header-cell-style="{ background: '#F6F7FC' }">
<el-table-column type="index" label="序号" width="80" align="center" /> <el-table-column type="index" label="序号" width="80" align="center" />
<el-table-column prop="name" label="模板名称" width="240" align="center" show-overflow-tooltip /> <el-table-column prop="name" label="模板名称" width="240" align="center" show-overflow-tooltip />
@ -85,9 +85,7 @@ export default {
const res = await infoApi.getMb(); const res = await infoApi.getMb();
if (res.code == 0) { if (res.code == 0) {
// //
state.tableData = res.data.sort((a,b) => { state.tableData = res.data;
return (a.name > b.name ? 1 : -1)
});
} else { } else {
} }
}; };

View File

@ -4,7 +4,7 @@
<div class="top-div"> <div class="top-div">
<el-button type="primary" @click="addData"></el-button> <el-button type="primary" @click="addData"></el-button>
</div> </div>
<el-table :data="tableData" height="760" border stripe <el-table :data="tableData" height="400" border stripe
:header-cell-style="{ background: '#F6F7FC' }"> :header-cell-style="{ background: '#F6F7FC' }">
<el-table-column type="index" label="序号" width="80" align="center" /> <el-table-column type="index" label="序号" width="80" align="center" />
<el-table-column prop="name" label="通讯名称" width="200" align="center" show-overflow-tooltip /> <el-table-column prop="name" label="通讯名称" width="200" align="center" show-overflow-tooltip />
@ -14,9 +14,16 @@
<span>{{ qudongOptions[scope.row.type] }}</span> <span>{{ qudongOptions[scope.row.type] }}</span>
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column
prop="host"
label="主机地址"
width="200"
align="center"
show-overflow-tooltip
/> -->
<el-table-column prop="status" label="通讯状态" width="200" align="center"> <el-table-column prop="status" label="通讯状态" width="200" align="center">
<template #default="scope"> <template #default="scope">
<span :style="{'color': getTextColor(scope.row.status)}"> {{ txStatus[scope.row.status] }} </span> <span> {{ txStatus[scope.row.status] }} </span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="enable" label="启用状态" width="350" align="center"> <el-table-column prop="enable" label="启用状态" width="350" align="center">
@ -152,9 +159,7 @@ export default {
} }
const res = await infoApi.getTx(param); const res = await infoApi.getTx(param);
if (res.code == 0) { if (res.code == 0) {
state.tableData = res.data.sort((a,b) => { state.tableData = res.data;
return (a.name > b.name ? 1 : -1)
});
} }
}; };
const dialogClose = () => { const dialogClose = () => {
@ -266,18 +271,6 @@ export default {
state.dialogVisible4 = true; state.dialogVisible4 = true;
} }
const getTextColor = (type) => {
if(type == 1) {
return ''
}
if(type == 2) {
return 'green'
}
if(type == 3) {
return 'red'
}
}
return { return {
...toRefs(state), ...toRefs(state),
addData, addData,
@ -295,8 +288,7 @@ export default {
dialogSuccess4, dialogSuccess4,
openPz, openPz,
openDetails, openDetails,
viewData, viewData
getTextColor
}; };
}, },
}; };