9***@qq.com
9***@qq.com
  • 发布:2022-10-31 09:19
  • 更新:2022-10-31 09:19
  • 阅读:163

项目里面用了<scroll-view>组件运行为H5时出现vue警告

分类:uni-app

当项目运行为H5时出现警告,<scroll-view>组件也不能使用

请问如何解决
代码如下

<template>  
    <view class="body">  
        <view class="shousuoqu">  
            <view class="leftinout">  
                <input type="text" placeholder="地址/客户名称/手机/项目编号"  
                    placeholder-style="font-size: 26rpx;font-family: PingFang SC-Regular, PingFang SC;font-weight: 400;color: #999999;">  
                <image src="" mode=""></image>  
            </view>  
            <view class="xinjian" @click="xaiyiye('/pages/xinjianxiangmu/xinjianxiangmu')">+ 新建项目</view>  
        </view>  
        <!--  -->  
        <view class="tabka">  
            <view :class="[ lkjhg==0?'duanxian ' :'sixiang' ]" @click="Tabbka(0)">立项中</view>  
            <view :class="[lkjhg==1?'duanxian ' :'sixiang' ]" @click="Tabbka(1)">设计中</view>  
            <view :class="[ lkjhg==2?'duanxian ' :'sixiang']" @click="Tabbka(2)">施工中</view>  
            <view :class="[ lkjhg==3?'duanxian ' :'sixiang' ]" @click="Tabbka(3)">已完工</view>  
        </view>  
        <!--  -->  
        <view class="liebiaoqu">  
            <scroll-view scroll-y="true" style="width: 100%;height: 100%;">  
                <block v-if="lkjhg==2">  
                    <view class="shuoming">进度节点标识说明 </view>  
                    <view class="paidui" style="margin: 16rpx 0;">  
                        <view class="paidui">  
                            <view class="huidian"></view>  
                            <view class="xiaoziti">节点未开工</view>  
                        </view>  
                        <view class="paidui">  
                            <view class="lvdian"></view>  
                            <view class="xiaoziti">节点正常</view>  
                        </view>  
                        <view class="paidui">  
                            <view class="hongdian"></view>  
                            <view class="xiaoziti">节点超时,数字为超时天数</view>  
                        </view>  
                    </view>  
                </block>  
                <view class="mianban" v-for="(item,index) in 5" :key="index" @click="xaiyiye('/pages/examination/details')">  
                    <view class="liangbain dixian">  
                        <view class="bianhao">项目编号:NO.202206251235</view>  
                        <view class="zhuantai">  
                            <text v-if="true">待审批</text>  
                            <text v-if="false">审批失败</text>  
                        </view>  
                    </view>  
                    <view class="xiangxidizhi">高新二路光谷大道中冶创业苑B5栋124</view>  
                    <view class="suozaidi">湖北省武汉市洪山区</view>  
                    <view class="liangbain" style="margin-top: 24rpx;">  
                        <view class="yonghu">  
                            <image src="../../static/logo.png" mode=""></image>  
                            <text class="xinming">高桂英</text>  
                            <text class="dianhua">16579854678</text>  
                        </view>  
                        <view class="bodadianhau" v-if="true">  
                            <image src="../../static/logo.png" mode=""></image>  
                            <text style="margin: 0 10rpx;">联系客户</text>  
                        </view>  
                        <view class="" v-else>  
                            删除项目  
                        </view>  
                    </view>  
                    <block v-if="lkjhg==2">  
                    <view class="duoyanse">  
                        <view class="zuoyou">  
                            <view class="jindudian">施工进度</view>  
                            <view class="gongyoudian">共5个节点</view>  
                        </view>  
                        <view class="paipaipai">  
                            <view class="weikaigoing">5</view>  
                            <view class="zhengdian">5</view>  
                            <view class="chaoshi">5</view>  
                        </view>  
                    </view>  
                    </block>  
                </view>  

                <view class="daodiliao" v-if="isLoadMore">已经到底了~</view>  
                <view class="kongbaiye" v-if="xiangmulist.length<=0">  
                    <view class="kongtu">  
                        <image src="../../static/logo.png" mode=""></image>  
                    </view>  
                    <view class="daodiliao" style="margin-top: 32rpx;">暂无立项项目</view>  
                </view>  
            </scroll-view>  
        </view>  
        <!--  -->  
        <!-- <tabbar index="0"></tabbar> -->  
    </view>  
</template>  

<script>  
    export default {  
        data() {  
            return {  
                xiangmulist: [1],  
                isLoadMore: false,  
                lkjhg: 0,  
            }  
        },  
        onLoad() {  

        },  

        onReachBottom: function() {  
            if (this.total <= this.teamList.length) {  
                this.isLoadMore = true  
                util.showErrorToast("没有更多了!")  
                return false;  
            }  
            // this.getDesignerList();  
        },  
        methods: {  
            Tabbka(index) {  
                this.lkjhg = index  
            },  
            xaiyiye(url){  
                uni.navigateTo({  
                    url:url  
                })  
            }  
        }  
    }  
</script>  

<style>  
    @import url("../../static/css/index.css");  
</style>  
2022-10-31 09:19 负责人:无 分享
已邀请:

该问题目前已经被锁定, 无法添加新回复