Laravel-admin: 能否添加一个Admin::view()?

Created on 6 Dec 2017  ·  3Comments  ·  Source: z-song/laravel-admin

  • Laravel Version: #.#.#
  • PHP Version:
  • Laravel-admin: #.#.#

Description:

我想要有个admin::view()的功能,以便插入html到页面,因为经常要用到bootstrap的modal功能。
如果已经有了,请提醒一下我怎么使用,谢谢

Steps To Reproduce:

Most helpful comment

return Admin::content(function (Content $content) {

            $content->header('测试聊天');

            $content->body(view('admin.chat'));
        });

那些容器本身就是可以传入view('index')这种原生模板的,另外,在表单中是可以使用html()来插入HTML的,在表格中也可以用display来实现HTML的插入;

All 3 comments

return Admin::content(function (Content $content) {

            $content->header('测试聊天');

            $content->body(view('admin.chat'));
        });

那些容器本身就是可以传入view('index')这种原生模板的,另外,在表单中是可以使用html()来插入HTML的,在表格中也可以用display来实现HTML的插入;

好的,经过你的提醒,我发现可以插入两个view。

return Admin::content(function (Content $content) {

            $content->header('测试聊天');

            $content->body(view('admin.chat'));

            $content->body(view('admin.list'));
});

这里面还可以放容器呢
像这样

$content->row(function(Row $row) {
    $row->column(4, 'foo');
    $row->column(8, 'bar');
});
----------------------------------
|foo       |bar                  |
|          |                     |
|          |                     |
|          |                     |
|          |                     |
|          |                     |
----------------------------------
Was this page helpful?
0 / 5 - 0 ratings

Related issues

clock1129 picture clock1129  ·  3Comments

evans-kim picture evans-kim  ·  3Comments

greentornado picture greentornado  ·  3Comments

joernroeder picture joernroeder  ·  3Comments

benny-sun picture benny-sun  ·  3Comments