<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Admin\Controller; use Illuminate\Routing\Controller; use ModStart\Admin\Auth\Admin; use ModStart\Admin\Auth\AdminPermission; use ModStart\Core\Input\Request; use ModStart\Core\Input\Response; use ModStart\Data\FileManager; use ModStart\Data\UeditorManager; class DataController extends Controller { public function fileManager($QLOpy) { if (Request::isPost()) { return FileManager::handle($QLOpy, 'admin_upload', 'admin_upload_category', Admin::id(), null, function ($NaoVl) { switch ($NaoVl) { case 'config': break; case 'categoryDelete': case 'fileDelete': goto S3rAC; S3rAC: AdminPermission::demoCheck(); goto LnOWV; YGt5l: break; goto KJVKP; LnOWV: AdminPermission::permitCheck('DataFileManagerDelete'); goto YGt5l; KJVKP: case 'init': case 'upload': case 'save': case 'saveRaw': case 'uploadAndSaveBase64': case 'uploadDirect': case 'uploadDirectRaw': goto NlQXx; wtzQm: break; goto dgMkA; CFwMc: AdminPermission::permitCheck('DataFileManagerUpload'); goto wtzQm; NlQXx: AdminPermission::demoCheck(); goto CFwMc; dgMkA: case 'fileEdit': case 'categoryEdit': goto U1eAy; U1eAy: AdminPermission::demoCheck(); goto XBa2J; XBa2J: AdminPermission::permitCheck('DataFileManagerAdd/Edit'); goto grg3t; grg3t: break; goto FEMtp; FEMtp: case 'list': case 'category': AdminPermission::permitCheck('DataFileManagerView'); break; default: Response::quit(-1, 'Data Permit Denied'); break; } }); } return view('modstart::admin.data.fileManager', array('category' => $QLOpy, 'pageTitle' => L('Select ' . ucfirst($QLOpy)))); } public function ueditor() { return UeditorManager::handle('admin_upload', 'admin_upload_category', Admin::id()); } }