Commit 5a05cab1 by lei

1

parent 265c5ac1
...@@ -20,6 +20,10 @@ ...@@ -20,6 +20,10 @@
</div> </div>
</template> </template>
<script setup lang="tsx"> <script setup lang="tsx">
import {
RadioGroup as TRadioGroup,
RadioButton as TRadioButton,
} from "tdesign-vue-next";
const props = defineProps({ const props = defineProps({
current: [String, Number], current: [String, Number],
type: String, type: String,
...@@ -30,13 +34,13 @@ const props = defineProps({ ...@@ -30,13 +34,13 @@ const props = defineProps({
}); });
const radioCurrent = ref(props.current); const radioCurrent = ref(props.current);
const radioOptions: any = computed(() => { const radioOptions: any = computed(() => {
if (props.type === 'analysisDate') { if (props.type === "analysisDate") {
return [ return [
{ label: '5M', value: '5m' }, { label: "5M", value: "5m" },
{ label: '30M', value: '30m' }, { label: "30M", value: "30m" },
{ label: '1H', value: '1h' }, { label: "1H", value: "1h" },
{ label: '6H', value: '6h' }, { label: "6H", value: "6h" },
{ label: '1D', value: '1d' }, { label: "1D", value: "1d" },
]; ];
} else if (props.options.length > 0) { } else if (props.options.length > 0) {
return props.options; return props.options;
...@@ -44,10 +48,10 @@ const radioOptions: any = computed(() => { ...@@ -44,10 +48,10 @@ const radioOptions: any = computed(() => {
return []; return [];
} }
}); });
const emit = defineEmits(['update:current', 'change']); const emit = defineEmits(["update:current", "change"]);
const changeDimension = (v) => { const changeDimension = (v) => {
radioCurrent.value = v; radioCurrent.value = v;
emit('update:current', v); emit("update:current", v);
emit('change', v); emit("change", v);
}; };
</script> </script>
import { defineNuxtPlugin } from "#app"; import { defineNuxtPlugin } from "#app";
import { import {
HeadMenu as THeadMenu,
MenuItem as TMenuItem,
Button as TButton, Button as TButton,
Header as Theader,
Content as TContent, Content as TContent,
Layout as Tlayout, Layout as Tlayout,
Input as TInput, Input as TInput,
...@@ -16,18 +13,12 @@ import { ...@@ -16,18 +13,12 @@ import {
Dialog as TDialog, Dialog as TDialog,
Option as TOption, Option as TOption,
Switch as TSwitch, Switch as TSwitch,
RadioGroup as TRadioGroup,
RadioButton as TRadioButton,
InputNumber as TInputNumber,
Checkbox as TCheckbox, Checkbox as TCheckbox,
Swiper as TSwiper, Swiper as TSwiper,
SwiperItem as TSwiperItem, SwiperItem as TSwiperItem,
} from "tdesign-vue-next"; } from "tdesign-vue-next";
const components = [ const components = [
THeadMenu,
TMenuItem,
TButton, TButton,
Theader,
TContent, TContent,
Tlayout, Tlayout,
TInput, TInput,
...@@ -40,9 +31,6 @@ const components = [ ...@@ -40,9 +31,6 @@ const components = [
TDialog, TDialog,
TOption, TOption,
TSwitch, TSwitch,
TRadioGroup,
TRadioButton,
TInputNumber,
TCheckbox, TCheckbox,
TSwiper, TSwiper,
TSwiperItem, TSwiperItem,
......
...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
<script lang="ts" setup> <script lang="ts" setup>
import Header from "./Header.vue"; import Header from "./Header.vue";
import Footer from "./Footer.vue"; import Footer from "./Footer.vue";
import { Header as THeader } from "tdesign-vue-next";
const route = useRoute(); const route = useRoute();
</script> </script>
......
...@@ -102,7 +102,11 @@ import FilterSvg from "/public/images/svg/filter/filter.svg"; ...@@ -102,7 +102,11 @@ import FilterSvg from "/public/images/svg/filter/filter.svg";
import FilterBuyAndSellSVG from "/public/images/svg/filter/filterBuyAndSell.svg"; import FilterBuyAndSellSVG from "/public/images/svg/filter/filterBuyAndSell.svg";
import historyListFilter from "./historyListFilter.vue"; import historyListFilter from "./historyListFilter.vue";
import { filterChainObj } from "@/constants/UnifiedManagementChain"; import { filterChainObj } from "@/constants/UnifiedManagementChain";
import { Table as TTable } from "tdesign-vue-next"; import {
Table as TTable,
RadioGroup as TRadioGroup,
RadioButton as TRadioButton,
} from "tdesign-vue-next";
const i18n = useI18n(); const i18n = useI18n();
let interval = null; let interval = null;
const tokenVisible = ref(false); const tokenVisible = ref(false);
......
...@@ -95,7 +95,7 @@ ...@@ -95,7 +95,7 @@
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
import { MessagePlugin } from "tdesign-vue-next"; import { MessagePlugin, InputNumber as TInputNumber } from "tdesign-vue-next";
import { useI18n } from "vue-i18n"; import { useI18n } from "vue-i18n";
import { import {
DatePicker as TDatePicker, DatePicker as TDatePicker,
......
<template> <template>
<div class="welfare-data"> <div class="welfare-data">
<div class="material-benefits"> <div class="material-benefits">
<h2>{{ $t('user.InvitationBenefits') }}</h2> <h2>{{ $t("user.InvitationBenefits") }}</h2>
<div class="invite-dataItem"> <div class="invite-dataItem">
<div class="invite-ItemData"> <div class="invite-ItemData">
<p>{{ $t('user.MyInvitationCode') }}</p> <p>{{ $t("user.MyInvitationCode") }}</p>
<p class="ItemData-p1">{{ formData.invite_code ?? '------' }}</p> <p class="ItemData-p1">{{ formData.invite_code ?? "------" }}</p>
<img <img
@click="doCopy(formData.invite_code)" @click="doCopy(formData.invite_code)"
:src="Imgs.copySvg" :src="Imgs.copySvg"
...@@ -13,8 +13,8 @@ ...@@ -13,8 +13,8 @@
/> />
</div> </div>
<div class="invite-ItemData"> <div class="invite-ItemData">
<p>{{ $t('user.InvitationLinks') }}</p> <p>{{ $t("user.InvitationLinks") }}</p>
<p class="ItemData-p1">{{ formData.invite_href ?? '------' }}</p> <p class="ItemData-p1">{{ formData.invite_href ?? "------" }}</p>
<img <img
@click="doCopy(formData.invite_href)" @click="doCopy(formData.invite_href)"
:src="Imgs.copySvg" :src="Imgs.copySvg"
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
/> />
</div> </div>
<div class="invite-ItemData"> <div class="invite-ItemData">
<p>{{ $t('user.InvitationPoints') }}</p> <p>{{ $t("user.InvitationPoints") }}</p>
<p class="ItemData-p1">0</p> <p class="ItemData-p1">0</p>
</div> </div>
</div> </div>
...@@ -30,10 +30,10 @@ ...@@ -30,10 +30,10 @@
<t-button <t-button
class="custom_button_back_border" class="custom_button_back_border"
@click="QrCodevisible = true" @click="QrCodevisible = true"
>{{ $t('user.InvitationQRCode') }}</t-button >{{ $t("user.InvitationQRCode") }}</t-button
> >
<t-button class="btn-item1" @click="InvitedVisible = true">{{ <t-button class="btn-item1" @click="InvitedVisible = true">{{
$t('user.AwardCollection') $t("user.AwardCollection")
}}</t-button> }}</t-button>
<InvitedDialog <InvitedDialog
:InvitedVisible="InvitedVisible" :InvitedVisible="InvitedVisible"
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
<t-button <t-button
@click="recordVisible = true" @click="recordVisible = true"
class="record-btn custom_button_back_border" class="record-btn custom_button_back_border"
>{{ $t('user.InvitationRecord') }}</t-button >{{ $t("user.InvitationRecord") }}</t-button
> >
<RecordDialog <RecordDialog
:inviteData="formData.inviteList" :inviteData="formData.inviteList"
...@@ -54,23 +54,23 @@ ...@@ -54,23 +54,23 @@
<div class="material-item"> <div class="material-item">
<div class="effectivity"> <div class="effectivity">
<div class="effectivity-item1"> <div class="effectivity-item1">
<h2>{{ formData.invite_total ?? '0' }}</h2> <h2>{{ formData.invite_total ?? "0" }}</h2>
<p>{{ $t('user.TotalNumber') }}</p> <p>{{ $t("user.TotalNumber") }}</p>
</div> </div>
<div class="line"></div> <div class="line"></div>
<div class="effectivity-item1"> <div class="effectivity-item1">
<h2>{{ formData.valid_invite_total ?? '0' }}</h2> <h2>{{ formData.valid_invite_total ?? "0" }}</h2>
<p>{{ $t('user.ValidInvitation') }}</p> <p>{{ $t("user.ValidInvitation") }}</p>
</div> </div>
</div> </div>
<div class="regulation"> <div class="regulation">
<h1>{{ $t('user.InvitationRules') }}</h1> <h1>{{ $t("user.InvitationRules") }}</h1>
<div class="regulation-content narrow-scrollbar"> <div class="regulation-content narrow-scrollbar">
<p>1、{{ $t('user.Rule1') }}</p> <p>1、{{ $t("user.Rule1") }}</p>
<p>2、{{ $t('user.Rule2') }}</p> <p>2、{{ $t("user.Rule2") }}</p>
<p>3、{{ $t('user.Rule3') }}</p> <p>3、{{ $t("user.Rule3") }}</p>
<p>4、{{ $t('user.Rule4') }}</p> <p>4、{{ $t("user.Rule4") }}</p>
<p>5、{{ $t('user.Rule5') }}</p> <p>5、{{ $t("user.Rule5") }}</p>
</div> </div>
</div> </div>
</div> </div>
...@@ -135,20 +135,21 @@ ...@@ -135,20 +135,21 @@
</div> </div>
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
import InvitedDialog from './InvitedDialog.vue'; import InvitedDialog from "./InvitedDialog.vue";
import RecordDialog from './recordDialog.vue'; import RecordDialog from "./recordDialog.vue";
import request from '@/utils/request'; import request from "@/utils/request";
import useCopy from '@/hooks/useCopy'; import useCopy from "@/hooks/useCopy";
import { InputNumber as TInputNumber } from "tdesign-vue-next";
const { doCopy } = useCopy(); const { doCopy } = useCopy();
const Cookie = useCookie('userCookie'); const Cookie = useCookie("userCookie");
const Imgs = { const Imgs = {
copySvg: '/images/svg/header/copy.svg', copySvg: "/images/svg/header/copy.svg",
}; };
const formData = reactive({ const formData = reactive({
invite_code: '', invite_code: "",
invite_href: '', invite_href: "",
invite_total: '', invite_total: "",
valid_invite_total: '', valid_invite_total: "",
inviteList: [], inviteList: [],
}); });
const InvitedVisible = ref(false); const InvitedVisible = ref(false);
...@@ -161,7 +162,7 @@ onMounted(() => { ...@@ -161,7 +162,7 @@ onMounted(() => {
getinvitationList(); getinvitationList();
}); });
const getinvitationList = async () => { const getinvitationList = async () => {
const res: any = await request.get('/api/user/invite/info', { const res: any = await request.get("/api/user/invite/info", {
headers: { headers: {
authorization: `Bearer ${Cookie.value}`, authorization: `Bearer ${Cookie.value}`,
}, },
...@@ -198,7 +199,7 @@ const closeRecordDialog = (value: boolean) => { ...@@ -198,7 +199,7 @@ const closeRecordDialog = (value: boolean) => {
}; };
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
@import '@/style/flex.less'; @import "@/style/flex.less";
.welfare-data { .welfare-data {
border: 1px solid var(--td-Search-info-border-bottom-2); border: 1px solid var(--td-Search-info-border-bottom-2);
width: calc(100vw - 410px); width: calc(100vw - 410px);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment