office share view bug.

pull/99/head
warlee 2016-09-02 11:16:46 +08:00
parent 6a02259992
commit b70a500a61
1 changed files with 11 additions and 1 deletions

View File

@ -306,6 +306,16 @@ class share extends Controller{
show_json($list);
}
public function _make_file_proxy($file_path){
if (!file_exists($file_path)) {
return '';
}
load_class('mcrypt');
$pass = $GLOBALS['config']['setting_system']['system_password'];
$fid = Mcrypt::encode($file_path,$pass,$GLOBALS['config']['settings']['download_url_time']);
$file_name = urlencode(get_path_this($file_path));
return APPHOST.'index.php?user/public_link&fid='.$fid.'&file_name=/'.$file_name;
}
//生成临时文件key
public function officeView(){
if (!file_exists($this->path)) {
@ -498,4 +508,4 @@ class share extends Controller{
_DIR_OUT($file_parem);
return $file_parem;
}
}
}