* Fix bug.

This commit is contained in:
滔哥
2018-10-24 16:13:50 +08:00
parent 49c61607ef
commit 8c0940c039
+5
View File
@@ -367,6 +367,11 @@ class file extends control
$this->app->loadLang('action');
$file = $this->file->getByID($fileID);
$data = fixer::input('post')->get();
if(validater::checkLength($data->fileName, 80, 1) == false)
{
$errTip = $this->lang->error->length;
die(js::alert(sprintf($errTip[1], $this->lang->file->title, 80, 1)));
}
$fileName = $data->fileName . '.' . $data->extension;
$this->dao->update(TABLE_FILE)->set('title')->eq($fileName)->where('id')->eq($fileID)->exec();