提交 53d9ac7f 作者: 方治民

fix: 修复图片地址、接口前缀、界面链接交互等问题

上级 c7c8d68a
# API 接口地址 # API 接口地址
# VITE_GLOB_API_URL=http://111.22.182.169:49600 VITE_GLOB_API_URL=http://111.22.182.169:49600
VITE_GLOB_API_URL=http://36.133.16.81:42111 # VITE_GLOB_API_URL=http://36.133.16.81:42111
# API 接口地址前缀 # API 接口地址前缀
VITE_GLOB_API_URL_PREFIX=/jeecg-boot VITE_GLOB_API_URL_PREFIX=/jeecg-boot
...@@ -312,7 +312,7 @@ ...@@ -312,7 +312,7 @@
title="服务协议及隐私保护" title="服务协议及隐私保护"
:buttons="[ :buttons="[
{ text: '不同意', plain: true }, { text: '不同意', plain: true },
{ text: '同意', plain: false }, { text: '同意', plain: false, color: '#fff' },
]" ]"
@click="onReadConfirm" @click="onReadConfirm"
> >
......
...@@ -286,6 +286,10 @@ ...@@ -286,6 +286,10 @@
function onBaseManagementClick(item: any) { function onBaseManagementClick(item: any) {
console.log('点击基地管理项:', item) console.log('点击基地管理项:', item)
// 在这里添加具体的基地管理点击逻辑 // 在这里添加具体的基地管理点击逻辑
uni.navigateTo({
url: '/pages/jidiguanli/jidiguanli',
})
} }
// 查看更多监测预警 // 查看更多监测预警
...@@ -311,7 +315,7 @@ ...@@ -311,7 +315,7 @@
// 在这里添加具体的查看逻辑 // 在这里添加具体的查看逻辑
// 跳转到灵活用工界面 // 跳转到灵活用工界面
Navigate.to('/pages/linghuoyonggong/linghuoyonggong?type=' + type) Navigate.to(`/pages/linghuoyonggong/linghuoyonggong?type=${type}`)
} }
// 查看金融服务 // 查看金融服务
...@@ -345,9 +349,9 @@ ...@@ -345,9 +349,9 @@
} }
// 解决轮播视频切换时,上一个视频不停止播放的问题 // 解决轮播视频切换时,上一个视频不停止播放的问题
const handleVideoPlay = (currentIndex) => { function handleVideoPlay(currentIndex) {
pageData.agricultureClass.videoList.forEach((_, index) => { pageData.agricultureClass.videoList.forEach((_, index) => {
if (index != currentIndex) { if (index !== currentIndex) {
const videoContext = uni.createVideoContext(`video${index}`) const videoContext = uni.createVideoContext(`video${index}`)
videoContext.pause() videoContext.pause()
} }
...@@ -477,7 +481,7 @@ ...@@ -477,7 +481,7 @@
<view class="codefun-flex-col group_15"> <view class="codefun-flex-col group_15">
<view class="codefun-flex-row codefun-justify-between codefun-items-baseline"> <view class="codefun-flex-row codefun-justify-between codefun-items-baseline">
<text class="font text_28">基地管理</text> <text class="font text_28">基地管理</text>
<text class="font_6 text_29">更多</text> <text class="font_6 text_29" @click="onBaseManagementClick">更多</text>
</view> </view>
<view class="codefun-flex-row equal-division_5 mt-17"> <view class="codefun-flex-row equal-division_5 mt-17">
<view <view
...@@ -679,7 +683,7 @@ ...@@ -679,7 +683,7 @@
> >
<swiper-item v-for="(video, index) in pageData.agricultureClass.videoList" :key="index"> <swiper-item v-for="(video, index) in pageData.agricultureClass.videoList" :key="index">
<video <video
:id="'video' + index" :id="`video${index}`"
:src="video.media_video" :src="video.media_video"
:poster="video.cover_image" :poster="video.cover_image"
:controls="false" :controls="false"
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
<text class="font_2 text_3">选择市县乡镇</text> <text class="font_2 text_3">选择市县乡镇</text>
<image <image
class="codefun-shrink-0 image_7 codefun-ml-4" class="codefun-shrink-0 image_7 codefun-ml-4"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=774cfe989f8417dc655fb301635f5893.png" src="/static/images/codefun/774cfe989f8417dc655fb301635f5893.png"
/> />
</view> </view>
</view> </view>
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
<view class="codefun-flex-row group_6"> <view class="codefun-flex-row group_6">
<image <image
class="codefun-shrink-0 codefun-self-center image_8" class="codefun-shrink-0 codefun-self-center image_8"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=1f4e4111336d0f182201176d8c761a37.png" src="/static/images/codefun/1f4e4111336d0f182201176d8c761a37.png"
/> />
<view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-self-center group_4"> <view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-self-center group_4">
<text class="font text_6">大联合收割机</text> <text class="font text_6">大联合收割机</text>
...@@ -69,7 +69,7 @@ ...@@ -69,7 +69,7 @@
<view class="codefun-flex-row codefun-items-center codefun-flex-1 codefun-self-center"> <view class="codefun-flex-row codefun-items-center codefun-flex-1 codefun-self-center">
<image <image
class="codefun-shrink-0 image_8" class="codefun-shrink-0 image_8"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=e3f873f79cdddaee3655c048852302e3.png" src="/static/images/codefun/e3f873f79cdddaee3655c048852302e3.png"
/> />
<view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-12"> <view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-12">
<text class="font text_9">小麦播种机</text> <text class="font text_9">小麦播种机</text>
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
<view class="codefun-flex-row codefun-items-center codefun-flex-1 codefun-self-center"> <view class="codefun-flex-row codefun-items-center codefun-flex-1 codefun-self-center">
<image <image
class="codefun-shrink-0 image_8" class="codefun-shrink-0 image_8"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=da314c458ad5d6714cfe7ee8524ccd9c.png" src="/static/images/codefun/da314c458ad5d6714cfe7ee8524ccd9c.png"
/> />
<view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-12"> <view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-12">
<text class="font text_12">多功能拖拉机</text> <text class="font text_12">多功能拖拉机</text>
...@@ -120,7 +120,7 @@ ...@@ -120,7 +120,7 @@
<view class="codefun-flex-row codefun-items-center codefun-flex-1 codefun-self-center"> <view class="codefun-flex-row codefun-items-center codefun-flex-1 codefun-self-center">
<image <image
class="codefun-shrink-0 image_8" class="codefun-shrink-0 image_8"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=3500502108a998fe7f49363a276af806.png" src="/static/images/codefun/3500502108a998fe7f49363a276af806.png"
/> />
<view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-12"> <view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-12">
<text class="font">水稻插秧机</text> <text class="font">水稻插秧机</text>
...@@ -143,51 +143,36 @@ ...@@ -143,51 +143,36 @@
<view class="grid"> <view class="grid">
<view class="codefun-flex-row codefun-justify-between codefun-items-center grid-item"> <view class="codefun-flex-row codefun-justify-between codefun-items-center grid-item">
<text class="font_3 text_19">农机类型</text> <text class="font_3 text_19">农机类型</text>
<image <image class="image_10" src="/static/images/codefun/a13c36a46232de65d09f43b1720ba29d.png" />
class="image_10"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=a13c36a46232de65d09f43b1720ba29d.png"
/>
</view> </view>
<view class="codefun-flex-row codefun-justify-between codefun-items-center grid-item_2"> <view class="codefun-flex-row codefun-justify-between codefun-items-center grid-item_2">
<view class="codefun-flex-row codefun-items-center"> <view class="codefun-flex-row codefun-items-center">
<image <image
class="codefun-shrink-0 image_9" class="codefun-shrink-0 image_9"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=bf7b1672e65ba021aa79827f30014280.png" src="/static/images/codefun/bf7b1672e65ba021aa79827f30014280.png"
/> />
<text class="font_3 text_20 codefun-ml-8">作业地点</text> <text class="font_3 text_20 codefun-ml-8">作业地点</text>
</view> </view>
<image <image class="image_10" src="/static/images/codefun/a13c36a46232de65d09f43b1720ba29d.png" />
class="image_10"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=a13c36a46232de65d09f43b1720ba29d.png"
/>
</view> </view>
<view class="codefun-flex-row codefun-justify-between codefun-items-center grid-item_4"> <view class="codefun-flex-row codefun-justify-between codefun-items-center grid-item_4">
<view class="codefun-flex-row codefun-items-center"> <view class="codefun-flex-row codefun-items-center">
<image <image
class="codefun-shrink-0 image_11" class="codefun-shrink-0 image_11"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=206576465476f031295c48dcef261286.png" src="/static/images/codefun/206576465476f031295c48dcef261286.png"
/> />
<text class="font_3 text_21 codefun-ml-4">作业时间</text> <text class="font_3 text_21 codefun-ml-4">作业时间</text>
</view> </view>
<image <image class="image_10" src="/static/images/codefun/a13c36a46232de65d09f43b1720ba29d.png" />
class="image_10"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=a13c36a46232de65d09f43b1720ba29d.png"
/>
</view> </view>
<view class="codefun-flex-row codefun-items-center grid-item_4"> <view class="codefun-flex-row codefun-items-center grid-item_4">
<image <image class="image_12" src="/static/images/codefun/43220b5bebf6a41ff3f05e6ec94ce9f0.png" />
class="image_12"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=43220b5bebf6a41ff3f05e6ec94ce9f0.png"
/>
<text class="font_3 text_22 codefun-ml-4">联系方式</text> <text class="font_3 text_22 codefun-ml-4">联系方式</text>
</view> </view>
</view> </view>
<view class="codefun-flex-col codefun-mt-12"> <view class="codefun-flex-col codefun-mt-12">
<view class="codefun-flex-row codefun-items-center grid-item group_12"> <view class="codefun-flex-row codefun-items-center grid-item group_12">
<image <image class="image_13" src="/static/images/codefun/a83082710831140b897349a7f3bd46d9.png" />
class="image_13"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=a83082710831140b897349a7f3bd46d9.png"
/>
<text class="font_3 text_23 codefun-ml-8">简要说明作业需求</text> <text class="font_3 text_23 codefun-ml-8">简要说明作业需求</text>
</view> </view>
<view <view
...@@ -203,7 +188,7 @@ ...@@ -203,7 +188,7 @@
<style scoped lang="scss"> <style scoped lang="scss">
.page { .page {
padding-bottom: 64rpx; padding-bottom: 12rpx;
background-color: #e6f5e8; background-color: #e6f5e8;
mix-blend-mode: NOTTHROUGH; mix-blend-mode: NOTTHROUGH;
width: 100%; width: 100%;
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
<view class="codefun-flex-col equal-division-item group_4"> <view class="codefun-flex-col equal-division-item group_4">
<image <image
class="codefun-self-center image_6" class="codefun-self-center image_6"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=1d8e91708cae6b6244d183b5c3eb1c5e.png" src="/static/images/codefun/1d8e91708cae6b6244d183b5c3eb1c5e.png"
/> />
<view <view
class="codefun-flex-row codefun-justify-center codefun-items-baseline codefun-self-stretch group_7 codefun-mt-8" class="codefun-flex-row codefun-justify-center codefun-items-baseline codefun-self-stretch group_7 codefun-mt-8"
...@@ -32,12 +32,12 @@ ...@@ -32,12 +32,12 @@
> >
<image <image
class="codefun-self-start image_9 image_10" class="codefun-self-start image_9 image_10"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=ac7a11ec05eb9854a6d3ee34633c53c0.png" src="/static/images/codefun/ac7a11ec05eb9854a6d3ee34633c53c0.png"
/> />
<view class="codefun-flex-col group_6"> <view class="codefun-flex-col group_6">
<image <image
class="codefun-self-center image_7" class="codefun-self-center image_7"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=5d6c7fea65df7f4528d28301a632acca.png" src="/static/images/codefun/5d6c7fea65df7f4528d28301a632acca.png"
/> />
<view class="codefun-flex-row codefun-items-baseline codefun-self-center codefun-mt-8"> <view class="codefun-flex-row codefun-items-baseline codefun-self-center codefun-mt-8">
<text class="font_3">开花</text> <text class="font_3">开花</text>
...@@ -48,12 +48,12 @@ ...@@ -48,12 +48,12 @@
<view class="codefun-flex-row codefun-justify-center group_5 equal-division-item_2"> <view class="codefun-flex-row codefun-justify-center group_5 equal-division-item_2">
<image <image
class="codefun-self-center image_9 pos_3" class="codefun-self-center image_9 pos_3"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=ac7a11ec05eb9854a6d3ee34633c53c0.png" src="/static/images/codefun/ac7a11ec05eb9854a6d3ee34633c53c0.png"
/> />
<view class="codefun-flex-col"> <view class="codefun-flex-col">
<image <image
class="codefun-self-center image_7" class="codefun-self-center image_7"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=23995baf95335d84a302baeadeeeb5d3.png" src="/static/images/codefun/23995baf95335d84a302baeadeeeb5d3.png"
/> />
<view class="codefun-flex-row codefun-items-baseline codefun-self-stretch codefun-mt-8"> <view class="codefun-flex-row codefun-items-baseline codefun-self-stretch codefun-mt-8">
<text class="font_3 text_5">结果</text> <text class="font_3 text_5">结果</text>
...@@ -90,10 +90,7 @@ ...@@ -90,10 +90,7 @@
<view class="codefun-flex-row horiz-list group_13 codefun-mt-16"> <view class="codefun-flex-row horiz-list group_13 codefun-mt-16">
<view class="codefun-flex-col horiz-list-item section_5"> <view class="codefun-flex-col horiz-list-item section_5">
<view class="codefun-flex-row codefun-items-center codefun-self-stretch"> <view class="codefun-flex-row codefun-items-center codefun-self-stretch">
<image <image class="image_11" src="/static/images/codefun/22109e59215c3e6f8e24b54d126d851f.png" />
class="image_11"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=22109e59215c3e6f8e24b54d126d851f.png"
/>
<text class="font_7 text_16 codefun-ml-4">智能预警</text> <text class="font_7 text_16 codefun-ml-4">智能预警</text>
</view> </view>
<text class="codefun-self-start font_12 text_18 codefun-mt-10">如何提前预防柑橘黄龙病?</text> <text class="codefun-self-start font_12 text_18 codefun-mt-10">如何提前预防柑橘黄龙病?</text>
...@@ -104,10 +101,7 @@ ...@@ -104,10 +101,7 @@
</view> </view>
<view class="codefun-flex-col horiz-list-item_2 section_6 mx-3.5"> <view class="codefun-flex-col horiz-list-item_2 section_6 mx-3.5">
<view class="codefun-flex-row codefun-items-center"> <view class="codefun-flex-row codefun-items-center">
<image <image class="image_12" src="/static/images/codefun/93b830e77b49a5d5a885dba853cca4f2.png" />
class="image_12"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=93b830e77b49a5d5a885dba853cca4f2.png"
/>
<text class="font_7 text_17 codefun-ml-4">精准施肥</text> <text class="font_7 text_17 codefun-ml-4">精准施肥</text>
</view> </view>
<text class="font_12 text_19 codefun-mt-10">柑橘园精准水肥管理方案</text> <text class="font_12 text_19 codefun-mt-10">柑橘园精准水肥管理方案</text>
...@@ -124,7 +118,7 @@ ...@@ -124,7 +118,7 @@
<view class="codefun-flex-col equal-division-item_4 group_16"> <view class="codefun-flex-col equal-division-item_4 group_16">
<image <image
class="codefun-self-center image_13" class="codefun-self-center image_13"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=8d95c077ff410c467d25f1d02b84cd3c.png" src="/static/images/codefun/8d95c077ff410c467d25f1d02b84cd3c.png"
/> />
<view class="codefun-flex-col codefun-self-stretch codefun-mt-20"> <view class="codefun-flex-col codefun-self-stretch codefun-mt-20">
<text class="codefun-self-center font_9">数据录入</text> <text class="codefun-self-center font_9">数据录入</text>
...@@ -134,13 +128,13 @@ ...@@ -134,13 +128,13 @@
<view class="codefun-flex-col equal-division-item_5 group_17"> <view class="codefun-flex-col equal-division-item_5 group_17">
<image <image
class="codefun-self-center image_14" class="codefun-self-center image_14"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=e4453ccb0959797614bc6ffb5d62d56f.png" src="/static/images/codefun/e4453ccb0959797614bc6ffb5d62d56f.png"
/> />
<view class="codefun-flex-col codefun-self-stretch codefun-mt-16"> <view class="codefun-flex-col codefun-self-stretch codefun-mt-16">
<view class="codefun-flex-col codefun-self-stretch group_20"> <view class="codefun-flex-col codefun-self-stretch group_20">
<image <image
class="codefun-shrink-0 codefun-self-start image_9 image_16" class="codefun-shrink-0 codefun-self-start image_9 image_16"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=b31cf305e90b1547bca2725e5a2ea5be.png" src="/static/images/codefun/b31cf305e90b1547bca2725e5a2ea5be.png"
/> />
<text class="codefun-self-center font_9 text_22">模型选择</text> <text class="codefun-self-center font_9 text_22">模型选择</text>
</view> </view>
...@@ -150,12 +144,12 @@ ...@@ -150,12 +144,12 @@
<view class="codefun-flex-row codefun-justify-between equal-division-item_6 group_18"> <view class="codefun-flex-row codefun-justify-between equal-division-item_6 group_18">
<image <image
class="codefun-self-start image_9 image_17" class="codefun-self-start image_9 image_17"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=b31cf305e90b1547bca2725e5a2ea5be.png" src="/static/images/codefun/b31cf305e90b1547bca2725e5a2ea5be.png"
/> />
<view class="codefun-flex-col group_19"> <view class="codefun-flex-col group_19">
<image <image
class="codefun-self-center image_15" class="codefun-self-center image_15"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=a8dc70a912aaa771eddc3a2bd607fdc3.png" src="/static/images/codefun/a8dc70a912aaa771eddc3a2bd607fdc3.png"
/> />
<view class="codefun-flex-col codefun-self-stretch codefun-mt-16"> <view class="codefun-flex-col codefun-self-stretch codefun-mt-16">
<text class="codefun-self-center font_9 text_21">查看结果</text> <text class="codefun-self-center font_9 text_21">查看结果</text>
...@@ -184,10 +178,7 @@ ...@@ -184,10 +178,7 @@
<text class="font_12 text_28 text_31">何时适合采摘?</text> <text class="font_12 text_28 text_31">何时适合采摘?</text>
</view> </view>
</view> </view>
<image <image class="image_18 pos_4" src="/static/images/codefun/8ecf54ab157b99371d9e1fecfa1ef085.png" />
class="image_18 pos_4"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=8ecf54ab157b99371d9e1fecfa1ef085.png"
/>
</view> </view>
</view> </view>
<view class="codefun-flex-col codefun-mt-24"> <view class="codefun-flex-col codefun-mt-24">
...@@ -199,10 +190,7 @@ ...@@ -199,10 +190,7 @@
<view <view
class="codefun-flex-col codefun-justify-start codefun-items-center codefun-shrink-0 codefun-self-center image-wrapper" class="codefun-flex-col codefun-justify-start codefun-items-center codefun-shrink-0 codefun-self-center image-wrapper"
> >
<image <image class="image_19" src="/static/images/codefun/ad2e6d5cc57cc9e4a91adc18b3a155e2.png" />
class="image_19"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=ad2e6d5cc57cc9e4a91adc18b3a155e2.png"
/>
</view> </view>
<view class="codefun-flex-col codefun-flex-1 codefun-self-start group_23 codefun-ml-12"> <view class="codefun-flex-col codefun-flex-1 codefun-self-start group_23 codefun-ml-12">
<text class="codefun-self-start font_12 text_33">胡萝卜高产种植技术要点</text> <text class="codefun-self-start font_12 text_33">胡萝卜高产种植技术要点</text>
...@@ -210,14 +198,14 @@ ...@@ -210,14 +198,14 @@
<view class="codefun-flex-row codefun-items-center"> <view class="codefun-flex-row codefun-items-center">
<image <image
class="codefun-shrink-0 image_20" class="codefun-shrink-0 image_20"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=74964a1e25c0e7d8c97198b99483e54a.png" src="/static/images/codefun/74964a1e25c0e7d8c97198b99483e54a.png"
/> />
<text class="font_4 text_34 codefun-ml-4">12:30</text> <text class="font_4 text_34 codefun-ml-4">12:30</text>
</view> </view>
<view class="codefun-flex-row codefun-items-center codefun-ml-20"> <view class="codefun-flex-row codefun-items-center codefun-ml-20">
<image <image
class="codefun-shrink-0 image_21" class="codefun-shrink-0 image_21"
src="https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=e8cae542eda3d68f054b3e0ce2afa242.png" src="/static/images/codefun/e8cae542eda3d68f054b3e0ce2afa242.png"
/> />
<text class="font_4 text_35 codefun-ml-6">99</text> <text class="font_4 text_35 codefun-ml-6">99</text>
</view> </view>
...@@ -240,7 +228,7 @@ ...@@ -240,7 +228,7 @@
overflow-x: hidden; overflow-x: hidden;
.group { .group {
.section_2 { .section_2 {
background-image: url('https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=c122979639a1f9d27d7c57245ab420a6.png'); background-image: url('/static/images/codefun/c122979639a1f9d27d7c57245ab420a6.png');
background-size: 100% 100%; background-size: 100% 100%;
background-repeat: no-repeat; background-repeat: no-repeat;
.section_3 { .section_3 {
...@@ -587,7 +575,7 @@ ...@@ -587,7 +575,7 @@
backdrop-filter: blur(4rpx); backdrop-filter: blur(4rpx);
.image-wrapper { .image-wrapper {
padding: 48rpx 0; padding: 48rpx 0;
background-image: url('https://ide.code.fun/api/image?token=6902c43a9520a30011f4e723&name=5149f97303e2fa97daa823a1452dce11.png'); background-image: url('/static/images/codefun/5149f97303e2fa97daa823a1452dce11.png');
background-size: 100% 100%; background-size: 100% 100%;
background-repeat: no-repeat; background-repeat: no-repeat;
width: 240rpx; width: 240rpx;
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
onLoad(() => { onLoad(() => {
uni.getLocation({ uni.getLocation({
type: 'wgs84', type: 'wgs84',
success: function (res) { success(res) {
pageData.weather.lon = res.longitude pageData.weather.lon = res.longitude
pageData.weather.lat = res.latitude pageData.weather.lat = res.latitude
uni.setStorageSync('location', { uni.setStorageSync('location', {
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
lat: res.latitude, lat: res.latitude,
}) })
}, },
fail: function (error) { fail() {
uni.showToast({ uni.showToast({
title: '获取地址失败,将导致部分功能不可用', title: '获取地址失败,将导致部分功能不可用',
icon: 'none', icon: 'none',
...@@ -243,7 +243,9 @@ ...@@ -243,7 +243,9 @@
}) })
} }
function getWarningInfo() { function getWarningInfo() {
if (!pageData.weather.lon || !pageData.weather.lat) return if (!pageData.weather.lon || !pageData.weather.lat) {
return
}
HomeAPI.warningInfo({ HomeAPI.warningInfo({
lon: pageData.weather.lon, lon: pageData.weather.lon,
...@@ -319,9 +321,9 @@ ...@@ -319,9 +321,9 @@
pageData.agricultureClass.time = e.target.duration pageData.agricultureClass.time = e.target.duration
} }
// 解决轮播视频切换时,上一个视频不停止播放的问题 // 解决轮播视频切换时,上一个视频不停止播放的问题
const handleVideoPlay = (currentIndex) => { function handleVideoPlay(currentIndex) {
pageData.agricultureClass.videoList.forEach((_, index) => { pageData.agricultureClass.videoList.forEach((_, index) => {
if (index != currentIndex) { if (index !== currentIndex) {
const videoContext = uni.createVideoContext(`video${index}`) const videoContext = uni.createVideoContext(`video${index}`)
videoContext.pause() videoContext.pause()
} }
...@@ -367,12 +369,12 @@ ...@@ -367,12 +369,12 @@
/> />
<view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-10"> <view class="codefun-flex-col codefun-items-start codefun-flex-1 codefun-ml-10">
<text class="text_5">{{ pageData.weather.temperature }}</text> <text class="text_5">{{ pageData.weather.temperature }}</text>
<text class="font_2 text_8 !text-26rpx codefun-mt-16">{{ <text class="font_2 text_8 !text-24rpx codefun-mt-16">{{
pageData.weather.condition pageData.weather.condition
}}</text> }}</text>
</view> </view>
</view> </view>
<view class="codefun-flex-col group_6 codefun-ml-22"> <view class="codefun-flex-col group_6 ml-2">
<view class="codefun-flex-row codefun-justify-between group_7"> <view class="codefun-flex-row codefun-justify-between group_7">
<!-- <image <!-- <image
class="image_9" class="image_9"
...@@ -587,7 +589,7 @@ ...@@ -587,7 +589,7 @@
> >
<swiper-item v-for="(video, index) in pageData.agricultureClass.videoList" :key="index"> <swiper-item v-for="(video, index) in pageData.agricultureClass.videoList" :key="index">
<video <video
:id="'video' + index" :id="`video${index}`"
:src="video.media_video" :src="video.media_video"
:poster="video.cover_image" :poster="video.cover_image"
:controls="false" :controls="false"
......
...@@ -158,7 +158,7 @@ ...@@ -158,7 +158,7 @@
margin-left: 18rpx; margin-left: 18rpx;
} }
.page { .page {
padding-bottom: 148rpx; padding-bottom: 28rpx;
background-color: #e6f5e8; background-color: #e6f5e8;
mix-blend-mode: NOTTHROUGH; mix-blend-mode: NOTTHROUGH;
width: 100%; width: 100%;
......
...@@ -9,6 +9,9 @@ const PROXY_LIST: [[string, string]?] = [ ...@@ -9,6 +9,9 @@ const PROXY_LIST: [[string, string]?] = [
// ['http://10.111.117.15:18100', `http://proxy.yiring.com:42180`], // ['http://10.111.117.15:18100', `http://proxy.yiring.com:42180`],
// eg: 生产环境 // eg: 生产环境
// [`http://192.168.0.100:18100`, `https://oss.beta.app.yiring.com`], // [`http://192.168.0.100:18100`, `https://oss.beta.app.yiring.com`],
// 开发环境(预览)
[`http://192.168.0.156:18100`, `http://111.22.182.169:49091`],
] ]
/** /**
...@@ -47,9 +50,15 @@ export function getIntranetUrl(url: string): string { ...@@ -47,9 +50,15 @@ export function getIntranetUrl(url: string): string {
*/ */
export function handleResponseResource<T>(body: T, options: Recordable) { export function handleResponseResource<T>(body: T, options: Recordable) {
for (const [intranet, extranet] of PROXY_LIST) { for (const [intranet, extranet] of PROXY_LIST) {
// FIXME: 临时处理,解决内网文件上传后预览,但是实际上传存储时还是内网地址的问题
const host = options.apiUrl.replace(/https?:\/\/(.*):\d+/, '$1')
const isIntranet = intranet.includes(host)
const isExtranet = extranet.includes(host)
// console.log('handleResponseResource', body, options.apiUrl, host, isIntranet, isExtranet)
// 当需要处理内外网资源地址映射时,进行内容处理 // 当需要处理内外网资源地址映射时,进行内容处理
const isIntranet = options.apiUrl.includes(intranet) // const isIntranet = options.apiUrl.includes(intranet)
const isExtranet = options.apiUrl.includes(extranet) // const isExtranet = options.apiUrl.includes(extranet)
if (isIntranet || isExtranet) { if (isIntranet || isExtranet) {
const isString = typeof body === 'string' const isString = typeof body === 'string'
const isObject = typeof body === 'object' const isObject = typeof body === 'object'
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论