Files
yimo-resource-blog/pages/blog/resource.vue

910 lines
24 KiB
Vue
Raw Normal View History

2025-08-14 15:04:24 +08:00
<template>
<view style="min-height: 100vh;position: relative;">
<!-- 顶部图片 -->
<view class="top-img">
<image class="ui-img" :src="$image.original(resourceInfo.showImg)" mode="aspectFill"></image>
2025-08-14 15:04:24 +08:00
<text @click="back()" class="cuIcon-back backbut"></text>
</view>
<view class="resource-box">
<view class="resource-view">
<view class="resource-img">
<image class="ui-img" src="https://img.yidaima.cn/feast/xiazai.svg" mode="aspectFit"></image>
</view>
<view class="resource-font">
{{resourceInfo.resourceTitle}}
</view>
</view>
<view class="resource-list">
<view v-if="type != 1" class="resource-view">
<view class="resource-img2">
<image class="ui-img" src="https://img.yidaima.cn/shuoming.svg" mode="aspectFit"></image>
</view>
<view class="resource-font2">
下载说明
</view>
</view>
<view v-if="type != 1" class="data-view">
<view style="border: 1px solid #ffffff" class="ql-container ql-snow">
<rich-text :nodes="contentDate" class="ql-editor"></rich-text>
</view>
<!-- <mp-html class="ql-editor" :tag-style="tag_style" :content="contentDate" :container-style="container_style"
selectable="true"> </mp-html> -->
</view>
2026-07-29 14:35:13 +08:00
<!-- 付费资源规格 -->
<view v-if="isLookAd == 3" class="spec-section">
<view class="resource-view">
<view class="resource-img2">
<image class="ui-img" src="https://img.yidaima.cn/feast/files.svg" mode="aspectFit"></image>
</view>
<view class="resource-font2">选择版本</view>
</view>
<view v-if="paySpecs.length" class="spec-list">
<view
v-for="item in paySpecs"
:key="item.id"
class="spec-item"
:class="{'spec-item-selected': selectedResourceListId == item.id}"
@click="selectSpec(item)"
>
<view class="spec-name">
{{item.listName}}
<text v-if="item.purchased" class="purchased-tag">已拥有</text>
<text v-else-if="item.status == 0" class="disabled-tag">已停用</text>
</view>
<view class="spec-price">
<text v-if="isUpgradeSpec(item)" class="upgrade-price-label"></text>
¥{{formatPrice(getPayablePriceFen(item))}}
</view>
</view>
</view>
<view v-else class="empty-spec">暂无可购买规格请联系管理员</view>
</view>
2025-08-14 15:04:24 +08:00
<!-- 资源列表 -->
<view>
<view class="resource-view">
<view class="resource-img2">
<image class="ui-img" src="https://img.yidaima.cn/feastwenjian.svg" mode="aspectFit"></image>
</view>
<view class="resource-font2">
2026-07-29 14:35:13 +08:00
{{isLookAd == 3 ? '已购资源' : '资源列表'}}
2025-08-14 15:04:24 +08:00
</view>
</view>
2026-07-29 14:35:13 +08:00
<template v-if="isLookAd == 3">
<view v-if="purchasedSpecs.length" id="purchased-resources">
<view class="shuoming2">复制下方链接打开手机浏览器进行下载</view>
<view v-for="item in purchasedSpecs" :key="item.id" class="file-list purchased-file">
<view class="resource-view">
<view class="resource-img3">
<image class="ui-img" src="https://img.yidaima.cn/feast/files.svg" mode="aspectFit"></image>
</view>
<view class="resource-font3">
{{item.listName}}
<text class="password" v-if="item.password">密码{{item.password}}</text>
</view>
</view>
<view class="file-url-box">
<text class="file-url">{{item.listUrl}}</text>
<text @click="copy(item.listUrl)" class="file-copy">复制</text>
</view>
</view>
</view>
<view v-else class="shuoming2">选择上方版本并完成付款后即可查看下载地址</view>
</template>
<template v-else>
<view v-if="isLookAd == 0" class="shuoming2">复制下方链接打开手机浏览器进行下载</view>
<view v-else class="shuoming2">请先点击下方按钮即可获取资源下载列表</view>
</template>
<template v-if="isLookAd == 0">
<view v-for="(item,index) in resourceInfo.appResourceListList" :key="index" class="file-list">
2026-07-29 14:35:13 +08:00
<view class="resource-view">
<view class="resource-img3">
<image class="ui-img" src="https://img.yidaima.cn/feast/files.svg" mode="aspectFit"></image>
</view>
<view class="resource-font3">
{{item.listName}}<text class="password" v-if="item.password != '' && item.password != null"> 密码{{item.password}} </text>
</view>
2025-08-14 15:04:24 +08:00
</view>
2026-07-29 14:35:13 +08:00
<view class="file-url-box"><text class="file-url">{{item.listUrl}}</text><text @click="copy(item.listUrl)" class="file-copy">复制</text></view>
2025-08-14 15:04:24 +08:00
</view>
</template>
2025-08-14 15:04:24 +08:00
<view v-if="adUnitId" style="width: 100%; margin-top: 50rpx;">
<ad-custom :unit-id="adUnitId" ad-intervals="30" ></ad-custom>
</view>
</view>
</view>
</view>
2026-07-29 14:35:13 +08:00
<view
v-if="(isLookAd == 1 || isLookAd == 2 || isLookAd == 3) && (isLookAd != 3 || selectedSpec)"
class="action-placeholder"
:class="{'action-placeholder-paid': isLookAd == 3}"
></view>
<view
v-if="(isLookAd == 1 || isLookAd == 2 || isLookAd == 3) && (isLookAd != 3 || selectedSpec)"
class="bottom-action-bar"
>
<view v-if="isLookAd == 3 && selectedSpec" class="action-summary">
<view class="action-summary-name">
<text class="action-summary-label">{{selectedIsUpgrade ? '升级补差' : '已选'}}</text>
<text class="action-summary-value">{{selectedSpec.listName}}</text>
</view>
<view class="action-summary-price">¥{{formatPrice(selectedPayPriceFen)}}</view>
</view>
<view v-if="isLookAd ==1" @click="lookAd()" class="resource-ad">
广告查看
</view>
<view v-if="isLookAd ==2" @click="jfAd()" class="resource-ad">
积分获取 {{resourceInfo.adNumber}} 积分
</view>
<view v-if="isLookAd ==3 && selectedSpec" @click="handlePaidAction()" class="resource-ad" :class="{'resource-owned': selectedSpec.purchased}">
{{paidButtonText}}
</view>
</view>
2025-08-14 15:04:24 +08:00
<u-toast ref="uToast"></u-toast>
</view>
</template>
<script>
import {
getResource,getResourceByUserId,resourceDownLoad,appGetUserById,exchangeResource,
createVirtualResourceOrder,getVirtualResourceOrder
2025-08-14 15:04:24 +08:00
} from "@/api/app/index.js"
import config from '@/config'
let videoAd = null;
export default {
data() {
return {
baseUrl: config.baseUrl,
adUnitId:"",
adUnitId2:"",
id:null,
resourceInfo:{
resourceTitle: '',
showImg: '',
appResourceListList: []
},
2025-08-14 15:04:24 +08:00
isLookAd:null,
paying: false,
2026-07-29 14:35:13 +08:00
selectedResourceListId: null,
2025-08-14 15:04:24 +08:00
tag_style: {
h1: 'line-height: 50px;font-size:16px;',
h2: 'line-height: 50px;font-size:16px',
h3: 'line-height: 50px;font-size:16px',
h4: 'line-height: 50px;font-size:16px',
},
container_style: 'font-size:15px;overflow-x: hidden;line-height:30px;letter-spacing:1px',
contentDate: "",
userId: null,
type:0
}
},
2026-07-29 14:35:13 +08:00
computed: {
paySpecs() {
var list = this.resourceInfo.appResourceListList || [];
return list.filter(function(item) {
return item.status == 1 || item.purchased;
});
},
purchasedSpecs() {
return this.paySpecs.filter(function(item) {
return !!item.purchased && !!item.listUrl;
});
},
highestPurchasedSpec() {
var purchased = this.paySpecs.filter(function(item) {
return !!item.purchased;
});
purchased.sort(function(left, right) {
var sortDiff = Number(right.sortOrder || 0) - Number(left.sortOrder || 0);
return sortDiff || Number(right.id || 0) - Number(left.id || 0);
});
return purchased.length ? purchased[0] : null;
},
selectedSpec() {
var selectedId = this.selectedResourceListId;
return this.paySpecs.find(function(item) {
return String(item.id) === String(selectedId);
}) || null;
},
selectedPayPriceFen() {
return this.getPayablePriceFen(this.selectedSpec);
},
selectedIsUpgrade() {
return this.isUpgradeSpec(this.selectedSpec);
},
paidButtonText() {
if (!this.selectedSpec) {
return '暂无可购买规格';
}
if (this.selectedSpec.purchased) {
return '已购买,查看资源';
}
if (this.paying) {
return '支付结果确认中...';
}
return this.selectedIsUpgrade ? '补差价升级' : '立即购买';
}
},
2025-08-14 15:04:24 +08:00
// 分享好友配置
onShareAppMessage(res) {
var that = this;
return {
title: that.resourceInfo.resourceTitle,
imageUrl: that.resourceInfo.showImg,
path: 'pages/blog/resource?id='+that.resourceInfo.id+"&share=1",
}
},
onShareTimeline(){
var that = this;
return {
title:that.resourceInfo.resourceTitle,
query:{
id: that.resourceInfo.id,
share: 1
},
imageUrl:that.resourceInfo.showImg
}
},
onLoad(option) {
const sysSet = uni.getStorageSync("sysSet") || {}
const userInfo = uni.getStorageSync("userInfo") || {}
this.adUnitId = sysSet.zyinfoAd || ""
this.adUnitId2 = sysSet.downVideoAd || ""
this.userId = userInfo.userId || null
const id = option && option.id
if (!/^\d+$/.test(String(id || ''))) {
uni.showToast({
title: '资源参数错误,请重新进入',
icon: 'none'
})
return
}
this.id = id
2026-07-29 14:35:13 +08:00
if (option && /^\d+$/.test(String(option.resourceListId || ''))) {
this.selectedResourceListId = option.resourceListId
}
2025-08-14 15:04:24 +08:00
if(option.type){
this.type = option.type
}
// 请求详情
this.getInfo()
//初始化激励广告
this.CreateAd()
},
methods: {
CreateAd(){
var that = this;
if (this.adUnitId2 != '') {
if (wx.createRewardedVideoAd) {
videoAd = wx.createRewardedVideoAd({
adUnitId: this.adUnitId2
})
videoAd.onLoad(() => {})
videoAd.onError((err) => {
that.$refs.uToast.show({
type: 'error',
title: '',
message: "请使用移动端设备访问",
icon: false
})
})
videoAd.onClose((res) => {
if (res && res.isEnded) {
// that.$refs.uToast.show({
// type: 'success',
// title: '',
// message: "╮(๑•́ ₃•̀๑)╭ 谢谢您的支持 ",
// icon: false
// })
that.isLookAd = 0
resourceDownLoad({id: that.id}).then(response => {})
} else {
}
})
}
}
},
jfAd(){
var that = this;
appGetUserById(that.userId).then(response => {
if (that.resourceInfo.adNumber > response.user.integral) {
uni.showModal({
title: '积分不足',
content: '您的积分为 '+response.user.integral+' ,签到做任务可获得积分',
cancelText: "取消",
confirmText: "获取积分",
confirmColor:'#ff0000',
cancelColor:'#000000',
success: function(res) {
if (res.confirm) {
// 执行确认后的操作
uni.switchTab({
url: '/pages/mine/index'
});
}
else {
// 执行取消后的操作
}
}
})
} else {
var data = {
source: '资源兑换',
isAdd: 1,
integralNumber: that.resourceInfo.adNumber,
userId: that.userId,
resourceId: that.id
}
exchangeResource(data).then(response => {
that.$refs.uToast.show({
type: 'success',
title: '',
message: "兑换成功",
icon: false
})
that.getInfo()
2025-08-14 15:04:24 +08:00
})
}
})
},
lookAd(){
// 用户触发广告后,显示激励视频广告
if (videoAd) {
videoAd.show().catch(() => {
// 失败重试
videoAd.load()
.then(() => videoAd.show())
.catch(err => {
console.error('激励视频 广告显示失败', err)
})
})
}
//下载次数+1
//添加广告记录
},
getInfo(){
var that = this;
getResourceByUserId(this.id).then(response => {
if (!response || !response.data) {
uni.showToast({
title: '资源信息不存在',
icon: 'none'
})
return
}
2025-08-14 15:04:24 +08:00
if(response.data.isAd == 0){
this.isLookAd = 0
resourceDownLoad({id: this.id}).then(response => {})
}else if(response.data.isAd == 1){
this.isLookAd = 1
//resourceDownLoad({id: this.id}).then(response => {})
}else if(response.data.isAd == 2){
2025-08-14 15:04:24 +08:00
this.isLookAd = 2
}else if(response.data.isAd == 3){
this.isLookAd = 3
2025-08-14 15:04:24 +08:00
}
that.resourceInfo = response.data
2026-07-29 14:35:13 +08:00
if (response.data.isAd == 3) {
that.selectDefaultSpec()
}
var str = that.resourceInfo.explain || ''
2025-08-14 15:04:24 +08:00
if (str.includes("/dev-api")) {
that.resourceInfo.explain = str.replace("/dev-api", that.baseUrl)
} else {
that.resourceInfo.explain = str.replace("/prod-api", that.baseUrl)
}
that.contentDate = that.resourceInfo.explain
2025-08-14 15:04:24 +08:00
.replace(/<h1([\s\w"=\/\.:;]+)((?:(style="[^"]+")))/ig, '<h1')
.replace(/<h1([\s\w"=\/\.:;]+)((?:(class="[^"]+")))/ig, '<h1')
.replace(/<h1>/ig, '<h1 class="h1">')
.replace(/<h2([\s\w"=\/\.:;]+)((?:(style="[^"]+")))/ig, '<h2')
.replace(/<h2([\s\w"=\/\.:;]+)((?:(class="[^"]+")))/ig, '<h2')
.replace(/<h2>/ig, '<h2 class="h2">')
.replace(/<h3([\s\w"=\/\.:;]+)((?:(style="[^"]+")))/ig, '<h3')
.replace(/<h3([\s\w"=\/\.:;]+)((?:(class="[^"]+")))/ig, '<h3')
.replace(/<h3>/ig, '<h3 class="h3">')
.replace(/<h4([\s\w"=\/\.:;]+)((?:(style="[^"]+")))/ig, '<h4')
.replace(/<h4([\s\w"=\/\.:;]+)((?:(class="[^"]+")))/ig, '<h4')
.replace(/<h4>/ig, '<h4 class="h4">')
.replace(/<h5([\s\w"=\/\.:;]+)((?:(style="[^"]+")))/ig, '<h5')
.replace(/<h5([\s\w"=\/\.:;]+)((?:(class="[^"]+")))/ig, '<h5')
.replace(/<h5>/ig, '<h5 class="h4">')
.replace(/<h6([\s\w"=\/\.:;]+)((?:(style="[^"]+")))/ig, '<h6')
.replace(/<h6([\s\w"=\/\.:;]+)((?:(class="[^"]+")))/ig, '<h6')
.replace(/<h6>/ig, '<h6 class="h6">')
.replace(/<code([\s\w"=\/\.:;]+)((?:(style="[^"]+")))/ig, '<code')
.replace(/<code([\s\w"=\/\.:;]+)((?:(class="[^"]+")))/ig, '<code')
.replace(/<code>/ig, '<code class="language-css">')
})
},
copy(url){
2026-07-29 14:35:13 +08:00
if (!url) {
return;
}
2025-08-14 15:04:24 +08:00
uni.setClipboardData({
data: url,
showToast: false,
success: function () {
}
});
},
2026-07-29 14:35:13 +08:00
isUpgradeSpec(item){
if (!item || item.purchased || !this.highestPurchasedSpec) {
return false;
}
return Number(item.sortOrder || 0) > Number(this.highestPurchasedSpec.sortOrder || 0);
},
getPayablePriceFen(item){
if (!item) {
return 0;
}
var targetPrice = Number(item.priceFen || 0);
if (!this.isUpgradeSpec(item)) {
return targetPrice;
}
var ownedPrice = Number(this.highestPurchasedSpec.priceFen || 0);
return Math.max(targetPrice - ownedPrice, 0);
},
selectDefaultSpec(){
var currentId = this.selectedResourceListId;
var currentExists = this.paySpecs.some(function(item) {
return String(item.id) === String(currentId);
});
if (currentExists) {
return;
}
var firstUnpurchased = this.paySpecs.find(function(item) {
return item.status == 1 && !item.purchased;
});
this.selectedResourceListId = firstUnpurchased
? firstUnpurchased.id
: (this.paySpecs.length ? this.paySpecs[0].id : null);
},
selectSpec(item){
if (this.paying) {
return;
}
this.selectedResourceListId = item.id;
},
handlePaidAction(){
if (!this.selectedSpec) {
return;
}
if (this.selectedSpec.purchased) {
uni.pageScrollTo({
selector: '#purchased-resources',
duration: 250
});
return;
}
this.payResource();
},
payResource(){
var that = this;
if (this.paying) {
return;
}
if (!this.userId) {
uni.showToast({
title: '请先登录后购买',
icon: 'none'
});
return;
}
2026-07-29 14:35:13 +08:00
if (!this.selectedSpec || this.selectedSpec.status != 1) {
uni.showToast({
title: '请选择可购买的版本',
icon: 'none'
});
return;
}
if (!this.selectedPayPriceFen || this.selectedPayPriceFen <= 0) {
uni.showToast({
title: '价格信息错误',
icon: 'none'
});
return;
}
if (typeof wx === 'undefined' || typeof wx.requestVirtualPayment !== 'function') {
uni.showToast({
title: '当前微信版本不支持虚拟支付,请升级微信',
icon: 'none'
});
return;
}
this.paying = true;
uni.login({
provider: 'weixin',
success: loginRes => {
createVirtualResourceOrder({
2026-07-29 14:35:13 +08:00
resourceListId: that.selectedSpec.id,
code: loginRes.code
}).then(response => {
var payParams = response.data;
wx.requestVirtualPayment({
signData: payParams.signData,
paySig: payParams.paySig,
signature: payParams.signature,
mode: payParams.mode,
success: () => {
that.confirmVirtualOrder(payParams.orderNo, 0);
},
fail: err => {
that.paying = false;
var cancelled = err && err.errCode === -2;
uni.showToast({
title: cancelled ? '已取消支付' : '支付未完成,请重试',
icon: 'none'
});
}
});
}).catch(() => {
that.paying = false;
});
},
fail: () => {
that.paying = false;
uni.showToast({
title: '获取微信登录凭证失败',
icon: 'none'
});
}
});
},
confirmVirtualOrder(orderNo, attempt){
var that = this;
var shouldSync = attempt === 1 || attempt === 6;
getVirtualResourceOrder(orderNo, shouldSync).then(response => {
var order = response.data;
if (order.unlocked) {
that.paying = false;
that.$refs.uToast.show({
type: 'success',
title: '',
message: '购买成功',
icon: false
});
2026-07-29 14:35:13 +08:00
resourceDownLoad({id: that.id}).then(function() {});
that.getInfo();
return;
}
if (order.status === 2 || order.status === 3) {
that.paying = false;
uni.showToast({
title: order.status === 2 ? '订单已退款' : '订单已关闭',
icon: 'none'
});
return;
}
if (attempt < 10) {
setTimeout(function() {
that.confirmVirtualOrder(orderNo, attempt + 1);
}, 1200);
} else {
that.paying = false;
uni.showToast({
title: '支付结果确认中,请稍后重新进入页面',
icon: 'none',
duration: 3000
});
}
}).catch(() => {
if (attempt < 10) {
setTimeout(function() {
that.confirmVirtualOrder(orderNo, attempt + 1);
}, 1200);
} else {
that.paying = false;
}
});
},
formatPrice(priceFen){
var value = Number(priceFen || 0) / 100;
return value.toFixed(2);
},
2025-08-14 15:04:24 +08:00
back(val) {
const pages = getCurrentPages();
if (pages.length > 1) {
uni.navigateBack()
} else {
uni.switchTab({
url: '/pages/index'
});
}
}
}
}
</script>
<style>
page {
background-color: #ffffff;
min-height: 100%;
}
.password{
font-size: 24rpx;
color: #4a4a4a;
margin-left: 40rpx;
}
.data-view {
margin: 0upx 20upx;
font-size: 34upx;
color: #333232;
line-height: 60upx;
word-wrap: break-word;
}
.jiesao{
padding: 20rpx 30rpx;
}
.resource-ad{
2026-07-29 14:35:13 +08:00
height: 88rpx;
width: 100%;
margin: 0;
2025-08-14 15:04:24 +08:00
border-radius: 100rpx;
background: #7a60fd;
2026-07-29 14:35:13 +08:00
line-height: 88rpx;
2025-08-14 15:04:24 +08:00
text-align: center;
2026-07-29 14:35:13 +08:00
font-size: 34rpx;
2025-08-14 15:04:24 +08:00
color: white;
2026-07-29 14:35:13 +08:00
box-shadow: 0 8rpx 22rpx rgba(122, 96, 253, 0.22);
}
.bottom-action-bar{
position: fixed;
left: 0;
right: 0;
bottom: 0;
z-index: 99;
box-sizing: border-box;
width: 100%;
padding: 18rpx 5% calc(18rpx + constant(safe-area-inset-bottom));
padding: 18rpx 5% calc(18rpx + env(safe-area-inset-bottom));
background: rgba(255, 255, 255, 0.98);
border-top: 1rpx solid #eeeeee;
box-shadow: 0 -10rpx 30rpx rgba(45, 45, 45, 0.1);
}
.action-summary{
height: 54rpx;
display: flex;
align-items: center;
justify-content: space-between;
padding: 0 12rpx 12rpx;
}
.action-summary-name{
display: flex;
align-items: center;
min-width: 0;
}
.action-summary-label{
flex-shrink: 0;
margin-right: 14rpx;
padding: 3rpx 12rpx;
border-radius: 999rpx;
font-size: 21rpx;
color: #6d52f5;
background: #f0ecff;
}
.action-summary-value{
max-width: 420rpx;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
font-size: 27rpx;
color: #333333;
}
.action-summary-price{
flex-shrink: 0;
font-size: 31rpx;
font-weight: 600;
color: #e54d42;
}
.action-placeholder{
width: 100%;
height: calc(142rpx + constant(safe-area-inset-bottom));
height: calc(142rpx + env(safe-area-inset-bottom));
}
.action-placeholder-paid{
height: calc(208rpx + constant(safe-area-inset-bottom));
height: calc(208rpx + env(safe-area-inset-bottom));
}
.resource-owned{
background: #39b54a;
}
.spec-section{
margin-bottom: 45rpx;
}
.spec-list{
margin: 24rpx 10rpx 0;
}
.spec-item{
min-height: 92rpx;
margin-bottom: 18rpx;
padding: 0 28rpx;
border: 2rpx solid #e5e5e5;
border-radius: 18rpx;
display: flex;
align-items: center;
justify-content: space-between;
background: #ffffff;
}
.spec-item-selected{
border-color: #7a60fd;
background: #f5f2ff;
box-shadow: 0 8rpx 20rpx rgba(122, 96, 253, 0.12);
}
.spec-name{
font-size: 29rpx;
font-weight: 500;
color: #2b2b2b;
}
.spec-price{
font-size: 31rpx;
font-weight: 600;
color: #e54d42;
}
.upgrade-price-label{
margin-right: 6rpx;
font-size: 22rpx;
font-weight: 500;
color: #7a60fd;
}
.purchased-tag,
.disabled-tag{
display: inline-block;
margin-left: 16rpx;
padding: 4rpx 12rpx;
border-radius: 999rpx;
font-size: 21rpx;
font-weight: 400;
}
.purchased-tag{
color: #248b3e;
background: #e8f7ec;
}
.disabled-tag{
color: #8799a3;
background: #f1f1f1;
}
.empty-spec{
margin: 24rpx 10rpx;
padding: 28rpx;
text-align: center;
border-radius: 18rpx;
color: #8799a3;
background: #f7f7f7;
}
.purchased-file{
padding: 24rpx;
border-radius: 20rpx;
background: #fafafa;
2025-08-14 15:04:24 +08:00
}
.file-list{
margin: 30rpx;
}
.file-url-box{
background: #dcdcdc;
height: 80rpx;
width: 100%;
border-radius: 20rpx;
margin-top: 20rpx;
line-height: 80rpx;
}
.file-url{
float: left;
margin-left: 40rpx;
white-space: nowrap; /* 防止文本换行 */
overflow: hidden; /* 隐藏超出容器的内容 */
text-overflow: ellipsis; /* 当文本溢出时显示省略号 */
/* 你还需要设置容器的宽度,以便知道何时文本应该溢出 */
width: 450rpx; /* 或者其他你需要的宽度 */
}
.file-copy{
float: right;
margin-right: 40rpx;
}
.shuoming{
margin: 25rpx 25rpx 30rpx 25rpx;
font-size: 25rpx;
}
.shuoming2{
margin: 25rpx 35rpx 30rpx 35rpx;
font-size: 26rpx;
background-color: #fff9d7;
height: 85rpx;
line-height: 85rpx;
text-align: center;
border-radius: 20rpx;
color: orange;
}
.resource-list{
margin: 40rpx 20rpx;
}
.resource-font {
font-weight: 600;
font-size: 35rpx;
margin-left: 20rpx;
}
.resource-view {
display: flex;
align-items: center;
justify-content: flex-start;
}
.resource-img {
height: 60rpx;
width: 60rpx;
}
.resource-font3 {
font-weight: 400;
font-size: 25rpx;
margin-left: 15rpx;
}
.resource-img3 {
height: 30rpx;
width: 30rpx;
}
.resource-font2 {
font-weight: 600;
font-size: 30rpx;
margin-left: 20rpx;
}
.resource-img2 {
height: 45rpx;
width: 45rpx;
}
.resource-box{
min-height: 350rpx;
width: 100%;
background-color: white;
border-radius: 50rpx;
margin-top: -60rpx;
position: relative;
z-index: 2;
padding: 50rpx 30rpx;
}
.top-img {
height: 500upx;
width: 100%;
position: relative;
z-index: 1;
}
.ui-img {
height: 100%;
width: 100%;
position: relative;
}
.backbut {
position: absolute;
left: 20rpx;
top: 100rpx;
font-size: 50rpx;
}
</style>