Skip to content

Commit

Permalink
Merge branch 'main' of github.com:vbenjs/vue-vben-admin
Browse files Browse the repository at this point in the history
  • Loading branch information
MZ-Dlovely committed Oct 30, 2024
2 parents 82887ca + e600d78 commit a71934e
Show file tree
Hide file tree
Showing 58 changed files with 1,614 additions and 1,650 deletions.
File renamed without changes.
2 changes: 1 addition & 1 deletion apps/web-antd/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/web-antd",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://vben.pro",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
4 changes: 2 additions & 2 deletions apps/web-antd/src/router/guard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { startProgress, stopProgress } from '@vben/utils';
import { useTitle } from '@vueuse/core';

import { $t } from '#/locales';
import { coreRouteNames, dynamicRoutes } from '#/router/routes';
import { accessRoutes, coreRouteNames } from '#/router/routes';
import { useAuthStore } from '#/store';

import { generateAccess } from './access';
Expand Down Expand Up @@ -105,7 +105,7 @@ function setupAccessGuard(router: Router) {
roles: userRoles,
router,
// 则会在菜单中显示,但是访问会被重定向到403
routes: dynamicRoutes,
routes: accessRoutes,
});

// 保存菜单信息和路由信息
Expand Down
9 changes: 7 additions & 2 deletions apps/web-antd/src/router/routes/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,16 @@ const dynamicRouteFiles = import.meta.glob('./modules/**/*.ts', {

// 有需要可以自行打开注释,并创建文件夹
// const externalRouteFiles = import.meta.glob('./external/**/*.ts', { eager: true });
// const staticRouteFiles = import.meta.glob('./static/**/*.ts', { eager: true });

/** 动态路由 */
const dynamicRoutes: RouteRecordRaw[] = mergeRouteModules(dynamicRouteFiles);

/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统 */
/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统(不会显示在菜单中) */
// const externalRoutes: RouteRecordRaw[] = mergeRouteModules(externalRouteFiles);
/** 不需要权限的菜单列表(会显示在菜单中) */
// const staticRoutes: RouteRecordRaw[] = mergeRouteModules(staticRouteFiles);
const staticRoutes: RouteRecordRaw[] = [];
const externalRoutes: RouteRecordRaw[] = [];

/** 路由列表,由基本路由+静态路由组成 */
Expand All @@ -28,4 +32,5 @@ const routes: RouteRecordRaw[] = [
/** 基本路由列表,这些路由不需要进入权限拦截 */
const coreRouteNames = traverseTreeValues(coreRoutes, (route) => route.name);

export { coreRouteNames, dynamicRoutes, routes };
const accessRoutes = [...dynamicRoutes, ...staticRoutes];
export { accessRoutes, coreRouteNames, routes };
2 changes: 1 addition & 1 deletion apps/web-ele/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/web-ele",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://vben.pro",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
4 changes: 2 additions & 2 deletions apps/web-ele/src/router/guard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { startProgress, stopProgress } from '@vben/utils';
import { useTitle } from '@vueuse/core';

import { $t } from '#/locales';
import { coreRouteNames, dynamicRoutes } from '#/router/routes';
import { accessRoutes, coreRouteNames } from '#/router/routes';
import { useAuthStore } from '#/store';

import { generateAccess } from './access';
Expand Down Expand Up @@ -105,7 +105,7 @@ function setupAccessGuard(router: Router) {
roles: userRoles,
router,
// 则会在菜单中显示,但是访问会被重定向到403
routes: dynamicRoutes,
routes: accessRoutes,
});

// 保存菜单信息和路由信息
Expand Down
9 changes: 7 additions & 2 deletions apps/web-ele/src/router/routes/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,16 @@ const dynamicRouteFiles = import.meta.glob('./modules/**/*.ts', {

// 有需要可以自行打开注释,并创建文件夹
// const externalRouteFiles = import.meta.glob('./external/**/*.ts', { eager: true });
// const staticRouteFiles = import.meta.glob('./static/**/*.ts', { eager: true });

/** 动态路由 */
const dynamicRoutes: RouteRecordRaw[] = mergeRouteModules(dynamicRouteFiles);

/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统 */
/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统(不会显示在菜单中) */
// const externalRoutes: RouteRecordRaw[] = mergeRouteModules(externalRouteFiles);
/** 不需要权限的菜单列表(会显示在菜单中) */
// const staticRoutes: RouteRecordRaw[] = mergeRouteModules(staticRouteFiles);
const staticRoutes: RouteRecordRaw[] = [];
const externalRoutes: RouteRecordRaw[] = [];

/** 路由列表,由基本路由+静态路由组成 */
Expand All @@ -28,4 +32,5 @@ const routes: RouteRecordRaw[] = [
/** 基本路由列表,这些路由不需要进入权限拦截 */
const coreRouteNames = traverseTreeValues(coreRoutes, (route) => route.name);

export { coreRouteNames, dynamicRoutes, routes };
const accessRoutes = [...dynamicRoutes, ...staticRoutes];
export { accessRoutes, coreRouteNames, routes };
2 changes: 1 addition & 1 deletion apps/web-naive/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/web-naive",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://vben.pro",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
4 changes: 2 additions & 2 deletions apps/web-naive/src/router/guard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { startProgress, stopProgress } from '@vben/utils';
import { useTitle } from '@vueuse/core';

import { $t } from '#/locales';
import { coreRouteNames, dynamicRoutes } from '#/router/routes';
import { accessRoutes, coreRouteNames } from '#/router/routes';
import { useAuthStore } from '#/store';

import { generateAccess } from './access';
Expand Down Expand Up @@ -104,7 +104,7 @@ function setupAccessGuard(router: Router) {
roles: userRoles,
router,
// 则会在菜单中显示,但是访问会被重定向到403
routes: dynamicRoutes,
routes: accessRoutes,
});

// 保存菜单信息和路由信息
Expand Down
9 changes: 7 additions & 2 deletions apps/web-naive/src/router/routes/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,16 @@ const dynamicRouteFiles = import.meta.glob('./modules/**/*.ts', {

// 有需要可以自行打开注释,并创建文件夹
// const externalRouteFiles = import.meta.glob('./external/**/*.ts', { eager: true });
// const staticRouteFiles = import.meta.glob('./static/**/*.ts', { eager: true });

/** 动态路由 */
const dynamicRoutes: RouteRecordRaw[] = mergeRouteModules(dynamicRouteFiles);

/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统 */
/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统(不会显示在菜单中) */
// const externalRoutes: RouteRecordRaw[] = mergeRouteModules(externalRouteFiles);
/** 不需要权限的菜单列表(会显示在菜单中) */
// const staticRoutes: RouteRecordRaw[] = mergeRouteModules(staticRouteFiles);
const staticRoutes: RouteRecordRaw[] = [];
const externalRoutes: RouteRecordRaw[] = [];

/** 路由列表,由基本路由+静态路由组成 */
Expand All @@ -28,4 +32,5 @@ const routes: RouteRecordRaw[] = [
/** 基本路由列表,这些路由不需要进入权限拦截 */
const coreRouteNames = traverseTreeValues(coreRoutes, (route) => route.name);

export { coreRouteNames, dynamicRoutes, routes };
const accessRoutes = [...dynamicRoutes, ...staticRoutes];
export { accessRoutes, coreRouteNames, routes };
2 changes: 1 addition & 1 deletion docs/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/docs",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"scripts": {
"build": "vitepress build",
Expand Down
2 changes: 1 addition & 1 deletion docs/src/guide/essentials/concept.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# 基础概念

新版本中,整体工程进行了重构,现在我们将会介绍一些基础概念,以便于你更好的理解整个文档。请务必仔先阅读这一部分
新版本中,整体工程进行了重构,现在我们将会介绍一些基础概念,以便于你更好的理解整个文档。请务必仔细阅读这一部分

## 大仓

Expand Down
2 changes: 1 addition & 1 deletion docs/src/guide/introduction/quick-start.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ pnpm install

#### 选择项目

执行以下命运行项目:
执行以下命令运行项目:

```bash
# 启动项目
Expand Down
2 changes: 1 addition & 1 deletion internal/lint-configs/commitlint-config/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/commitlint-config",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
Expand Down
2 changes: 1 addition & 1 deletion internal/lint-configs/stylelint-config/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/stylelint-config",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
Expand Down
3 changes: 1 addition & 2 deletions internal/node-utils/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/node-utils",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
Expand Down Expand Up @@ -35,7 +35,6 @@
"dayjs": "catalog:",
"execa": "catalog:",
"find-up": "catalog:",
"nanoid": "catalog:",
"ora": "catalog:",
"pkg-types": "catalog:",
"prettier": "catalog:",
Expand Down
2 changes: 0 additions & 2 deletions internal/node-utils/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ export { default as colors } from 'chalk';
export { consola } from 'consola';
export * from 'execa';

export { nanoid } from 'nanoid';

export { default as fs } from 'node:fs/promises';

export { type PackageJson, readPackageJSON } from 'pkg-types';
Expand Down
2 changes: 1 addition & 1 deletion internal/tailwind-config/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/tailwind-config",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
Expand Down
2 changes: 1 addition & 1 deletion internal/tsconfig/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/tsconfig",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
Expand Down
2 changes: 1 addition & 1 deletion internal/vite-config/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/vite-config",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vben-admin-monorepo",
"version": "5.4.2",
"version": "5.4.3",
"private": true,
"keywords": [
"monorepo",
Expand Down Expand Up @@ -101,7 +101,7 @@
"node": ">=20.10.0",
"pnpm": ">=9.5.0"
},
"packageManager": "pnpm@9.12.2",
"packageManager": "pnpm@9.12.3",
"pnpm": {
"peerDependencyRules": {
"allowedVersions": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/base/design/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/design",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/base/icons/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/icons",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/base/shared/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/shared",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/base/typings/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/typings",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/composables/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/composables",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/preferences/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/preferences",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
5 changes: 4 additions & 1 deletion packages/@core/ui-kit/form-ui/src/form-render/form.vue
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,10 @@ const formCollapsed = computed(() => {
});
const computedSchema = computed(
(): ({ commonComponentProps: Record<string, any> } & FormSchema)[] => {
(): ({
commonComponentProps: Record<string, any>;
formFieldProps: Record<string, any>;
} & Omit<FormSchema, 'formFieldProps'>)[] => {
const {
componentProps = {},
controlClass = '',
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/ui-kit/layout-ui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/layout-ui",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/ui-kit/menu-ui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/menu-ui",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/ui-kit/shadcn-ui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/shadcn-ui",
"version": "5.4.2",
"version": "5.4.3",
"#main": "./dist/index.mjs",
"#module": "./dist/index.mjs",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
Expand Down
2 changes: 1 addition & 1 deletion packages/@core/ui-kit/tabs-ui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben-core/tabs-ui",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/constants/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/constants",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/effects/access/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/access",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/effects/common-ui/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/common-ui",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/effects/hooks/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/hooks",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/effects/layouts/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/layouts",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
2 changes: 1 addition & 1 deletion packages/effects/plugins/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vben/plugins",
"version": "5.4.2",
"version": "5.4.3",
"homepage": "https://github.com/vbenjs/vue-vben-admin",
"bugs": "https://github.com/vbenjs/vue-vben-admin/issues",
"repository": {
Expand Down
Loading

0 comments on commit a71934e

Please sign in to comment.