2 /** @package Openemr::Controller */
6 * Copyright (C) 2016-2017 Jerry Padgett <sjpadgett@gmail.com>
8 * LICENSE: This program is free software: you can redistribute it and/or modify
9 * it under the terms of the GNU Affero General Public License as
10 * published by the Free Software Foundation, either version 3 of the
11 * License, or (at your option) any later version.
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU Affero General Public License for more details.
18 * You should have received a copy of the GNU Affero General Public License
19 * along with this program. If not, see <http://www.gnu.org/licenses/>.
22 * @author Jerry Padgett <sjpadgett@gmail.com>
23 * @link http://www.open-emr.org
26 /** import supporting libraries */
27 require_once("AppBaseController.php");
30 * DefaultController is the entry point to the application
32 * @package Openemr::Controller
33 * @author ClassBuilder
36 class ProviderController
extends AppBaseController
39 * Override here for any controller-specific functionality
41 protected function Init()
45 // $this->RequirePermission(SecureApp::$PERMISSION_USER,'SecureApp.LoginForm');
49 * Display the home page for the application
51 public function Home()
54 if (isset($_SESSION['authUserID'])) {
55 $cuser = $_SESSION['authUserID'];
57 header("refresh:5;url= ./provider");
58 echo 'Shared session not allowed with Portal!!! <br>Onsite portal is using this session<br>Waiting until Onsite Portal is logged out........';
62 $this->Assign('cpid', $GLOBALS['pid']);
63 $this->Assign('cuser', $cuser);
69 * Displayed when an invalid route is specified
71 public function Error404()
77 * Display a fatal error message
79 public function ErrorFatal()
84 public function ErrorApi404()
86 $this->RenderErrorJSON('An unknown API endpoint was requested.');