优化上传组件
This commit is contained in:
20
app/model/Attach.php
Normal file
20
app/model/Attach.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | SentCMS [ WE CAN DO IT JUST THINK IT ]
|
||||
// +----------------------------------------------------------------------
|
||||
// | Copyright (c) 2013 http://www.tensent.cn All rights reserved.
|
||||
// +----------------------------------------------------------------------
|
||||
// | Author: molong <molong@tensent.cn> <http://www.tensent.cn>
|
||||
// +----------------------------------------------------------------------
|
||||
namespace app\model;
|
||||
|
||||
/**
|
||||
* 附件模型
|
||||
*/
|
||||
class Attach extends \think\Model {
|
||||
|
||||
protected function getUrlAttr($value, $data){
|
||||
return $value ? $value : $data['path'];
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user