更改图片

This commit is contained in:
tangxinyue 2026-06-30 16:17:01 +08:00
parent 7bfa56cf5b
commit f842ab9d6a
9 changed files with 81 additions and 45 deletions

View File

@ -20,7 +20,7 @@
</view> </view>
</view> </view>
</view> </view>
<image ref="bgImage" class="bg-image" src="@/static/image/alipay-bill/main-bg.png" mode="widthFix"></image> <image ref="bgImage" class="bg-image" :src="billBgImage" mode="widthFix"></image>
<image class="eye-image" src="@/static/image/alipay-bill/hide.png" mode="widthFix"></image> <image class="eye-image" src="@/static/image/alipay-bill/hide.png" mode="widthFix"></image>
<image class="find-more" src="@/static/image/alipay-bill/find-more.png" mode=""></image> <image class="find-more" src="@/static/image/alipay-bill/find-more.png" mode=""></image>
@ -32,18 +32,18 @@
<view class="frist-money money-type-item"> <view class="frist-money money-type-item">
<view class="type-input-box"> <view class="type-input-box">
<!-- <{{ moneyFrist.type }}>支出最多 --> <!-- <{{ moneyFrist.type }}>支出最多 -->
<<view class="percentage-input-box"> &lt;<view class="percentage-input-box">
<text class="ghost-text">{{ moneyFrist.type }}</text> <text class="ghost-text">{{ moneyFrist.type }}</text>
<input class="percentage-input" type="text" v-model="moneyFrist.type" <input class="percentage-input" type="text" v-model="moneyFrist.type"
@input="inputPercentage($event, 'moneyFrist')" maxlength="4"></input> @input="inputPercentage($event, 'moneyFrist')" maxlength="4" />
</view>>支出最多 </view>&gt;支出最多
</view> </view>
<view class="money"> <view class="money">
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneyFrist.percentage }}</text> <text class="ghost-text">{{ moneyFrist.percentage }}</text>
<input class="percentage-input" type="digit" v-model="moneyFrist.percentage" <input class="percentage-input" type="digit" v-model="moneyFrist.percentage"
@input="inputPercentage($event, 'moneyFrist')"></input> @input="inputPercentage($event, 'moneyFrist')" />
</view> </view>
<view>%</view> <view>%</view>
</view> </view>
@ -54,7 +54,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneySecond.type }}</text> <text class="ghost-text">{{ moneySecond.type }}</text>
<input class="percentage-input" type="text" v-model="moneySecond.type" <input class="percentage-input" type="text" v-model="moneySecond.type"
@input="inputPercentage($event, 'moneySecond')"></input> @input="inputPercentage($event, 'moneySecond')" />
</view> </view>
</view> </view>
<view class="money"> <view class="money">
@ -62,7 +62,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneySecond.percentage }}</text> <text class="ghost-text">{{ moneySecond.percentage }}</text>
<input class="percentage-input" type="digit" v-model="moneySecond.percentage" <input class="percentage-input" type="digit" v-model="moneySecond.percentage"
@input="inputPercentage($event, 'moneySecond')"></input> @input="inputPercentage($event, 'moneySecond')" />
</view> </view>
<view>%</view> <view>%</view>
</view> </view>
@ -73,7 +73,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneyThird.type }}</text> <text class="ghost-text">{{ moneyThird.type }}</text>
<input class="percentage-input" type="text" v-model="moneyThird.type" <input class="percentage-input" type="text" v-model="moneyThird.type"
@input="inputPercentage($event, 'moneyThird')"></input> @input="inputPercentage($event, 'moneyThird')" />
</view> </view>
</view> </view>
<view class="money"> <view class="money">
@ -81,7 +81,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneyThird.percentage }}</text> <text class="ghost-text">{{ moneyThird.percentage }}</text>
<input class="percentage-input" type="digit" v-model="moneyThird.percentage" <input class="percentage-input" type="digit" v-model="moneyThird.percentage"
@input="inputPercentage($event, 'moneyThird')"></input> @input="inputPercentage($event, 'moneyThird')" />
</view> </view>
<view>%</view> <view>%</view>
</view> </view>
@ -92,7 +92,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneyFourth.type }}</text> <text class="ghost-text">{{ moneyFourth.type }}</text>
<input class="percentage-input" type="text" v-model="moneyFourth.type" <input class="percentage-input" type="text" v-model="moneyFourth.type"
@input="inputPercentage($event, 'moneyFourth')"></input> @input="inputPercentage($event, 'moneyFourth')" />
</view> </view>
</view> </view>
<view class="money"> <view class="money">
@ -100,7 +100,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneyFourth.percentage }}</text> <text class="ghost-text">{{ moneyFourth.percentage }}</text>
<input class="percentage-input" type="digit" v-model="moneyFourth.percentage" <input class="percentage-input" type="digit" v-model="moneyFourth.percentage"
@input="inputPercentage($event, 'moneyFourth')"></input> @input="inputPercentage($event, 'moneyFourth')" />
</view> </view>
<view>%</view> <view>%</view>
</view> </view>
@ -111,7 +111,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneyFifth.type }}</text> <text class="ghost-text">{{ moneyFifth.type }}</text>
<input class="percentage-input" type="text" v-model="moneyFifth.type" <input class="percentage-input" type="text" v-model="moneyFifth.type"
@input="inputPercentage($event, 'moneyFifth')"></input> @input="inputPercentage($event, 'moneyFifth')" />
</view> </view>
</view> </view>
<view class="money"> <view class="money">
@ -119,7 +119,7 @@
<view class="percentage-input-box"> <view class="percentage-input-box">
<text class="ghost-text">{{ moneyFifth.percentage }}</text> <text class="ghost-text">{{ moneyFifth.percentage }}</text>
<input class="percentage-input" type="digit" v-model="moneyFifth.percentage" <input class="percentage-input" type="digit" v-model="moneyFifth.percentage"
@input="inputPercentage($event, 'moneyFifth')"></input> @input="inputPercentage($event, 'moneyFifth')" />
</view> </view>
<view>%</view> <view>%</view>
</view> </view>
@ -169,10 +169,9 @@ import {
getCurrentInstance getCurrentInstance
} from 'vue'; } from 'vue';
import { import {
onLoad, onLoad
onShow,
onUnload
} from '@dcloudio/uni-app'; } from '@dcloudio/uni-app';
import { imgLocal } from '@/utils/common.js';
const statusBarHeight = ref(0); const statusBarHeight = ref(0);
const dialogPopup = ref(null); const dialogPopup = ref(null);
const timeDialogPopup = ref(null); const timeDialogPopup = ref(null);
@ -203,7 +202,7 @@ const data = reactive({
type: '服饰装扮', type: '服饰装扮',
percentage: "83" percentage: "83"
}, },
navBarHeight: 0 billBgImage: ''
}) })
let { let {
@ -214,11 +213,11 @@ let {
moneyFourth, moneyFourth,
moneyFifth, moneyFifth,
time, time,
navBarHeight billBgImage
} = toRefs(data) } = toRefs(data)
onLoad(() => { onLoad(async () => {
// //
proxy.$apiUserEvent('all', { proxy.$apiUserEvent('all', {
type: 'click', type: 'click',
@ -228,6 +227,9 @@ onLoad(() => {
time.value = getYesterday(); time.value = getYesterday();
statusBarHeight.value = uni.getSystemInfoSync().statusBarHeight; statusBarHeight.value = uni.getSystemInfoSync().statusBarHeight;
data.billBgImage = await imgLocal.getLocalImage('alipay-bill/main-bg.png');
console.log("data.billBgImage", data.billBgImage)
const config = uni.getStorageSync('config') const config = uni.getStorageSync('config')
console.log("---config---", config); console.log("---config---", config);
const font = config.config['client.uniapp.font'] const font = config.config['client.uniapp.font']

View File

@ -244,6 +244,7 @@
<script setup> <script setup>
import NavBar from '@/components/nav-bar/nav-bar.vue' import NavBar from '@/components/nav-bar/nav-bar.vue'
import { imgLocal } from '@/utils/common.js';
import { import {
ref, ref,
toRefs, toRefs,
@ -298,7 +299,7 @@ const buttonGroup = [{
} }
}] }]
const defualtData = { let defualtData = {
benefitsText: '尊享礼遇18000元/年', benefitsText: '尊享礼遇18000元/年',
cardHolderName: 'XiaoMing', cardHolderName: 'XiaoMing',
vipLevel: "v3", vipLevel: "v3",
@ -355,7 +356,10 @@ onReady(() => {
}).exec() }).exec()
}) })
onShow(() => { onShow(async () => {
defualtData.bgImage = await imgLocal.getLocalImage('finance-management/bg-style/style-1.png');
console.log(defualtData.bgImage)
financeInfo.value = { financeInfo.value = {
...defualtData, ...defualtData,
...uni.getStorageSync('financeInfo') ...uni.getStorageSync('financeInfo')

View File

@ -2,13 +2,12 @@
<view> <view>
<NavBar title="选择理财图片样式" bgColor="#F5F5F5" isRightButton @right-click="handleRightButtonClick"></NavBar> <NavBar title="选择理财图片样式" bgColor="#F5F5F5" isRightButton @right-click="handleRightButtonClick"></NavBar>
<view class="conatiner flex flex-justify-between"> <view class="conatiner flex flex-justify-between">
<view v-for="index in 6" :key="index" class="cover-item flex flex-column flex-align-center" <view v-for="(item, index) in bgList" :key="index" class="cover-item flex flex-column flex-align-center"
@click="data.selectedImage = index"> @click="data.selectedImage = index">
<view class="image-box" :class="{ 'active': index == data.selectedImage }"> <view class="image-box" :class="{ 'active': index == data.selectedImage }">
<image class="w100 h100" :src="`/static/image/finance-management/covers/cover-${index}.png`" <image class="w100 h100" :src="item" mode="widthFix"></image>
mode="widthFix"></image>
</view> </view>
<view class="text">样式{{ index }}</view> <view class="text">样式{{ index + 1 }}</view>
</view> </view>
</view> </view>
</view> </view>
@ -17,6 +16,8 @@
<script setup> <script setup>
import NavBar from '@/components/nav-bar/nav-bar.vue' import NavBar from '@/components/nav-bar/nav-bar.vue'
import { ref, reactive, toRefs, onMounted } from 'vue'; import { ref, reactive, toRefs, onMounted } from 'vue';
import { onLoad } from '@dcloudio/uni-app';
import { imgLocal } from '@/utils/common.js';
const defualtData = { const defualtData = {
benefitsText: '尊享礼遇18000元/年', benefitsText: '尊享礼遇18000元/年',
@ -82,6 +83,14 @@ const data = reactive({
}) })
const { bgImage, selectedImage, financeInfo } = toRefs(data) const { bgImage, selectedImage, financeInfo } = toRefs(data)
const bgList = ref([])
onLoad(async () => {
for (let i = 1; i <= 6; i++) {
const imgPath = await imgLocal.getLocalImage(`finance-management/covers/cover-${i}.png`)
bgList.value.push(imgPath)
}
})
onMounted(() => { onMounted(() => {
financeInfo.value = { financeInfo.value = {
@ -90,11 +99,12 @@ onMounted(() => {
} }
}) })
const handleRightButtonClick = () => { const handleRightButtonClick = async () => {
const financeInfoData = { const financeInfoData = {
...financeInfo.value ...financeInfo.value
} }
financeInfoData.bgImage = `/static/image/finance-management/bg-style/style-${data.selectedImage}.png` // financeInfoData.bgImage = `finance-management/bg-style/style-${data.selectedImage}.png`
financeInfoData.bgImage = await imgLocal.getLocalImage(`finance-management/bg-style/style-${data.selectedImage + 1}.png`)
uni.setStorageSync('financeInfo', financeInfoData) uni.setStorageSync('financeInfo', financeInfoData)
uni.navigateBack() uni.navigateBack()
} }

View File

@ -19,8 +19,7 @@
css="position: absolute; left: 117.0px; top: 76.8px; width: 66px; height: 66px; border-radius: 200px; object-fit: cover; display: block;"></l-painter-image> css="position: absolute; left: 117.0px; top: 76.8px; width: 66px; height: 66px; border-radius: 200px; object-fit: cover; display: block;"></l-painter-image>
<!-- 头像框 (压在头像上方) --> <!-- 头像框 (压在头像上方) -->
<l-painter-image <l-painter-image :src="headerImage"
:src="`/static/image/other/game/wangzhe/avatar-frame-${honorData.type}.png`"
css="position: absolute; left: 0; top: 0; width: 183px; height: 141px"></l-painter-image> css="position: absolute; left: 0; top: 0; width: 183px; height: 141px"></l-painter-image>
<!-- 性别图标 --> <!-- 性别图标 -->
@ -227,6 +226,7 @@
<script setup> <script setup>
import { ref, reactive, onMounted, getCurrentInstance } from 'vue' import { ref, reactive, onMounted, getCurrentInstance } from 'vue'
import { onLoad, onReady, onUnload } from '@dcloudio/uni-app' import { onLoad, onReady, onUnload } from '@dcloudio/uni-app'
import { imgLocal } from '@/utils/common.js';
const rightButtonText = ref("编辑"); const rightButtonText = ref("编辑");
const instance = getCurrentInstance(); const instance = getCurrentInstance();
const { proxy } = getCurrentInstance(); const { proxy } = getCurrentInstance();
@ -234,6 +234,7 @@ const nicknameImage = ref('');
const showPreview = ref(false); // const showPreview = ref(false); //
const isMountedReady = ref(false); const isMountedReady = ref(false);
const isFontLoaded = ref(false); const isFontLoaded = ref(false);
const headerImage = ref('')
// css calc() // css calc()
const sysInfo = uni.getSystemInfoSync(); const sysInfo = uni.getSystemInfoSync();
@ -264,11 +265,12 @@ const honorData = reactive({
peakStrong: '5632' peakStrong: '5632'
}) })
onLoad(() => { onLoad(async () => {
const cachedData = uni.getStorageSync('wangzheHonorData'); const cachedData = uni.getStorageSync('wangzheHonorData');
if (cachedData) { if (cachedData) {
Object.assign(honorData, cachedData); Object.assign(honorData, cachedData);
} }
headerImage.value = await imgLocal.getLocalImage(`other/game/wangzhe/avatar-frame-${honorData.type}.png`)
uni.$on('editFormPhoto', (info) => { uni.$on('editFormPhoto', (info) => {
tempData.avatar = info; tempData.avatar = info;
@ -390,11 +392,12 @@ const editPopup = ref(null);
const tempData = reactive({}); const tempData = reactive({});
const newAvatars = ref([]); const newAvatars = ref([]);
function handleChangeTheme(typeIndex) { async function handleChangeTheme(typeIndex) {
// //
finalPosterPath.value = ''; finalPosterPath.value = '';
honorData.type = typeIndex; honorData.type = typeIndex;
uni.setStorageSync('wangzheHonorData', honorData); uni.setStorageSync('wangzheHonorData', honorData);
headerImage.value = await imgLocal.getLocalImage(`other/game/wangzhe/avatar-frame-${typeIndex}.png`)
} }
function onRightClick() { function onRightClick() {

View File

@ -177,6 +177,7 @@ import { onShow, onLoad } from '@dcloudio/uni-app';
import ListCard from './components/list-card/list-card.vue'; import ListCard from './components/list-card/list-card.vue';
import { defaultDataList } from '@/pages/shopping/pdd/json/order.json'; import { defaultDataList } from '@/pages/shopping/pdd/json/order.json';
import { util } from '@/utils/common.js'; import { util } from '@/utils/common.js';
import { imgLocal } from '@/utils/common.js';
const { proxy } = getCurrentInstance(); const { proxy } = getCurrentInstance();
const activeTab = ref(0); const activeTab = ref(0);
@ -430,7 +431,7 @@ const filteredOrderList = computed(() => {
return list.slice().sort((a, b) => getOrderTime(b) - getOrderTime(a)); return list.slice().sort((a, b) => getOrderTime(b) - getOrderTime(a));
}); });
onShow(() => { onShow(async () => {
const pddCouponInfo = uni.getStorageSync('pddCouponInfo'); const pddCouponInfo = uni.getStorageSync('pddCouponInfo');
if (pddCouponInfo) { if (pddCouponInfo) {
couponInfo.value = pddCouponInfo; couponInfo.value = pddCouponInfo;
@ -449,7 +450,7 @@ onShow(() => {
// () // ()
let savedScreenshot = uni.getStorageSync('pdd_screenshot'); let savedScreenshot = uni.getStorageSync('pdd_screenshot');
if (!savedScreenshot) { if (!savedScreenshot) {
savedScreenshot = '/static/image/shopping/pdd/pdd-bottom-product.png'; savedScreenshot = await imgLocal.getLocalImage(`shopping/pdd/pdd-bottom-product.png`)
uni.setStorageSync('pdd_screenshot', savedScreenshot); uni.setStorageSync('pdd_screenshot', savedScreenshot);
} }
screenshotImage.value = savedScreenshot; screenshotImage.value = savedScreenshot;

View File

@ -202,8 +202,7 @@
<view v-if="order.orderType != 'wait_pay'"> <view v-if="order.orderType != 'wait_pay'">
<image style="width: 100%;" :src="screenshotImage || '/static/image/shopping/pdd/pdd-bottom-product.png'" <image style="width: 100%;" :src="screenshotImage" mode="widthFix"></image>
mode="widthFix"></image>
</view> </view>
<!-- 底部固定支付栏 --> <!-- 底部固定支付栏 -->
@ -235,6 +234,7 @@
<text>去支付</text> <text>去支付</text>
</view> </view>
</view> </view>
<!-- 底部固定支付栏 --> <!-- 底部固定支付栏 -->
<view v-else class="fixed-bottom-bar flex-justify-between"> <view v-else class="fixed-bottom-bar flex-justify-between">
<view class="flex-align-center buttons"> <view class="flex-align-center buttons">
@ -261,6 +261,7 @@ import { ref, computed, getCurrentInstance } from 'vue';
import { onLoad, onShow } from '@dcloudio/uni-app'; import { onLoad, onShow } from '@dcloudio/uni-app';
import { stringUtil } from '@/utils/common.js'; import { stringUtil } from '@/utils/common.js';
import { util } from '@/utils/common.js'; import { util } from '@/utils/common.js';
import { imgLocal } from '@/utils/common.js';
const { proxy } = getCurrentInstance(); const { proxy } = getCurrentInstance();
// //
@ -372,7 +373,8 @@ const couponInfo = ref({
couponPath: '/static/image/shopping/pdd/coupon1.png' couponPath: '/static/image/shopping/pdd/coupon1.png'
}); });
onShow(() => { const screenshotImage = ref('')
onShow(async () => {
const cacheList = uni.getStorageSync('pddOrderList'); const cacheList = uni.getStorageSync('pddOrderList');
order.value = cacheList.find(item => item.id == id.value); order.value = cacheList.find(item => item.id == id.value);
@ -380,6 +382,11 @@ onShow(() => {
if (pddCouponInfo) { if (pddCouponInfo) {
couponInfo.value = pddCouponInfo; couponInfo.value = pddCouponInfo;
} }
screenshotImage.value = uni.getStorageSync('pdd_screenshot');
if (!screenshotImage.value) {
screenshotImage.value = await imgLocal.getLocalImage(`shopping/pdd/pdd-bottom-product.png`)
}
}) })

View File

@ -328,6 +328,7 @@ import { util } from '@/utils/common.js';
import { defualtData, waimaiType, waimaiClassfiy, waimaiProductList } from '../json/order.json'; import { defualtData, waimaiType, waimaiClassfiy, waimaiProductList } from '../json/order.json';
import AutoWidthInput from "@/components/common/auto-width-input.vue"; import AutoWidthInput from "@/components/common/auto-width-input.vue";
import DateTimePicker from '@/components/dengrq-datetime-picker/dateTimePicker/index.vue'; import DateTimePicker from '@/components/dengrq-datetime-picker/dateTimePicker/index.vue';
import { imgLocal } from '@/utils/common.js';
const isScrolled = ref(false); const isScrolled = ref(false);
const screenshotImage = ref(''); const screenshotImage = ref('');
@ -464,7 +465,7 @@ const switchTab = (item) => {
fees: JSON.parse(JSON.stringify(order.value.fees || [])), fees: JSON.parse(JSON.stringify(order.value.fees || [])),
compensations: JSON.parse(JSON.stringify(order.value.compensations || [])), compensations: JSON.parse(JSON.stringify(order.value.compensations || [])),
deliveryPhoto: order.value.deliveryPhoto, deliveryPhoto: order.value.deliveryPhoto,
mapUrl: order.value.mapUrl, mapUrl: order.value.mapUrl || mapPhotos.value[0],
deliveryTime: order.value.deliveryTime, deliveryTime: order.value.deliveryTime,
remainingPayTime: order.value.remainingPayTime, remainingPayTime: order.value.remainingPayTime,
surplusDeliveryTime: order.value.surplusDeliveryTime, surplusDeliveryTime: order.value.surplusDeliveryTime,
@ -498,7 +499,7 @@ const switchTab = (item) => {
} }
if (backup.mapUrl) { if (backup.mapUrl) {
order.value.mapUrl = backup.mapUrl; order.value.mapUrl = backup.mapUrl || mapPhotos.value[0];
} else { } else {
order.value.mapUrl = mapPhotos.value[0]; order.value.mapUrl = mapPhotos.value[0];
} }
@ -542,6 +543,7 @@ const onConfirm = () => {
const idx = list.findIndex(item => String(item.id) === String(currentId.value)); const idx = list.findIndex(item => String(item.id) === String(currentId.value));
if (idx > -1) { if (idx > -1) {
list[idx] = JSON.parse(JSON.stringify(order.value)); list[idx] = JSON.parse(JSON.stringify(order.value));
console.log(list[idx], "编辑")
} else { } else {
list.unshift(JSON.parse(JSON.stringify(order.value))); list.unshift(JSON.parse(JSON.stringify(order.value)));
} }
@ -582,7 +584,7 @@ const setDefaultOrderTime = () => {
} }
}; };
onLoad((options) => { onLoad(async (options) => {
const editFlag = String(options.isEdit) === 'true' || options.isEdit === true; const editFlag = String(options.isEdit) === 'true' || options.isEdit === true;
if (editFlag && options.id) { if (editFlag && options.id) {
isEditMode.value = true; isEditMode.value = true;
@ -602,6 +604,11 @@ onLoad((options) => {
setDefaultOrderTime(); setDefaultOrderTime();
clickRandomDate(); clickRandomDate();
} }
const map1 = await imgLocal.getLocalImage(`shopping/taobao/waimai/map1.png`)
const map2 = await imgLocal.getLocalImage(`shopping/taobao/waimai/map2.png`)
mapPhotos.value[0] = map1;
mapPhotos.value[1] = map2;
}); });
// === (mm:ss) === // === (mm:ss) ===

View File

@ -721,7 +721,7 @@
"remainingPayTime": "", "remainingPayTime": "",
"orderQty": "12单", "orderQty": "12单",
"surplusDeliveryTime": "40分钟", "surplusDeliveryTime": "40分钟",
"mapUrl": "/static/image/shopping/taobao/waimai/map1.png", "mapUrl": "",
"goodsList": [ "goodsList": [
{ {
"image": "", "image": "",
@ -1208,7 +1208,7 @@
"remainingPayTime": "05:13", "remainingPayTime": "05:13",
"orderQty": "2单", "orderQty": "2单",
"surplusDeliveryTime": "20分钟", "surplusDeliveryTime": "20分钟",
"mapUrl": "/static/image/shopping/taobao/waimai/map1.png", "mapUrl": "",
"goodsList": [ "goodsList": [
{ {
"image": "/static/image/shopping/jingdong/product/waimai/haidilao.png", "image": "/static/image/shopping/jingdong/product/waimai/haidilao.png",

View File

@ -28,9 +28,8 @@
</nav-bar> </nav-bar>
<!-- 待收货骑手地图 --> <!-- 待收货骑手地图 -->
<view v-if="order.statusType == 'wait_recv'" class="map-box" <view v-if="order.statusType == 'wait_recv'" class="map-box"
:style="{ 'background-image': 'url(' + (order.mapUrl || '/static/image/shopping/taobao/waimai/map1.png') + ')' }"> :style="{ 'background-image': 'url(' + (order.mapUrl || defaultMap) + ')' }">
<image style="width: 100%;opacity: 0;" <image style="width: 100%;opacity: 0;" :src="order.mapUrl || defaultMap" mode="widthFix">
:src="order.mapUrl || '/static/image/shopping/taobao/waimai/map1.png'" mode="widthFix">
</image> </image>
<view class="qishou flex-align-center flex-column"> <view class="qishou flex-align-center flex-column">
<view class="qishou-info"> <view class="qishou-info">
@ -310,6 +309,7 @@ import { ref, reactive, computed } from 'vue';
import { onPageScroll, onShow, onLoad } from '@dcloudio/uni-app'; import { onPageScroll, onShow, onLoad } from '@dcloudio/uni-app';
import { util } from '@/utils/common.js'; import { util } from '@/utils/common.js';
import { defualtData } from '../json/order.json'; import { defualtData } from '../json/order.json';
import { imgLocal } from '@/utils/common.js';
const isScrolled = ref(false); const isScrolled = ref(false);
const screenshotImage = ref('') const screenshotImage = ref('')
@ -335,11 +335,13 @@ const order = ref({});
const currentId = ref(''); const currentId = ref('');
const isExpanded = ref(false); const isExpanded = ref(false);
const isOrderInfoExpanded = ref(false); const isOrderInfoExpanded = ref(false);
const defaultMap = ref('');
onLoad((options) => { onLoad(async (options) => {
if (options.id) { if (options.id) {
currentId.value = String(options.id); currentId.value = String(options.id);
} }
defaultMap.value = await imgLocal.getLocalImage(`shopping/taobao/waimai/map1.png`)
}); });
onShow(() => { onShow(() => {