Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
.idea
/vendor
/composer.lock
13 changes: 13 additions & 0 deletions src/Think.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,19 @@ public function getConfig(string $name)
return $this->template->getConfig($name);
}

/**
* 设置布局
* @access public
* @param bool|string $name 布局模板名称 false 则关闭布局
* @param string $replace 布局模板内容替换标识
* @return $this
*/
public function layout(bool|string $name, string $replace = '')
{
$this->template->layout($name, $replace);
return $this;
}

public function __call($method, $params)
{
return call_user_func_array([$this->template, $method], $params);
Expand Down