Exemplo n.º 1
0
<?php

include_once '../../../config/symbini.php';
include_once $serverRoot . '/classes/OccurrenceCrowdSource.php';
header("Content-Type: text/html; charset=" . $charset);
$action = array_key_exists('action', $_REQUEST) ? $_REQUEST['action'] : '';
$csManager = new OccurrenceCrowdSource();
$pArr = array();
if ($symbUid) {
    if (array_key_exists("CollAdmin", $userRights)) {
        $pArr = $userRights['CollAdmin'];
    }
}
$statusStr = '';
?>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=<?php 
echo $charset;
?>
">
	<title><?php 
echo $defaultTitle;
?>
 Crowdsourcing Score Board</title>
    <link href="../../../css/base.css?<?php 
echo $CSS_VERSION;
?>
" rel="stylesheet" type="text/css" />
    <link href="../../../css/main.css?<?php 
echo $CSS_VERSION;
Exemplo n.º 2
0
<?php

include_once '../../../config/symbini.php';
include_once $serverRoot . '/classes/OccurrenceCrowdSource.php';
header("Content-Type: text/html; charset=" . $charset);
if (!$symbUid) {
    header('Location: ../../../profile/index.php?refurl=../collections/specprocessor/index.php?tabindex=2&' . $_SERVER['QUERY_STRING']);
}
$collid = array_key_exists('collid', $_REQUEST) ? $_REQUEST['collid'] : 0;
$uid = array_key_exists('uid', $_REQUEST) ? $_REQUEST['uid'] : 0;
$rStatus = array_key_exists('rstatus', $_REQUEST) ? $_REQUEST['rstatus'] : '5,10';
$start = array_key_exists('start', $_REQUEST) ? $_REQUEST['start'] : 0;
$limit = array_key_exists('limit', $_REQUEST) ? $_REQUEST['limit'] : 500;
$action = array_key_exists('action', $_REQUEST) ? $_REQUEST['action'] : '';
$csManager = new OccurrenceCrowdSource();
//If collid is null, it will be assumed that current user wants to review their own specimens (they can still edit pending, closed specimen can't be editted)
$csManager->setCollid($collid);
$isEditor = 0;
if (array_key_exists('CollAdmin', $USER_RIGHTS) && in_array($collid, $USER_RIGHTS['CollAdmin'])) {
    $isEditor = 1;
}
$statusStr = '';
if (array_key_exists('occid', $_POST)) {
    $statusStr = $csManager->submitReviews($_POST);
}
$projArr = $csManager->getProjectDetails();
?>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=<?php 
echo $charset;
Exemplo n.º 3
0
        $specManager->deleteProject($_POST['sppriddel']);
    } elseif ($action == 'Add to Queue') {
        $csManager = new OccurrenceCrowdSource();
        $csManager->setCollid($collid);
        $statusStr = $csManager->addToQueue($_POST['omcsid'], $_POST['family'], $_POST['taxon'], $_POST['country'], $_POST['stateprovince'], $_POST['limit']);
        if (is_numeric($statusStr)) {
            $statusStr .= ' records added to queue';
        }
        $action = '';
    } elseif ($action == 'delqueue') {
        $csManager = new OccurrenceCrowdSource();
        $csManager->setCollid($collid);
        $statusStr = $csManager->deleteQueue($_GET['omcsid']);
    } elseif ($action == 'Edit Crowdsource Project') {
        $omcsid = $_POST['omcsid'];
        $csManager = new OccurrenceCrowdSource();
        $csManager->setCollid($collid);
        $statusStr = $csManager->editProject($omcsid, $_POST['instr'], $_POST['url']);
    }
}
?>
<html>
	<head>
		<title>Specimen Processor Control Panel</title>
		<link href="<?php 
echo $CLIENT_ROOT;
?>
/css/base.css?<?php 
echo $CSS_VERSION;
?>
" type="text/css" rel="stylesheet" />
Exemplo n.º 4
0
<?php

include_once '../../../config/symbini.php';
include_once $serverRoot . '/classes/OccurrenceCrowdSource.php';
header("Content-Type: text/html; charset=" . $charset);
$collid = array_key_exists('collid', $_REQUEST) ? $_REQUEST['collid'] : 0;
$omcsid = array_key_exists('omcsid', $_REQUEST) ? $_REQUEST['omcsid'] : 0;
$csManager = new OccurrenceCrowdSource();
$csManager->setCollid($collid);
if (!$omcsid) {
    $omcsid = $csManager->getOmcsid();
}
$isEditor = 0;
if ($IS_ADMIN) {
    $isEditor = 1;
} elseif ($collid) {
    if (array_key_exists("CollAdmin", $userRights) && in_array($collid, $userRights["CollAdmin"])) {
        $isEditor = 1;
    }
}
$statusStr = '';
$projArr = $csManager->getProjectDetails();
?>
<!-- inner text -->
<div id="innertext" style="background-color:white;">
	<?php 
if ($statusStr) {
    ?>
		<hr/>
		<div style="margin:20px;color:<?php 
    echo substr($statusStr, 0, 5) == 'ERROR' ? 'red' : 'green';