Exemplo n.º 1
0
 /**
  * 存储小文件文件到集群(2M以内的文件)
  *
  * @param string $fileBytes            
  * @param string $fileName            
  * @return string
  */
 public function uploadFile($fileBytes, $fileName)
 {
     $fileBytes = base64_decode($fileBytes);
     $rst = $this->_model->storeBytesToGridFS($fileBytes, $fileName, array('collection_id' => $this->_collection_id, 'project_id' => $this->_project_id));
     return $this->result($rst);
 }