ios 首页 任务 我的 修改

This commit is contained in:
duan
2024-12-30 22:30:10 +08:00
parent 9a52daeffe
commit c978fab954
33 changed files with 3400 additions and 696 deletions

View File

@@ -0,0 +1,127 @@
<template>
<view>
<view class="df" style=" justify-content: space-around;flex-wrap: wrap; margin-top: 10rpx;">
<view style="border-radius:21rpx 21rpx 21rpx 21rpx;width: 33%;text-align: center;margin-top: 20rpx;padding:0 26rpx;"
class="liststyle" v-for="item in $props.list" :key="item">
<image :src="item.titleImg" style="width: 188rpx;height: 247rpx;border-radius:21rpx 21rpx 21rpx 21rpx"
mode=""></image>
<view style="font-weight: 400;font-size: 25rpx;color: #333333;text-align: left;">
{{item.title.slice(0,6)}}
</view>
<view style="font-weight: 400;font-size: 21rpx;color: #999999;text-align: left;">
{{item.courseLabel}}
</view>
</view>
</view>
</view>
</template>
<script>
export default {
props: {
list: {
type: Array,
default: []
},
},
data() {
return {
}
},
methods: {
}
}
</script>
<style scoped lang="scss">
.zuijin {
width: 100%;
margin-top: 26rpx;
.GpkmladwbU {
width: 700rpx;
height: 100%;
flex-wrap: wrap;
}
.kjFVivdwbz {
width: calc((700rpx - 40rpx) / 3);
height: 100%;
margin-bottom: 30rpx;
margin-right: calc(40rpx / 2);
}
.kjFVivdwbz:nth-of-type(3n) {
margin-right: 0;
}
.MXdwbIHrMo {
width: 100%;
// height: 204rpx;
height: 204rpx;
border-radius: 24rpx 24rpx 0 0;
position: relative;
image {
width: 100%;
height: 100%;
border-radius: 24rpx 24rpx 0 0;
}
.kpdwbbDLKT {
position: absolute;
bottom: 10rpx;
right: 0;
max-width: 80%;
border-radius: 10rpx;
background-color: rgba(51, 51, 51, 0.7);
color: #FFFFFF;
font-size: 22rpx;
padding: 10rpx;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
}
.gSSSCWdwbD {
width: 100%;
height: 100rpx;
background-color: #ffffff;
border-radius: 0 0 24rpx 24rpx;
align-content: center;
}
.dwbkFoLNxI {
width: 100%;
padding: 0 20rpx;
color: #333333;
font-size: 30rpx;
font-weight: bold;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.kemrdwbYSM {
width: 100%;
padding: 0 20rpx;
color: #999999;
font-size: 22rpx;
}
}
.liststyle:last-child {
margin-right: auto;
margin-left: 6rpx;
}
.df {
display: flex;
align-items: center;
}
</style>

View File

@@ -445,7 +445,7 @@
this.videoInfo = []
}
httpsRequest.getT("app/common/type/919", {}).then(res => {
httpsRequest.getT("/app/common/type/919", {}).then(res => {
if (res.code == 0) {
const sysInfo = uni.getSystemInfoSync();
let isIos = sysInfo.platform == 'ios'

159
pages/index/index2.vue Normal file
View File

@@ -0,0 +1,159 @@
<template>
<view>
<view style="height: 555rpx;position: relative;">
<image src="../../static/indexbh.png" style="width: 100%;height: 555rpx;position: absolute;" mode="">
</image>
<view style="display: flex;align-items: center;justify-content: space-between; padding: 88rpx 25rpx;">
<image src="../../static/logo.png" style="width: 187rpx;height:50rpx;" mode=""></image>
<view style="z-index: 50;width: 236rpx;line-height: 43rpx;background: rgba(255,255,255,0.29);border-radius: 7rpx 7rpx 7rpx 7rpx;
font-weight: 400;font-size: 21rpx;color: rgba(255,255,255,0.85);display: flex;align-items: center;"
@tap="moreVideo">
<uni-icons type="search" size="16" style="color: rgba(255,255,255,0.85);"></uni-icons>
点击搜索更多好剧
</view>
</view>
<template v-if="noticeList.length>0">
<view class="gongao">
<view class="gongaoicon">
公告
</view>
<swiper :autoplay="true" :vertical="true" :interval="4000" :circular="true" :indicator-dots="false"
class="swiperstyle">
<swiper-item @tap='goMsg(item.url)' v-for="(item, index) in noticeList">
<view style="height: 80rpx;line-height: 80rpx;">{{item.title}}</view>
</swiper-item>
</swiper>
</view>
</template>
</view>
<view style="display: flex;align-items: center;justify-content: space-between;padding:0 20rpx;">
<view style="background-color: #f0f0f0;margin-left:20rpx;padding:6rpx 20rpx" @tap="getrecomVideo('')">
最新
</view>
<view style="background-color: #f0f0f0;margin-left:20rpx;padding:6rpx 20rpx" @tap="getrecomVideo('1')">
排行
</view>
<view style="background-color: #f0f0f0;margin-left:20rpx;padding:6rpx 20rpx" @tap="getrecomVideo('2')">
最热
</view>
<view style="background-color: #f0f0f0;margin-left:20rpx;padding:6rpx 20rpx" @tap="getrecomVideo('1')">
剧情
</view>
<view style="background-color: #f0f0f0;margin-left:20rpx;padding:6rpx 20rpx" @tap="getrecomVideo('2')">
飙升
</view>
</view>
<view class="">
<contentlist :list='list'></contentlist>
</view>
</view>
</template>
<script>
import contentlist from './components/contentlist.vue'
export default {
components: {
contentlist
},
data() {
return {
noticeList: [], //公告列表
list: [],
page: 1
}
},
onShow() {
this.getMsg()
this.getrecomVideo()
},
onReachBottom() {
++this.page
this.getrecomVideo()
},
methods: {
moreVideo() {
uni.navigateTo({
url: '/pages/index/course/courseList?title=最新热播'
})
},
// 列表
//获取推荐视频
getrecomVideo(sort) {
if (sort) {
this.page = 1
}
let data = {
page: this.page,
limit: 12,
sort: sort,
classifyId: ''
}
this.$Request.getT('/app/course/selectCourse', data).then(res => {
if (res.code == 0) {
if (this.page == 1) {
this.list = res.data.list
} else {
this.list = [...this.list, ...res.data.list]
}
}
})
},
// 公告
getMsg() {
let data = {
page: 1,
limit: 5,
state: 1
}
this.$u.api.msg(data).then(res => {
if (res.code == 0) {
this.notice = res.data.list
res.data.list.forEach(res => {
this.noticeList.push(res)
})
} else {
uni.showToast({
title: res.msg,
duration: 1000,
icon: 'none'
});
}
})
},
}
}
</script>
<style scoped lang="scss">
.gongao {
position: absolute;
bottom: 75rpx;
left: 70rpx;
border-radius: 21rpx 21rpx 21rpx 21rpx;
width: 611rpx;
height: 78rpx;
background-color: rgba(255, 255, 255, .65);
display: flex;
align-items: center;
padding: 12rpx;
.gongaoicon {
color: #ffffff;
width: 98rpx;
height: 50rpx;
line-height: 50rpx;
text-align: center;
background-image: url('../../static/gonggaobg.png');
background-size: 98rpx 50rpx;
}
.swiperstyle {
height: 78rpx;
width: 80%;
}
}
</style>

File diff suppressed because it is too large Load Diff

View File

@@ -1,9 +1,22 @@
<template>
<view style="padding-bottom: 40rpx;">
<u-navbar :background="background" :is-back="isBack" :title="title" :border-bottom="false">
</u-navbar>
<!-- <u-navbar :background="background" :is-back="isBack" :title="title" :border-bottom="false">
</u-navbar> -->
<!-- 登录信息 -->
<view class="info flex align-center justify-center">
<view class="info " style="padding: 20rpx;">
<view
style="background-color: #f5f1f1;padding: 20rpx; display: flex;align-items: center;justify-content: space-between;"
class="">
<image src="../../static/logo.png" style="width: 170rpx;height: 51rpx;z-index: 999;" mode=""></image>
<!-- <view class="">
<image src="../../static/dwbimgs/one.png" style="width: 46rpx;height: 46rpx;z-index: 999;" mode="">
</image>
<image src="../../static/dwbimgs/two.png" style="width: 46rpx;height: 46rpx;z-index: 999;" mode="">
</image>
<image src="../../static/dwbimgs/three.png" style="width: 46rpx;height: 46rpx;z-index: 999;"
mode=""></image>
</view> -->
</view>
<view class="info-box">
<view @click="token?goNav('/pages/me/userinfo'):goNav('/pages/login/login')"
class="info-box-c flex align-center justify-between">
@@ -15,9 +28,9 @@
<view class="info-box-c-l-name-t">
{{userName?userName:'未登录'}}
</view>
<view class="info-box-c-l-name-b" v-if="invitationCode">
<!-- <view class="info-box-c-l-name-b" v-if="invitationCode">
ID:{{invitationCode}}
</view>
</view> -->
</view>
</view>
<view class="info-box-c-r">
@@ -28,22 +41,22 @@
</view>
<!-- 统计 -->
<view class="statistics flex align-center justify-center">
<view class="statistics-box flex align-center justify-between">
<view class="statistics-box flex align-center justify-between" style="margin: 0 100rpx;">
<view class="statistics-box-item" @click="goNav('/me/jilu/duanju-love')">
<view class="statistics-box-item-top">
{{myLoveNum}}
</view>
<view class="statistics-box-item-btn">
我的喜欢
</view>
<view class="statistics-box-item-top">
{{myLoveNum}}
</view>
</view>
<view class="statistics-box-item" @click="goNav('/me/jilu/duanju-zhjuiju-jilu')">
<view class="statistics-box-item-top">
{{myZhui}}
</view>
<view class="statistics-box-item-btn">
我的追剧
</view>
<view class="statistics-box-item-top">
{{myZhui}}
</view>
</view>
<!-- <view class="statistics-box-item" @click="goNav('/me/jifen/duanju-jifen')">
<view class="statistics-box-item-top">
@@ -53,13 +66,14 @@
我的积分
</view>
</view> -->
<view v-if="isShowMoneyPay" class="statistics-box-item" @click="goNav('/me/yaoqing/ymg-yaoqing-tixian')">
<view class="statistics-box-item-top">
{{userInfo.amount || '0.00'}}
</view>
<view v-if="isShowMoneyPay" class="statistics-box-item"
@click="goNav('/me/yaoqing/ymg-yaoqing-tixian')">
<view class="statistics-box-item-btn">
我的红包
</view>
<view class="statistics-box-item-top">
{{userInfo.amount || '0.00'}}
</view>
</view>
</view>
</view>
@@ -85,16 +99,47 @@
</view>
</view> -->
<!-- 钱包 -->
<view class="money flex align-center justify-center" v-if="isWxIosPay == true">
<view class="money" v-if="isWxIosPay == true" style="position: relative;">
<!-- <view
style="position: relative;background-color: #f2b5b5;width: 700rpx;height: 74rpx;padding:20rpx;border-radius: 14rpx 14rpx 0rpx 0rpx;position: absolute;left: 0;top: 0;display: flex;align-items: center;justify-content: space-between;">
<view class="df">
<image src="../../static/dwbimgs/money.png" style="width: 47rpx;height: 47rpx;margin-right: 28rpx;"
mode=""></image>
<view style="font-weight: bold;font-size: 36rpx;color: #FFFFFF;">
{{formatNumber(moneyNum)}}
</view>
</view>
<view
style="font-weight: bold;font-size: 25rpx;color: #977641;width: 110rpx;text-align:center;line-height: 50rpx;background: linear-gradient( 90deg, #FEE7BC 0%, #FDCC89 100%);border-radius: 46rpx 46rpx 46rpx 46rpx;">
提现
</view>
<view style="position: absolute;background-color: #fff;width: 40rpx;height: 40rpx;transform: rotate(45deg);bottom: -10rpx;left: 48%;background-color: #f2b5b5;">
</view>
</view> -->
<view style="margin-top: 0rpx;">观看历史</view>
<view class="df" style=" justify-content: space-between;margin-top: 28rpx;">
<view style="border-radius:21rpx 21rpx 21rpx 21rpx" v-for="item in list" :key="item">
<image :src="item.titleImg"
style="width: 188rpx;height: 247rpx;border-radius:21rpx 21rpx 21rpx 21rpx" mode=""></image>
<view style="font-weight: 400;font-size: 25rpx;color: #333333;">
{{item.title}}
</view>
<view style="font-weight: 400;font-size: 21rpx;color: #999999;">
看到{{item.courseDetailsName}}
</view>
</view>
</view>
</view>
<!-- <view class="money flex align-center justify-center" v-if="isWxIosPay == true">
<view class="money-box flex align-center justify-between">
<view class="">
<view class="money-box-title flex align-center">
<view class="money-box-title-l">
金币余额
</view>
<!-- <view @click="isShoMoney = !isShoMoney" class="money-box-title-r" style="margin-left: 12rpx;">
<u-icon :name="isShoMoney?'eye':'eye-off'" color="#5A4A32" size="40"></u-icon>
</view> -->
</view>
<view class="money-box-price">
<block v-if="isShoMoney">
@@ -108,11 +153,8 @@
<view class="money-box-btn" @click="goNav('/me/yaoqing/redPack-mingxi?moneyType=2&viewType=2')">
金币明细
</view>
<!-- <view class="money-box-btn" @click="goNav('/me/wallet/wallet')">
立即充值
</view> -->
</view>
</view>
</view> -->
<!-- 常用工具 -->
<view class="tool flex align-center justify-center">
<view class="tool-box">
@@ -184,7 +226,8 @@
观看历史
</view>
</view>
<view v-if="rate>0 && isShowMoneyPay" class="tool-box-content-item flex align-center justify-center flex-wrap"
<view v-if="rate>0 && isShowMoneyPay"
class="tool-box-content-item flex align-center justify-center flex-wrap"
@click="goNav('/me/yaoqing/ymf-my-team')">
<view class="tool-box-content-item-img">
<image src="../../static/images/me/vtd.png" mode=""></image>
@@ -251,8 +294,8 @@
</u-popup>
<!-- 抖音im客服 -->
<ttMsg />
<other-xuanfu></other-xuanfu>
</view>
</template>
@@ -261,11 +304,12 @@
import ttMsg from '../../components/ttMsg/ttMsg.vue'
import httpsRequest from '../../common/httpRequest.js'
import otherXuanfu from '@/components/other-xuafu.vue'
export default {
components: {
ttMsg,otherXuanfu
ttMsg,
otherXuanfu
},
data() {
return {
@@ -283,6 +327,7 @@
}],
isLogin: false,
userName: '未登录',
list: [],
isVIP: false,
invitationCode: '',
token: '',
@@ -295,7 +340,7 @@
showCard: false,
numCount: 0,
rate: 0,
twoRate:0,
twoRate: 0,
kmPaySel: '否',
isWxIosPay: true, //微信下是否显示支付功能
userInfo: {},
@@ -304,18 +349,18 @@
},
onLoad() {
this.getBannerList()
this.zxczxczxczsw(1212,5)
this.zzzzzzzzzzzzzzzzs(1212.5)
this.zxcee(1212,5)
this.aaaaccx(1212,5)
this.wwrqx(1212,5)
this.zxczxczxczsw(1212, 5)
this.zzzzzzzzzzzzzzzzs(1212.5)
this.zxcee(1212, 5)
this.aaaaccx(1212, 5)
this.wwrqx(1212, 5)
},
onShow() {
this.ymfgetDataList()
const systemInfo = uni.getSystemInfoSync();
const isIOS = /iOS/.test(systemInfo.platform);
if ( !isIOS ) {
if (!isIOS) {
this.isBack = true
}
this.isWxIosPay = uni.getStorageSync('isWxIosPay')
@@ -335,8 +380,8 @@
this.userName = res.data.userName
this.avatar = res.data.avatar
this.invitationCode = res.data.invitationCode
this.rate = res.data.rate||0
this.twoRate = res.data.twoRate||0
this.rate = res.data.rate || 0
this.twoRate = res.data.twoRate || 0
}
})
@@ -374,7 +419,7 @@
}
this.avatar = uni.getStorageSync('avatar') ? uni.getStorageSync('avatar') : '../../static/images/logo.png'
httpsRequest.getT("app/common/type/919", {}).then(res => {
httpsRequest.getT("/app/common/type/919", {}).then(res => {
console.log(res);
if (res.code === 0) {
const sysInfo = uni.getSystemInfoSync();
@@ -464,6 +509,26 @@
}
})
},
//获取观看记录
ymfgetDataList() {
let data = {
page: 1,
limit: 3,
classify: 3
}
this.$Request.getT('/app/courseCollect/selectByUserId', data).then(res => {
if (res.code === 0) {
console.log(res,'debug')
let arr = []
res.data.records.forEach((ele, index) => {
if (index < 3) {
arr.push(ele)
}
})
this.list = arr
}
})
},
/**
* 获取积分
*/
@@ -553,7 +618,7 @@
}
r1 = Number(arg1.toString().replace(".", ""));
r2 = Number(arg2.toString().replace(".", ""));
},
/**
* 保留小数n位不进行四舍五入
@@ -576,7 +641,7 @@
return parseFloat(num).toFixed(decimal);
}
},
//乘法函数,用来得到精确的乘法结果
//说明javascript的乘法结果会有误差在两个浮点数相乘的时候会比较明显。这个函数返回较为精确的乘法结果。
//调用mul(arg1,arg2)
@@ -689,7 +754,7 @@
// #endif
}
},
goNav(e,type) {
goNav(e, type) {
console.log(e)
let token = uni.getStorageSync('token')
if (token) {
@@ -702,7 +767,7 @@
url: e
})
}
} else {
uni.navigateTo({
url: "/pages/login/login"
@@ -881,7 +946,7 @@
.statistics-box-item-btn {
width: 100%;
text-align: center;
color: #999999;
color: #333;
font-size: 26rpx;
// margin-top: 20rpx
}
@@ -933,41 +998,45 @@
}
.money {
width: 100%;
height: auto;
margin-top: 20rpx;
.money-box {
width: 686rpx;
height: 100%;
border-radius: 24rpx;
background: #ffffff;
padding: 30rpx;
}
.money-box-btn {
background: linear-gradient(90deg, #FF7581 0%, #F8A5AF 100%);
border-radius: 44rpx;
padding: 18rpx 30rpx;
font-size: 24rpx;
color: #ffffff;
font-weight: bold;
}
.money-box-title-l {
color: #333333;
font-size: 28rpx;
font-weight: normal;
}
.money-box-price {
color: #333333;
font-size: 48rpx;
font-weight: 800;
margin-top: 20rpx;
box-sizing: border-box;
background-color: #fff;
margin: 30rpx;
padding: 55rpx 24rpx;
}
// .money-box {
// width: 686rpx;
// height: 100%;
// border-radius: 24rpx;
// background: #ffffff;
// padding: 30rpx;
// }
// .money-box-btn {
// background: linear-gradient(90deg, #FF7581 0%, #F8A5AF 100%);
// border-radius: 44rpx;
// padding: 18rpx 30rpx;
// font-size: 24rpx;
// color: #ffffff;
// font-weight: bold;
// }
// .money-box-title-l {
// color: #333333;
// font-size: 28rpx;
// font-weight: normal;
// }
// .money-box-price {
// color: #333333;
// font-size: 48rpx;
// font-weight: 800;
// margin-top: 20rpx;
// }
}
@@ -1015,4 +1084,9 @@
font-size: 24rpx;
}
}
.df {
display: flex;
align-items: center;
}
</style>

View File

@@ -17,15 +17,14 @@
<image class="task_icon2 u-relative" src="../../static/images/me/task_icon2.png"></image>
</view>
<view class="content signIn margin-lr padding bg-white u-relative" style="margin-bottom: 32rpx;">
<view class="title flex justify-between">
<view>已连续签到 <text class="num">{{signDays}}</text> </view>
<!-- <view class="dk flex">
<text style="margin-right: 20rpx;">打卡提醒</text>
<u-switch v-model="checked" size="35" active-color="#EA9EA8 "></u-switch>
</view> -->
<view class="content signIn margin-lr bg-white u-relative" style="margin-bottom: 32rpx;">
<view class="">
<image src="../../static/dwbimgs/renwubg.png"
style="width: 100%;height: 78rpx;position: absolute;left: 0;top: 0;z-index:1" mode=""></image>
<view style="z-index: 9999;position: absolute;text-align: center;width: 98%;">已连续签到 <text class="num"
style="color: #EC6F48;margin: 0 10rpx;">{{signDays}}</text> </view>
</view>
<view class="signInList flex justify-between">
<!-- <view class="signInList flex justify-between">
<text class="line"></text>
<view class="signIn-Item"
:class="{active: item.showText == '待签到'||item.showText == '未签到'||item.showText == '已签到'}"
@@ -39,9 +38,24 @@
<view class="radius"></view>
<view class="_label">{{item.showText}}</view>
</view>
</view> -->
<view style="margin-top: 100rpx; display: flex;align-items: center; justify-content: space-between;">
<view class="" v-for="item in signInList" :key="item" style="position: relative;"
:style="filterDate(item)=='已签到'?'color:#EFA765':'color:#999'">
{{filterDate(item)}}
<view
style="margin-top: 20rpx;;width: 80rpx;height: 94rpx;background: linear-gradient( 180deg, #FFF7E3 0%, #FFFFFF 100%);border-radius: 14rpx 14rpx 0rpx 0rpx;"
:style="filterDate(item)=='已签到'?'color:#999':'color:#EFA765'">
{{item.signDay.substr(5,8)}}
</view>
<image v-if="item.status==0" src="../../static/dwbimgs/xing (1).png"
style="width: 52rpx;height: 48rpx;position: absolute;top: 100rpx;left: 14rpx;" mode=""></image>
<image v-else src="../../static/dwbimgs/xing (2).png"
style="width: 52rpx;height: 48rpx;position: absolute;top: 100rpx;left: 14rpx;" mode="">
</image>
</view>
</view>
<view class="tishi">连续签到7天即可获得7元奖励</view>
<!-- <view class="tishi">连续签到7天即可获得7元奖励</view> -->
<!-- <view class="signInBtn" @click="goNav({jumpType: 0, id:15, buttonTitle: '去领取'})">
<view>{{signInBtn}}</view>
@@ -86,6 +100,10 @@
</template>
<script>
import {
data
} from '../../tuniao-ui/libs/mixin/mixin'
export default {
data() {
@@ -97,28 +115,7 @@
list: [],
checked: false,
signDays: 0,
signInList: [{
name: '第一天'
},
{
name: '第二天'
},
{
name: '第三天'
},
{
name: '第四天'
},
{
name: '第五天'
},
{
name: '第六天'
},
{
name: '第七天'
},
],
signInList: [],
signInBtn: '点击签到',
isShowMoneyPay: true,
}
@@ -131,7 +128,7 @@
onShow() {
this.getTaskdata()
this.getsignIn()
this.$Request.getT("app/common/type/919", {}).then(res => {
this.$Request.getT("/app/common/type/919", {}).then(res => {
if (res.code == 0) {
const sysInfo = uni.getSystemInfoSync();
let isIos = sysInfo.platform == 'ios'
@@ -144,7 +141,24 @@
//说明javascript的乘法结果会有误差在两个浮点数相乘的时候会比较明显。这个函数返回较为精确的乘法结果。
//调用mul(arg1,arg2)
//返回值arg1乘以arg2的精确结果
filterDate(d) {
// 获取当前时间
// 循环比较,返回字段
if (d.status == 1) {
return '已签到'
} else {
return '待签到'
// let time1 = d.signDay
// let date1 = new Date(time1);
// let date2 = new Date().getTime() + 8 * 60 * 60;
// if (date1.getTime() < date2) {
// return '未签到'
// } else if (date1.getTime() > date2) {
// return '待签到'
// }
}
},
mul(arg1, arg2) {
var m = 0,
s1 = arg1.toString(),
@@ -217,7 +231,7 @@
}
r1 = Number(arg1.toString().replace(".", ""));
r2 = Number(arg2.toString().replace(".", ""));
},
/**
* 保留小数n位不进行四舍五入
@@ -249,19 +263,19 @@
getsignIn() {
this.$Request.getT('app/userSignRecord/getUserSignData', {}).then(res => {
this.$Request.getT('/app/userSignRecord/getUserSignData', {}).then(res => {
if (res.code == 0) {
this.signInList = res.data.recordList
this.signDays = res.data.signDays
this.signInList.map((item, index) => {
if (item.showText == '待签到' && index > 0) {
this.signInBtn = this.signInList[index - 1].status == 0 ? '重新签到' : '点击签到'
}
let someDate = new Date(item.signDay); // 假设这是需要判断的日期
if (item.signDate && this.isToday(someDate)) {
this.signInBtn = '已签到'
}
})
// this.signInList.map((item, index) => {
// if (item.showText == '待签到' && index > 0) {
// this.signInBtn = this.signInList[index - 1].status == 0 ? '重新签到' : '点击签到'
// }
// let someDate = new Date(item.signDay); // 假设这是需要判断的日期
// if (item.signDate && this.isToday(someDate)) {
// this.signInBtn = '已签到'
// }
// })
} else {
// uni.showToast({
// title: res.msg,
@@ -339,7 +353,7 @@
let data = {
id: id
}
this.$Request.getT('app/taskCenter/taskReceive', data).then(res => {
this.$Request.getT('/app/taskCenter/taskReceive', data).then(res => {
if (res.code == 0) {
uni.showToast({
title: id == 15 ? '签到成功' : '领取成功',
@@ -362,7 +376,7 @@
*/
getTaskdata() {
this.$Request.getT('app/taskCenter/selectTaskCenter', {}).then(res => {
this.$Request.getT('/app/taskCenter/selectTaskCenter', {}).then(res => {
if (res.code == 0) {
this.list = res.data
}
@@ -596,6 +610,7 @@
font-weight: 400;
font-size: 20rpx;
color: #7F7F7F;
margin-top: 20rpx;
}
.signInBtn {