11
This commit is contained in:
parent
a65b8312e1
commit
dd626b5618
|
@ -19,13 +19,13 @@ const install = (Vue, vm) => {
|
||||||
|
|
||||||
// },
|
// },
|
||||||
// });
|
// });
|
||||||
uni.setStorageSync('deptId', 101);
|
uni.setStorageSync('deptId', 100);
|
||||||
Vue.prototype.$u.http.setConfig({
|
Vue.prototype.$u.http.setConfig({
|
||||||
// baseUrl: 'http://61.174.243.28:15861',
|
// baseUrl: 'http://61.174.243.28:15861',
|
||||||
// baseUrl: 'http://192.168.2.14:8080',
|
// baseUrl: 'http://192.168.2.14:8080',
|
||||||
// baseUrl: 'http://124.221.246.124:2289',
|
// baseUrl: 'http://124.221.246.124:2289',
|
||||||
baseUrl: 'https://dianche.chuantewulian.cn/prod-api',
|
// baseUrl: 'https://dianche.chuantewulian.cn/prod-api',
|
||||||
// baseUrl: 'https://dche.ccttiot.com/prod-api',
|
baseUrl: 'https://dche.ccttiot.com/prod-api',
|
||||||
loadingText: '努力加载中~',
|
loadingText: '努力加载中~',
|
||||||
// loadingTime: 2000,
|
// loadingTime: 2000,
|
||||||
// 设置自定义头部content-type
|
// 设置自定义头部content-type
|
||||||
|
|
|
@ -51,7 +51,7 @@
|
||||||
/* 小程序特有相关 */
|
/* 小程序特有相关 */
|
||||||
"mp-weixin" : {
|
"mp-weixin" : {
|
||||||
"libVersion" : "latest",
|
"libVersion" : "latest",
|
||||||
"appid" : "wx4d178f8c80348214",
|
"appid" : "wx3428c498d5061192",
|
||||||
"setting" : {
|
"setting" : {
|
||||||
"urlCheck" : false
|
"urlCheck" : false
|
||||||
},
|
},
|
||||||
|
|
95
page_user/bulelink.vue
Normal file
95
page_user/bulelink.vue
Normal file
|
@ -0,0 +1,95 @@
|
||||||
|
<template>
|
||||||
|
<view class="page">
|
||||||
|
<u-navbar :title="info.title" :border-bottom="false" :background="bgc" title-color='#000' title-size='36'
|
||||||
|
height='45'></u-navbar>
|
||||||
|
<view class="cont" v-html="content"></view>
|
||||||
|
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
bgc: {
|
||||||
|
backgroundColor: "#fff",
|
||||||
|
},
|
||||||
|
content: '',
|
||||||
|
info:{}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad() {
|
||||||
|
this.getword()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
// getclass() {
|
||||||
|
|
||||||
|
// this.$u.get("/app/classify/list?&parentId=111?&classifyId=114" ).then((res) => {
|
||||||
|
|
||||||
|
// if (res.code == 200) {
|
||||||
|
// this.classlist = res.data
|
||||||
|
// let id =this.classlist[0].classifyId
|
||||||
|
// this.getword(id)
|
||||||
|
// } else {
|
||||||
|
// // uni.showToast({
|
||||||
|
// // title: res.msg,
|
||||||
|
// // icon: 'none',
|
||||||
|
// // duration: 2000
|
||||||
|
// // });
|
||||||
|
// }
|
||||||
|
// });
|
||||||
|
// },
|
||||||
|
getword() {
|
||||||
|
|
||||||
|
this.$u.get("/app/article/list?classifyId=" + 100).then((res) => {
|
||||||
|
|
||||||
|
if (res.code == 200) {
|
||||||
|
this.info = res.rows.find(item => item.articleId == 18);
|
||||||
|
this.content = this.info.content
|
||||||
|
this.content = this.replaceImgWithImage(this.content)
|
||||||
|
|
||||||
|
} else {
|
||||||
|
// uni.showToast({
|
||||||
|
// title: res.msg,
|
||||||
|
// icon: 'none',
|
||||||
|
// duration: 2000
|
||||||
|
// });
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
replaceImgWithImage(content) {
|
||||||
|
// 替换所有的 为 \u00A0
|
||||||
|
content = content.replace(/ /g, '\u00A0');
|
||||||
|
|
||||||
|
// 替换 <img> 标签的宽度和高度样式
|
||||||
|
content = content.replace(/<img([^>]*)>/g, (match, group1) => {
|
||||||
|
// 查找并移除可能存在的尾部斜杠
|
||||||
|
let cleanedGroup = group1.replace(/\s*\/$/, '');
|
||||||
|
return `<img style="width: 85vw ; height: auto;" ${cleanedGroup} />`;
|
||||||
|
});
|
||||||
|
|
||||||
|
return content;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
page {
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.page {
|
||||||
|
width: 750rpx;
|
||||||
|
padding-bottom: 100rpx;
|
||||||
|
.cont {
|
||||||
|
|
||||||
|
margin-top: 34rpx;
|
||||||
|
margin: 0 auto;
|
||||||
|
width: 634rpx;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -4477,13 +4477,14 @@
|
||||||
this.showdevice = true;
|
this.showdevice = true;
|
||||||
this.type = 0;
|
this.type = 0;
|
||||||
} else {
|
} else {
|
||||||
if (this.deviceInfos.onlineStatus == 0) {
|
// if (this.deviceInfos.onlineStatus == 0) {
|
||||||
wx.showToast({
|
// wx.showToast({
|
||||||
title: '车辆离线中,请使用其他车辆',
|
// title: '车辆离线中,请使用其他车辆',
|
||||||
icon: 'none',
|
// icon: 'none',
|
||||||
duration: 4000
|
// duration: 4000
|
||||||
});
|
// });
|
||||||
} else if (this.deviceInfos.status == 0) {
|
// } else
|
||||||
|
if (this.deviceInfos.status == 0) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: '车辆未上架,请使用其他车辆',
|
title: '车辆未上架,请使用其他车辆',
|
||||||
icon: 'none',
|
icon: 'none',
|
||||||
|
@ -4571,15 +4572,16 @@
|
||||||
this.showdevice = true;
|
this.showdevice = true;
|
||||||
this.type = 0;
|
this.type = 0;
|
||||||
} else {
|
} else {
|
||||||
if (this.deviceInfos
|
// if (this.deviceInfos
|
||||||
.onlineStatus ==
|
// .onlineStatus ==
|
||||||
0) {
|
// 0) {
|
||||||
uni.showToast({
|
// uni.showToast({
|
||||||
title: '车辆离线中,请使用其他车辆',
|
// title: '车辆离线中,请使用其他车辆',
|
||||||
icon: 'none',
|
// icon: 'none',
|
||||||
duration: 4000
|
// duration: 4000
|
||||||
});
|
// });
|
||||||
} else if (this.deviceInfos
|
// } else
|
||||||
|
if (this.deviceInfos
|
||||||
.status ==
|
.status ==
|
||||||
0) {
|
0) {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
|
|
Loading…
Reference in New Issue
Block a user