本文整理汇总了PHP中checkPerms函数的典型用法代码示例。如果您正苦于以下问题:PHP checkPerms函数的具体用法?PHP checkPerms怎么用?PHP checkPerms使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了checkPerms函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: ProvinceList
function ProvinceList($http_post_vars, $sess, $sortBy, $sortOrder, $hideInactive)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must be Super-User to access
$pageType = "1%%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->sess = $sess;
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "ProvinceList.htm");
$this->tpl->set_var("TITLE", "Province List");
$this->tpl->set_var("Session", $this->sess->url(""));
$this->formArray["sortBy"] = $sortBy;
$this->formArray["sortOrder"] = $sortOrder;
$this->formArray["hideInactive"] = $hideInactive;
foreach ($http_post_vars as $key => $value) {
$this->formArray[$key] = $value;
}
}
示例2: OwnerPersonList
function OwnerPersonList($sess, $sortKey, $sortOrder, $page)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
$this->formArray["sortKey"] = "TRIM(Person.lastName), TRIM(Person.firstName), TRIM(Person.middleName)";
$this->formArray["sortOrder"] = "asc";
$this->formArray["page"] = 1;
//if($sortKey!="")
// $this->formArray["sortKey"] = $sortKey;
if ($sortOrder != "") {
$this->formArray["sortOrder"] = $sortOrder;
}
if ($page != "") {
$this->formArray["page"] = $page;
}
// must be Super-User to access
$pageType = "1%%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "OwnerPersonList.htm");
$this->tpl->set_var("TITLE", "Owner Person List");
}
示例3: ODList
function ODList($http_post_vars, $sess, $odID, $page, $searchKey, $barangay, $formAction, $sortBy, $sortOrder, $viewArchives, $transactionCode = "", $mergeBasketCSV)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must have atleast AM-EDIT access
$pageType = "%1%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "ODList.htm");
$this->tpl->set_var("TITLE", "Consolidation > RPU List");
$this->sess = $sess;
$this->formArray["odID"] = $odID;
$this->formArray["page"] = $page;
$this->formArray["searchKey"] = $searchKey;
$this->formArray["barangay"] = $barangay;
$this->formArray["sortBy"] = $sortBy;
$this->formArray["sortOrder"] = $sortOrder;
$this->formArray["viewArchives"] = $viewArchives;
$this->formArray["transactionCode"] = $transactionCode;
$this->formArray["formAction"] = $formAction;
$this->formArray["mergeBasketCSV"] = $mergeBasketCSV;
$this->formArray["viewArchivesTitle"] = "";
$this->formArray["archiveValue"] = "";
$this->formArray["odIDArray"] = "";
foreach ($http_post_vars as $key => $value) {
$this->formArray[$key] = $value;
}
}
示例4: TreasurySettingsEncode
function TreasurySettingsEncode($http_post_vars, $sess, $formAction, $masterTables)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
$this->masterTables = $masterTables;
// must be Super-User to access
$pageType = "1%%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "TreasurySettingsEncode.htm");
$this->tpl->set_var("TITLE", "Treasury Settings");
$this->formArray = array("formAction" => $formAction, "message" => "", "cutOff" => "");
foreach ($http_post_vars as $key => $value) {
$this->formArray[$key] = $value;
}
if ($this->formArray["discountPeriod_month"] != "" && $this->formArray["discountPeriod_month"] != "") {
$dateStr = putPreZero($this->formArray["discountPeriod_month"]) . "-" . putPreZero($this->formArray["discountPeriod_day"]);
$this->formArray["discountPeriod"] = $dateStr;
}
}
示例5: GeneralRevision
function GeneralRevision($http_post_vars, $http_get_vars, $sess)
{
//,$formAction,$totalArchived,$totalCreated,$message,$barang
global $auth;
// this will attempt to count "latest active RPUs" that have NOT undergone general revision for the
// past X number of days from today
$this->countBackDays = 30;
$this->countBackDaysTimeStr = strtotime("-" . $this->countBackDays . " days");
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must be Super-User to access
$pageType = "1%%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->userID = $auth->auth["uid"];
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "GeneralRevision.htm");
$this->tpl->set_var("TITLE", "General Revision");
$this->tpl->set_var("Session", $this->sess->url(""));
$this->formArray = array("formAction" => $http_get_vars["formAction"], "barangayID" => $http_get_vars["barangayID"], "totalArchived" => $http_get_vars["totalArchived"], "totalCreated" => $http_get_vars["totalCreated"], "message" => $http_get_vars["message"], "countBackDays" => $this->countBackDays, "countBackDaysTimeStr" => $this->countBackDaysTimeStr, "progressLog" => $http_get_vars["progressLog"], "timerStart" => $http_get_vars["timerStart"], "timerEnd" => $http_get_vars["timerEnd"]);
foreach ($http_post_vars as $key => $value) {
$this->formArray[$key] = $value;
}
}
示例6: setPageDetailPerms
function setPageDetailPerms()
{
if (!checkPerms($this->user["userType"], "%%%1%%%%%%")) {
// hide Blocks if userType is not at least TM-Edit
$this->hideBlock("TreasuryMaintenanceLink");
} else {
$this->hideBlock("TreasuryMaintenanceLinkText");
}
}
示例7: setPageDetailPerms
function setPageDetailPerms()
{
if (!checkPerms($this->user["userType"], "%1%%%%%%%%")) {
// hide Blocks if userType is not at least AM-Edit
$this->tpl->set_var("ownerViewAccess", "viewOnly");
} else {
$this->tpl->set_var("ownerViewAccess", "view");
}
}
示例8: compileCoffee
function compileCoffee($filename)
{
global $coffee;
// Check if we can write to the javascript file
$jsfile = str_replace('.coffee', '.js', $filename);
if (!checkPerms($jsfile, 'w')) {
die("Can't write to javascript file!");
}
// Compile
$cmd = $coffee . " -c " . escapeshellarg(getcwd() . '/' . $filename);
exec($cmd);
}
示例9: setPageDetailPerms
function setPageDetailPerms()
{
if (!checkPerms($this->user["userType"], "%1%%%%%%%%")) {
// hide Blocks if userType is not at least AM-Edit
$this->hideBlock("SearchAddOwnerPersonLink");
$this->hideBlock("SearchAddOwnerCompanyLink");
$this->hideBlock("PropertyInfoEncodeLink");
$this->tpl->set_var("ownerViewAccess", "viewOnly");
$this->tpl->set_var("removeOwnerDisabled", "disabled");
} else {
$this->tpl->set_var("ownerViewAccess", "view");
$this->tpl->set_var("removeOwnerDisabled", "");
}
}
示例10: RPTREncode
function RPTREncode()
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must have atleast TM-EDIT access
$pageType = "%%%1%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new Template(getcwd());
$this->tpl->set_var("uname", $this->user["uname"]);
$this->tpl->set_var("today", date("F j, Y"));
}
示例11: TransactionsHome
function TransactionsHome($sess)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must have atleast AM-EDIT access
$pageType = "%1%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "TransactionsHome.htm");
$this->tpl->set_var("TITLE", "AM : Transactions");
}
示例12: OwnersList
function OwnersList($sess)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must be Super-User to access
$pageType = "1%%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "OwnerList.htm");
$this->tpl->set_var("TITLE", "Owner List");
}
示例13: RPTOPBatchEncode
function RPTOPBatchEncode($http_post_vars, $formAction = "", $sess)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must have atleast AM-EDIT access
$pageType = "%1%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "RPTOPBatchEncode.htm");
$this->tpl->set_var("TITLE", "Encode RPTOP by Batch");
$this->formArray = array("rptopID" => $rptopID, "rptopNumber" => "", "taxableYear" => "", "cityAssessor" => "", "citytreasurer" => "", "cityAssessorID" => "", "citytreasurerID" => "", "stepNumber" => "01", "limit" => 5, "formAction" => $formAction);
foreach ($http_post_vars as $key => $value) {
$this->formArray[$key] = $value;
}
}
示例14: AssessmentSettingsEncode
function AssessmentSettingsEncode($http_post_vars, $sess, $formAction)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must be Super-User to access
$pageType = "1%%%%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: Unauthorized.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "AssessmentSettingsEncode.htm");
$this->tpl->set_var("TITLE", "Assessment Settings");
$this->formArray = array("formAction" => $formAction, "message" => "");
foreach ($http_post_vars as $key => $value) {
$this->formArray[$key] = $value;
}
}
示例15: PurgeReceipt
function PurgeReceipt($http_post_vars, $formAction = "", $sess)
{
global $auth;
$this->sess = $sess;
$this->user = $auth->auth;
$this->formArray["uid"] = $auth->auth["uid"];
$this->user = $auth->auth;
// must have atleast TM-EDIT access
$pageType = "%%%1%%%%%%";
if (!checkPerms($this->user["userType"], $pageType)) {
header("Location: UnauthorizedPopup.php" . $this->sess->url(""));
exit;
}
$this->tpl = new rpts_Template(getcwd(), "keep");
$this->tpl->set_file("rptsTemplate", "PurgeReceipt.htm");
$this->tpl->set_var("TITLE", "TM : Purge Receipt");
$this->formArray = array("formAction" => $formAction);
foreach ($http_post_vars as $key => $value) {
$this->formArray[$key] = $value;
}
}