Esempio n. 1
0
function cancelDocument($gid)
{
    global $database;
    $uid = (int) mosGetParam($_REQUEST, "id", "");
    if (!$uid) {
        _returnTo('cat_view', _DML_OP_CANCELED);
    }
    $doc = new mosDMDocument($database);
    $doc->load($uid);
    if ($doc->cancel()) {
        _returnTo('cat_view', _DML_OP_CANCELED, $doc->catid);
    }
    _returnTo('cat_view', _DML_OP_CANCELED);
}
Esempio n. 2
0
function cancelDocument()
{
    $database = JFactory::getDBO();
    $mainframe = JFactory::getApplication();
    $doc = new mosDMDocument($database);
    if ($doc->cancel()) {
        $mainframe->redirect("index.php?option=com_docman&section=documents");
    }
}
function cancelDocument($gid)
{
    $database = JFactory::getDBO();
    $uid = JRequest::getInt('id', 0);
    if (!$uid) {
        _returnTo('cat_view', _DML_OP_CANCELED);
    }
    $doc = new mosDMDocument($database);
    $doc->load($uid);
    if ($doc->cancel()) {
        _returnTo('cat_view', _DML_OP_CANCELED, $doc->catid);
    }
    _returnTo('cat_view', _DML_OP_CANCELED);
}
Esempio n. 4
0
function cancelDocument()
{
    global $database;
    $doc = new mosDMDocument($database);
    if ($doc->cancel()) {
        mosRedirect("index2.php?option=com_docman&section=documents");
    }
}