ak73gucas/json-editor

用于 Laravel-admin 的 JSON 编辑器

1.0.8 2020-07-16 03:39 UTC

This package is auto-updated.

Last update: 2024-09-17 16:30:33 UTC


README

这是一个将 JSON 编辑器 集成到 laravel-adminlaravel-admin 扩展。

DEMO 使用 admin/admin 登录

截图

安装

composer require ak73gucas/json-editor
php artisan vendor:publish --tag=laravel-admin-json-editor

更新

composer require ak73gucas/json-editor
php artisan vendor:publish --tag=laravel-admin-json-editor --force

配置

config/admin.php 文件的 extensions 部分中,添加属于此扩展的配置。

'extensions' => [
    'json-editor' => [
        // set to false if you want to disable this extension
        'enable' => true,
        'config' =>
            [
                'mode' => 'tree',
                'modes' => ['code', 'form', 'text', 'tree', 'view'], // allowed modes
            ],
    ]
]

更多配置信息请查看 JSON Editor

用法

在表单中使用它

$form->json('content');

更多资源

优秀的 Laravel-admin

许可

MIT 许可证 下授权。