Browse Source

Merge branch 'develop' of http://39.106.31.193:9211/mengff/jihe-hs into develop

wangqin
王钦 7 months ago
parent
commit
5a4f97bbc1
  1. 46
      ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/index.vue
  2. 5
      ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/DrivingGuidance/components/DeviceControlDialog.vue
  3. 29
      ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/DrivingGuidance/index.vue
  4. 50
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/dispatch/index.vue
  5. 2
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/emergencyProcessManagement/commonPhrases/index.vue
  6. 1
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/event/index.vue

46
ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/index.vue

@ -1,18 +1,11 @@
<template> <template>
<BorderRadiusImage <BorderRadiusImage class="RoadStateCard" borderRadius="2px"
class="RoadStateCard" borderColor="linear-gradient(360deg, rgba(55, 231, 255, 0.3), rgba(55, 231, 255, 0))" borderWidth="2px">
borderRadius="2px" <div class="left" v-if="isShowLeft">
borderColor="linear-gradient(360deg, rgba(55, 231, 255, 0.3), rgba(55, 231, 255, 0))"
borderWidth="2px"
>
<div class="left">
<!-- <img :src="(cardData.pictures ? cardData.pictures[0] : null) || require(`./test.png`)"> --> <!-- <img :src="(cardData.pictures ? cardData.pictures[0] : null) || require(`./test.png`)"> -->
<!-- <img :src="require(`./test.png`)"> --> <!-- <img :src="require(`./test.png`)"> -->
<ElImage <ElImage style="width: 212px; height: 159px" :src="cardData.pictures ? cardData.pictures[0] : null"
style="width: 212px; height: 159px" :preview-src-list="cardData.pictures || []">
:src="cardData.pictures ? cardData.pictures[0] : null"
:preview-src-list="cardData.pictures || []"
>
<div slot="error"> <div slot="error">
<i class="el-icon-picture-outline icon"></i> <i class="el-icon-picture-outline icon"></i>
</div> </div>
@ -26,25 +19,14 @@
</p> </p>
</div> </div>
<div class="controls"> <div class="controls">
<Button <Button :style="{ background: firstBtnColor, width: isShowLeft ? '50%' : '25%' }"
:style="{ background: firstBtnColor, width: '50%' }" @click.native="$emit('firstBtnClick', cardData.id)">{{ getFirstBtnText(cardData.state) }}</Button>
@click.native="$emit('firstBtnClick', cardData.id)" <Button v-if="cardData.state == 4" :style="{ background: lastBtnColor, width: isShowLeft ? '50%' : '25%' }"
>{{ getFirstBtnText(cardData.state) }}</Button @click.native="$emit('lastBtnClick', cardData.id)">{{ getLastBtnText(cardData.state) }}</Button>
>
<Button
v-if="cardData.state == 4"
:style="{ background: lastBtnColor, width: '50%' }"
@click.native="$emit('lastBtnClick', cardData.id)"
>{{ getLastBtnText(cardData.state) }}</Button
>
</div> </div>
</div> </div>
<img <img v-if="cardData.state" class="status" :src="require(`./images/${statusMap[cardData.state]}.svg`)" />
v-if="cardData.state"
class="status"
:src="require(`./images/${statusMap[cardData.state]}.svg`)"
/>
</BorderRadiusImage> </BorderRadiusImage>
</template> </template>
@ -106,6 +88,10 @@ export default {
}, },
], ],
}, },
isShowLeft: {
type: Boolean,
default: true
}
}, },
data() { data() {
return { return {
@ -180,7 +166,7 @@ export default {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
> p { >p {
font-size: 12px; font-size: 12px;
color: #f4f4f4; color: #f4f4f4;
line-height: 24px; line-height: 24px;
@ -212,7 +198,7 @@ export default {
display: flex; display: flex;
gap: 9px; gap: 9px;
> div { >div {
// flex: 1; // flex: 1;
} }
} }

5
ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/DrivingGuidance/components/DeviceControlDialog.vue

@ -38,7 +38,7 @@ export default {
props: { props: {
visible: Boolean, visible: Boolean,
deviceId: String, deviceId: String,
id: String, id: Number,
deviceType: String, deviceType: String,
}, },
data() { data() {
@ -49,6 +49,9 @@ export default {
computed: { computed: {
modelVisible: { modelVisible: {
get() { get() {
if(this.visible){
console.log('id',id)
}
return this.visible; return this.visible;
}, },
set(val) { set(val) {

29
ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/DrivingGuidance/index.vue

@ -164,18 +164,23 @@ export default {
handleClickTabs() { }, handleClickTabs() { },
requestURL(functionId = 52, options = {}) { requestURL(functionId = 52, options = {}) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
request if (!this.dialogData.iotDeviceId) {
.post( reject();
`business/device/functions/${this.dialogData.iotDeviceId}/${functionId}`, } else {
options request
) .post(
.then((result) => { `business/device/functions/${this.dialogData.iotDeviceId}/${functionId}`,
if (result.code != 200) return reject(); options
resolve(result.data[0]); )
}) .then((result) => {
.catch((err) => { if (result.code != 200) return reject();
reject(); resolve(result.data[0]);
}); })
.catch((err) => {
reject();
});
}
}); });
}, },
}, },

50
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/dispatch/index.vue

@ -9,51 +9,27 @@
刷新 刷新
</ButtonGradient> </ButtonGradient>
<InputSearch <InputSearch ref="searchComp" style="width: 402px" :formList="searchFormList"
ref="searchComp" :formConfigOptions="{ dFormData: { eventState: '0' } }" @handleSearch="handleSearch" />
style="width: 402px"
:formList="searchFormList"
:formConfigOptions="{ dFormData: { eventState: '0' } }"
@handleSearch="handleSearch"
/>
</div> </div>
<!-- 内容 --> <!-- 内容 -->
<div class="body"> <div class="body">
<RoadStateCard <RoadStateCard v-for="(item, index) in data" :key="index" :cardData="item" :isShowLeft="false" @firstBtnClick="firstBtnClick"
v-for="(item, index) in data" @lastBtnClick="lastBtnClick" />
:key="index"
:cardData="item"
@firstBtnClick="firstBtnClick"
@lastBtnClick="lastBtnClick"
/>
</div> </div>
<!-- 分页 --> <!-- 分页 -->
<div class="footer"> <div class="footer">
<Pagination <Pagination @current-change="initData" @size-change="onSizeChange" width="'100%'"
@current-change="initData" :page-sizes="[12, 16, 20, 30, 50]" :page-size="searchData.pageSize" :current-page.sync="searchData.pageNum"
@size-change="onSizeChange" layout="total, sizes, prev, pager, next" :total="total">
width="'100%'"
:page-sizes="[12, 16, 20, 30, 50]"
:page-size="searchData.pageSize"
:current-page.sync="searchData.pageNum"
layout="total, sizes, prev, pager, next"
:total="total"
>
</Pagination> </Pagination>
</div> </div>
<EventDetailDialog <EventDetailDialog :visible="eventDetailDialogVisible" :formData="detailDialogFormData"
:visible="eventDetailDialogVisible" @update:value="handleClose" />
:formData="detailDialogFormData" <EventDispatchDialog :visible="eventDispatchDialogVisible" @update:value="handleClose" :eventId="eventId" />
@update:value="handleClose"
/>
<EventDispatchDialog
:visible="eventDispatchDialogVisible"
@update:value="handleClose"
:eventId="eventId"
/>
</div> </div>
</template> </template>
@ -104,7 +80,7 @@ export default {
this.initData(); this.initData();
}, },
methods: { methods: {
onRefreshForm(){ onRefreshForm() {
this.searchData.pageNum = 1; this.searchData.pageNum = 1;
this.$refs.searchComp.handleResetForm(); this.$refs.searchComp.handleResetForm();
}, },
@ -205,8 +181,8 @@ export default {
display: flex; display: flex;
// justify-content: flex-end; // justify-content: flex-end;
justify-content: space-between; justify-content: space-between;
.refresh-btn {
} .refresh-btn {}
} }
.body { .body {

2
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/emergencyProcessManagement/commonPhrases/index.vue

@ -1,5 +1,5 @@
<template> <template>
<Dialog v-model="modelVisible" title="配置常用语" width="880px"> <Dialog v-model="modelVisible" title="配置常用语" width="880px" top="8%">
<!-- <Button style="margin: 10px 0 20px 20px; width: 100px;" @click.native="onAdd">添加</Button> --> <!-- <Button style="margin: 10px 0 20px 20px; width: 100px;" @click.native="onAdd">添加</Button> -->
<div class="header"> <div class="header">
<el-form ref="form" label-width="120px"> <el-form ref="form" label-width="120px">

1
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/event/index.vue

@ -153,6 +153,7 @@ export default {
cardData: { ...item, state }, cardData: { ...item, state },
lastBtnColor: textColor, lastBtnColor: textColor,
lastBtnText: text, lastBtnText: text,
isShowLeft: this.activeName == '-1'
}; };
}, },
queryData(flag) { queryData(flag) {

Loading…
Cancel
Save