修复BUG

This commit is contained in:
aixianling
2023-09-11 11:08:13 +08:00
parent 7aa9601f22
commit 568ffbb825
3 changed files with 70 additions and 56 deletions

2
.npmrc
View File

@@ -1,5 +1,5 @@
registry=http://192.168.1.87:4873/ registry=http://192.168.1.87:4873/
email=aixianling@sinoecare.com email=aixianling@sinoecare.com
always-auth=true always-auth=true
_auth="YWRtaW46YWRtaW4xMjM="
package-lock=false package-lock=false
//192.168.1.87:4873/:_auth="YWRtaW46YWRtaW4xMjM="

View File

@@ -87,6 +87,7 @@ export default {
this.$http.post(url, null, {params}).then((res) => { this.$http.post(url, null, {params}).then((res) => {
if (res?.data) { if (res?.data) {
let parents = res.data.map(e => e.parentGirdId) let parents = res.data.map(e => e.parentGirdId)
console.log(parents)
this.allData = res.data.map(e => ({...e, hasChildren: parents.includes(e.id)})) this.allData = res.data.map(e => ({...e, hasChildren: parents.includes(e.id)}))
this.treeInit() this.treeInit()
if (this.$route.query.selected) { //确认按钮弹窗报错 if (this.$route.query.selected) { //确认按钮弹窗报错
@@ -106,7 +107,10 @@ export default {
params: {girdId: last} params: {girdId: last}
}).then(res => { }).then(res => {
if (res?.data) { if (res?.data) {
this.selectList = [{girdName: '可选范围', id: ''}, res.data.filter(e => !!this.allData.find(a => a.id == e.id))].flat() this.selectList = [{
girdName: '可选范围',
id: ''
}, res.data.filter(e => !!this.allData.find(a => a.id == e.id))].flat()
this.getGridsByGridMemberAndParent({id: last}) this.getGridsByGridMemberAndParent({id: last})
} }
}) })
@@ -138,7 +142,7 @@ export default {
this.selectList = [] this.selectList = []
this.treeInit(true) this.treeInit(true)
} else { } else {
this.selectList.splice(index, 8) this.selectList.splice(index + 1, 8)
this.getGridsByGridMemberAndParent(row) this.getGridsByGridMemberAndParent(row)
} }
}, },

View File

@@ -2,15 +2,9 @@
<div class="statistics"> <div class="statistics">
<AiTopFixed> <AiTopFixed>
<div class="select-gird"> <div class="select-gird">
<!-- <AiPagePicker type="gird" v-model="selectGird" valueObj nodeKey="id" class="right-span" @change="handleSelectGird" <AiPagePicker type="gird" valueObj nodeKey="id" formType="2" @select="handleSelectGird" class="right-span"
action="/app/apppatrolreportinfo/listByInfo"> action="/app/apppatrolreportinfo/listByInfo">
<AiMore v-model="selectGird.girdName"/>
</AiPagePicker> -->
<AiPagePicker type="gird" valueObj nodeKey="id" formType="2" @select="handleSelectGird" class="right-span" action="/app/appgirdmemberinfo/queryMyGirdList">
<AiMore v-model="selectGird.girdName" icon="arrow-right" placeholder="选择网格"/> <AiMore v-model="selectGird.girdName" icon="arrow-right" placeholder="选择网格"/>
<!-- <span :class="searchGrid.girdName ? 'grid-name' : 'grid-name color-999'">{{searchGrid.girdName || '所属网格'}}</span>
<u-icon name="close-circle" color="#999" size="34" style="margin-left: 4px" v-if="searchGrid.girdName" @click.stop="clearGrid" />
<u-icon name="arrow-down" color="#999" size="24" style="margin-left: 4px" v-else /> -->
</AiPagePicker> </AiPagePicker>
</div> </div>
</AiTopFixed> </AiTopFixed>
@@ -40,7 +34,8 @@
<div class="info-content"> <div class="info-content">
<div class="title">巡查事件分类 <div class="title">巡查事件分类
<!-- <div class="type-select" :style="statusInfo.name ? '' : 'color:#999;'" @click="show=true">{{statusInfo.name || '请选择'}}<u-icon name="arrow-right"></u-icon></div> --> <!-- <div class="type-select" :style="statusInfo.name ? '' : 'color:#999;'" @click="show=true">{{statusInfo.name || '请选择'}}<u-icon name="arrow-right"></u-icon></div> -->
<u-select v-model="show" :list="$dict.getDict('clapEventStatusHistory')" value-name="dictValue" label-name="dictName" @confirm="selectStatus"></u-select> <u-select v-model="show" :list="$dict.getDict('clapEventStatusHistory')" value-name="dictValue"
label-name="dictName" @confirm="selectStatus"></u-select>
</div> </div>
<AiEmpty v-if="!typeData.length"></AiEmpty> <AiEmpty v-if="!typeData.length"></AiEmpty>
<div class="echart-content" id="type" v-else></div> <div class="echart-content" id="type" v-else></div>
@@ -53,6 +48,7 @@
<script> <script>
import {mapState} from 'vuex' import {mapState} from 'vuex'
import echarts from 'echarts' import echarts from 'echarts'
export default { export default {
props: {}, props: {},
data() { data() {
@@ -325,21 +321,25 @@ export default {
.statstics-content { .statstics-content {
padding: 30px 30px 0; padding: 30px 30px 0;
} }
::v-deep .AiTopFixed { ::v-deep .AiTopFixed {
.content { .content {
background-color: #3975C6; background-color: #3975C6;
color: #fff; color: #fff;
} }
.icon-img { .icon-img {
width: 48px; width: 48px;
height: 48px; height: 48px;
} }
} }
::v-deep .AiMore { ::v-deep .AiMore {
span { span {
color: #fff; color: #fff;
} }
} }
.info-content { .info-content {
width: 100%; width: 100%;
background: #FFF; background: #FFF;
@@ -347,6 +347,7 @@ export default {
margin-bottom: 24px; margin-bottom: 24px;
position: relative; position: relative;
padding-bottom: 32px; padding-bottom: 32px;
.title { .title {
font-size: 32px; font-size: 32px;
font-family: PingFangSC-Regular, PingFang SC; font-family: PingFangSC-Regular, PingFang SC;
@@ -354,11 +355,13 @@ export default {
color: #333; color: #333;
line-height: 48px; line-height: 48px;
padding: 24px 16px 24px 24px; padding: 24px 16px 24px 24px;
img { img {
float: right; float: right;
width: 40px; width: 40px;
height: 40px; height: 40px;
} }
.type-select { .type-select {
font-size: 26px; font-size: 26px;
position: absolute; position: absolute;
@@ -369,12 +372,15 @@ export default {
line-height: 48px; line-height: 48px;
} }
} }
.el-row { .el-row {
display: flex; display: flex;
padding: 32px 0 60px 0; padding: 32px 0 60px 0;
.item { .item {
flex: 1; flex: 1;
text-align: center; text-align: center;
h2 { h2 {
font-size: 64px; font-size: 64px;
font-family: DINAlternate-Bold, DINAlternate; font-family: DINAlternate-Bold, DINAlternate;
@@ -383,6 +389,7 @@ export default {
line-height: 64px; line-height: 64px;
margin-bottom: 8px; margin-bottom: 8px;
} }
p { p {
font-size: 28px; font-size: 28px;
font-family: PingFangSC-Regular, PingFang SC; font-family: PingFangSC-Regular, PingFang SC;
@@ -391,10 +398,12 @@ export default {
} }
} }
} }
.echart-content { .echart-content {
width: 100%; width: 100%;
height: 500px; height: 500px;
} }
.num { .num {
position: absolute; position: absolute;
left: 50%; left: 50%;
@@ -406,6 +415,7 @@ export default {
text-align: center; text-align: center;
} }
} }
.pad-b120 { .pad-b120 {
background-color: #F3F7F8; background-color: #F3F7F8;
padding-bottom: 120px; padding-bottom: 120px;