diff --git a/CHANGELOG.md b/CHANGELOG.md index b5d6892fcf00c79543d614faa6c5a0183eedc299..111083172cd65254e1fc0bc82b8184a77124842c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,17 @@ # Release Notes -## [Unreleased](https://github.com/liaodeity/laravel-admin-cms/compare/v8.3.2...8.x) +## [Unreleased](https://github.com/liaodeity/laravel-admin-cms/compare/v8.3.3...8.x) + + +## [v8.3.3](https://github.com/liaodeity/laravel-admin-cms/compare/v8.3.2...v8.3.3) + +### Added +- 支持七牛云上传云存储([#9](https://gitee.com/liaodeiy/laravel-admin-cms/pulls/9)) +- 支持阿里云OSS上传云存储 +- 添加附件删除功能 + +### Fixed +- 修复附件上传按钮,一次上传后点击监听失效 ## [v8.3.2](https://github.com/liaodeity/laravel-admin-cms/compare/v8.3.1...v8.3.2) diff --git a/app/Http/Controllers/Admin/AttachmentController.php b/app/Http/Controllers/Admin/AttachmentController.php index d218478e8a5dcabb4be948e789d38700915fc375..93dbd6fc8ecbd468c4a6064299860861097784ca 100644 --- a/app/Http/Controllers/Admin/AttachmentController.php +++ b/app/Http/Controllers/Admin/AttachmentController.php @@ -123,7 +123,7 @@ class AttachmentController extends Controller $lists = $M->whereIn ('id', $ids)->get (); $num = 0; foreach ($lists as $item) { - $log_title = '删除附件[' . ($item->category->title ?? '') . '->' . $item->title . ']记录'; + $log_title = '删除附件记录'; $check = $this->repository->allowDelete ($item->id); if ($check) { $ret = Attachment::deleteFile ($item); diff --git a/database/migrations/2021_05_20_134344_create_category.php b/database/migrations/2021_05_20_134344_create_category.php new file mode 100644 index 0000000000000000000000000000000000000000..ffd5a0ee2822d01bc29d492705e9260b0f2ba68d --- /dev/null +++ b/database/migrations/2021_05_20_134344_create_category.php @@ -0,0 +1,39 @@ +id (); + $table->unsignedBigInteger ('pid')->default (0)->comment ('父ID'); + $table->unsignedBigInteger ('cover_id')->default (0)->comment ('分类图片'); + $table->tinyInteger ('module_id')->default (0)->comment ('分类模块'); + //$table->string ('module_id',100)->default ('')->comment ('分类标识[about,news,product,jobs]'); + $table->string ('cate_name', 20)->default ('')->comment ('分类名称'); + $table->string ('cate_desc', 200)->default ('')->comment ('分类描述'); + $table->smallInteger ('sort')->default (0)->comment ('排序'); + $table->tinyInteger ('status')->default (0)->comment ('状态【1=显示、4=隐藏】'); + $table->timestamps (); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down () + { + Schema::dropIfExists ('categories'); + } +} diff --git a/database/migrations/2021_05_20_143656_create_articles.php b/database/migrations/2021_05_20_143656_create_articles.php new file mode 100644 index 0000000000000000000000000000000000000000..399ab58a06500dfe0423166b89f5ce257451bd5f --- /dev/null +++ b/database/migrations/2021_05_20_143656_create_articles.php @@ -0,0 +1,43 @@ +id (); + $table->foreignId ('user_id')->constrained ()->cascadeOnDelete (); + $table->foreignId ('menu_id')->constrained ()->cascadeOnDelete (); + $table->foreignId ('category_id')->constrained ()->cascadeOnDelete (); + $table->string ('name', 100)->nullable ()->unique ()->comment ('名称唯一标识'); + $table->string ('title', 200)->default ('')->comment ('标题'); + $table->unsignedBigInteger ('cover_id')->default (0)->comment ('封面图片'); + $table->text ('content')->comment ('内容'); + $table->unsignedBigInteger ('views_number')->default (0)->comment ('浏览次数'); + $table->string ('source', 100)->default ('')->comment ('来源'); + $table->timestamp ('published_at')->nullable ()->comment ('发表时间'); + $table->tinyInteger ('is_top')->default (0)->comment ('是否置顶'); + $table->tinyInteger ('status')->default (0)->comment ('状态【1=正常、4=隐藏】'); + $table->timestamps (); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down () + { + Schema::dropIfExists ('articles'); + } +} diff --git a/database/migrations/2021_05_26_150713_create_web_menus.php b/database/migrations/2021_05_26_150713_create_web_menus.php new file mode 100644 index 0000000000000000000000000000000000000000..c3f3e5ae96ebb451e744edb2af3fe250624bb752 --- /dev/null +++ b/database/migrations/2021_05_26_150713_create_web_menus.php @@ -0,0 +1,43 @@ +id (); + $table->unsignedBigInteger ('pid')->default (0)->comment ('父ID'); + $table->string ('name', 50)->default ('')->comment ('菜单标识'); + $table->string ('title', 100)->default ('')->comment ('菜单标题'); + $table->string ('seo_keyword', 150)->default ('')->comment ('SEO关键词'); + $table->string ('seo_description', 200)->default ('')->comment ('SEO描述'); + $table->string ('url', 200)->default ('')->comment ('地址'); + $table->string ('target', 10)->default ('')->comment ('链接类型'); + //$table->unsignedBigInteger ('category_id')->default (0)->comment ('采用分类ID'); + //$table->unsignedBigInteger ('page_id')->default (0)->comment ('采用页面ID'); + $table->morphs ('adopt'); + $table->smallInteger ('sort')->default (0)->comment ('排序'); + $table->tinyInteger ('status')->default (0)->comment ('状态'); + $table->timestamps (); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down () + { + Schema::dropIfExists ('web_menus'); + } +}