Files
xl-mobile/src/components/TaskCard.vue

123 lines
3.6 KiB
Vue
Raw Normal View History

2025-03-27 15:38:21 +08:00
<script setup>
import dy from "../static/images/抖音.png";
import qrw from "../static/icons/qrw.png";
2025-03-28 09:37:10 +08:00
import XCountdown from "./XCountdown.vue";
2025-03-28 15:34:00 +08:00
import {toPage} from "../utils/uils.js";
2025-05-19 19:03:53 +08:00
import FBENUM from "../enum/FBENUM.js";
import PlatformENUM from "../enum/PlatformENUM.js";
import dayjs from "dayjs";
const {data} = defineProps({
data: {
type: Object,
default: {}
}
});
2025-03-27 15:38:21 +08:00
</script>
<template>
2025-06-16 20:54:42 +08:00
<view @click="toPage(`/pages/taskDetails/index?id=${data.id}&task_children_id=${data.task_children_id}`)"
2025-05-19 19:03:53 +08:00
class="rounded-[8rpx] bg-[#fff] !p-[24rpx] overflow-hidden task-card">
2025-03-27 16:35:46 +08:00
<view class="!pb-[20rpx] !flex justify-between" style="border-bottom: 1px solid #E5E6EB">
<view style="font-size: 28rpx">
2025-05-19 19:03:53 +08:00
任务编号{{ data.uid }}
2025-03-27 16:35:46 +08:00
</view>
2025-05-19 19:03:53 +08:00
<view v-if="data.back_status === 1" style="font-size: 24rpx">
<Text class="text-[#165DFF]">{{ dayjs(data.time).format('MM-DD-HH:mm') }}</Text>
后可开始回填
2025-03-27 16:35:46 +08:00
</view>
2025-05-19 19:03:53 +08:00
<x-countdown v-else :time="dayjs(data.time)">
2025-03-28 09:37:10 +08:00
<view style="font-size: 24rpx;font-weight: 400;" class="text-[rgb(78,89,105)]">审核倒计时:</view>
</x-countdown>
2025-03-27 16:35:46 +08:00
</view>
<view class="!flex gap-[26rpx] !pt-[20rpx]">
2025-05-19 19:03:53 +08:00
<image class="!size-[88rpx] rounded-[50%] overflow-hidden" mode="aspectFill"
:src="PlatformENUM[data.platform_id]"></image>
2025-03-27 15:38:21 +08:00
<view class="!h-[88rpx] !flex flex-col justify-between">
2025-05-19 19:03:53 +08:00
<view class="title">{{ data.goods_name }}</view>
2025-03-27 15:38:21 +08:00
<view class="!flex gap-[8rpx]">
2025-05-19 19:03:53 +08:00
<view class="tag">{{ data.platform }}</view>
<view class="tag">{{ FBENUM[data.fb_num - 1] }}连发</view>
2025-03-27 15:38:21 +08:00
</view>
</view>
2025-03-27 16:35:46 +08:00
<view class="!h-[88rpx] !ml-auto !flex items-center gap-[6rpx]">
2025-05-19 19:03:53 +08:00
<view class="price-info">{{ data.status_text }}</view>
2025-03-27 15:38:21 +08:00
<view class="price">
<text class="unit">¥</text>
2025-05-19 19:03:53 +08:00
{{ data.coin.toFixed(2) }}
2025-03-27 15:38:21 +08:00
</view>
</view>
</view>
<view class="!mt-[34rpx] !px-[20rpx] !py-[10rpx] bg-[#F2F3F5] info relative">
2025-03-27 16:35:46 +08:00
<view class="!flex gap-[8rpx] justify-between">
<view>领取账号:</view>
2025-05-19 19:03:53 +08:00
<view>{{ data.account }}</view>
2025-03-27 16:35:46 +08:00
</view>
<view class="!flex gap-[8rpx] justify-between">
<view>领取时间:</view>
2025-05-19 19:03:53 +08:00
<view>{{ data.accept_time }}</view>
2025-03-27 15:38:21 +08:00
</view>
</view>
</view>
</template>
<style lang="scss" scoped>
2025-03-27 16:35:46 +08:00
.task-card {
box-shadow: 0px 2px 5px 0px rgba(0, 0, 0, 0.1);
2025-03-27 15:38:21 +08:00
}
.info {
2025-03-27 16:35:46 +08:00
color: #000;
font-size: 24rpx;
font-weight: 300;
2025-03-27 15:38:21 +08:00
letter-spacing: 0;
text-align: left;
}
.title {
color: rgb(29, 33, 41);
font-size: 14px;
font-weight: 500;
line-height: 140%;
letter-spacing: 0;
text-align: left;
}
.price-info {
/* 12/Regular */
color: rgb(255, 87, 34);
font-size: 12px;
font-weight: 400;
line-height: 140%;
letter-spacing: 0;
text-align: right;
}
.price {
color: rgb(29, 33, 41);
font-size: 20px;
font-weight: 700;
line-height: 140%;
letter-spacing: 0;
text-align: right;
.unit {
font-size: 22rpx;
}
}
.tag {
color: rgb(22, 93, 255);
font-size: 10px;
font-weight: 400;
line-height: 140%;
letter-spacing: 0;
text-align: center;
border-radius: 4rpx;
background: rgb(232, 243, 255);
padding: 3rpx 8rpx;
}
</style>