修复 pnpm run builde 报错

This commit is contained in:
2026-09-10 01:39:18 +08:00
parent 7500d3ab56
commit d578a81b74
11 changed files with 43 additions and 28 deletions
+5
View File
@@ -0,0 +1,5 @@
declare module "@wangeditor/editor-for-vue" {
import type { Component } from "vue";
export const Editor: Component;
export const Toolbar: Component;
}
+1 -1
View File
@@ -62,7 +62,7 @@
<el-table-column label="备注" align="center" prop="comment">
<template #default="scope">
<div v-if="scope.row.comment">
{{ formatComment(scope.row) }}
{{ formatComment(scope.row as IntegralPageUserVO) }}
</div>
</template>
</el-table-column>
+7 -6
View File
@@ -178,9 +178,10 @@ import ConfigAPI, {
ConfigForm,
ConfigPageQuery,
} from "@/api/config";
import type { FormInstance } from "element-plus";
const queryFormRef = ref(ElForm);
const dataFormRef = ref(ElForm);
const queryFormRef = ref<FormInstance>();
const dataFormRef = ref<FormInstance>();
const loading = ref(false);
const ids = ref<number[]>([]);
@@ -235,7 +236,7 @@ function handleQuery() {
}
/** 重置系统配置查询 */
function handleResetQuery() {
queryFormRef.value.resetFields();
queryFormRef.value!.resetFields();
queryParams.pageNum = 1;
handleQuery();
}
@@ -268,7 +269,7 @@ function handleRefreshCache() {
/** 提交系统配置表单 */
function handleSubmit() {
dataFormRef.value.validate((valid: any) => {
dataFormRef.value!.validate((valid: any) => {
if (valid) {
loading.value = true;
const id = formData.id;
@@ -296,8 +297,8 @@ function handleSubmit() {
/** 关闭系统配置弹窗 */
function handleCloseDialog() {
dialog.visible = false;
dataFormRef.value.resetFields();
dataFormRef.value.clearValidate();
dataFormRef.value!.resetFields();
dataFormRef.value!.clearValidate();
formData.id != undefined;
}
+7 -6
View File
@@ -222,9 +222,10 @@ defineOptions({
});
import DictAPI, { DictPageQuery, DictPageVO, DictForm } from "@/api/dict";
import type { FormInstance } from "element-plus";
const queryFormRef = ref(ElForm);
const dataFormRef = ref(ElForm);
const queryFormRef = ref<FormInstance>();
const dataFormRef = ref<FormInstance>();
const loading = ref(false);
const ids = ref<number[]>([]);
@@ -275,7 +276,7 @@ function handleQuery() {
// 重置查询
function handleResetClick() {
queryFormRef.value.resetFields();
queryFormRef.value!.resetFields();
queryParams.pageNum = 1;
handleQuery();
}
@@ -306,7 +307,7 @@ function handleEditClick(id: number, name: string) {
// 提交字典表单
function handleSubmitClick() {
dataFormRef.value.validate((isValid: boolean) => {
dataFormRef.value!.validate((isValid: boolean) => {
if (isValid) {
loading.value = true;
const id = formData.id;
@@ -335,8 +336,8 @@ function handleSubmitClick() {
function handleCloseDialog() {
dialog.visible = false;
dataFormRef.value.resetFields();
dataFormRef.value.clearValidate();
dataFormRef.value!.resetFields();
dataFormRef.value!.clearValidate();
formData.id = undefined;
formData.dictItems = [];
+3 -2
View File
@@ -81,8 +81,9 @@ defineOptions({
});
import LogAPI, { LogPageVO, LogPageQuery } from "@/api/log";
import type { FormInstance } from "element-plus";
const queryFormRef = ref(ElForm);
const queryFormRef = ref<FormInstance>();
const loading = ref(false);
const total = ref(0);
@@ -111,7 +112,7 @@ function handleQuery() {
}
/** 重置查询 */
function handleResetQuery() {
queryFormRef.value.resetFields();
queryFormRef.value!.resetFields();
queryParams.pageNum = 1;
queryParams.createTime = undefined;
handleQuery();
+7 -6
View File
@@ -454,9 +454,10 @@ defineOptions({
import MenuAPI, { MenuQuery, MenuForm, MenuVO } from "@/api/menu";
import { MenuTypeEnum } from "@/enums/MenuTypeEnum";
import type { FormInstance } from "element-plus";
const queryFormRef = ref(ElForm);
const menuFormRef = ref(ElForm);
const queryFormRef = ref<FormInstance>();
const menuFormRef = ref<FormInstance>();
const loading = ref(false);
const dialog = reactive({
@@ -514,7 +515,7 @@ function handleQuery() {
// 重置查询
function handleResetQuery() {
queryFormRef.value.resetFields();
queryFormRef.value!.resetFields();
handleQuery();
}
@@ -569,7 +570,7 @@ function handleMenuTypeChange() {
/** 菜单保存提交 */
function submitForm() {
menuFormRef.value.validate((isValid: boolean) => {
menuFormRef.value!.validate((isValid: boolean) => {
if (isValid) {
const menuId = formData.value.id;
if (menuId) {
@@ -621,8 +622,8 @@ function handleDelete(menuId: number) {
// 关闭弹窗
function handleCloseDialog() {
dialog.visible = false;
menuFormRef.value.resetFields();
menuFormRef.value.clearValidate();
menuFormRef.value!.resetFields();
menuFormRef.value!.clearValidate();
formData.value.id = undefined;
}
+1 -1
View File
@@ -36,7 +36,7 @@
<i-ep-edit />
转账
</el-button>
<el-button type="warning" size="small" link @click="handleOpenDialog(scope.row)">
<el-button type="warning" size="small" link @click="handleOpenDialog(scope.row as DrawPageVO)">
<i-ep-edit />
驳回
</el-button>
+1 -1
View File
@@ -71,7 +71,7 @@
<el-table-column label="备注" align="center" prop="comment">
<template #default="scope">
<div v-if="scope.row.comment">
{{ formatComment(scope.row) }}
{{ formatComment(scope.row as IntegralPageAdminVO) }}
</div>
</template>
</el-table-column>
+5 -5
View File
@@ -101,23 +101,23 @@
</el-table-column>
<el-table-column label="操作" align="center" fixed="right" width="240">
<template #default="scope">
<el-button type="primary" link @click="handleOpenDialog(scope.row)">
<el-button type="primary" link @click="handleOpenDialog(scope.row as StyleVO)">
<el-icon><EditPen /></el-icon>
定价
</el-button>
<el-button v-if="scope.row.state == 2" type="success" link @click="handleState(1, scope.row)">
<el-button v-if="scope.row.state == 2" type="success" link @click="handleState(1, scope.row as StyleVO)">
<el-icon><CirclePlus /></el-icon>
上线
</el-button>
<el-button v-else type="info" link @click="handleState(2, scope.row)">
<el-button v-else type="info" link @click="handleState(2, scope.row as StyleVO)">
<el-icon><Remove /></el-icon>
下线
</el-button>
<el-button v-if="scope.row.state == 0" type="success" link @click="handleState(1, scope.row)">
<el-button v-if="scope.row.state == 0" type="success" link @click="handleState(1, scope.row as StyleVO)">
<el-icon><Star /></el-icon>
{{ "取消推荐" }}
</el-button>
<el-button v-else-if="scope.row.state == 1" type="danger" link @click="handleState(0, scope.row)">
<el-button v-else-if="scope.row.state == 1" type="danger" link @click="handleState(0, scope.row as StyleVO)">
<el-icon><Star /></el-icon>
{{ "设为推荐" }}
</el-button>