|  |  | @ -11,8 +11,18 @@ | 
			
		
	
		
			
				
					|  |  |  | 				> | 
			
		
	
		
			
				
					|  |  |  | 					<el-table-column type="selection" width="55" /> | 
			
		
	
		
			
				
					|  |  |  | 					<!-- prop="name"  --> | 
			
		
	
		
			
				
					|  |  |  |           <el-table-column label="序号" type="index" align="center" width="50" /> | 
			
		
	
		
			
				
					|  |  |  |           <el-table-column label="发布内容" align="center" prop="context" width="400" > | 
			
		
	
		
			
				
					|  |  |  | 					<el-table-column | 
			
		
	
		
			
				
					|  |  |  | 						label="序号" | 
			
		
	
		
			
				
					|  |  |  | 						type="index" | 
			
		
	
		
			
				
					|  |  |  | 						align="center" | 
			
		
	
		
			
				
					|  |  |  | 						width="50" | 
			
		
	
		
			
				
					|  |  |  | 					/> | 
			
		
	
		
			
				
					|  |  |  | 					<el-table-column | 
			
		
	
		
			
				
					|  |  |  | 						label="发布内容" | 
			
		
	
		
			
				
					|  |  |  | 						align="center" | 
			
		
	
		
			
				
					|  |  |  | 						prop="context" | 
			
		
	
		
			
				
					|  |  |  | 						width="400" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  | 						<template slot-scope="{ row }"> | 
			
		
	
		
			
				
					|  |  |  | 							<div>{{ row.context }}</div> | 
			
		
	
		
			
				
					|  |  |  | 						</template> | 
			
		
	
	
		
			
				
					|  |  | @ -26,26 +36,49 @@ | 
			
		
	
		
			
				
					|  |  |  | 					<el-table-column label="发布人" align="center" prop="creater_name" /> | 
			
		
	
		
			
				
					|  |  |  | 					<el-table-column label="状态" align="center" prop="is_state"> | 
			
		
	
		
			
				
					|  |  |  | 						<template slot-scope="{ row }"> | 
			
		
	
		
			
				
					|  |  |  |               <div :class="{ 'stop_txt': row.is_state}">{{ row.is_state==1 ? '发布中' : '停止' }}</div> | 
			
		
	
		
			
				
					|  |  |  | 							<div :class="{ stop_txt: row.is_state }"> | 
			
		
	
		
			
				
					|  |  |  | 								{{ row.is_state == 1 ? "发布中" : "停止" }} | 
			
		
	
		
			
				
					|  |  |  | 							</div> | 
			
		
	
		
			
				
					|  |  |  | 						</template> | 
			
		
	
		
			
				
					|  |  |  | 					</el-table-column> | 
			
		
	
		
			
				
					|  |  |  |           <el-table-column label="操作" width="120px" align="center" fixed="right"> | 
			
		
	
		
			
				
					|  |  |  | 					<el-table-column | 
			
		
	
		
			
				
					|  |  |  | 						label="操作" | 
			
		
	
		
			
				
					|  |  |  | 						width="120px" | 
			
		
	
		
			
				
					|  |  |  | 						align="center" | 
			
		
	
		
			
				
					|  |  |  | 						fixed="right" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  | 						<template slot-scope="scope"> | 
			
		
	
		
			
				
					|  |  |  | 							<el-button | 
			
		
	
		
			
				
					|  |  |  | 								type="primary" | 
			
		
	
		
			
				
					|  |  |  | 								class="edit_btn" | 
			
		
	
		
			
				
					|  |  |  | 								@click="editFormData(scope.row)" | 
			
		
	
		
			
				
					|  |  |  |               >编辑</el-button> | 
			
		
	
		
			
				
					|  |  |  | 								>编辑</el-button | 
			
		
	
		
			
				
					|  |  |  | 							> | 
			
		
	
		
			
				
					|  |  |  | 							<el-button | 
			
		
	
		
			
				
					|  |  |  | 								type="primary" | 
			
		
	
		
			
				
					|  |  |  |                 :class="['start_btn', { 'stop_btn': scope.row.is_state==1 }]" | 
			
		
	
		
			
				
					|  |  |  | 								:class="['start_btn', { stop_btn: scope.row.is_state == 1 }]" | 
			
		
	
		
			
				
					|  |  |  | 								@click="isStopHandle(scope.$index, scope.row)" | 
			
		
	
		
			
				
					|  |  |  |               >{{ scope.row.is_state==1 ? '停止' : '恢复' }}</el-button> | 
			
		
	
		
			
				
					|  |  |  | 								>{{ scope.row.is_state == 1 ? "停止" : "恢复" }}</el-button | 
			
		
	
		
			
				
					|  |  |  | 							> | 
			
		
	
		
			
				
					|  |  |  | 						</template> | 
			
		
	
		
			
				
					|  |  |  | 					</el-table-column> | 
			
		
	
		
			
				
					|  |  |  | 				</el-table> | 
			
		
	
		
			
				
					|  |  |  | 			</el-col> | 
			
		
	
		
			
				
					|  |  |  | 		</el-row> | 
			
		
	
		
			
				
					|  |  |  | 		<!-- 分页器 --> | 
			
		
	
		
			
				
					|  |  |  | 		<el-pagination | 
			
		
	
		
			
				
					|  |  |  | 			style="margin-top: 20px; text-align: center" | 
			
		
	
		
			
				
					|  |  |  | 			:current-page="queryInfo.page" | 
			
		
	
		
			
				
					|  |  |  | 			:total="total" | 
			
		
	
		
			
				
					|  |  |  | 			:page-size="queryInfo.size" | 
			
		
	
		
			
				
					|  |  |  | 			:pager-count="5" | 
			
		
	
		
			
				
					|  |  |  | 			:page-sizes="[3, 5, 10]" | 
			
		
	
		
			
				
					|  |  |  | 			@current-change="getUrgentMessage" | 
			
		
	
		
			
				
					|  |  |  | 			@size-change="handleSizeChange" | 
			
		
	
		
			
				
					|  |  |  | 			layout="prev, pager, next, jumper,->,sizes,total" | 
			
		
	
		
			
				
					|  |  |  | 		> | 
			
		
	
		
			
				
					|  |  |  | 		</el-pagination> | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | 		<!-- 编辑紧急通知 --> | 
			
		
	
		
			
				
					|  |  |  | 		<div class="publish_layer"> | 
			
		
	
		
			
				
					|  |  |  | 			<el-dialog | 
			
		
	
	
		
			
				
					|  |  | @ -60,34 +93,48 @@ | 
			
		
	
		
			
				
					|  |  |  | 						label="文本颜色" | 
			
		
	
		
			
				
					|  |  |  | 						prop="context_color" | 
			
		
	
		
			
				
					|  |  |  | 						:rules="[ | 
			
		
	
		
			
				
					|  |  |  |               { required: true, message: '请选择文本颜色', trigger: '' } | 
			
		
	
		
			
				
					|  |  |  | 							{ required: true, message: '请选择文本颜色', trigger: '' }, | 
			
		
	
		
			
				
					|  |  |  | 						]" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  |             <colorPicker v-model="form.context_color" class="txt_color" @change="headleChangeColor" /> | 
			
		
	
		
			
				
					|  |  |  | 						<colorPicker | 
			
		
	
		
			
				
					|  |  |  | 							v-model="form.context_color" | 
			
		
	
		
			
				
					|  |  |  | 							class="txt_color" | 
			
		
	
		
			
				
					|  |  |  | 							@change="headleChangeColor" | 
			
		
	
		
			
				
					|  |  |  | 						/> | 
			
		
	
		
			
				
					|  |  |  | 						<el-input v-show="false" v-model="form.context_color" /> | 
			
		
	
		
			
				
					|  |  |  | 					</el-form-item> | 
			
		
	
		
			
				
					|  |  |  | 					<el-form-item | 
			
		
	
		
			
				
					|  |  |  | 						label="文本内容" | 
			
		
	
		
			
				
					|  |  |  | 						prop="context" | 
			
		
	
		
			
				
					|  |  |  | 						:rules="[ | 
			
		
	
		
			
				
					|  |  |  |               { required: true, message: '请输入文本内容', trigger: 'blur' } | 
			
		
	
		
			
				
					|  |  |  | 							{ required: true, message: '请输入文本内容', trigger: 'blur' }, | 
			
		
	
		
			
				
					|  |  |  | 						]" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  |             <el-input v-model="form.context" type="textarea" rows="6" style="width: 674px;" /> | 
			
		
	
		
			
				
					|  |  |  | 						<el-input | 
			
		
	
		
			
				
					|  |  |  | 							v-model="form.context" | 
			
		
	
		
			
				
					|  |  |  | 							type="textarea" | 
			
		
	
		
			
				
					|  |  |  | 							rows="6" | 
			
		
	
		
			
				
					|  |  |  | 							style="width: 674px" | 
			
		
	
		
			
				
					|  |  |  | 						/> | 
			
		
	
		
			
				
					|  |  |  | 					</el-form-item> | 
			
		
	
		
			
				
					|  |  |  | 					<el-form-item | 
			
		
	
		
			
				
					|  |  |  | 						label="文本大小" | 
			
		
	
		
			
				
					|  |  |  |             prop="context_size" | 
			
		
	
		
			
				
					|  |  |  | 						prop="context_size_name" | 
			
		
	
		
			
				
					|  |  |  | 						:rules="[ | 
			
		
	
		
			
				
					|  |  |  | 							{ required: true, message: '请选择文本大小', trigger: 'change' }, | 
			
		
	
		
			
				
					|  |  |  | 						]" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  |             <el-select v-model="form.context_size" size="small" class="filter-item"> | 
			
		
	
		
			
				
					|  |  |  | 						<el-select | 
			
		
	
		
			
				
					|  |  |  | 							v-model="form.context_size_name" | 
			
		
	
		
			
				
					|  |  |  | 							size="small" | 
			
		
	
		
			
				
					|  |  |  | 							class="filter-item" | 
			
		
	
		
			
				
					|  |  |  | 							@change="selectSize" | 
			
		
	
		
			
				
					|  |  |  | 						> | 
			
		
	
		
			
				
					|  |  |  | 							<el-option | 
			
		
	
		
			
				
					|  |  |  | 								v-for="item in sizeData" | 
			
		
	
		
			
				
					|  |  |  | 								:key="item.key" | 
			
		
	
		
			
				
					|  |  |  | 								:label="item.name" | 
			
		
	
		
			
				
					|  |  |  |                 :value="item.key" | 
			
		
	
		
			
				
					|  |  |  | 								:value="item" | 
			
		
	
		
			
				
					|  |  |  | 							/> | 
			
		
	
		
			
				
					|  |  |  | 						</el-select> | 
			
		
	
		
			
				
					|  |  |  | 					</el-form-item> | 
			
		
	
	
		
			
				
					|  |  | @ -98,7 +145,13 @@ | 
			
		
	
		
			
				
					|  |  |  | 							{ required: true, message: '请选择文本位置', trigger: 'change' }, | 
			
		
	
		
			
				
					|  |  |  | 						]" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  |             <el-select v-model="form.context_position_name" size="small" value-key="name"  class="filter-item" @change="selectPosition"> | 
			
		
	
		
			
				
					|  |  |  | 						<el-select | 
			
		
	
		
			
				
					|  |  |  | 							v-model="form.context_position_name" | 
			
		
	
		
			
				
					|  |  |  | 							size="small" | 
			
		
	
		
			
				
					|  |  |  | 							value-key="name" | 
			
		
	
		
			
				
					|  |  |  | 							class="filter-item" | 
			
		
	
		
			
				
					|  |  |  | 							@change="selectPosition" | 
			
		
	
		
			
				
					|  |  |  | 						> | 
			
		
	
		
			
				
					|  |  |  | 							<el-option | 
			
		
	
		
			
				
					|  |  |  | 								v-for="item in positionData" | 
			
		
	
		
			
				
					|  |  |  | 								:key="item.key" | 
			
		
	
	
		
			
				
					|  |  | @ -114,7 +167,12 @@ | 
			
		
	
		
			
				
					|  |  |  | 							{ required: true, message: '请选择滚动速度', trigger: 'change' }, | 
			
		
	
		
			
				
					|  |  |  | 						]" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  |             <el-select v-model="form.context_speed_name" size="small" class="filter-item" @change="selectSpeed"> | 
			
		
	
		
			
				
					|  |  |  | 						<el-select | 
			
		
	
		
			
				
					|  |  |  | 							v-model="form.context_speed_name" | 
			
		
	
		
			
				
					|  |  |  | 							size="small" | 
			
		
	
		
			
				
					|  |  |  | 							class="filter-item" | 
			
		
	
		
			
				
					|  |  |  | 							@change="selectSpeed" | 
			
		
	
		
			
				
					|  |  |  | 						> | 
			
		
	
		
			
				
					|  |  |  | 							<el-option | 
			
		
	
		
			
				
					|  |  |  | 								v-for="item in speedData" | 
			
		
	
		
			
				
					|  |  |  | 								:key="item.key" | 
			
		
	
	
		
			
				
					|  |  | @ -130,17 +188,38 @@ | 
			
		
	
		
			
				
					|  |  |  | 							{ required: true, message: '请选择设备', trigger: 'change' }, | 
			
		
	
		
			
				
					|  |  |  | 						]" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  |             <el-radio-group v-model="form.notice_device" @change="clearCheckbox()"> | 
			
		
	
		
			
				
					|  |  |  | 						<el-radio-group | 
			
		
	
		
			
				
					|  |  |  | 							v-model="form.notice_device" | 
			
		
	
		
			
				
					|  |  |  | 							@change="clearCheckbox()" | 
			
		
	
		
			
				
					|  |  |  | 						> | 
			
		
	
		
			
				
					|  |  |  | 							<el-radio :label="1" value="all">所有设备</el-radio> | 
			
		
	
		
			
				
					|  |  |  |               <el-radio :label="2"  value= "other" >部分设备<i v-if="form.notice_device === 2" class="radio_tip" @click="addDeviceTag()">添加</i></el-radio> | 
			
		
	
		
			
				
					|  |  |  | 							<el-radio :label="2" value="other" | 
			
		
	
		
			
				
					|  |  |  | 								>部分设备<i | 
			
		
	
		
			
				
					|  |  |  | 									v-if="form.notice_device === 2" | 
			
		
	
		
			
				
					|  |  |  | 									class="radio_tip" | 
			
		
	
		
			
				
					|  |  |  | 									@click="addDeviceTag()" | 
			
		
	
		
			
				
					|  |  |  | 									>添加</i | 
			
		
	
		
			
				
					|  |  |  | 								></el-radio | 
			
		
	
		
			
				
					|  |  |  | 							> | 
			
		
	
		
			
				
					|  |  |  | 						</el-radio-group> | 
			
		
	
		
			
				
					|  |  |  | 					</el-form-item> | 
			
		
	
		
			
				
					|  |  |  |           <div v-if="form.notice_device === 1" class="select_all_tip">所有设备都将被发送</div> | 
			
		
	
		
			
				
					|  |  |  |           <div v-if="deviceTags.length>0 && form.notice_device === 2" class="select_other"> | 
			
		
	
		
			
				
					|  |  |  | 					<div v-if="form.notice_device === 1" class="select_all_tip"> | 
			
		
	
		
			
				
					|  |  |  | 						所有设备都将被发送 | 
			
		
	
		
			
				
					|  |  |  | 					</div> | 
			
		
	
		
			
				
					|  |  |  | 					<div | 
			
		
	
		
			
				
					|  |  |  | 						v-if="deviceTags.length > 0 && form.notice_device === 2" | 
			
		
	
		
			
				
					|  |  |  | 						class="select_other" | 
			
		
	
		
			
				
					|  |  |  | 					> | 
			
		
	
		
			
				
					|  |  |  | 						<el-row> | 
			
		
	
		
			
				
					|  |  |  |               <el-col :span="10" class="other_tip">以下设备都将被发送<span>总计{{ deviceTags.length }}个设备</span></el-col> | 
			
		
	
		
			
				
					|  |  |  | 							<el-col :span="10" class="other_tip" | 
			
		
	
		
			
				
					|  |  |  | 								>以下设备都将被发送<span | 
			
		
	
		
			
				
					|  |  |  | 									>总计{{ deviceTags.length }}个设备</span | 
			
		
	
		
			
				
					|  |  |  | 								></el-col | 
			
		
	
		
			
				
					|  |  |  | 							> | 
			
		
	
		
			
				
					|  |  |  | 							<el-col :span="4"> | 
			
		
	
		
			
				
					|  |  |  |                 <el-button round class="delt_btn" @click="clearDevice()">清空</el-button> | 
			
		
	
		
			
				
					|  |  |  | 								<el-button round class="delt_btn" @click="clearDevice()" | 
			
		
	
		
			
				
					|  |  |  | 									>清空</el-button | 
			
		
	
		
			
				
					|  |  |  | 								> | 
			
		
	
		
			
				
					|  |  |  | 							</el-col> | 
			
		
	
		
			
				
					|  |  |  | 						</el-row> | 
			
		
	
		
			
				
					|  |  |  | 						<el-tag | 
			
		
	
	
		
			
				
					|  |  | @ -160,11 +239,12 @@ | 
			
		
	
		
			
				
					|  |  |  | 					<!-- :loading="crud.status.cu === 2"   | 
			
		
	
		
			
				
					|  |  |  |            @click="crud.submitCU"--> | 
			
		
	
		
			
				
					|  |  |  | 					<el-button type="primary" round @click="submit">保存</el-button> | 
			
		
	
		
			
				
					|  |  |  |           <el-button round @click="messageVisible=false">关闭</el-button> | 
			
		
	
		
			
				
					|  |  |  | 					<el-button round @click="closeDialog">关闭</el-button> | 
			
		
	
		
			
				
					|  |  |  | 				</div> | 
			
		
	
		
			
				
					|  |  |  | 			</el-dialog> | 
			
		
	
		
			
				
					|  |  |  | 		</div> | 
			
		
	
		
			
				
					|  |  |  | 		<!-- 添加发布的设备 --> | 
			
		
	
		
			
				
					|  |  |  | 		<!-- 添加发布的设备 --> | 
			
		
	
		
			
				
					|  |  |  | 		<div class="add_device_layer"> | 
			
		
	
		
			
				
					|  |  |  | 			<el-dialog | 
			
		
	
		
			
				
					|  |  |  | 				title="请选择设备" | 
			
		
	
	
		
			
				
					|  |  | @ -189,125 +269,192 @@ | 
			
		
	
		
			
				
					|  |  |  | </template> | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | <script> | 
			
		
	
		
			
				
					|  |  |  | import { parseTime } from '@/utils/index.js' | 
			
		
	
		
			
				
					|  |  |  | import { ReqDeviceList} from '@/api/device/deviceList.js' | 
			
		
	
		
			
				
					|  |  |  | import {reqUrgentMessage,reqQueryMessage,reqEditMessage} from '@/api/publish/urgentMessage' | 
			
		
	
		
			
				
					|  |  |  | 	import { parseTime } from "@/utils/index.js"; | 
			
		
	
		
			
				
					|  |  |  | 	import { ReqDeviceList } from "@/api/device/deviceList.js"; | 
			
		
	
		
			
				
					|  |  |  | 	import { | 
			
		
	
		
			
				
					|  |  |  | 		reqUrgentMessage, | 
			
		
	
		
			
				
					|  |  |  | 		reqQueryMessage, | 
			
		
	
		
			
				
					|  |  |  | 		reqEditMessage, | 
			
		
	
		
			
				
					|  |  |  |     reqChangeMessage | 
			
		
	
		
			
				
					|  |  |  | 	} from "@/api/publish/urgentMessage"; | 
			
		
	
		
			
				
					|  |  |  | 	export default { | 
			
		
	
		
			
				
					|  |  |  |   name: 'UrgentMessage', | 
			
		
	
		
			
				
					|  |  |  | 		name: "UrgentMessage", | 
			
		
	
		
			
				
					|  |  |  | 		filters: { | 
			
		
	
		
			
				
					|  |  |  | 			parseTime(time, cFormat) { | 
			
		
	
		
			
				
					|  |  |  |       return parseTime(time, cFormat) | 
			
		
	
		
			
				
					|  |  |  |     } | 
			
		
	
		
			
				
					|  |  |  | 				return parseTime(time, cFormat); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 		}, | 
			
		
	
		
			
				
					|  |  |  | 		data() { | 
			
		
	
		
			
				
					|  |  |  | 			return { | 
			
		
	
		
			
				
					|  |  |  | 				isAddEdit: false, | 
			
		
	
		
			
				
					|  |  |  | 				form: { | 
			
		
	
		
			
				
					|  |  |  |         context_color: '#ff0000',//文本的颜色 | 
			
		
	
		
			
				
					|  |  |  |         context: '', //文本的内容 | 
			
		
	
		
			
				
					|  |  |  | 					context_color: "#ff0000", //文本的颜色 | 
			
		
	
		
			
				
					|  |  |  | 					context: "", //文本的内容 | 
			
		
	
		
			
				
					|  |  |  | 					context_position: null, //文本的位置 | 
			
		
	
		
			
				
					|  |  |  | 					context_position_name: null, | 
			
		
	
		
			
				
					|  |  |  | 					context_speed_name: null, | 
			
		
	
		
			
				
					|  |  |  | 					context_speed: null, //文本的速度 | 
			
		
	
		
			
				
					|  |  |  | 					context_size_name: null, | 
			
		
	
		
			
				
					|  |  |  | 					context_size: null, //文字的大小 | 
			
		
	
		
			
				
					|  |  |  | 					// create_by:'', //发布人 | 
			
		
	
		
			
				
					|  |  |  | 					notice_device: null, | 
			
		
	
		
			
				
					|  |  |  | 					notice_devices: [], | 
			
		
	
		
			
				
					|  |  |  |         notice_id:'' ,//紧急通知的id | 
			
		
	
		
			
				
					|  |  |  |         orga_id:'133221333123111', | 
			
		
	
		
			
				
					|  |  |  | 					notice_id: "", //紧急通知的id | 
			
		
	
		
			
				
					|  |  |  | 					orga_id: "133221333123111", | 
			
		
	
		
			
				
					|  |  |  | 				}, | 
			
		
	
		
			
				
					|  |  |  | 				queryInfo: { | 
			
		
	
		
			
				
					|  |  |  |          notice_name:'', | 
			
		
	
		
			
				
					|  |  |  |          orga_id:'133221333123111', | 
			
		
	
		
			
				
					|  |  |  | 					notice_name: "", | 
			
		
	
		
			
				
					|  |  |  | 					orga_id: "133221333123111", | 
			
		
	
		
			
				
					|  |  |  | 					page: 1, | 
			
		
	
		
			
				
					|  |  |  |          size:3 | 
			
		
	
		
			
				
					|  |  |  | 					size: 3, | 
			
		
	
		
			
				
					|  |  |  | 				}, | 
			
		
	
		
			
				
					|  |  |  | 				total: 0, | 
			
		
	
		
			
				
					|  |  |  | 				messageVisible: false, | 
			
		
	
		
			
				
					|  |  |  | 				selectDeviceVisible: false, | 
			
		
	
		
			
				
					|  |  |  |       sizeData: [{ key: '0', name: 16 }, { key: '1', name: 22 }, { key: '2', name: 24 }, { key: '3', name: 30 }], | 
			
		
	
		
			
				
					|  |  |  |       positionData: [{ key: 1, name: '顶部' }, { key: 2, name: '中间' }, { key: 3, name: '底部' }], | 
			
		
	
		
			
				
					|  |  |  |       speedData: [{ key: 0, name: '1s' }, { key: 1, name: '2s'  }, { key: 2, name: '3s' }], | 
			
		
	
		
			
				
					|  |  |  | 				sizeData: [ | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 0, name: 16 }, | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 1, name: 22 }, | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 2, name: 24 }, | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 3, name: 30 }, | 
			
		
	
		
			
				
					|  |  |  | 				], | 
			
		
	
		
			
				
					|  |  |  | 				positionData: [ | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 1, name: "顶部" }, | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 2, name: "中间" }, | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 3, name: "底部" }, | 
			
		
	
		
			
				
					|  |  |  | 				], | 
			
		
	
		
			
				
					|  |  |  | 				speedData: [ | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 0, name: "1s" }, | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 1, name: "2s" }, | 
			
		
	
		
			
				
					|  |  |  | 					{ key: 2, name: "3s" }, | 
			
		
	
		
			
				
					|  |  |  | 				], | 
			
		
	
		
			
				
					|  |  |  | 				selectedList: [], | 
			
		
	
		
			
				
					|  |  |  | 				// 部分设备列表的数据 | 
			
		
	
		
			
				
					|  |  |  | 				deviceList: [], | 
			
		
	
		
			
				
					|  |  |  | 				// newArr:[], | 
			
		
	
		
			
				
					|  |  |  | 				deviceTags: [], | 
			
		
	
		
			
				
					|  |  |  | 				// 紧急通知列表 | 
			
		
	
		
			
				
					|  |  |  |       urgentMessage:[] | 
			
		
	
		
			
				
					|  |  |  |     } | 
			
		
	
		
			
				
					|  |  |  | 				urgentMessage: [], | 
			
		
	
		
			
				
					|  |  |  | 			}; | 
			
		
	
		
			
				
					|  |  |  | 		}, | 
			
		
	
		
			
				
					|  |  |  | 		mounted() { | 
			
		
	
		
			
				
					|  |  |  |     this.getUrgentMessage() | 
			
		
	
		
			
				
					|  |  |  |     this.getDevice() | 
			
		
	
		
			
				
					|  |  |  | 			this.getUrgentMessage(); | 
			
		
	
		
			
				
					|  |  |  | 			this.getDevice(); | 
			
		
	
		
			
				
					|  |  |  | 		}, | 
			
		
	
		
			
				
					|  |  |  | 		methods: { | 
			
		
	
		
			
				
					|  |  |  | 			// 获取紧急通知的列表 | 
			
		
	
		
			
				
					|  |  |  |     getUrgentMessage(){ | 
			
		
	
		
			
				
					|  |  |  |        const params=this.queryInfo | 
			
		
	
		
			
				
					|  |  |  |        reqUrgentMessage(params).then(res=>{ | 
			
		
	
		
			
				
					|  |  |  |          | 
			
		
	
		
			
				
					|  |  |  | 			getUrgentMessage(pager=1) { | 
			
		
	
		
			
				
					|  |  |  |         this.queryInfo.page=pager | 
			
		
	
		
			
				
					|  |  |  | 				const params = this.queryInfo; | 
			
		
	
		
			
				
					|  |  |  | 				reqUrgentMessage(params).then((res) => { | 
			
		
	
		
			
				
					|  |  |  | 					if (res.code == 200) { | 
			
		
	
		
			
				
					|  |  |  |            this.urgentMessage=res.data.content | 
			
		
	
		
			
				
					|  |  |  |             // console.log( this.urgentMessage) | 
			
		
	
		
			
				
					|  |  |  | 						this.urgentMessage = res.data.content; | 
			
		
	
		
			
				
					|  |  |  | 						this.total = res.data.totalElements; | 
			
		
	
		
			
				
					|  |  |  | 						// console.log(this.urgentMessage); | 
			
		
	
		
			
				
					|  |  |  | 					} | 
			
		
	
		
			
				
					|  |  |  |        }) | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | 				}); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 获取设备列表的信息 | 
			
		
	
		
			
				
					|  |  |  | 			getDevice() { | 
			
		
	
		
			
				
					|  |  |  |       const params = this.queryInfo | 
			
		
	
		
			
				
					|  |  |  |       ReqDeviceList(params).then(res => { | 
			
		
	
		
			
				
					|  |  |  | 				const params = this.queryInfo; | 
			
		
	
		
			
				
					|  |  |  | 				ReqDeviceList(params).then((res) => { | 
			
		
	
		
			
				
					|  |  |  | 					if (res.code == 200) { | 
			
		
	
		
			
				
					|  |  |  |             this.deviceList=res.data.content       | 
			
		
	
		
			
				
					|  |  |  | 						this.deviceList = res.data.content; | 
			
		
	
		
			
				
					|  |  |  | 					} else { | 
			
		
	
		
			
				
					|  |  |  |             return this.$message.error('获取设备列表失败!') | 
			
		
	
		
			
				
					|  |  |  | 						return this.$message.error("获取设备列表失败!"); | 
			
		
	
		
			
				
					|  |  |  | 					} | 
			
		
	
		
			
				
					|  |  |  |       }) | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | 				}); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  |       // 紧急通知的状态  is_state为1 发布中 2 停止 | 
			
		
	
		
			
				
					|  |  |  |       // row.is_state == 1 ? "停止" : "恢复" | 
			
		
	
		
			
				
					|  |  |  | 			isStopHandle(index, row) { | 
			
		
	
		
			
				
					|  |  |  |         console.log(row) | 
			
		
	
		
			
				
					|  |  |  |         // console.log(index) | 
			
		
	
		
			
				
					|  |  |  | 				if (row.is_state == 1) { | 
			
		
	
		
			
				
					|  |  |  |         row.is_state=2 | 
			
		
	
		
			
				
					|  |  |  | 					row.is_state = 2;        | 
			
		
	
		
			
				
					|  |  |  | 				} else { | 
			
		
	
		
			
				
					|  |  |  |         row.is_state=1 | 
			
		
	
		
			
				
					|  |  |  | 					row.is_state = 1; | 
			
		
	
		
			
				
					|  |  |  | 				} | 
			
		
	
		
			
				
					|  |  |  |         const params={ | 
			
		
	
		
			
				
					|  |  |  |           id:row.notice_id, | 
			
		
	
		
			
				
					|  |  |  |           state:row.is_state | 
			
		
	
		
			
				
					|  |  |  |         } | 
			
		
	
		
			
				
					|  |  |  |         reqChangeMessage(params).then(res=>{ | 
			
		
	
		
			
				
					|  |  |  |           // console.log(res) | 
			
		
	
		
			
				
					|  |  |  |           if(res.code==200){ | 
			
		
	
		
			
				
					|  |  |  |             if(params.state==1){ | 
			
		
	
		
			
				
					|  |  |  |               this.$message({ | 
			
		
	
		
			
				
					|  |  |  | 									type: "success", | 
			
		
	
		
			
				
					|  |  |  | 									message:'已发布成功!'						 | 
			
		
	
		
			
				
					|  |  |  | 								}); | 
			
		
	
		
			
				
					|  |  |  |             }else{ | 
			
		
	
		
			
				
					|  |  |  |               this.$message({ | 
			
		
	
		
			
				
					|  |  |  | 									type: "success", | 
			
		
	
		
			
				
					|  |  |  | 									message:'已停止!'						 | 
			
		
	
		
			
				
					|  |  |  | 								}); | 
			
		
	
		
			
				
					|  |  |  |             } | 
			
		
	
		
			
				
					|  |  |  |           }else{ | 
			
		
	
		
			
				
					|  |  |  |             	return this.$message.error("失败了~~~~"); | 
			
		
	
		
			
				
					|  |  |  |           } | 
			
		
	
		
			
				
					|  |  |  |         }) | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  |         | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | 			// 编辑 | 
			
		
	
		
			
				
					|  |  |  | 			editFormData(row) { | 
			
		
	
		
			
				
					|  |  |  |       console.log(row) | 
			
		
	
		
			
				
					|  |  |  |       this.messageVisible = true | 
			
		
	
		
			
				
					|  |  |  | 				this.messageVisible = true; | 
			
		
	
		
			
				
					|  |  |  | 				// 根据id查询返回的紧急通知的数据 | 
			
		
	
		
			
				
					|  |  |  | 				const params = { | 
			
		
	
		
			
				
					|  |  |  |          notice_id:row.notice_id | 
			
		
	
		
			
				
					|  |  |  |       } | 
			
		
	
		
			
				
					|  |  |  |       reqQueryMessage(params).then(res=>{     | 
			
		
	
		
			
				
					|  |  |  |         console.log(res)   | 
			
		
	
		
			
				
					|  |  |  | 					notice_id: row.notice_id, | 
			
		
	
		
			
				
					|  |  |  | 				}; | 
			
		
	
		
			
				
					|  |  |  | 				reqQueryMessage(params).then((res) => { | 
			
		
	
		
			
				
					|  |  |  | 					if (res.code == 200) { | 
			
		
	
		
			
				
					|  |  |  |          this.form.notice_device=res.data.notice.noticeDevice | 
			
		
	
		
			
				
					|  |  |  |          this.form.context_color=res.data.notice.contextColor | 
			
		
	
		
			
				
					|  |  |  |          this.form.context=res.data.notice.context | 
			
		
	
		
			
				
					|  |  |  |          this.form.context_position=res.data.notice.contextPosition | 
			
		
	
		
			
				
					|  |  |  |          this.form.context_size=res.data.notice.contextSize       | 
			
		
	
		
			
				
					|  |  |  | 						this.form.notice_device = res.data.notice.noticeDevice; | 
			
		
	
		
			
				
					|  |  |  | 						this.form.context_color = res.data.notice.contextColor; | 
			
		
	
		
			
				
					|  |  |  | 						this.form.context = res.data.notice.context; | 
			
		
	
		
			
				
					|  |  |  | 						this.form.context_position = res.data.notice.contextPosition; | 
			
		
	
		
			
				
					|  |  |  | 						this.form.context_size = res.data.notice.contextSize; | 
			
		
	
		
			
				
					|  |  |  | 						this.form.notice_id = row.notice_id; | 
			
		
	
		
			
				
					|  |  |  | 						//  判断文字位置 | 
			
		
	
		
			
				
					|  |  |  | 						if (this.form.context_position == 1) { | 
			
		
	
		
			
				
					|  |  |  |                 this.form.context_position_name='顶部' | 
			
		
	
		
			
				
					|  |  |  | 							this.form.context_position_name = "顶部"; | 
			
		
	
		
			
				
					|  |  |  | 						} else if (this.form.context_position == 2) { | 
			
		
	
		
			
				
					|  |  |  |                 this.form.context_position_name='中部' | 
			
		
	
		
			
				
					|  |  |  | 							this.form.context_position_name = "中部"; | 
			
		
	
		
			
				
					|  |  |  | 						} else { | 
			
		
	
		
			
				
					|  |  |  |                 this.form.context_position_name='底部' | 
			
		
	
		
			
				
					|  |  |  | 							this.form.context_position_name = "底部"; | 
			
		
	
		
			
				
					|  |  |  | 						} | 
			
		
	
		
			
				
					|  |  |  | 						// 判断速度 | 
			
		
	
		
			
				
					|  |  |  |               if(this.form.context_speed==0){ | 
			
		
	
		
			
				
					|  |  |  |               this.form.context_speed_name='1s' | 
			
		
	
		
			
				
					|  |  |  |             }else if(this.form.context_speed==1){ | 
			
		
	
		
			
				
					|  |  |  |                 this.form.context_speed_name='2s' | 
			
		
	
		
			
				
					|  |  |  | 						//   if(context_speed_name == 0){ | 
			
		
	
		
			
				
					|  |  |  | 						//   this.form.context_speed_name='1s' | 
			
		
	
		
			
				
					|  |  |  | 						// }else if(this.form.context_speed==1){ | 
			
		
	
		
			
				
					|  |  |  | 						//     this.form.context_speed_name='2s' | 
			
		
	
		
			
				
					|  |  |  | 						// }else{ | 
			
		
	
		
			
				
					|  |  |  | 						//     this.form.context_speed_name='3s' | 
			
		
	
		
			
				
					|  |  |  | 						// } | 
			
		
	
		
			
				
					|  |  |  | 						//判断文字大小 | 
			
		
	
		
			
				
					|  |  |  | 						if (this.form.context_size == 0) { | 
			
		
	
		
			
				
					|  |  |  | 							this.form.context_size_name = "16"; | 
			
		
	
		
			
				
					|  |  |  | 						} else if (this.form.context_size == 1) { | 
			
		
	
		
			
				
					|  |  |  | 							this.form.context_size_name = "22"; | 
			
		
	
		
			
				
					|  |  |  | 						} else if (this.form.context_size == 2) { | 
			
		
	
		
			
				
					|  |  |  | 							this.form.context_size_name = "24"; | 
			
		
	
		
			
				
					|  |  |  | 						} else { | 
			
		
	
		
			
				
					|  |  |  |                 this.form.context_speed_name='3s' | 
			
		
	
		
			
				
					|  |  |  | 							this.form.context_size_name = "30"; | 
			
		
	
		
			
				
					|  |  |  | 						} | 
			
		
	
		
			
				
					|  |  |  |              | 
			
		
	
		
			
				
					|  |  |  | 					} | 
			
		
	
		
			
				
					|  |  |  |       }) | 
			
		
	
		
			
				
					|  |  |  | 				}); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 新增 | 
			
		
	
		
			
				
					|  |  |  | 			addFormData() { | 
			
		
	
		
			
				
					|  |  |  | 				this.messageVisible = true; | 
			
		
	
		
			
				
					|  |  |  | 				this.$nextTick(() => { | 
			
		
	
		
			
				
					|  |  |  | 					this.form.notice_id = null; | 
			
		
	
		
			
				
					|  |  |  | 				}); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 提交 | 
			
		
	
		
			
				
					|  |  |  | 			submit() { | 
			
		
	
		
			
				
					|  |  |  | 				this.$refs.form.validate((valid) => { | 
			
		
	
		
			
				
					|  |  |  | 					// 修改 | 
			
		
	
		
			
				
					|  |  |  | 					if (valid) { | 
			
		
	
		
			
				
					|  |  |  | 						const params = { | 
			
		
	
		
			
				
					|  |  |  | 							context: this.form.context, | 
			
		
	
		
			
				
					|  |  |  | 							context_color: this.form.context_color, | 
			
		
	
	
		
			
				
					|  |  | @ -317,74 +464,112 @@ export default { | 
			
		
	
		
			
				
					|  |  |  | 							notice_device: this.form.notice_device, | 
			
		
	
		
			
				
					|  |  |  | 							notice_devices: this.form.notice_devices, | 
			
		
	
		
			
				
					|  |  |  | 							notice_id: this.form.notice_id, | 
			
		
	
		
			
				
					|  |  |  |          orga_id:'133221333123111' | 
			
		
	
		
			
				
					|  |  |  |        } | 
			
		
	
		
			
				
					|  |  |  |        reqEditMessage(params).then(res=>{ | 
			
		
	
		
			
				
					|  |  |  |          console.log(params) | 
			
		
	
		
			
				
					|  |  |  |          console.log(res) | 
			
		
	
		
			
				
					|  |  |  |        }) | 
			
		
	
		
			
				
					|  |  |  | 							orga_id: "133221333123111", | 
			
		
	
		
			
				
					|  |  |  | 						}; | 
			
		
	
		
			
				
					|  |  |  | 						reqEditMessage(params).then((res) => { | 
			
		
	
		
			
				
					|  |  |  | 							if (res.code == 200) { | 
			
		
	
		
			
				
					|  |  |  | 								this.$message({ | 
			
		
	
		
			
				
					|  |  |  | 									type: "success", | 
			
		
	
		
			
				
					|  |  |  | 									message: this.form.notice_id | 
			
		
	
		
			
				
					|  |  |  | 										? "修改紧急通知成功" | 
			
		
	
		
			
				
					|  |  |  | 										: "添加紧急通知成功", | 
			
		
	
		
			
				
					|  |  |  | 								}); | 
			
		
	
		
			
				
					|  |  |  | 								this.messageVisible = false; | 
			
		
	
		
			
				
					|  |  |  | 								this.getUrgentMessage(this.form.notice_id? this.queryInfo:1); | 
			
		
	
		
			
				
					|  |  |  | 							} | 
			
		
	
		
			
				
					|  |  |  | 						}); | 
			
		
	
		
			
				
					|  |  |  | 					} | 
			
		
	
		
			
				
					|  |  |  | 				}); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 所有设备和部分设备的切换数据处理 | 
			
		
	
		
			
				
					|  |  |  | 			clearCheckbox() { | 
			
		
	
		
			
				
					|  |  |  | 				if (this.form.notice_device == 1) { | 
			
		
	
		
			
				
					|  |  |  |         this.form.notice_devices=[] | 
			
		
	
		
			
				
					|  |  |  |       }else{ | 
			
		
	
		
			
				
					|  |  |  |         this.form.AllDevice=this.deviceList | 
			
		
	
		
			
				
					|  |  |  | 					this.form.notice_devices = []; | 
			
		
	
		
			
				
					|  |  |  | 				} | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  |       // 多选框 | 
			
		
	
		
			
				
					|  |  |  | 			handleSelectionChange(val) { | 
			
		
	
		
			
				
					|  |  |  |       this.selectedList = val | 
			
		
	
		
			
				
					|  |  |  |       if (val.length > 0) { | 
			
		
	
		
			
				
					|  |  |  |         this.clearBtnDisabled = false | 
			
		
	
		
			
				
					|  |  |  |       } else { | 
			
		
	
		
			
				
					|  |  |  |         this.clearBtnDisabled = true | 
			
		
	
		
			
				
					|  |  |  |       } | 
			
		
	
		
			
				
					|  |  |  |       // console.log(val) | 
			
		
	
		
			
				
					|  |  |  | 				this.selectedList = val; | 
			
		
	
		
			
				
					|  |  |  | 				// if (val.length > 0) { | 
			
		
	
		
			
				
					|  |  |  | 				// 	this.clearBtnDisabled = false; | 
			
		
	
		
			
				
					|  |  |  | 				// } else { | 
			
		
	
		
			
				
					|  |  |  | 				// 	this.clearBtnDisabled = true; | 
			
		
	
		
			
				
					|  |  |  | 				// } | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 改变文字的颜色 | 
			
		
	
		
			
				
					|  |  |  | 			headleChangeColor() { | 
			
		
	
		
			
				
					|  |  |  |       console.log(this.form.context_color) | 
			
		
	
		
			
				
					|  |  |  | 				this.form.context_size; | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 改变文字的大小 | 
			
		
	
		
			
				
					|  |  |  | 			selectSize(selVal) { | 
			
		
	
		
			
				
					|  |  |  | 				this.form.context_size = selVal.key; | 
			
		
	
		
			
				
					|  |  |  | 				this.form.context_size_name = selVal.name; | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 改变文字的位置 | 
			
		
	
		
			
				
					|  |  |  | 			selectPosition(selVal) { | 
			
		
	
		
			
				
					|  |  |  |       // console.log(selVal) | 
			
		
	
		
			
				
					|  |  |  |       this.form.context_position=selVal.key | 
			
		
	
		
			
				
					|  |  |  |       this.form.context_position_name=selVal.name | 
			
		
	
		
			
				
					|  |  |  | 				this.form.context_position = selVal.key; | 
			
		
	
		
			
				
					|  |  |  | 				this.form.context_position_name = selVal.name; | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 速度 | 
			
		
	
		
			
				
					|  |  |  | 			selectSpeed(selVal) { | 
			
		
	
		
			
				
					|  |  |  |        this.form.context_speed=selVal.key | 
			
		
	
		
			
				
					|  |  |  |        this.form.context_speed_name=selVal.name | 
			
		
	
		
			
				
					|  |  |  | 				this.form.context_speed = selVal.key; | 
			
		
	
		
			
				
					|  |  |  | 				this.form.context_speed_name = selVal.name; | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			//添加设备的对话框 | 
			
		
	
		
			
				
					|  |  |  | 			addDeviceTag() { | 
			
		
	
		
			
				
					|  |  |  |       this.selectDeviceVisible = true | 
			
		
	
		
			
				
					|  |  |  | 				this.selectDeviceVisible = true; | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 添加设备 | 
			
		
	
		
			
				
					|  |  |  | 			tagHandle(tag) { | 
			
		
	
		
			
				
					|  |  |  |       this.form.notice_devices.push({deviceId:tag.device_id}) | 
			
		
	
		
			
				
					|  |  |  | 				// 收集参数 部分设备的列表 | 
			
		
	
		
			
				
					|  |  |  | 				if (this.form.notice_devices.length == 0) { | 
			
		
	
		
			
				
					|  |  |  | 					this.form.notice_devices.push({ deviceId: tag.device_id }); | 
			
		
	
		
			
				
					|  |  |  | 				} else { | 
			
		
	
		
			
				
					|  |  |  | 					const result = this.form.notice_devices.some((item) => { | 
			
		
	
		
			
				
					|  |  |  | 						return item.deviceId == tag.device_id; | 
			
		
	
		
			
				
					|  |  |  | 					}); | 
			
		
	
		
			
				
					|  |  |  | 					if (!result) { | 
			
		
	
		
			
				
					|  |  |  | 						this.form.notice_devices.push({ deviceId: tag.device_id }); | 
			
		
	
		
			
				
					|  |  |  | 					} | 
			
		
	
		
			
				
					|  |  |  | 				} | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | 				// 添加设备不能重复 不重复才添加 | 
			
		
	
		
			
				
					|  |  |  | 				if (this.deviceTags.length == 0) { | 
			
		
	
		
			
				
					|  |  |  |         this.deviceTags.push(tag) | 
			
		
	
		
			
				
					|  |  |  | 					this.deviceTags.push(tag); | 
			
		
	
		
			
				
					|  |  |  | 				} else { | 
			
		
	
		
			
				
					|  |  |  |         const current = this.deviceTags &&this.deviceTags.some((item) => item.device_name == tag.device_name ) | 
			
		
	
		
			
				
					|  |  |  |        // 查找是否存在相同的 | 
			
		
	
		
			
				
					|  |  |  |       console.log('current', current) | 
			
		
	
		
			
				
					|  |  |  | 					const current = | 
			
		
	
		
			
				
					|  |  |  | 						this.deviceTags && | 
			
		
	
		
			
				
					|  |  |  | 						this.deviceTags.some((item) => item.device_name == tag.device_name); | 
			
		
	
		
			
				
					|  |  |  | 					if (!current) { | 
			
		
	
		
			
				
					|  |  |  |         this.deviceTags.push(tag)   | 
			
		
	
		
			
				
					|  |  |  | 						this.deviceTags.push(tag); | 
			
		
	
		
			
				
					|  |  |  | 					} else { | 
			
		
	
		
			
				
					|  |  |  | 						this.$message("请勿添加重复的设备!"); | 
			
		
	
		
			
				
					|  |  |  | 					} | 
			
		
	
		
			
				
					|  |  |  | 					// !this.deviceTags.some(item => item.device_name === tag.device_name) | 
			
		
	
		
			
				
					|  |  |  | 					//  && this.deviceTags.push(tag) | 
			
		
	
		
			
				
					|  |  |  | 				} | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 单独删除某一个设备 | 
			
		
	
		
			
				
					|  |  |  | 			handleClose(tag) { | 
			
		
	
		
			
				
					|  |  |  |       this.deviceTags.splice(this.deviceTags.indexOf(tag), 1) | 
			
		
	
		
			
				
					|  |  |  |       // console.log(this.deviceTags) | 
			
		
	
		
			
				
					|  |  |  | 				this.deviceTags.splice(this.deviceTags.indexOf(tag), 1); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  | 			// 清空设备 | 
			
		
	
		
			
				
					|  |  |  | 			clearDevice() { | 
			
		
	
		
			
				
					|  |  |  |       this.deviceTags = [] | 
			
		
	
		
			
				
					|  |  |  | 				this.deviceTags = []; | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  |   } | 
			
		
	
		
			
				
					|  |  |  | } | 
			
		
	
		
			
				
					|  |  |  | 			// 关闭重置表单 | 
			
		
	
		
			
				
					|  |  |  | 			closeDialog() { | 
			
		
	
		
			
				
					|  |  |  | 				this.messageVisible = false; | 
			
		
	
		
			
				
					|  |  |  | 				this.$refs.form.resetFields(); | 
			
		
	
		
			
				
					|  |  |  | 			}, | 
			
		
	
		
			
				
					|  |  |  |       // 每条显示数据改变时的事件 | 
			
		
	
		
			
				
					|  |  |  |      handleSizeChange(size) { | 
			
		
	
		
			
				
					|  |  |  |       //整理参数 | 
			
		
	
		
			
				
					|  |  |  |       this.queryInfo.size = size | 
			
		
	
		
			
				
					|  |  |  |       this.getUrgentMessage(); | 
			
		
	
		
			
				
					|  |  |  |     }, | 
			
		
	
		
			
				
					|  |  |  | 		}, | 
			
		
	
		
			
				
					|  |  |  | 	}; | 
			
		
	
		
			
				
					|  |  |  | </script> | 
			
		
	
		
			
				
					|  |  |  | 
 | 
			
		
	
		
			
				
					|  |  |  | <style lang="scss" scoped> | 
			
		
	
	
		
			
				
					|  |  | @ -427,7 +612,7 @@ export default { | 
			
		
	
		
			
				
					|  |  |  | 		font-size: 12px; | 
			
		
	
		
			
				
					|  |  |  | 		color: #999; | 
			
		
	
		
			
				
					|  |  |  | 		background: #fff; | 
			
		
	
		
			
				
					|  |  |  |   box-shadow: 0 0 5px rgba(0,0,0,.14); | 
			
		
	
		
			
				
					|  |  |  | 		box-shadow: 0 0 5px rgba(0, 0, 0, 0.14); | 
			
		
	
		
			
				
					|  |  |  | 	} | 
			
		
	
		
			
				
					|  |  |  | 	.select_other { | 
			
		
	
		
			
				
					|  |  |  | 		width: 600px; | 
			
		
	
	
		
			
				
					|  |  | 
 |