增加创建链接

This commit is contained in:
lingling 2025-02-24 22:08:45 +08:00
parent 719551bbb0
commit 128ada0d4e
1 changed files with 36 additions and 26 deletions

View File

@ -2,6 +2,10 @@
<div class="container">
<Breadcrumb :items="['menu.promotion', 'menu.promotion.Table']" />
<a-card class="general-card" :title="$t('menu.promotion.Table')">
<div style="display: flex;justify-content: space-between;">
<a-button type="primary" @click="createlink">生成新链接</a-button>
<div>http://127.0.0.1:8787/Recommend/index?invite_code=</div>
</div>
<!-- <a-table :columns="columns" :data="data" @change="handleChange">
<template #columns>
<a-table-column title="id" data-index="id"></a-table-column>
@ -29,10 +33,16 @@
<script setup>
import { ref, onMounted, h } from 'vue';
import { lists } from '@/api/promotion';
import { lists, Generatelink } from '@/api/promotion';
import { IconSearch } from '@arco-design/web-vue/es/icon';
const data = ref([])
const createlink = async () => {
const res1 = await Generatelink()
const res = await lists()
data.value = res.data
}
onMounted(async () => {
const res = await lists()
data.value = res.data