fix #1220
This commit is contained in:
@@ -47,7 +47,7 @@ class Edit extends PostEdit implements ActionInterface
|
||||
$this->user->pass('editor');
|
||||
|
||||
/** 获取文章内容 */
|
||||
if (!empty($this->request->cid) && 'delete' != $this->request->do && 'sort' != $this->request->do) {
|
||||
if (!empty($this->request->cid) && in_array($this->request->do, ['save', 'publish'])) {
|
||||
$this->db->fetchRow($this->select()
|
||||
->where('table.contents.type = ? OR table.contents.type = ?', 'page', 'page_draft')
|
||||
->where('table.contents.cid = ?', $this->request->filter('int')->cid)
|
||||
|
||||
@@ -45,7 +45,7 @@ class Edit extends Contents implements ActionInterface
|
||||
$this->user->pass('contributor');
|
||||
|
||||
/** 获取文章内容 */
|
||||
if (!empty($this->request->cid) && 'delete' != $this->request->do) {
|
||||
if (!empty($this->request->cid) && in_array($this->request->do, ['save', 'publish'])) {
|
||||
$this->db->fetchRow($this->select()
|
||||
->where('table.contents.type = ? OR table.contents.type = ?', 'post', 'post_draft')
|
||||
->where('table.contents.cid = ?', $this->request->filter('int')->cid)
|
||||
|
||||
Reference in New Issue
Block a user