Commit e5a4f52f authored by caicaicai's avatar caicaicai

修改

parent 97a770e9
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<!-- <title><%= htmlWebpackPlugin.options.title %></title> --> <!-- <title><%= htmlWebpackPlugin.options.title %></title> -->
<title>鑫海数字矿山后台管理系统</title> <title>卡车调度系统终端平台</title>
<script> <script>
window.basePathUrl = '<%= BASE_URL %>' //标识config、widgets所在的目录 window.basePathUrl = '<%= BASE_URL %>' //标识config、widgets所在的目录
......
...@@ -21,3 +21,10 @@ export const intelligentDispatchQuery = '/api/Manmades'; //获取绩效统计— ...@@ -21,3 +21,10 @@ export const intelligentDispatchQuery = '/api/Manmades'; //获取绩效统计—
export const updatePass = '/api/users/updatePass'; //修改个人信息密码 export const updatePass = '/api/users/updatePass'; //修改个人信息密码
export const carFleetQuery = '/api/CarRoad'; //获取语音申请车队 export const carFleetQuery = '/api/CarRoad'; //获取语音申请车队
export const carsInforQuery = '/api/CarBreak'; //获取语音申请车辆 export const carsInforQuery = '/api/CarBreak'; //获取语音申请车辆
export const faultInforQuery = '/api/BreakClass'; //获取车辆故障类型
export const carRealTimeLocationQuery1 = '/gps/all'; //获取车辆实时位置
export const carRealTimeLocationQuery2 = '/gps'; //获取一个车辆位置
export const faultDayAdd = '/api/Fault'; //添加故障日报
export const faultMonthAdd = '/api/FaultMonth'; //添加故障月报
export const faultYearAdd = '/api/FaultYear'; //添加故障年报
export const waitingtrucksQuery = '/api/Dispatch/waitingtrucks'; //获取待装车卡车列表
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<div style="background: white"> <div style="background: white">
<el-container> <el-container>
<el-header style="font-size: 20px; font-weight: bold" <el-header style="font-size: 20px; font-weight: bold"
>鑫海矿业监控视频</el-header >卡车调度系统终端平台监控视频</el-header
> >
<el-container> <el-container>
......
...@@ -40,8 +40,8 @@ const automation = { ...@@ -40,8 +40,8 @@ const automation = {
//默认vuex //默认vuex
export default new Vuex.Store({ export default new Vuex.Store({
state: { state: {
projectName:"鑫海数字矿山后台管理系统", projectName:"卡车调度系统终端平台",
platformName:"鑫海数字矿山后台管理平台", platformName:"卡车调度系统终端平台",
}, },
mutations: { mutations: {
......
...@@ -12,17 +12,17 @@ ...@@ -12,17 +12,17 @@
<el-radio v-model="from.car" label="其他车辆故障" border>其他车辆故障</el-radio> <el-radio v-model="from.car" label="其他车辆故障" border>其他车辆故障</el-radio>
</div> </div>
</div> </div>
<div>
<span>车辆名称:</span>
<el-input v-model="from.carname" placeholder="请输入车辆名称" style="width:18vw;font-size:18px;"></el-input>
</div>
<div> <div>
<span>车辆号码:</span> <span>车辆号码:</span>
<el-input v-model="from.carcode" placeholder="请输入车辆号码" style="width:18vw;font-size:18px;"></el-input> <el-select v-model="from.carcode" placeholder="请选择车辆号码" style="width:18vw;">
<el-option v-for="(obj,index) in carInforData" :label="obj.number" :value="obj.number" :key="index"></el-option>
</el-select>
</div> </div>
<div> <div>
<span>司机名称:</span> <span>司机名称:</span>
<el-input v-model="from.name" placeholder="请输入司机名称" style="width:18vw;font-size:18px;"></el-input> <el-select v-model="from.name" placeholder="请选择司机名称" style="width:18vw;">
<el-option v-for="(obj,index) in peopleInforData" :label="obj.name" :value="obj.name" :key="index"></el-option>
</el-select>
</div> </div>
<div style="display:flex;"> <div style="display:flex;">
<span>车辆位置:</span> <span>车辆位置:</span>
...@@ -30,13 +30,12 @@ ...@@ -30,13 +30,12 @@
<img src="../../../../assets/images/truckTuPian/dingwei1.png" height="20"> <img src="../../../../assets/images/truckTuPian/dingwei1.png" height="20">
<span style="color: rgb(24,228,240);font-size:18px;margin-top:-10px;text-decoration:underline;">{{getLocationText}}</span> <span style="color: rgb(24,228,240);font-size:18px;margin-top:-10px;text-decoration:underline;">{{getLocationText}}</span>
</div> </div>
<span style="margin-left:10px;" v-if="zuobiaoShow">坐标:{{parseFloat(from.lat).toFixed(2)}},{{parseFloat(from.lon).toFixed(2)}}</span>
</div> </div>
<div> <div>
<span>故障类型:</span> <span>故障类型:</span>
<el-select v-model="from.fault" placeholder="请选择故障类型" style="width:18vw;"> <el-select v-model="from.fault" placeholder="请选择故障类型" style="width:18vw;">
<el-option label="车辆碰撞" value="车辆碰撞" style="font-size:18px;"></el-option> <el-option v-for="(obj,index) in faultInforData" :label="obj.breakclass" :value="obj.breakclass" :key="index"></el-option>
<el-option label="爆胎" value="爆胎" style="font-size:18px;"></el-option>
<el-option label="缺油" value="缺油" style="font-size:18px;"></el-option>
</el-select> </el-select>
</div> </div>
<div> <div>
...@@ -59,31 +58,56 @@ ...@@ -59,31 +58,56 @@
<script> <script>
import { httpGet, httpPostForJson, putForJson, httpDelForJson} from "@/common/httpBean.js" import { httpGet, httpPostForJson, putForJson, httpDelForJson} from "@/common/httpBean.js"
import {failureDeclarationAdd} from "@/axios/api.js" import {failureDeclarationAdd,vehicleInformationQuery,personalCenterInforQuery,faultInforQuery,carRealTimeLocationQuery2,faultDayAdd,faultMonthAdd,faultYearAdd} from "@/axios/api.js"
export default { export default {
data() { data() {
return { return {
showDecide:false, showDecide:false,
from:{carcode:''}, from:{car:'',carcode:'',name:'',fault:'',problem:'',lat:'',lon:''},
getLocationText:'点击获取车辆位置', getLocationText:'点击获取车辆位置',
submitLoading:false, submitLoading:false,
carnumber:'',
personName:'',
carInforData:[],
peopleInforData:[],
faultInforData:[],
zuobiaoShow:false,
} }
}, },
mounted() { }, mounted() { },
methods: { methods: {
loadData(value) { loadData(carnumber,personName) {
this.showDecide = true; this.showDecide = true;
this.from = {carcode:''}; this.carnumber = carnumber;
this.personName = personName;
this.from = {car:'',carcode:'',name:'',fault:'',problem:'',lat:'',lon:''};
this.getLocationText = '点击获取车辆位置'; this.getLocationText = '点击获取车辆位置';
httpGet(vehicleInformationQuery,{size:9999}).then((res) => {
if(res.code == 200){
this.carInforData = res.data.content;
}
});
httpGet(personalCenterInforQuery,{size:9999}).then((res) => {
if(res.code == 200){
this.peopleInforData = res.data.content;
}
});
httpGet(faultInforQuery,{size:9999}).then((res) => {
if(res.code == 200){
this.faultInforData = res.data.content;
}
});
}, },
failureDeCloseFn(){ failureDeCloseFn(){
this.showDecide = false; this.showDecide = false;
this.from = {carcode:''}; this.zuobiaoShow = false;
this.from = {car:'',carcode:'',name:'',fault:'',problem:'',lat:'',lon:''};
this.getLocationText = '点击获取车辆位置'; this.getLocationText = '点击获取车辆位置';
}, },
//获取车辆位置 //获取车辆位置
getLocationFn(){ getLocationFn(){
let that = this;
if(this.from.carcode == ''){ if(this.from.carcode == ''){
this.$notify({ this.$notify({
title: '请输入车辆号码!', title: '请输入车辆号码!',
...@@ -91,14 +115,39 @@ export default { ...@@ -91,14 +115,39 @@ export default {
duration: 2500 duration: 2500
}) })
}else{ }else{
this.getLocationText = '已获取车辆位置'; httpGet(vehicleInformationQuery,{number:this.from.carcode}).then((res) => {
this.from.adr = '13.545,36.252'; if(res.code == 200){
if(res.data.content[0].equipmentName == '' || !res.data.content[0].equipmentName){
this.$notify({
title: '暂无车辆位置!',
type: 'error',
duration: 2500
})
}else{
httpGet(carRealTimeLocationQuery2,{name:res.data.content[0].equipmentName}).then((res1) => {
if(res1.code == 200){
that.from.lat = res1.data.lat;
that.from.lon = res1.data.lon;
that.zuobiaoShow = true;
this.$notify({
title: '获取成功!',
type: 'success',
duration: 2500
})
}
});
}
}
});
} }
}, },
//提交申报 //提交申报
submitDeFn(){ submitDeFn(){
this.submitLoading = true; this.submitLoading = true;
httpPostForJson(faultDayAdd,this.from).then((res) => {});
httpPostForJson(faultMonthAdd,this.from).then((res) => {});
httpPostForJson(faultYearAdd,this.from).then((res) => {});
httpPostForJson(failureDeclarationAdd,this.from).then((res) => { httpPostForJson(failureDeclarationAdd,this.from).then((res) => {
if(res.code == 200){ if(res.code == 200){
if(res.code == 200){ if(res.code == 200){
...@@ -107,27 +156,45 @@ export default { ...@@ -107,27 +156,45 @@ export default {
type: 'success', type: 'success',
duration: 2500 duration: 2500
}); });
this.from = {carcode:''}; this.from = {car:'',carcode:'',name:'',fault:'',problem:'',lat:'',lon:''};
this.getLocationText = '点击获取车辆位置'; this.getLocationText = '点击获取车辆位置';
this.submitLoading = false; this.submitLoading = false;
this.zuobiaoShow = false;
}else{ }else{
this.$notify({ this.$notify({
title: res.head.message, title: res.head.message,
type: 'error', type: 'error',
duration: 2500 duration: 2500
}) })
this.from = {carcode:''}; this.from = {car:'',carcode:'',name:'',fault:'',problem:'',lat:'',lon:''};
this.getLocationText = '点击获取车辆位置'; this.getLocationText = '点击获取车辆位置';
this.submitLoading = false; this.submitLoading = false;
this.zuobiaoShow = false;
} }
} }
}); });
} },
} },
watch:{
'from.car':function(){
if(this.from.car == '当前车辆故障'){
this.from.carcode = this.carnumber;
this.from.name = this.personName;
}else{
this.from.carcode = '';
this.from.name = '';
}
},
},
} }
</script> </script>
<style scope> <style scope>
.el-select-dropdown__item{
font-size: 20px;
height: 45px;
line-height: 45px;
}
.failureDeMainViews{ .failureDeMainViews{
position: absolute; position: absolute;
z-index: 1; z-index: 1;
......
...@@ -14,16 +14,12 @@ ...@@ -14,16 +14,12 @@
<div class="voiceAppContent_2"> <div class="voiceAppContent_2">
<div> <div>
<div class="voiceAppContent_2_title"> <div class="voiceAppContent_2_title">
<div>车辆名称</div>
<div>车牌号</div> <div>车牌号</div>
<!-- <div>终端设备</div> -->
</div> </div>
<div class="voiceAppContent_2_content"> <div class="voiceAppContent_2_content">
<el-checkbox-group v-model="selectCarRadioArray"> <el-checkbox-group v-model="selectCarRadioArray">
<el-checkbox v-for="(item,index) in carsInforData" :label="item" :key="index" style="margin-top:10px;"> <el-checkbox v-for="(item,index) in carsInforData" :label="item" :key="index" style="margin-top:10px;">
<div style="width:14vw">{{item.name}}</div> <div style="width:20vw;text-align: center;">{{item.number}}</div>
<div style="width:7.5vw">{{item.number}}</div>
<!-- <div>{{item.equipmentName}}</div> -->
</el-checkbox> </el-checkbox>
</el-checkbox-group> </el-checkbox-group>
</div> </div>
...@@ -34,7 +30,6 @@ ...@@ -34,7 +30,6 @@
</div> </div>
<div class="voiceAppContent_2_3_content"> <div class="voiceAppContent_2_3_content">
<div v-for="(item,index) in selectCarRadioArray" :key="index" class="voiceAppContent_2_content_selectCar"> <div v-for="(item,index) in selectCarRadioArray" :key="index" class="voiceAppContent_2_content_selectCar">
<div>车辆名称:{{item.name}}</div>
<div>车牌号:{{item.number}}</div> <div>车牌号:{{item.number}}</div>
<div style="width:27px;height:27px;background-color: rgb(4,112,171);text-align: center;font-size:40px;" @click="cancelSelect(index)"> <div style="width:27px;height:27px;background-color: rgb(4,112,171);text-align: center;font-size:40px;" @click="cancelSelect(index)">
<span>×</span> <span>×</span>
...@@ -119,7 +114,7 @@ ...@@ -119,7 +114,7 @@
<script> <script>
import { httpGet, httpPostForJson, putForJson, httpDelForJson} from "@/common/httpBean.js" import { httpGet, httpPostForJson, putForJson, httpDelForJson} from "@/common/httpBean.js"
import {carFleetQuery,carsInforQuery} from "@/axios/api.js" import {carFleetQuery,carsInforQuery,vehicleInformationQuery} from "@/axios/api.js"
import situationPic1 from '../../../../assets/images/truckTuPian/tonghuazhong1.png' import situationPic1 from '../../../../assets/images/truckTuPian/tonghuazhong1.png'
import situationPic2 from '../../../../assets/images/truckTuPian/tonghuazhong2.png' import situationPic2 from '../../../../assets/images/truckTuPian/tonghuazhong2.png'
//加载必须要的core,demo简化起见采用的直接加载类库,实际使用时应当采用异步按需加载 //加载必须要的core,demo简化起见采用的直接加载类库,实际使用时应当采用异步按需加载
...@@ -187,7 +182,7 @@ export default { ...@@ -187,7 +182,7 @@ export default {
this.selectCarRadioArray = []; this.selectCarRadioArray = [];
this.situationWhich = 10000; this.situationWhich = 10000;
this.userName1 = value; this.userName1 = value;
//this.recOpen() this.recOpen();
//车队 //车队
httpGet(carFleetQuery,{size:9999,page:0}).then((res) => { httpGet(carFleetQuery,{size:9999,page:0}).then((res) => {
if(res.code == 200){ if(res.code == 200){
...@@ -208,7 +203,7 @@ export default { ...@@ -208,7 +203,7 @@ export default {
query.number = this.searchText; query.number = this.searchText;
query.road = this.selectCarFleet; query.road = this.selectCarFleet;
//车辆 //车辆
httpGet(carsInforQuery,query).then((res) => { httpGet(vehicleInformationQuery,query).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.carsInforData = res.data.content; this.carsInforData = res.data.content;
} }
...@@ -407,6 +402,7 @@ export default { ...@@ -407,6 +402,7 @@ export default {
}); });
this.tonghua1 = '开始通话'; this.tonghua1 = '开始通话';
this.tonghuadisabled = false; this.tonghuadisabled = false;
this.recOpen();
}, },
...@@ -479,6 +475,7 @@ export default { ...@@ -479,6 +475,7 @@ export default {
type: 'success', type: 'success',
duration: 2500 duration: 2500
}); });
} else if (This.websocket.readyState === 0) { // 表示正在连接,设置300ms后发送信息 } else if (This.websocket.readyState === 0) { // 表示正在连接,设置300ms后发送信息
setTimeout(function () { setTimeout(function () {
This.websocketsend(`{"toUserId":"${This.carAllNumberString}","contentText":"${postData}","fromUserId":"${This.userName1}"}`); This.websocketsend(`{"toUserId":"${This.carAllNumberString}","contentText":"${postData}","fromUserId":"${This.userName1}"}`);
...@@ -700,6 +697,9 @@ export default { ...@@ -700,6 +697,9 @@ export default {
width: 200px; width: 200px;
height: 50px; height: 50px;
} }
.el-input__inner{
font-size: 18px;
}
.voiceAppMainViews{ .voiceAppMainViews{
position: absolute; position: absolute;
z-index: 1; z-index: 1;
......
...@@ -185,7 +185,7 @@ export default { ...@@ -185,7 +185,7 @@ export default {
this.$refs.personalCenterMethod.personalCenCloseFn(); this.$refs.personalCenterMethod.personalCenCloseFn();
this.$refs.smallWindowMethod.carInCloseFn(); this.$refs.smallWindowMethod.carInCloseFn();
let byValue = this.carName; let byValue = this.carName;
this.$refs.failureDeclarationMethod.loadData(byValue); this.$refs.failureDeclarationMethod.loadData(this.carnumber,this.personalName);
}else{ }else{
this.selectFunction = 0; this.selectFunction = 0;
this.$refs.voiceApplicationMethod.voiceAppCloseFn(); this.$refs.voiceApplicationMethod.voiceAppCloseFn();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment