Commit 8abcca40 authored by neogcg's avatar neogcg

配置详情

parent 18d6d570
...@@ -91,6 +91,7 @@ export const constantRoutes = [ ...@@ -91,6 +91,7 @@ export const constantRoutes = [
{ {
path: 'statistics', path: 'statistics',
name: 'settingAtatistics', name: 'settingAtatistics',
component: () => import('@/views/setting/statistics/index'), component: () => import('@/views/setting/statistics/index'),
meta: { title: '配置信息统计' }, meta: { title: '配置信息统计' },
children: [ children: [
...@@ -98,18 +99,32 @@ export const constantRoutes = [ ...@@ -98,18 +99,32 @@ export const constantRoutes = [
] ]
}, },
{ {
path: "/detail", path: "/detail/",
name: "detail", name: "detail",
component: () => import('@/views/setting/statistics/detail'), beforeEnter: (to, from, next) => {
meta: { title: "详情" }, if (to.query.type==1) {
hidden: true, to.meta.title = '铁路线详情'
}
else if (to.query.type==2) {
to.meta.title = '站点详情'
}
else if (to.query.type==3) {
to.meta.title = 'FSU详情'
}
else if (to.query.type==4) {
to.meta.title = '监测设备详情'
}
else if (to.query.type==5) {
to.meta.title = '漏缆详情'
}
else if (to.query.type==6) {
to.meta.title = '天馈线详情'
} else{
to.meta.title = '详情'
}
next()
}, },
{ component: () => import('@/views/setting/statistics/detail'),
path: "/sitedetail",
name: "sitedetail",
component: () => import('@/views/setting/statistics/sitedetail'),
meta: { title: "站点详情" },
hidden: true, hidden: true,
}, },
...@@ -234,5 +249,8 @@ export function resetRouter() { ...@@ -234,5 +249,8 @@ export function resetRouter() {
const newRouter = createRouter() const newRouter = createRouter()
router.matcher = newRouter.matcher // reset router router.matcher = newRouter.matcher // reset router
} }
router.beforeResolve((to, from, next) => {
window.document.title = to.meta.title
next()
})
export default router export default router
...@@ -59,5 +59,18 @@ ...@@ -59,5 +59,18 @@
margin-bottom: 20px; margin-bottom: 20px;
.label{ .label{
font-weight: 400px; font-weight: 400px;
font-size: 14px;
} }
} }
.search-div{
background: #EAF1FE;
padding-top: 16px;
margin-bottom: 20px;
}
.none{
display: none;
}
.seabtn{
color: #fff;
background:rgba(122, 164, 251, 0.55);
}
...@@ -214,11 +214,11 @@ export default { ...@@ -214,11 +214,11 @@ export default {
asyncstationList: "station/asyncList", asyncstationList: "station/asyncList",
}), }),
changerailWay() { changerailWay() {
console.log(this.FSUForm.parentId);
this.stationSelect2 = this.stationlist.filter( this.stationSelect2 = this.stationlist.filter(
(item) => item.wayId === this.FSUForm.wayId (item) => item.wayId === this.FSUForm.wayId
); );
console.log(this.stationSelect2);
}, },
readNodes(aaa = [], arrarea = []) { readNodes(aaa = [], arrarea = []) {
for (let item of aaa) { for (let item of aaa) {
...@@ -237,11 +237,11 @@ export default { ...@@ -237,11 +237,11 @@ export default {
if (valid) { if (valid) {
this.FSUForm.parentId = this.FSUForm.siteId; this.FSUForm.parentId = this.FSUForm.siteId;
this.FSUForm.fsuPort = Number(this.FSUForm.fsuPort); this.FSUForm.fsuPort = Number(this.FSUForm.fsuPort);
console.log(this.FSUForm);
fsusave(this.FSUform).then((res) => { fsusave(this.FSUform).then((res) => {
if (res.code == 200) { if (res.code == 200) {
successAlert("添加成功"); successAlert("添加成功");
console.log(res);
} else { } else {
warning("添加失败"); warning("添加失败");
} }
...@@ -281,7 +281,7 @@ export default { ...@@ -281,7 +281,7 @@ export default {
this.asyncstationList(); this.asyncstationList();
this.railWaySelect = this.railWaylist; this.railWaySelect = this.railWaylist;
this.stationSelect = this.stationlist; this.stationSelect = this.stationlist;
console.log(this.asd);
}, },
}; };
</script> </script>
......
...@@ -22,7 +22,11 @@ ...@@ -22,7 +22,11 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="所在站点:" prop="siteId"> <el-form-item label="所在站点:" prop="siteId">
<el-select v-model="leakyCableForm.siteId" placeholder="请选择站点" @change="changesite()"> <el-select
v-model="leakyCableForm.siteId"
placeholder="请选择站点"
@change="changesite()"
>
<el-option <el-option
v-for="item in stationSelect2" v-for="item in stationSelect2"
:key="item.id" :key="item.id"
...@@ -32,7 +36,11 @@ ...@@ -32,7 +36,11 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="所在FSU:" prop="fsuId"> <el-form-item label="所在FSU:" prop="fsuId">
<el-select v-model="leakyCableForm.fsuId" placeholder="请选择FSU" @change="changefsu()"> <el-select
v-model="leakyCableForm.fsuId"
placeholder="请选择FSU"
@change="changefsu()"
>
<el-option <el-option
v-for="item in fsuSelect2" v-for="item in fsuSelect2"
:key="item.id" :key="item.id"
...@@ -42,7 +50,10 @@ ...@@ -42,7 +50,10 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="所在监测设备:" prop="monitor"> <el-form-item label="所在监测设备:" prop="monitor">
<el-select v-model="leakyCableForm.monitor" placeholder="请选择监测设备" > <el-select
v-model="leakyCableForm.monitor"
placeholder="请选择监测设备"
>
<el-option <el-option
v-for="item in monitor2" v-for="item in monitor2"
:key="item.id" :key="item.id"
...@@ -122,7 +133,7 @@ ...@@ -122,7 +133,7 @@
<script> <script>
import { leakyCablesave } from "../../api"; import { leakyCablesave } from "../../api";
import { mapGetters, mapActions } from "vuex"; import { mapGetters, mapActions } from "vuex";
import { successAlert,warningAlert } from "@/utils/alert"; import { successAlert, warningAlert } from "@/utils/alert";
export default { export default {
props: [], props: [],
components: {}, components: {},
...@@ -143,10 +154,10 @@ export default { ...@@ -143,10 +154,10 @@ export default {
}, },
], ],
leakyCableForm: { leakyCableForm: {
wayId:"", wayId: "",
siteId:"", siteId: "",
fsuId:"", fsuId: "",
monitor:"", monitor: "",
antennaFeederLength: 0, antennaFeederLength: 0,
hundredMetersLoss: 0, hundredMetersLoss: 0,
inserterLength: 0, inserterLength: 0,
...@@ -200,7 +211,11 @@ export default { ...@@ -200,7 +211,11 @@ export default {
}, },
], ],
sendPower: [ sendPower: [
{ required: true, message: "请输入漏缆测试信号发射功率", trigger: "blur" }, {
required: true,
message: "请输入漏缆测试信号发射功率",
trigger: "blur",
},
], ],
}, },
}; };
...@@ -210,7 +225,7 @@ export default { ...@@ -210,7 +225,7 @@ export default {
railWaylist: "railWay/list", railWaylist: "railWay/list",
stationlist: "station/list", stationlist: "station/list",
fsulist: "FSU/list", fsulist: "FSU/list",
monitorEquiplist:"monitor/list" monitorEquiplist: "monitor/list",
}), }),
}, },
methods: { methods: {
...@@ -219,28 +234,21 @@ export default { ...@@ -219,28 +234,21 @@ export default {
asyncstationList: "station/asyncList", asyncstationList: "station/asyncList",
asyncfsuList: "FSU/asyncList", asyncfsuList: "FSU/asyncList",
asyncmonitorList: "monitor/asyncList", asyncmonitorList: "monitor/asyncList",
}), }),
changerailWay() { changerailWay() {
this.stationSelect2 = this.stationlist.filter( this.stationSelect2 = this.stationlist.filter(
(item) => item.parentId === this.leakyCableForm.wayId (item) => item.parentId === this.leakyCableForm.wayId
); );
}, },
changesite() { changesite() {
this.fsuSelect2 = this.fsulist.filter( this.fsuSelect2 = this.fsulist.filter(
(item) => item.parentId === this.leakyCableForm.siteId (item) => item.parentId === this.leakyCableForm.siteId
); );
}, },
changefsu() { changefsu() {
this.monitor2 = this.monitorEquiplist.filter( this.monitor2 = this.monitorEquiplist.filter(
(item) => item.parentId === this.leakyCableForm.fsuId (item) => item.parentId === this.leakyCableForm.fsuId
); );
}, },
reset() { reset() {
this.$refs.leakyCableForm.resetFields(); this.$refs.leakyCableForm.resetFields();
...@@ -249,19 +257,18 @@ export default { ...@@ -249,19 +257,18 @@ export default {
this.$refs.leakyCableForm.validate((valid) => { this.$refs.leakyCableForm.validate((valid) => {
if (valid) { if (valid) {
leakyCablesave(this.leakyCableForm).then((res) => { leakyCablesave(this.leakyCableForm).then((res) => {
if (res.code==200) { if (res.code == 200) {
successAlert("添加成功") successAlert("添加成功");
console.log(res); } else {
}else{ warning("添加失败");
warning("添加失败")
} }
}); });
} }
this.leakyCableForm = { this.leakyCableForm = {
parentId:"", parentId: "",
siteId:"", siteId: "",
fsuId:"", fsuId: "",
monitor:"", monitor: "",
antennaFeederLength: 0, antennaFeederLength: 0,
hundredMetersLoss: 0, hundredMetersLoss: 0,
inserterLength: 0, inserterLength: 0,
...@@ -284,7 +291,6 @@ export default { ...@@ -284,7 +291,6 @@ export default {
this.asyncmonitorList(); this.asyncmonitorList();
this.railWaySelect = this.railWaylist; this.railWaySelect = this.railWaylist;
}, },
}; };
</script> </script>
......
...@@ -149,10 +149,10 @@ export default { ...@@ -149,10 +149,10 @@ export default {
fsuId: "", fsuId: "",
equipCode: "", equipCode: "",
equipFactory: "", equipFactory: "",
equipMode: '', equipMode: "",
equipName: "", equipName: "",
equipSerialNumber: "", equipSerialNumber: "",
equipType: '', equipType: "",
installDate: "2022-02-24 12:24:84", installDate: "2022-02-24 12:24:84",
kmSign: "", kmSign: "",
...@@ -241,10 +241,10 @@ export default { ...@@ -241,10 +241,10 @@ export default {
fsuId: "", fsuId: "",
equipCode: "", equipCode: "",
equipFactory: "", equipFactory: "",
equipMode: '', equipMode: "",
equipName: "", equipName: "",
equipSerialNumber: "", equipSerialNumber: "",
equipType: '', equipType: "",
installDate: "2022-02-22 12:24:84", installDate: "2022-02-22 12:24:84",
kmSign: "", kmSign: "",
...@@ -255,8 +255,8 @@ export default { ...@@ -255,8 +255,8 @@ export default {
}, },
created() { created() {
selectMonitorItem().then((res) => { selectMonitorItem().then((res) => {
this.equipTypeSelect=res["03"] this.equipTypeSelect = res["03"];
this.equipModeSelect=res["09"] this.equipModeSelect = res["09"];
}); });
}, },
mounted() { mounted() {
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
</template> </template>
<script> <script>
import { railWaysave } from "../../api"; import { railWaysave } from "../../api";
import { successAlert,warningAlert } from "@/utils/alert"; import { successAlert, warningAlert } from "@/utils/alert";
import { mapGetters, mapActions } from "vuex"; import { mapGetters, mapActions } from "vuex";
export default { export default {
props: [], props: [],
...@@ -83,11 +83,11 @@ export default { ...@@ -83,11 +83,11 @@ export default {
this.$refs.form.validate((valid) => { this.$refs.form.validate((valid) => {
if (valid) { if (valid) {
railWaysave(this.formData).then((res) => { railWaysave(this.formData).then((res) => {
if (res.code==200) { if (res.code == 200) {
successAlert("添加成功") successAlert("添加成功");
this.asyncrailWayList() this.asyncrailWayList();
}else{ } else {
warning("添加失败") warning("添加失败");
} }
}); });
} }
......
...@@ -75,7 +75,7 @@ ...@@ -75,7 +75,7 @@
<script> <script>
import { sitesave } from "../../api"; import { sitesave } from "../../api";
import { mapGetters, mapActions } from "vuex"; import { mapGetters, mapActions } from "vuex";
import { successAlert,warningAlert } from "@/utils/alert"; import { successAlert, warningAlert } from "@/utils/alert";
export default { export default {
props: [], props: [],
components: {}, components: {},
...@@ -93,7 +93,7 @@ export default { ...@@ -93,7 +93,7 @@ export default {
], ],
stationForm: { stationForm: {
parentId: "", parentId: "",
wayId:'', wayId: "",
siteCode: "", siteCode: "",
siteName: "", siteName: "",
siteAddress: "", siteAddress: "",
...@@ -107,12 +107,8 @@ export default { ...@@ -107,12 +107,8 @@ export default {
rules: { rules: {
parentId: [ parentId: [
{ required: true, message: "请选择铁路线", trigger: "blur" }, { required: true, message: "请选择铁路线", trigger: "blur" },
],
wayId: [
{ required: true, message: "请选择铁路线", trigger: "blur" },
], ],
wayId: [{ required: true, message: "请选择铁路线", trigger: "blur" }],
siteCode: [ siteCode: [
{ required: true, message: "请输入站点编号", trigger: "blur" }, { required: true, message: "请输入站点编号", trigger: "blur" },
], ],
...@@ -143,22 +139,21 @@ export default { ...@@ -143,22 +139,21 @@ export default {
}, },
computed: { computed: {
...mapGetters({ ...mapGetters({
railWaylist:"railWay/list", railWaylist: "railWay/list",
}), }),
}, },
methods: { methods: {
...mapActions({ ...mapActions({
asyncrailWayList: "railWay/asyncList", asyncrailWayList: "railWay/asyncList",
}), }),
readNodes (aaa=[], arrarea=[]) { readNodes(aaa = [], arrarea = []) {
for (let item of aaa) { for (let item of aaa) {
arrarea.push({"id":item.id,"name":item.name}) arrarea.push({ id: item.id, name: item.name });
if (item.children) { if (item.children) {
this.readNodes(item.children,arrarea) this.readNodes(item.children, arrarea);
} }
} }
return arrarea return arrarea;
}, },
reset() { reset() {
this.$refs.stationform.resetFields(); this.$refs.stationform.resetFields();
...@@ -166,22 +161,19 @@ export default { ...@@ -166,22 +161,19 @@ export default {
submit() { submit() {
this.$refs.stationform.validate((valid) => { this.$refs.stationform.validate((valid) => {
if (valid) { if (valid) {
this.stationForm.parentId=this.stationForm.wayId this.stationForm.parentId = this.stationForm.wayId;
console.log(this.stationForm);
sitesave(this.stationForm).then((res) => { sitesave(this.stationForm).then((res) => {
if (res.code==200) { if (res.code == 200) {
successAlert("添加成功") successAlert("添加成功");
console.log(res); } else {
}else{ warning("添加失败");
warning("添加失败")
} }
}); });
} }
this.stationForm = { this.stationForm = {
parentId: '', parentId: "",
wayId:'', wayId: "",
siteCode: "", siteCode: "",
siteName: "", siteName: "",
siteAddress: "", siteAddress: "",
...@@ -196,10 +188,9 @@ export default { ...@@ -196,10 +188,9 @@ export default {
}, },
}, },
mounted() { mounted() {
this.asyncrailWayList();
this.asyncrailWayList() this.railWaySelect = this.railWaylist;
this.railWaySelect= this.railWaylist;
}, },
}; };
</script> </script>
......
...@@ -6,16 +6,13 @@ ...@@ -6,16 +6,13 @@
<div class="content" v-if="activeName === '0'"> <div class="content" v-if="activeName === '0'">
<div class="content-title">添加铁路线</div> <div class="content-title">添加铁路线</div>
<railWay></railWay> <railWay></railWay>
</div> </div>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="站点" name="1"> <el-tab-pane label="站点" name="1">
<div class="content" v-if="activeName === '1'"> <div class="content" v-if="activeName === '1'">
<div class="content-title">添加站点</div> <div class="content-title">添加站点</div>
<station></station> <station></station>
</div> </div>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="FSU" name="2"> <el-tab-pane label="FSU" name="2">
...@@ -27,7 +24,7 @@ ...@@ -27,7 +24,7 @@
<el-tab-pane label="监测设备" name="3"> <el-tab-pane label="监测设备" name="3">
<div class="content" v-if="activeName === '3'"> <div class="content" v-if="activeName === '3'">
<div class="content-title">添加监测设备</div> <div class="content-title">添加监测设备</div>
<monitorEquip></monitorEquip> <monitorEquip></monitorEquip>
</div> </div>
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="漏缆" name="4"> <el-tab-pane label="漏缆" name="4">
...@@ -43,28 +40,26 @@ ...@@ -43,28 +40,26 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
</div> </div>
<!-- <div class="btn">
<el-button type="primary" @click="reset">重置</el-button>
<el-button type="primary" @click="submit">确认提交</el-button>
</div> -->
</div> </div>
</template> </template>
<script> <script>
import { railWaysave,sitesave } from "../api" import { railWaysave, sitesave } from "../api";
import railWay from "./comp/railWay.vue" import railWay from "./comp/railWay.vue";
import monitorEquip from "./comp/monitorEquip.vue" import monitorEquip from "./comp/monitorEquip.vue";
import station from "./comp/station.vue" import station from "./comp/station.vue";
import FSU from "./comp/FSU.vue" import FSU from "./comp/FSU.vue";
import leakyCable from "./comp/leakyCable.vue" import leakyCable from "./comp/leakyCable.vue";
export default { export default {
components: { components: {
monitorEquip,station,railWay,FSU,leakyCable monitorEquip,
station,
railWay,
FSU,
leakyCable,
}, },
data() { data() {
return { return {
activeName: "0", activeName: "0",
tabs: [ tabs: [
{ {
...@@ -92,18 +87,10 @@ export default { ...@@ -92,18 +87,10 @@ export default {
key: "5", key: "5",
}, },
], ],
}; };
}, },
methods: { methods: {
handleClick(tab, event) { handleClick(tab, event) {},
},
}, },
}; };
</script> </script>
......
...@@ -39,7 +39,10 @@ const path = { ...@@ -39,7 +39,10 @@ const path = {
export function railWaylist() { export function railWaylist() {
return request.post(path.railWaylist, ...arguments) return request.post(path.railWaylist, ...arguments)
} }
export function roleAdd() {
return request.post("http://localhost/api/railWay/selectPage", ...arguments)
}
// export const roleAdd = (params)=> post("http://172.16.0.242:8886/api/railWay/selectPage",params)
export function railWaydetail() { export function railWaydetail() {
return request.post(path.railWaydetail, ...arguments) return request.post(path.railWaydetail, ...arguments)
} }
...@@ -60,10 +63,11 @@ export function railWayselectList() { ...@@ -60,10 +63,11 @@ export function railWayselectList() {
// export function selectForSite() { // export function selectForSite() {
// return request.post(path.selectForSite, ...arguments) // return request.post(path.selectForSite, ...arguments)
// } // }
export function sitelist() {
export function sitelist() {
return request.post(path.sitelist, ...arguments) return request.post(path.sitelist, ...arguments)
} }
export function sitedetail() { export function sitedetail() {
return request.post(path.sitedetail, ...arguments) return request.post(path.sitedetail, ...arguments)
} }
......
...@@ -103,11 +103,7 @@ ...@@ -103,11 +103,7 @@
> >
<el-table-column type="selection" width="55" align="center" /> <el-table-column type="selection" width="55" align="center" />
<el-table-column prop="equipName" label="设备名称" align="center" /> <el-table-column prop="equipName" label="设备名称" align="center" />
<el-table-column <el-table-column prop="wayId" label="所在铁路线" align="center" />
prop="wayId"
label="所在铁路线"
align="center"
/>
<el-table-column <el-table-column
prop="siteId" prop="siteId"
label="所在站点" label="所在站点"
...@@ -125,47 +121,56 @@ ...@@ -125,47 +121,56 @@
label="FSU端口数" label="FSU端口数"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="ip" prop="ip"
label="IP地址" label="IP地址"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="equipFactory" prop="equipFactory"
label="设备厂商" label="设备厂商"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="backupMode" prop="backupMode"
label="设备备用方式" label="设备备用方式"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="connectMode" prop="connectMode"
label="通信方式" label="通信方式"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="equipType" prop="equipType"
label="设备类型" label="设备类型"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="equipSubType" prop="equipSubType"
label="设备子类型" label="设备子类型"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="softVersion" prop="softVersion"
label="软件版本号" label="软件版本号"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="equipSerialNumber" prop="equipSerialNumber"
label="设备生产序列号" label="设备生产序列号"
show-overflow-tooltip show-overflow-tooltip
align="center" align="center"
/> <el-table-column />
<el-table-column
prop="kmSign" prop="kmSign"
label="设备所在铁路公里标" label="设备所在铁路公里标"
show-overflow-tooltip show-overflow-tooltip
...@@ -197,7 +202,7 @@ ...@@ -197,7 +202,7 @@
<script> <script>
import Pagination from "@/components/Pagination"; import Pagination from "@/components/Pagination";
import { fsulist, fsubatchDelete, fsudetail } from "../../api"; import { fsulist, fsubatchDelete, fsudetail } from "../../api";
import { successAlert,warningAlert } from "@/utils/alert"; import { successAlert, warningAlert } from "@/utils/alert";
import { mapGetters, mapActions } from "vuex"; import { mapGetters, mapActions } from "vuex";
export default { export default {
props: [], props: [],
...@@ -208,17 +213,17 @@ export default { ...@@ -208,17 +213,17 @@ export default {
stationSelect: [], stationSelect: [],
stationSelect2: [], stationSelect2: [],
FSUForm: { FSUForm: {
fsuCode:"", fsuCode: "",
equipName: "阿达21", equipName: "阿达21",
equipSerialNumber: "4651", equipSerialNumber: "4651",
ip: "151511", ip: "192.168.0.3",
parentId: "", parentId: "",
siteId: "", siteId: "",
siteName: "asd", siteName: "asd",
wayId: "", wayId: "",
}, },
Info:[], Info: [],
visible:false, visible: false,
tableData: [], tableData: [],
params: { params: {
pageNum: 1, pageNum: 1,
...@@ -242,11 +247,9 @@ export default { ...@@ -242,11 +247,9 @@ export default {
asyncfsuList: "FSU/asyncList", asyncfsuList: "FSU/asyncList",
}), }),
changerailWay() { changerailWay() {
this.stationSelect2 = this.stationlist.filter( this.stationSelect2 = this.stationlist.filter(
(item) => item.wayId === this.FSUForm.wayId (item) => item.wayId === this.FSUForm.wayId
); );
}, },
tableRowClassName({ row, rowIndex }) { tableRowClassName({ row, rowIndex }) {
return rowIndex % 2 === 0 ? "" : "single-row"; return rowIndex % 2 === 0 ? "" : "single-row";
...@@ -257,15 +260,14 @@ export default { ...@@ -257,15 +260,14 @@ export default {
delData() { delData() {
let ids = this.ids; let ids = this.ids;
fsubatchDelete({ ids }).then((res) => { fsubatchDelete({ ids }).then((res) => {
if (res.code==200) { if (res.code == 200) {
successAlert("删除成功"); successAlert("删除成功");
this.asyncfsuList(); this.asyncfsuList();
this.getTableData(); this.getTableData();
}else{ } else {
warningAlert("删除失败") warningAlert("删除失败");
} }
}); });
}, },
refresh() { refresh() {
this.getTableData(); this.getTableData();
...@@ -276,16 +278,16 @@ export default { ...@@ -276,16 +278,16 @@ export default {
this.multipleSelection = val; this.multipleSelection = val;
this.ids = this.multipleSelection.map((i) => i.id); this.ids = this.multipleSelection.map((i) => i.id);
}, },
handleView(row) { handleView(row) {
// this.$router.push({ this.$router.push({
// path:'/detail', path: "/detail",
// query:{ query: {
// id:row.id id: row.id,
// }, type: 3,
// }) },
});
}, },
handlePageChange(pageData) { handlePageChange(pageData) {
this.params.pageSize = pageData.size; this.params.pageSize = pageData.size;
...@@ -293,13 +295,11 @@ export default { ...@@ -293,13 +295,11 @@ export default {
this.getTableData(); this.getTableData();
}, },
getTableData() { getTableData() {
let params = { let params = {
current: this.params.pageNum, current: this.params.pageNum,
size: this.params.pageSize, size: this.params.pageSize,
}; };
fsulist(params).then((res) => { fsulist(params).then((res) => {
console.log(res.records);
let list = res.records || []; let list = res.records || [];
this.tableData = list; this.tableData = list;
this.total = res.total; this.total = res.total;
...@@ -316,7 +316,6 @@ export default { ...@@ -316,7 +316,6 @@ export default {
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.leakage-cable { .leakage-cable {
.leakage-top { .leakage-top {
margin-bottom: 20px; margin-bottom: 20px;
......
...@@ -11,11 +11,11 @@ ...@@ -11,11 +11,11 @@
>删除</el-button >删除</el-button
> >
<el-button type="primary" @click="refresh">刷新</el-button> <el-button type="primary" @click="refresh">刷新</el-button>
<el-button type="primary" @click="query">查询</el-button> <el-button type="primary" @click="query()">查询</el-button>
<el-button type="primary" @click="exportData">导出</el-button> <el-button type="primary" @click="exportData">导出</el-button>
</div> </div>
</div> </div>
<div> <div :class="block==0?'search-div' : 'none'">
<div class="search-input-box"> <div class="search-input-box">
<label>漏缆描述:</label> <label>漏缆描述:</label>
<el-input <el-input
...@@ -36,18 +36,26 @@ ...@@ -36,18 +36,26 @@
v-model="leakyCableForm.leakyCableCode" v-model="leakyCableForm.leakyCableCode"
clearable clearable
> >
</el-input> </el-input>
</div> </div>
<div class="search-input-box"> <div class="search-input-box">
<label>漏缆型号:</label> <label>漏缆型号:</label>
<el-input <el-select
size="small" size="small"
placeholder="请输入漏缆型号" placeholder="请输入漏缆型号"
style="width: 180px" style="width: 180px"
v-model="leakyCableForm.leakyCableMode" v-model="leakyCableForm.leakyCableMode"
clearable clearable
> >
</el-input> <el-option
v-for="item in leakySelect"
:key="item.id"
:label="item.leakyName"
:value="item.id"
></el-option>
</el-select>
</div> </div>
<div class="search-input-box"> <div class="search-input-box">
<label>所在铁路线:</label> <label>所在铁路线:</label>
...@@ -110,7 +118,6 @@ ...@@ -110,7 +118,6 @@
placeholder="请选择所在监测设备" placeholder="请选择所在监测设备"
style="width: 180px" style="width: 180px"
v-model="leakyCableForm.monitor" v-model="leakyCableForm.monitor"
clearable clearable
> >
<el-option <el-option
...@@ -121,6 +128,10 @@ ...@@ -121,6 +128,10 @@
></el-option> ></el-option>
</el-select> </el-select>
</div> </div>
<div class="search-input-box">
<el-button class="seabtn" @click="searchQuery()">查询</el-button>
<el-button class="seabtn" @click="reset()">重置</el-button>
</div>
</div> </div>
<el-table <el-table
ref="multipleTable" ref="multipleTable"
...@@ -237,6 +248,7 @@ export default { ...@@ -237,6 +248,7 @@ export default {
components: { Pagination }, components: { Pagination },
data() { data() {
return { return {
leakySelect:[],
railWaySelect: [], railWaySelect: [],
stationSelect2: [], stationSelect2: [],
fsuSelect2: [], fsuSelect2: [],
...@@ -246,7 +258,7 @@ export default { ...@@ -246,7 +258,7 @@ export default {
parentId: "", parentId: "",
siteId: "", siteId: "",
fsuId: "", fsuId: "",
monitor:"", monitor: "",
leakyCableCode: "22", leakyCableCode: "22",
leakyCableDescribe: "打打", leakyCableDescribe: "打打",
...@@ -260,6 +272,7 @@ export default { ...@@ -260,6 +272,7 @@ export default {
total: 10, total: 10,
multipleSelection: [], multipleSelection: [],
ids: [], ids: [],
block:1,
}; };
}, },
computed: { computed: {
...@@ -277,7 +290,6 @@ export default { ...@@ -277,7 +290,6 @@ export default {
asyncfsuList: "FSU/asyncList", asyncfsuList: "FSU/asyncList",
asyncmonitorList: "monitor/asyncList", asyncmonitorList: "monitor/asyncList",
asyncleakyList: "leaky/asyncList", asyncleakyList: "leaky/asyncList",
}), }),
changerailWay() { changerailWay() {
this.stationSelect2 = this.stationlist.filter( this.stationSelect2 = this.stationlist.filter(
...@@ -305,7 +317,7 @@ export default { ...@@ -305,7 +317,7 @@ export default {
leakyCablebatchDelete({ ids }).then((res) => { leakyCablebatchDelete({ ids }).then((res) => {
if (res.code == 200) { if (res.code == 200) {
successAlert("删除成功"); successAlert("删除成功");
this.asyncleakyList() this.asyncleakyList();
this.getTableData(); this.getTableData();
} else { } else {
warningAlert("删除失败"); warningAlert("删除失败");
...@@ -315,7 +327,28 @@ export default { ...@@ -315,7 +327,28 @@ export default {
refresh() { refresh() {
this.getTableData(); this.getTableData();
}, },
query() {}, searchQuery(){},
reset(){
this.leakyCableForm= {
wayId: "",
parentId: "",
siteId: "",
fsuId: "",
monitor: "",
leakyCableCode: "",
leakyCableDescribe: "",
leakyCableMode: "",
}
},
query() {
if (this.block==1) {
this.block=0
} else {
this.block=1
}
},
exportData() {}, exportData() {},
handleSelectionChange(val) { handleSelectionChange(val) {
this.multipleSelection = val; this.multipleSelection = val;
...@@ -328,6 +361,7 @@ export default { ...@@ -328,6 +361,7 @@ export default {
path: "/detail", path: "/detail",
query: { query: {
id: row.id, id: row.id,
type: 5,
}, },
}); });
let id = row.id; let id = row.id;
...@@ -339,10 +373,6 @@ export default { ...@@ -339,10 +373,6 @@ export default {
this.getTableData(); this.getTableData();
}, },
getTableData() { getTableData() {
// this.tableData2 = this.tableData.slice(( this.params.pageNum - 1) * this.params.pageSize,
// this.params.pageNum * this.params.pageSize
// );
// this.total = this.tableData.length
let params = { let params = {
current: this.params.pageNum, current: this.params.pageNum,
size: this.params.pageSize, size: this.params.pageSize,
...@@ -407,4 +437,5 @@ export default { ...@@ -407,4 +437,5 @@ export default {
padding: 5px !important; padding: 5px !important;
} }
} }
</style> </style>
\ No newline at end of file
...@@ -200,7 +200,7 @@ import { ...@@ -200,7 +200,7 @@ import {
monitorEquipbatchDelete, monitorEquipbatchDelete,
monitorEquipdetail, monitorEquipdetail,
} from "../../api"; } from "../../api";
import { successAlert,warningAlert } from "@/utils/alert"; import { successAlert, warningAlert } from "@/utils/alert";
import { mapGetters, mapActions } from "vuex"; import { mapGetters, mapActions } from "vuex";
export default { export default {
props: [], props: [],
...@@ -213,10 +213,11 @@ export default { ...@@ -213,10 +213,11 @@ export default {
fsuSelect2: [], fsuSelect2: [],
monitorForm: { monitorForm: {
wayId:"", wayId: "",
parentId:"", parentId: "",
siteId:"", ip: "",
fsuId:"", siteId: "",
fsuId: "",
equipCode: "", equipCode: "",
equipName: "", equipName: "",
}, },
...@@ -245,18 +246,14 @@ export default { ...@@ -245,18 +246,14 @@ export default {
asyncmonitorList: "monitor/asyncList", asyncmonitorList: "monitor/asyncList",
}), }),
changerailWay() { changerailWay() {
this.stationSelect2 = this.stationlist.filter( this.stationSelect2 = this.stationlist.filter(
(item) => item.parentId === this.monitorForm.wayId (item) => item.parentId === this.monitorForm.wayId
); );
}, },
changesite() { changesite() {
this.fsuSelect2 = this.fsuSelect.filter( this.fsuSelect2 = this.fsuSelect.filter(
(item) => item.parentId === this.monitorForm.siteId (item) => item.parentId === this.monitorForm.siteId
); );
}, },
tableRowClassName({ row, rowIndex }) { tableRowClassName({ row, rowIndex }) {
return rowIndex % 2 === 0 ? "" : "single-row"; return rowIndex % 2 === 0 ? "" : "single-row";
...@@ -267,15 +264,14 @@ export default { ...@@ -267,15 +264,14 @@ export default {
delData() { delData() {
let ids = this.ids; let ids = this.ids;
monitorEquipbatchDelete({ ids }).then((res) => { monitorEquipbatchDelete({ ids }).then((res) => {
if (res.code==200) { if (res.code == 200) {
successAlert("删除成功"); successAlert("删除成功");
this.asyncmonitorList(); this.asyncmonitorList();
this.getTableData(); this.getTableData();
}else{ } else {
warningAlert("删除失败") warningAlert("删除失败");
} }
}); });
}, },
refresh() { refresh() {
this.getTableData(); this.getTableData();
...@@ -286,22 +282,18 @@ export default { ...@@ -286,22 +282,18 @@ export default {
this.multipleSelection = val; this.multipleSelection = val;
this.ids = this.multipleSelection.map((i) => i.id); this.ids = this.multipleSelection.map((i) => i.id);
}, },
handleView(row) { handleView(row) {
this.$router.push({ this.$router.push({
path:'/detail', path: "/detail",
query:{ query: {
id:row.id id: row.id,
type: 4,
}, },
})
let id = row.id;
monitorEquipdetail({ id }).then((res) => {
}); });
let id = row.id;
monitorEquipdetail({ id }).then((res) => {});
}, },
handlePageChange(pageData) { handlePageChange(pageData) {
this.params.pageSize = pageData.size; this.params.pageSize = pageData.size;
...@@ -309,16 +301,11 @@ export default { ...@@ -309,16 +301,11 @@ export default {
this.getTableData(); this.getTableData();
}, },
getTableData() { getTableData() {
// this.tableData2 = this.tableData.slice(( this.params.pageNum - 1) * this.params.pageSize,
// this.params.pageNum * this.params.pageSize
// );
// this.total = this.tableData.length
let params = { let params = {
current: this.params.pageNum, current: this.params.pageNum,
size: this.params.pageSize, size: this.params.pageSize,
}; };
monitorEquiplist(params).then((res) => { monitorEquiplist(params).then((res) => {
console.log(res.records);
let list = res.records || []; let list = res.records || [];
this.tableData = list; this.tableData = list;
this.total = res.total; this.total = res.total;
......
...@@ -11,17 +11,18 @@ ...@@ -11,17 +11,18 @@
>删除</el-button >删除</el-button
> >
<el-button type="primary" @click="refresh">刷新</el-button> <el-button type="primary" @click="refresh">刷新</el-button>
<el-button type="primary" @click="query">查询</el-button> <el-button type="primary" @click="query()">查询</el-button>
<el-button type="primary" @click="exportData">导出</el-button> <el-button type="primary" @click="exportData">导出</el-button>
</div> </div>
</div> </div>
<div> <div :class="block==0?'search-div' : 'none'">
<div class="search-input-box"> <div class="search-input-box">
<label>铁路名称:</label> <label>铁路名称:</label>
<el-input <el-input
size="small" size="small"
placeholder="请输入铁路名称" placeholder="请输入铁路名称"
style="width: 180px" style="width: 180px"
v-model="railData.name"
clearable clearable
> >
</el-input> </el-input>
...@@ -31,6 +32,7 @@ ...@@ -31,6 +32,7 @@
<el-input <el-input
size="small" size="small"
placeholder="请输入起点站名" placeholder="请输入起点站名"
v-model="railData.startPointName"
style="width: 180px" style="width: 180px"
clearable clearable
> >
...@@ -41,6 +43,7 @@ ...@@ -41,6 +43,7 @@
<el-input <el-input
size="small" size="small"
placeholder="请输入终点站名" placeholder="请输入终点站名"
v-model="railData.endPointName"
style="width: 180px" style="width: 180px"
clearable clearable
> >
...@@ -107,7 +110,7 @@ ...@@ -107,7 +110,7 @@
</template> </template>
<script> <script>
import Pagination from "@/components/Pagination"; import Pagination from "@/components/Pagination";
import { railWaylist,railWaydetail, railWaybatchDelete } from "../../api"; import { railWaylist, railWaydetail, railWaybatchDelete,roleAdd } from "../../api";
import { mapGetters, mapActions } from "vuex"; import { mapGetters, mapActions } from "vuex";
import { successAlert, warningAlert } from "@/utils/alert"; import { successAlert, warningAlert } from "@/utils/alert";
export default { export default {
...@@ -115,6 +118,13 @@ export default { ...@@ -115,6 +118,13 @@ export default {
components: { Pagination }, components: { Pagination },
data() { data() {
return { return {
railData: {
endPointName: "",
name: "ccc",
startPointName: "",
current: 1,
size:10
},
visible: false, visible: false,
Info: [], Info: [],
tableData: [], tableData: [],
...@@ -143,7 +153,7 @@ export default { ...@@ -143,7 +153,7 @@ export default {
railWaybatchDelete({ ids }).then((res) => { railWaybatchDelete({ ids }).then((res) => {
if (res.code == 200) { if (res.code == 200) {
successAlert("删除成功"); successAlert("删除成功");
this.asyncrailWayList() this.asyncrailWayList();
this.getTableData(); this.getTableData();
} else { } else {
warningAlert("删除失败"); warningAlert("删除失败");
...@@ -153,7 +163,11 @@ export default { ...@@ -153,7 +163,11 @@ export default {
refresh() { refresh() {
this.getTableData(); this.getTableData();
}, },
query() {}, query() {
this.getTableData();
},
exportData() {}, exportData() {},
handleSelectionChange(val) { handleSelectionChange(val) {
this.multipleSelection = val; this.multipleSelection = val;
...@@ -166,6 +180,7 @@ export default { ...@@ -166,6 +180,7 @@ export default {
path: "/detail", path: "/detail",
query: { query: {
id: row.id, id: row.id,
type: 1,
}, },
}); });
...@@ -181,11 +196,13 @@ export default { ...@@ -181,11 +196,13 @@ export default {
this.getTableData(); this.getTableData();
}, },
getTableData() { getTableData() {
let params = { let params = {
current: this.params.pageNum, current: this.params.pageNum,
size: this.params.pageSize, size: this.params.pageSize,
}; };
railWaylist(params).then((res) => { railWaylist(this.railData).then((res) => {
let list = res.records || []; let list = res.records || [];
this.tableData = list; this.tableData = list;
this.total = res.total; this.total = res.total;
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
>删除</el-button >删除</el-button
> >
<el-button type="primary" @click="refresh">刷新</el-button> <el-button type="primary" @click="refresh">刷新</el-button>
<el-button type="primary" @click="query">查询</el-button> <el-button type="primary" @click="query()">查询</el-button>
<el-button type="primary" @click="exportData">导出</el-button> <el-button type="primary" @click="exportData">导出</el-button>
</div> </div>
</div> </div>
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
size="small" size="small"
placeholder="请输入站名" placeholder="请输入站名"
style="width: 180px" style="width: 180px"
v-model="siteForm.siteName"
clearable clearable
> >
</el-input> </el-input>
...@@ -32,6 +33,7 @@ ...@@ -32,6 +33,7 @@
size="small" size="small"
placeholder="请输入起点编号" placeholder="请输入起点编号"
style="width: 180px" style="width: 180px"
v-model="siteForm.siteCode"
clearable clearable
> >
</el-input> </el-input>
...@@ -42,6 +44,7 @@ ...@@ -42,6 +44,7 @@
size="small" size="small"
placeholder="请输入站点地址" placeholder="请输入站点地址"
style="width: 180px" style="width: 180px"
v-model="siteForm.siteAddress"
clearable clearable
> >
</el-input> </el-input>
...@@ -52,6 +55,7 @@ ...@@ -52,6 +55,7 @@
size="small" size="small"
placeholder="请选择所在铁路线" placeholder="请选择所在铁路线"
style="width: 180px" style="width: 180px"
v-model="siteForm.wayId"
clearable clearable
> >
<el-option <el-option
...@@ -158,6 +162,15 @@ export default { ...@@ -158,6 +162,15 @@ export default {
components: { Pagination }, components: { Pagination },
data() { data() {
return { return {
siteForm: {
wayId: "",
siteCode: "",
siteName: "委屈",
siteAddress: "",
siteId:'',
current: 1,
size:10,
},
railWaySelect: [], railWaySelect: [],
visible: false, visible: false,
Info: [], Info: [],
...@@ -202,7 +215,16 @@ export default { ...@@ -202,7 +215,16 @@ export default {
refresh() { refresh() {
this.getTableData(); this.getTableData();
}, },
query() {}, query() {
// sitelist(this.siteForm).then((res) => {
// console.log(this.siteForm);
// console.log(res.records);
// let list = res.records || [];
// this.tableData = list;
// this.total = res.total;
// });
this.getTableData();
},
exportData() {}, exportData() {},
handleSelectionChange(val) { handleSelectionChange(val) {
this.multipleSelection = val; this.multipleSelection = val;
...@@ -212,16 +234,14 @@ export default { ...@@ -212,16 +234,14 @@ export default {
handleView(row) { handleView(row) {
this.$router.push({ this.$router.push({
path: "/sitedetail", path: "/detail",
query: { query: {
id: row.id, id: row.id,
type: 2,
}, },
}); });
// let id = row.id; let id = row.id;
// sitedetail({ id }).then((res) => { sitedetail({ id }).then((res) => {});
// this.Info = res;
// this.visible = true;
// });
}, },
handlePageChange(pageData) { handlePageChange(pageData) {
this.params.pageSize = pageData.size; this.params.pageSize = pageData.size;
...@@ -229,10 +249,9 @@ export default { ...@@ -229,10 +249,9 @@ export default {
this.getTableData(); this.getTableData();
}, },
getTableData() { getTableData() {
let params = { console.log(123);
current: this.params.pageNum, let params = this.siteForm
size: this.params.pageSize,
};
sitelist(params).then((res) => { sitelist(params).then((res) => {
let list = res.records || []; let list = res.records || [];
this.tableData = list; this.tableData = list;
......
<template> <template>
<div class="dashboard-container">
<!-- 首页 -->
<header class="header_title">{{titleinfo}}</header>
<el-row :gutter="24">
<el-col :span="12" v-for="item in listData" class="mb20">
<el-card shadow="never">
<div slot="header" class="clearfix posa">
<span>{{ item.title }}</span>
<el-button v-if="item.option" style="float: right; padding: 3px 0;margin-right:20px" type="text" class="savebtn">保存</el-button>
</div>
<div v-for="k in item.list" :key="k.name" :class="item.list.length<=2? 'text2' : 'text'">
<el-row :gutter="24">
<el-col :span="10">
<div class="item_name">{{ k.name }}</div>
</el-col>
<el-col :span="10">
<div v-if="item.option">
<el-input v-model="k.value" clearable placeholder="请输入内容">{{ k.value }}</el-input>
</div>
<el-row :gutter="20" v-else-if="k.handle">
<el-col :span="10" class="value_handle">{{ k.value }}</el-col>
<el-col :span="10"><el-button class="alarmbtn" type="primary" size="mini">处理告警</el-button></el-col>
</el-row>
<div class="item_data" v-else>{{ k.value }}</div>
</el-col>
</el-row>
</div>
</el-card>
</el-col>
</el-row>
<div> <div>
<type :type="type" :curInfo="curInfo" />
</div>
</div> </div>
</template> </template>
<script> <script>
import { mapGetters, mapActions } from "vuex"; import { treeBaseInfo } from "../../dashboard/api";
import { railWaydetail,sitedetail,fsudetail,monitorEquipdetail } from "../api"; import Type from "../../dashboard/components/index.vue";
export default { export default {
props: [], props: [],
components: {}, components: { Type },
data() { data() {
return { return {
titleinfo:'', titleinfo: "",
listData2: [],
listData : [
{
title: '服务器信息',
list: [
{
name: '服务器IP',
value: '192.168.1.110',
},
{
name: '操作系统',
value: 'Red Hat EnterpiseLin...',
},
{
name: '系统软件版本',
value: '192.168.1.110',
},
]
},
{
title: '当前状态',
list: [
{
handle: true,
name: '设备状态',
value: '告警',
},
{
handle: true,
name: '漏缆状态',
value: '紧急告警',
}
]
},
{
title: '管理员(admin)管理范围',
list: [
{
name: '基站',
value: '20个',
},
{
name: 'FSU',
value: '20台',
},
{
name: '监测设备',
value: '81台',
},
{
name: '混缆',
value: '142根',
},
]
},
{
title: '基本信息',
option: true,
list: [
{
name: '铁路名称',
value: '张呼铁路客运专线',
},
{
name: '铁路起点站名',
value: '张家口',
},
{
name: '铁路终点站名',
value: '呼和浩特',
},
{
name: '铁路总长度(公里)',
value: '286.8',
},
]
},
], type: 1,
id: "", curInfo: {},
listData: [],
}; };
}, },
computed: { computed: {},
...mapGetters({}),
},
methods: {
...mapActions({}),
},
methods: { methods: {
getParams() { getParams() {
this.id = this.$route.query.id; this.type = this.$route.query.type;
// console.log(this.id); let params = {
railWaydetail({ id: this.id }).then((res) => { id: this.$route.query.id,
type: this.type,
};
this.titleinfo=res.name + '信息' treeBaseInfo(params).then((res) => {
this.listData[3].list[0].value=res.name let controlLimit = res.controlLimit;
this.listData[3].list[1].value=res.startPointName controlLimit.map((item) => {
this.listData[3].list[2].value=res.endPointName res[`type${item.type}`] = item.sum;
this.listData[3].list[3].value=res.totalLong });
this.curInfo = res;
}); });
}, },
}, },
...@@ -153,116 +42,3 @@ export default { ...@@ -153,116 +42,3 @@ export default {
mounted() {}, mounted() {},
}; };
</script> </script>
<style lang="scss" scoped>
.header_title {
font-size: 23px;
font-family: Source Han Sans CN;
font-weight: 500;
line-height: 40px;
text-align: center;
color: #0058ff;
letter-spacing: 10px;
opacity: 1;
margin-bottom: 20px;
}
::v-deep.el-card {
border: 1px solid #e3e3e3;
border-radius: 8px;
min-height: 243px;
.el-card__header {
font-size: 18px;
color: #333333;
font-weight: 500;
text-align: center;
background: rgba(226, 235, 255, 0.39);
opacity: 1;
}
.el-card__body {
padding: 0px;
}
}
.posa {
position: relative;
}
.savebtn {
position: absolute;
right: 2%;
}
// .el-col {
// margin-bottom: 20px;
// }
.text {
// display: flex;
padding: 10px 20px 10px 20px;
border-bottom: 1px solid #e3e3e3;
&:last-child {
border-bottom: none;
}
.item_name,
.item_data,
.value_handle {
height: 16px;
line-height: 16px;
margin-top: 12px;
margin-bottom: 12px;
}
.item_name {
width: 262px;
height: 16px;
line-height: 16px;
color: #7e7e7e;
margin-top: 12px;
margin-bottom: 12px;
}
.item_data {
}
.value_handle {
color: red;
margin-right: 10px;
}
.alarmbtn {
margin-top: 6px;
margin-bottom: 6px;
}
.el-card:last-child .text {
border-bottom: none !important;
}
}
.text2 {
// display: flex;
padding: 10px 20px 10px 20px;
border-bottom: 1px solid #e3e3e3;
.item_name,
.item_data,
.value_handle {
height: 16px;
line-height: 16px;
margin-top: 12px;
margin-bottom: 12px;
}
.item_name {
width: 262px;
height: 16px;
line-height: 16px;
color: #7e7e7e;
margin-top: 12px;
margin-bottom: 12px;
}
.item_data {
}
.value_handle {
color: red;
margin-right: 10px;
min-width: 52px;
}
.alarmbtn {
margin-top: 6px;
margin-bottom: 6px;
}
.el-card:last-child .text {
border-bottom: none !important;
}
}
</style>
...@@ -32,7 +32,14 @@ import { ...@@ -32,7 +32,14 @@ import {
sitelist, sitelist,
} from "../api"; } from "../api";
export default { export default {
components: { Pagination, railWayTable, stationTable,fsuTable,monitorTable,leakyTable }, components: {
Pagination,
railWayTable,
stationTable,
fsuTable,
monitorTable,
leakyTable,
},
data() { data() {
return { return {
params: { params: {
...@@ -68,9 +75,7 @@ export default { ...@@ -68,9 +75,7 @@ export default {
}, },
], ],
tableData2: [], tableData2: [],
tableData: [ tableData: [],
],
multipleSelection: [], multipleSelection: [],
ids: [], ids: [],
}; };
...@@ -86,14 +91,8 @@ export default { ...@@ -86,14 +91,8 @@ export default {
refresh() {}, refresh() {},
query() {}, query() {},
exportData() {}, exportData() {},
},
mounted() {
}, },
mounted() {},
}; };
</script> </script>
......
<template>
<div class="dashboard-container">
<!-- 首页 -->
<header class="header_title">{{titleinfo}}</header>
<el-row :gutter="24">
<el-col :span="12" v-for="item in listData" class="mb20">
<el-card shadow="never">
<div slot="header" class="clearfix posa">
<span>{{ item.title }}</span>
<el-button v-if="item.option" style="float: right; padding: 3px 0;margin-right:20px" type="text" class="savebtn">保存</el-button>
</div>
<div v-for="k in item.list" :key="k.name" :class="item.list.length<=2? 'text2' : 'text'">
<el-row :gutter="24">
<el-col :span="10">
<div class="item_name">{{ k.name }}</div>
</el-col>
<el-col :span="10">
<div v-if="item.option">
<el-input v-model="k.value" clearable placeholder="请输入内容">{{ k.value }}</el-input>
</div>
<el-row :gutter="20" v-else-if="k.handle">
<el-col :span="10" class="value_handle">{{ k.value }}</el-col>
<el-col :span="10"><el-button class="alarmbtn" type="primary" size="mini">处理告警</el-button></el-col>
</el-row>
<div class="item_data" v-else>{{ k.value }}</div>
</el-col>
</el-row>
</div>
</el-card>
</el-col>
</el-row>
<div>
</div>
</div>
</template>
<script>
import {mapGetters,mapActions} from 'vuex';
import { sitedetail } from "../api";
export default {
props: [],
components: {},
data() {
return {
titleinfo:'',
id: "",
listData : [
{
title: '管理范围',
list: [
{
name: 'FSU',
value: '1台',
},
{
name: '监测设备',
value: '1台',
},
{
name: '漏缆',
value: '2根',
},
]
},
{
title: '基本信息',
option: true,
list: [
{
name: '站点编号',
value: '',
},
{
name: '站名',
value: '',
}, {
name: '站点地址',
value: '',
}, {
name: '所在铁路线',
value: '',
}, {
name: '站点所在局',
value: '',
},
{
name: '站点所在段号',
value: '',
}, {
name: '站点所在铁路公里标',
value: '',
}, {
name: '站点经度',
value: '',
}, {
name: '站点纬度',
value: '',
}, {
name:'站点监控时间',
value: '',
},
{
name:'站点其他信息',
value: '',
},
]
},
{
title: '当前状态',
list: [
{
handle: true,
name: '设备状态',
value: '正常',
},
{
handle: true,
name: '漏缆状态',
value: '正常',
}
]
},
],
};
},
computed: {
...mapGetters({}),
},
methods: {
...mapActions({}),
getParams() {
this.id = this.$route.query.id;
sitedetail({ id: this.id }).then((res) => {
this.titleinfo='站点(' + res.siteName + ")"
this.listData[1].list[0].value=res.siteCode
this.listData[1].list[1].value=res.siteName
this.listData[1].list[2].value=res.siteAddress
this.listData[1].list[3].value=res.siteArea
this.listData[1].list[4].value=res.wayId
this.listData[1].list[5].value=res.siteSectionCode
this.listData[1].list[6].value=res.siteKmSign
this.listData[1].list[7].value=res.siteLatitude
this.listData[1].list[8].value=res.siteLongitude
this.listData[1].list[10].value=res.siteOtherMessage
});
},
},
created() {
this.getParams();
},
mounted() {},
};
</script>
<style lang="scss" scoped>
.header_title {
font-size: 23px;
font-family: Source Han Sans CN;
font-weight: 500;
line-height: 40px;
text-align: center;
color: #0058ff;
letter-spacing: 10px;
opacity: 1;
margin-bottom: 20px;
}
::v-deep.el-card {
border: 1px solid #e3e3e3;
border-radius: 8px;
min-height: 243px;
.el-card__header {
font-size: 18px;
color: #333333;
font-weight: 500;
text-align: center;
background: rgba(226, 235, 255, 0.39);
opacity: 1;
}
.el-card__body {
padding: 0px;
}
}
.posa {
position: relative;
}
.savebtn {
position: absolute;
right: 2%;
}
// .el-col {
// margin-bottom: 20px;
// }
.text {
// display: flex;
padding: 10px 20px 10px 20px;
border-bottom: 1px solid #e3e3e3;
&:last-child {
border-bottom: none;
}
.item_name,
.item_data,
.value_handle {
height: 16px;
line-height: 16px;
margin-top: 12px;
margin-bottom: 12px;
}
.item_name {
width: 262px;
height: 16px;
line-height: 16px;
color: #7e7e7e;
margin-top: 12px;
margin-bottom: 12px;
}
.item_data {
}
.value_handle {
color: red;
margin-right: 10px;
}
.alarmbtn {
margin-top: 6px;
margin-bottom: 6px;
}
.el-card:last-child .text {
border-bottom: none !important;
}
}
.text2 {
// display: flex;
padding: 10px 20px 10px 20px;
border-bottom: 1px solid #e3e3e3;
.item_name,
.item_data,
.value_handle {
height: 16px;
line-height: 16px;
margin-top: 12px;
margin-bottom: 12px;
}
.item_name {
width: 262px;
height: 16px;
line-height: 16px;
color: #7e7e7e;
margin-top: 12px;
margin-bottom: 12px;
}
.item_data {
}
.value_handle {
color: red;
margin-right: 10px;
min-width: 52px;
}
.alarmbtn {
margin-top: 6px;
margin-bottom: 6px;
}
.el-card:last-child .text {
border-bottom: none !important;
}
}
</style>
\ No newline at end of file
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