2
0

fix:套餐界面修改参数

This commit is contained in:
zhongzm
2024-12-24 19:11:44 +08:00
parent 70979b17e1
commit b214cc0552
4 changed files with 39 additions and 5 deletions

View File

@@ -1,7 +1,7 @@
<script setup lang="ts">
import { useI18n } from 'vue-i18n';
import { ref, onMounted } from 'vue';
import { fetchPackageList, submitPackageOrder } from '@/service/api/auth';
import { fetchPackageList, submitOrder } from '@/service/api/auth';
import { message } from 'ant-design-vue';
const { t } = useI18n();
@@ -113,7 +113,10 @@ const selectPackage = (option: PackageOption) => {
// 添加办理套餐的方法
const handleSubmitOrder = async () => {
try {
await submitPackageOrder(selectedPackage.value.id);
await submitOrder({
type: 0,
packageId: selectedPackage.value.id
});
message.success('套餐办理成功!');
} catch (error) {
message.error('套餐办理失败,请重试!');