Commit c91a9953 by 前端

Merge branch 'develop' into 'master'

V1.11.0版本需求已上线,合并代码到master

See merge request !49
2 parents 4fd74085 b7f60a5b
...@@ -111,6 +111,16 @@ function getAdjFreqInfo(params) { ...@@ -111,6 +111,16 @@ function getAdjFreqInfo(params) {
return request(params, '/trialdrive/vehicle/getadjfreqinfo'); return request(params, '/trialdrive/vehicle/getadjfreqinfo');
} }
// 获取生效调频记录详情
function GET_FREQ_DETAILS(params) {
return request(params, '/trialdrive/vehicle/effectFreqInfo');
}
// 关闭调频
function REST_FREQ_INFO(params) {
return request({}, '/trialdrive/vehicle/resetAdjFreq?sn=' + params.sn, "post");
}
export { export {
getList, getList,
getSpecialShopList, getSpecialShopList,
...@@ -134,4 +144,6 @@ export { ...@@ -134,4 +144,6 @@ export {
deleteNewVehicle, deleteNewVehicle,
updateNewVehicle, updateNewVehicle,
getAdjFreqInfo, getAdjFreqInfo,
GET_FREQ_DETAILS,
REST_FREQ_INFO
}; };
...@@ -4,18 +4,18 @@ import { Message } from 'element-ui'; ...@@ -4,18 +4,18 @@ import { Message } from 'element-ui';
import { debounce } from 'utils/tools'; import { debounce } from 'utils/tools';
const error = debounce((msg, getToken) => { const error = debounce((msg, getToken) => {
if(window.__POWERED_BY_QIANKUN__) { if (window.__POWERED_BY_QIANKUN__) {
let stateRes = { let stateRes = {
errorMsg: msg, errorMsg: msg,
showLoading: false showLoading: false
}; };
if(getToken === 'removeToken') { if (getToken === 'removeToken') {
stateRes.token = getToken; stateRes.token = getToken;
localStorage.removeItem('token'); localStorage.removeItem('token');
} }
actions.setGlobalState(stateRes); actions.setGlobalState(stateRes);
} else { } else {
if(msg) { if (msg) {
Message({ Message({
message: msg, message: msg,
type: 'error' type: 'error'
...@@ -25,7 +25,7 @@ const error = debounce((msg, getToken) => { ...@@ -25,7 +25,7 @@ const error = debounce((msg, getToken) => {
}, 1000, true); }, 1000, true);
const showLoading = (status) => { const showLoading = (status) => {
if(window.__POWERED_BY_QIANKUN__) { if (window.__POWERED_BY_QIANKUN__) {
actions.setGlobalState({ actions.setGlobalState({
token: localStorage.getItem('token') || '', token: localStorage.getItem('token') || '',
errorMsg: '', errorMsg: '',
...@@ -75,6 +75,13 @@ const checkStatus = (status, msg) => { ...@@ -75,6 +75,13 @@ const checkStatus = (status, msg) => {
break; break;
case 603: case 603:
error('尚未登录或登录已过期,请重新登录', 'removeToken'); error('尚未登录或登录已过期,请重新登录', 'removeToken');
localStorage.removeItem('token');
localStorage.removeItem('userInfo');
localStorage.removeItem('breadcrumb');
//store.dispatch('app/setToken', '');
setTimeout(() => {
window.location.reload();
}, 10)
break; break;
case 505: case 505:
error('http版本不支持该请求!'); error('http版本不支持该请求!');
...@@ -87,7 +94,7 @@ const checkStatus = (status, msg) => { ...@@ -87,7 +94,7 @@ const checkStatus = (status, msg) => {
break; break;
default: default:
} }
} }
export { export {
checkStatus, checkStatus,
......
...@@ -276,19 +276,23 @@ ...@@ -276,19 +276,23 @@
<table class="freq_table el_table" v-loading="freqLoading"> <table class="freq_table el_table" v-loading="freqLoading">
<tr> <tr>
<th width="20%">调频时间</th> <th width="20%">调频时间</th>
<th width="16%">调频模式</th> <th width="14%">调频模式</th>
<th width="10%">上点频次</th> <th width="14%">上点频次</th>
<th width="14%">调频上点个数</th> <th width="14%">持续时长</th>
<th width="16%">设备上点总个数</th> <th width="14%">设备是否响应</th>
<th width="10%">剩余电量</th> <!-- <th width="10%">调频上点个数</th>
<th width="14%">调频操作人</th> <th width="10%">设备上点总个数</th> -->
<th width="14%">剩余电量</th>
<th width="10%">调频操作人</th>
</tr> </tr>
<tr v-for="(item,index) in freqTableData" :key="index"> <tr v-for="(item,index) in freqTableData" :key="index">
<td>{{item.createTime}}</td> <td>{{item.createTime}}</td>
<td>{{item.freqTypeStr}}</td> <td>{{item.freqTypeStr}}</td>
<td>{{item.frequency}}</td> <td>{{item.frequency}}</td>
<td>{{item.freTotal}}</td> <td>{{item.duration == '-1'?'永久有效':(item.duration?(item.duration+ '分钟'):'--')}}</td>
<td>{{item.devicePointTotal}}</td> <td>{{responseStatusList[item.responseStatus]||'--'}}</td>
<!-- <td>{{item.freTotal}}</td>
<td>{{item.devicePointTotal}}</td> -->
<td>{{item.batteryLevel}}%</td> <td>{{item.batteryLevel}}%</td>
<td>{{item.operation}}</td> <td>{{item.operation}}</td>
</tr> </tr>
...@@ -344,7 +348,7 @@ ...@@ -344,7 +348,7 @@
<!-- 车辆归属弹框 end --> <!-- 车辆归属弹框 end -->
<!-- 一键调频 弹框 开始 --> <!-- 一键调频 弹框 开始 -->
<freq-modal :freqVisible="freqVisible" :frequencyForm="frequencyForm" @onFreqModalChange="FreqModalChange" :sn="freqSn" :enableFreq="enableFreq"></freq-modal> <freq-modal :freqVisible="freqVisible" v-if="freqVisible" :frequencyForm="frequencyForm" @onFreqModalChange="FreqModalChange" :sn="freqSn" :enableFreq="enableFreq"></freq-modal>
<!-- 一键调频 弹框 end --> <!-- 一键调频 弹框 end -->
</div> </div>
...@@ -833,6 +837,10 @@ export default { ...@@ -833,6 +837,10 @@ export default {
ajaxLoading: false, ajaxLoading: false,
settleFlagList: SETTLEFLAGLIST, settleFlagList: SETTLEFLAGLIST,
SETTLE_FLAG_LIST, SETTLE_FLAG_LIST,
responseStatusList:{
1:'发送中',
2:'是'
}
}; };
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!