* [task#145417,done,0.5h] Remove getDraft function.
This commit is contained in:
@@ -2317,7 +2317,7 @@ class doc extends control
|
||||
$doc->module = (int)$doc->module;
|
||||
$doc->privs = array('edit' => common::hasPriv('doc', 'edit', $doc) && $doc->acl == 'open');
|
||||
$doc->editors = $this->doc->getEditors($docID);
|
||||
$doc->draft = $doc->status == 'draft' ? $this->doc->getDraft($docID, $version) : null;
|
||||
$doc->draft = $doc->status == 'draft' ? $this->doc->getContent($docID, $version) : null;
|
||||
|
||||
$lib = $this->doc->getLibByID((int)$doc->lib);
|
||||
$objectType = $lib->type;
|
||||
|
||||
@@ -1152,19 +1152,6 @@ class docModel extends model
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取文档草稿。
|
||||
* Get doc draft.
|
||||
*
|
||||
* @param int $docID 文档ID
|
||||
* @access public
|
||||
* @return ?object
|
||||
*/
|
||||
public function getDraft(int $docID, int $version): ?object
|
||||
{
|
||||
return $this->getContent($docID, $version);
|
||||
}
|
||||
|
||||
/**
|
||||
* 处理文档数据。
|
||||
* Process doc data.
|
||||
|
||||
Reference in New Issue
Block a user