mirror of
https://gitee.com/java110/MicroCommunityWeb.git
synced 2026-02-24 21:59:12 +08:00
优化代码
This commit is contained in:
parent
70abada764
commit
f91e67dd79
20
app.js
20
app.js
@ -40,20 +40,20 @@ let opts = {
|
||||
}
|
||||
|
||||
// todo 测试环境 测试使用,生产环境请用nginx带来
|
||||
// app.use('/callComponent', proxy('http://192.168.100.108:8088', opts));
|
||||
// app.use('/app', proxy('http://192.168.100.108:8088', opts));
|
||||
// app.use('/ws', createProxyMiddleware({
|
||||
// target: 'http://192.168.100.108:8008',
|
||||
// changeOrigin: true,
|
||||
// ws: true
|
||||
// }));
|
||||
app.use('/callComponent', proxy('http://192.168.100.108:8088', opts));
|
||||
app.use('/app', proxy('http://192.168.100.108:8088', opts));
|
||||
app.use('/ws', createProxyMiddleware({
|
||||
target: 'http://192.168.100.108:8008',
|
||||
changeOrigin: true,
|
||||
ws: true
|
||||
}));
|
||||
|
||||
|
||||
|
||||
// todo 本机 开发用,生产环境请用nginx带来
|
||||
app.use('/ws', proxy('http://127.0.0.1:8008', opts));
|
||||
app.use('/callComponent', proxy('http://127.0.0.1:8008', opts));
|
||||
app.use('/app', proxy('http://127.0.0.1:8008', opts));
|
||||
// app.use('/ws', proxy('http://127.0.0.1:8008', opts));
|
||||
// app.use('/callComponent', proxy('http://127.0.0.1:8008', opts));
|
||||
// app.use('/app', proxy('http://127.0.0.1:8008', opts));
|
||||
|
||||
//app.listen(3000);
|
||||
app.use(express.json());
|
||||
|
||||
@ -136,7 +136,34 @@
|
||||
vc.jumpToPage('/#/pages/property/parkingAreaText?paId=' + _parkingArea.paId)
|
||||
},
|
||||
_openParkingAreaTotalControl: function (_parkingArea) {
|
||||
vc.jumpToIot('/#/pages/car/parkingAreaTotalControl?paId=' + _parkingArea.paId);
|
||||
|
||||
//todo 查询物联网停车场ID
|
||||
let param = {
|
||||
params: {
|
||||
page:1,
|
||||
row:1,
|
||||
communityId:vc.getCurrentCommunity().communityId,
|
||||
num:_parkingArea.num,
|
||||
iotApiCode:'listParkingAreaBmoImpl'
|
||||
}
|
||||
};
|
||||
//发送get请求
|
||||
vc.http.apiGet('/iot.getOpenApi',
|
||||
param,
|
||||
function (json, res) {
|
||||
let _json = JSON.parse(json);
|
||||
if(!_json.data || _json.data.length < 0){
|
||||
vc.toast('物联网系统不存在该停车场');
|
||||
return ;
|
||||
}
|
||||
vc.jumpToIot('/#/pages/car/parkingAreaTotalControl?paId=' + _json.data[0].paId);
|
||||
},
|
||||
function (errInfo, error) {
|
||||
console.log('请求失败处理');
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@ -113,7 +113,7 @@
|
||||
</table>
|
||||
<!-- 分页 -->
|
||||
<div>
|
||||
<div class="col-sm-7">
|
||||
<div class="col-sm-5">
|
||||
数据来源于物联网系统,请到物联网系统管理数据
|
||||
</div>
|
||||
<div class="col-sm-7">
|
||||
|
||||
Loading…
Reference in New Issue
Block a user