Highway to PSR2
[openemr.git] / interface / forms / newGroupEncounter / new.php
blob005ee06a9e0fc35c0620ca950a8137e6ef58fde3
1 <?php
2 /**
3 * Encounter form new script.
5 * Copyright (C) 2016 Shachar Zilbershlag <shaharzi@matrix.co.il>
6 * Copyright (C) 2016 Amiel Elboim <amielel@matrix.co.il>
8 * LICENSE: This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License
10 * as published by the Free Software Foundation; either version 2
11 * of the License, or (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://opensource.org/licenses/gpl-license.php>;.
19 * @package OpenEMR
20 * @author Amiel Elboim <amielel@matrix.co.il>
21 * @author Brady Miller <brady.g.miller@gmail.com>
22 * @link http://www.open-emr.org
28 include_once("../../globals.php");
29 include_once("$srcdir/acl.inc");
30 include_once("$srcdir/lists.inc");
32 // todo -include_once("$srcdir/groups.inc");
35 /*// todo Check permission to create encounters.
36 $tmp = getGroupData($pid, "squad");
37 if (($tmp['squad'] && ! acl_check('squads', $tmp['squad'])) ||
38 ! (acl_check('encounters', 'notes_a' ) ||
39 acl_check('encounters', 'notes' ) ||
40 acl_check('encounters', 'coding_a') ||
41 acl_check('encounters', 'coding' ) ||
42 acl_check('encounters', 'relaxed' )))
44 echo "<body>\n<html>\n";
45 echo "<p>(" . xlt('New encounters not authorized'). ")</p>\n";
46 echo "</body>\n</html>\n";
47 exit();
48 }*/
50 $viewmode = false;
51 if (acl_check("groups", "glog", false, 'write')) {
52 require_once("common.php");
53 } else {
54 echo xlt("access not allowed");