Browse Source

添加搜索条件

master
wwp 1 month ago
parent
commit
d43c7d4fda
1 changed files with 38 additions and 12 deletions
  1. +38
    -12
      monitorMobile/pages/earlyWarning/index.vue

+ 38
- 12
monitorMobile/pages/earlyWarning/index.vue View File

@@ -55,6 +55,19 @@
</view> </view>
</u-col> </u-col>
</u-row> </u-row>
<u-row style="margin-top:10px;" justify="space-between" gutter="10">
<u-col span="12">
<view class="demo-layout" @click="toOpenmanjor">
<view class="left-layout">
<text>{{searchForm.$cameraId || '预警摄像头'}}</text>
</view>
<view class="right-layout">
<image style="width: 30rpx;height:30rpx;"
src="@/static/image/earlyWarning/arrowRight.png" mode=""></image>
</view>
</view>
</u-col>
</u-row>
<u-row style="margin-top:10px;" justify="space-between" gutter="10"> <u-row style="margin-top:10px;" justify="space-between" gutter="10">
<u-col span="12"> <u-col span="12">
<uni-datetime-picker v-model="searchForm.tick" type="datetimerange"> <uni-datetime-picker v-model="searchForm.tick" type="datetimerange">
@@ -88,7 +101,8 @@


</view> </view>
<view class="tableBox"> <view class="tableBox">
<u-empty marginTop="100rpx" :show="warnList.length == 0&&status == 'nomore'" mode="list" text="暂无数据"></u-empty>
<u-empty marginTop="100rpx" :show="warnList.length == 0&&status == 'nomore'" mode="list"
text="暂无数据"></u-empty>
<!-- <u-pull-refresh :refreshing="refreshing" @refresh="onRefresh"> --> <!-- <u-pull-refresh :refreshing="refreshing" @refresh="onRefresh"> -->
<!-- <scroll-view class="scroll-view" scroll-y="true" refresher-enabled="true" <!-- <scroll-view class="scroll-view" scroll-y="true" refresher-enabled="true"
@refresher-pull="onRefresh" @refresher-refresh="doRefresh" @refresher-restore="restore" @refresher-pull="onRefresh" @refresher-refresh="doRefresh" @refresher-restore="restore"
@@ -172,9 +186,12 @@
<!-- </scroll-view> --> <!-- </scroll-view> -->
<!-- </u-pull-refresh> --> <!-- </u-pull-refresh> -->
</view> </view>
<selectSearch ref="selectSearchBox" :cellVisible="false"
v-model="searchForm.alarmType" :options="warnOption" :title.sync="searchForm.$alarmType"
placeholder="预警类型" search-placeholder="预警类型" />
<selectSearch ref="selectSearchBox" :cellVisible="false" v-model="searchForm.alarmType"
:options="warnOption" :title.sync="searchForm.$alarmType" placeholder="预警类型"
search-placeholder="预警类型" />
<selectSearch ref="selectmanjorBox" :cellVisible="false" v-model="searchForm.cameraId"
:options="[{value:'',label:'全部'},...allOptions.monitorList]" :title.sync="searchForm.$cameraId" placeholder="预警摄像头"
search-placeholder="预警摄像头" />
<selectRadio ref="selectRadioBox" :cellVisible="false" v-model="searchForm.warnHand" <selectRadio ref="selectRadioBox" :cellVisible="false" v-model="searchForm.warnHand"
:options="handOption" :title.sync="searchForm.$warnHand" placeholder="处理状态" /> :options="handOption" :title.sync="searchForm.$warnHand" placeholder="处理状态" />
</view> </view>
@@ -204,18 +221,19 @@
$alarmType: '全部', $alarmType: '全部',
warnHand: '', warnHand: '',
$warnHand: '', $warnHand: '',
cameraId: '',
$cameraId: '',
tick: [], tick: [],
StartTick: '', StartTick: '',
EndTick: '', EndTick: '',
pageNum: 1, pageNum: 1,
pageSize: 10 pageSize: 10
}, },
warnOption: [
{
label: '全部',
value: ''
}
],
warnOption: [{
label: '全部',
value: ''
}],
creamaData: [],
handOption: [{ handOption: [{
label: '已处理', label: '已处理',
value: 1 value: 1
@@ -275,6 +293,8 @@
$alarmType: '全部', $alarmType: '全部',
warnHand: '', warnHand: '',
$warnHand: '', $warnHand: '',
cameraId: '',
$cameraId: '',
tick: [], tick: [],
StartTick: '', StartTick: '',
EndTick: '', EndTick: '',
@@ -286,7 +306,7 @@
onsubmit() { onsubmit() {
let arr = [] let arr = []
for (let key in this.searchForm) { for (let key in this.searchForm) {
if (['$alarmType', '$warnHand', 'StartTick', 'EndTick'].includes(key)) {
if (['$alarmType','$cameraId', '$warnHand', 'StartTick', 'EndTick'].includes(key)) {
if (Object.hasOwnProperty.call(this.searchForm, key) && this.searchForm[key]) { if (Object.hasOwnProperty.call(this.searchForm, key) && this.searchForm[key]) {
arr.push(this.searchForm[key]) arr.push(this.searchForm[key])
} }
@@ -314,7 +334,7 @@
value: item.code value: item.code
}; };
}) })
this.warnOption = [...this.warnOption,...arr]
this.warnOption = [...this.warnOption, ...arr]
// this.warnOption.unshift({ // this.warnOption.unshift({
// label: '全部', // label: '全部',
// value: '' // value: ''
@@ -324,6 +344,8 @@




}, },
// 获取摄像头
// creamaData
// 跳转详情页面 // 跳转详情页面
toDetail(row) { toDetail(row) {
uni.navigateTo({ uni.navigateTo({
@@ -334,6 +356,10 @@
toOpen() { toOpen() {
this.$refs.selectSearchBox.show = true; this.$refs.selectSearchBox.show = true;
}, },
// 预警摄像头弹框筛选
toOpenmanjor() {
this.$refs.selectmanjorBox.show = true;
},
// 处理情况筛选 // 处理情况筛选
toOpenSelect() { toOpenSelect() {
this.$refs.selectRadioBox.show = true; this.$refs.selectRadioBox.show = true;


Loading…
Cancel
Save