feat: 项目管理调整

This commit is contained in:
caiyuchao
2025-06-30 19:03:10 +08:00
parent f0949b211a
commit acd01127d1
6 changed files with 256 additions and 129 deletions

View File

@@ -63,7 +63,10 @@ async function onDelete(row: ProjectApi.Project) {
/** 导出表格 */
async function onExport() {
const data = await exportProject(await gridApi.formApi.getValues());
downloadFileFromBlobPart({ fileName: '项目.xls', source: data });
downloadFileFromBlobPart({
fileName: `${$t('project.project')}.xls`,
source: data,
});
}
/** 表格操作按钮的回调函数 */
@@ -82,6 +85,8 @@ function onActionClick({ code, row }: OnActionClickParams<ProjectApi.Project>) {
const [Grid, gridApi] = useVbenVxeGrid({
formOptions: {
collapsed: true,
collapsedRows: 2,
schema: useGridFormSchema(),
},
gridOptions: {
@@ -117,7 +122,7 @@ const [Grid, gridApi] = useVbenVxeGrid({
<Page auto-content-height>
<FormModal @success="onRefresh" />
<Grid table-title="项目列表">
<Grid :table-title="$t('project.list')">
<template #toolbar-tools>
<Button
:icon="h(Plus)"
@@ -125,7 +130,7 @@ const [Grid, gridApi] = useVbenVxeGrid({
@click="onCreate"
v-access:code="['license:project:create']"
>
{{ $t('ui.actionTitle.create', ['项目']) }}
{{ $t('ui.actionTitle.create', [$t('project.project')]) }}
</Button>
<Button
:icon="h(Download)"