<%@ LANGUAGE = JavaScript %>
<% /*
     $Revision$
     $Id$

     File:        prs_inzetbaar_delete.asp
*/ %>
<%
var JSON_Result = true;
%>

<!-- #include file="../Shared/common.inc" -->
<!-- #include file="../Shared/json2.js" -->

<%
protectRequest.validateToken();
/***** Get webform parameters *****/
var kpndisc_key = getFParamInt("kpndisc_key");
var message = "";
/***** End get webform parameters *****/

var autfunction = "WEB_FINMSU";
var authparams = user.checkAutorisation(autfunction);
user.auth_required_or_abort(authparams.PRSwritelevel < 9 && authparams.ALGwritelevel < 9);

// Verwijderdatum van de factuur zetten en niet fysiek verwijderen
var sql = "DELETE prs_kostenplaatsdisc"
        + " WHERE prs_kostenplaatsdisc_key = " + kpndisc_key;

oRs = Oracle.Execute(sql);
result = {success: true};

Response.Write(JSON.stringify(result));
%>