refactor:项目升级Vue3+uView Plus

- 改造入口文件、全量替换组件引入
- 过滤器迁移混入,更新忽略配置,新增迁移文档
This commit is contained in:
lifenlong
2026-06-06 22:51:10 +08:00
parent d5663cfb4d
commit f4337fd030
269 changed files with 1956 additions and 42350 deletions

View File

@@ -1,7 +1,7 @@
<template>
<view class="content">
<u-navbar>
<u-tabs :active-color="lightColor" class="slot-wrap" :list="navList" count="count" :is-scroll="true" :current="tabCurrentIndex" @change="tabClick"></u-tabs>
<u-tabs :active-color="lightColor" class="slot-wrap" :list="navList" :is-scroll="true" :current="tabCurrentIndex" @change="tabClick"></u-tabs>
</u-navbar>
<view class="swiper-box">
<!-- 显示商品栏 -->
@@ -10,19 +10,21 @@
<!-- 空白页 -->
<u-empty style="margin-top: 40rpx" text="暂无收藏商品数据" mode="favor" v-if="goodsEmpty"></u-empty>
<!-- 商品展示数据 -->
<u-swipe-action @open="openLeftChange(item, index, 'goods')" :show="item.selected" btn-width="180"
:options="LeftOptions" v-else v-for="(item, index) in goodList"
@click="clickGoodsSwiperAction(item, index)" :index="index" :key="index">
<u-swipe-action v-else v-for="(item, index) in goodList" :key="index">
<u-swipe-action-item @open="openLeftChange(item, index, 'goods')" :show="item.selected"
:options="LeftOptions"
@click="clickGoodsSwiperAction(item, index)" :name="index">
<view class="goods" @click="goGoodsDetail(item)">
<u-image width="131rpx" height="131rpx" :src="item.image" mode="aspectFit">
<u-loading slot="loading"></u-loading>
<template #loading><u-loading></u-loading></template>
</u-image>
<view class="goods-intro">
<view>{{ item.goodsName }}</view>
<view class="goods-sn">{{ item.goods_sn }}</view>
<view>{{ item.price | unitPrice }}</view>
<view>{{unitPrice(item.price) }}</view>
</view>
</view>
</u-swipe-action-item>
</u-swipe-action>
</scroll-view>
@@ -33,15 +35,16 @@
<!-- 空白页 -->
<u-empty style="margin-top: 40rpx" text="暂无收藏店铺数据" mode="favor" v-if="storeEmpty"></u-empty>
<!-- 店铺展示数据 -->
<u-swipe-action @open="openLeftChange(item, 'store')" :show="item.selected" btn-width="180"
:options="LeftOptions" v-else v-for="(item, index) in storeList" :key="index"
<u-swipe-action v-else v-for="(item, index) in storeList" :key="index">
<u-swipe-action-item @open="openLeftChange(item, 'store')" :show="item.selected"
:options="LeftOptions"
@click="clickStoreSwiperAction(item)">
<view class="store" @click="goStoreMainPage(item.id)">
<view class="intro">
<view class="store-logo">
<u-image width="102rpx" height="102rpx" :src="item.storeLogo" :alt="item.storeName"
mode="aspectFit">
<u-loading slot="loading"></u-loading>
<template #loading><u-loading></u-loading></template>
</u-image>
</view>
<view class="store-name">
@@ -54,6 +57,7 @@
</view>
</view>
</view>
</u-swipe-action-item>
</u-swipe-action>
</scroll-view>
</view>
@@ -145,9 +149,9 @@
let way;
type == "goods" ? (way = goodList) : (way = storeList);
way.forEach((item) => {
this.$set(item, "selected", false);
item["selected"] = false;
});
this.$set(val, "selected", false);
val["selected"] = false;
val.selected = true;
},