tangyi 2022-03-25 11:41:35 +08:00
commit c0a4e1efe7
2 changed files with 35 additions and 31 deletions

View File

@ -3,7 +3,9 @@
<status-nav :navBarTitle="title" returnColor="#c2c2c2"></status-nav>
<container-subgroup>
<view slot="content" style="margin: 0 -30rpx;" class="bacf">
<view class="pad30">
<rich-text :nodes="richText" class="fon24 line-h40 col6"></rich-text>
</view>
</view>
</container-subgroup>
</view>
@ -24,10 +26,10 @@
methods:{
checkAgreement(type){
console.log(type,26);
let url = type*1 ? '/universal/api.login/register_user_agreement' : '/universal/api.login/register_privacy_agreement';
let url = type*1 ? '/universal/api.login/register_privacy_agreement' : '/universal/api.login/register_user_agreement';
this.$requst.post(url).then(res=>{
if(res.code==1) {
// this.richText =
this.richText = this.$toolAll.tools.escape2Html(res.data.protocol);
} else this.$toolAll.tools.showToast(res.msg);
})
}

View File

@ -182,7 +182,7 @@
<view class="mar-s30">
<scroll-view scroll-x>
<view :class="solutionList.length == 4 ? 'disjbac' : 'disac'">
<view @tap="goDetail(0)" class="posir flexs" v-for="(item,index) in solutionList" :key="index" style="width: 23%;height: 214rpx;" :style="{marginRight: solutionList.length != 4 ? '20rpx' : ''}">
<view @tap="goDetail(0,item.id)" class="posir flexs" v-for="(item,index) in solutionList" :key="index" style="width: 23%;height: 214rpx;" :style="{marginRight: solutionList.length != 4 ? '20rpx' : ''}">
<image style="width: 100%;height: 214rpx;" class="radius10 " :src="item.imgsrc" mode="widthFix"></image>
<view class="posia solution-title clips1">{{item.title}}</view>
</view>
@ -193,13 +193,15 @@
<!-- 常见故障 -->
<view class="bacf mar-zy20 pad-sx30 pad-zy10 radius10">
<view class="fon34 bold col3" @tap="goPlant(1)"><text class="col9 mar-z10">Common faults</text></view>
<view @tap="goDetail(1)" class="pad-sx20 bbot disjb" v-for="(item,index) in faultsList" :key="index">
<view class="fon28 line-h38">
<view @tap="goDetail(1,item.id)" class="pad-sx20 bbot disjb" v-for="(item,index) in faultsList" :key="index">
<view class="fon28 line-h38 disjb fc" style="min-height: 160rpx;">
<view>
<view class="col3 clips1">{{item.title}}</view>
<view class="fon22 col6 clips3 mar-sx10">{{item.content}}</view>
</view>
<view class="col9">{{item.views}}人看过</view>
</view>
<image class="flexs mar-z20" :src="item.imgsrc" style="width: 280rpx;height: 112rpx;" mode="widthFix" lazy-load></image>
<image class="flexs mar-z20" :src="item.imgsrc" style="width: 280rpx;height: 160rpx;" mode="aspectFill" lazy-load></image>
</view>
</view>
@ -293,26 +295,7 @@
{imgsrc:'/static/public/icon-home-checkSparePart.png',title:'查备件',num:0},
],
//
faultsList:[
{
imgsrc:'/static/deleteImg/flying-img05.png',
title:'1.启动时提示“大屏幕系统没有找到”',
content:'故障原因串口线或者USB线与发送卡没连接;电脑 COM或者USB口坏;串口线或者USB线坏;发送卡坏;没 有安装USB驱动。',
views:4399
},
{
imgsrc:'/static/deleteImg/flying-img05.png',
title:'1.启动时提示“大屏幕系统没有找到”',
content:'故障原因串口线或者USB线与发送卡没连接;电脑 COM或者USB口坏;串口线或者USB线坏;发送卡坏;没 有安装USB驱动。',
views:4399
},
{
imgsrc:'/static/deleteImg/flying-img05.png',
title:'1.启动时提示“大屏幕系统没有找到”',
content:'故障原因串口线或者USB线与发送卡没连接;电脑 COM或者USB口坏;串口线或者USB线坏;发送卡坏;没 有安装USB驱动。',
views:4399
},
],
faultsList:[],
}
},
onLoad(options) {
@ -322,6 +305,8 @@
this.getPlanType();
//
// this.getIncrementServiceType();
//
this.getFaultsList();
},
methods: {
goNoticeDetail(e){
@ -377,6 +362,23 @@
this.$toolAll.tools.showToast('已催单成功')
}
},
//
getFaultsList(){
this.$requst.post('/universal/api.question/question').then(res=>{
if(res.code) {
res.data.forEach(item=>{
let obj = {
id:item.id,
title:item.title,
imgsrc: uni.getStorageSync('hostapi') + '/' + item.cover_img,
content:item.summary,
views:item.reading
}
this.faultsList.push(obj);
})
}
})
},
//
otherEv(index) {
let otherUrls = [
@ -395,9 +397,9 @@
})
},
//
goDetail(index) {
goDetail(index,id) {
uni.navigateTo({
url:`/pagesB/plan-fault-product-detail/detail?index=${index}`
url:`/pagesB/plan-fault-product-detail/detail?index=${index}&id=${id}`
})
},
//