richdocuments/lib/genesis.php

29 lines
611 B
PHP
Raw Normal View History

2013-08-07 21:14:36 +03:00
<?php
2013-08-08 00:22:21 +03:00
/**
* ownCloud - Office App
*
* @author Victor Dubiniuk
* @copyright 2013 Victor Dubiniuk victor.dubiniuk@gmail.com
*
* This file is licensed under the Affero General Public License version 3 or
* later.
*/
2013-08-07 21:14:36 +03:00
namespace OCA\Office;
class Genesis {
public static function serve($args){
2013-08-07 23:56:46 +03:00
\OCP\JSON::checkLoggedIn();
2013-08-07 21:14:36 +03:00
$session = Session::getSession(@$args['es_id']);
$filename = isset($session['genesis_url']) ? $session['genesis_url'] : '';
2013-08-07 21:41:11 +03:00
$officeView = View::initOfficeView($session['owner']);
$download = new Download($officeView, $filename);
2013-08-07 21:14:36 +03:00
$download->sendResponse();
}
}