微信 appid 抽到 .env、合并 env 配置、My 页底部备案信息、订单状态图改名

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
chenhao 2026-06-30 16:41:00 +08:00
parent 184d17fdea
commit 168d049b04
18 changed files with 43 additions and 31 deletions

3
.env Normal file
View File

@ -0,0 +1,3 @@
VITE_API_URL = "https://shop.jhxinyu.com"
VITE_OSS_URL = "https://shop.jhxinyu.com/uploads"
VITE_WX_APPID = "wx7f6c37c381b4f273"

View File

@ -1,2 +0,0 @@
VITE_API_URL = "https://shop.jhxinyu.com"
VITE_OSS_URL = "https://shop.jhxinyu.com/uploads"

View File

@ -1,2 +0,0 @@
VITE_API_URL = "https://shop.jhxinyu.com"
VITE_OSS_URL = "https://shop.jhxinyu.com/uploads"

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

@ -111,13 +111,13 @@ export default {
wx.ready(() => {
wx.updateAppMessageShareData(shareinfo);
wx.updateTimelineShareData(shareinfo);
wx.getLocation({
type: 'gcj02',
success: (e) => {
localStorage.setItem('user_latitude', e.latitude)
localStorage.setItem('user_longitude', e.longitude)
}
});
// wx.getLocation({
// type: 'gcj02',
// success: (e) => {
// localStorage.setItem('user_latitude', e.latitude)
// localStorage.setItem('user_longitude', e.longitude)
// }
// });
});
wx.error((e) => {
});

View File

@ -1,8 +1,6 @@
@import 'public.less';
@import 'tailwind.less';
@proColor: #841e36;
:root:root {
--main-color: #2e5d31;
}
@ -1062,7 +1060,7 @@
.box;
.box-center-center;
padding: 0 2.4vw;
background: @proColor;
background: var(--main-color);
width: 13.33vw;
height: 6vw;
border-radius: 3vw;

View File

@ -667,6 +667,7 @@ img {
.trade_confirm__deduction {
.trade_confirm__deduction_top {
.box;
padding-bottom: 3.33vw;
span {
font-weight: bold;

View File

@ -176,7 +176,7 @@ export default {
checkWxLogin() {
if (!this.$isWechat()) return
const REDIRECT_URI = encodeURIComponent('https://shop.jhxinyu.com/#/WxCallback')
window.location.href = `https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxdff8dd2032f1e054&redirect_uri=${REDIRECT_URI}&response_type=code&scope=snsapi_userinfo&state=STATE#wechat_redirect`
window.location.href = `https://open.weixin.qq.com/connect/oauth2/authorize?appid=${import.meta.env.VITE_WX_APPID}&redirect_uri=${REDIRECT_URI}&response_type=code&scope=snsapi_userinfo&state=STATE#wechat_redirect`
},
validatePhone(phone) {
if (!phone) {

View File

@ -31,7 +31,7 @@
</div>
</div>
<div class="goods_detail__deduct">
<!-- <div class="goods_detail__deduct">
<div class="goods_detail__deduct_item goods_detail__deduct_item--point" v-if="data.deductjifen > 0">
<img src="/img/icon-goods-detail-service-1.png" alt="">
积分抵{{ data.deductjifen?.toFixed(2) || '0.00' }}
@ -41,7 +41,7 @@
<img src="/img/icon-goods-detail-service-2.png" alt="">
会员卡额度抵{{ data.deducthuiyuanka?.toFixed(2) || '0.00' }}
</div>
</div>
</div> -->
<hr>
@ -153,7 +153,8 @@
<span>{{ data.saleprice?.toFixed(2) || '0.00' }}</span>积分
</div>
<div class="goods_detail__share_price" v-else>¥{{ data.saleprice?.toFixed(2) || '0.00' }}</div>
<div class="goods_detail__share_price--original" v-if="data.mallstate !== 5">¥{{ data.originalprice?.toFixed(2) || '0.00' }}</div>
<div class="goods_detail__share_price--original" v-if="data.mallstate !== 5">¥{{
data.originalprice?.toFixed(2) || '0.00' }}</div>
</div>
<div class="goods_detail__share_bottom">
@ -172,8 +173,8 @@
<van-popup v-model:show="showArea" safe-area-inset-bottom
style=" width: 86.67vw; background-color: #fff7f7; border-radius: 2.67vw;overflow: visible;" class="goods_detail__area_popup"
@click.self="showArea = false">
style=" width: 86.67vw; background-color: #fff7f7; border-radius: 2.67vw;overflow: visible;"
class="goods_detail__area_popup" @click.self="showArea = false">
<div class="goods_detail__area_box" style="position: relative;height: 80vw;">
<img style="width:31.73vw;position: absolute;top: -16vw;z-index: 1;left: 50%;transform: translateX(-50%);"
src="/img/img-empty.png" alt="">

View File

@ -45,7 +45,7 @@
<span>商品金额</span>
<b class="r"><span></span>{{ totalPrice }}</b>
</div>
<div class="trade_confirm__radio_group">
<!-- <div class="trade_confirm__radio_group">
<div class="trade_confirm__radio_item" :class="{ 'trade_confirm__radio_item--active': checked === '1' }" @click="toggleRadio('1')">
<div class="trade_confirm__radio_content">
<div class="trade_confirm__radio_line">
@ -77,13 +77,13 @@
<van-icon v-if="checked === '2'" name="success" />
</div>
</div>
</div>
</div> -->
<div class="trade_confirm__count">
<div v-if="freight > 0">
<span>运费</span>
<span class="trade_confirm__count_price">{{ freight.toFixed(2) }}</span>
</div>
<div v-if="checked">
<!-- <div v-if="checked">
<span>抵扣金额</span>
<span class="trade_confirm__count_price">-{{ actualDeduct?.toFixed(2) || '0.00' }}</span>
</div>
@ -92,7 +92,7 @@
<span class="trade_confirm__count_price">
{{ actualPay?.toFixed(2) || '0.00' }}
</span>
</div>
</div> -->
</div>
</div>
</div>

View File

@ -2,13 +2,14 @@
<BasePage :back="back">
<div class="trade_list b_l_w">
<div class="trade_list__tabs">
<van-tabs class="trade_list__tabs_area" v-model:active="TradeArea" color="#f00" title-active-color="#222"
<!-- <van-tabs class="trade_list__tabs_area" v-model:active="TradeArea" color="#f00" title-active-color="#222"
title-inactive-color="#999" line-width="0" line-height=".667vw" @change="changeMall">
<van-tab v-for="i in mallList" :title="i.label" :name="i.value"></van-tab>
</van-tabs>
</van-tabs> -->
<van-tabs class="trade_list__tabs_states" v-model:active="activeTab" color="#ca2904" title-active-color="#ca2904"
title-inactive-color="#000" line-width="4vw" line-height=".667vw" @change="onTabChange">
<van-tabs class="trade_list__tabs_states" v-model:active="activeTab" color="#ca2904"
title-active-color="#ca2904" title-inactive-color="#000" line-width="4vw" line-height=".667vw"
@change="onTabChange">
<van-tab title="全部" name=""></van-tab>
<van-tab v-for="i in tradeStates" :title="i.label" :name="String(i.value)"></van-tab>
</van-tabs>
@ -25,7 +26,8 @@
<template #default="{ item }">
<div class="trade_list__item">
<div class="trade_list__order">
<span :class="'trade_list__state--mall' + item.mallstate" class="trade_list__state">{{ item.mallstatename.slice(0, 2) }}</span>
<span :class="'trade_list__state--mall' + item.mallstate" class="trade_list__state">{{
item.mallstatename.slice(0, 2) }}</span>
<span>订单编号:{{ item.ordernum }}</span>
<img src="/img/icon-copy-black.png" @click="$copyText(item.ordernum); $showSuccessToast('复制成功')" alt="">
</div>
@ -39,7 +41,7 @@
</div>
<div class="trade_list__concession" v-if="item.mallstate !== 4">
<span v-if="item.mallstate !== 5">¥{{ item.proskusaleprice?.toFixed(2)
}}</span>
}}</span>
<span v-else>{{ item.proskusaleprice?.toFixed(2) }}积分</span>
<p v-if="item.discountratio && item.mallstate !== 5">惠利{{ item.discountratio }}%</p>
</div>

View File

@ -3,7 +3,8 @@
<div class="invite_page__poster_source" style="font-family: 'PingFang SC'">
<div class="invite_page__poster_body">
<div class="w100">
<img id="invite_page__bg_img" src="/img/img-invite-bg.jpg" crossorigin="anonymous">
<!-- <img id="invite_page__bg_img" src="/img/img-invite-bg.jpg" crossorigin="anonymous"> -->
<img id="invite_page__bg_img" :src="$file(inviteImg)" crossorigin="anonymous">
</div>
<img class="invite_page__avatar" :src="$file(data.Avatar)" crossorigin="anonymous">
<div class="invite_page__nickname">
@ -33,6 +34,7 @@ export default {
NickName: '',
},
link: '',
inviteImg: ''
}
},
mounted() {
@ -42,6 +44,8 @@ export default {
async init() {
try {
const userInfo = await this.$get('/v1/client/DUsersClient')
const inviData = await this.$get('/v1/client/CDatadicsClient/code_yqmbj');
this.inviteImg = inviData.data.contents;
if (userInfo?.data) {
this.data.Avatar = userInfo.data.userimg || ''
this.data.NickName = userInfo.data.nickname || ''

View File

@ -172,6 +172,13 @@
<van-button style="background: #fff; width: 60vw" @click="showFollow = false">关闭</van-button>
</van-dialog>
<div class="my_page__footer"
style="text-align: center; color: #999; font-size: 3.2vw; line-height: 1.8; padding: 6vw 0 0;">
<p>客服电话13018860070</p>
<p>金华市弛欲贸易有限公司</p>
<a href="https://beian.miit.gov.cn" target="_blank" style="color: #999;">浙ICP备2026005590号-1</a>
</div>
</div>
</template>