falcon758/lavaliteposts

postbuffer 的通道包。

1.7 2020-04-02 22:50 UTC

This package is auto-updated.

Last update: 2024-09-19 20:25:34 UTC


README

Lavalite 包,为 cms 提供通道管理功能。

安装

首先通过 Composer 安装此包。编辑您的项目 composer.json 文件以要求 postbuffer/channels

"falcon758/lavaliteposts": "*"

接下来,通过终端更新 Composer

composer update

此操作完成后,在命令行中执行以下命令以完成安装。

Postbuffer\Channels\Providers\ChannelsServiceProvider::class,

并将其添加到别名

'Channels'  => Postbuffer\Channels\Facades\Channels::class,

发布文件和迁移数据库。

迁移和种子

php artisan migrate
php artisan db:seed --class=Postbuffer\\ChannelsTableSeeder

发布配置

php artisan vendor:publish --provider="Postbuffer\Channels\Providers\ChannelsServiceProvider" --tag="config"

发布语言

php artisan vendor:publish --provider="Postbuffer\Channels\Providers\ChannelsServiceProvider" --tag="lang"

发布视图

php artisan vendor:publish --provider="Postbuffer\Channels\Providers\ChannelsServiceProvider" --tag="view"

Web Urls

管理员

http://path-to-route-folder/admin/channels/{modulename}

用户

http://path-to-route-folder/user/channels/{modulename}

公共

http://path-to-route-folder/channels

API 端点

列表

http://path-to-route-folder/api/user/channels/{modulename}
METHOD: GET

创建

http://path-to-route-folder/api/user/channels/{modulename}
METHOD: POST

编辑

http://path-to-route-folder/api/user/channels/{modulename}/{id}
METHOD: PUT

删除

http://path-to-route-folder/api/user/channels/{modulename}/{id}
METHOD: DELETE

公共列表

http://path-to-route-folder/api/channels/{modulename}
METHOD: GET

公共单条

http://path-to-route-folder/api/channels/{modulename}/{slug}
METHOD: GET