From 6dde7334b7dd5506106a8b97991a779f4c995b36 Mon Sep 17 00:00:00 2001 From: fisssssh Date: Fri, 13 Mar 2026 21:42:44 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=9B=B4=E6=96=B0=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E9=A2=84=E8=A7=88=E5=8F=8A=E7=9B=B8=E5=85=B3=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 30 +++++----- codestyle-admin-web/src/types/components.d.ts | 56 ------------------- .../src/views/template/list/PreviewModal.vue | 43 ++++++++++++-- .../main/resources/config/application-dev.yml | 2 +- 4 files changed, 54 insertions(+), 77 deletions(-) diff --git a/README.md b/README.md index 2cdb553..315887a 100644 --- a/README.md +++ b/README.md @@ -256,33 +256,32 @@ 1. **克隆项目** ```bash - git clone https://github.com/codestyle-team/codestyle.git + git clone https://github.com/itxaiohanglover/codestyle cd codestyle ``` 2. **配置数据库** ```bash # 创建数据库 - mysql -u root -p - CREATE DATABASE codestyle DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci; + mysql -u root -p你的密码 -e "CREATE DATABASE codestyle_admin DEFAULT CHARACTER SET utf8mb4 COLLATE + utf8mb4_unicode_ci;" + + # 导入表结构和数据 + mysql -u root -p你的密码 codestyle_admin < main_table.sql + mysql -u root -p你的密码 codestyle_admin < main_data.sql +``` - # 导入初始化脚本 - mysql -u root -p codestyle < docs/sql/init.sql - ``` - 3. **配置应用** ```bash - # 修改后端配置 - cd codestyle-admin/codestyle-server/src/main/resources - cp application-dev.yml.example application-dev.yml - # 编辑 application-dev.yml,配置数据库、Redis、ES 连接信息 + 编辑 application-dev.yml,将数据库密码改为 你的密码: + password: ${DB_PWD:你的密码} ``` - + 4. **启动后端** ```bash cd codestyle-admin - mvn clean package -DskipTests - java -jar codestyle-server/target/codestyle-server.jar + mvn clean package -DskipTests -Pfat-jar + java -jar codestyle-server/target/codestyle-admin.jar ``` 5. **启动前端** @@ -294,7 +293,8 @@ 6. **访问应用** - 前端地址:http://localhost:5173 - - 后端地址:http://localhost:8080 + - 后端地址:http://localhost:8000 + - API文档:http://localhost:8000/doc.html - 默认账号:admin / admin123 ### Docker 部署 diff --git a/codestyle-admin-web/src/types/components.d.ts b/codestyle-admin-web/src/types/components.d.ts index 5b9bb06..7fa6b1b 100644 --- a/codestyle-admin-web/src/types/components.d.ts +++ b/codestyle-admin-web/src/types/components.d.ts @@ -7,63 +7,7 @@ export {} declare module 'vue' { export interface GlobalComponents { - Avatar: typeof import('./../components/Avatar/index.vue')['default'] - Breadcrumb: typeof import('./../components/Breadcrumb/index.vue')['default'] - CellCopy: typeof import('./../components/CellCopy/index.vue')['default'] - Chart: typeof import('./../components/Chart/index.vue')['default'] - ColumnSetting: typeof import('./../components/GiTable/src/components/ColumnSetting.vue')['default'] - CronForm: typeof import('./../components/GenCron/CronForm/index.vue')['default'] - CronModal: typeof import('./../components/GenCron/CronModal/index.vue')['default'] - DateRangePicker: typeof import('./../components/DateRangePicker/index.vue')['default'] - DayForm: typeof import('./../components/GenCron/CronForm/component/day-form.vue')['default'] - FilePreview: typeof import('./../components/FilePreview/index.vue')['default'] - GiCellAvatar: typeof import('./../components/GiCell/GiCellAvatar.vue')['default'] - GiCellGender: typeof import('./../components/GiCell/GiCellGender.vue')['default'] - GiCellStatus: typeof import('./../components/GiCell/GiCellStatus.vue')['default'] - GiCellTag: typeof import('./../components/GiCell/GiCellTag.vue')['default'] - GiCellTags: typeof import('./../components/GiCell/GiCellTags.vue')['default'] - GiCodeView: typeof import('./../components/GiCodeView/index.vue')['default'] - GiDot: typeof import('./../components/GiDot/index.tsx')['default'] - GiEditTable: typeof import('./../components/GiEditTable/GiEditTable.vue')['default'] - GiFooter: typeof import('./../components/GiFooter/index.vue')['default'] - GiForm: typeof import('./../components/GiForm/src/GiForm.vue')['default'] - GiIconBox: typeof import('./../components/GiIconBox/index.vue')['default'] - GiIconSelector: typeof import('./../components/GiIconSelector/index.vue')['default'] - GiIframe: typeof import('./../components/GiIframe/index.vue')['default'] - GiOption: typeof import('./../components/GiOption/index.vue')['default'] - GiOptionItem: typeof import('./../components/GiOptionItem/index.vue')['default'] - GiPageLayout: typeof import('./../components/GiPageLayout/index.vue')['default'] - GiSpace: typeof import('./../components/GiSpace/index.vue')['default'] - GiSplitButton: typeof import('./../components/GiSplitButton/index.vue')['default'] - GiSplitPane: typeof import('./../components/GiSplitPane/index.vue')['default'] - GiSplitPaneFlexibleBox: typeof import('./../components/GiSplitPane/components/GiSplitPaneFlexibleBox.vue')['default'] - GiSvgIcon: typeof import('./../components/GiSvgIcon/index.vue')['default'] - GiTable: typeof import('./../components/GiTable/src/GiTable.vue')['default'] - GiTag: typeof import('./../components/GiTag/index.tsx')['default'] - GiThemeBtn: typeof import('./../components/GiThemeBtn/index.vue')['default'] - HourForm: typeof import('./../components/GenCron/CronForm/component/hour-form.vue')['default'] - Icon403: typeof import('./../components/icons/Icon403.vue')['default'] - Icon404: typeof import('./../components/icons/Icon404.vue')['default'] - Icon500: typeof import('./../components/icons/Icon500.vue')['default'] - IconBorders: typeof import('./../components/icons/IconBorders.vue')['default'] - IconTableSize: typeof import('./../components/icons/IconTableSize.vue')['default'] - IconTreeAdd: typeof import('./../components/icons/IconTreeAdd.vue')['default'] - IconTreeReduce: typeof import('./../components/icons/IconTreeReduce.vue')['default'] - JsonPretty: typeof import('./../components/JsonPretty/index.vue')['default'] - MinuteForm: typeof import('./../components/GenCron/CronForm/component/minute-form.vue')['default'] - MonthForm: typeof import('./../components/GenCron/CronForm/component/month-form.vue')['default'] - MultipartUpload: typeof import('./../components/MultipartUpload/index.vue')['default'] - ParentView: typeof import('./../components/ParentView/index.vue')['default'] RouterLink: typeof import('vue-router')['RouterLink'] RouterView: typeof import('vue-router')['RouterView'] - SecondForm: typeof import('./../components/GenCron/CronForm/component/second-form.vue')['default'] - SplitPanel: typeof import('./../components/SplitPanel/index.vue')['default'] - TextCopy: typeof import('./../components/TextCopy/index.vue')['default'] - UserSelect: typeof import('./../components/UserSelect/index.vue')['default'] - Verify: typeof import('./../components/Verify/index.vue')['default'] - VerifyPoints: typeof import('./../components/Verify/Verify/VerifyPoints.vue')['default'] - VerifySlide: typeof import('./../components/Verify/Verify/VerifySlide.vue')['default'] - WeekForm: typeof import('./../components/GenCron/CronForm/component/week-form.vue')['default'] - YearForm: typeof import('./../components/GenCron/CronForm/component/year-form.vue')['default'] } } diff --git a/codestyle-admin-web/src/views/template/list/PreviewModal.vue b/codestyle-admin-web/src/views/template/list/PreviewModal.vue index bc932cd..3a5c831 100644 --- a/codestyle-admin-web/src/views/template/list/PreviewModal.vue +++ b/codestyle-admin-web/src/views/template/list/PreviewModal.vue @@ -150,6 +150,7 @@