chore(组件): 组件尽量使用异步导入模式

This commit is contained in:
2026-01-04 14:40:00 +08:00
parent 4da852944e
commit 9415f397d2
172 changed files with 11520 additions and 10979 deletions

View File

@@ -40,7 +40,8 @@
<!-- 商品信息 -->
<view class="goods-wrap">
<view class="goods-img" @click="refundDetail(detail)">
<image :src="$util.img(detail.sku_image, { size: 'mid' })" @error="imageError()" mode="aspectFill" :lazy-load="true"></image>
<image :src="$util.img(detail.sku_image, { size: 'mid' })" @error="imageError()"
mode="aspectFill" :lazy-load="true"></image>
</view>
<view class="goods-info">
<view class="goods-name" @click="refundDetail(detail)">{{ detail.sku_name }}</view>
@@ -49,21 +50,26 @@
<!-- 退款信息 -->
<view class="info">
<view class="cell">退款方式{{ detail.refund_type == 1 ? '仅退款' : '退款退货' }}</view>
<view class="cell" v-if="detail.refund_status == 3">退款途径{{ detail.refund_money_type == 1 ? '原路退款' : detail.refund_money_type == 2 ? '线下退款' : '退款到余额' }}</view>
<view class="cell" v-if="detail.refund_status == 3">退款途径{{ detail.refund_money_type == 1 ?
'原路退款' : detail.refund_money_type == 2 ? '线下退款' : '退款到余额' }}</view>
<view class="cell">退款原因{{ detail.refund_reason }}</view>
<view class="cell" v-if="detail.refund_status == 3 && detail.refund_real_money>0">退款金额{{ $lang('common.currencySymbol') }}{{ detail.refund_real_money }}</view>
<view class="cell" v-else-if="detail.refund_apply_money>0">退款金额{{ $lang('common.currencySymbol') }}{{ detail.refund_apply_money }}</view>
<view class="cell" v-if="detail.refund_status == 3 && detail.refund_real_money > 0">退款金额{{
$lang('common.currencySymbol') }}{{ detail.refund_real_money }}</view>
<view class="cell" v-else-if="detail.refund_apply_money > 0">退款金额{{
$lang('common.currencySymbol') }}{{ detail.refund_apply_money }}</view>
<view class="cell">退款编号{{ detail.refund_no }}</view>
<view class="cell">申请时间{{ $util.timeStampTurnTime(detail.refund_action_time) }}</view>
<view class="cell" v-if="detail.refund_time">退款时间{{ $util.timeStampTurnTime(detail.refund_time) }}</view>
<view class="cell" v-if="detail.refund_time">退款时间{{
$util.timeStampTurnTime(detail.refund_time) }}</view>
<view class="cell" v-if="detail.refund_remark != ''">退款说明{{ detail.refund_remark }}</view>
<view class="cell" v-if="detail.use_point>0">退款积分{{ detail.use_point }}</view>
<view class="cell" v-if="detail.use_point > 0">退款积分{{ detail.use_point }}</view>
</view>
</view>
</view>
<view class="action" :class="{ 'bottom-safe-area': isIphoneX }" v-if="detail.refund_action.length">
<view class="order-box-btn" v-for="(actionItem, actionIndex) in detail.refund_action" :key="actionIndex" @click="refundAction(actionItem.event)">
<view class="order-box-btn" v-for="(actionItem, actionIndex) in detail.refund_action"
:key="actionIndex" @click="refundAction(actionItem.event)">
{{ actionItem.title }}
</view>
</view>
@@ -75,37 +81,24 @@
<view class="item">
<view class="label">物流公司</view>
<view class="cont">
<input
type="text"
placeholder="请输入物流公司"
class="input"
<input type="text" placeholder="请输入物流公司" class="input"
placeholder-class="input-placeholder color-tip"
v-model="formData.refund_delivery_name"
/>
v-model="formData.refund_delivery_name" />
</view>
</view>
<view class="item">
<view class="label">物流单号</view>
<view class="cont">
<input
type="text"
placeholder="请输入物流单号"
class="input"
<input type="text" placeholder="请输入物流单号" class="input"
placeholder-class="input-placeholder color-tip"
v-model="formData.refund_delivery_no"
/>
v-model="formData.refund_delivery_no" />
</view>
</view>
<view class="item">
<view class="label">物流说明</view>
<view class="cont">
<textarea
placeholder-class="color-tip font-size-tag"
:auto-height="true"
class="textarea"
placeholder="选填"
v-model="formData.refund_delivery_remark"
/>
<textarea placeholder-class="color-tip font-size-tag" :auto-height="true"
class="textarea" placeholder="选填" v-model="formData.refund_delivery_remark" />
</view>
</view>
</view>
@@ -115,7 +108,8 @@
<view v-show="action == 'consultrecord'">
<view class="record-wrap">
<view class="record-item" :class="logItem.action_way == 1 ? 'buyer' : ''" v-for="(logItem, logIndex) in detail.refund_log_list" :key="logIndex">
<view class="record-item" :class="logItem.action_way == 1 ? 'buyer' : ''"
v-for="(logItem, logIndex) in detail.refund_log_list" :key="logIndex">
<view class="cont">
<view class="head">
<text>{{ logItem.action_way == 1 ? '买家' : '卖家' }}</text>
@@ -130,7 +124,7 @@
<view class="empty-box"></view>
</view>
<view class="history-bottom" :class="{ 'bottom-safe-area': isIphoneX }">
<!-- <ns-contact :niushop="{order_id: detail.order_id}">
<!-- <ns-contact :niushop="{order_id: detail.order_id}">
<view>
<text class="iconfont icon-ziyuan"></text>
<text>联系客服</text>
@@ -141,15 +135,19 @@
</view>
</scroll-view>
<loading-cover ref="loadingCover"></loading-cover>
</view>
</template>
<script>
import refundMethod from './public/js/refundMethod.js';
import validate from 'common/js/validate.js';
import nsContact from '@/components/ns-contact/ns-contact.vue';
export default {
components: {
nsContact: () => import('@/components/ns-contact/ns-contact.vue'),
loadingCover: () => import('@/components/loading-cover/loading-cover.vue'),
},
data() {
return {
order_goods_id: '',
@@ -166,9 +164,6 @@ export default {
isSub: false
};
},
components: {
nsContact
},
mixins: [refundMethod],
onLoad(option) {
if (option.order_goods_id) this.order_goods_id = option.order_goods_id;