Esempio n. 1
0
        lineList($api);
        break;
    case 'regionList':
        regionList($api);
        break;
    case 'ispList':
        ispList($api);
        break;
    case 'statisticsList':
        statisticsList($api);
        break;
    case 'recordList':
        recordList($api);
        break;
    case 'recordAdd':
        recordAdd($api);
        break;
    case 'spareAdd':
        spareAdd($api);
        break;
    case 'recordUpdate':
        recordUpdate($api);
        break;
    case 'recordDelete':
        recordDelete($api);
        break;
    default:
        return false;
}
/**
 * 域名列表 
Esempio n. 2
0
} else {
    $mysqli = $system->get_mysqli();
    if ($system->get_user_id() < 1) {
        $response = $system->addError(HEURIST_REQUEST_DENIED);
    } else {
        $action = @$_REQUEST['a'];
        // || @$_REQUEST['action'];
        // call function from db_record library
        // these function returns standard response: status and data
        // data is recordset (in case success) or message
        if ($action == "a" || $action == "add") {
            $record = array();
            $record['RecTypeID'] = @$_REQUEST['rt'];
            $record['OwnerUGrpID'] = @$_REQUEST['ro'];
            $record['NonOwnerVisibility'] = @$_REQUEST['rv'];
            $response = recordAdd($system, $record);
        } else {
            if ($action == "s" || $action == "save") {
                $response = recordSave($system, $_REQUEST);
            } else {
                if (($action == "d" || $action == "delete") && @$_REQUEST['ids']) {
                    $response = recordDelete($system, $_REQUEST['ids']);
                } else {
                    $response = $system->addError(HEURIST_INVALID_REQUEST);
                }
            }
        }
    }
}
header('Content-type: text/javascript');
print json_encode($response);