Compare commits
No commits in common. "359115ccf8bfdf2b824164b493952509b4875f0f" and "f368998a6d8a353cb9acf0f8c11ad6cbe481e941" have entirely different histories.
359115ccf8
...
f368998a6d
|
@ -1,21 +1,6 @@
|
|||
<template>
|
||||
<el-card shadow="never" class="aui-card--fill">
|
||||
<div class="mod-ability__bsabilityai">
|
||||
<div class="second-title">
|
||||
<div
|
||||
|
||||
:class="[choose === 0 ? 'departmentStyle' : 'departmentStyle1']"
|
||||
@click="handleChose(0)"
|
||||
>
|
||||
市级领域场景
|
||||
</div>
|
||||
<div
|
||||
:class="[choose === 1 ? 'departmentStyle' : 'departmentStyle1']"
|
||||
@click="handleChose(1)"
|
||||
>
|
||||
基层场景
|
||||
</div>
|
||||
</div>
|
||||
<el-form :inline="true" :model="dataForm">
|
||||
<el-form-item>
|
||||
<el-input v-model="dataForm.name" placeholder="名称" clearable></el-input>
|
||||
|
@ -55,36 +40,21 @@
|
|||
</el-pagination>
|
||||
|
||||
<!-- 弹窗, 新增 / 修改 -->
|
||||
<!-- <add-update-scene v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="query" @closeModal="closeModal"
|
||||
<add-update-scene v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="query" @closeModal="closeModal"
|
||||
:addOrUpdateVisible="addOrUpdateVisible" :modalType="modalType">
|
||||
</add-update-scene> -->
|
||||
<!-- 市级挂接 -->
|
||||
<city-add v-if="cityVisible" ref="cityAdd" @refreshDataList="query" @closeModal="closeModal"
|
||||
:cityVisible="cityVisible" :modalType="modalType">
|
||||
</city-add>
|
||||
<!--基层挂架-->
|
||||
<area-add v-if="areaVisible" ref="areaAdd" @refreshDataList="query" @closeModal="closeModal"
|
||||
:areaVisible="areaVisible" :modalType="modalType">
|
||||
</area-add>
|
||||
</add-update-scene>
|
||||
</div>
|
||||
</el-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import mixinViewModule from "@/mixins/view-module";
|
||||
import AddUpdateScene from "./add-update-scene";
|
||||
|
||||
import cityAdd from "./city-add";
|
||||
import areaAdd from "./area-add";
|
||||
export default {
|
||||
mixins: [mixinViewModule],
|
||||
data() {
|
||||
return {
|
||||
//市级挂接
|
||||
cityVisible:false,
|
||||
//基层挂接
|
||||
areaVisible:false,
|
||||
//tab切换
|
||||
choose: 0,
|
||||
tableData: [],
|
||||
childName: '',
|
||||
mixinViewModuleOptions: {
|
||||
|
@ -99,27 +69,20 @@ export default {
|
|||
name: "",
|
||||
order: 'desc',
|
||||
orderField: 'create_date',
|
||||
type: '赋能场景',
|
||||
district: 0//0市级 1基层
|
||||
|
||||
type: '赋能场景'
|
||||
},
|
||||
qp: false,
|
||||
modalType: 'add',
|
||||
};
|
||||
},
|
||||
components: {
|
||||
areaAdd,
|
||||
cityAdd
|
||||
AddUpdateScene,
|
||||
},
|
||||
mounted() {
|
||||
window.addEventListener("resize", this.a);
|
||||
this.fullScreen();
|
||||
},
|
||||
methods: {
|
||||
handleChose(index) {
|
||||
this.choose = index;
|
||||
this.searchData()
|
||||
},
|
||||
deleteRow(id) {
|
||||
this.$confirm('确认是否删除?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
|
@ -149,7 +112,6 @@ export default {
|
|||
},
|
||||
// 查询
|
||||
searchData() {
|
||||
this.dataForm.district=this.choose
|
||||
this.query()
|
||||
},
|
||||
// 重置
|
||||
|
@ -159,36 +121,20 @@ export default {
|
|||
},
|
||||
// 修改
|
||||
handleUpdate(val) {
|
||||
if(this.choose==0){
|
||||
this.cityVisible=true
|
||||
}else{
|
||||
this.areaVisible=true
|
||||
}
|
||||
|
||||
this.addOrUpdateVisible = true;
|
||||
this.modalType = 'update';
|
||||
const cloneVal = JSON.parse(JSON.stringify(val))
|
||||
this.$nextTick(() => {
|
||||
if(this.choose==0){
|
||||
this.$refs.cityAdd.getDetail(cloneVal)
|
||||
}else{
|
||||
this.$refs.areaAdd.getDetail(cloneVal)
|
||||
}
|
||||
|
||||
this.$refs.addOrUpdate.getDetail(cloneVal)
|
||||
})
|
||||
},
|
||||
// 挂接
|
||||
addServe() {
|
||||
//this.addOrUpdateVisible = true
|
||||
this.addOrUpdateVisible = true
|
||||
this.modalType = 'add';
|
||||
if(this.choose===0){
|
||||
this.cityVisible=true
|
||||
}else{
|
||||
this.areaVisible=true
|
||||
}
|
||||
},
|
||||
closeModal() {
|
||||
this.cityVisible = false;
|
||||
this.areaVisible=false;
|
||||
this.addOrUpdateVisible = false;
|
||||
},
|
||||
// 详情
|
||||
showDetail(val) {
|
||||
|
@ -218,32 +164,6 @@ export default {
|
|||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.second-title {
|
||||
margin-bottom: 16px;
|
||||
font-size: 14px;
|
||||
cursor: pointer;
|
||||
text-align: center;
|
||||
width: 100%;
|
||||
height: 32px;
|
||||
line-height: 32px;
|
||||
background: rgb(0,0,0,0.03);
|
||||
border-bottom: 1px solid #d9d9d9;
|
||||
}
|
||||
|
||||
.departmentStyle {
|
||||
float: left;
|
||||
width: 100px;
|
||||
color: #0058e1;
|
||||
background-color: #fff;
|
||||
border-right: 1px solid #d9d9d9;
|
||||
border-left: 1px solid #d9d9d9;
|
||||
border-top: 1px solid #d9d9d9;
|
||||
}
|
||||
.departmentStyle1 {
|
||||
|
||||
float: left;
|
||||
width: 100px;
|
||||
}
|
||||
.el-tooltip__popper {
|
||||
max-width: 50%;
|
||||
}
|
||||
|
|
|
@ -181,7 +181,6 @@
|
|||
<el-table-column prop="yyzy" label="应用资源" min-width="100%">
|
||||
</el-table-column>
|
||||
<el-table-column prop="count" label="总计" min-width="100%">
|
||||
<el-table-column prop="count" label="总计" min-width="100%">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<el-table :data="tableData" :header-cell-style="{ textAlign: 'center' }" :cell-style="{ textAlign: 'center' }"
|
||||
|
@ -207,7 +206,6 @@
|
|||
<el-table-column prop="ysp" label="云视频" min-width="100%" >
|
||||
</el-table-column>
|
||||
<el-table-column prop="count" label="总计" min-width="100%">
|
||||
<el-table-column prop="count" label="总计" min-width="100%">
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--明细表-->
|
||||
|
@ -508,51 +506,50 @@ export default {
|
|||
})
|
||||
.then((res) => {
|
||||
if (res.data.code !== 0) {
|
||||
this.tableData =[]
|
||||
this.tableDataClone = []
|
||||
this.total = 0
|
||||
return this.$message.error("服务器内部异常")
|
||||
|
||||
}else{
|
||||
const result = res.data.data
|
||||
for (let i = 0; i < result.length; i++) {
|
||||
if (!result[i].hasOwnProperty('yyzy')) {
|
||||
result[i].yyzy = 0
|
||||
this.tableData = []
|
||||
this.tableDataClone = []
|
||||
this.total = 0
|
||||
return this.$message.error('服务器内部异常')
|
||||
} else {
|
||||
const result = res.data.data
|
||||
for (let i = 0; i < result.length; i++) {
|
||||
if (!result[i].hasOwnProperty('yyzy')) {
|
||||
result[i].yyzy = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('kfzj')) {
|
||||
result[i].kfzj = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('znsf')) {
|
||||
result[i].znsf = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('tcfw')) {
|
||||
result[i].tcfw = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('ywzj')) {
|
||||
result[i].ywzj = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('hys')) {
|
||||
result[i].hys = 0
|
||||
}
|
||||
// result[i].zj =
|
||||
// parseInt(result[i].yyzy) +
|
||||
// parseInt(result[i].kfzj) +
|
||||
// parseInt(result[i].znsf) +
|
||||
// parseInt(result[i].ywzj) +
|
||||
// parseInt(result[i].tcfw) +
|
||||
// parseInt(result[i].hys)
|
||||
}
|
||||
if (!result[i].hasOwnProperty('kfzj')) {
|
||||
result[i].kfzj = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('znsf')) {
|
||||
result[i].znsf = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('tcfw')) {
|
||||
result[i].tcfw = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('ywzj')) {
|
||||
result[i].ywzj = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('hys')) {
|
||||
result[i].hys = 0
|
||||
}
|
||||
result[i].zj =
|
||||
parseInt(result[i].yyzy) +
|
||||
parseInt(result[i].kfzj) +
|
||||
parseInt(result[i].znsf) +
|
||||
parseInt(result[i].ywzj) +
|
||||
parseInt(result[i].tcfw) +
|
||||
parseInt(result[i].hys)
|
||||
this.tableData = res.data.data
|
||||
this.tableDataClone = res.data.data
|
||||
this.total = res.data.data.total
|
||||
this.exportExcelCondition = qs.stringify({
|
||||
approveStatus: this.status,
|
||||
deptId: this.abilityDepartment,
|
||||
startDate: this.startDate,
|
||||
endDate: this.endDate,
|
||||
resourceName: this.resourceName
|
||||
})
|
||||
}
|
||||
this.tableData = res.data.data
|
||||
this.tableDataClone = res.data.data
|
||||
this.total = res.data.data.total
|
||||
this.exportExcelCondition = qs.stringify({
|
||||
approveStatus: this.status,
|
||||
deptId: this.abilityDepartment,
|
||||
startDate: this.startDate,
|
||||
endDate: this.endDate,
|
||||
resourceName: this.resourceName
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
// 组件服务部门使用情况列表-改为能力使用统计
|
||||
|
@ -583,23 +580,54 @@ export default {
|
|||
})
|
||||
.then((res) => {
|
||||
if (res.data.code !== 0) {
|
||||
this.tableData =[]
|
||||
this.tableDataClone = []
|
||||
this.total = 0
|
||||
return this.$message.error("服务器内部异常")
|
||||
|
||||
}else{
|
||||
const result = res.data.data
|
||||
|
||||
this.tableData = res.data.data
|
||||
this.tableDataClone = res.data.data
|
||||
this.total = res.data.data.total
|
||||
this.exportExcelCondition = qs.stringify({
|
||||
approveStatus: this.status,
|
||||
deptId: this.abilityDepartment,
|
||||
startDate: this.startDate,
|
||||
endDate: this.endDate,
|
||||
resourceName: this.resourceName
|
||||
this.tableData = []
|
||||
this.tableDataClone = []
|
||||
this.total = 0
|
||||
return this.$message.error('服务器内部异常')
|
||||
} else {
|
||||
const result = res.data.data
|
||||
for (let i = 0; i < result.length; i++) {
|
||||
if (!result[i].hasOwnProperty('yyzy')) {
|
||||
result[i].yyzy = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('kfzj')) {
|
||||
result[i].kfzj = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('znsf')) {
|
||||
result[i].znsf = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('tcfw')) {
|
||||
result[i].tcfw = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('ywzj')) {
|
||||
result[i].ywzj = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('hys')) {
|
||||
result[i].hys = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('yzy')) {
|
||||
result[i].yzy = 0
|
||||
}
|
||||
if (!result[i].hasOwnProperty('ysp')) {
|
||||
result[i].ysp = 0
|
||||
}
|
||||
// result[i].zj =
|
||||
// parseInt(result[i].yyzy) +
|
||||
// parseInt(result[i].kfzj) +
|
||||
// parseInt(result[i].znsf) +
|
||||
// parseInt(result[i].ywzj) +
|
||||
// parseInt(result[i].tcfw) +
|
||||
// parseInt(result[i].hys)
|
||||
}
|
||||
this.tableData = res.data.data
|
||||
this.tableDataClone = res.data.data
|
||||
this.total = res.data.data.total
|
||||
this.exportExcelCondition = qs.stringify({
|
||||
approveStatus: this.status,
|
||||
deptId: this.abilityDepartment,
|
||||
startDate: this.startDate,
|
||||
endDate: this.endDate,
|
||||
resourceName: this.resourceName
|
||||
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue