feat(custom): !
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2024-09-03 22:21:16 +08:00
parent fd715b51a8
commit 0fe04dd0c3
13 changed files with 4867 additions and 1659 deletions

View File

@@ -68,7 +68,7 @@ const tabs = [
const count = ref(tabs.map((item) => item.messages).flat().length)
watch(activeTab, (v) => {
if (count === 0) return
if (count.value === 0) return
const tabIndex = tabs.findIndex((item) => item.name === v)
count.value -= tabs[tabIndex].messages.length
if (count.value < 0) count.value = 0

View File

@@ -32,12 +32,12 @@
<!-- ]"-->
<!-- />-->
<!-- </n-form-item-gi>-->
<n-form-item-gi :span="12" label="现金价格:" path="number">
<n-form-item-gi :span="12" label="商品价格:" path="number">
<n-input-number v-model:value="model.number" :min="0" placeholder="输入现金价格" />
</n-form-item-gi>
<n-form-item-gi :span="12" label="积分价格:" path="exchange">
<n-input-number v-model:value="model.exchange" :min="0" placeholder="输入积分价格" />
</n-form-item-gi>
<!-- <n-form-item-gi :span="12" label="积分价格:" path="exchange">-->
<!-- <n-input-number v-model:value="model.exchange" :min="0" placeholder="输入积分价格" />-->
<!-- </n-form-item-gi>-->
<n-form-item-gi :span="12" label="商品库存:" path="stock">
<n-input-number v-model:value="model.stock" :min="0" placeholder="输入商品库存" />
</n-form-item-gi>
@@ -118,12 +118,12 @@ const rules = {
message: '请输入商品价格',
trigger: 'blur',
},
exchange: {
required: true,
type: 'number',
message: '请输入市场价格',
trigger: 'blur',
},
// exchange: {
// required: true,
// type: 'number',
// message: '请输入市场价格',
// trigger: 'blur',
// },
stock: {
required: true,
type: 'number',
@@ -150,7 +150,7 @@ const getClassList = async () => {
classList.value = res.data.data.filter((item) => item.status !== 2)
if (row && type.value === 'edit') {
console.log(row)
// console.log(row)
type.value = 'edit'
model.value = {
...row,

View File

@@ -236,16 +236,22 @@ const columns = ref([
key: 'count',
},
{
title: '订单总价',
title: '订单金额',
align: 'center',
slot: 'number',
render: (row) => h('span', row.pay_type === 1 ? `${row.price}元` : `${row.exchange}积分`),
render: (row) => h('span', `${row.price}元`),
},
{
title: '积分抵扣',
align: 'center',
slot: 'discount_price',
render: (row) => h('span', `${row.discount_price}`),
},
{
title: '支付方式',
align: 'center',
slot: 'pay_type',
render: (row) => h('span', row.pay_type === 1 ? '微信' : '积分'),
render: (row) => h('span', row.pay_type === 1 ? '微信' : '平台抵扣'),
},
{
title: '订单状态',

View File

@@ -26,7 +26,7 @@ export default {
path: 'tx_list',
component: () => import('./tx_list/index.vue'),
meta: {
title: '积分提现',
title: '余额提现',
icon: 'mdi:account-multiple',
order: 10,
},

View File

@@ -1,24 +1,24 @@
<template>
<!-- <div> -->
<CommonPage show-footer :title="$route.title">
<div w-1200 flex items-center justify-between>
<n-card class="w-300">
<n-statistic label="可提现积分">
<n-number-animation
ref="numberAnimationInstRef"
:precision="2"
:from="0"
:to="userInfo.integral"
/>
</n-statistic>
</n-card>
<div w-100 text-center text-25>/</div>
<n-card class="w-300">
<n-statistic label="兑换比例">
<n-number-animation ref="numberAnimationInstRef" :precision="2" :from="0" :to="100" />
</n-statistic>
</n-card>
<div w-100 text-center text-25>=</div>
<div w-1200 flex items-center>
<!-- <n-card class="w-300">-->
<!-- <n-statistic label="可提现积分">-->
<!-- <n-number-animation-->
<!-- ref="numberAnimationInstRef"-->
<!-- :precision="2"-->
<!-- :from="0"-->
<!-- :to="userInfo.integral"-->
<!-- />-->
<!-- </n-statistic>-->
<!-- </n-card>-->
<!-- <div w-100 text-center text-25>/</div>-->
<!-- <n-card class="w-300">-->
<!-- <n-statistic label="兑换比例">-->
<!-- <n-number-animation ref="numberAnimationInstRef" :precision="2" :from="0" :to="100" />-->
<!-- </n-statistic>-->
<!-- </n-card>-->
<!-- <div w-100 text-center text-25>=</div>-->
<n-card class="w-300">
<n-statistic label="CNY">
<n-number-animation
@@ -30,7 +30,12 @@
</n-statistic>
</n-card>
<div ml-10 w-300 flex flex-col items-center justify-center>
<n-input-number v-model:value="formData.integral" clearable placeholder="请输入提现积分" />
<n-input-number
v-model:value="formData.integral"
clearable
w-full
placeholder="请输入提现余额"
/>
<n-button mt-10 w-full type="primary" @click="ok">立即提现</n-button>
</div>
</div>
@@ -66,7 +71,7 @@ const columns = ref([
align: 'center',
},
{
title: '上次留存积分',
title: '上次留存余额',
key: 'balance',
align: 'center',
},