FSN#36395 Ontmantelen CodeCharge

svn path=/Website/trunk/; revision=29372
This commit is contained in:
Erik Groener
2016-05-12 07:30:48 +00:00
parent 5c9a5dc0b3
commit 37c1ce776c
47 changed files with 0 additions and 12342 deletions

View File

@@ -1,118 +0,0 @@
<%@language = "javascript" %>
<%
/* $Revision$
$Id$
File: BuildExpression.asp
Description: Detailscherm om expressie te bouwen
Parameters: step_key (REQUIRED)
Context:
Note: Modal popup
*/ %>
<!-- #include file="../Shared/common.inc" -->
<!-- #include file="../Shared/iface.inc" -->
<!-- #include file="../mld/mld.inc" -->
<!-- #include file="../mld/mld_flexkenmerk.inc" -->
<%
FCLTHeader.Requires({ plugins: ["jQuery", "suggest"],
js: ["jQuery-ui.js", "modal_kenmerken.js"]
})
var step_key = getQParamInt("step_key");
var sql = "SELECT ms.mld_stdmelding_key,"
+ " md.ins_discipline_key,"
+ " md.ins_srtdiscipline_key"
+ " FROM mld_workflowstep ws,"
+ " mld_stdmelding ms,"
+ " mld_discipline md"
+ " WHERE ws.mld_stdmelding_key = ms.mld_stdmelding_key"
+ " AND md.ins_discipline_key = ms.mld_ins_discipline_key"
+ " AND ws.mld_workflowstep_key = " + step_key;
var oRs = Oracle.Execute(sql);
var srtdisc_key = oRs("ins_srtdiscipline_key").Value;
var disc_key = oRs("ins_discipline_key").Value;
var stdm_key = oRs("mld_stdmelding_key").Value;
oRs.Close()
%>
<html>
<head>
<%
FCLTHeader.Generate();
%>
<script type="text/javascript" >
window.return_data = {};
function quoted_sql(tekst, maxlen) // maxlen is optioneel
{
if (tekst == null)
return "NULL";
if (!maxlen)
maxlen = 4000;
tekst = tekst.replace(/[\x00-\x08\x0B\x0C\x0E-\x1F]+/g, "?");
tekst = tekst.substr(0, maxlen);
return "'" + tekst.replace(/\'/g,"''") + "'"; // " syntax highlight correctie
}
function preview ()
{
$("#sample").html(expr_text());
FcltMgr.resized();
}
$(function () { $("input,select").change(preview); });
function expr_text()
{
var sqlarr = [];
var aantal_kenm = $("#k_all").val();
// Ingevulde waarden van de kenmerken bewaren.
// TODO: getKenmerkSql hier inzetten?
for (var n = 1; n <= aantal_kenm; n++)
{
var kw = new kenmerkValues(n);
if (typeof kw.val == 'number')
kw.val = String(kw.val);
var keyname = ":flex" + kw.key;
if (kw.op == 'IS NOT NULL' || kw.op == 'IS NULL')
sqlarr.push(keyname + " " + kw.op)
else if (kw.val && kw.typ != "R" && kw.typ != "S")
{
if (kw.op == 'LIKE' || kw.op == 'NOT LIKE')
sqlarr.push("UPPER(" + keyname + ") " + kw.op + " " + quoted_sql(kw.val.toUpperCase()))
else
sqlarr.push(keyname + " " + kw.op + " " + quoted_sql(kw.val))
}
else if (kw.val != '-1' && kw.val != '' && (kw.typ == "R" || kw.typ == "S"))
sqlarr.push(keyname + " " + kw.op + " " + quoted_sql(kw.val));
}
return sqlarr.join(" AND ");
}
function expr_submit()
{
window.return_data.org_data = FcltMgr.dialogArguments();
window.return_data.expression = expr_text();
FcltMgr.closeDetail(window, return_data);
}
</script>
</head>
<body class="modal" id="mod_wfexpression" >
<form id="wf" name="wf" method="post">
<%
generateFlexKenmerkBlock({ stdm_arr : [stdm_key],
disc_arr : [disc_key],
srtdisc : [srtdisc_key], // Srtdiscipline/Soort melding
flexcolumns : 1,
closing : 1,
advanced : true,
wfbuilder : true
});
var buttons = [ {title: L("lcl_submit"), icon: "opslaan.png", action: "expr_submit()" },
{title: L("lcl_cancel"), icon: "undo.png", action: "FcltMgr.closeDetail( window )" }];
CreateButtons(buttons);
%></form>
<div id='sample'></div>
</body>
</html>

View File

@@ -1,658 +0,0 @@
// ===================================================================
// Author: Matt Kruse <matt@mattkruse.com>
// WWW: http://www.mattkruse.com/
//
// NOTICE: You may use this code for any purpose, commercial or
// private, without any further permission from the author. You may
// remove this notice from your final code if you wish, however it is
// appreciated by the author if at least my web site address is kept.
//
// You may *NOT* re-distribute this code in any way except through its
// use. That means, you can include it in your product, or your web
// site, or any other form where the code is actually being used. You
// may not put the plain javascript up on your site for download or
// include it in your javascript libraries for download.
// If you wish to share this code with others, please just point them
// to the URL instead.
// Please DO NOT link directly to my .js files from your site. Copy
// the files to your server and use them there. Thank you.
// ===================================================================
/* SOURCE FILE: AnchorPosition.js */
/*
AnchorPosition.js
Author: Matt Kruse
Last modified: 10/11/02
DESCRIPTION: These functions find the position of an <A> tag in a document,
so other elements can be positioned relative to it.
COMPATABILITY: Netscape 4.x,6.x,Mozilla, IE 5.x,6.x on Windows. Some small
positioning errors - usually with Window positioning - occur on the
Macintosh platform.
FUNCTIONS:
getAnchorPosition(anchorname)
Returns an Object() having .x and .y properties of the pixel coordinates
of the upper-left corner of the anchor. Position is relative to the PAGE.
getAnchorWindowPosition(anchorname)
Returns an Object() having .x and .y properties of the pixel coordinates
of the upper-left corner of the anchor, relative to the WHOLE SCREEN.
NOTES:
1) For popping up separate browser windows, use getAnchorWindowPosition.
Otherwise, use getAnchorPosition
2) Your anchor tag MUST contain both NAME and ID attributes which are the
same. For example:
<A NAME="test" ID="test"> </A>
3) There must be at least a space between <A> </A> for IE5.5 to see the
anchor tag correctly. Do not do <A></A> with no space.
*/
// getAnchorPosition(anchorname)
// This function returns an object having .x and .y properties which are the coordinates
// of the named anchor, relative to the page.
function getAnchorPosition(anchorname) {
// This function will return an Object with x and y properties
var useWindow=false;
var coordinates=new Object();
var x=0,y=0;
// Browser capability sniffing
var use_gebi=false, use_css=false, use_layers=false;
if (document.getElementById) { use_gebi=true; }
else if (document.getElementById) { use_css=true; }
else if (document.layers) { use_layers=true; }
// Logic to find position
if (use_gebi && document.getElementById) {
x=AnchorPosition_getPageOffsetLeft(document.getElementById(anchorname));
y=AnchorPosition_getPageOffsetTop(document.getElementById(anchorname));
}
else if (use_gebi) {
var o=document.getElementById(anchorname);
x=AnchorPosition_getPageOffsetLeft(o);
y=AnchorPosition_getPageOffsetTop(o);
}
else if (use_css) {
x=AnchorPosition_getPageOffsetLeft(document.getElementById(anchorname));
y=AnchorPosition_getPageOffsetTop(document.getElementById(anchorname));
}
else if (use_layers) {
var found=0;
for (var i=0; i<document.anchors.length; i++) {
if (document.anchors[i].name==anchorname) { found=1; break; }
}
if (found==0) {
coordinates.x=0; coordinates.y=0; return coordinates;
}
x=document.anchors[i].x;
y=document.anchors[i].y;
}
else {
coordinates.x=0; coordinates.y=0; return coordinates;
}
coordinates.x=x;
coordinates.y=y;
return coordinates;
}
// getAnchorWindowPosition(anchorname)
// This function returns an object having .x and .y properties which are the coordinates
// of the named anchor, relative to the window
function getAnchorWindowPosition(anchorname) {
var coordinates=getAnchorPosition(anchorname);
var x=0;
var y=0;
if (document.getElementById) {
if (isNaN(window.screenX)) {
x=coordinates.x-document.body.scrollLeft+window.screenLeft;
y=coordinates.y-document.body.scrollTop+window.screenTop;
}
else {
x=coordinates.x+window.screenX+(window.outerWidth-window.innerWidth)-window.pageXOffset;
y=coordinates.y+window.screenY+(window.outerHeight-24-window.innerHeight)-window.pageYOffset;
}
}
else if (document.getElementById) {
x=coordinates.x-document.body.scrollLeft+window.screenLeft;
y=coordinates.y-document.body.scrollTop+window.screenTop;
}
else if (document.layers) {
x=coordinates.x+window.screenX+(window.outerWidth-window.innerWidth)-window.pageXOffset;
y=coordinates.y+window.screenY+(window.outerHeight-24-window.innerHeight)-window.pageYOffset;
}
coordinates.x=x;
coordinates.y=y;
return coordinates;
}
// Functions for IE to get position of an object
function AnchorPosition_getPageOffsetLeft (el) {
var ol=el.offsetLeft;
while ((el=el.offsetParent) != null) { ol += el.offsetLeft; }
return ol;
}
function AnchorPosition_getWindowOffsetLeft (el) {
return AnchorPosition_getPageOffsetLeft(el)-document.body.scrollLeft;
}
function AnchorPosition_getPageOffsetTop (el) {
var ot=el.offsetTop;
while((el=el.offsetParent) != null) { ot += el.offsetTop; }
return ot;
}
function AnchorPosition_getWindowOffsetTop (el) {
return AnchorPosition_getPageOffsetTop(el)-document.body.scrollTop;
}
/* SOURCE FILE: PopupWindow.js */
/*
PopupWindow.js
Author: Matt Kruse
Last modified: 02/16/04
DESCRIPTION: This object allows you to easily and quickly popup a window
in a certain place. The window can either be a DIV or a separate browser
window.
COMPATABILITY: Works with Netscape 4.x, 6.x, IE 5.x on Windows. Some small
positioning errors - usually with Window positioning - occur on the
Macintosh platform. Due to bugs in Netscape 4.x, populating the popup
window with <STYLE> tags may cause errors.
USAGE:
// Create an object for a WINDOW popup
var win = new PopupWindow();
// Create an object for a DIV window using the DIV named 'mydiv'
var win = new PopupWindow('mydiv');
// Set the window to automatically hide itself when the user clicks
// anywhere else on the page except the popup
win.autoHide();
// Show the window relative to the anchor name passed in
win.showPopup(anchorname);
// Hide the popup
win.hidePopup();
// Set the size of the popup window (only applies to WINDOW popups
win.setSize(width,height);
// Populate the contents of the popup window that will be shown. If you
// change the contents while it is displayed, you will need to refresh()
win.populate(string);
// set the URL of the window, rather than populating its contents
// manually
win.setUrl("http://www.site.com/");
// Refresh the contents of the popup
win.refresh();
// Specify how many pixels to the right of the anchor the popup will appear
win.offsetX = 50;
// Specify how many pixels below the anchor the popup will appear
win.offsetY = 100;
NOTES:
1) Requires the functions in AnchorPosition.js
2) Your anchor tag MUST contain both NAME and ID attributes which are the
same. For example:
<A NAME="test" ID="test"> </A>
3) There must be at least a space between <A> </A> for IE5.5 to see the
anchor tag correctly. Do not do <A></A> with no space.
4) When a PopupWindow object is created, a handler for 'onmouseup' is
attached to any event handler you may have already defined. Do NOT define
an event handler for 'onmouseup' after you define a PopupWindow object or
the autoHide() will not work correctly.
*/
// Set the position of the popup window based on the anchor
function PopupWindow_getXYPosition(anchorname) {
var coordinates;
if (this.type == "WINDOW") {
coordinates = getAnchorWindowPosition(anchorname);
}
else {
coordinates = getAnchorPosition(anchorname);
}
this.x = coordinates.x;
this.y = coordinates.y;
}
// Set width/height of DIV/popup window
function PopupWindow_setSize(width,height) {
this.width = width;
this.height = height;
}
// Fill the window with contents
function PopupWindow_populate(contents) {
this.contents = contents;
this.populated = false;
}
// Set the URL to go to
function PopupWindow_setUrl(url) {
this.url = url;
}
// Set the window popup properties
function PopupWindow_setWindowProperties(props) {
this.windowProperties = props;
}
// Refresh the displayed contents of the popup
function PopupWindow_refresh() {
if (this.divName != null) {
// refresh the DIV object
if (this.use_gebi) {
document.getElementById(this.divName).innerHTML = this.contents;
}
else if (this.use_css) {
document.getElementById(this.divName).innerHTML = this.contents;
}
else if (this.use_layers) {
var d = document.layers[this.divName];
d.document.open();
d.document.writeln(this.contents);
d.document.close();
}
}
else {
if (this.popupWindow != null && !this.popupWindow.closed) {
if (this.url!="") {
this.popupWindow.location.href=this.url;
}
else {
this.popupWindow.document.open();
this.popupWindow.document.writeln(this.contents);
this.popupWindow.document.close();
}
this.popupWindow.focus();
}
}
}
// Position and show the popup, relative to an anchor object
function PopupWindow_showPopup(anchorname) {
this.getXYPosition(anchorname);
this.x += this.offsetX;
this.y += this.offsetY;
if (!this.populated && (this.contents != "")) {
this.populated = true;
this.refresh();
}
if (this.divName != null) {
// Show the DIV object
if (this.use_gebi) {
document.getElementById(this.divName).style.left = this.x + "px";
document.getElementById(this.divName).style.top = this.y;
document.getElementById(this.divName).style.visibility = "visible";
}
else if (this.use_css) {
document.getElementById(this.divName).style.left = this.x;
document.getElementById(this.divName).style.top = this.y;
document.getElementById(this.divName).style.visibility = "visible";
}
else if (this.use_layers) {
document.layers[this.divName].left = this.x;
document.layers[this.divName].top = this.y;
document.layers[this.divName].visibility = "visible";
}
}
else {
if (this.popupWindow == null || this.popupWindow.closed) {
// If the popup window will go off-screen, move it so it doesn't
if (this.x<0) { this.x=0; }
if (this.y<0) { this.y=0; }
if (screen && screen.availHeight) {
if ((this.y + this.height) > screen.availHeight) {
this.y = screen.availHeight - this.height;
}
}
if (screen && screen.availWidth) {
if ((this.x + this.width) > screen.availWidth) {
this.x = screen.availWidth - this.width;
}
}
var avoidAboutBlank = window.opera || ( document.layers && !navigator.mimeTypes['*'] ) || navigator.vendor == 'KDE' || ( document.childNodes && !document.getElementById && !navigator.taintEnabled );
this.popupWindow = window.open(avoidAboutBlank?"":"about:blank","window_"+anchorname,this.windowProperties+",width="+this.width+",height="+this.height+",screenX="+this.x+",left="+this.x+",screenY="+this.y+",top="+this.y+"");
}
this.refresh();
}
}
// Hide the popup
function PopupWindow_hidePopup() {
if (this.divName != null) {
if (this.use_gebi) {
document.getElementById(this.divName).style.visibility = "hidden";
}
else if (this.use_css) {
document.getElementById(this.divName).style.visibility = "hidden";
}
else if (this.use_layers) {
document.layers[this.divName].visibility = "hidden";
}
}
else {
if (this.popupWindow && !this.popupWindow.closed) {
this.popupWindow.close();
this.popupWindow = null;
}
}
}
// Pass an event and return whether or not it was the popup DIV that was clicked
function PopupWindow_isClicked(e) {
if (this.divName != null) {
if (this.use_layers) {
var clickX = e.pageX;
var clickY = e.pageY;
var t = document.layers[this.divName];
if ((clickX > t.left) && (clickX < t.left+t.clip.width) && (clickY > t.top) && (clickY < t.top+t.clip.height)) {
return true;
}
else { return false; }
}
else if (document.getElementById) { // Need to hard-code this to trap IE for error-handling
var t = window.event.srcElement;
while (t.parentElement != null) {
if (t.id==this.divName) {
return true;
}
t = t.parentElement;
}
return false;
}
else if (this.use_gebi && e) {
var t = e.originalTarget;
while (t.parentNode != null) {
if (t.id==this.divName) {
return true;
}
t = t.parentNode;
}
return false;
}
return false;
}
return false;
}
// Check an onMouseDown event to see if we should hide
function PopupWindow_hideIfNotClicked(e) {
if (this.autoHideEnabled && !this.isClicked(e)) {
this.hidePopup();
}
}
// Call this to make the DIV disable automatically when mouse is clicked outside it
function PopupWindow_autoHide() {
this.autoHideEnabled = true;
}
// This global function checks all PopupWindow objects onmouseup to see if they should be hidden
function PopupWindow_hidePopupWindows(e) {
for (var i=0; i<popupWindowObjects.length; i++) {
if (popupWindowObjects[i] != null) {
var p = popupWindowObjects[i];
p.hideIfNotClicked(e);
}
}
}
// Run this immediately to attach the event listener
function PopupWindow_attachListener() {
if (document.layers) {
document.captureEvents(Event.MOUSEUP);
}
window.popupWindowOldEventListener = document.onmouseup;
if (window.popupWindowOldEventListener != null) {
document.onmouseup = new Function("window.popupWindowOldEventListener(); PopupWindow_hidePopupWindows();");
}
else {
document.onmouseup = PopupWindow_hidePopupWindows;
}
}
// CONSTRUCTOR for the PopupWindow object
// Pass it a DIV name to use a DHTML popup, otherwise will default to window popup
function PopupWindow() {
if (!window.popupWindowIndex) { window.popupWindowIndex = 0; }
if (!window.popupWindowObjects) { window.popupWindowObjects = new Array(); }
if (!window.listenerAttached) {
window.listenerAttached = true;
PopupWindow_attachListener();
}
this.index = popupWindowIndex++;
popupWindowObjects[this.index] = this;
this.divName = null;
this.popupWindow = null;
this.width=0;
this.height=0;
this.populated = false;
this.visible = false;
this.autoHideEnabled = false;
this.contents = "";
this.url="";
this.windowProperties="toolbar=no,location=no,status=no,menubar=no,scrollbars=auto,resizable,alwaysRaised,dependent,titlebar=no";
if (arguments.length>0) {
this.type="DIV";
this.divName = arguments[0];
}
else {
this.type="WINDOW";
}
this.use_gebi = false;
this.use_css = false;
this.use_layers = false;
if (document.getElementById) { this.use_gebi = true; }
else if (document.getElementById) { this.use_css = true; }
else if (document.layers) { this.use_layers = true; }
else { this.type = "WINDOW"; }
this.offsetX = 0;
this.offsetY = 0;
// Method mappings
this.getXYPosition = PopupWindow_getXYPosition;
this.populate = PopupWindow_populate;
this.setUrl = PopupWindow_setUrl;
this.setWindowProperties = PopupWindow_setWindowProperties;
this.refresh = PopupWindow_refresh;
this.showPopup = PopupWindow_showPopup;
this.hidePopup = PopupWindow_hidePopup;
this.setSize = PopupWindow_setSize;
this.isClicked = PopupWindow_isClicked;
this.autoHide = PopupWindow_autoHide;
this.hideIfNotClicked = PopupWindow_hideIfNotClicked;
}
/* SOURCE FILE: ColorPicker2.js */
/*
Last modified: 02/24/2003
DESCRIPTION: This widget is used to select a color, in hexadecimal #RRGGBB
form. It uses a color "swatch" to display the standard 216-color web-safe
palette. The user can then click on a color to select it.
COMPATABILITY: See notes in AnchorPosition.js and PopupWindow.js.
Only the latest DHTML-capable browsers will show the color and hex values
at the bottom as your mouse goes over them.
USAGE:
// Create a new ColorPicker object using DHTML popup
var cp = new ColorPicker();
// Create a new ColorPicker object using Window Popup
var cp = new ColorPicker('window');
// Add a link in your page to trigger the popup. For example:
<A HREF="#" onClick="cp.show('pick');return false;" NAME="pick" ID="pick">Pick</A>
// Or use the built-in "select" function to do the dirty work for you:
<A HREF="#" onClick="cp.select(document.forms[0].color,'pick');return false;" NAME="pick" ID="pick">Pick</A>
// If using DHTML popup, write out the required DIV tag near the bottom
// of your page.
<SCRIPT LANGUAGE="JavaScript">cp.writeDiv()</SCRIPT>
// Write the 'pickColor' function that will be called when the user clicks
// a color and do something with the value. This is only required if you
// want to do something other than simply populate a form field, which is
// what the 'select' function will give you.
function pickColor(color) {
field.value = color;
}
NOTES:
1) Requires the functions in AnchorPosition.js and PopupWindow.js
2) Your anchor tag MUST contain both NAME and ID attributes which are the
same. For example:
<A NAME="test" ID="test"> </A>
3) There must be at least a space between <A> </A> for IE5.5 to see the
anchor tag correctly. Do not do <A></A> with no space.
4) When a ColorPicker object is created, a handler for 'onmouseup' is
attached to any event handler you may have already defined. Do NOT define
an event handler for 'onmouseup' after you define a ColorPicker object or
the color picker will not hide itself correctly.
*/
ColorPicker_targetInput = null;
function ColorPicker_writeDiv() {
document.writeln("<DIV ID=\"colorPickerDiv\" STYLE=\"position:absolute;visibility:hidden;\"> </DIV>");
}
function ColorPicker_show(anchorname) {
this.showPopup(anchorname);
}
function ColorPicker_pickColor(color,obj) {
obj.hidePopup();
pickColor(color);
}
// A Default "pickColor" function to accept the color passed back from popup.
// User can over-ride this with their own function.
function pickColor(color) {
if (ColorPicker_targetInput==null) {
alert("Target Input is null, which means you either didn't use the 'select' function or you have no defined your own 'pickColor' function to handle the picked color!");
return;
}
ColorPicker_targetInput.value = color;
}
// This function is the easiest way to popup the window, select a color, and
// have the value populate a form field, which is what most people want to do.
function ColorPicker_select(inputobj,linkname) {
if (inputobj.type!="text" && inputobj.type!="hidden" && inputobj.type!="textarea") {
alert("colorpicker.select: Input object passed is not a valid form input object");
window.ColorPicker_targetInput=null;
return;
}
window.ColorPicker_targetInput = inputobj;
this.show(linkname);
}
// This function runs when you move your mouse over a color block, if you have a newer browser
function ColorPicker_highlightColor(c) {
var thedoc = (arguments.length>1)?arguments[1]:window.document;
var d = thedoc.getElementById("colorPickerSelectedColor");
d.style.backgroundColor = c;
d = thedoc.getElementById("colorPickerSelectedColorValue");
d.innerHTML = c;
}
function ColorPicker() {
var windowMode = false;
// Create a new PopupWindow object
if (arguments.length==0) {
var divname = "colorPickerDiv";
}
else if (arguments[0] == "window") {
var divname = '';
windowMode = true;
}
else {
var divname = arguments[0];
}
if (divname != "") {
var cp = new PopupWindow(divname);
}
else {
var cp = new PopupWindow();
cp.setSize(225,250);
}
// Object variables
cp.currentValue = "#FFFFFF";
// Method Mappings
cp.writeDiv = ColorPicker_writeDiv;
cp.highlightColor = ColorPicker_highlightColor;
cp.show = ColorPicker_show;
cp.select = ColorPicker_select;
// Code to populate color picker window
var colors = new Array("#000000","#000033","#000066","#000099","#0000CC","#0000FF","#330000","#330033","#330066","#330099","#3300CC",
"#3300FF","#660000","#660033","#660066","#660099","#6600CC","#6600FF","#990000","#990033","#990066","#990099",
"#9900CC","#9900FF","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#FF0000","#FF0033","#FF0066",
"#FF0099","#FF00CC","#FF00FF","#003300","#003333","#003366","#003399","#0033CC","#0033FF","#333300","#333333",
"#333366","#333399","#3333CC","#3333FF","#663300","#663333","#663366","#663399","#6633CC","#6633FF","#993300",
"#993333","#993366","#993399","#9933CC","#9933FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF",
"#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#006600","#006633","#006666","#006699","#0066CC",
"#0066FF","#336600","#336633","#336666","#336699","#3366CC","#3366FF","#666600","#666633","#666666","#666699",
"#6666CC","#6666FF","#996600","#996633","#996666","#996699","#9966CC","#9966FF","#CC6600","#CC6633","#CC6666",
"#CC6699","#CC66CC","#CC66FF","#FF6600","#FF6633","#FF6666","#FF6699","#FF66CC","#FF66FF","#009900","#009933",
"#009966","#009999","#0099CC","#0099FF","#339900","#339933","#339966","#339999","#3399CC","#3399FF","#669900",
"#669933","#669966","#669999","#6699CC","#6699FF","#999900","#999933","#999966","#999999","#9999CC","#9999FF",
"#CC9900","#CC9933","#CC9966","#CC9999","#CC99CC","#CC99FF","#FF9900","#FF9933","#FF9966","#FF9999","#FF99CC",
"#FF99FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#33CC00","#33CC33","#33CC66","#33CC99",
"#33CCCC","#33CCFF","#66CC00","#66CC33","#66CC66","#66CC99","#66CCCC","#66CCFF","#99CC00","#99CC33","#99CC66",
"#99CC99","#99CCCC","#99CCFF","#CCCC00","#CCCC33","#CCCC66","#CCCC99","#CCCCCC","#CCCCFF","#FFCC00","#FFCC33",
"#FFCC66","#FFCC99","#FFCCCC","#FFCCFF","#00FF00","#00FF33","#00FF66","#00FF99","#00FFCC","#00FFFF","#33FF00",
"#33FF33","#33FF66","#33FF99","#33FFCC","#33FFFF","#66FF00","#66FF33","#66FF66","#66FF99","#66FFCC","#66FFFF",
"#99FF00","#99FF33","#99FF66","#99FF99","#99FFCC","#99FFFF","#CCFF00","#CCFF33","#CCFF66","#CCFF99","#CCFFCC",
"#CCFFFF","#FFFF00","#FFFF33","#FFFF66","#FFFF99","#FFFFCC","#FFFFFF");
var total = colors.length;
var width = 18;
var cp_contents = "";
var windowRef = (windowMode)?"window.opener.":"";
if (windowMode) {
cp_contents += "<HTML><HEAD><TITLE>Select Color</TITLE></HEAD>";
cp_contents += "<BODY MARGINWIDTH=0 MARGINHEIGHT=0 LEFTMARGIN=0 TOPMARGIN=0><CENTER>";
}
cp_contents += "<TABLE BORDER=1 CELLSPACING=1 CELLPADDING=0>";
var use_highlight = (document.getElementById)?true:false;
for (var i=0; i<total; i++) {
if ((i % width) == 0) { cp_contents += "<TR>"; }
if (use_highlight) { var mo = 'onMouseOver="'+windowRef+'ColorPicker_highlightColor(\''+colors[i]+'\',window.document)"'; }
else { mo = ""; }
cp_contents += '<TD BGCOLOR="'+colors[i]+'"><FONT SIZE="-3"><A HREF="#" onClick="'+windowRef+'ColorPicker_pickColor(\''+colors[i]+'\','+windowRef+'window.popupWindowObjects['+cp.index+']);return false;" '+mo+' STYLE="text-decoration:none;">&nbsp;&nbsp;&nbsp;</A></FONT></TD>';
if ( ((i+1)>=total) || (((i+1) % width) == 0)) {
cp_contents += "</TR>";
}
}
// If the browser supports dynamically changing TD cells, add the fancy stuff
if (document.getElementById) {
var width1 = Math.floor(width/2);
var width2 = width = width1;
cp_contents += "<TR><TD COLSPAN='"+width1+"' BGCOLOR='#ffffff' ID='colorPickerSelectedColor'>&nbsp;</TD><TD COLSPAN='"+width2+"' ALIGN='CENTER' ID='colorPickerSelectedColorValue'>#FFFFFF</TD></TR>";
}
cp_contents += "</TABLE>";
if (windowMode) {
cp_contents += "</CENTER></BODY></HTML>";
}
// end populate code
// Write the contents to the popup object
cp.populate(cp_contents+"\n");
// Move the table down a bit so you can see it
cp.offsetY = 25;
cp.autoHide();
return cp;
}

View File

@@ -1,227 +0,0 @@
<!-- #INCLUDE FILE="adovbs.inc" -->
<!-- #INCLUDE FILE="TemplateObj.asp" -->
<%
'
' Filename: Common.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'===============================
' Database Connection Definition
'-------------------------------
' Facilitor Beheer & Onderhoud Connection begin
Dim cn : Set cn = Server.CreateObject("ADODB.Connection")
'-------------------------------
' Create database connection string, login and password variables
'-------------------------------
Dim strConn, strLogin, strPassword
strConn = "File Name="+myUDLPath() + ""
strLogin = ""
strPassword = ""
'-------------------------------
' Open the connection
'-------------------------------
cn.open strConn, strLogin, strPassword
'-------------------------------
' Facilitor Beheer & Onderhoud Connection end
'-------------------------------
' Create forward only recordset using current database and passed SQL statement
'-------------------------------
sub openrs(rs, sql)
Set rs = Server.CreateObject("ADODB.Recordset")
rs.CursorLocation = adUseServer
rs.Open sql, cn, adOpenForwardOnly, adLockReadOnly, adCmdText
end sub
'-------------------------------
' Create static only recordset using current database and passed SQL statement
'-------------------------------
sub openStaticRS(rs, sql)
Set rs = Server.CreateObject("ADODB.Recordset")
rs.CursorLocation = adUseServer
rs.Open sql, cn, adOpenStatic, adLockReadOnly, adCmdText
end sub
'===============================
'===============================
' Site Initialization
'-------------------------------
' Specify Debug mode (true/false)
Dim bDebug : bDebug = false
'-------------------------------
' Obtain the path where this site is located on the server
'-------------------------------
Dim sAppPath : sAppPath = left(Request("PATH_TRANSLATED"), instrrev(Request("PATH_TRANSLATED"), "\"))
'===============================
'===============================
' Common functions
'-------------------------------
' Convert non-standard characters to HTML
'-------------------------------
function ToHTML(strValue)
if IsNull(strValue) then
ToHTML = ""
else
ToHTML = Server.HTMLEncode(strValue)
end if
end function
'-------------------------------
' Convert value to URL
'-------------------------------
function ToURL(strValue)
if IsNull(strValue) then strValue = ""
ToURL = Server.URLEncode(strValue)
end function
'-------------------------------
' Obtain HTML value of a field
'-------------------------------
function GetValueHTML(rs, strFieldName)
GetValueHTML = ToHTML(GetValue(rs, strFieldName))
end function
'-------------------------------
' Obtain database field value
'-------------------------------
function GetValue(rs, strFieldName)
on error resume next
if rs is nothing then
GetValue = ""
elseif (not rs.EOF) and (strFieldName <> "") then
res = rs(strFieldName)
if isnull(res) then
res = ""
end if
if VarType(res) = vbBoolean then
if res then res = "1" else res = "0"
end if
GetValue = res
else
GetValue = ""
end if
if bDebug then response.write err.Description
on error goto 0
end function
'-------------------------------
' Obtain specific URL Parameter from URL string
'-------------------------------
function GetParam(ParamName)
if Request.QueryString(ParamName).Count > 0 then
Param = Request.QueryString(ParamName)
elseif Request.Form(ParamName).Count > 0 then
Param = Request.Form(ParamName)
else
Param = ""
end if
if Param = "" then
GetParam = Empty
else
GetParam = Param
end if
end function
'-------------------------------
' Convert value for use with SQL statament
'-------------------------------
Function ToSQL(Value, sType)
Dim Param : Param = Value
if Param = "" then
ToSQL = "Null"
else
if sType = "Number" then
ToSQL = replace(CDbl(Param), ",", ".")
else
ToSQL = "'" & Replace(Param, "'", "''") & "'"
end if
end if
end function
'-------------------------------
' Lookup field in the database based on provided criteria
' Input: Table (Table), Field Name (fName), criteria (sWhere)
'-------------------------------
function DLookUp(Table, fName, sWhere)
on error resume next
Dim Res : Res = cn.execute("select " & fName & " from " & Table & " where " & sWhere).Fields(0).Value
if IsNull(Res) then Res = ""
DLookUp = Res
if bDebug then response.write err.Description
on error goto 0
end function
'-------------------------------
' Obtain Checkbox value depending on field type
'-------------------------------
function getCheckBoxValue(sVal, CheckedValue, UnCheckedValue, sType)
if isempty(sVal) then
if UnCheckedValue = "" then
getCheckBoxValue = "Null"
else
if sType = "Number" then
getCheckBoxValue = UnCheckedValue
else
getCheckBoxValue = "'" & Replace(UnCheckedValue, "'", "''") & "'"
end if
end if
else
if CheckedValue = "" then
getCheckBoxValue = "Null"
else
if sType = "Number" then
getCheckBoxValue = CheckedValue
else
getCheckBoxValue = "'" & Replace(CheckedValue, "'", "''") & "'"
end if
end if
end if
end function
'-------------------------------
' Obtain lookup value from array containing List Of Values
'-------------------------------
function getValFromLOV(sVal, aArr)
Dim i
Dim sRes : sRes = ""
if (ubound(aArr) mod 2) = 1 then
for i = 0 to ubound(aArr) step 2
if cstr(sVal) = cstr(aArr(i)) then sRes = aArr(i+1)
next
end if
getValFromLOV = sRes
end function
'-------------------------------
' Process Errors
'-------------------------------
function ProcessError()
if cn.Errors.Count > 0 then
ProcessError = cn.Errors(0).Description & " (" & cn.Errors(0).Source & ")"
elseif not (Err.Description = "") then
ProcessError = Err.Description
else
ProcessError = ""
end if
end Function
'-------------------------------
' Verify user's security level and redirect to login page if needed
'-------------------------------
function CheckSecurity()
if Session("UserID") = "" then
cn.Close
Set cn = Nothing
response.redirect("Login.asp?querystring=" & toURL(request.serverVariables("QUERY_STRING")) & "&ret_page=" & toURL(request.serverVariables("SCRIPT_NAME")))
End if
end function
'===============================
'===============================
' GlobalFuncs begin
%><!-- #INCLUDE FILE="FACMGTTools.asp" --><%
' GlobalFuncs end
'===============================
%>

View File

@@ -1,889 +0,0 @@
<%
' $Revision$
' $Id$
'
' File: Facmgttools.asp
' Description: Hulp functies voor Facmgt
' Parameters:
' Context: Via common.asp geinclude in elk Facmgt bestand
' Note: Controleert of je wel ingelogd bent.
jqueryver = "jquery-1.11.3" // Zie fac.header.inc
%>
<!-- #INCLUDE FILE="VBlogger.inc" -->
<%
'===============================
' GlobalFuncs begin
' Deze worden geinclude vanuit common.asp en zijn daarmee overal
' beschikbaar
dim str_concat, to_date_f, sysdate, fnToChar, fnNVL, user_key
g_sql_prefix = "##SQL##"
' ====================================================================
If IsEmpty(Session("customerId")) Or IsEmpty(Session("user_key")) Then ' ASP-Sessie verlopen.
Response.Redirect("../shared/expired.asp")
End If
user_key = CLng(Session("user_key"))
if Not user_key > 0 Then
Response.Redirect("../../")
End If
' Oke, we zijn in ieder geval ingelogd.
If Request.Servervariables("HTTP_FCLT_VERSION").Count > 0 Then
' wordt opgepikt door FCLTAPI.DLL voor in de logging en daarna gestript. Niet in Fiddler te zien dus
Response.AddHeader "FCLT_USERID", Session("customerId") & "\" & user_key
End If
' Zoek ons bestand terug in het menu en test de rechten daarvan
dim strPath
strPath = Request.Servervariables("SCRIPT_NAME")
arrNames = Split(strPath, "/")
strPath = arrNames(Ubound(arrNames))
' xxxrecord.asp zit nooit in het menu. Maak er xxxgrid.asp van.
if Right(strPath, 10) = "record.asp" Then
strPath = Left(strPath, Len(strPath)-10) & "grid.asp"
End If
'Response.Write strPath
'Response.End
sql = "SELECT fac_functie_key" & _
" FROM fac_v_menu" & _
" WHERE UPPER(url) LIKE '%"&UCase(replace(strPath, "'", "''"))&"%'"
openrs rsFun, sql
if rsFun.EOF Then
' is dit erg?
Else
if isnull(rsFun("fac_functie_key").Value) Then
INTERNAL_ERROR_FACMGT_ZONDER_FACFUNCTIE
End If
sql = "SELECT 1 FROM fac_v_webgebruiker" & _
" WHERE prs_perslid_key = " & user_key & _
" AND fac_functie_key = " & rsFun("fac_functie_key").Value & _
" AND fac_gebruiker_prs_level_write < 9" & _
" AND fac_gebruiker_alg_level_write < 9"
openrs rsRechten, sql
if rsRechten.Eof Then
Response.Write("Not Authorized")
Response.End
End If
End If
' Simpele versie van de JavaScript functie:
' *Eist* schrijfrechten op autfunction
Sub checkAutorisation(autfunction)
sql = "SELECT * FROM fac_v_webgebruiker fvw, fac_functie ff" & _
" WHERE fvw.prs_perslid_key = " & user_key & _
" AND ff.fac_functie_code = '" & autfunction & "'" & _
" AND fvw.fac_functie_key = ff.fac_functie_key" & _
" AND fvw.fac_gebruiker_prs_level_write < 9" & _
" AND fvw.fac_gebruiker_alg_level_write < 9"
openrs rsRechten, sql
if rsRechten.Eof Then
Response.Write("Not Authorized")
Response.End
End If
End Sub
' ====================================================================
Function protectQS(url)
Dim pqs
Set pqs = GetObject("script:"&Server.MapPath("../shared/protectQS.wsc"))
protectQS = pqs.create(url, ""&Application(Session("customerId") + "_protectsecret"), user_key, Server.MapPath("../shared/sha1.wsc"))
End Function
' ====================================================================
' AntiForgeryToken
sFormAction = GetParam("FormAction")
sFName = Request.Servervariables("SCRIPT_NAME")
arrFNames = Split(sFName, "/")
sFName = arrNames(Ubound(arrFNames))
useToken = True
' Bij ...grid.asp bestanden niet een cookie aanmaken en controleren (bij ...record?.asp bestanden wel)
if Right(sFName, 8) = "grid.asp" Then
useToken = False
End If
sFName = Replace(sFName, ".", "")
sFName = Replace(sFName, "_", "")
Sub validateAntiForgeryToken()
sVerificationToken = GetParam("__RequestVerificationToken")
sCookieToken = Session("ASPFIXATION")
' Response.Write("sVerificationToken = " & sVerificationToken)
' Response.Write("sCookieToken = " & sCookieToken)
' // De token van het hidden inputveld valideren met de ASPFIXATION cookie
if sVerificationToken <> sCookieToken Then
Response.Write("Authentification Error: The input process was possibly to slow. Try again")
Response.End
End If
end Sub
Sub makeAntiForgeryToken()
' Session ASPFIXATION token wordt gebruikt als cookie voor CSRF Cross Site
dim token
token = Session("ASPFIXATION")
%>
<script type="text/javascript">
function DoMakeAFT()
{
for (var i = 0; i < document.forms.length; i++)
{
var elem = document.createElement("input");
elem.name = '__RequestVerificationToken';
elem.type = 'hidden';
elem.value = '<%=token%>';
document.forms[i].appendChild( elem );
}
}
</script>
<%
' Zo laat mogelijk en voor de zekerheid via een (korte!) Timeout
setvar "Footer","<script type=""text/javascript"">setTimeout(""DoMakeAFT()"", 100);</script>"
end Sub
Select Case sFormAction
Case "update", "insert", "delete"
if useToken then
validateAntiForgeryToken
end if
end select
' ====================================================================
' Vertaalde teksten
Set vbLCL = Server.CreateObject("Scripting.Dictionary")
sql = "SELECT FAC_LOCALE_MGT_LABEL, FAC_LOCALE_MGT_Module, FAC_LOCALE_MGT_Filenaam, FAC_LOCALE_MGT_TEKST" & _
" FROM FAC_LOCALE_MGT" & _
" WHERE FAC_LOCALE_MGT_LANG = '"&Session("user_lang")&"'" & _
" ORDER BY FAC_LOCALE_MGT_Filenaam, FAC_LOCALE_MGT_Module"
openrs rsLCL, sql
while not rsLCL.EOF
module = rsLCL("FAC_LOCALE_MGT_Module").Value
file = rsLCL("FAC_LOCALE_MGT_Filenaam").Value
if Not isnull(module) AND Not vbLCL.Exists(module) then
Set oMod = Server.CreateObject("Scripting.Dictionary")
vbLCL.Add module, oMod
end if
if Not isnull(file) then
If Not vbLCL.Item(module).Exists(file) then
Set oFile = Server.CreateObject("Scripting.Dictionary")
vbLCL.Item(module).Add file, oFile
End If
end if
if Not isnull(file) then
vbLCL.Item(module).Item(file).Add rsLCL("FAC_LOCALE_MGT_LABEL").Value, rsLCL("FAC_LOCALE_MGT_TEKST").Value
ElseIf Not isnull(module) then
vbLCL.Item(module).Add rsLCL("FAC_LOCALE_MGT_LABEL").Value, rsLCL("FAC_LOCALE_MGT_TEKST").Value
Else
vbLCL.Add rsLCL("FAC_LOCALE_MGT_LABEL").Value, rsLCL("FAC_LOCALE_MGT_TEKST").Value
End If
rsLCL.MoveNext
wend
' ====================================================================
Function myUDLPath()
If IsEmpty(Session("customerId")) Or IsEmpty(Session("user_key")) Then ' ASP-Sessie verlopen.
Response.Redirect("../shared/expired.asp")
End If
myUDLPath = Server.MapPath("..\..\cust\"+Session("CustomerID")+"\oracle.udl")
End Function
'Detecteer op welke database er gewerkt wordt
' Oracle
str_concat = "||"
sysdate = "SYSDATE"
fnToChar = "TO_CHAR"
fnNVL = "NVL"
from_dual = " from dual"
function StrToTable(strTable)
dim tmp
tmp = strTable
' Verwijder het einde van de string
tmp = replace(tmp,"grid.asp","")
tmp = replace(tmp,"record.asp","")
StrToTable = tmp
set tmp = Nothing
end function
function customFacDelete(strTable,value)
dim tmp
dim tabel
tabel = strToTable(strTable)
tmp = "update "+tabel+" set "+tabel+"_VERWIJDER="+sysdate+" where "+tabel+"_KEY="+CStr(value)
customFacDelete = tmp
set tmp = Nothing
end function
function customFacDelete1(strTable,veld,value)
dim tmp
dim tabel
tabel = strToTable(strTable)
tmp = "update "+tabel+" set "+tabel+"_VERWIJDER="+sysdate+" where "+veld+"="+CStr(value)
customFacDelete1 = tmp
set tmp = Nothing
end function
'Functie om string naar datum te converteren.
function toDate(datum)
if (datum="") then
toDate = "Null"
exit function
end if
'Oracle
toDate = "TO_DATE('"+datum+"','dd mm yy')"
end function
' ============================================================================
' LET OP: DEZE openrs overruled de default openrs uit Common.asp
' hij logt eventueel de SQL
' Let op: In de CodeCharge code wordt ook vaak een cn.execute
' gedaan. Deze worden niet automatisch gelogt!
' ============================================================================
sub openrs(rs, sql)
Set rs = Server.CreateObject("ADODB.Recordset")
rs.CursorLocation = adUseServer
VB_Log(sql)
rs.Open sql, cn, adOpenForwardOnly, adLockReadOnly, adCmdText
end sub
' ============================================================================
' LET OP: DEZE PrintVar overruled de default PrintVar uit TemplateObj.asp
' A) hij injecteert jQuery
'
Function PrintVar(sName)
tmp = ParsedBlocks(sName)
tmp = replace(tmp,"Site.css",AddTimeStamp("../../temp/" + Session("customerId") + ".css"))
jq = "../localscripts/" & jqueryver & ".min.js" ''
scr = Chr(13) & "<script type='text/javascript' src='" & AddTimeStamp(jq) & "'></script>"
tmp = replace(tmp,"</head>", scr & "</head>")
fPath = "../localscripts/FcltMgr.js"
scr = Chr(13) & "<script type='text/javascript' src='" & AddTimeStamp(fPath) & "'></script>"
tmp = replace(tmp,"</head>", scr & "</head>")
fPath = "./FacmgtTools.js"
scr = Chr(13) & "<script type='text/javascript' src='" & AddTimeStamp(fPath) & "'></script>"
tmp = replace(tmp,"</head>", scr & "</head>")
fPath = "../shared/locale_facmgt.js"
scr = Chr(13) & "<script type='text/javascript' src='" & AddTimeStamp(fPath) & "'></script>"
tmp = replace(tmp,"</head>", scr & "</head>")
scr = Chr(13) & "<script type='text/javascript'>var multi_language_option = " & S("multi_language_option") & "</script>"
tmp = replace(tmp,"</head>", scr & "</head>")
PrintVar = tmp
End function
Function AddTimeStamp(sPath)
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
Set f = objFSO.GetFile(Server.MapPath(sPath))
timeStart = "1/1/1970 12:00:00 AM"
timeStamp = datediff("s", timeStart, f.DateLastModified)
Set f = Nothing
Set objFSO = Nothing
AddTimeStamp = sPath & "?" & timeStamp
End Function
' ============================================================================
' LET OP: DEZE ProcessError overruled de default ProcessError uit Common.asp
' hij probeert de fac_message er bij te halen
' ============================================================================
function ProcessError()
if cn.Errors.Count > 0 then
ProcessError = cn.Errors(0).Description ' & " (" & cn.Errors(0).Source & ")"
xx = DLookUp("FAC_MESSAGE", "FAC_MESSAGE_TEXT", "FAC_MESSAGE_CODE = " + ToSQL(ProcessError, "Text"))
ProcessError = ProcessError + ": " + xx
elseif not (Err.Description = "") then
ProcessError = Err.Description
else
ProcessError = ""
end if
// VB_LOG("ProcessError found: " + ProcessError)
end Function
' ============================================================================
' LET OP: DEZE LoadTemplate overruled de default LoadTemplate uit
' TemplateObj.asp. Deze probeert de labels te vertalen
' Dat doen we door direct na laden van de HTML deze te 'vertalen'
' Dan zit er nog geen klant-data in die we per ongeluk mee vertalen
' ============================================================================
Sub LoadTemplate(sPath, sName)
Dim nName
if not isObject(objFSO) then
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
Set DBlocks = Server.CreateObject("Scripting.Dictionary")
Set ParsedBlocks = Server.CreateObject("Scripting.Dictionary")
end if
if objFSO.FileExists(sPath) then
DBlocks.Add sName, objFSO.OpenTextFile(sPath).ReadAll
nName = NextDBlockName(sName)
while not (nName = "")
SetBlock sName, nName
nName = NextDBlockName(sName)
wend
end if
VB_LOG("Loading file: " & sPath)
For Each Item in DBlocks
VB_LOG("Translating blok " & Item)
' Kijk eerst of er een bestands-specifieke vertaling is
' Zo niet neem dan een module(eerste 3 char) vertaling
' Zo niet neem dan een globale vertaling
DBlocks(Item) = TranslateBlock(sPath, Item, DBlocks(Item))
Next
if useToken then
makeAntiForgeryToken
end if
End Sub
'' We zoeken te vertalen:
' <font class="ColumnFONT">Omschrijving</font>
' <font class="DataFONT">Geen records</font>
Function TranslateBlock(sPath, blockName, sTpl)
sTpl = TranslateFind(sPath, blockName, sTpl, "<font class=""ColumnFONT"">", "</font>")
sTpl = TranslateFind(sPath, blockName, sTpl, "<font class=""DataFONT"">", "</font>")
sTpl = TranslateFind(sPath, blockName, sTpl, "<font class=""FieldCaptionFONT"">", "</font>")
' <input type="submit" value="Verwijderen" onclick="document.KenmerkRecord.FormAction.value = 'delete';"/>
sTpl = TranslateFind(sPath, blockName, sTpl, "<input type=""submit"" value=""", """ onclick=""")
' <input type="submit" value="Zoeken">
sTpl = TranslateFind(sPath, blockName, sTpl, "<input type=""submit"" value=""", """>")
TranslateBlock = sTpl
End Function
Function TranslateFind(sPath, blockName, sTpl, pre, post)
Dim regEx, sMatch, oMatches, sName, sTTpl
Dim res, b, e, isOk, begin
Dim w(5)
begin = 1
b = instr(begin, sTpl, pre)
while b > 0
e = instr(b, sTpl, post)
if (e > 0) then
' Zoek wel de binnenste:
while instr(b+1, sTpl, pre) > b AND instr(b+1, sTpl, pre) < e
b = instr(b+1, sTpl, pre)
wend
tb = b + Len(pre) 'instr(b, sTpl, "FONT"">") + 6 ' hier begint echt de tekst
VB_LOG("b: " & b & " tb: " & tb & " e: " & e & " s=" & Server.HTMLEncode(mid(sTpl, tb)))
res = mid(sTpl, tb, e - tb)
VB_LOG("Tekst: x" & Server.HTMLEncode(res) & "x")
sTpl = mid(sTpl, 1, tb-1) & TranslateOne(sPath, blockName, res) & mid(sTpl, e)
begin = e + 1
else
begin = begin + 1
end if
b = instr(begin, sTpl, pre)
wend
TranslateFind = sTpl
End Function
Function matchi(msg, patrn)
matchi = (domatchi(msg, patrn).Count > 0)
End Function
Function domatchi(strng, patrn)
Set regEx = New RegExp ' Create a regular expression.
regEx.Pattern = patrn ' Set pattern.
regEx.IgnoreCase = True ' Set case insensitivity.
Set domatchi = regEx.Execute(strng)
End Function
' ============================================================================
' LET OP: DEZE SetVar overruled de default SetVar uit TemplateObj.asp
' A) hij probeert FormTitle te vertalen
' B) Ook probeert hij ORA- foutmeldingen te vertalen.
' C) SetVar van een Trn_xxxx maakt hij html-safe
'' TODO: 'labels' vertalen door testen op <i>? fldVoorraad= "<i>Voorraad</i>"
Function SetVar(sName, sValue)
Dim sv2, arr, x
if Left(sValue, 4) = "ORA-" then ' Uit m_conncetions.inc afgeleid
msg = sValue
if matchi(msg, "^ORA-20000") OR matchi(msg, "^ORA-20004") OR matchi(msg, "^ORA-00001") OR matchi(msg, "^ORA-02290") then
faccode = ""
friendlyMsg = ""
knownError = False
Set RegCode = domatchi(msg, "^ORA-20000: (\w*)(.*)\nORA-") ' Zoek: ORA-20000: res_m039 ORA-06512: at "UWVA_500.ALG_T_ALG_RUIMTE_B_IU", line 71 ORA-04088: error during execution of trigger 'UWVA_500.ALG_T_ALG_RUIMTE_B_IU'
If RegCode.count = 0 Then
Set RegCode = domatchi(msg, "^ORA-20004: (\w*)(.*)\nORA-") ' Zoek: ORA-20004: ins_m145,Normverbruik,0, ORA-06512: at .......
End If
If RegCode.count = 0 Then
Set RegCode = domatchi(msg, "^ORA-00001: .* \(.*\.(\w*)\)") ' Zoek: ORA-00001: unique constraint (UWVA_500.ALG_U_ALG_RUIMTE_UPPER_NR) violated
End If
if RegCode.count = 0 Then
Set RegCode = domatchi(msg, "^ORA-02290: .* \(.*\.(\w*)\)") ' Zoek: ORA-02290: check constraint (UWVA_500.ALG_C_ALG_RUIMTE_UPPER_NR) violated
End If
If RegCode(0).SubMatches.count > 1 Then
faccode = RegCode(0).SubMatches(0)
End If
If matchi(msg, "^ORA-20000") AND RegCode(0).SubMatches.count > 2 Then
friendlyMsg = RegCode(0).SubMatches(1) ' een ORA-20000 met ingebouwde tekst zoals ORA-20000: alg_m999 Ruimte kan nog niet verwijderd worden. Er zijn nog lopende meldingen
knownError = True
End If
// We gaan proberen de tekst er bij te zoeken
If faccode <> "" Then
sql2 = "select FAC_MESSAGE_TEXT from fac_message where fac_message_code = upper('"+Replace(faccode, "'", "''")+"')"
Set oRs = cn.Execute( sql2 )
if Not oRs.EOF Then
knownError = True
friendlyMsg = oRs("FAC_MESSAGE_TEXT").Value & "<br>(" & faccode & ")"
End if
oRs.Close()
End If
If knownError Then
sValue = friendlyMsg
else
' We kunnen niets
End If
end if
end if
if sName = "FormTitle" then
sv2 = TranslateOne("\", "", sValue)
if sv2 = sValue then ' nog geen complete vertaling gevonden
arr=Split(sValue)
sv2 = ""
if UBound(arr) >= 0 then
for each x in arr
sv2 = sv2 & " " & TranslateOne("\", "", Ucase(Left(x, 1)) & Mid(x,2))
next
end if
if sv2 = " " & sValue then ' nog geen complete vertaling gevonden
sv2 = TranslateOne("\", "", "Details") ' dan maar generiek
end If
end if
sValue = sv2
end if
' Trn_ (transit) variabelen moeten wel XSS bestendig gemaakt worden
Dim val2
val2 = replace(replace(sValue, "{", "&#123;"), "}", "&#125;")
if Left(sName, 4) = "Trn_" then
val2 = Server.HTMLEncode(val2)
end if
if ParsedBlocks.Exists(sName) then
ParsedBlocks(sName) = val2
else
ParsedBlocks.add sName, val2
end if
End Function
' Voorkeur is altijd sPath-specifiek
' zoniet dan module (alg) specifiek
' zoniet dan generiek
Function TranslateOne(sPath, blockName, txt)
Dim sName, arrNames, module, oModule
TranslateOne = txt ' standaard niet vertalen
arrNames = Split(sPath, "\")
sName = arrNames(Ubound(arrNames))
module = UCase(mid(sName, 1, 3))
if vbLCL.Exists(module) then
Set oModule = vbLCL.Item(module)
if oModule.Exists(sname) then
if oModule.Item(sname).Exists(txt) then
TranslateOne = oModule.Item(sname).Item(txt)
Exit Function
end if
end if
if vbLCL.Item(module).Exists(txt) then
TranslateOne = vbLCL.Item(module).Item(txt)
Exit Function
end if
end if
'' Generiek
if vbLCL.Exists(txt) then
TranslateOne = vbLCL.Item(txt)
end if
End Function
Function FCLTLCL(txt)
FCLTLCL = TranslateOne("\", "", txt)
Exit Function
End Function
' Als de JScript variant maar we nemen niet de moeite te cachen
Function L(lcl)
Dim Table, fName, sWhere
Table = "fac_locale_xsl"
fName = " COALESCE(fac_locale_xsl_cust, fac_locale_xsl_tekst)"
sWhere = " fac_locale_xsl_lang = '"&Session("user_lang")&"'" & _
" AND fac_locale_xsl_label = " & ToSQL(lcl, "Text") & _
" AND fac_locale_xsl_module = 'ASP'"
L = DLookUp(Table, fName, sWhere)
Exit Function
End Function
' Als de JScript variant maar we nemen niet de moeite te cachen
' Ook doen we niets met het datatype en leveren altijd string op!
Function S(sname)
Dim Table, fName, sWhere
Table = "fac_setting"
fName = " coalesce(fac_setting_pvalue, fac_setting_default)"
sWhere = " fac_setting_name = " & ToSQL(sname, "Text")
S = DLookUp(Table, fName, sWhere)
Exit Function
End Function
'Deze functie vertaalt het positie autorisatieniveau naar tekst
function decode_pos_level(aut_level)
select case aut_level
case "-1" d_pos_level = FCLTLCL("Alles")
case "0" d_pos_level = L("lcl_region")
case "1" d_pos_level = L("lcl_district")
case "2" d_pos_level = L("lcl_location")
case "3" d_pos_level = L("lcl_building")
case "4" d_pos_level = L("lcl_floor")
case "5" d_pos_level = L("lcl_room")
case "9" d_pos_level = FCLTLCL("Geen")
case else d_pos_level = aut_level
end select
decode_pos_level = d_pos_level
end function
function decode_org_level(aut_level)
select case aut_level
case "-1" d_org_level = FCLTLCL("Alles")
case "0" d_org_level = L("lcl_company")
case "1" d_org_level = L("lcl_dep_name_level1")
case "2" d_org_level = L("lcl_dep_name_level2")
case "3" d_org_level = L("lcl_dep_name_level3")
case "4" d_org_level = L("lcl_dep_name_level4")
case "5" d_org_level = L("lcl_dep_name_level5")
case "9" d_org_level = FCLTLCL("Geen")
case else d_org_level = aut_level
end select
decode_org_level = d_org_level
end function
function buildName(prs_perslid_key)
if prs_perslid_key = "" then
buildName = ""
else
tmpsql = "select prs_perslid_naam, prs_perslid_voorletters, prs_perslid_voornaam from prs_v_aanwezigperslid where prs_perslid_key = "&prs_perslid_key
VB_Log("tmpsql")
VB_Log(tmpsql)
openrs tmprs, tmpsql
Voorletters = getValue(tmprs,"prs_perslid_voorletters")
Voornaam = getValue(tmprs,"prs_perslid_voornaam")
Naam = getValue(tmprs,"prs_perslid_naam")
if Voorletters <> "" then
Naam= Naam & ", "&Voorletters
end if
if Voornaam <> "" then
Naam = Naam& " ("&Voornaam&")"
end if
tmprs.Close
buildName = Naam
end if
end function
function decode_min_level(minlevel)
select case minlevel
case "1" decode_min_level = "Lezen"
case "2" decode_min_level = "Schrijven"
case "3" decode_min_level = "Keuze"
case else decode_min_level = ""
end select
decode_min_level = TranslateOne("\", "", decode_min_level)
end function
function buildORGRadioList()
str = ""
for i = -1 to CDbl(S("prs_max_dep_level"))
str = str & i & ";" & decode_org_level(i) & ";"
next
str = str & "9;" & decode_org_level(9) ' Geen
buildORGRadioList = str
end function
function buildPOSRadioList()
' s = "-1;Alles;0;Regio;1;District;2;Locatie;3;Gebouw;4;Verdieping;5;Ruimte;9;Geen"
DIM s
s = ""
for i = -1 to 4
s = s & i & ";" & decode_pos_level(i) & ";"
next
s = s & "9;" & decode_pos_level(9) ' Geen
buildPOSRadioList = s
end function
function buildVerplichtingList()
DIM s
s = ";" & FCLTLCL("Niet verplicht") & _
";1;" & FCLTLCL("Altijd verplicht") & _
";2;" & FCLTLCL("Groepsverplichting")
buildVerplichtingList = s
end function
function buildGroepsverplichtingList()
DIM s
sGroepsverplichting = FCLTLCL("Groep")
s = "0;"
for i = 1 to 9
s = s & ";" & i & ";" & sGroepsverplichting & " " & i
next
buildGroepsverplichtingList = s
end function
function buildStatusList()
DIM statusList
DIM sql
' " SELECT 0, '" & L("lcl_mld_pending") & "' FROM DUAL" &_
' " UNION SELECT 2, '" & L("lcl_mld_ingevoerd") & "' FROM DUAL" &_
' " UNION SELECT 3, '" & L("lcl_mld_ingezien") & "' FROM DUAL" &_
' " UNION SELECT 4, '" & L("lcl_mld_geaccepteerd") & "' FROM DUAL" &_
' " UNION SELECT 6, '" & L("lcl_mld_verwerkt") & "' FROM DUAL" &_
' " UNION SELECT 7, '" & L("lcl_mld_uitgegeven") & "' FROM DUAL" &_
sql = "SELECT 1, '" & L("lcl_mld_afgewezen") & "' FROM DUAL" &_
" UNION SELECT 6, '" & L("lcl_mld_afgemeld") & "' FROM DUAL" &_
" ORDER BY 1"
openrs rsStatus, sql
statusList = "-1;"
While not rsStatus.EOF
statusList = statusList & ";" & getValue(rsStatus,0) & ";" & getValue(rsStatus,1)
rsStatus.MoveNext
wend
buildStatusList = statusList
end function
function buildKenmerkTypeList(pKENMERKTYPE)
sResult = ""
select case pKENMERKTYPE
case "C": sResult = "C;"& FCLTLCL("Karakter")
case "N": sResult = "N;"& FCLTLCL("Numeriek")
case "D": sResult = "D;"& FCLTLCL("Datum")
case "R": sResult = "R;"& FCLTLCL("Referentie (listbox)") &";S;"& FCLTLCL("Referentie (suggest)")
case "S": sResult = "S;"& FCLTLCL("Referentie (suggest)") &";R;"& FCLTLCL("Referentie (listbox)")
case "X": sResult = "X;"& FCLTLCL("Bestandsnaam")
case "F": sResult = "F;"& FCLTLCL("Bestand")
case "E": sResult = "E;"& FCLTLCL("Encrypted Bestand")
case "M": sResult = "M;"& FCLTLCL("Folder met bestanden")
case "L": sResult = "L;"& FCLTLCL("Label") &";l;"& FCLTLCL("Label (inklapbaar)")
case "l": sResult = "l;"& FCLTLCL("Label (inklapbaar)") &";L;"& FCLTLCL("Label")
case "Q": sResult = "Q;"& FCLTLCL("Blanco")
case else sResult = ";" & _
";C;"& FCLTLCL("Karakter") & _
";N;"& FCLTLCL("Numeriek") & _
";D;"& FCLTLCL("Datum") & _
";R;"& FCLTLCL("Referentie (listbox)") & _
";S;"& FCLTLCL("Referentie (suggest)") & _
";X;"& FCLTLCL("Bestandsnaam") & _
";F;"& FCLTLCL("Bestand") & _
";E;"& FCLTLCL("Encrypted Bestand") & _
";M;"& FCLTLCL("Folder met bestanden") & _
";L;"& FCLTLCL("Label") & _
";l;"& FCLTLCL("Label (inklapbaar)") & _
";Q;"& FCLTLCL("Blanco")
end select
buildKenmerkTypeList = sResult
end function
function buildKenmerkTypeSearch()
sResult = ";"& FCLTLCL("Alles") & _
";C;"& FCLTLCL("Karakter") & _
";N;"& FCLTLCL("Numeriek") & _
";D;"& FCLTLCL("Datum") & _
";R;"& FCLTLCL("Referentie (listbox)") & _
";S;"& FCLTLCL("Referentie (suggest)") & _
";X;"& FCLTLCL("Bestandsnaam") & _
";F;"& FCLTLCL("Bestand") & _
";E;"& FCLTLCL("Encrypted Bestand") & _
";M;"& FCLTLCL("Folder met bestanden") & _
";L;"& FCLTLCL("Label") & _
";l;"& FCLTLCL("Label (inklapbaar)") & _
";Q;"& FCLTLCL("Blanco")
buildKenmerkTypeSearch = sResult
end function
function decodeKenmerkType(sType)
select case sType
case "C" sKenmerkType = FCLTLCL("Karakter")
case "N" sKenmerkType = FCLTLCL("Numeriek")
case "D" sKenmerkType = FCLTLCL("Datum")
case "R" sKenmerkType = FCLTLCL("Referentie (listbox)")
case "S" sKenmerkType = FCLTLCL("Referentie (suggest)")
case "X" sKenmerkType = FCLTLCL("Bestandsnaam")
case "F" sKenmerkType = FCLTLCL("Bestand")
case "E" sKenmerkType = FCLTLCL("Encrypted bestand")
case "M" sKenmerkType = FCLTLCL("Folder met bestanden")
case "L" sKenmerkType = FCLTLCL("Label")
case "l" sKenmerkType = FCLTLCL("Label (inklapbaar)")
case "Q" sKenmerkType = FCLTLCL("Blanco")
case else sKenmerkType = ""
end select
decodeKenmerkType = sKenmerkType
end function
function getFacGroepByPrsLidKey(pPRS_PERSLID_KEY)
if isNull(pPRS_PERSLID_KEY) or isEmpty(pPRS_PERSLID_KEY) or (pPRS_PERSLID_KEY="") then
getFacGroepByPrsLidKey = ""
exit function
end if
groepSql = "select fg.fac_groep_omschrijving "&_
"from fac_groep fg, fac_gebruikersgroep gg "&_
"where fg.fac_groep_key = gg.fac_groep_key and "&_
"gg.prs_perslid_key="& ToSQL(pPRS_PERSLID_KEY, "Number") &" "&_
"order by fg.fac_groep_omschrijving asc "
VB_Log("groepSql")
VB_Log(groepSql)
openrs rsGroep, groepSql
sResult = ""
while not rsGroep.EOF
sResult = sResult & "<br>" & ToHTML(getValue(rsGroep,"fac_groep_omschrijving"))
rsGroep.MoveNext
wend
getFacGroepByPrsLidKey = Mid(sResult,5,Len(sResult))
end function
function getWorkflowstepOmschr(pMLD_WORKFLOWSTEP_KEY)
sResult = ""
if pMLD_WORKFLOWSTEP_KEY <> "" then
sqlTekst = "select w.mld_workflowstep_omschrijving "&str_concat&"' ('"&str_concat&"d.ins_discipline_omschrijving "&str_concat&" ' / ' "&str_concat&" s.mld_stdmelding_omschrijving "&str_concat&"')' as h "&_
"from mld_discipline d, mld_stdmelding s, mld_workflowstep w "&_
"where d.ins_discipline_verwijder is null "&_
" and s.mld_ins_discipline_key = d.ins_discipline_key "&_
" and s.mld_stdmelding_key=w.mld_stdmelding_key "&_
" and w.mld_workflowstep_key="& ToSQL(pMLD_WORKFLOWSTEP_KEY, "Number")
openrs rsTekst, sqlTekst
if not rsTekst.EOF then
sResult = getValue(rsTekst,"h")
end if
rsTekst.Close
end if
getWorkflowstepOmschr = sResult
end function
function getWorkflowNextSteps(pMLD_WORKFLOWSTEP_KEY,pMLD_WORKFLOWRULE_RESULT)
sResult = ""
if (pMLD_WORKFLOWSTEP_KEY <> "") and (pMLD_WORKFLOWRULE_RESULT <> "") then
sqlKeys = "select mld_workflowstep_next_key "&_
"from mld_workflowrule "&_
"where mld_workflowstep_key = "& ToSQL(pMLD_WORKFLOWSTEP_KEY, "Number") &_
" and mld_workflowrule_result = "& ToSQL(pMLD_WORKFLOWRULE_RESULT, "Number")
openrs rsKeys,sqlKeys
while not rsKeys.EOF
sKey = getValue(rsKeys,"mld_workflowstep_next_key")
if sResult <> "" then sResult = sResult & "<br>"
sResult = sResult & ToHTML(getWorkflowstepOmschr(sKey))
rsKeys.MoveNext
wend
end if
getWorkflowNextSteps = sResult
end function
'Zoekt de omschrijving van een vakgroeptype op bij een discipline_key
function getSrtDisciplineOmschr(pINS_DISCIPLINE_KEY)
if pINS_DISCIPLINE_KEY = "" or isNull(pINS_DISCIPLINE_KEY) then
getSrtDisciplineOmschr = ""
exit function
end if
sResult = ""
sqlSrtDiscipline = "select ins_srtdiscipline_omschrijving "&_
"from ins_srtdiscipline s, ins_tab_discipline t "&_
"where s.ins_srtdiscipline_key = t.ins_srtdiscipline_key "&_
" and t.ins_discipline_key="& ToSQL(pINS_DISCIPLINE_KEY, "Number")
openrs rsSrtDiscipline, sqlSrtDiscipline
if not rsSrtDiscipline.EOF then
sResult = ToHTML(getValue(rsSrtDiscipline,"ins_srtdiscipline_omschrijving"))
end if
getSrtDisciplineOmschr = sResult
end function
' Genereer een legenda aan de hand van voorkomende waarden
Function GenereerLegenda(fldCAD_THEMA_VIEW, fldCAD_THEMA_OMSCHRIJVING)
rndSQL = "to_char(dbms_utility.get_hash_value(WAARDE,0,power(2,24)), '0XXXXX')"
'rndSQL = "to_char(trunc(dbms_random.value(0, POWER(2,24))),'0XXXXX')"
' wordt soms te lang legName = "Legenda_" & fldCAD_THEMA_OMSCHRIJVING & "_" & Timer
legName = "Legenda_" & Timer
sSql = "INSERT INTO CAD_LEGENDA (CAD_LEGENDA_OMSCHRIJVING, CAD_LEGENDA_DISCREET) VALUES (" + ToSQL(legName, "Text") + ", 1)"
cn.execute sSQL
sSql = "SELECT CAD_LEGENDA_KEY FROM CAD_LEGENDA WHERE CAD_LEGENDA_OMSCHRIJVING = " + ToSQL(legName, "Text")
openrs rsLegenda, sSql
iKey = getValue(rsLegenda,"CAD_LEGENDA_KEY")
sSql = "INSERT INTO CAD_LEGENDAWAARDE"&_
" (CAD_LEGENDA_KEY, CAD_LEGENDAWAARDE_VALUE,"&_
" CAD_LEGENDAWAARDE_RGB, CAD_LEGENDAWAARDE_OMSCHR)"&_
" SELECT DISTINCT " & iKey & ", WAARDE, "&rndSQL&", WAARDE"&_
" FROM " & fldCAD_THEMA_VIEW
cn.execute sSQL
GenereerLegenda = iKey
End Function
' Breidt een legenda uit aan de hand van voorkomende nieuwe waarden
Sub UpdateLegenda(fldCAD_THEMA_VIEW, fldCAD_LEGENDA_KEY)
rndSQL = "to_char(dbms_utility.get_hash_value(WAARDE,0,power(2,24)), '0XXXXX')"
sSql = "INSERT INTO CAD_LEGENDAWAARDE"&_
" (CAD_LEGENDA_KEY, CAD_LEGENDAWAARDE_VALUE,"&_
" CAD_LEGENDAWAARDE_RGB, CAD_LEGENDAWAARDE_OMSCHR)"&_
" SELECT DISTINCT " & ToSQL(fldCAD_LEGENDA_KEY, "Number") & ", WAARDE, "&rndSQL&", WAARDE"&_
" FROM " & fldCAD_THEMA_VIEW & " thv " &_
" WHERE WAARDE IS NOT NULL " &_
" AND NOT EXISTS (SELECT cl.CAD_LEGENDAWAARDE_VALUE FROM CAD_LEGENDAWAARDE cl "&_
"WHERE cl.CAD_LEGENDAWAARDE_VALUE = thv.WAARDE "&_
" AND cl.CAD_LEGENDA_KEY="&ToSQL(fldCAD_LEGENDA_KEY, "Number") & ")"
cn.execute sSQL
End Sub
' Accepteer zowel komma als punten in strDbl zodat later CDbl goed werkt
Function SafeToDouble(strDbl)
If Instr(CStr(1.5), ",") > 1 Then ' Het moeten komma's zijn
SafeToDouble = replace(strDbl, ".", ",")
Else
SafeToDouble = replace(strDbl, ",", ".")
End If
End Function
' Kopieer de rechten van een functie/groep/discipline naar een andere discipline
' We ondersteunen geen kopie naar een andere functie of groep
Sub KopieRechten (FunctieKey, GroepKey, DiscKeyVan , DiscKeyNaar)
VB_Log("Kopie: " & FunctieKey & "," & GroepKey & "," & DiscKeyVan & "," & DiscKeyNaar)
sqlVan = "SELECT * FROM FAC_GROEPRECHTEN" & _
" WHERE FAC_FUNCTIE_KEY = " & FunctieKey & _
" AND FAC_GROEP_KEY = " & GroepKey & _
" AND INS_DISCIPLINE_KEY = " & DiscKeyVan
whrNaar = " WHERE FAC_FUNCTIE_KEY = " & FunctieKey & _
" AND FAC_GROEP_KEY = " & GroepKey & _
" AND INS_DISCIPLINE_KEY = " & DiscKeyNaar
openrs rsVan, sqlVan
if rsVan.EOF Then
sql = "DELETE FROM FAC_GROEPRECHTEN " + whrNaar
VB_Log(sql)
cn.execute sql
Else
openrs rsNaar, "SELECT FAC_GROEPRECHTEN_KEY FROM FAC_GROEPRECHTEN " + whrNaar
if rsNaar.EOF Then
sql = "insert into FAC_GROEPRECHTEN (" & _
"FAC_FUNCTIE_KEY,FAC_GROEP_KEY,INS_DISCIPLINE_KEY," & _
"FAC_GEBRUIKER_PRS_LEVEL_READ,FAC_GEBRUIKER_PRS_LEVEL_WRITE," & _
"FAC_GEBRUIKER_ALG_LEVEL_READ,FAC_GEBRUIKER_ALG_LEVEL_WRITE" & _
")" & _
" values (" & FunctieKey & "," & GroepKey & "," & DiscKeyNaar & "," & _
rsVan("FAC_GEBRUIKER_PRS_LEVEL_READ") & "," & _
rsVan("FAC_GEBRUIKER_PRS_LEVEL_WRITE") & "," & _
rsVan("FAC_GEBRUIKER_ALG_LEVEL_READ") & "," & _
rsVan("FAC_GEBRUIKER_ALG_LEVEL_WRITE") & _
")"
Else
sql = "UPDATE FAC_GROEPRECHTEN SET " & _
"FAC_GEBRUIKER_PRS_LEVEL_READ="&rsVan("FAC_GEBRUIKER_PRS_LEVEL_READ")&"," & _
"FAC_GEBRUIKER_PRS_LEVEL_WRITE="&rsVan("FAC_GEBRUIKER_PRS_LEVEL_WRITE")&"," & _
"FAC_GEBRUIKER_ALG_LEVEL_READ="&rsVan("FAC_GEBRUIKER_ALG_LEVEL_READ")&"," & _
"FAC_GEBRUIKER_ALG_LEVEL_WRITE="&rsVan("FAC_GEBRUIKER_ALG_LEVEL_WRITE") & _
whrNaar
End If
VB_Log(sql)
rsNaar.Close
cn.execute sql
End If
rsVan.Close
End Sub
%>

View File

@@ -1,75 +0,0 @@
/*
$Revision$
$Id$
File: FacmgtTools.js
Description: Wordt geinjecteerd in elke FacMgt html
Parameters:
Context:
Note:
*/
$(function () {
onloadFacMgt();
}
);
// Vervang alle Facmgt onclick's door 'openDetail'
// maar alleen in de dataregels, niet in de paginering
// Maakt ook eventueel vertaal linkjes
function onloadFacMgt(translate_lcls)
{
// if (window.location.href.match(/\_Page\=/)) // Uitsluitend als we op een vervolgpagina zitten!
{
$('td.DataTD>a').click(function()
{ // nameProp is IE, href is FF
FcltMgr.openDetail("appl/facmgtvb/"+(this.nameProp||this.getAttribute("href")), this.innerText||this.textContent )
return false;
})
}
// (Ook) geen vertaallinkjes als we niet in frames zitten, te lastig
if (!window.multi_language_option || !window.parent || window.parent == window)
return;
// (Ook) niet bij toevoegen
if ($("input[name=FormAction][value=insert]").length)
return;
// Vertaal linkjes maken */
var fname = window.location.href.split("/")[window.location.href.split("/").length-1].split("?")[0];
for (var i in facmgt_lcls[fname])
{
var nm = facmgt_lcls[fname][i].toUpperCase();
$("input[name="+nm+"],textarea[name="+nm+"]").each(function()
{
// zoek het label er bij, die maken we klikbaar
var lbl = $(this).closest("tr").find(".FieldCaptionTD");
lbl.addClass("facmgtmultilang")
.click(function ()
{
// zoek de key uit de url
var urlparams = window.location.search.substr(1).split("&");
// we gokken dat de eerste de key is
var key = urlparams[0].split("=")[1];
if (key > 0)
{
// Zoek eerstvolgende <input> type text
var inp = $(this).closest("tr").find("textarea,input[type=text]");
var url = "../fac/fac_locale_data.asp?kolomnaam="+inp[0].name+"&kolomkeyval=" + key
+ "&kolomkeydata=" +escape(inp.val())
+ "&lbl=" +escape($(this).text())
+ "&typ=" +inp[0].tagName;
//var url = "../fac/fac_locale_list.asp?sString="+inp[0].name+"&extrakey=" + key;
// Onze Facmgt's hebben geen Fcltheader.Generate en dus geen
// window.LCL = {}; Daarom pakken de de L() lekker lui uit de parent
// Zou fout gaan zonder frames (touch=1) maar dan komen de vertaallinkjes toch niet.
parent.FcltMgr.openModalDetail(url, parent.L("lcl_lcl_vertaling") );
}
});
})
}
}

View File

@@ -1,281 +0,0 @@
<%
'
' Filename: Page.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
' Page CustomIncludes begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' Page CustomIncludes end
'-------------------------------
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "Page.asp"
sTemplateFileName = "Page.html"
'===============================
'===============================
' Page PageSecurity begin
' Page PageSecurity end
'===============================
'===============================
' Page Open Event begin
' Page Open Event end
'===============================
'===============================
' Page OpenAnyPage Event begin
' Page OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' Page Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
Form1_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' Page Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' Page Close Event begin
' Page Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub Form1_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Form1"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 25
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim sActionFileName : sActionFileName = ".asp"
SetVar "TransitParams", ""
SetVar "FormParams", ""
'-------------------------------
' Build ORDER BY statement
'-------------------------------
iSort = GetParam("FormForm1_Sorting")
iSorted = GetParam("FormForm1_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormForm1_Sorting=" & iSort & "&FormForm1_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormForm1_Sorting=" & iSort & "&FormForm1_Sorted=" & "&"
end if
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select .undefined as _undefined " & _
" from "
'-------------------------------
'-------------------------------
' Form1 Open Event begin
' Form1 Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the link to the record page
'-------------------------------
SetVar "FormAction", sActionFileName
'-------------------------------
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListForm1", ""
Parse "Form1NoRecords", False
SetVar "Form1Navigator", ""
Parse "FormForm1", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 25
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormForm1_Page")
if IsEmpty(iPage) then iPage = 1 else iPage = CLng(iPage)
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
'-------------------------------
' Form1 Show begin
'-------------------------------
'-------------------------------
' Form1 Show Event begin
' Form1 Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
Parse "DListForm1", True
'-------------------------------
' Form1 Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' Form1 Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "Form1Navigator", ""
else
if bEof then
SetVar "Form1NavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "Form1NavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "Form1CurrentPage", iPage
Parse "Form1Navigator", False
end if
'-------------------------------
' Form1 Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "Form1NoRecords", ""
Parse "FormForm1", False
'-------------------------------
' Form1 Close Event begin
' Form1 Close Event end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,56 +0,0 @@
<html>
<head>
<title>Facilitor Beheer & Onderhoud</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormForm1Header-->
<!--EndFormForm1Header-->
<!--BeginFormForm1--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="0"><a name="Form1"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
</tr>
<!--BeginDListForm1-->
<tr>
</tr>
<!--EndDListForm1-->
<!--BeginForm1NoRecords-->
<tr><td colspan="0" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndForm1NoRecords-->
<tr>
<td colspan="0" class="ColumnTD">
<font class="ColumnFONT">
<a href="{FormAction}?{TransitParams}"><font class="ColumnFONT">Toevoegen</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<!--BeginForm1Navigator-->
<a href{Form1NavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormForm1_Page={PrevPage}#Form1"><font class="ColumnFONT">Vorige</font></a>
[ {Form1CurrentPage} ]
<a href{Form1NavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormForm1_Page={NextPage}#Form1"><font class="ColumnFONT">Volgende</font></a>
<!--EndForm1Navigator-->
</font>
</td>
</tr>
</table>
<!--EndFormForm1-->
<!--BeginFormForm1Footer-->
<!--EndFormForm1Footer-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,2 +0,0 @@
@import url("../shared/default.css");

View File

@@ -1,194 +0,0 @@
<%
'
' Filename: TemplateObj.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
' Usage:
' LoadTemplate server.mappath("/templates/new.html"), "main"
' SetVar "ID", 2
' SetVar "Value", "Name"
' Parse "DynBlock", False 'or True if you want to create a list
' Parse "main", False
' PrintVar "main"
'
Dim objFSO
Dim DBlocks
Dim ParsedBlocks
Sub SetBlock(sTplName, sBlockName)
Dim nName
if not DBlocks.Exists(sBlockName) then
DBlocks.Add sBlockName, getBlock(DBlocks(sTplName), sBlockName)
end if
DBlocks(sTplName) = replaceBlock(DBlocks(sTplName), sBlockName)
nName = NextDBlockName(sBlockName)
while not (nName = "")
SetBlock sBlockName, nName
nName = NextDBlockName(sBlockName)
wend
End Sub
Sub LoadTemplate(sPath, sName)
Dim nName
if not isObject(objFSO) then
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
Set DBlocks = Server.CreateObject("Scripting.Dictionary")
Set ParsedBlocks = Server.CreateObject("Scripting.Dictionary")
end if
if objFSO.FileExists(sPath) then
DBlocks.Add sName, objFSO.OpenTextFile(sPath).ReadAll
nName = NextDBlockName(sName)
while not (nName = "")
SetBlock sName, nName
nName = NextDBlockName(sName)
wend
end if
End Sub
Sub UnloadTemplate()
if isObject(objFSO) then
Set objFSO = nothing
Set DBlocks = nothing
Set ParsedBlocks = nothing
end if
End Sub
Function GetVar(sName)
GetVar = DBlocks(sName)
End Function
Function SetVar(sName, sValue)
if ParsedBlocks.Exists(sName) then
ParsedBlocks(sName) = replace(replace(sValue, "{", "&#123;"), "}", "&#125;")
else
ParsedBlocks.add sName, replace(replace(sValue, "{", "&#123;"), "}", "&#125;")
end if
End Function
Function Parse(sTplName, bRepeat)
if ParsedBlocks.Exists(sTplName) then
if bRepeat then
ParsedBlocks(sTplName) = ParsedBlocks(sTplName) & ProceedTpl(DBlocks(sTplName))
else
ParsedBlocks(sTplName) = ProceedTpl(DBlocks(sTplName))
end if
else
ParsedBlocks.add sTplName, ProceedTpl(DBlocks(sTplName))
end if
End Function
Function PrintVar(sName)
PrintVar = ParsedBlocks(sName)
End function
Function ProceedTpl(sTpl)
Dim regEx, sMatch, oMatches, sName, sTTpl
sTTpl = sTpl
sMatch = getNextPattern(sTTpl, 1)
while len(sMatch) > 0
sName = mid(sMatch, 2, len(sMatch) - 2)
if ParsedBlocks.Exists(sName) then
sTTpl = replace(sTTpl, sMatch, ParsedBlocks(sName))
else
sTTpl = replace(sTTpl, sMatch, DBlocks(sName))
end if
sMatch = getNextPattern(sTTpl, 1)
wend
ProceedTpl = sTTpl
End Function
Function getNextPattern(str, begin)
Dim res, b, e, isOk
Dim w(5)
b = instr(begin, str, "{")
if b > 0 then
e = instr(b, str, "}")
w(1) = instr(b, str, " ")
w(2) = instr(b, str, ";")
w(3) = instr(b, str, ":")
w(4) = instr(b, str, "=")
w(5) = instr(b, str, "(")
isOk = true
For i = 1 to 5
if w(i) < e and w(i) > b then isOk = false
Next
if isOk then
res = mid(str, b, e - b + 1)
else
res = getNextPattern(str, e)
end if
else
res = ""
end if
getNextPattern = res
End Function
Function getBlock(sTemplate, sName)
Dim BBloc, EBlock, alpha
alpha = len(sName) + 12
BBlock = instr(sTemplate, "<!--Begin" & sName & "-->")
EBlock = instr(sTemplate, "<!--End" & sName & "-->")
if not (BBlock = 0 or EBlock = 0) then
getBlock = mid(sTemplate, BBlock + alpha, EBlock - BBlock - alpha)
else
getBlock = ""
end if
End Function
Function replaceBlock(sTemplate, sName)
Dim BBloc, EBlock
BBlock = instr(sTemplate, "<!--Begin" & sName & "-->")
EBlock = instr(sTemplate, "<!--End" & sName & "-->")
if not (BBlock = 0 or EBlock = 0) then
replaceBlock = left(sTemplate, BBlock - 1) & "{" & sName & "}" & right(sTemplate, len(sTemplate) - EBlock - len("<!--End" & sName & "-->") + 1)
else
replaceBlock = sTemplate
end if
end function
Function NextDBlockName(sTemplateName)
dim BTag, ETag, sName, sTemplate
sTemplate = DBlocks(sTemplateName)
BTag = instr(sTemplate, "<!--Begin")
if BTag > 0 then
ETag = instr(BTag, sTemplate, "-->")
sName = Mid(sTemplate, BTag + 9, ETag - (BTag + 9))
if instr(sTemplate, "<!--End" & sName & "-->") > 0 then
NextDBlockName = sName
else
NextDBlockName = ""
end if
else
NextDBlockName = ""
end if
End function
'Print all Dynamic Variables
Function PrintAll()
dim aPBlocks
dim aDBlocks
dim i, res
aPBlocks = ParsedBlocks.Items
aDBlocks = DBlocks.Items
res = "<table border=1>"
for i = 1 to UBound(aDBlocks)
res = res & "<tr><td><pre>" & ToHTML(aDBlocks(i)) & "</pre></td></tr>"
next
for i = 1 to UBound(aPBlocks)
res = res & "<tr><td><pre>" & ToHTML(aPBlocks(i)) & "</pre></td></tr>"
next
res = res & "</table>"
PrintAll = res
End Function
%>

View File

@@ -1,75 +0,0 @@
<SCRIPT LANGUAGE="JavaScript" RUNAT="Server">
// SESSION must be started like: http://dit03/facilitorwork/dijk?logging
function padout(number) { return (number < 10) ? '0' + number : number; }
function __LogAppend(s)
{
if (Session("logging")&&(Session("logging")&32))
{
var objFile, objText
var lPath = "C:/Temp/log_"+Session("customerId")+".html";
objFile = Server.CreateObject("Scripting.FileSystemObject");
var IsNew = (!objFile.FileExists(lPath))
objText = objFile.OpenTextFile(lPath, 8, true, 0);
objText.WriteLine(s);
objText.Close();
objText = null;
objFile = null;
}
}
function VB_Log(s) {
if (Session("logging")&&(Session("logging")&32))
{
var objFile, objText
// var lPath = "C:/Temp/log_"+Session("customerId")+".html";
var lPath = Server.MapPath("../../temp/flog_"+Session("customerId")+".html")
objFile = Server.CreateObject("Scripting.FileSystemObject");
var IsNew = (!objFile.FileExists(lPath))
objText = objFile.OpenTextFile(lPath, 8, true, 0);
if (IsNew)
{ objText.WriteLine("<style>");
objText.WriteLine("td {");
objText.WriteLine(" font-family: Verdana;");
objText.WriteLine(" font-size: smaller;");
objText.WriteLine(" font-weight: normal;");
objText.WriteLine(" color: #000000;");
objText.WriteLine(" text-decoration: none;");
objText.WriteLine(" padding-bottom: 2px;");
objText.WriteLine(" padding-top: 2px;");
objText.WriteLine(" padding-left: 2px;");
objText.WriteLine(" padding-right: 2px;");
objText.WriteLine(" background-color: #D6D8E8;");
objText.WriteLine("}");
objText.WriteLine("</style>");
objText.WriteLine("");
objText.WriteLine("<form action=./../shared/wisLog.asp>")
objText.WriteLine(" <input type=submit value=\"CLEAR this logfile\">");
objText.WriteLine("</form>");
objText.WriteLine("<table>"); // The closing </table> is never placed. IE doesn't care
objText.WriteLine("<tr><td colspan='3' align='center'>Logging was reset");
}
var now = new Date();
var sNow = now.getFullYear()+"/"+padout(now.getMonth()+1)+"/"+padout(now.getDate())+"&nbsp;"+
padout(now.getHours())+":"+padout(now.getMinutes())+":"+padout(now.getSeconds());
var x = Request.ServerVariables("URL")+"";
//x = x.substring(Session("wwwroot").length+1);
var ip = Request.ServerVariables("REMOTE_ADDR") + "";
// while (ip.indexOf(".") >= 0)
// ip = ip.substring(1)
ip = Request.ServerVariables("REMOTE_USER") + " " + ip
objText.WriteLine("</td></tr><tr><td valign='top' title='"+ ip + "'>" + Session("user_key") + " "+sNow+"<br>" + x + "</td><td>" +s+"");
objText.Close();
objText = null;
objFile = null;
}
}
</SCRIPT>

View File

@@ -1,376 +0,0 @@
<%
'--------------------------------------------------------------------
' Microsoft ADO
'
' (c) 1996-1998 Microsoft Corporation. All Rights Reserved.
'
'
'
' ADO constants include file for VBScript
'
'--------------------------------------------------------------------
'---- CursorTypeEnum Values ----
Const adOpenForwardOnly = 0
Const adOpenKeyset = 1
Const adOpenDynamic = 2
Const adOpenStatic = 3
'---- CursorOptionEnum Values ----
Const adHoldRecords = &H00000100
Const adMovePrevious = &H00000200
Const adAddNew = &H01000400
Const adDelete = &H01000800
Const adUpdate = &H01008000
Const adBookmark = &H00002000
Const adApproxPosition = &H00004000
Const adUpdateBatch = &H00010000
Const adResync = &H00020000
Const adNotify = &H00040000
Const adFind = &H00080000
Const adSeek = &H00400000
Const adIndex = &H00800000
'---- LockTypeEnum Values ----
Const adLockReadOnly = 1
Const adLockPessimistic = 2
Const adLockOptimistic = 3
Const adLockBatchOptimistic = 4
'---- ExecuteOptionEnum Values ----
Const adRunAsync = &H00000010
Const adAsyncExecute = &H00000010
Const adAsyncFetch = &H00000020
Const adAsyncFetchNonBlocking = &H00000040
Const adExecuteNoRecords = &H00000080
'---- ConnectOptionEnum Values ----
Const adAsyncConnect = &H00000010
'---- ObjectStateEnum Values ----
Const adStateClosed = &H00000000
Const adStateOpen = &H00000001
Const adStateConnecting = &H00000002
Const adStateExecuting = &H00000004
Const adStateFetching = &H00000008
'---- CursorLocationEnum Values ----
Const adUseServer = 2
Const adUseClient = 3
'---- DataTypeEnum Values ----
Const adEmpty = 0
Const adTinyInt = 16
Const adSmallInt = 2
Const adInteger = 3
Const adBigInt = 20
Const adUnsignedTinyInt = 17
Const adUnsignedSmallInt = 18
Const adUnsignedInt = 19
Const adUnsignedBigInt = 21
Const adSingle = 4
Const adDouble = 5
Const adCurrency = 6
Const adDecimal = 14
Const adNumeric = 131
Const adBoolean = 11
Const adError = 10
Const adUserDefined = 132
Const adVariant = 12
Const adIDispatch = 9
Const adIUnknown = 13
Const adGUID = 72
Const adDate = 7
Const adDBDate = 133
Const adDBTime = 134
Const adDBTimeStamp = 135
Const adBSTR = 8
Const adChar = 129
Const adVarChar = 200
Const adLongVarChar = 201
Const adWChar = 130
Const adVarWChar = 202
Const adLongVarWChar = 203
Const adBinary = 128
Const adVarBinary = 204
Const adLongVarBinary = 205
Const adChapter = 136
Const adFileTime = 64
Const adDBFileTime = 137
Const adPropVariant = 138
Const adVarNumeric = 139
'---- FieldAttributeEnum Values ----
Const adFldMayDefer = &H00000002
Const adFldUpdatable = &H00000004
Const adFldUnknownUpdatable = &H00000008
Const adFldFixed = &H00000010
Const adFldIsNullable = &H00000020
Const adFldMayBeNull = &H00000040
Const adFldLong = &H00000080
Const adFldRowID = &H00000100
Const adFldRowVersion = &H00000200
Const adFldCacheDeferred = &H00001000
Const adFldKeyColumn = &H00008000
'---- EditModeEnum Values ----
Const adEditNone = &H0000
Const adEditInProgress = &H0001
Const adEditAdd = &H0002
Const adEditDelete = &H0004
'---- RecordStatusEnum Values ----
Const adRecOK = &H0000000
Const adRecNew = &H0000001
Const adRecModified = &H0000002
Const adRecDeleted = &H0000004
Const adRecUnmodified = &H0000008
Const adRecInvalid = &H0000010
Const adRecMultipleChanges = &H0000040
Const adRecPendingChanges = &H0000080
Const adRecCanceled = &H0000100
Const adRecCantRelease = &H0000400
Const adRecConcurrencyViolation = &H0000800
Const adRecIntegrityViolation = &H0001000
Const adRecMaxChangesExceeded = &H0002000
Const adRecObjectOpen = &H0004000
Const adRecOutOfMemory = &H0008000
Const adRecPermissionDenied = &H0010000
Const adRecSchemaViolation = &H0020000
Const adRecDBDeleted = &H0040000
'---- GetRowsOptionEnum Values ----
Const adGetRowsRest = -1
'---- PositionEnum Values ----
Const adPosUnknown = -1
Const adPosBOF = -2
Const adPosEOF = -3
'---- enum Values ----
Const adBookmarkCurrent = 0
Const adBookmarkFirst = 1
Const adBookmarkLast = 2
'---- MarshalOptionsEnum Values ----
Const adMarshalAll = 0
Const adMarshalModifiedOnly = 1
'---- AffectEnum Values ----
Const adAffectCurrent = 1
Const adAffectGroup = 2
Const adAffectAll = 3
Const adAffectAllChapters = 4
'---- ResyncEnum Values ----
Const adResyncUnderlyingValues = 1
Const adResyncAllValues = 2
'---- CompareEnum Values ----
Const adCompareLessThan = 0
Const adCompareEqual = 1
Const adCompareGreaterThan = 2
Const adCompareNotEqual = 3
Const adCompareNotComparable = 4
'---- FilterGroupEnum Values ----
Const adFilterNone = 0
Const adFilterPendingRecords = 1
Const adFilterAffectedRecords = 2
Const adFilterFetchedRecords = 3
Const adFilterPredicate = 4
Const adFilterConflictingRecords = 5
'---- SearchDirectionEnum Values ----
Const adSearchForward = 1
Const adSearchBackward = -1
'---- PersistFormatEnum Values ----
Const adPersistADTG = 0
Const adPersistXML = 1
'---- StringFormatEnum Values ----
Const adStringXML = 0
Const adStringHTML = 1
Const adClipString = 2
'---- ConnectPromptEnum Values ----
Const adPromptAlways = 1
Const adPromptComplete = 2
Const adPromptCompleteRequired = 3
Const adPromptNever = 4
'---- ConnectModeEnum Values ----
Const adModeUnknown = 0
Const adModeRead = 1
Const adModeWrite = 2
Const adModeReadWrite = 3
Const adModeShareDenyRead = 4
Const adModeShareDenyWrite = 8
Const adModeShareExclusive = &Hc
Const adModeShareDenyNone = &H10
'---- IsolationLevelEnum Values ----
Const adXactUnspecified = &Hffffffff
Const adXactChaos = &H00000010
Const adXactReadUncommitted = &H00000100
Const adXactBrowse = &H00000100
Const adXactCursorStability = &H00001000
Const adXactReadCommitted = &H00001000
Const adXactRepeatableRead = &H00010000
Const adXactSerializable = &H00100000
Const adXactIsolated = &H00100000
'---- XactAttributeEnum Values ----
Const adXactCommitRetaining = &H00020000
Const adXactAbortRetaining = &H00040000
'---- PropertyAttributesEnum Values ----
Const adPropNotSupported = &H0000
Const adPropRequired = &H0001
Const adPropOptional = &H0002
Const adPropRead = &H0200
Const adPropWrite = &H0400
'---- ErrorValueEnum Values ----
Const adErrInvalidArgument = &Hbb9
Const adErrNoCurrentRecord = &Hbcd
Const adErrIllegalOperation = &Hc93
Const adErrInTransaction = &Hcae
Const adErrFeatureNotAvailable = &Hcb3
Const adErrItemNotFound = &Hcc1
Const adErrObjectInCollection = &Hd27
Const adErrObjectNotSet = &Hd5c
Const adErrDataConversion = &Hd5d
Const adErrObjectClosed = &He78
Const adErrObjectOpen = &He79
Const adErrProviderNotFound = &He7a
Const adErrBoundToCommand = &He7b
Const adErrInvalidParamInfo = &He7c
Const adErrInvalidConnection = &He7d
Const adErrNotReentrant = &He7e
Const adErrStillExecuting = &He7f
Const adErrOperationCancelled = &He80
Const adErrStillConnecting = &He81
Const adErrNotExecuting = &He83
Const adErrUnsafeOperation = &He84
'---- ParameterAttributesEnum Values ----
Const adParamSigned = &H0010
Const adParamNullable = &H0040
Const adParamLong = &H0080
'---- ParameterDirectionEnum Values ----
Const adParamUnknown = &H0000
Const adParamInput = &H0001
Const adParamOutput = &H0002
Const adParamInputOutput = &H0003
Const adParamReturnValue = &H0004
'---- CommandTypeEnum Values ----
Const adCmdUnknown = &H0008
Const adCmdText = &H0001
Const adCmdTable = &H0002
Const adCmdStoredProc = &H0004
Const adCmdFile = &H0100
Const adCmdTableDirect = &H0200
'---- EventStatusEnum Values ----
Const adStatusOK = &H0000001
Const adStatusErrorsOccurred = &H0000002
Const adStatusCantDeny = &H0000003
Const adStatusCancel = &H0000004
Const adStatusUnwantedEvent = &H0000005
'---- EventReasonEnum Values ----
Const adRsnAddNew = 1
Const adRsnDelete = 2
Const adRsnUpdate = 3
Const adRsnUndoUpdate = 4
Const adRsnUndoAddNew = 5
Const adRsnUndoDelete = 6
Const adRsnRequery = 7
Const adRsnResynch = 8
Const adRsnClose = 9
Const adRsnMove = 10
Const adRsnFirstChange = 11
Const adRsnMoveFirst = 12
Const adRsnMoveNext = 13
Const adRsnMovePrevious = 14
Const adRsnMoveLast = 15
'---- SchemaEnum Values ----
Const adSchemaProviderSpecific = -1
Const adSchemaAsserts = 0
Const adSchemaCatalogs = 1
Const adSchemaCharacterSets = 2
Const adSchemaCollations = 3
Const adSchemaColumns = 4
Const adSchemaCheckConstraints = 5
Const adSchemaConstraintColumnUsage = 6
Const adSchemaConstraintTableUsage = 7
Const adSchemaKeyColumnUsage = 8
Const adSchemaReferentialConstraints = 9
Const adSchemaTableConstraints = 10
Const adSchemaColumnsDomainUsage = 11
Const adSchemaIndexes = 12
Const adSchemaColumnPrivileges = 13
Const adSchemaTablePrivileges = 14
Const adSchemaUsagePrivileges = 15
Const adSchemaProcedures = 16
Const adSchemaSchemata = 17
Const adSchemaSQLLanguages = 18
Const adSchemaStatistics = 19
Const adSchemaTables = 20
Const adSchemaTranslations = 21
Const adSchemaProviderTypes = 22
Const adSchemaViews = 23
Const adSchemaViewColumnUsage = 24
Const adSchemaViewTableUsage = 25
Const adSchemaProcedureParameters = 26
Const adSchemaForeignKeys = 27
Const adSchemaPrimaryKeys = 28
Const adSchemaProcedureColumns = 29
Const adSchemaDBInfoKeywords = 30
Const adSchemaDBInfoLiterals = 31
Const adSchemaCubes = 32
Const adSchemaDimensions = 33
Const adSchemaHierarchies = 34
Const adSchemaLevels = 35
Const adSchemaMeasures = 36
Const adSchemaProperties = 37
Const adSchemaMembers = 38
'---- SeekEnum Values ----
Const adSeekFirstEQ = &H1
Const adSeekLastEQ = &H2
Const adSeekAfterEQ = &H4
Const adSeekAfter = &H8
Const adSeekBeforeEQ = &H10
Const adSeekBefore = &H20
'---- ADCPROP_UPDATECRITERIA_ENUM Values ----
Const adCriteriaKey = 0
Const adCriteriaAllCols = 1
Const adCriteriaUpdCols = 2
Const adCriteriaTimeStamp = 3
'---- ADCPROP_ASYNCTHREADPRIORITY_ENUM Values ----
Const adPriorityLowest = 1
Const adPriorityBelowNormal = 2
Const adPriorityNormal = 3
Const adPriorityAboveNormal = 4
Const adPriorityHighest = 5
'---- CEResyncEnum Values ----
Const adResyncNone = 0
Const adResyncAutoIncrement = 1
Const adResyncConflicts = 2
Const adResyncUpdates = 4
Const adResyncInserts = 8
Const adResyncAll = 15
'---- ADCPROP_AUTORECALC_ENUM Values ----
Const adRecalcUpFront = 0
Const adRecalcAlways = 1
%>

View File

@@ -1,355 +0,0 @@
<%
'
' Filename: fac_mgtrapgrid.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_mgtrapgrid CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_mgtrapgrid CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_mgtrapgrid.asp"
sTemplateFileName = "fac_mgtrapgrid.html"
'===============================
'===============================
' fac_mgtrapgrid PageSecurity begin
' fac_mgtrapgrid PageSecurity end
'===============================
'===============================
' fac_mgtrapgrid Open Event begin
' fac_mgtrapgrid Open Event end
'===============================
'===============================
' fac_mgtrapgrid OpenAnyPage Event begin
' fac_mgtrapgrid OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_mgtrapgrid Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
MgtrapGrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_mgtrapgrid Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_mgtrapgrid Close Event begin
' fac_mgtrapgrid Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub MgtrapGrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Dashboards"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 25
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
Dim sActionFileName : sActionFileName = "fac_mgtraprecord.asp"
SetVar "TransitParams", ""
SetVar "FormParams", ""
'-------------------------------
' Build ORDER BY statement
'-------------------------------
sOrder = " order by F.FAC_MGTRAP_OMSCHRIJVING Asc"
iSort = GetParam("FormMgtrapGrid_Sorting")
iSorted = GetParam("FormMgtrapGrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormMgtrapGrid_Sorting=" & iSort & "&FormMgtrapGrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormMgtrapGrid_Sorting=" & iSort & "&FormMgtrapGrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by F.FAC_MGTRAP_KEY" & sDirection
if iSort = 2 then sOrder = " order by F.FAC_MGTRAP_OMSCHRIJVING" & sDirection
if iSort = 3 then sOrder = " order by F.FAC_MGTRAP_VIEW_NAME" & sDirection
if iSort = 4 then sOrder = " order by F.FAC_MGTRAP_INFO" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select F.FAC_MGTRAP_INFO as F_FAC_MGTRAP_INFO, " & _
"F.FAC_MGTRAP_KEY as F_FAC_MGTRAP_KEY, " & _
"F.FAC_MGTRAP_OMSCHRIJVING as F_FAC_MGTRAP_OMSCHRIJVING, " & _
"F.FAC_MGTRAP_VIEW_NAME as F_FAC_MGTRAP_VIEW_NAME " & _
" from FAC_MGTRAP F "
'-------------------------------
'-------------------------------
' MgtrapGrid Open Event begin
' MgtrapGrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the link to the record page
'-------------------------------
SetVar "FormAction", sActionFileName
'-------------------------------
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListMgtrapGrid", ""
Parse "MgtrapGridNoRecords", False
SetVar "MgtrapGridNavigator", ""
Parse "FormMgtrapGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 25
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormMgtrapGrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "MgtrapGridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldFAC_MGTRAP_INFO = GetValue(rs, "F_FAC_MGTRAP_INFO")
fldFAC_MGTRAP_KEY_URLLink = "fac_mgtraprecord.asp"
fldFAC_MGTRAP_KEY_FAC_MGTRAP_KEY = GetValue(rs, "F_FAC_MGTRAP_KEY")
fldFAC_MGTRAP_KEY = GetValue(rs, "F_FAC_MGTRAP_KEY")
fldFAC_MGTRAP_OMSCHRIJVING_URLLink = "fac_mgtraprecord.asp"
fldFAC_MGTRAP_OMSCHRIJVING_FAC_MGTRAP_KEY = GetValue(rs, "F_FAC_MGTRAP_KEY")
fldFAC_MGTRAP_OMSCHRIJVING = GetValue(rs, "F_FAC_MGTRAP_OMSCHRIJVING")
fldFAC_MGTRAP_VIEW_NAME = GetValue(rs, "F_FAC_MGTRAP_VIEW_NAME")
'-------------------------------
' MgtrapGrid Show begin
'-------------------------------
'-------------------------------
' MgtrapGrid Show Event begin
' MgtrapGrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "FAC_MGTRAP_KEY", ToHTML(fldFAC_MGTRAP_KEY)
SetVar "FAC_MGTRAP_KEY_URLLink", fldFAC_MGTRAP_KEY_URLLink
SetVar "PrmFAC_MGTRAP_KEY_FAC_MGTRAP_KEY", ToURL(fldFAC_MGTRAP_KEY_FAC_MGTRAP_KEY)
SetVar "FAC_MGTRAP_OMSCHRIJVING", ToHTML(fldFAC_MGTRAP_OMSCHRIJVING)
SetVar "FAC_MGTRAP_OMSCHRIJVING_URLLink", fldFAC_MGTRAP_OMSCHRIJVING_URLLink
SetVar "PrmFAC_MGTRAP_OMSCHRIJVING_FAC_MGTRAP_KEY", ToURL(fldFAC_MGTRAP_OMSCHRIJVING_FAC_MGTRAP_KEY)
SetVar "FAC_MGTRAP_VIEW_NAME", ToHTML(fldFAC_MGTRAP_VIEW_NAME)
SetVar "FAC_MGTRAP_INFO", ToHTML(fldFAC_MGTRAP_INFO)
Parse "DListMgtrapGrid", True
'-------------------------------
' MgtrapGrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' MgtrapGrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "MgtrapGridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "MgtrapGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "MgtrapGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "MgtrapGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "MgtrapGridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "MgtrapGridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "MgtrapGridCurrentPage", iPage
Parse "MgtrapGridNavigator", False
end if
'-------------------------------
' MgtrapGrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "MgtrapGridNoRecords", ""
Parse "FormMgtrapGrid", False
'-------------------------------
' MgtrapGrid Close Event begin
' MgtrapGrid Close Event end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,66 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Dashboards</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormMgtrapGridHeader-->
<!--EndFormMgtrapGridHeader-->
<!--BeginFormMgtrapGrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="4"><a name="MgtrapGrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormMgtrapGrid_Sorting=1&FormMgtrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Key</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormMgtrapGrid_Sorting=2&FormMgtrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Omschrijving</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormMgtrapGrid_Sorting=3&FormMgtrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Viewname</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormMgtrapGrid_Sorting=4&FormMgtrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Info</font></a></td>
</tr>
<!--BeginDListMgtrapGrid-->
<tr>
<td class="DataTD"><a href="{FAC_MGTRAP_KEY_URLLink}?FAC_MGTRAP_KEY={PrmFAC_MGTRAP_KEY_FAC_MGTRAP_KEY}&{TransitParams}"><font class="DataFONT">{FAC_MGTRAP_KEY}</font></a>&nbsp;</td>
<td class="DataTD"><a href="{FAC_MGTRAP_OMSCHRIJVING_URLLink}?FAC_MGTRAP_KEY={PrmFAC_MGTRAP_OMSCHRIJVING_FAC_MGTRAP_KEY}&{TransitParams}"><font class="DataFONT">{FAC_MGTRAP_OMSCHRIJVING}</font></a>&nbsp;</td>
<td class="DataTD"><font class="DataFONT">{FAC_MGTRAP_VIEW_NAME}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_MGTRAP_INFO}&nbsp;</font></td>
</tr>
<!--EndDListMgtrapGrid-->
<!--BeginMgtrapGridNoRecords-->
<tr><td colspan="4" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndMgtrapGridNoRecords-->
<tr>
<td colspan="4" class="ColumnTD">
<font class="ColumnFONT">
<a href="{FormAction}?{TransitParams}"><font class="ColumnFONT">Toevoegen</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<!--BeginMgtrapGridNavigator-->
<a href{MgtrapGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormMgtrapGrid_Page=1#MgtrapGrid"><font class="ColumnFONT"><<</font></a>
<a href{MgtrapGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormMgtrapGrid_Page={PrevPage}#MgtrapGrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginMgtrapGridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormMgtrapGrid_Page={NavigatorPageNumber}#MgtrapGrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndMgtrapGridNavigatorPages-->van {MgtrapGridPageCount} ]
<a href{MgtrapGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormMgtrapGrid_Page={NextPage}#MgtrapGrid"><font class="ColumnFONT">></font></a>
<a href{MgtrapGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormMgtrapGrid_Page=last#MgtrapGrid"><font class="ColumnFONT">>></font></a>
<!--EndMgtrapGridNavigator-->
</font>
</td>
</tr>
</table>
<!--EndFormMgtrapGrid-->
<!--BeginFormMgtrapGridFooter-->
<!--EndFormMgtrapGridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,414 +0,0 @@
<%
'
' Filename: fac_mgtraprecord.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_mgtraprecord CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_mgtraprecord CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_mgtraprecord.asp"
sTemplateFileName = "fac_mgtraprecord.html"
'===============================
'===============================
' fac_mgtraprecord PageSecurity begin
' fac_mgtraprecord PageSecurity end
'===============================
'===============================
' fac_mgtraprecord Open Event begin
' fac_mgtraprecord Open Event end
'===============================
'===============================
' fac_mgtraprecord OpenAnyPage Event begin
' fac_mgtraprecord OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_mgtraprecord Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sMgtrapRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "MgtrapRecord"
MgtrapRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
MgtrapRecord_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_mgtraprecord Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_mgtraprecord Close Event begin
' fac_mgtraprecord Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub MgtrapRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKFAC_MGTRAP_KEY : pPKFAC_MGTRAP_KEY = ""
Dim fldFAC_MGTRAP_OMSCHRIJVING : fldFAC_MGTRAP_OMSCHRIJVING = ""
Dim fldFAC_MGTRAP_VIEW_NAME : fldFAC_MGTRAP_VIEW_NAME = ""
Dim fldFAC_MGTRAP_INFO : fldFAC_MGTRAP_INFO = ""
Dim fldFAC_MGTRAP_WAARDE1 : fldFAC_MGTRAP_WAARDE1 = ""
Dim fldFAC_MGTRAP_WAARDE2 : fldFAC_MGTRAP_WAARDE2 = ""
Dim fldFAC_MGTRAP_WAARDE3 : fldFAC_MGTRAP_WAARDE3 = ""
Dim fldFAC_MGTRAP_WAARDE4 : fldFAC_MGTRAP_WAARDE4 = ""
Dim fldFAC_FUNCTIE_KEY : fldFAC_FUNCTIE_KEY = ""
'-------------------------------
'-------------------------------
' MgtrapRecord Action begin
'-------------------------------
sActionFileName = "fac_mgtrapgrid.asp"
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' MgtrapRecord BeforeCancel Event begin
' MgtrapRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKFAC_MGTRAP_KEY = GetParam("PK_FAC_MGTRAP_KEY")
if IsEmpty(pPKFAC_MGTRAP_KEY) then exit sub
sWhere = "FAC_MGTRAP_KEY=" & ToSQL(pPKFAC_MGTRAP_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldFAC_MGTRAP_OMSCHRIJVING = GetParam("FAC_MGTRAP_OMSCHRIJVING")
fldFAC_MGTRAP_VIEW_NAME = GetParam("FAC_MGTRAP_VIEW_NAME")
fldFAC_MGTRAP_INFO = GetParam("FAC_MGTRAP_INFO")
fldFAC_MGTRAP_WAARDE1 = GetParam("FAC_MGTRAP_WAARDE1")
fldFAC_MGTRAP_WAARDE2 = GetParam("FAC_MGTRAP_WAARDE2")
fldFAC_MGTRAP_WAARDE3 = GetParam("FAC_MGTRAP_WAARDE3")
fldFAC_MGTRAP_WAARDE4 = GetParam("FAC_MGTRAP_WAARDE4")
fldFAC_FUNCTIE_KEY = GetParam("FAC_FUNCTIE_KEY")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if not isNumeric(fldFAC_MGTRAP_WAARDE1) then
sMgtrapRecordErr = sMgtrapRecordErr & "De waarde in veld Waarde 1 is niet correct.<br>"
end if
if not isNumeric(fldFAC_MGTRAP_WAARDE2) then
sMgtrapRecordErr = sMgtrapRecordErr & "De waarde in veld Waarde 2 is niet correct.<br>"
end if
if not isNumeric(fldFAC_MGTRAP_WAARDE3) then
sMgtrapRecordErr = sMgtrapRecordErr & "De waarde in veld Waarde 3 is niet correct.<br>"
end if
if not isNumeric(fldFAC_MGTRAP_WAARDE4) then
sMgtrapRecordErr = sMgtrapRecordErr & "De waarde in veld Waarde 4 is niet correct.<br>"
end if
if not isNumeric(fldFAC_FUNCTIE_KEY) then
sMgtrapRecordErr = sMgtrapRecordErr & "De waarde in veld Autorisatie als is niet correct.<br>"
end if
'-------------------------------
' MgtrapRecord Check Event begin
' MgtrapRecord Check Event end
'-------------------------------
If len(sMgtrapRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' MgtrapRecord Insert Event begin
' MgtrapRecord Insert Event end
'-------------------------------
sSQL = "insert into FAC_MGTRAP (" & _
"FAC_MGTRAP_OMSCHRIJVING," & _
"FAC_MGTRAP_VIEW_NAME," & _
"FAC_MGTRAP_INFO," & _
"FAC_MGTRAP_WAARDE1," & _
"FAC_MGTRAP_WAARDE2," & _
"FAC_MGTRAP_WAARDE3," & _
"FAC_MGTRAP_WAARDE4," & _
"FAC_FUNCTIE_KEY)" & _
" values (" & _
ToSQL(fldFAC_MGTRAP_OMSCHRIJVING, "Text") & "," & _
ToSQL(fldFAC_MGTRAP_VIEW_NAME, "Text") & "," & _
ToSQL(fldFAC_MGTRAP_INFO, "Text") & "," & _
ToSQL(fldFAC_MGTRAP_WAARDE1, "Number") & "," & _
ToSQL(fldFAC_MGTRAP_WAARDE2, "Number") & "," & _
ToSQL(fldFAC_MGTRAP_WAARDE3, "Number") & "," & _
ToSQL(fldFAC_MGTRAP_WAARDE4, "Number") & "," & _
ToSQL(fldFAC_FUNCTIE_KEY, "Number") & _
")"
case "update"
'-------------------------------
' MgtrapRecord Update Event begin
' MgtrapRecord Update Event end
'-------------------------------
sSQL = "update FAC_MGTRAP set " & _
"FAC_MGTRAP_OMSCHRIJVING=" & ToSQL(fldFAC_MGTRAP_OMSCHRIJVING, "Text") & _
",FAC_MGTRAP_VIEW_NAME=" & ToSQL(fldFAC_MGTRAP_VIEW_NAME, "Text") & _
",FAC_MGTRAP_INFO=" & ToSQL(fldFAC_MGTRAP_INFO, "Text") & _
",FAC_MGTRAP_WAARDE1=" & ToSQL(fldFAC_MGTRAP_WAARDE1, "Number") & _
",FAC_MGTRAP_WAARDE2=" & ToSQL(fldFAC_MGTRAP_WAARDE2, "Number") & _
",FAC_MGTRAP_WAARDE3=" & ToSQL(fldFAC_MGTRAP_WAARDE3, "Number") & _
",FAC_MGTRAP_WAARDE4=" & ToSQL(fldFAC_MGTRAP_WAARDE4, "Number") & _
",FAC_FUNCTIE_KEY=" & ToSQL(fldFAC_FUNCTIE_KEY, "Number")
sSQL = sSQL & " where " & sWhere
case "delete"
'-------------------------------
' MgtrapRecord Delete Event begin
' MgtrapRecord Delete Event end
'-------------------------------
sSQL = "delete from FAC_MGTRAP where " & sWhere
end select
'-------------------------------
'-------------------------------
' MgtrapRecord BeforeExecute Event begin
' MgtrapRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sMgtrapRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sMgtrapRecordErr = ProcessError
on error goto 0
if len(sMgtrapRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName
'-------------------------------
' MgtrapRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub MgtrapRecord_Show()
'-------------------------------
' MgtrapRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Details dashboard"
Dim bPK : bPK = True
Dim sFAC_FUNCTIE_KEYDisplayValue: sFAC_FUNCTIE_KEYDisplayValue = ""
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sMgtrapRecordErr = "" then
pFAC_MGTRAP_KEY = GetParam("FAC_MGTRAP_KEY")
SetVar "MgtrapRecordError", ""
else
fldFAC_MGTRAP_OMSCHRIJVING = GetParam("FAC_MGTRAP_OMSCHRIJVING")
fldFAC_MGTRAP_VIEW_NAME = GetParam("FAC_MGTRAP_VIEW_NAME")
fldFAC_MGTRAP_INFO = GetParam("FAC_MGTRAP_INFO")
fldFAC_MGTRAP_WAARDE1 = GetParam("FAC_MGTRAP_WAARDE1")
fldFAC_MGTRAP_WAARDE2 = GetParam("FAC_MGTRAP_WAARDE2")
fldFAC_MGTRAP_WAARDE3 = GetParam("FAC_MGTRAP_WAARDE3")
fldFAC_MGTRAP_WAARDE4 = GetParam("FAC_MGTRAP_WAARDE4")
fldFAC_FUNCTIE_KEY = GetParam("FAC_FUNCTIE_KEY")
pFAC_MGTRAP_KEY = GetParam("PK_FAC_MGTRAP_KEY")
SetVar "sMgtrapRecordErr", sMgtrapRecordErr
SetVar "FormTitle", sFormTitle
Parse "MgtrapRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pFAC_MGTRAP_KEY) then bPK = False
sWhere = sWhere & "FAC_MGTRAP_KEY=" & ToSQL(pFAC_MGTRAP_KEY, "Number")
SetVar "PK_FAC_MGTRAP_KEY", pFAC_MGTRAP_KEY
'-------------------------------
'-------------------------------
' MgtrapRecord Open Event begin
' MgtrapRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_MGTRAP where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "MgtrapRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldFAC_MGTRAP_KEY = GetValue(rs, "FAC_MGTRAP_KEY")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sMgtrapRecordErr = "" then
fldFAC_MGTRAP_OMSCHRIJVING = GetValue(rs, "FAC_MGTRAP_OMSCHRIJVING")
fldFAC_MGTRAP_VIEW_NAME = GetValue(rs, "FAC_MGTRAP_VIEW_NAME")
fldFAC_MGTRAP_INFO = GetValue(rs, "FAC_MGTRAP_INFO")
fldFAC_MGTRAP_WAARDE1 = GetValue(rs, "FAC_MGTRAP_WAARDE1")
fldFAC_MGTRAP_WAARDE2 = GetValue(rs, "FAC_MGTRAP_WAARDE2")
fldFAC_MGTRAP_WAARDE3 = GetValue(rs, "FAC_MGTRAP_WAARDE3")
fldFAC_MGTRAP_WAARDE4 = GetValue(rs, "FAC_MGTRAP_WAARDE4")
fldFAC_FUNCTIE_KEY = GetValue(rs, "FAC_FUNCTIE_KEY")
end if
SetVar "MgtrapRecordInsert", ""
Parse "MgtrapRecordEdit", False
'-------------------------------
' MgtrapRecord ShowEdit Event begin
' MgtrapRecord ShowEdit Event end
'-------------------------------
else
SetVar "MgtrapRecordEdit", ""
Parse "MgtrapRecordInsert", False
'-------------------------------
' MgtrapRecord ShowInsert Event begin
' MgtrapRecord ShowInsert Event end
'-------------------------------
end if
Parse "MgtrapRecordCancel", false
'-------------------------------
' MgtrapRecord Show Event begin
' MgtrapRecord Show Event end
'-------------------------------
'-------------------------------
' Show form field
'-------------------------------
SetVar "FAC_MGTRAP_KEY", ToHTML(fldFAC_MGTRAP_KEY)
SetVar "FAC_MGTRAP_OMSCHRIJVING", ToHTML(fldFAC_MGTRAP_OMSCHRIJVING)
SetVar "FAC_MGTRAP_VIEW_NAME", ToHTML(fldFAC_MGTRAP_VIEW_NAME)
SetVar "FAC_MGTRAP_INFO", ToHTML(fldFAC_MGTRAP_INFO)
SetVar "FAC_MGTRAP_WAARDE1", ToHTML(fldFAC_MGTRAP_WAARDE1)
SetVar "FAC_MGTRAP_WAARDE2", ToHTML(fldFAC_MGTRAP_WAARDE2)
SetVar "FAC_MGTRAP_WAARDE3", ToHTML(fldFAC_MGTRAP_WAARDE3)
SetVar "FAC_MGTRAP_WAARDE4", ToHTML(fldFAC_MGTRAP_WAARDE4)
SetVar "MgtrapRecordLBFAC_FUNCTIE_KEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sFAC_FUNCTIE_KEYDisplayValue
Parse "MgtrapRecordLBFAC_FUNCTIE_KEY", True
openrs rsFAC_FUNCTIE_KEY, "select fac_functie_key, fac_functie_omschrijving from fac_functie order by fac_functie_omschrijving asc"
while not rsFAC_FUNCTIE_KEY.EOF
SetVar "ID", GetValue(rsFAC_FUNCTIE_KEY, 0) : SetVar "Value", GetValue(rsFAC_FUNCTIE_KEY, 1)
if cstr(GetValue(rsFAC_FUNCTIE_KEY, 0)) = cstr(fldFAC_FUNCTIE_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "MgtrapRecordLBFAC_FUNCTIE_KEY", True
rsFAC_FUNCTIE_KEY.MoveNext
wend
set rsFAC_FUNCTIE_KEY = nothing
Parse "FormMgtrapRecord", False
'-------------------------------
' MgtrapRecord Close Event begin
' MgtrapRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' MgtrapRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,120 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Details Dashboards</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormMgtrapRecordHeader-->
<!--EndFormMgtrapRecordHeader-->
<!--BeginFormMgtrapRecord-->
<form method="POST" action="{FileName}" name="MgtrapRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginMgtrapRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sMgtrapRecordErr}</font></td>
</tr>
<!--EndMgtrapRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_MGTRAP_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Omschrijving</font></td>
<td class="DataTD"><input type="text" name="FAC_MGTRAP_OMSCHRIJVING" maxlength="60" value="{FAC_MGTRAP_OMSCHRIJVING}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Viewname</font></td>
<td class="DataTD"><input type="text" name="FAC_MGTRAP_VIEW_NAME" maxlength="32" value="{FAC_MGTRAP_VIEW_NAME}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Info</font></td>
<td class="DataTD"><textarea name="FAC_MGTRAP_INFO" cols="72" rows="3">{FAC_MGTRAP_INFO}</textarea></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Waarde 1</font></td>
<td class="DataTD"><input type="text" name="FAC_MGTRAP_WAARDE1" maxlength="100" value="{FAC_MGTRAP_WAARDE1}" size="32"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Waarde 2</font></td>
<td class="DataTD"><input type="text" name="FAC_MGTRAP_WAARDE2" maxlength="100" value="{FAC_MGTRAP_WAARDE2}" size="32"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Waarde 3</font></td>
<td class="DataTD"><input type="text" name="FAC_MGTRAP_WAARDE3" maxlength="100" value="{FAC_MGTRAP_WAARDE3}" size="32"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Waarde 4</font></td>
<td class="DataTD"><input type="text" name="FAC_MGTRAP_WAARDE4" maxlength="100" value="{FAC_MGTRAP_WAARDE4}" size="32"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Autorisatie als</font></td>
<td class="DataTD"><select name="FAC_FUNCTIE_KEY"><!--BeginMgtrapRecordLBFAC_FUNCTIE_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndMgtrapRecordLBFAC_FUNCTIE_KEY--></select></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginMgtrapRecordInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.MgtrapRecord.FormAction.value = 'insert';">
<!--EndMgtrapRecordInsert-->
<!--BeginMgtrapRecordEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginMgtrapRecordUpdate-->
<input type="submit" value="Bewaren" onclick="document.MgtrapRecord.FormAction.value = 'update';"/>
<!--EndMgtrapRecordUpdate-->
<!--BeginMgtrapRecordDelete-->
<input type="submit" value="Verwijderen" onclick="document.MgtrapRecord.FormAction.value = 'delete';"/>
<!--EndMgtrapRecordDelete-->
<!--EndMgtrapRecordEdit-->
<!--BeginMgtrapRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.MgtrapRecord.FormAction.value = 'cancel';"/>
<!--EndMgtrapRecordCancel-->
<input type="hidden" name="FormName" value="MgtrapRecord"/>
<input type="hidden" name="PK_FAC_MGTRAP_KEY" value="{PK_FAC_MGTRAP_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormMgtrapRecord-->
<!--BeginFormMgtrapRecordFooter-->
<!--EndFormMgtrapRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,351 +0,0 @@
<%
'
' Filename: fac_notificatiejobgrid.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_notificatiejobgrid CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_notificatiejobgrid CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_notificatiejobgrid.asp"
sTemplateFileName = "fac_notificatiejobgrid.html"
'===============================
'===============================
' fac_notificatiejobgrid PageSecurity begin
' fac_notificatiejobgrid PageSecurity end
'===============================
'===============================
' fac_notificatiejobgrid Open Event begin
' fac_notificatiejobgrid Open Event end
'===============================
'===============================
' fac_notificatiejobgrid OpenAnyPage Event begin
' fac_notificatiejobgrid OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_notificatiejobgrid Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
NotificatieJobGrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_notificatiejobgrid Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_notificatiejobgrid Close Event begin
' fac_notificatiejobgrid Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub NotificatieJobGrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Notificatiejobs"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 25
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
SetVar "TransitParams", ""
SetVar "FormParams", ""
'-------------------------------
' Build ORDER BY statement
'-------------------------------
sOrder = " order by F.FAC_NOTIFICATIE_JOB_OMS Asc"
iSort = GetParam("FormNotificatieJobGrid_Sorting")
iSorted = GetParam("FormNotificatieJobGrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormNotificatieJobGrid_Sorting=" & iSort & "&FormNotificatieJobGrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormNotificatieJobGrid_Sorting=" & iSort & "&FormNotificatieJobGrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by F.FAC_NOTIFICATIE_JOB_OMS" & sDirection
if iSort = 2 then sOrder = " order by F.FAC_NOTIFICATIE_JOB_MODE" & sDirection
if iSort = 3 then sOrder = " order by F.FAC_NOTIFICATIE_JOB_INTERVAL" & sDirection
if iSort = 4 then sOrder = " order by F.FAC_NOTIFICATIE_JOB_NEXTRUN" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select F.FAC_NOTIFICATIE_JOB_INTERVAL as F_FAC_NOTIFICATIE_JOB_INTERVAL, " & _
"F.FAC_NOTIFICATIE_JOB_KEY as F_FAC_NOTIFICATIE_JOB_KEY, " & _
"F.FAC_NOTIFICATIE_JOB_MODE as F_FAC_NOTIFICATIE_JOB_MODE, " & _
"F.FAC_NOTIFICATIE_JOB_NEXTRUN as F_FAC_NOTIFICATIE_JOB_NEXTRUN, " & _
"F.FAC_NOTIFICATIE_JOB_OMS as F_FAC_NOTIFICATIE_JOB_OMS " & _
" from FAC_NOTIFICATIE_JOB F "
'-------------------------------
'-------------------------------
' NotificatieJobGrid Open Event begin
' NotificatieJobGrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListNotificatieJobGrid", ""
Parse "NotificatieJobGridNoRecords", False
SetVar "NotificatieJobGridNavigator", ""
Parse "FormNotificatieJobGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 25
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormNotificatieJobGrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "NotificatieJobGridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldFAC_NOTIFICATIE_JOB_INTERVAL = GetValue(rs, "F_FAC_NOTIFICATIE_JOB_INTERVAL")
fldFAC_NOTIFICATIE_JOB_KEY = GetValue(rs, "F_FAC_NOTIFICATIE_JOB_KEY")
fldFAC_NOTIFICATIE_JOB_MODE = GetValue(rs, "F_FAC_NOTIFICATIE_JOB_MODE")
fldFAC_NOTIFICATIE_JOB_NEXTRUN = GetValue(rs, "F_FAC_NOTIFICATIE_JOB_NEXTRUN")
fldFAC_NOTIFICATIE_JOB_OMS_URLLink = "fac_notificatiejobrecord.asp"
fldFAC_NOTIFICATIE_JOB_OMS_FAC_NOTIFICATIE_JOB_KEY = GetValue(rs, "F_FAC_NOTIFICATIE_JOB_KEY")
fldFAC_NOTIFICATIE_JOB_OMS = GetValue(rs, "F_FAC_NOTIFICATIE_JOB_OMS")
'-------------------------------
' NotificatieJobGrid Show begin
'-------------------------------
'-------------------------------
' NotificatieJobGrid Show Event begin
fldBIT0_STATUS = fldFAC_SRTNOTIFICATIE_MODE AND 1 ' &B0001
fldBIT1_MAIL = fldFAC_SRTNOTIFICATIE_MODE AND 2 ' &B0100
fldBIT2_SMS = fldFAC_SRTNOTIFICATIE_MODE AND 4 ' &B0010
fldBIT3_ALERT = fldFAC_SRTNOTIFICATIE_MODE AND 8 ' &B1000
' NotificatieJobGrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "FAC_NOTIFICATIE_JOB_KEY", ToHTML(fldFAC_NOTIFICATIE_JOB_KEY)
SetVar "FAC_NOTIFICATIE_JOB_OMS", ToHTML(fldFAC_NOTIFICATIE_JOB_OMS)
SetVar "FAC_NOTIFICATIE_JOB_OMS_URLLink", fldFAC_NOTIFICATIE_JOB_OMS_URLLink
SetVar "PrmFAC_NOTIFICATIE_JOB_OMS_FAC_NOTIFICATIE_JOB_KEY", ToURL(fldFAC_NOTIFICATIE_JOB_OMS_FAC_NOTIFICATIE_JOB_KEY)
SetVar "FAC_NOTIFICATIE_JOB_MODE", ToHTML(fldFAC_NOTIFICATIE_JOB_MODE)
SetVar "FAC_NOTIFICATIE_JOB_INTERVAL", ToHTML(fldFAC_NOTIFICATIE_JOB_INTERVAL)
SetVar "FAC_NOTIFICATIE_JOB_NEXTRUN", ToHTML(fldFAC_NOTIFICATIE_JOB_NEXTRUN)
Parse "DListNotificatieJobGrid", True
'-------------------------------
' NotificatieJobGrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' NotificatieJobGrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "NotificatieJobGridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "NotificatieJobGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "NotificatieJobGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "NotificatieJobGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "NotificatieJobGridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "NotificatieJobGridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "NotificatieJobGridCurrentPage", iPage
Parse "NotificatieJobGridNavigator", False
end if
'-------------------------------
' NotificatieJobGrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "NotificatieJobGridNoRecords", ""
Parse "FormNotificatieJobGrid", False
'-------------------------------
' NotificatieJobGrid Close Event begin
' NotificatieJobGrid Close Event end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,65 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Notificaties</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormNotificatieJobGridHeader-->
<!--EndFormNotificatieJobGridHeader-->
<!--BeginFormNotificatieJobGrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="4"><a name="NotificatieJobGrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormNotificatieJobGrid_Sorting=1&FormNotificatieJobGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Omschrijving</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormNotificatieJobGrid_Sorting=2&FormNotificatieJobGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Mode</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormNotificatieJobGrid_Sorting=3&FormNotificatieJobGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Interval</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormNotificatieJobGrid_Sorting=4&FormNotificatieJobGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">NextRun</font></a></td>
</tr>
<!--BeginDListNotificatieJobGrid-->
<tr>
<td class="DataTD"><a href="{FAC_NOTIFICATIE_JOB_OMS_URLLink}?FAC_NOTIFICATIE_JOB_KEY={PrmFAC_NOTIFICATIE_JOB_OMS_FAC_NOTIFICATIE_JOB_KEY}&{TransitParams}"><font class="DataFONT">{FAC_NOTIFICATIE_JOB_OMS}</font></a>&nbsp;</td>
<td class="DataTD"><font class="DataFONT">{FAC_NOTIFICATIE_JOB_MODE}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_NOTIFICATIE_JOB_INTERVAL}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_NOTIFICATIE_JOB_NEXTRUN}&nbsp;</font></td>
</tr>
<!--EndDListNotificatieJobGrid-->
<!--BeginNotificatieJobGridNoRecords-->
<tr><td colspan="4" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndNotificatieJobGridNoRecords-->
<!--BeginNotificatieJobGridNavigator-->
<tr>
<td colspan="4" class="ColumnTD">
<font class="ColumnFONT">
<a href{NotificatieJobGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormNotificatieJobGrid_Page=1#NotificatieJobGrid"><font class="ColumnFONT"><<</font></a>
<a href{NotificatieJobGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormNotificatieJobGrid_Page={PrevPage}#NotificatieJobGrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginNotificatieJobGridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormNotificatieJobGrid_Page={NavigatorPageNumber}#NotificatieJobGrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndNotificatieJobGridNavigatorPages-->van {NotificatieJobGridPageCount} ]
<a href{NotificatieJobGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormNotificatieJobGrid_Page={NextPage}#NotificatieJobGrid"><font class="ColumnFONT">></font></a>
<a href{NotificatieJobGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormNotificatieJobGrid_Page=last#NotificatieJobGrid"><font class="ColumnFONT">>></font></a>
</font>
</td>
</tr>
<!--EndNotificatieJobGridNavigator-->
</table>
<!--EndFormNotificatieJobGrid-->
<!--BeginFormNotificatieJobGridFooter-->
<!--EndFormNotificatieJobGridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,378 +0,0 @@
<%
'
' Filename: fac_notificatiejobrecord.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_notificatiejobrecord CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_notificatiejobrecord CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_notificatiejobrecord.asp"
sTemplateFileName = "fac_notificatiejobrecord.html"
'===============================
'===============================
' fac_notificatiejobrecord PageSecurity begin
' fac_notificatiejobrecord PageSecurity end
'===============================
'===============================
' fac_notificatiejobrecord Open Event begin
' fac_notificatiejobrecord Open Event end
'===============================
'===============================
' fac_notificatiejobrecord OpenAnyPage Event begin
' fac_notificatiejobrecord OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_notificatiejobrecord Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sNotificatieRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "NotificatieRecord"
NotificatieRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
NotificatieRecord_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_notificatiejobrecord Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_notificatiejobrecord Close Event begin
' fac_notificatiejobrecord Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub NotificatieRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKFAC_NOTIFICATIE_JOB_KEY : pPKFAC_NOTIFICATIE_JOB_KEY = ""
Dim fldFAC_NOTIFICATIE_JOB_OMS : fldFAC_NOTIFICATIE_JOB_OMS = ""
Dim fldFAC_NOTIFICATIE_JOB_VIEW : fldFAC_NOTIFICATIE_JOB_VIEW = ""
Dim fldFAC_NOTIFICATIE_JOB_MODE : fldFAC_NOTIFICATIE_JOB_MODE = ""
Dim fldFAC_NOTIFICATIE_JOB_INTERVAL : fldFAC_NOTIFICATIE_JOB_INTERVAL = ""
Dim fldFAC_NOTIFICATIE_JOB_NEXTRUN : fldFAC_NOTIFICATIE_JOB_NEXTRUN = ""
'-------------------------------
'-------------------------------
' NotificatieRecord Action begin
'-------------------------------
sActionFileName = "fac_notificatiejobgrid.asp"
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' NotificatieRecord BeforeCancel Event begin
' NotificatieRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKFAC_NOTIFICATIE_JOB_KEY = GetParam("PK_FAC_NOTIFICATIE_JOB_KEY")
if IsEmpty(pPKFAC_NOTIFICATIE_JOB_KEY) then exit sub
sWhere = "FAC_NOTIFICATIE_JOB_KEY=" & ToSQL(pPKFAC_NOTIFICATIE_JOB_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldFAC_NOTIFICATIE_JOB_OMS = GetParam("FAC_NOTIFICATIE_JOB_OMS")
fldFAC_NOTIFICATIE_JOB_VIEW = GetParam("FAC_NOTIFICATIE_JOB_VIEW")
fldFAC_NOTIFICATIE_JOB_MODE = GetParam("FAC_NOTIFICATIE_JOB_MODE")
fldFAC_NOTIFICATIE_JOB_INTERVAL = GetParam("FAC_NOTIFICATIE_JOB_INTERVAL")
fldFAC_NOTIFICATIE_JOB_NEXTRUN = GetParam("FAC_NOTIFICATIE_JOB_NEXTRUN")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if not isNumeric(fldFAC_NOTIFICATIE_JOB_MODE) then
sNotificatieRecordErr = sNotificatieRecordErr & "De waarde in veld Mode is niet correct.<br>"
end if
if not isNumeric(fldFAC_NOTIFICATIE_JOB_INTERVAL) then
sNotificatieRecordErr = sNotificatieRecordErr & "De waarde in veld Interval (uur) is niet correct.<br>"
end if
'-------------------------------
' NotificatieRecord Check Event begin
cn.execute "alter session set NLS_DATE_FORMAT='DD-MM-YYYY HH24:MI:SS'"
' NotificatieRecord Check Event end
'-------------------------------
If len(sNotificatieRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' NotificatieRecord Insert Event begin
' NotificatieRecord Insert Event end
'-------------------------------
sSQL = "insert into FAC_NOTIFICATIE_JOB (" & _
"FAC_NOTIFICATIE_JOB_OMS," & _
"FAC_NOTIFICATIE_JOB_VIEW," & _
"FAC_NOTIFICATIE_JOB_MODE," & _
"FAC_NOTIFICATIE_JOB_INTERVAL," & _
"FAC_NOTIFICATIE_JOB_NEXTRUN)" & _
" values (" & _
ToSQL(fldFAC_NOTIFICATIE_JOB_OMS, "Text") & "," & _
ToSQL(fldFAC_NOTIFICATIE_JOB_VIEW, "Text") & "," & _
ToSQL(fldFAC_NOTIFICATIE_JOB_MODE, "Number") & "," & _
ToSQL(fldFAC_NOTIFICATIE_JOB_INTERVAL, "Number") & "," & _
ToSQL(fldFAC_NOTIFICATIE_JOB_NEXTRUN, "Date") & _
")"
case "update"
'-------------------------------
' NotificatieRecord Update Event begin
fldFAC_SRTNOTIFICATIE_MODE = CInt(fldBIT0_STATUS) + CInt(fldBIT1_MAIL) + CInt(fldBIT2_SMS) + CInt(fldBIT3_ALERT)
' NotificatieRecord Update Event end
'-------------------------------
if sSQL = "" then
sSQL = "update FAC_NOTIFICATIE_JOB set " & _
"FAC_NOTIFICATIE_JOB_OMS=" & ToSQL(fldFAC_NOTIFICATIE_JOB_OMS, "Text") & _
",FAC_NOTIFICATIE_JOB_VIEW=" & ToSQL(fldFAC_NOTIFICATIE_JOB_VIEW, "Text") & _
",FAC_NOTIFICATIE_JOB_MODE=" & ToSQL(fldFAC_NOTIFICATIE_JOB_MODE, "Number") & _
",FAC_NOTIFICATIE_JOB_INTERVAL=" & ToSQL(fldFAC_NOTIFICATIE_JOB_INTERVAL, "Number") & _
",FAC_NOTIFICATIE_JOB_NEXTRUN=" & ToSQL(fldFAC_NOTIFICATIE_JOB_NEXTRUN, "Date")
sSQL = sSQL & " where " & sWhere
end if
end select
'-------------------------------
'-------------------------------
' NotificatieRecord BeforeExecute Event begin
' NotificatieRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sNotificatieRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sNotificatieRecordErr = ProcessError
on error goto 0
if len(sNotificatieRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName
'-------------------------------
' NotificatieRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub NotificatieRecord_Show()
'-------------------------------
' NotificatieRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Details notificatiejob"
Dim bPK : bPK = True
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sNotificatieRecordErr = "" then
pFAC_NOTIFICATIE_JOB_KEY = GetParam("FAC_NOTIFICATIE_JOB_KEY")
SetVar "NotificatieRecordError", ""
else
fldFAC_NOTIFICATIE_JOB_KEY = GetParam("FAC_NOTIFICATIE_JOB_KEY")
fldFAC_NOTIFICATIE_JOB_OMS = GetParam("FAC_NOTIFICATIE_JOB_OMS")
fldFAC_NOTIFICATIE_JOB_VIEW = GetParam("FAC_NOTIFICATIE_JOB_VIEW")
fldFAC_NOTIFICATIE_JOB_MODE = GetParam("FAC_NOTIFICATIE_JOB_MODE")
fldFAC_NOTIFICATIE_JOB_INTERVAL = GetParam("FAC_NOTIFICATIE_JOB_INTERVAL")
fldFAC_NOTIFICATIE_JOB_NEXTRUN = GetParam("FAC_NOTIFICATIE_JOB_NEXTRUN")
pFAC_NOTIFICATIE_JOB_KEY = GetParam("PK_FAC_NOTIFICATIE_JOB_KEY")
SetVar "sNotificatieRecordErr", sNotificatieRecordErr
SetVar "FormTitle", sFormTitle
Parse "NotificatieRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pFAC_NOTIFICATIE_JOB_KEY) then bPK = False
sWhere = sWhere & "FAC_NOTIFICATIE_JOB_KEY=" & ToSQL(pFAC_NOTIFICATIE_JOB_KEY, "Number")
SetVar "PK_FAC_NOTIFICATIE_JOB_KEY", pFAC_NOTIFICATIE_JOB_KEY
'-------------------------------
'-------------------------------
' NotificatieRecord Open Event begin
' NotificatieRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_NOTIFICATIE_JOB where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "NotificatieRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldFAC_NOTIFICATIE_JOB_KEY = GetValue(rs, "FAC_NOTIFICATIE_JOB_KEY")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sNotificatieRecordErr = "" then
fldFAC_NOTIFICATIE_JOB_OMS = GetValue(rs, "FAC_NOTIFICATIE_JOB_OMS")
fldFAC_NOTIFICATIE_JOB_VIEW = GetValue(rs, "FAC_NOTIFICATIE_JOB_VIEW")
fldFAC_NOTIFICATIE_JOB_MODE = GetValue(rs, "FAC_NOTIFICATIE_JOB_MODE")
fldFAC_NOTIFICATIE_JOB_INTERVAL = GetValue(rs, "FAC_NOTIFICATIE_JOB_INTERVAL")
fldFAC_NOTIFICATIE_JOB_NEXTRUN = GetValue(rs, "FAC_NOTIFICATIE_JOB_NEXTRUN")
end if
SetVar "NotificatieRecordDelete", ""
SetVar "NotificatieRecordInsert", ""
Parse "NotificatieRecordEdit", False
'-------------------------------
' NotificatieRecord ShowEdit Event begin
' NotificatieRecord ShowEdit Event end
'-------------------------------
else
SetVar "NotificatieRecordEdit", ""
Parse "NotificatieRecordInsert", False
'-------------------------------
' NotificatieRecord ShowInsert Event begin
' NotificatieRecord ShowInsert Event end
'-------------------------------
end if
Parse "NotificatieRecordCancel", false
if sNotificatieRecordErr = "" then
'-------------------------------
' NotificatieRecord Show Event begin
fldBIT0_STATUS = fldFAC_SRTNOTIFICATIE_MODE AND 1 ' &B0001
fldBIT1_MAIL = fldFAC_SRTNOTIFICATIE_MODE AND 2 ' &B0100
fldBIT2_SMS = fldFAC_SRTNOTIFICATIE_MODE AND 4 ' &B0010
fldBIT3_ALERT = fldFAC_SRTNOTIFICATIE_MODE AND 8 ' &B1000
' Maak dd-mm-jjjj hh:mm:ss
if fldFAC_NOTIFICATIE_JOB_NEXTRUN <> "" then
fldFAC_NOTIFICATIE_JOB_NEXTRUN = FormatDateTime(rs("FAC_NOTIFICATIE_JOB_NEXTRUN"), 2) + " " + _
FormatDateTime(rs("FAC_NOTIFICATIE_JOB_NEXTRUN"), 4)
end if
' NotificatieRecord Show Event end
'-------------------------------
end if
'-------------------------------
' Show form field
'-------------------------------
SetVar "FAC_NOTIFICATIE_JOB_KEY", ToHTML(fldFAC_NOTIFICATIE_JOB_KEY)
SetVar "FAC_NOTIFICATIE_JOB_OMS", ToHTML(fldFAC_NOTIFICATIE_JOB_OMS)
SetVar "FAC_NOTIFICATIE_JOB_VIEW", ToHTML(fldFAC_NOTIFICATIE_JOB_VIEW)
SetVar "FAC_NOTIFICATIE_JOB_MODE", ToHTML(fldFAC_NOTIFICATIE_JOB_MODE)
SetVar "FAC_NOTIFICATIE_JOB_INTERVAL", ToHTML(fldFAC_NOTIFICATIE_JOB_INTERVAL)
SetVar "FAC_NOTIFICATIE_JOB_NEXTRUN", ToHTML(fldFAC_NOTIFICATIE_JOB_NEXTRUN)
Parse "FormNotificatieRecord", False
'-------------------------------
' NotificatieRecord Close Event begin
' NotificatieRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' NotificatieRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,97 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Notificaties</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormNotificatieRecordHeader-->
<!--EndFormNotificatieRecordHeader-->
<!--BeginFormNotificatieRecord-->
<form method="POST" action="{FileName}" name="NotificatieRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginNotificatieRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sNotificatieRecordErr}</font></td>
</tr>
<!--EndNotificatieRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Omschrijving</font></td>
<td class="DataTD"><input type="text" name="FAC_NOTIFICATIE_JOB_OMS" maxlength="60" value="{FAC_NOTIFICATIE_JOB_OMS}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">View</font></td>
<td class="DataTD"><textarea name="FAC_NOTIFICATIE_JOB_VIEW" cols="72" rows="5">{FAC_NOTIFICATIE_JOB_VIEW}</textarea></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Mode</font></td>
<td class="DataTD"><input type="text" name="FAC_NOTIFICATIE_JOB_MODE" maxlength="60" value="{FAC_NOTIFICATIE_JOB_MODE}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Interval (uur)</font></td>
<td class="DataTD"><input type="text" name="FAC_NOTIFICATIE_JOB_INTERVAL" maxlength="60" value="{FAC_NOTIFICATIE_JOB_INTERVAL}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Nextrun (dd-mm-jjjj hh:mm:ss)</font></td>
<td class="DataTD"><input type="text" name="FAC_NOTIFICATIE_JOB_NEXTRUN" maxlength="20" value="{FAC_NOTIFICATIE_JOB_NEXTRUN}" size="20"></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginNotificatieRecordInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.NotificatieRecord.FormAction.value = 'insert';">
<!--EndNotificatieRecordInsert-->
<!--BeginNotificatieRecordEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginNotificatieRecordUpdate-->
<input type="submit" value="Bewaren" onclick="document.NotificatieRecord.FormAction.value = 'update';"/>
<!--EndNotificatieRecordUpdate-->
<!--EndNotificatieRecordEdit-->
<!--BeginNotificatieRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.NotificatieRecord.FormAction.value = 'cancel';"/>
<!--EndNotificatieRecordCancel-->
<input type="hidden" name="FormName" value="NotificatieRecord"/>
<input type="hidden" name="PK_FAC_NOTIFICATIE_JOB_KEY" value="{PK_FAC_NOTIFICATIE_JOB_KEY}"/>
<input type="hidden" name="FAC_NOTIFICATIE_JOB_KEY" value="{FAC_NOTIFICATIE_JOB_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormNotificatieRecord-->
<!--BeginFormNotificatieRecordFooter-->
<!--EndFormNotificatieRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,470 +0,0 @@
<%
'
' Filename: fac_persoongroepgrid.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_persoongroepgrid CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_persoongroepgrid CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_persoongroepgrid.asp"
sTemplateFileName = "fac_persoongroepgrid.html"
'===============================
'===============================
' fac_persoongroepgrid CustomSecurity Event begin
checkAutorisation("WEB_PRSMSU")
' fac_persoongroepgrid CustomSecurity Event end
'===============================
'===============================
' fac_persoongroepgrid Open Event begin
' fac_persoongroepgrid Open Event end
'===============================
'===============================
' fac_persoongroepgrid OpenAnyPage Event begin
' fac_persoongroepgrid OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_persoongroepgrid Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
PersoonSearch_Show
PersoonGrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_persoongroepgrid Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_persoongroepgrid Close Event begin
' fac_persoongroepgrid Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub PersoonGrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Autorisaties"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 50
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
SetVar "TransitParams", "fFAC_GROEP_KEY=" & ToURL(GetParam("fFAC_GROEP_KEY")) & "&fPRS_AFDELING_KEY=" & ToURL(GetParam("fPRS_AFDELING_KEY")) & "&fPRS_PERSLID_NAAM=" & ToURL(GetParam("fPRS_PERSLID_NAAM")) & "&fPRS_PERSLID_OSLOGIN=" & ToURL(GetParam("fPRS_PERSLID_OSLOGIN")) & "&"
SetVar "FormParams", "fFAC_GROEP_KEY=" & ToURL(GetParam("fFAC_GROEP_KEY")) & "&fPRS_AFDELING_KEY=" & ToURL(GetParam("fPRS_AFDELING_KEY")) & "&fPRS_PERSLID_NAAM=" & ToURL(GetParam("fPRS_PERSLID_NAAM")) & "&fPRS_PERSLID_OSLOGIN=" & ToURL(GetParam("fPRS_PERSLID_OSLOGIN")) & "&"
'-------------------------------
' Build WHERE statement
'-------------------------------
pfPRS_AFDELING_KEY = GetParam("fPRS_AFDELING_KEY")
if IsNumeric(pfPRS_AFDELING_KEY) and not isEmpty(pfPRS_AFDELING_KEY) then pfPRS_AFDELING_KEY = ToSQL(pfPRS_AFDELING_KEY, "Number") else pfPRS_AFDELING_KEY = Empty
if not isEmpty(pfPRS_AFDELING_KEY) then
HasParam = true
sWhere = sWhere & "P.PRS_AFDELING_KEY=" & pfPRS_AFDELING_KEY
end if
if HasParam then
sWhere = " AND (PRS_PERSLID_OSLOGIN IS NOT NULL) AND (" & sWhere & ")"
else
sWhere = " AND PRS_PERSLID_OSLOGIN IS NOT NULL"
end if
'-------------------------------
' Build ORDER BY statement
'-------------------------------
sOrder = " order by P.PRS_PERSLID_NAAM Asc"
iSort = GetParam("FormPersoonGrid_Sorting")
iSorted = GetParam("FormPersoonGrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormPersoonGrid_Sorting=" & iSort & "&FormPersoonGrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormPersoonGrid_Sorting=" & iSort & "&FormPersoonGrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by P.PRS_PERSLID_KEY" & sDirection
if iSort = 2 then sOrder = " order by P.PRS_PERSLID_NAAM" & sDirection
if iSort = 3 then sOrder = " order by P.PRS_PERSLID_OSLOGIN" & sDirection
if iSort = 4 then sOrder = " order by P1.PRS_AFDELING_OMSCHRIJVING" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select P.PRS_AFDELING_KEY as P_PRS_AFDELING_KEY, " & _
"P.PRS_PERSLID_KEY as P_PRS_PERSLID_KEY, " & _
"P.PRS_PERSLID_NAAM as P_PRS_PERSLID_NAAM, " & _
"P.PRS_PERSLID_OSLOGIN as P_PRS_PERSLID_OSLOGIN, " & _
"P1.PRS_AFDELING_KEY as P1_PRS_AFDELING_KEY, " & _
"P1.PRS_AFDELING_OMSCHRIJVING as P1_PRS_AFDELING_OMSCHRIJVING " & _
" from PRS_V_AANWEZIGPERSLID P, PRS_V_AANWEZIGAFDELING P1" & _
" where P1.PRS_AFDELING_KEY=P.PRS_AFDELING_KEY "
'-------------------------------
'-------------------------------
' PersoonGrid Open Event begin
tmpWhere = ""
pPRS_PERSLID_NAAM = getParam("fPRS_PERSLID_NAAM")
if not isEmpty(pPRS_PERSLID_NAAM) then
HasParam = true
tmpWhere = tmpWhere & " UPPER(P.PRS_PERSLID_NAAM) like " & ToSQL("%"& UCase(pPRS_PERSLID_NAAM) &"%", "Text")
end if
pPRS_PERSLID_OSLOGIN = getParam("fPRS_PERSLID_OSLOGIN")
if not isEmpty(pPRS_PERSLID_OSLOGIN) then
if not (tmpWhere = "") then tmpWhere = tmpWhere & " and "
HasParam = true
tmpWhere = tmpWhere & " UPPER(P.PRS_PERSLID_OSLOGIN) like " & ToSQL("%"& UCase(pPRS_PERSLID_OSLOGIN) &"%", "Text")
end if
pFAC_GROEP_KEY = getParam("fFAC_GROEP_KEY")
if not isEmpty(pFAC_GROEP_KEY) then
if not (tmpWhere = "") then tmpWhere = tmpWhere & " and "
hasParam = true
tmpWhere = tmpWhere & ToSQL(pFAC_GROEP_KEY, "Number") & " in (select gg.fac_groep_key from fac_gebruikersgroep gg where gg.prs_perslid_key=P.PRS_PERSLID_KEY) "
end if
if tmpWhere<>"" then
sWhere = sWhere & " AND (" & tmpWhere & ")"
end if
' PersoonGrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListPersoonGrid", ""
Parse "PersoonGridNoRecords", False
SetVar "PersoonGridNavigator", ""
Parse "FormPersoonGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 50
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormPersoonGrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "PersoonGridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldPRS_AFDELING_KEY = GetValue(rs, "P1_PRS_AFDELING_OMSCHRIJVING")
fldPRS_PERSLID_KEY = GetValue(rs, "P_PRS_PERSLID_KEY")
fldPRS_PERSLID_NAAM_URLLink = "fac_persoongroeprecord.asp"
fldPRS_PERSLID_NAAM_PRS_PERSLID_KEY = GetValue(rs, "P_PRS_PERSLID_KEY")
fldPRS_PERSLID_NAAM = GetValue(rs, "P_PRS_PERSLID_NAAM")
fldPRS_PERSLID_OSLOGIN = GetValue(rs, "P_PRS_PERSLID_OSLOGIN")
'-------------------------------
' PersoonGrid Show begin
'-------------------------------
'-------------------------------
' PersoonGrid Show Event begin
fldFAC_GROEP_KEY = getFacGroepByPrsLidKey(fldPRS_PERSLID_KEY)
fldPRS_PERSLID_NAAM = buildName(fldPRS_PERSLID_KEY)
' PersoonGrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "PRS_PERSLID_KEY", ToHTML(fldPRS_PERSLID_KEY)
SetVar "PRS_PERSLID_NAAM", ToHTML(fldPRS_PERSLID_NAAM)
SetVar "PRS_PERSLID_NAAM_URLLink", fldPRS_PERSLID_NAAM_URLLink
SetVar "PrmPRS_PERSLID_NAAM_PRS_PERSLID_KEY", ToURL(fldPRS_PERSLID_NAAM_PRS_PERSLID_KEY)
SetVar "PRS_PERSLID_OSLOGIN", ToHTML(fldPRS_PERSLID_OSLOGIN)
SetVar "PRS_AFDELING_KEY", ToHTML(fldPRS_AFDELING_KEY)
SetVar "FAC_GROEP_KEY", fldFAC_GROEP_KEY
Parse "DListPersoonGrid", True
'-------------------------------
' PersoonGrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' PersoonGrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "PersoonGridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "PersoonGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "PersoonGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "PersoonGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "PersoonGridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "PersoonGridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "PersoonGridCurrentPage", iPage
Parse "PersoonGridNavigator", False
end if
'-------------------------------
' PersoonGrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "PersoonGridNoRecords", ""
Parse "FormPersoonGrid", False
'-------------------------------
' PersoonGrid Close Event begin
' PersoonGrid Close Event end
'-------------------------------
End Sub
'===============================
'===============================
' Display Search Form
'-------------------------------
Sub PersoonSearch_Show()
Dim sFormTitle: sFormTitle = ""
Dim sActionFileName: sActionFileName = "fac_persoongroepgrid.asp"
Dim sfPRS_AFDELING_KEYDisplayValue: sfPRS_AFDELING_KEYDisplayValue = ""
Dim sfFAC_GROEP_KEYDisplayValue: sfFAC_GROEP_KEYDisplayValue = ""
'-------------------------------
' PersoonSearch Open Event begin
' PersoonSearch Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
SetVar "ActionPage", sActionFileName
'-------------------------------
' Set variables with search parameters
'-------------------------------
fldfPRS_PERSLID_NAAM = GetParam("fPRS_PERSLID_NAAM")
fldfPRS_AFDELING_KEY = GetParam("fPRS_AFDELING_KEY")
fldfPRS_PERSLID_OSLOGIN = GetParam("fPRS_PERSLID_OSLOGIN")
fldfFAC_GROEP_KEY = GetParam("fFAC_GROEP_KEY")
'-------------------------------
' PersoonSearch Show begin
'-------------------------------
'-------------------------------
' PersoonSearch Show Event begin
' PersoonSearch Show Event end
'-------------------------------
SetVar "fPRS_PERSLID_NAAM", ToHTML(fldfPRS_PERSLID_NAAM)
SetVar "PersoonSearchLBfPRS_AFDELING_KEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sfPRS_AFDELING_KEYDisplayValue
Parse "PersoonSearchLBfPRS_AFDELING_KEY", True
openrs rsfPRS_AFDELING_KEY, "select prs_afdeling_key, prs_afdeling_naam from prs_v_aanwezigafdeling order by prs_afdeling_naam"
while not rsfPRS_AFDELING_KEY.EOF
SetVar "ID", GetValue(rsfPRS_AFDELING_KEY, 0) : SetVar "Value", GetValue(rsfPRS_AFDELING_KEY, 1)
if cstr(GetValue(rsfPRS_AFDELING_KEY, 0)) = cstr(fldfPRS_AFDELING_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "PersoonSearchLBfPRS_AFDELING_KEY", True
rsfPRS_AFDELING_KEY.MoveNext
wend
set rsfPRS_AFDELING_KEY = nothing
SetVar "fPRS_PERSLID_OSLOGIN", ToHTML(fldfPRS_PERSLID_OSLOGIN)
SetVar "PersoonSearchLBfFAC_GROEP_KEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sfFAC_GROEP_KEYDisplayValue
Parse "PersoonSearchLBfFAC_GROEP_KEY", True
openrs rsfFAC_GROEP_KEY, "select FAC_GROEP_KEY, FAC_GROEP_OMSCHRIJVING from FAC_GROEP order by 2"
while not rsfFAC_GROEP_KEY.EOF
SetVar "ID", GetValue(rsfFAC_GROEP_KEY, 0) : SetVar "Value", GetValue(rsfFAC_GROEP_KEY, 1)
if cstr(GetValue(rsfFAC_GROEP_KEY, 0)) = cstr(fldfFAC_GROEP_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "PersoonSearchLBfFAC_GROEP_KEY", True
rsfFAC_GROEP_KEY.MoveNext
wend
set rsfFAC_GROEP_KEY = nothing
'-------------------------------
' PersoonSearch Show end
'-------------------------------
'-------------------------------
' PersoonSearch Close Event begin
' PersoonSearch Close Event end
'-------------------------------
Parse "FormPersoonSearch", False
End Sub
'===============================
%>

View File

@@ -1,98 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Groepen bij personen</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormPersoonSearchHeader-->
<!--EndFormPersoonSearchHeader-->
<!--BeginFormPersoonSearch--><form method="POST" action="{ActionPage}" name="PersoonSearch">
<input type="hidden" name="FormName" value="PersoonSearch"><input type="hidden" name="FormAction" value="search">
<table class="FormTABLE">
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Naam</font></td>
<td class="DataTD"><input type="text" name="fPRS_PERSLID_NAAM" maxlength="30" value="{fPRS_PERSLID_NAAM}" size=""></td>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Afdeling</font></td>
<td class="DataTD"><select name="fPRS_AFDELING_KEY"><!--BeginPersoonSearchLBfPRS_AFDELING_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndPersoonSearchLBfPRS_AFDELING_KEY--></select></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Inlogcode</font></td>
<td class="DataTD"><input type="text" name="fPRS_PERSLID_OSLOGIN" maxlength="" value="{fPRS_PERSLID_OSLOGIN}" size=""></td>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Groep</font></td>
<td class="DataTD"><select name="fFAC_GROEP_KEY"><!--BeginPersoonSearchLBfFAC_GROEP_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndPersoonSearchLBfFAC_GROEP_KEY--></select></td>
<td><input type="submit" value="Zoeken"></td>
</tr>
</table>
</form><!--EndFormPersoonSearch-->
<!--BeginFormPersoonSearchFooter-->
<!--EndFormPersoonSearchFooter-->
</td>
</tr>
</table>
<table>
<tr>
<td valign="top">
<!--BeginFormPersoonGridHeader-->
<!--EndFormPersoonGridHeader-->
<!--BeginFormPersoonGrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="5"><a name="PersoonGrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormPersoonGrid_Sorting=1&FormPersoonGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Key</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormPersoonGrid_Sorting=2&FormPersoonGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Naam</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormPersoonGrid_Sorting=3&FormPersoonGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Login</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormPersoonGrid_Sorting=4&FormPersoonGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Afdeling</font></a></td>
<td class="ColumnTD"><a ><font class="ColumnFONT">Groepen</font></a></td>
</tr>
<!--BeginDListPersoonGrid-->
<tr>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_KEY}&nbsp;</font></td>
<td class="DataTD"><a href="{PRS_PERSLID_NAAM_URLLink}?PRS_PERSLID_KEY={PrmPRS_PERSLID_NAAM_PRS_PERSLID_KEY}&{TransitParams}"><font class="DataFONT">{PRS_PERSLID_NAAM}</font></a>&nbsp;</td>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_OSLOGIN}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_AFDELING_KEY}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_GROEP_KEY}&nbsp;</font></td>
</tr>
<!--EndDListPersoonGrid-->
<!--BeginPersoonGridNoRecords-->
<tr><td colspan="5" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndPersoonGridNoRecords-->
<!--BeginPersoonGridNavigator-->
<tr>
<td colspan="5" class="ColumnTD">
<font class="ColumnFONT">
<a href{PersoonGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormPersoonGrid_Page=1#PersoonGrid"><font class="ColumnFONT"><<</font></a>
<a href{PersoonGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormPersoonGrid_Page={PrevPage}#PersoonGrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginPersoonGridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormPersoonGrid_Page={NavigatorPageNumber}#PersoonGrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndPersoonGridNavigatorPages-->van {PersoonGridPageCount} ]
<a href{PersoonGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormPersoonGrid_Page={NextPage}#PersoonGrid"><font class="ColumnFONT">></font></a>
<a href{PersoonGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormPersoonGrid_Page=last#PersoonGrid"><font class="ColumnFONT">>></font></a>
</font>
</td>
</tr>
<!--EndPersoonGridNavigator-->
</table>
<!--EndFormPersoonGrid-->
<!--BeginFormPersoonGridFooter-->
<!--EndFormPersoonGridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,589 +0,0 @@
<%
'
' Filename: fac_persoongroeprecord.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_persoongroeprecord CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_persoongroeprecord CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_persoongroeprecord.asp"
sTemplateFileName = "fac_persoongroeprecord.html"
'===============================
'===============================
' fac_persoongroeprecord CustomSecurity Event begin
checkAutorisation("WEB_PRSMSU")
' fac_persoongroeprecord CustomSecurity Event end
'===============================
'===============================
' fac_persoongroeprecord Open Event begin
' fac_persoongroeprecord Open Event end
'===============================
'===============================
' fac_persoongroeprecord OpenAnyPage Event begin
' fac_persoongroeprecord OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_persoongroeprecord Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sPersoonRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "PersoonRecord"
PersoonRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
PersoonRecord_Show
GroepGrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_persoongroeprecord Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_persoongroeprecord Close Event begin
' fac_persoongroeprecord Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub GroepGrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Autorisatiegroepen"
Dim HasParam : HasParam = false
Dim bReq : bReq = true
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 25
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
Dim sActionFileName : sActionFileName = "fac_persoongroeprecord1.asp"
SetVar "TransitParams", "PRS_PERSLID_KEY=" & ToURL(GetParam("PRS_PERSLID_KEY")) & "&fFAC_GROEP_KEY=" & ToURL(GetParam("fFAC_GROEP_KEY")) & "&fPRS_AFDELING_KEY=" & ToURL(GetParam("fPRS_AFDELING_KEY")) & "&fPRS_PERSLID_NAAM=" & ToURL(GetParam("fPRS_PERSLID_NAAM")) & "&"
SetVar "FormParams", "PRS_PERSLID_KEY=" & ToURL(GetParam("PRS_PERSLID_KEY")) & "&fFAC_GROEP_KEY=" & ToURL(GetParam("fFAC_GROEP_KEY")) & "&fPRS_AFDELING_KEY=" & ToURL(GetParam("fPRS_AFDELING_KEY")) & "&fPRS_PERSLID_NAAM=" & ToURL(GetParam("fPRS_PERSLID_NAAM")) & "&"
'-------------------------------
' Build WHERE statement
'-------------------------------
pPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
if IsNumeric(pPRS_PERSLID_KEY) and not isEmpty(pPRS_PERSLID_KEY) then pPRS_PERSLID_KEY = ToSQL(pPRS_PERSLID_KEY, "Number") else pPRS_PERSLID_KEY = Empty
if not isEmpty(pPRS_PERSLID_KEY) then
HasParam = true
sWhere = sWhere & "F.PRS_PERSLID_KEY=" & pPRS_PERSLID_KEY
else
bReq = false
end if
if HasParam then
sWhere = " AND (" & sWhere & ")"
end if
'-------------------------------
' Build ORDER BY statement
'-------------------------------
iSort = GetParam("FormGroepGrid_Sorting")
iSorted = GetParam("FormGroepGrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormGroepGrid_Sorting=" & iSort & "&FormGroepGrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormGroepGrid_Sorting=" & iSort & "&FormGroepGrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by F.FAC_GEBRUIKERSGROEP_KEY" & sDirection
if iSort = 2 then sOrder = " order by F1.FAC_GROEP_OMSCHRIJVING" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select F.FAC_GEBRUIKERSGROEP_KEY as F_FAC_GEBRUIKERSGROEP_KEY, " & _
"F.FAC_GROEP_KEY as F_FAC_GROEP_KEY, " & _
"F.PRS_PERSLID_KEY as F_PRS_PERSLID_KEY, " & _
"F1.FAC_GROEP_KEY as F1_FAC_GROEP_KEY, " & _
"F1.FAC_GROEP_OMSCHRIJVING as F1_FAC_GROEP_OMSCHRIJVING " & _
" from FAC_GEBRUIKERSGROEP F, FAC_GROEP F1" & _
" where F1.FAC_GROEP_KEY=F.FAC_GROEP_KEY "
'-------------------------------
'-------------------------------
' GroepGrid Open Event begin
' GroepGrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the link to the record page
'-------------------------------
SetVar "FormAction", sActionFileName
'-------------------------------
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Process if form has all required parameter
'-------------------------------
if not bReq then
SetVar "DListGroepGrid", ""
Parse "GroepGridNoRecords", False
SetVar "GroepGridNavigator", ""
Parse "FormGroepGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListGroepGrid", ""
Parse "GroepGridNoRecords", False
SetVar "GroepGridNavigator", ""
Parse "FormGroepGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 25
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormGroepGrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "GroepGridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldFAC_GEBRUIKERSGROEP_KEY = GetValue(rs, "F_FAC_GEBRUIKERSGROEP_KEY")
fldFAC_GROEP_KEY_URLLink = "fac_persoongroeprecord2.asp"
fldFAC_GROEP_KEY_FAC_GEBRUIKERSGROEP_KEY = GetValue(rs, "F_FAC_GEBRUIKERSGROEP_KEY")
fldFAC_GROEP_KEY = GetValue(rs, "F1_FAC_GROEP_OMSCHRIJVING")
fldPRS_PERSLID_KEY = GetValue(rs, "F_PRS_PERSLID_KEY")
'-------------------------------
' GroepGrid Show begin
'-------------------------------
'-------------------------------
' GroepGrid Show Event begin
' GroepGrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "FAC_GEBRUIKERSGROEP_KEY", ToHTML(fldFAC_GEBRUIKERSGROEP_KEY)
SetVar "PRS_PERSLID_KEY", ToHTML(fldPRS_PERSLID_KEY)
SetVar "FAC_GROEP_KEY", ToHTML(fldFAC_GROEP_KEY)
SetVar "FAC_GROEP_KEY_URLLink", fldFAC_GROEP_KEY_URLLink
SetVar "PrmFAC_GROEP_KEY_FAC_GEBRUIKERSGROEP_KEY", ToURL(fldFAC_GROEP_KEY_FAC_GEBRUIKERSGROEP_KEY)
Parse "DListGroepGrid", True
'-------------------------------
' GroepGrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' GroepGrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "GroepGridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "GroepGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "GroepGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "GroepGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "GroepGridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "GroepGridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "GroepGridCurrentPage", iPage
Parse "GroepGridNavigator", False
end if
'-------------------------------
' GroepGrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "GroepGridNoRecords", ""
Parse "FormGroepGrid", False
'-------------------------------
' GroepGrid Close Event begin
' GroepGrid Close Event end
'-------------------------------
End Sub
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub PersoonRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKPRS_PERSLID_KEY : pPKPRS_PERSLID_KEY = ""
'-------------------------------
'-------------------------------
' PersoonRecord Action begin
'-------------------------------
sActionFileName = "fac_persoongroepgrid.asp"
sParams = sParams & "fPRS_AFDELING_KEY=" & ToURL(GetParam("Trn_fPRS_AFDELING_KEY")) & "&"
sParams = sParams & "fFAC_GROEP_KEY=" & ToURL(GetParam("Trn_fFAC_GROEP_KEY")) & "&"
sParams = sParams & "fPRS_PERSLID_NAAM=" & ToURL(GetParam("Trn_fPRS_PERSLID_NAAM"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' PersoonRecord BeforeCancel Event begin
' PersoonRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
'-------------------------------
' PersoonRecord Check Event begin
' PersoonRecord Check Event end
'-------------------------------
If len(sPersoonRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' PersoonRecord BeforeExecute Event begin
' PersoonRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sPersoonRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sPersoonRecordErr = ProcessError
on error goto 0
if len(sPersoonRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' PersoonRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub PersoonRecord_Show()
'-------------------------------
' PersoonRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Naam"
Dim bPK : bPK = True
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sPersoonRecordErr = "" then
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("fPRS_PERSLID_NAAM")
pPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
SetVar "PersoonRecordError", ""
else
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("Trn_fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("Trn_fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("Trn_fPRS_PERSLID_NAAM")
pPRS_PERSLID_KEY = GetParam("PK_PRS_PERSLID_KEY")
SetVar "sPersoonRecordErr", sPersoonRecordErr
SetVar "FormTitle", sFormTitle
Parse "PersoonRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pPRS_PERSLID_KEY) then bPK = False
sWhere = sWhere & "PRS_PERSLID_KEY=" & ToSQL(pPRS_PERSLID_KEY, "Number")
SetVar "PK_PRS_PERSLID_KEY", pPRS_PERSLID_KEY
'-------------------------------
'-------------------------------
' PersoonRecord Open Event begin
' PersoonRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_V_WEBUSER where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "PersoonRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldPRS_AFDELING_KEY = GetValue(rs, "PRS_AFDELING_KEY")
fldPRS_PERSLID_KEY = GetValue(rs, "PRS_PERSLID_KEY")
fldPRS_PERSLID_NAAM = GetValue(rs, "PRS_PERSLID_NAAM")
SetVar "PersoonRecordDelete", ""
SetVar "PersoonRecordUpdate", ""
SetVar "PersoonRecordInsert", ""
'-------------------------------
' PersoonRecord ShowEdit Event begin
' PersoonRecord ShowEdit Event end
'-------------------------------
else
SetVar "PersoonRecordEdit", ""
SetVar "PersoonRecordInsert", ""
'-------------------------------
' PersoonRecord ShowInsert Event begin
' PersoonRecord ShowInsert Event end
'-------------------------------
end if
Parse "PersoonRecordCancel", false
'-------------------------------
' Set lookup fields
'-------------------------------
fldPRS_AFDELING_KEY = DLookUp("PRS_V_AANWEZIGAFDELING", "PRS_AFDELING_OMSCHRIJVING", "PRS_AFDELING_KEY=" & ToSQL(fldPRS_AFDELING_KEY, "Number"))
if sPersoonRecordErr = "" then
'-------------------------------
' PersoonRecord Show Event begin
fldPRS_PERSLID_NAAM = buildName(fldPRS_PERSLID_KEY)
' PersoonRecord Show Event end
'-------------------------------
end if
'-------------------------------
' Show form field
'-------------------------------
SetVar "PRS_PERSLID_KEY", ToHTML(fldPRS_PERSLID_KEY)
SetVar "PRS_PERSLID_NAAM", ToHTML(fldPRS_PERSLID_NAAM)
SetVar "PRS_AFDELING_KEY", ToHTML(fldPRS_AFDELING_KEY)
Parse "FormPersoonRecord", False
'-------------------------------
' PersoonRecord Close Event begin
' PersoonRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' PersoonRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,123 +0,0 @@
<html>
<head>
<title>Facilitor Management Online -</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormPersoonRecordHeader-->
<!--EndFormPersoonRecordHeader-->
<!--BeginFormPersoonRecord-->
<form method="POST" action="{FileName}" name="PersoonRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginPersoonRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sPersoonRecordErr}</font></td>
</tr>
<!--EndPersoonRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Naam</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_NAAM}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Afdeling</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_AFDELING_KEY}&nbsp;</font></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginPersoonRecordCancel-->
<input type="submit" value="Terug" onclick="document.PersoonRecord.FormAction.value = 'cancel';"/>
<!--EndPersoonRecordCancel-->
<input type="hidden" name="FormName" value="PersoonRecord"/>
<input type="hidden" value="cancel" name="FormAction"/>
<input type="hidden" name="Trn_fPRS_AFDELING_KEY" value="{Trn_fPRS_AFDELING_KEY}"/>
<input type="hidden" name="Trn_fFAC_GROEP_KEY" value="{Trn_fFAC_GROEP_KEY}"/>
<input type="hidden" name="Trn_fPRS_PERSLID_NAAM" value="{Trn_fPRS_PERSLID_NAAM}"/>
<input type="hidden" name="PK_PRS_PERSLID_KEY" value="{PK_PRS_PERSLID_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormPersoonRecord-->
<!--BeginFormPersoonRecordFooter-->
<!--EndFormPersoonRecordFooter-->
</td>
</tr>
</table>
<table>
<tr>
<td valign="top">
<!--BeginFormGroepGridHeader-->
<!--EndFormGroepGridHeader-->
<!--BeginFormGroepGrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><a name="GroepGrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormGroepGrid_Sorting=1&FormGroepGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Key</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormGroepGrid_Sorting=2&FormGroepGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Groep</font></a></td>
</tr>
<!--BeginDListGroepGrid-->
<tr>
<td class="DataTD"><font class="DataFONT">{FAC_GEBRUIKERSGROEP_KEY}&nbsp;</font></td>
<td class="DataTD"><a href="{FAC_GROEP_KEY_URLLink}?FAC_GEBRUIKERSGROEP_KEY={PrmFAC_GROEP_KEY_FAC_GEBRUIKERSGROEP_KEY}&{TransitParams}"><font class="DataFONT">{FAC_GROEP_KEY}</font></a>&nbsp;</td>
</tr>
<!--EndDListGroepGrid-->
<!--BeginGroepGridNoRecords-->
<tr><td colspan="2" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndGroepGridNoRecords-->
<tr>
<td colspan="2" class="ColumnTD">
<font class="ColumnFONT">
<a href="{FormAction}?{TransitParams}"><font class="ColumnFONT">Toevoegen</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<!--BeginGroepGridNavigator-->
<a href{GroepGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormGroepGrid_Page=1#GroepGrid"><font class="ColumnFONT"><<</font></a>
<a href{GroepGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormGroepGrid_Page={PrevPage}#GroepGrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginGroepGridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormGroepGrid_Page={NavigatorPageNumber}#GroepGrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndGroepGridNavigatorPages-->van {GroepGridPageCount} ]
<a href{GroepGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormGroepGrid_Page={NextPage}#GroepGrid"><font class="ColumnFONT">></font></a>
<a href{GroepGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormGroepGrid_Page=last#GroepGrid"><font class="ColumnFONT">>></font></a>
<!--EndGroepGridNavigator-->
</font>
</td>
</tr>
</table>
<!--EndFormGroepGrid-->
<!--BeginFormGroepGridFooter-->
<!--EndFormGroepGridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,579 +0,0 @@
<%
'
' Filename: fac_persoongroeprecord1.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_persoongroeprecord1 CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_persoongroeprecord1 CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_persoongroeprecord1.asp"
sTemplateFileName = "fac_persoongroeprecord1.html"
'===============================
'===============================
' fac_persoongroeprecord1 CustomSecurity Event begin
checkAutorisation("WEB_PRSMSU")
' fac_persoongroeprecord1 CustomSecurity Event end
'===============================
'===============================
' fac_persoongroeprecord1 Open Event begin
' fac_persoongroeprecord1 Open Event end
'===============================
'===============================
' fac_persoongroeprecord1 OpenAnyPage Event begin
' fac_persoongroeprecord1 OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_persoongroeprecord1 Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sGroepRecordAddErr = ""
sPersoonRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "GroepRecordAdd"
GroepRecordAddAction(sAction)
Case "PersoonRecord"
PersoonRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
PersoonRecord_Show
GroepRecordAdd_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_persoongroeprecord1 Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_persoongroeprecord1 Close Event begin
' fac_persoongroeprecord1 Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub GroepRecordAddAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKFAC_GEBRUIKERSGROEP_KEY : pPKFAC_GEBRUIKERSGROEP_KEY = ""
Dim fldPRS_PERSLID_KEY : fldPRS_PERSLID_KEY = ""
Dim fldFAC_GROEP_KEY : fldFAC_GROEP_KEY = ""
'-------------------------------
'-------------------------------
' GroepRecordAdd Action begin
'-------------------------------
sActionFileName = "fac_persoongroeprecord.asp"
sParams = sParams & "PRS_PERSLID_KEY=" & ToURL(GetParam("Trn_PRS_PERSLID_KEY")) & "&"
sParams = sParams & "fPRS_AFDELING_KEY=" & ToURL(GetParam("Trn_fPRS_AFDELING_KEY")) & "&"
sParams = sParams & "fFAC_GROEP_KEY=" & ToURL(GetParam("Trn_fFAC_GROEP_KEY")) & "&"
sParams = sParams & "fPRS_PERSLID_NAAM=" & ToURL(GetParam("Trn_fPRS_PERSLID_NAAM"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' GroepRecordAdd BeforeCancel Event begin
' GroepRecordAdd BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKFAC_GEBRUIKERSGROEP_KEY = GetParam("PK_FAC_GEBRUIKERSGROEP_KEY")
if IsEmpty(pPKFAC_GEBRUIKERSGROEP_KEY) then exit sub
sWhere = "FAC_GEBRUIKERSGROEP_KEY=" & ToSQL(pPKFAC_GEBRUIKERSGROEP_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
fldFAC_GROEP_KEY = GetParam("FAC_GROEP_KEY")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if IsEmpty(fldFAC_GROEP_KEY) then
sGroepRecordAddErr = sGroepRecordAddErr & "De waarde in veld Groep is verplicht.<br>"
end if
if not isNumeric(fldPRS_PERSLID_KEY) then
sGroepRecordAddErr = sGroepRecordAddErr & "De waarde in veld PRS_PERSLID_KEY is niet correct.<br>"
end if
if not isNumeric(fldFAC_GROEP_KEY) then
sGroepRecordAddErr = sGroepRecordAddErr & "De waarde in veld Groep is niet correct.<br>"
end if
'-------------------------------
' GroepRecordAdd Check Event begin
' GroepRecordAdd Check Event end
'-------------------------------
If len(sGroepRecordAddErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' GroepRecordAdd Insert Event begin
' GroepRecordAdd Insert Event end
'-------------------------------
sSQL = "insert into FAC_GEBRUIKERSGROEP (" & _
"PRS_PERSLID_KEY," & _
"FAC_GROEP_KEY)" & _
" values (" & _
ToSQL(fldPRS_PERSLID_KEY, "Number") & "," & _
ToSQL(fldFAC_GROEP_KEY, "Number") & _
")"
case "update"
'-------------------------------
' GroepRecordAdd Update Event begin
' GroepRecordAdd Update Event end
'-------------------------------
sSQL = "update FAC_GEBRUIKERSGROEP set " & _
"PRS_PERSLID_KEY=" & ToSQL(fldPRS_PERSLID_KEY, "Number") & _
",FAC_GROEP_KEY=" & ToSQL(fldFAC_GROEP_KEY, "Number")
sSQL = sSQL & " where " & sWhere
case "delete"
'-------------------------------
' GroepRecordAdd Delete Event begin
' GroepRecordAdd Delete Event end
'-------------------------------
sSQL = "delete from FAC_GEBRUIKERSGROEP where " & sWhere
end select
'-------------------------------
'-------------------------------
' GroepRecordAdd BeforeExecute Event begin
' GroepRecordAdd BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sGroepRecordAddErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sGroepRecordAddErr = ProcessError
on error goto 0
if len(sGroepRecordAddErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' GroepRecordAdd Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub GroepRecordAdd_Show()
'-------------------------------
' GroepRecordAdd Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Autorisatiegroepen"
Dim bPK : bPK = True
Dim sFAC_GROEP_KEYDisplayValue: sFAC_GROEP_KEYDisplayValue = ""
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sGroepRecordAddErr = "" then
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
SetVar "Trn_PRS_PERSLID_KEY", GetParam("PRS_PERSLID_KEY")
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("fPRS_PERSLID_NAAM")
pFAC_GEBRUIKERSGROEP_KEY = GetParam("FAC_GEBRUIKERSGROEP_KEY")
SetVar "GroepRecordAddError", ""
else
fldFAC_GEBRUIKERSGROEP_KEY = GetParam("FAC_GEBRUIKERSGROEP_KEY")
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
fldFAC_GROEP_KEY = GetParam("FAC_GROEP_KEY")
SetVar "Trn_PRS_PERSLID_KEY", GetParam("Trn_PRS_PERSLID_KEY")
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("Trn_fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("Trn_fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("Trn_fPRS_PERSLID_NAAM")
pFAC_GEBRUIKERSGROEP_KEY = GetParam("PK_FAC_GEBRUIKERSGROEP_KEY")
SetVar "sGroepRecordAddErr", sGroepRecordAddErr
SetVar "FormTitle", sFormTitle
Parse "GroepRecordAddError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pFAC_GEBRUIKERSGROEP_KEY) then bPK = False
sWhere = sWhere & "FAC_GEBRUIKERSGROEP_KEY=" & ToSQL(pFAC_GEBRUIKERSGROEP_KEY, "Number")
SetVar "PK_FAC_GEBRUIKERSGROEP_KEY", pFAC_GEBRUIKERSGROEP_KEY
'-------------------------------
'-------------------------------
' GroepRecordAdd Open Event begin
' GroepRecordAdd Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_GEBRUIKERSGROEP where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "GroepRecordAdd") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldFAC_GEBRUIKERSGROEP_KEY = GetValue(rs, "FAC_GEBRUIKERSGROEP_KEY")
fldPRS_PERSLID_KEY = GetValue(rs, "PRS_PERSLID_KEY")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sGroepRecordAddErr = "" then
fldFAC_GROEP_KEY = GetValue(rs, "FAC_GROEP_KEY")
end if
SetVar "GroepRecordAddInsert", ""
Parse "GroepRecordAddEdit", False
'-------------------------------
' GroepRecordAdd ShowEdit Event begin
' GroepRecordAdd ShowEdit Event end
'-------------------------------
else
if sGroepRecordAddErr = "" then
fldPRS_PERSLID_KEY = ToHTML(GetParam("PRS_PERSLID_KEY"))
end if
SetVar "GroepRecordAddEdit", ""
Parse "GroepRecordAddInsert", False
'-------------------------------
' GroepRecordAdd ShowInsert Event begin
' GroepRecordAdd ShowInsert Event end
'-------------------------------
end if
Parse "GroepRecordAddCancel", false
'-------------------------------
' GroepRecordAdd Show Event begin
' GroepRecordAdd Show Event end
'-------------------------------
'-------------------------------
' Show form field
'-------------------------------
SetVar "FAC_GEBRUIKERSGROEP_KEY", ToHTML(fldFAC_GEBRUIKERSGROEP_KEY)
SetVar "PRS_PERSLID_KEY", ToHTML(fldPRS_PERSLID_KEY)
SetVar "GroepRecordAddLBFAC_GROEP_KEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sFAC_GROEP_KEYDisplayValue
Parse "GroepRecordAddLBFAC_GROEP_KEY", True
openrs rsFAC_GROEP_KEY, "select fac_groep_key, fac_groep_omschrijving from fac_groep fg where fac_groep_key not in (select fac_groep_key from fac_gebruikersgroep where prs_perslid_key="&ToSQL(fldPRS_PERSLID_KEY,"Number")&") AND (NOT EXISTS ( SELECT * FROM fac_groeprechten fgr, fac_functie ff WHERE fgr.fac_groep_key = fg.fac_groep_key AND fgr.fac_functie_key = ff.fac_functie_key AND ff.fac_functie_code = 'WEB_PRSSYS') OR fac_groep_key IN (SELECT fac_groep_key FROM fac_gebruikersgroep WHERE prs_perslid_key = "&Session("User_key")&")) order by fac_groep_omschrijving asc"
while not rsFAC_GROEP_KEY.EOF
SetVar "ID", GetValue(rsFAC_GROEP_KEY, 0) : SetVar "Value", GetValue(rsFAC_GROEP_KEY, 1)
if cstr(GetValue(rsFAC_GROEP_KEY, 0)) = cstr(fldFAC_GROEP_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "GroepRecordAddLBFAC_GROEP_KEY", True
rsFAC_GROEP_KEY.MoveNext
wend
set rsFAC_GROEP_KEY = nothing
Parse "FormGroepRecordAdd", False
'-------------------------------
' GroepRecordAdd Close Event begin
' GroepRecordAdd Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' GroepRecordAdd Show end
'-------------------------------
End Sub
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub PersoonRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKPRS_PERSLID_KEY : pPKPRS_PERSLID_KEY = ""
'-------------------------------
'-------------------------------
' PersoonRecord Action begin
'-------------------------------
sActionFileName = "fac_persoongroepgrid.asp"
sParams = sParams & "fPRS_AFDELING_KEY=" & ToURL(GetParam("Trn_fPRS_AFDELING_KEY")) & "&"
sParams = sParams & "fFAC_GROEP_KEY=" & ToURL(GetParam("Trn_fFAC_GROEP_KEY")) & "&"
sParams = sParams & "fPRS_PERSLID_NAAM=" & ToURL(GetParam("Trn_fPRS_PERSLID_NAAM"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' PersoonRecord BeforeCancel Event begin
' PersoonRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
'-------------------------------
' PersoonRecord Check Event begin
' PersoonRecord Check Event end
'-------------------------------
If len(sPersoonRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' PersoonRecord BeforeExecute Event begin
' PersoonRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sPersoonRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sPersoonRecordErr = ProcessError
on error goto 0
if len(sPersoonRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' PersoonRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub PersoonRecord_Show()
'-------------------------------
' PersoonRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Naam"
Dim bPK : bPK = True
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sPersoonRecordErr = "" then
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("fPRS_PERSLID_NAAM")
pPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
SetVar "PersoonRecordError", ""
else
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("Trn_fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("Trn_fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("Trn_fPRS_PERSLID_NAAM")
pPRS_PERSLID_KEY = GetParam("PK_PRS_PERSLID_KEY")
SetVar "sPersoonRecordErr", sPersoonRecordErr
SetVar "FormTitle", sFormTitle
Parse "PersoonRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pPRS_PERSLID_KEY) then bPK = False
sWhere = sWhere & "PRS_PERSLID_KEY=" & ToSQL(pPRS_PERSLID_KEY, "Number")
SetVar "PK_PRS_PERSLID_KEY", pPRS_PERSLID_KEY
'-------------------------------
'-------------------------------
' PersoonRecord Open Event begin
' PersoonRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_V_WEBUSER where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "PersoonRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldPRS_AFDELING_KEY = GetValue(rs, "PRS_AFDELING_KEY")
fldPRS_PERSLID_KEY = GetValue(rs, "PRS_PERSLID_KEY")
fldPRS_PERSLID_NAAM = GetValue(rs, "PRS_PERSLID_NAAM")
SetVar "PersoonRecordDelete", ""
SetVar "PersoonRecordUpdate", ""
SetVar "PersoonRecordInsert", ""
'-------------------------------
' PersoonRecord ShowEdit Event begin
' PersoonRecord ShowEdit Event end
'-------------------------------
else
SetVar "PersoonRecordEdit", ""
SetVar "PersoonRecordInsert", ""
'-------------------------------
' PersoonRecord ShowInsert Event begin
' PersoonRecord ShowInsert Event end
'-------------------------------
end if
Parse "PersoonRecordCancel", false
'-------------------------------
' Set lookup fields
'-------------------------------
fldPRS_AFDELING_KEY = DLookUp("PRS_V_AANWEZIGAFDELING", "PRS_AFDELING_OMSCHRIJVING", "PRS_AFDELING_KEY=" & ToSQL(fldPRS_AFDELING_KEY, "Number"))
if sPersoonRecordErr = "" then
'-------------------------------
' PersoonRecord Show Event begin
fldPRS_PERSLID_NAAM = buildName(fldPRS_PERSLID_KEY)
' PersoonRecord Show Event end
'-------------------------------
end if
'-------------------------------
' Show form field
'-------------------------------
SetVar "PRS_PERSLID_KEY", ToHTML(fldPRS_PERSLID_KEY)
SetVar "PRS_PERSLID_NAAM", ToHTML(fldPRS_PERSLID_NAAM)
SetVar "PRS_AFDELING_KEY", ToHTML(fldPRS_AFDELING_KEY)
Parse "FormPersoonRecord", False
'-------------------------------
' PersoonRecord Close Event begin
' PersoonRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' PersoonRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,147 +0,0 @@
<html>
<head>
<title>Facilitor Management Online -</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormPersoonRecordHeader-->
<!--EndFormPersoonRecordHeader-->
<!--BeginFormPersoonRecord-->
<form method="POST" action="{FileName}" name="PersoonRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginPersoonRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sPersoonRecordErr}</font></td>
</tr>
<!--EndPersoonRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Naam</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_NAAM}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Afdeling</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_AFDELING_KEY}&nbsp;</font></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginPersoonRecordCancel-->
<input type="submit" value="Terug" onclick="document.PersoonRecord.FormAction.value = 'cancel';"/>
<!--EndPersoonRecordCancel-->
<input type="hidden" name="FormName" value="PersoonRecord"/>
<input type="hidden" value="cancel" name="FormAction"/>
<input type="hidden" name="Trn_fPRS_AFDELING_KEY" value="{Trn_fPRS_AFDELING_KEY}"/>
<input type="hidden" name="Trn_fFAC_GROEP_KEY" value="{Trn_fFAC_GROEP_KEY}"/>
<input type="hidden" name="Trn_fPRS_PERSLID_NAAM" value="{Trn_fPRS_PERSLID_NAAM}"/>
<input type="hidden" name="PK_PRS_PERSLID_KEY" value="{PK_PRS_PERSLID_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormPersoonRecord-->
<!--BeginFormPersoonRecordFooter-->
<!--EndFormPersoonRecordFooter-->
</td>
</tr>
</table>
<table>
<tr>
<td valign="top">
<!--BeginFormGroepRecordAddHeader-->
<!--EndFormGroepRecordAddHeader-->
<!--BeginFormGroepRecordAdd-->
<form method="POST" action="{FileName}" name="GroepRecordAdd">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginGroepRecordAddError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sGroepRecordAddErr}</font></td>
</tr>
<!--EndGroepRecordAddError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Groep</font></td>
<td class="DataTD"><select name="FAC_GROEP_KEY"><!--BeginGroepRecordAddLBFAC_GROEP_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndGroepRecordAddLBFAC_GROEP_KEY--></select></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginGroepRecordAddInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.GroepRecordAdd.FormAction.value = 'insert';">
<!--EndGroepRecordAddInsert-->
<!--BeginGroepRecordAddEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginGroepRecordAddUpdate-->
<input type="submit" value="Bewaren" onclick="document.GroepRecordAdd.FormAction.value = 'update';"/>
<!--EndGroepRecordAddUpdate-->
<!--BeginGroepRecordAddDelete-->
<input type="submit" value="Verwijderen" onclick="document.GroepRecordAdd.FormAction.value = 'delete';"/>
<!--EndGroepRecordAddDelete-->
<!--EndGroepRecordAddEdit-->
<!--BeginGroepRecordAddCancel-->
<input type="submit" value="Annuleren" onclick="document.GroepRecordAdd.FormAction.value = 'cancel';"/>
<!--EndGroepRecordAddCancel-->
<input type="hidden" name="FormName" value="GroepRecordAdd"/>
<input type="hidden" name="Trn_PRS_PERSLID_KEY" value="{Trn_PRS_PERSLID_KEY}"/>
<input type="hidden" name="Trn_fPRS_AFDELING_KEY" value="{Trn_fPRS_AFDELING_KEY}"/>
<input type="hidden" name="Trn_fFAC_GROEP_KEY" value="{Trn_fFAC_GROEP_KEY}"/>
<input type="hidden" name="Trn_fPRS_PERSLID_NAAM" value="{Trn_fPRS_PERSLID_NAAM}"/>
<input type="hidden" name="PK_FAC_GEBRUIKERSGROEP_KEY" value="{PK_FAC_GEBRUIKERSGROEP_KEY}"/>
<input type="hidden" name="FAC_GEBRUIKERSGROEP_KEY" value="{FAC_GEBRUIKERSGROEP_KEY}"/>
<input type="hidden" name="PRS_PERSLID_KEY" value="{PRS_PERSLID_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormGroepRecordAdd-->
<!--BeginFormGroepRecordAddFooter-->
<!--EndFormGroepRecordAddFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,534 +0,0 @@
<%
'
' Filename: fac_persoongroeprecord2.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_persoongroeprecord2 CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_persoongroeprecord2 CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_persoongroeprecord2.asp"
sTemplateFileName = "fac_persoongroeprecord2.html"
'===============================
'===============================
' fac_persoongroeprecord2 CustomSecurity Event begin
checkAutorisation("WEB_PRSMSU")
' fac_persoongroeprecord2 CustomSecurity Event end
'===============================
'===============================
' fac_persoongroeprecord2 Open Event begin
' fac_persoongroeprecord2 Open Event end
'===============================
'===============================
' fac_persoongroeprecord2 OpenAnyPage Event begin
' fac_persoongroeprecord2 OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_persoongroeprecord2 Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sGroepRecordErr = ""
sPersoonRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "GroepRecord"
GroepRecordAction(sAction)
Case "PersoonRecord"
PersoonRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
PersoonRecord_Show
GroepRecord_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_persoongroeprecord2 Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_persoongroeprecord2 Close Event begin
' fac_persoongroeprecord2 Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub GroepRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKFAC_GEBRUIKERSGROEP_KEY : pPKFAC_GEBRUIKERSGROEP_KEY = ""
Dim fldPRS_PERSLID_KEY : fldPRS_PERSLID_KEY = ""
'-------------------------------
'-------------------------------
' GroepRecord Action begin
'-------------------------------
sActionFileName = "fac_persoongroeprecord.asp"
sParams = sParams & "PRS_PERSLID_KEY=" & ToURL(GetParam("Trn_PRS_PERSLID_KEY")) & "&"
sParams = sParams & "fPRS_AFDELING_KEY=" & ToURL(GetParam("Trn_fPRS_AFDELING_KEY")) & "&"
sParams = sParams & "fFAC_GROEP_KEY=" & ToURL(GetParam("Trn_fFAC_GROEP_KEY")) & "&"
sParams = sParams & "fPRS_PERSLID_NAAM=" & ToURL(GetParam("Trn_fPRS_PERSLID_NAAM"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' GroepRecord BeforeCancel Event begin
' GroepRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKFAC_GEBRUIKERSGROEP_KEY = GetParam("PK_FAC_GEBRUIKERSGROEP_KEY")
if IsEmpty(pPKFAC_GEBRUIKERSGROEP_KEY) then exit sub
sWhere = "FAC_GEBRUIKERSGROEP_KEY=" & ToSQL(pPKFAC_GEBRUIKERSGROEP_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if not isNumeric(fldPRS_PERSLID_KEY) then
sGroepRecordErr = sGroepRecordErr & "De waarde in veld PRS_PERSLID_KEY is niet correct.<br>"
end if
'-------------------------------
' GroepRecord Check Event begin
' GroepRecord Check Event end
'-------------------------------
If len(sGroepRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "delete"
'-------------------------------
' GroepRecord Delete Event begin
' GroepRecord Delete Event end
'-------------------------------
sSQL = "delete from FAC_GEBRUIKERSGROEP where " & sWhere
end select
'-------------------------------
'-------------------------------
' GroepRecord BeforeExecute Event begin
' GroepRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sGroepRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sGroepRecordErr = ProcessError
on error goto 0
if len(sGroepRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' GroepRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub GroepRecord_Show()
'-------------------------------
' GroepRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Autorisatiegroepen"
Dim bPK : bPK = True
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sGroepRecordErr = "" then
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
SetVar "Trn_PRS_PERSLID_KEY", GetParam("PRS_PERSLID_KEY")
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("fPRS_PERSLID_NAAM")
pFAC_GEBRUIKERSGROEP_KEY = GetParam("FAC_GEBRUIKERSGROEP_KEY")
SetVar "GroepRecordError", ""
else
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
SetVar "Trn_PRS_PERSLID_KEY", GetParam("Trn_PRS_PERSLID_KEY")
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("Trn_fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("Trn_fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("Trn_fPRS_PERSLID_NAAM")
pFAC_GEBRUIKERSGROEP_KEY = GetParam("PK_FAC_GEBRUIKERSGROEP_KEY")
SetVar "sGroepRecordErr", sGroepRecordErr
SetVar "FormTitle", sFormTitle
Parse "GroepRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pFAC_GEBRUIKERSGROEP_KEY) then bPK = False
sWhere = sWhere & "FAC_GEBRUIKERSGROEP_KEY=" & ToSQL(pFAC_GEBRUIKERSGROEP_KEY, "Number")
SetVar "PK_FAC_GEBRUIKERSGROEP_KEY", pFAC_GEBRUIKERSGROEP_KEY
'-------------------------------
'-------------------------------
' GroepRecord Open Event begin
' GroepRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_GEBRUIKERSGROEP where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "GroepRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldFAC_GEBRUIKERSGROEP_KEY = GetValue(rs, "FAC_GEBRUIKERSGROEP_KEY")
fldFAC_GROEP_KEY = GetValue(rs, "FAC_GROEP_KEY")
fldPRS_PERSLID_KEY = GetValue(rs, "PRS_PERSLID_KEY")
SetVar "GroepRecordUpdate", ""
SetVar "GroepRecordInsert", ""
Parse "GroepRecordEdit", False
'-------------------------------
' GroepRecord ShowEdit Event begin
' GroepRecord ShowEdit Event end
'-------------------------------
else
if sGroepRecordErr = "" then
fldPRS_PERSLID_KEY = ToHTML(GetParam("PRS_PERSLID_KEY"))
end if
SetVar "GroepRecordEdit", ""
SetVar "GroepRecordInsert", ""
'-------------------------------
' GroepRecord ShowInsert Event begin
' GroepRecord ShowInsert Event end
'-------------------------------
end if
Parse "GroepRecordCancel", false
'-------------------------------
' Set lookup fields
'-------------------------------
fldFAC_GROEP_KEY = DLookUp("FAC_GROEP", "FAC_GROEP_OMSCHRIJVING", "FAC_GROEP_KEY=" & ToSQL(fldFAC_GROEP_KEY, "Number"))
'-------------------------------
' GroepRecord Show Event begin
' GroepRecord Show Event end
'-------------------------------
'-------------------------------
' Show form field
'-------------------------------
SetVar "FAC_GEBRUIKERSGROEP_KEY", ToHTML(fldFAC_GEBRUIKERSGROEP_KEY)
SetVar "PRS_PERSLID_KEY", ToHTML(fldPRS_PERSLID_KEY)
SetVar "FAC_GROEP_KEY", ToHTML(fldFAC_GROEP_KEY)
Parse "FormGroepRecord", False
'-------------------------------
' GroepRecord Close Event begin
' GroepRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' GroepRecord Show end
'-------------------------------
End Sub
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub PersoonRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKPRS_PERSLID_KEY : pPKPRS_PERSLID_KEY = ""
'-------------------------------
'-------------------------------
' PersoonRecord Action begin
'-------------------------------
sActionFileName = "fac_persoongroepgrid.asp"
sParams = sParams & "fPRS_AFDELING_KEY=" & ToURL(GetParam("Trn_fPRS_AFDELING_KEY")) & "&"
sParams = sParams & "fFAC_GROEP_KEY=" & ToURL(GetParam("Trn_fFAC_GROEP_KEY")) & "&"
sParams = sParams & "fPRS_PERSLID_NAAM=" & ToURL(GetParam("Trn_fPRS_PERSLID_NAAM"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' PersoonRecord BeforeCancel Event begin
' PersoonRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
'-------------------------------
' PersoonRecord Check Event begin
' PersoonRecord Check Event end
'-------------------------------
If len(sPersoonRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' PersoonRecord BeforeExecute Event begin
' PersoonRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sPersoonRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sPersoonRecordErr = ProcessError
on error goto 0
if len(sPersoonRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' PersoonRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub PersoonRecord_Show()
'-------------------------------
' PersoonRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Naam"
Dim bPK : bPK = True
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sPersoonRecordErr = "" then
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("fPRS_PERSLID_NAAM")
pPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
SetVar "PersoonRecordError", ""
else
SetVar "Trn_fPRS_AFDELING_KEY", GetParam("Trn_fPRS_AFDELING_KEY")
SetVar "Trn_fFAC_GROEP_KEY", GetParam("Trn_fFAC_GROEP_KEY")
SetVar "Trn_fPRS_PERSLID_NAAM", GetParam("Trn_fPRS_PERSLID_NAAM")
pPRS_PERSLID_KEY = GetParam("PK_PRS_PERSLID_KEY")
SetVar "sPersoonRecordErr", sPersoonRecordErr
SetVar "FormTitle", sFormTitle
Parse "PersoonRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pPRS_PERSLID_KEY) then bPK = False
sWhere = sWhere & "PRS_PERSLID_KEY=" & ToSQL(pPRS_PERSLID_KEY, "Number")
SetVar "PK_PRS_PERSLID_KEY", pPRS_PERSLID_KEY
'-------------------------------
'-------------------------------
' PersoonRecord Open Event begin
' PersoonRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_V_WEBUSER where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "PersoonRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldPRS_AFDELING_KEY = GetValue(rs, "PRS_AFDELING_KEY")
fldPRS_PERSLID_KEY = GetValue(rs, "PRS_PERSLID_KEY")
fldPRS_PERSLID_NAAM = GetValue(rs, "PRS_PERSLID_NAAM")
SetVar "PersoonRecordDelete", ""
SetVar "PersoonRecordUpdate", ""
SetVar "PersoonRecordInsert", ""
'-------------------------------
' PersoonRecord ShowEdit Event begin
' PersoonRecord ShowEdit Event end
'-------------------------------
else
SetVar "PersoonRecordEdit", ""
SetVar "PersoonRecordInsert", ""
'-------------------------------
' PersoonRecord ShowInsert Event begin
' PersoonRecord ShowInsert Event end
'-------------------------------
end if
Parse "PersoonRecordCancel", false
'-------------------------------
' Set lookup fields
'-------------------------------
fldPRS_AFDELING_KEY = DLookUp("PRS_V_AANWEZIGAFDELING", "PRS_AFDELING_OMSCHRIJVING", "PRS_AFDELING_KEY=" & ToSQL(fldPRS_AFDELING_KEY, "Number"))
if sPersoonRecordErr = "" then
'-------------------------------
' PersoonRecord Show Event begin
fldPRS_PERSLID_NAAM = buildName(fldPRS_PERSLID_KEY)
' PersoonRecord Show Event end
'-------------------------------
end if
'-------------------------------
' Show form field
'-------------------------------
SetVar "PRS_PERSLID_KEY", ToHTML(fldPRS_PERSLID_KEY)
SetVar "PRS_PERSLID_NAAM", ToHTML(fldPRS_PERSLID_NAAM)
SetVar "PRS_AFDELING_KEY", ToHTML(fldPRS_AFDELING_KEY)
Parse "FormPersoonRecord", False
'-------------------------------
' PersoonRecord Close Event begin
' PersoonRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' PersoonRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,142 +0,0 @@
<html>
<head>
<title>Facilitor Management Online -</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormPersoonRecordHeader-->
<!--EndFormPersoonRecordHeader-->
<!--BeginFormPersoonRecord-->
<form method="POST" action="{FileName}" name="PersoonRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginPersoonRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sPersoonRecordErr}</font></td>
</tr>
<!--EndPersoonRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Naam</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_PERSLID_NAAM}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Afdeling</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_AFDELING_KEY}&nbsp;</font></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginPersoonRecordCancel-->
<input type="submit" value="Terug" onclick="document.PersoonRecord.FormAction.value = 'cancel';"/>
<!--EndPersoonRecordCancel-->
<input type="hidden" name="FormName" value="PersoonRecord"/>
<input type="hidden" value="cancel" name="FormAction"/>
<input type="hidden" name="Trn_fPRS_AFDELING_KEY" value="{Trn_fPRS_AFDELING_KEY}"/>
<input type="hidden" name="Trn_fFAC_GROEP_KEY" value="{Trn_fFAC_GROEP_KEY}"/>
<input type="hidden" name="Trn_fPRS_PERSLID_NAAM" value="{Trn_fPRS_PERSLID_NAAM}"/>
<input type="hidden" name="PK_PRS_PERSLID_KEY" value="{PK_PRS_PERSLID_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormPersoonRecord-->
<!--BeginFormPersoonRecordFooter-->
<!--EndFormPersoonRecordFooter-->
</td>
</tr>
</table>
<table>
<tr>
<td valign="top">
<!--BeginFormGroepRecordHeader-->
<!--EndFormGroepRecordHeader-->
<!--BeginFormGroepRecord-->
<form method="POST" action="{FileName}" name="GroepRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginGroepRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sGroepRecordErr}</font></td>
</tr>
<!--EndGroepRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_GEBRUIKERSGROEP_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Groep</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_GROEP_KEY}&nbsp;</font></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginGroepRecordEdit-->
<input type="hidden" value="cancel" name="FormAction"/>
<!--BeginGroepRecordDelete-->
<input type="submit" value="Verwijderen" onclick="document.GroepRecord.FormAction.value = 'delete';"/>
<!--EndGroepRecordDelete-->
<!--EndGroepRecordEdit-->
<!--BeginGroepRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.GroepRecord.FormAction.value = 'cancel';"/>
<!--EndGroepRecordCancel-->
<input type="hidden" name="FormName" value="GroepRecord"/>
<input type="hidden" name="Trn_PRS_PERSLID_KEY" value="{Trn_PRS_PERSLID_KEY}"/>
<input type="hidden" name="Trn_fPRS_AFDELING_KEY" value="{Trn_fPRS_AFDELING_KEY}"/>
<input type="hidden" name="Trn_fFAC_GROEP_KEY" value="{Trn_fFAC_GROEP_KEY}"/>
<input type="hidden" name="Trn_fPRS_PERSLID_NAAM" value="{Trn_fPRS_PERSLID_NAAM}"/>
<input type="hidden" name="PK_FAC_GEBRUIKERSGROEP_KEY" value="{PK_FAC_GEBRUIKERSGROEP_KEY}"/>
<input type="hidden" name="PRS_PERSLID_KEY" value="{PRS_PERSLID_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormGroepRecord-->
<!--BeginFormGroepRecordFooter-->
<!--EndFormGroepRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,419 +0,0 @@
<%
'
' Filename: fac_userrapgrid.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_userrapgrid CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_userrapgrid CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_userrapgrid.asp"
sTemplateFileName = "fac_userrapgrid.html"
'===============================
'===============================
' fac_userrapgrid PageSecurity begin
' fac_userrapgrid PageSecurity end
'===============================
'===============================
' fac_userrapgrid Open Event begin
' fac_userrapgrid Open Event end
'===============================
'===============================
' fac_userrapgrid OpenAnyPage Event begin
' fac_userrapgrid OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_userrapgrid Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
UserrapSearch_Show
UserrapGrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_userrapgrid Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_userrapgrid Close Event begin
' fac_userrapgrid Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub UserrapGrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Rapportages"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 25
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
Dim sActionFileName : sActionFileName = "fac_userraprecord.asp"
SetVar "TransitParams", "sFAC_USRRAP_OMSCHRIJVING=" & ToURL(GetParam("sFAC_USRRAP_OMSCHRIJVING")) & "&sFAC_USRRAP_VIEW_NAME=" & ToURL(GetParam("sFAC_USRRAP_VIEW_NAME")) & "&"
SetVar "FormParams", "sFAC_USRRAP_OMSCHRIJVING=" & ToURL(GetParam("sFAC_USRRAP_OMSCHRIJVING")) & "&sFAC_USRRAP_VIEW_NAME=" & ToURL(GetParam("sFAC_USRRAP_VIEW_NAME")) & "&"
'-------------------------------
' Build WHERE statement
'-------------------------------
'-------------------------------
' Build ORDER BY statement
'-------------------------------
sOrder = " order by F.FAC_USRRAP_OMSCHRIJVING Asc"
iSort = GetParam("FormUserrapGrid_Sorting")
iSorted = GetParam("FormUserrapGrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormUserrapGrid_Sorting=" & iSort & "&FormUserrapGrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormUserrapGrid_Sorting=" & iSort & "&FormUserrapGrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by F.FAC_USRRAP_KEY" & sDirection
if iSort = 2 then sOrder = " order by F.FAC_USRRAP_OMSCHRIJVING" & sDirection
if iSort = 3 then sOrder = " order by F.FAC_USRRAP_VIEW_NAME" & sDirection
if iSort = 4 then sOrder = " order by F.FAC_USRRAP_INFO" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select F.FAC_USRRAP_INFO as F_FAC_USRRAP_INFO, " & _
"F.FAC_USRRAP_KEY as F_FAC_USRRAP_KEY, " & _
"F.FAC_USRRAP_OMSCHRIJVING as F_FAC_USRRAP_OMSCHRIJVING, " & _
"F.FAC_USRRAP_VIEW_NAME as F_FAC_USRRAP_VIEW_NAME " & _
" from FAC_USRRAP F "
'-------------------------------
'-------------------------------
' UserrapGrid Open Event begin
tmpWhere = ""
pFAC_USRRAP_OMSCHRIJVING = getParam("sFAC_USRRAP_OMSCHRIJVING")
pFAC_USRRAP_VIEW_NAME = getParam("sFAC_USRRAP_VIEW_NAME")
if not isEmpty(pFAC_USRRAP_OMSCHRIJVING) or not isEmpty(pFAC_USRRAP_VIEW_NAME) then
hasParam = true
if not isEmpty(pFAC_USRRAP_OMSCHRIJVING) then
tmpWhere = tmpWhere & " AND Upper(FAC_USRRAP_OMSCHRIJVING) like '%" & UCase(replace(pFAC_USRRAP_OMSCHRIJVING,"'","''")) & "%'"
end if
if not isEmpty(pFAC_USRRAP_VIEW_NAME) then
tmpWhere = tmpWhere & " AND Upper(FAC_USRRAP_VIEW_NAME) like '%" & UCase(replace(pFAC_USRRAP_VIEW_NAME ,"'","''")) & "%'"
end if
end if
if sWhere = "" then
sWhere = " WHERE 1=1 "
end if
sWhere = sWhere & tmpWhere
' UserrapGrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the link to the record page
'-------------------------------
SetVar "FormAction", sActionFileName
'-------------------------------
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListUserrapGrid", ""
Parse "UserrapGridNoRecords", False
SetVar "UserrapGridNavigator", ""
Parse "FormUserrapGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 25
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormUserrapGrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "UserrapGridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldFAC_USRRAP_INFO = GetValue(rs, "F_FAC_USRRAP_INFO")
fldFAC_USRRAP_KEY = GetValue(rs, "F_FAC_USRRAP_KEY")
fldFAC_USRRAP_OMSCHRIJVING_URLLink = "fac_userraprecord.asp"
fldFAC_USRRAP_OMSCHRIJVING_FAC_USRRAP_KEY = GetValue(rs, "F_FAC_USRRAP_KEY")
fldFAC_USRRAP_OMSCHRIJVING = GetValue(rs, "F_FAC_USRRAP_OMSCHRIJVING")
fldFAC_USRRAP_VIEW_NAME = GetValue(rs, "F_FAC_USRRAP_VIEW_NAME")
'-------------------------------
' UserrapGrid Show begin
'-------------------------------
'-------------------------------
' UserrapGrid Show Event begin
' UserrapGrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "FAC_USRRAP_KEY", ToHTML(fldFAC_USRRAP_KEY)
SetVar "FAC_USRRAP_OMSCHRIJVING", ToHTML(fldFAC_USRRAP_OMSCHRIJVING)
SetVar "FAC_USRRAP_OMSCHRIJVING_URLLink", fldFAC_USRRAP_OMSCHRIJVING_URLLink
SetVar "PrmFAC_USRRAP_OMSCHRIJVING_FAC_USRRAP_KEY", ToURL(fldFAC_USRRAP_OMSCHRIJVING_FAC_USRRAP_KEY)
SetVar "FAC_USRRAP_VIEW_NAME", ToHTML(fldFAC_USRRAP_VIEW_NAME)
SetVar "FAC_USRRAP_INFO", ToHTML(fldFAC_USRRAP_INFO)
Parse "DListUserrapGrid", True
'-------------------------------
' UserrapGrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' UserrapGrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "UserrapGridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "UserrapGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "UserrapGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "UserrapGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "UserrapGridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "UserrapGridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "UserrapGridCurrentPage", iPage
Parse "UserrapGridNavigator", False
end if
'-------------------------------
' UserrapGrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "UserrapGridNoRecords", ""
Parse "FormUserrapGrid", False
'-------------------------------
' UserrapGrid Close Event begin
' UserrapGrid Close Event end
'-------------------------------
End Sub
'===============================
'===============================
' Display Search Form
'-------------------------------
Sub UserrapSearch_Show()
Dim sFormTitle: sFormTitle = ""
Dim sActionFileName: sActionFileName = "fac_userrapgrid.asp"
'-------------------------------
' UserrapSearch Open Event begin
' UserrapSearch Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
SetVar "ActionPage", sActionFileName
'-------------------------------
' Set variables with search parameters
'-------------------------------
fldsFAC_USRRAP_OMSCHRIJVING = GetParam("sFAC_USRRAP_OMSCHRIJVING")
fldsFAC_USRRAP_VIEW_NAME = GetParam("sFAC_USRRAP_VIEW_NAME")
'-------------------------------
' UserrapSearch Show begin
'-------------------------------
'-------------------------------
' UserrapSearch Show Event begin
' UserrapSearch Show Event end
'-------------------------------
SetVar "sFAC_USRRAP_OMSCHRIJVING", ToHTML(fldsFAC_USRRAP_OMSCHRIJVING)
SetVar "sFAC_USRRAP_VIEW_NAME", ToHTML(fldsFAC_USRRAP_VIEW_NAME)
'-------------------------------
' UserrapSearch Show end
'-------------------------------
'-------------------------------
' UserrapSearch Close Event begin
' UserrapSearch Close Event end
'-------------------------------
Parse "FormUserrapSearch", False
End Sub
'===============================
%>

View File

@@ -1,91 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Gebruikersrapportages</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormUserrapSearchHeader-->
<!--EndFormUserrapSearchHeader-->
<!--BeginFormUserrapSearch--><form method="POST" action="{ActionPage}" name="UserrapSearch">
<input type="hidden" name="FormName" value="UserrapSearch"><input type="hidden" name="FormAction" value="search">
<table class="FormTABLE">
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Omschrijving</font></td>
<td class="DataTD"><input type="text" name="sFAC_USRRAP_OMSCHRIJVING" maxlength="30" value="{sFAC_USRRAP_OMSCHRIJVING}" size="30"></td>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Viewname</font></td>
<td class="DataTD"><input type="text" name="sFAC_USRRAP_VIEW_NAME" maxlength="30" value="{sFAC_USRRAP_VIEW_NAME}" size="30"></td>
<td><input type="submit" value="Zoeken"></td>
</tr>
</table>
</form><!--EndFormUserrapSearch-->
<!--BeginFormUserrapSearchFooter-->
<!--EndFormUserrapSearchFooter-->
</td>
</tr>
</table>
<table>
<tr>
<td valign="top">
<!--BeginFormUserrapGridHeader-->
<!--EndFormUserrapGridHeader-->
<!--BeginFormUserrapGrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="4"><a name="UserrapGrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormUserrapGrid_Sorting=1&FormUserrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Key</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormUserrapGrid_Sorting=2&FormUserrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Omschrijving</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormUserrapGrid_Sorting=3&FormUserrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Viewname</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormUserrapGrid_Sorting=4&FormUserrapGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Info</font></a></td>
</tr>
<!--BeginDListUserrapGrid-->
<tr>
<td class="DataTD"><font class="DataFONT">{FAC_USRRAP_KEY}&nbsp;</font></td>
<td class="DataTD"><a href="{FAC_USRRAP_OMSCHRIJVING_URLLink}?FAC_USRRAP_KEY={PrmFAC_USRRAP_OMSCHRIJVING_FAC_USRRAP_KEY}&{TransitParams}"><font class="DataFONT">{FAC_USRRAP_OMSCHRIJVING}</font></a>&nbsp;</td>
<td class="DataTD"><font class="DataFONT">{FAC_USRRAP_VIEW_NAME}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_USRRAP_INFO}&nbsp;</font></td>
</tr>
<!--EndDListUserrapGrid-->
<!--BeginUserrapGridNoRecords-->
<tr><td colspan="4" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndUserrapGridNoRecords-->
<tr>
<td colspan="4" class="ColumnTD">
<font class="ColumnFONT">
<a href="{FormAction}?{TransitParams}"><font class="ColumnFONT">Toevoegen</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<!--BeginUserrapGridNavigator-->
<a href{UserrapGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormUserrapGrid_Page=1#UserrapGrid"><font class="ColumnFONT"><<</font></a>
<a href{UserrapGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormUserrapGrid_Page={PrevPage}#UserrapGrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginUserrapGridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormUserrapGrid_Page={NavigatorPageNumber}#UserrapGrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndUserrapGridNavigatorPages-->van {UserrapGridPageCount} ]
<a href{UserrapGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormUserrapGrid_Page={NextPage}#UserrapGrid"><font class="ColumnFONT">></font></a>
<a href{UserrapGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormUserrapGrid_Page=last#UserrapGrid"><font class="ColumnFONT">>></font></a>
<!--EndUserrapGridNavigator-->
</font>
</td>
</tr>
</table>
<!--EndFormUserrapGrid-->
<!--BeginFormUserrapGridFooter-->
<!--EndFormUserrapGridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,514 +0,0 @@
<%
'
' Filename: fac_userraprecord.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_userraprecord CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_userraprecord CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_userraprecord.asp"
sTemplateFileName = "fac_userraprecord.html"
'===============================
'===============================
' fac_userraprecord PageSecurity begin
' fac_userraprecord PageSecurity end
'===============================
'===============================
' fac_userraprecord Open Event begin
' fac_userraprecord Open Event end
'===============================
'===============================
' fac_userraprecord OpenAnyPage Event begin
' fac_userraprecord OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fac_userraprecord Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sUserrapRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "UserrapRecord"
UserrapRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
UserrapRecord_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_userraprecord Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_userraprecord Close Event begin
' fac_userraprecord Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub UserrapRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKFAC_USRRAP_KEY : pPKFAC_USRRAP_KEY = ""
Dim fldFAC_USRRAP_OMSCHRIJVING : fldFAC_USRRAP_OMSCHRIJVING = ""
Dim fldFAC_USRRAP_VIEW_NAME : fldFAC_USRRAP_VIEW_NAME = ""
Dim fldFAC_USRRAP_INFO : fldFAC_USRRAP_INFO = ""
Dim fldFAC_USRRAP_IN_HUIDIGE_LOCATIE : fldFAC_USRRAP_IN_HUIDIGE_LOCATIE = ""
Dim fldFAC_USRRAP_AANMAAK : fldFAC_USRRAP_AANMAAK = ""
Dim fldFAC_USRRAP_TEMPLATE : fldFAC_USRRAP_TEMPLATE = ""
Dim fldFAC_USRRAP_MACRO : fldFAC_USRRAP_MACRO = ""
Dim fldFAC_USRRAP_VRAAGBEGINDATUM : fldFAC_USRRAP_VRAAGBEGINDATUM = ""
Dim fldFAC_USRRAP_VRAAGEINDDATUM : fldFAC_USRRAP_VRAAGEINDDATUM = ""
Dim fldFAC_USRRAP_FUNCTIE : fldFAC_USRRAP_FUNCTIE = ""
Dim fldFAC_FUNCTIE_KEY : fldFAC_FUNCTIE_KEY = ""
Dim fldFAC_USRRAP_AUTOREFRESH : fldFAC_USRRAP_AUTOREFRESH = ""
'-------------------------------
'-------------------------------
' UserrapRecord Action begin
'-------------------------------
sActionFileName = "fac_userrapgrid.asp"
sParams = sParams & "sFAC_USRRAP_OMSCHRIJVING=" & ToURL(GetParam("Trn_sFAC_USRRAP_OMSCHRIJVING")) & "&"
sParams = sParams & "sFAC_USRRAP_VIEW_NAME=" & ToURL(GetParam("Trn_sFAC_USRRAP_VIEW_NAME"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' UserrapRecord BeforeCancel Event begin
' UserrapRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKFAC_USRRAP_KEY = GetParam("PK_FAC_USRRAP_KEY")
if IsEmpty(pPKFAC_USRRAP_KEY) then exit sub
sWhere = "FAC_USRRAP_KEY=" & ToSQL(pPKFAC_USRRAP_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldFAC_USRRAP_OMSCHRIJVING = GetParam("FAC_USRRAP_OMSCHRIJVING")
fldFAC_USRRAP_VIEW_NAME = GetParam("FAC_USRRAP_VIEW_NAME")
fldFAC_USRRAP_INFO = GetParam("FAC_USRRAP_INFO")
fldFAC_USRRAP_IN_HUIDIGE_LOCATIE = GetParam("FAC_USRRAP_IN_HUIDIGE_LOCATIE")
fldFAC_USRRAP_AANMAAK = GetParam("FAC_USRRAP_AANMAAK")
fldFAC_USRRAP_TEMPLATE = GetParam("FAC_USRRAP_TEMPLATE")
fldFAC_USRRAP_MACRO = GetParam("FAC_USRRAP_MACRO")
fldFAC_USRRAP_VRAAGBEGINDATUM = GetParam("FAC_USRRAP_VRAAGBEGINDATUM")
fldFAC_USRRAP_VRAAGEINDDATUM = GetParam("FAC_USRRAP_VRAAGEINDDATUM")
fldFAC_USRRAP_FUNCTIE = GetParam("FAC_USRRAP_FUNCTIE")
fldFAC_FUNCTIE_KEY = GetParam("FAC_FUNCTIE_KEY")
fldFAC_USRRAP_AUTOREFRESH = getCheckBoxValue(GetParam("FAC_USRRAP_AUTOREFRESH"), "1", "0", "Number")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if IsEmpty(fldFAC_USRRAP_OMSCHRIJVING) then
sUserrapRecordErr = sUserrapRecordErr & "De waarde in veld Omschrijving is verplicht.<br>"
end if
if IsEmpty(fldFAC_USRRAP_VIEW_NAME) then
sUserrapRecordErr = sUserrapRecordErr & "De waarde in veld Viewname is verplicht.<br>"
end if
if not isNumeric(fldFAC_USRRAP_VRAAGBEGINDATUM) then
sUserrapRecordErr = sUserrapRecordErr & "De waarde in veld FAC_USRRAP_VRAAGBEGINDATUM is niet correct.<br>"
end if
if not isNumeric(fldFAC_USRRAP_VRAAGEINDDATUM) then
sUserrapRecordErr = sUserrapRecordErr & "De waarde in veld FAC_USRRAP_VRAAGEINDDATUM is niet correct.<br>"
end if
if not isNumeric(fldFAC_USRRAP_FUNCTIE) then
sUserrapRecordErr = sUserrapRecordErr & "De waarde in veld Styling optie is niet correct.<br>"
end if
if not isNumeric(fldFAC_FUNCTIE_KEY) then
sUserrapRecordErr = sUserrapRecordErr & "De waarde in veld Autorisatie als is niet correct.<br>"
end if
'-------------------------------
' UserrapRecord Check Event begin
' UserrapRecord Check Event end
'-------------------------------
If len(sUserrapRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' UserrapRecord Insert Event begin
sSQL = "insert into FAC_USRRAP (" & _
"FAC_USRRAP_OMSCHRIJVING," & _
"FAC_USRRAP_VIEW_NAME," & _
"FAC_USRRAP_INFO," & _
"FAC_USRRAP_IN_HUIDIGE_LOCATIE," & _
"FAC_USRRAP_AANMAAK," & _
"FAC_USRRAP_TEMPLATE," & _
"FAC_USRRAP_MACRO," & _
"FAC_USRRAP_VRAAGBEGINDATUM," & _
"FAC_USRRAP_VRAAGEINDDATUM," & _
"FAC_USRRAP_FUNCTIE,"&_
"FAC_USRRAP_AUTOREFRESH,"&_
"FAC_FUNCTIE_KEY)" & _
" values (" & _
ToSQL(fldFAC_USRRAP_OMSCHRIJVING, "Text") & "," & _
ToSQL(fldFAC_USRRAP_VIEW_NAME, "Text") & "," & _
ToSQL(fldFAC_USRRAP_INFO, "Text") & "," & _
ToSQL(fldFAC_USRRAP_IN_HUIDIGE_LOCATIE, "Text") & "," & _
SysDate & "," & _
ToSQL(fldFAC_USRRAP_TEMPLATE, "Text") & "," & _
ToSQL(fldFAC_USRRAP_MACRO, "Text") & "," & _
ToSQL(fldFAC_USRRAP_VRAAGBEGINDATUM, "Number") & "," & _
ToSQL(fldFAC_USRRAP_VRAAGEINDDATUM, "Number") & "," & _
ToSQL(fldFAC_USRRAP_FUNCTIE, "Number") & "," & _
ToSql(fldFAC_USRRAP_AUTOREFRESH,"Number") & "," & _
ToSql(fldFAC_FUNCTIE_KEY,"Number") &_
")"
' UserrapRecord Insert Event end
'-------------------------------
if sSQL = "" then
sSQL = "insert into FAC_USRRAP (" & _
"FAC_USRRAP_OMSCHRIJVING," & _
"FAC_USRRAP_VIEW_NAME," & _
"FAC_USRRAP_INFO," & _
"FAC_USRRAP_IN_HUIDIGE_LOCATIE," & _
"FAC_USRRAP_AANMAAK," & _
"FAC_USRRAP_TEMPLATE," & _
"FAC_USRRAP_MACRO," & _
"FAC_USRRAP_VRAAGBEGINDATUM," & _
"FAC_USRRAP_VRAAGEINDDATUM," & _
"FAC_USRRAP_FUNCTIE," & _
"FAC_FUNCTIE_KEY," & _
"FAC_USRRAP_AUTOREFRESH)" & _
" values (" & _
ToSQL(fldFAC_USRRAP_OMSCHRIJVING, "Text") & "," & _
ToSQL(fldFAC_USRRAP_VIEW_NAME, "Text") & "," & _
ToSQL(fldFAC_USRRAP_INFO, "Text") & "," & _
ToSQL(fldFAC_USRRAP_IN_HUIDIGE_LOCATIE, "Text") & "," & _
ToSQL(fldFAC_USRRAP_AANMAAK, "Date") & "," & _
ToSQL(fldFAC_USRRAP_TEMPLATE, "Text") & "," & _
ToSQL(fldFAC_USRRAP_MACRO, "Text") & "," & _
ToSQL(fldFAC_USRRAP_VRAAGBEGINDATUM, "Number") & "," & _
ToSQL(fldFAC_USRRAP_VRAAGEINDDATUM, "Number") & "," & _
ToSQL(fldFAC_USRRAP_FUNCTIE, "Number") & "," & _
ToSQL(fldFAC_FUNCTIE_KEY, "Number") & "," & _
fldFAC_USRRAP_AUTOREFRESH & _
")"
end if
case "update"
'-------------------------------
' UserrapRecord Update Event begin
sSQL = "update FAC_USRRAP set " & _
"FAC_USRRAP_OMSCHRIJVING=" & ToSQL(fldFAC_USRRAP_OMSCHRIJVING, "Text") & _
",FAC_USRRAP_VIEW_NAME=" & ToSQL(fldFAC_USRRAP_VIEW_NAME, "Text") & _
",FAC_USRRAP_INFO=" & ToSQL(fldFAC_USRRAP_INFO, "Text") &_
",FAC_USRRAP_AUTOREFRESH=" & ToSQL(fldFAC_USRRAP_AUTOREFRESH,"Number") &_
",FAC_USRRAP_FUNCTIE=" & ToSQL(fldFAC_USRRAP_FUNCTIE,"Number") &_
",FAC_FUNCTIE_KEY=" & ToSQL(fldFAC_FUNCTIE_KEY,"Number")
sSQL = sSQL & " where " & sWhere
' UserrapRecord Update Event end
'-------------------------------
if sSQL = "" then
sSQL = "update FAC_USRRAP set " & _
"FAC_USRRAP_OMSCHRIJVING=" & ToSQL(fldFAC_USRRAP_OMSCHRIJVING, "Text") & _
",FAC_USRRAP_VIEW_NAME=" & ToSQL(fldFAC_USRRAP_VIEW_NAME, "Text") & _
",FAC_USRRAP_INFO=" & ToSQL(fldFAC_USRRAP_INFO, "Text") & _
",FAC_USRRAP_IN_HUIDIGE_LOCATIE=" & ToSQL(fldFAC_USRRAP_IN_HUIDIGE_LOCATIE, "Text") & _
",FAC_USRRAP_AANMAAK=" & ToSQL(fldFAC_USRRAP_AANMAAK, "Date") & _
",FAC_USRRAP_TEMPLATE=" & ToSQL(fldFAC_USRRAP_TEMPLATE, "Text") & _
",FAC_USRRAP_MACRO=" & ToSQL(fldFAC_USRRAP_MACRO, "Text") & _
",FAC_USRRAP_VRAAGBEGINDATUM=" & ToSQL(fldFAC_USRRAP_VRAAGBEGINDATUM, "Number") & _
",FAC_USRRAP_VRAAGEINDDATUM=" & ToSQL(fldFAC_USRRAP_VRAAGEINDDATUM, "Number") & _
",FAC_USRRAP_FUNCTIE=" & ToSQL(fldFAC_USRRAP_FUNCTIE, "Number") & _
",FAC_FUNCTIE_KEY=" & ToSQL(fldFAC_FUNCTIE_KEY, "Number") & _
",FAC_USRRAP_AUTOREFRESH=" & fldFAC_USRRAP_AUTOREFRESH
sSQL = sSQL & " where " & sWhere
end if
case "delete"
'-------------------------------
' UserrapRecord Delete Event begin
' UserrapRecord Delete Event end
'-------------------------------
sSQL = "delete from FAC_USRRAP where " & sWhere
end select
'-------------------------------
'-------------------------------
' UserrapRecord BeforeExecute Event begin
' UserrapRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sUserrapRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sUserrapRecordErr = ProcessError
on error goto 0
if len(sUserrapRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' UserrapRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub UserrapRecord_Show()
'-------------------------------
' UserrapRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Details rapportage"
Dim bPK : bPK = True
Dim sFAC_FUNCTIE_KEYDisplayValue: sFAC_FUNCTIE_KEYDisplayValue = ""
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sUserrapRecordErr = "" then
SetVar "Trn_sFAC_USRRAP_OMSCHRIJVING", GetParam("sFAC_USRRAP_OMSCHRIJVING")
SetVar "Trn_sFAC_USRRAP_VIEW_NAME", GetParam("sFAC_USRRAP_VIEW_NAME")
pFAC_USRRAP_KEY = GetParam("FAC_USRRAP_KEY")
SetVar "UserrapRecordError", ""
else
fldFAC_USRRAP_OMSCHRIJVING = GetParam("FAC_USRRAP_OMSCHRIJVING")
fldFAC_USRRAP_VIEW_NAME = GetParam("FAC_USRRAP_VIEW_NAME")
fldFAC_USRRAP_INFO = GetParam("FAC_USRRAP_INFO")
fldFAC_USRRAP_IN_HUIDIGE_LOCATIE = GetParam("FAC_USRRAP_IN_HUIDIGE_LOCATIE")
fldFAC_USRRAP_AANMAAK = GetParam("FAC_USRRAP_AANMAAK")
fldFAC_USRRAP_TEMPLATE = GetParam("FAC_USRRAP_TEMPLATE")
fldFAC_USRRAP_MACRO = GetParam("FAC_USRRAP_MACRO")
fldFAC_USRRAP_VRAAGBEGINDATUM = GetParam("FAC_USRRAP_VRAAGBEGINDATUM")
fldFAC_USRRAP_VRAAGEINDDATUM = GetParam("FAC_USRRAP_VRAAGEINDDATUM")
fldFAC_USRRAP_FUNCTIE = GetParam("FAC_USRRAP_FUNCTIE")
fldFAC_FUNCTIE_KEY = GetParam("FAC_FUNCTIE_KEY")
fldFAC_USRRAP_AUTOREFRESH = getCheckBoxValue(GetParam("FAC_USRRAP_AUTOREFRESH"), "1", "0", "Number")
SetVar "Trn_sFAC_USRRAP_OMSCHRIJVING", GetParam("Trn_sFAC_USRRAP_OMSCHRIJVING")
SetVar "Trn_sFAC_USRRAP_VIEW_NAME", GetParam("Trn_sFAC_USRRAP_VIEW_NAME")
pFAC_USRRAP_KEY = GetParam("PK_FAC_USRRAP_KEY")
SetVar "sUserrapRecordErr", sUserrapRecordErr
SetVar "FormTitle", sFormTitle
Parse "UserrapRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pFAC_USRRAP_KEY) then bPK = False
sWhere = sWhere & "FAC_USRRAP_KEY=" & ToSQL(pFAC_USRRAP_KEY, "Number")
SetVar "PK_FAC_USRRAP_KEY", pFAC_USRRAP_KEY
'-------------------------------
'-------------------------------
' UserrapRecord Open Event begin
' UserrapRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_USRRAP where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "UserrapRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldFAC_USRRAP_AANMAAK = GetValue(rs, "FAC_USRRAP_AANMAAK")
fldFAC_USRRAP_IN_HUIDIGE_LOCATIE = GetValue(rs, "FAC_USRRAP_IN_HUIDIGE_LOCATIE")
fldFAC_USRRAP_KEY = GetValue(rs, "FAC_USRRAP_KEY")
fldFAC_USRRAP_MACRO = GetValue(rs, "FAC_USRRAP_MACRO")
fldFAC_USRRAP_TEMPLATE = GetValue(rs, "FAC_USRRAP_TEMPLATE")
fldFAC_USRRAP_VRAAGBEGINDATUM = GetValue(rs, "FAC_USRRAP_VRAAGBEGINDATUM")
fldFAC_USRRAP_VRAAGEINDDATUM = GetValue(rs, "FAC_USRRAP_VRAAGEINDDATUM")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sUserrapRecordErr = "" then
fldFAC_USRRAP_OMSCHRIJVING = GetValue(rs, "FAC_USRRAP_OMSCHRIJVING")
fldFAC_USRRAP_VIEW_NAME = GetValue(rs, "FAC_USRRAP_VIEW_NAME")
fldFAC_USRRAP_INFO = GetValue(rs, "FAC_USRRAP_INFO")
fldFAC_USRRAP_FUNCTIE = GetValue(rs, "FAC_USRRAP_FUNCTIE")
fldFAC_FUNCTIE_KEY = GetValue(rs, "FAC_FUNCTIE_KEY")
fldFAC_USRRAP_AUTOREFRESH = GetValue(rs, "FAC_USRRAP_AUTOREFRESH")
end if
SetVar "UserrapRecordInsert", ""
Parse "UserrapRecordEdit", False
'-------------------------------
' UserrapRecord ShowEdit Event begin
' UserrapRecord ShowEdit Event end
'-------------------------------
else
if sUserrapRecordErr = "" then
fldFAC_USRRAP_VRAAGBEGINDATUM= "0"
fldFAC_USRRAP_VRAAGEINDDATUM= "0"
fldFAC_USRRAP_FUNCTIE= "0"
end if
SetVar "UserrapRecordEdit", ""
Parse "UserrapRecordInsert", False
'-------------------------------
' UserrapRecord ShowInsert Event begin
' UserrapRecord ShowInsert Event end
'-------------------------------
end if
Parse "UserrapRecordCancel", false
'-------------------------------
' UserrapRecord Show Event begin
' UserrapRecord Show Event end
'-------------------------------
'-------------------------------
' Show form field
'-------------------------------
SetVar "FAC_USRRAP_KEY", ToHTML(fldFAC_USRRAP_KEY)
SetVar "FAC_USRRAP_OMSCHRIJVING", ToHTML(fldFAC_USRRAP_OMSCHRIJVING)
SetVar "FAC_USRRAP_VIEW_NAME", ToHTML(fldFAC_USRRAP_VIEW_NAME)
SetVar "FAC_USRRAP_INFO", ToHTML(fldFAC_USRRAP_INFO)
SetVar "FAC_USRRAP_IN_HUIDIGE_LOCATIE", ToHTML(fldFAC_USRRAP_IN_HUIDIGE_LOCATIE)
SetVar "FAC_USRRAP_AANMAAK", ToHTML(fldFAC_USRRAP_AANMAAK)
SetVar "FAC_USRRAP_TEMPLATE", ToHTML(fldFAC_USRRAP_TEMPLATE)
SetVar "FAC_USRRAP_MACRO", ToHTML(fldFAC_USRRAP_MACRO)
SetVar "FAC_USRRAP_VRAAGBEGINDATUM", ToHTML(fldFAC_USRRAP_VRAAGBEGINDATUM)
SetVar "FAC_USRRAP_VRAAGEINDDATUM", ToHTML(fldFAC_USRRAP_VRAAGEINDDATUM)
SetVar "UserrapRecordLBFAC_USRRAP_FUNCTIE", ""
LOV = Split("0;on-gestylede;1;gestylede;2;procedure;3;procedure gestyled;8;Via tabelizer", ";")
if (ubound(LOV) mod 2) = 1 then
for i = 0 to ubound(LOV) step 2
SetVar "ID", LOV(i) : SetVar "Value", LOV(i+1)
if cstr(LOV(i)) = cstr(fldFAC_USRRAP_FUNCTIE) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "UserrapRecordLBFAC_USRRAP_FUNCTIE", True
next
end if
SetVar "UserrapRecordLBFAC_FUNCTIE_KEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sFAC_FUNCTIE_KEYDisplayValue
Parse "UserrapRecordLBFAC_FUNCTIE_KEY", True
openrs rsFAC_FUNCTIE_KEY, "select fac_functie_key, fac_functie_omschrijving from fac_functie order by fac_functie_omschrijving asc"
while not rsFAC_FUNCTIE_KEY.EOF
SetVar "ID", GetValue(rsFAC_FUNCTIE_KEY, 0) : SetVar "Value", GetValue(rsFAC_FUNCTIE_KEY, 1)
if cstr(GetValue(rsFAC_FUNCTIE_KEY, 0)) = cstr(fldFAC_FUNCTIE_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "UserrapRecordLBFAC_FUNCTIE_KEY", True
rsFAC_FUNCTIE_KEY.MoveNext
wend
set rsFAC_FUNCTIE_KEY = nothing
if (LCase(fldFAC_USRRAP_AUTOREFRESH) = LCase("1")) then
SetVar "FAC_USRRAP_AUTOREFRESH_CHECKED", "CHECKED"
else
SetVar "FAC_USRRAP_AUTOREFRESH_CHECKED", ""
end if
Parse "FormUserrapRecord", False
'-------------------------------
' UserrapRecord Close Event begin
' UserrapRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' UserrapRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,129 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Details gebruikersrapportage</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormUserrapRecordHeader-->
<script type="text/javascript">
document.body.onload=initFields;
function initFields()
{
var viaTabelizer = ($("[name=FAC_USRRAP_FUNCTIE]").val() == 8);
if (viaTabelizer)
{
$("[name=FAC_USRRAP_FUNCTIE]").parent().parent().hide();
}
$("[name=FAC_USRRAP_FUNCTIE] option[value='8']").hide();
}
</script>
<!--EndFormUserrapRecordHeader-->
<!--BeginFormUserrapRecord-->
<form method="POST" action="{FileName}" name="UserrapRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginUserrapRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sUserrapRecordErr}</font></td>
</tr>
<!--EndUserrapRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_USRRAP_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Omschrijving</font></td>
<td class="DataTD"><input type="text" name="FAC_USRRAP_OMSCHRIJVING" maxlength="60" value="{FAC_USRRAP_OMSCHRIJVING}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Viewname</font></td>
<td class="DataTD"><input type="text" name="FAC_USRRAP_VIEW_NAME" maxlength="32" value="{FAC_USRRAP_VIEW_NAME}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Info</font></td>
<td class="DataTD"><textarea name="FAC_USRRAP_INFO" cols="72" rows="3">{FAC_USRRAP_INFO}</textarea></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Styling optie</font></td>
<td class="DataTD"><select name="FAC_USRRAP_FUNCTIE"><!--BeginUserrapRecordLBFAC_USRRAP_FUNCTIE--><option value="{ID}" {Selected}>{Value}</option><!--EndUserrapRecordLBFAC_USRRAP_FUNCTIE--></select></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Autorisatie als</font></td>
<td class="DataTD"><select name="FAC_FUNCTIE_KEY"><!--BeginUserrapRecordLBFAC_FUNCTIE_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndUserrapRecordLBFAC_FUNCTIE_KEY--></select></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Automatisch verversen</font></td>
<td class="DataTD"><input {FAC_USRRAP_AUTOREFRESH_CHECKED} type="checkbox" name="FAC_USRRAP_AUTOREFRESH"></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginUserrapRecordInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.UserrapRecord.FormAction.value = 'insert';">
<!--EndUserrapRecordInsert-->
<!--BeginUserrapRecordEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginUserrapRecordUpdate-->
<input type="submit" value="Bewaren" onclick="document.UserrapRecord.FormAction.value = 'update';"/>
<!--EndUserrapRecordUpdate-->
<!--BeginUserrapRecordDelete-->
<input type="submit" value="Verwijderen" onclick="document.UserrapRecord.FormAction.value = 'delete';"/>
<!--EndUserrapRecordDelete-->
<!--EndUserrapRecordEdit-->
<!--BeginUserrapRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.UserrapRecord.FormAction.value = 'cancel';"/>
<!--EndUserrapRecordCancel-->
<input type="hidden" name="FormName" value="UserrapRecord"/>
<input type="hidden" name="Trn_sFAC_USRRAP_OMSCHRIJVING" value="{Trn_sFAC_USRRAP_OMSCHRIJVING}"/>
<input type="hidden" name="Trn_sFAC_USRRAP_VIEW_NAME" value="{Trn_sFAC_USRRAP_VIEW_NAME}"/>
<input type="hidden" name="PK_FAC_USRRAP_KEY" value="{PK_FAC_USRRAP_KEY}"/>
<input type="hidden" name="FAC_USRRAP_IN_HUIDIGE_LOCATIE" value="{FAC_USRRAP_IN_HUIDIGE_LOCATIE}"/>
<input type="hidden" name="FAC_USRRAP_AANMAAK" value="{FAC_USRRAP_AANMAAK}"/>
<input type="hidden" name="FAC_USRRAP_TEMPLATE" value="{FAC_USRRAP_TEMPLATE}"/>
<input type="hidden" name="FAC_USRRAP_MACRO" value="{FAC_USRRAP_MACRO}"/>
<input type="hidden" name="FAC_USRRAP_VRAAGBEGINDATUM" value="{FAC_USRRAP_VRAAGBEGINDATUM}"/>
<input type="hidden" name="FAC_USRRAP_VRAAGEINDDATUM" value="{FAC_USRRAP_VRAAGEINDDATUM}"/>
</td>
</tr>
</table>
</form>
<!--EndFormUserrapRecord-->
<!--BeginFormUserrapRecordFooter-->
<!--EndFormUserrapRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,514 +0,0 @@
<%
'
' Filename: fac_usrdatarecord1.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fac_usrdatarecord1 CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fac_usrdatarecord1 CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fac_usrdatarecord1.asp"
sTemplateFileName = "fac_usrdatarecord1.html"
'===============================
'===============================
' fac_usrdatarecord1 PageSecurity begin
' fac_usrdatarecord1 PageSecurity end
'===============================
'===============================
' fac_usrdatarecord1 Open Event begin
' fac_usrdatarecord1 Open Event end
'===============================
'===============================
' fac_usrdatarecord1 OpenAnyPage Event begin
' fac_usrdatarecord1 OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
'-------------------------------
' fac_usrdatarecord1 CustomShowPage Event begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sUserDataRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "UserDataRecord"
UserDataRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
UserDataRecord_Show
' Cancel if no parent key.
usrtab_key = GetParam("FAC_USRTAB_KEY")
if usrtab_key = "" then
sAction = "cancel"
UserDataRecordAction(sAction)
end if
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fac_usrdatarecord1 CustomShowPage Event end
'-------------------------------
'-------------------------------
' Destroy all object variables
'-------------------------------
' fac_usrdatarecord1 Close Event begin
' fac_usrdatarecord1 Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub UserDataRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKFAC_USRDATA_KEY : pPKFAC_USRDATA_KEY = ""
Dim fldFAC_USRTAB_KEY : fldFAC_USRTAB_KEY = ""
Dim fldFAC_USRDATA_CODE : fldFAC_USRDATA_CODE = ""
Dim fldFAC_USRDATA_OMSCHR : fldFAC_USRDATA_OMSCHR = ""
Dim fldFAC_USRDATA_VOLGNR : fldFAC_USRDATA_VOLGNR = ""
Dim fldFAC_USRDATA_PRIJS : fldFAC_USRDATA_PRIJS = ""
Dim fldFAC_USRDATA_VERVALDATUM : fldFAC_USRDATA_VERVALDATUM = ""
Dim fldFAC_USRDATA_PARENTKEY : fldFAC_USRDATA_PARENTKEY = ""
'-------------------------------
'-------------------------------
' UserDataRecord Action begin
'-------------------------------
sActionFileName = "fac_usrtabrecord1.asp"
sParams = sParams & "FAC_USRTAB_KEY=" & ToURL(GetParam("Trn_FAC_USRTAB_KEY")) & "&"
sParams = sParams & "FAC_USRDATA_OMSCHR=" & ToURL(GetParam("Trn_FAC_USRDATA_OMSCHR")) & "&"
sParams = sParams & "sFAC_USRTAB_OMSCHRIJVING=" & ToURL(GetParam("Trn_sFAC_USRTAB_OMSCHRIJVING"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' UserDataRecord BeforeCancel Event begin
' UserDataRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKFAC_USRDATA_KEY = GetParam("PK_FAC_USRDATA_KEY")
if IsEmpty(pPKFAC_USRDATA_KEY) then exit sub
sWhere = "FAC_USRDATA_KEY=" & ToSQL(pPKFAC_USRDATA_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldFAC_USRTAB_KEY = GetParam("FAC_USRTAB_KEY")
fldFAC_USRDATA_CODE = GetParam("FAC_USRDATA_CODE")
fldFAC_USRDATA_OMSCHR = GetParam("FAC_USRDATA_OMSCHR")
fldFAC_USRDATA_VOLGNR = GetParam("FAC_USRDATA_VOLGNR")
fldFAC_USRDATA_PRIJS = GetParam("FAC_USRDATA_PRIJS")
fldFAC_USRDATA_VERVALDATUM = GetParam("FAC_USRDATA_VERVALDATUM")
fldFAC_USRDATA_PARENTKEY = GetParam("FAC_USRDATA_PARENTKEY")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if IsEmpty(fldFAC_USRDATA_CODE) then
sUserDataRecordErr = sUserDataRecordErr & "De waarde in veld Waarde code is verplicht.<br>"
end if
if not isNumeric(fldFAC_USRTAB_KEY) then
sUserDataRecordErr = sUserDataRecordErr & "De waarde in veld is niet correct.<br>"
end if
if not isNumeric(fldFAC_USRDATA_VOLGNR) then
sUserDataRecordErr = sUserDataRecordErr & "De waarde in veld Volgnummer is niet correct.<br>"
end if
if not isNumeric(fldFAC_USRDATA_PRIJS) then
sUserDataRecordErr = sUserDataRecordErr & "De waarde in veld Prijs is niet correct.<br>"
end if
if not isNumeric(fldFAC_USRDATA_PARENTKEY) then
sUserDataRecordErr = sUserDataRecordErr & "De waarde in veld {lblWaarde} is niet correct.<br>"
end if
'-------------------------------
' UserDataRecord Check Event begin
fldFAC_USRDATA_PRIJS = SafeToDouble(fldFAC_USRDATA_PRIJS)
cwhere = " fac_usrdata_upper = " & ToSQL(fldFAC_USRDATA_CODE, "Text") &_
" AND fac_usrtab_key = " & ToSQL(fldFAC_USRTAB_KEY, "Number") &_
" AND fac_usrdata_verwijder IS NULL " &_
" AND fac_usrdata_key <> " & ToSQL(pPKFAC_USRDATA_KEY, "Number")
a = CInt(DLookUp("FAC_USRDATA", "fac_usrdata_key", cwhere))
if a <> 0 then
sUserDataRecordErr = sUserDataRecordErr & "De waarde in veld Waarde code wordt al gebruikt.<br>"
end if
' UserDataRecord Check Event end
'-------------------------------
If len(sUserDataRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' UserDataRecord Insert Event begin
' Speciaal voor de toData
sSQL = "insert into FAC_USRDATA (" & _
"FAC_USRTAB_KEY," & _
"FAC_USRDATA_CODE," & _
"FAC_USRDATA_OMSCHR," & _
"FAC_USRDATA_VOLGNR," & _
"FAC_USRDATA_PRIJS," & _
"FAC_USRDATA_VERVALDATUM," & _
"FAC_USRDATA_PARENTKEY)" & _
" values (" & _
ToSQL(fldFAC_USRTAB_KEY, "Number") & "," & _
ToSQL(fldFAC_USRDATA_CODE, "Text") & "," & _
ToSQL(fldFAC_USRDATA_OMSCHR, "Text") & "," & _
ToSQL(fldFAC_USRDATA_VOLGNR, "Number") & "," & _
ToSQL(fldFAC_USRDATA_PRIJS, "Number") & "," & _
toDate(fldFAC_USRDATA_VERVALDATUM) & "," & _
ToSQL(fldFAC_USRDATA_PARENTKEY, "Number") & _
")"
' UserDataRecord Insert Event end
'-------------------------------
if sSQL = "" then
sSQL = "insert into FAC_USRDATA (" & _
"FAC_USRTAB_KEY," & _
"FAC_USRDATA_CODE," & _
"FAC_USRDATA_OMSCHR," & _
"FAC_USRDATA_VOLGNR," & _
"FAC_USRDATA_PRIJS," & _
"FAC_USRDATA_VERVALDATUM," & _
"FAC_USRDATA_PARENTKEY)" & _
" values (" & _
ToSQL(fldFAC_USRTAB_KEY, "Number") & "," & _
ToSQL(fldFAC_USRDATA_CODE, "Text") & "," & _
ToSQL(fldFAC_USRDATA_OMSCHR, "Text") & "," & _
ToSQL(fldFAC_USRDATA_VOLGNR, "Number") & "," & _
ToSQL(fldFAC_USRDATA_PRIJS, "Number") & "," & _
ToSQL(fldFAC_USRDATA_VERVALDATUM, "Date") & "," & _
ToSQL(fldFAC_USRDATA_PARENTKEY, "Number") & _
")"
end if
case "update"
'-------------------------------
' UserDataRecord Update Event begin
'Speciaal voor de toDate
sSQL = "update FAC_USRDATA set " & _
"FAC_USRTAB_KEY=" & ToSQL(fldFAC_USRTAB_KEY, "Number") & _
",FAC_USRDATA_CODE=" & ToSQL(fldFAC_USRDATA_CODE, "Text") & _
",FAC_USRDATA_OMSCHR=" & ToSQL(fldFAC_USRDATA_OMSCHR, "Text") & _
",FAC_USRDATA_VOLGNR=" & ToSQL(fldFAC_USRDATA_VOLGNR, "Number") & _
",FAC_USRDATA_PRIJS=" & ToSQL(fldFAC_USRDATA_PRIJS, "Number") & _
",FAC_USRDATA_VERVALDATUM=" & ToDate(fldFAC_USRDATA_VERVALDATUM) & _
",FAC_USRDATA_PARENTKEY=" & ToSQL(fldFAC_USRDATA_PARENTKEY, "Number")
sSQL = sSQL & " where " & sWhere
' UserDataRecord Update Event end
'-------------------------------
if sSQL = "" then
sSQL = "update FAC_USRDATA set " & _
"FAC_USRTAB_KEY=" & ToSQL(fldFAC_USRTAB_KEY, "Number") & _
",FAC_USRDATA_CODE=" & ToSQL(fldFAC_USRDATA_CODE, "Text") & _
",FAC_USRDATA_OMSCHR=" & ToSQL(fldFAC_USRDATA_OMSCHR, "Text") & _
",FAC_USRDATA_VOLGNR=" & ToSQL(fldFAC_USRDATA_VOLGNR, "Number") & _
",FAC_USRDATA_PRIJS=" & ToSQL(fldFAC_USRDATA_PRIJS, "Number") & _
",FAC_USRDATA_VERVALDATUM=" & ToSQL(fldFAC_USRDATA_VERVALDATUM, "Date") & _
",FAC_USRDATA_PARENTKEY=" & ToSQL(fldFAC_USRDATA_PARENTKEY, "Number")
sSQL = sSQL & " where " & sWhere
end if
case "delete"
'-------------------------------
' UserDataRecord Delete Event begin
dim tmpkey
tmpkey = "PK_"&strToTable("fac_usrdatarecord.asp")&"_KEY"
sSql = customFacDelete("fac_usrdatarecord.asp",getParam(tmpkey))
set tmpkey = Nothing
' UserDataRecord Delete Event end
'-------------------------------
if sSQL = "" then
sSQL = "delete from FAC_USRDATA where " & sWhere
end if
end select
'-------------------------------
'-------------------------------
' UserDataRecord BeforeExecute Event begin
' UserDataRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sUserDataRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sUserDataRecordErr = ProcessError
on error goto 0
if len(sUserDataRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' UserDataRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub UserDataRecord_Show()
'-------------------------------
' UserDataRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Details tabelwaarde"
Dim bPK : bPK = True
Dim sFAC_USRDATA_PARENTKEYDisplayValue: sFAC_USRDATA_PARENTKEYDisplayValue = ""
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sUserDataRecordErr = "" then
fldFAC_USRTAB_KEY = GetParam("FAC_USRTAB_KEY")
fldFAC_USRDATA_OMSCHR = GetParam("FAC_USRDATA_OMSCHR")
SetVar "Trn_FAC_USRTAB_KEY", GetParam("FAC_USRTAB_KEY")
SetVar "Trn_FAC_USRDATA_OMSCHR", GetParam("FAC_USRDATA_OMSCHR")
SetVar "Trn_sFAC_USRTAB_OMSCHRIJVING", GetParam("sFAC_USRTAB_OMSCHRIJVING")
pFAC_USRDATA_KEY = GetParam("FAC_USRDATA_KEY")
SetVar "UserDataRecordError", ""
else
fldFAC_USRTAB_KEY = GetParam("FAC_USRTAB_KEY")
fldFAC_USRDATA_CODE = GetParam("FAC_USRDATA_CODE")
fldFAC_USRDATA_OMSCHR = GetParam("FAC_USRDATA_OMSCHR")
fldFAC_USRDATA_VOLGNR = GetParam("FAC_USRDATA_VOLGNR")
fldFAC_USRDATA_PRIJS = GetParam("FAC_USRDATA_PRIJS")
fldFAC_USRDATA_VERVALDATUM = GetParam("FAC_USRDATA_VERVALDATUM")
fldFAC_USRDATA_PARENTKEY = GetParam("FAC_USRDATA_PARENTKEY")
SetVar "Trn_FAC_USRTAB_KEY", GetParam("Trn_FAC_USRTAB_KEY")
SetVar "Trn_FAC_USRDATA_OMSCHR", GetParam("Trn_FAC_USRDATA_OMSCHR")
SetVar "Trn_sFAC_USRTAB_OMSCHRIJVING", GetParam("Trn_sFAC_USRTAB_OMSCHRIJVING")
pFAC_USRDATA_KEY = GetParam("PK_FAC_USRDATA_KEY")
SetVar "sUserDataRecordErr", sUserDataRecordErr
SetVar "FormTitle", sFormTitle
Parse "UserDataRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
fldfac_usrtab_naam = GetParam("fac_usrtab_naam")
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pFAC_USRDATA_KEY) then bPK = False
sWhere = sWhere & "FAC_USRDATA_KEY=" & ToSQL(pFAC_USRDATA_KEY, "Number")
SetVar "PK_FAC_USRDATA_KEY", pFAC_USRDATA_KEY
'-------------------------------
'-------------------------------
' UserDataRecord Open Event begin
pSql = "SELECT UP.fac_usrtab_naam " & _
"FROM fac_usrtab UP " & _
", fac_usrtab UT " & _
"WHERE UP.fac_usrtab_key = UT.fac_usrtab_parentkey " & _
"AND ut.fac_usrtab_key = " & ToSQL(fldFAC_USRTAB_KEY, "Number")
openrs rs, pSql
waardeLabel = getValue(rs,"FAC_USRTAB_NAAM")
if waardeLabel = "" then waardeLabel = "Waarde referentie"
setVar "lblWaarde", FCLTLCL(waardeLabel)
koppel_waardeSql = "SELECT UD.FAC_USRDATA_KEY, UD.FAC_USRDATA_OMSCHR " & _
"FROM fac_usrdata UD " & _
", fac_usrtab UT " & _
"WHERE UD.fac_usrtab_key = UT.fac_usrtab_parentkey " & _
"AND UD.fac_usrdata_verwijder IS NULL " & _
"AND UT.fac_usrtab_key = " & ToSQL(fldFAC_USRTAB_KEY, "Number") & _
" ORDER BY 2"
' UserDataRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FAC_USRDATA where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "UserDataRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldFAC_USRDATA_KEY = GetValue(rs, "FAC_USRDATA_KEY")
fldFAC_USRTAB_KEY = GetValue(rs, "FAC_USRTAB_KEY")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sUserDataRecordErr = "" then
fldFAC_USRDATA_CODE = GetValue(rs, "FAC_USRDATA_CODE")
fldFAC_USRDATA_OMSCHR = GetValue(rs, "FAC_USRDATA_OMSCHR")
fldFAC_USRDATA_VOLGNR = GetValue(rs, "FAC_USRDATA_VOLGNR")
fldFAC_USRDATA_PRIJS = GetValue(rs, "FAC_USRDATA_PRIJS")
fldFAC_USRDATA_VERVALDATUM = GetValue(rs, "FAC_USRDATA_VERVALDATUM")
fldFAC_USRDATA_PARENTKEY = GetValue(rs, "FAC_USRDATA_PARENTKEY")
end if
SetVar "UserDataRecordInsert", ""
Parse "UserDataRecordEdit", False
'-------------------------------
' UserDataRecord ShowEdit Event begin
' UserDataRecord ShowEdit Event end
'-------------------------------
else
if sUserDataRecordErr = "" then
fldFAC_USRTAB_KEY = ToHTML(GetParam("FAC_USRTAB_KEY"))
fldFAC_USRDATA_OMSCHR = ToHTML(GetParam("FAC_USRDATA_OMSCHR"))
end if
SetVar "UserDataRecordEdit", ""
Parse "UserDataRecordInsert", False
'-------------------------------
' UserDataRecord ShowInsert Event begin
' UserDataRecord ShowInsert Event end
'-------------------------------
end if
Parse "UserDataRecordCancel", false
if sUserDataRecordErr = "" then
'-------------------------------
' UserDataRecord Show Event begin
if fldFAC_USRDATA_VERVALDATUM <> "" then
datum = CDate(fldFAC_USRDATA_VERVALDATUM)
fldFAC_USRDATA_VERVALDATUM = Day(datum)&"-"&Month(datum)&"-"&Year(datum)
end if
if getParam("fac_usrtab_key") <> "" then
fldFAC_USRTAB_KEY = getParam("fac_usrtab_key")
end if
pSql = "SELECT UT.fac_usrtab_naam " & _
"FROM fac_usrtab UT " & _
"WHERE UT.fac_usrtab_key = " & ToSQL(fldFAC_USRTAB_KEY, "Number")
openrs rs, pSql
fldfac_usrtab_naam = getValue(rs,"FAC_USRTAB_NAAM")
' UserDataRecord Show Event end
'-------------------------------
end if
'-------------------------------
' Show form field
'-------------------------------
SetVar "FAC_USRDATA_KEY", ToHTML(fldFAC_USRDATA_KEY)
SetVar "FAC_USRTAB_KEY", ToHTML(fldFAC_USRTAB_KEY)
SetVar "fac_usrtab_naam", ToHTML(fldfac_usrtab_naam)
SetVar "FAC_USRDATA_CODE", ToHTML(fldFAC_USRDATA_CODE)
SetVar "FAC_USRDATA_OMSCHR", ToHTML(fldFAC_USRDATA_OMSCHR)
SetVar "FAC_USRDATA_VOLGNR", ToHTML(fldFAC_USRDATA_VOLGNR)
SetVar "FAC_USRDATA_PRIJS", ToHTML(fldFAC_USRDATA_PRIJS)
SetVar "FAC_USRDATA_VERVALDATUM", ToHTML(fldFAC_USRDATA_VERVALDATUM)
SetVar "UserDataRecordLBFAC_USRDATA_PARENTKEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sFAC_USRDATA_PARENTKEYDisplayValue
Parse "UserDataRecordLBFAC_USRDATA_PARENTKEY", True
openrs rsFAC_USRDATA_PARENTKEY, ""&koppel_waardeSql&""
while not rsFAC_USRDATA_PARENTKEY.EOF
SetVar "ID", GetValue(rsFAC_USRDATA_PARENTKEY, 0) : SetVar "Value", GetValue(rsFAC_USRDATA_PARENTKEY, 1)
if cstr(GetValue(rsFAC_USRDATA_PARENTKEY, 0)) = cstr(fldFAC_USRDATA_PARENTKEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "UserDataRecordLBFAC_USRDATA_PARENTKEY", True
rsFAC_USRDATA_PARENTKEY.MoveNext
wend
set rsFAC_USRDATA_PARENTKEY = nothing
Parse "FormUserDataRecord", False
'-------------------------------
' UserDataRecord Close Event begin
' UserDataRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' UserDataRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,119 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Details waarde</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormUserDataRecordHeader-->
<!--EndFormUserDataRecordHeader-->
<!--BeginFormUserDataRecord-->
<form method="POST" action="{FileName}" name="UserDataRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginUserDataRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sUserDataRecordErr}</font></td>
</tr>
<!--EndUserDataRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{FAC_USRDATA_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Tabelnaam</font></td>
<td class="DataTD"><font class="DataFONT">{fac_usrtab_naam}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Waarde code</font></td>
<td class="DataTD"><input type="text" name="FAC_USRDATA_CODE" maxlength="40" value="{FAC_USRDATA_CODE}" size="40"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Waarde omschrijving</font></td>
<td class="DataTD"><input type="text" name="FAC_USRDATA_OMSCHR" maxlength="60" value="{FAC_USRDATA_OMSCHR}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Volgnummer</font></td>
<td class="DataTD"><input type="text" name="FAC_USRDATA_VOLGNR" maxlength="10" value="{FAC_USRDATA_VOLGNR}" size="10"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Prijs</font></td>
<td class="DataTD"><input type="text" name="FAC_USRDATA_PRIJS" maxlength="10" value="{FAC_USRDATA_PRIJS}" size="10"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Vervaldatum</font></td>
<td class="DataTD"><input type="text" name="FAC_USRDATA_VERVALDATUM" maxlength="10" value="{FAC_USRDATA_VERVALDATUM}" size="10"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">{lblWaarde}</font></td>
<td class="DataTD"><select name="FAC_USRDATA_PARENTKEY"><!--BeginUserDataRecordLBFAC_USRDATA_PARENTKEY--><option value="{ID}" {Selected}>{Value}</option><!--EndUserDataRecordLBFAC_USRDATA_PARENTKEY--></select></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginUserDataRecordInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.UserDataRecord.FormAction.value = 'insert';">
<!--EndUserDataRecordInsert-->
<!--BeginUserDataRecordEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginUserDataRecordUpdate-->
<input type="submit" value="Bewaren" onclick="document.UserDataRecord.FormAction.value = 'update';"/>
<!--EndUserDataRecordUpdate-->
<!--BeginUserDataRecordDelete-->
<input type="submit" value="Verwijderen" onclick="document.UserDataRecord.FormAction.value = 'delete';"/>
<!--EndUserDataRecordDelete-->
<!--EndUserDataRecordEdit-->
<!--BeginUserDataRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.UserDataRecord.FormAction.value = 'cancel';"/>
<!--EndUserDataRecordCancel-->
<input type="hidden" name="FormName" value="UserDataRecord"/>
<input type="hidden" name="Trn_FAC_USRTAB_KEY" value="{Trn_FAC_USRTAB_KEY}"/>
<input type="hidden" name="Trn_FAC_USRDATA_OMSCHR" value="{Trn_FAC_USRDATA_OMSCHR}"/>
<input type="hidden" name="Trn_sFAC_USRTAB_OMSCHRIJVING" value="{Trn_sFAC_USRTAB_OMSCHRIJVING}"/>
<input type="hidden" name="PK_FAC_USRDATA_KEY" value="{PK_FAC_USRDATA_KEY}"/>
<input type="hidden" name="FAC_USRTAB_KEY" value="{FAC_USRTAB_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormUserDataRecord-->
<!--BeginFormUserDataRecordFooter-->
<!--EndFormUserDataRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,446 +0,0 @@
<%
'
' Filename: fin_btwtabelwaardegrid.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fin_btwtabelwaardegrid CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fin_btwtabelwaardegrid CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fin_btwtabelwaardegrid.asp"
sTemplateFileName = "fin_btwtabelwaardegrid.html"
'===============================
'===============================
' fin_btwtabelwaardegrid PageSecurity begin
' fin_btwtabelwaardegrid PageSecurity end
'===============================
'===============================
' fin_btwtabelwaardegrid Open Event begin
' fin_btwtabelwaardegrid Open Event end
'===============================
'===============================
' fin_btwtabelwaardegrid OpenAnyPage Event begin
' fin_btwtabelwaardegrid OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fin_btwtabelwaardegrid Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
BTWTabelwaardeSearch_Show
BTWTabelwaardegrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fin_btwtabelwaardegrid Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fin_btwtabelwaardegrid Close Event begin
' fin_btwtabelwaardegrid Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub BTWTabelwaardegrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "BTW Tabelwaardes"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 25
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
Dim sActionFileName : sActionFileName = "fin_btwtabelwaarderecord.asp"
SetVar "TransitParams", "FIN_BTWTABEL_KEY=" & ToURL(GetParam("FIN_BTWTABEL_KEY")) & "&"
SetVar "FormParams", "FIN_BTWTABEL_KEY=" & ToURL(GetParam("FIN_BTWTABEL_KEY")) & "&"
'-------------------------------
' Build WHERE statement
'-------------------------------
pFIN_BTWTABEL_KEY = GetParam("FIN_BTWTABEL_KEY")
if IsNumeric(pFIN_BTWTABEL_KEY) and not isEmpty(pFIN_BTWTABEL_KEY) then pFIN_BTWTABEL_KEY = ToSQL(pFIN_BTWTABEL_KEY, "Number") else pFIN_BTWTABEL_KEY = Empty
if not isEmpty(pFIN_BTWTABEL_KEY) then
HasParam = true
sWhere = sWhere & "F.FIN_BTWTABEL_KEY=" & pFIN_BTWTABEL_KEY
end if
if HasParam then
sWhere = " AND (FIN_BTWTABELWAARDE_VERWIJDER IS NULL) AND (" & sWhere & ")"
else
sWhere = " AND FIN_BTWTABELWAARDE_VERWIJDER IS NULL"
end if
'-------------------------------
' Build ORDER BY statement
'-------------------------------
sOrder = " order by F.FIN_BTWTABELWAARDE_PERC Asc"
iSort = GetParam("FormBTWTabelwaardegrid_Sorting")
iSorted = GetParam("FormBTWTabelwaardegrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormBTWTabelwaardegrid_Sorting=" & iSort & "&FormBTWTabelwaardegrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormBTWTabelwaardegrid_Sorting=" & iSort & "&FormBTWTabelwaardegrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by F.FIN_BTWTABELWAARDE_KEY" & sDirection
if iSort = 2 then sOrder = " order by F1.FIN_BTWTABEL_OMSCHRIJVING" & sDirection
if iSort = 3 then sOrder = " order by F.FIN_BTWTABELWAARDE_CODE" & sDirection
if iSort = 4 then sOrder = " order by F.FIN_BTWTABELWAARDE_OMS" & sDirection
if iSort = 5 then sOrder = " order by F.FIN_BTWTABELWAARDE_PERC" & sDirection
if iSort = 6 then sOrder = " order by F.FIN_BTWTABELWAARDE_VERLEGD" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select F.FIN_BTWTABELWAARDE_CODE as F_FIN_BTWTABELWAARDE_CODE, " & _
"F.FIN_BTWTABELWAARDE_KEY as F_FIN_BTWTABELWAARDE_KEY, " & _
"F.FIN_BTWTABELWAARDE_OMS as F_FIN_BTWTABELWAARDE_OMS, " & _
"F.FIN_BTWTABELWAARDE_PERC as F_FIN_BTWTABELWAARDE_PERC, " & _
"F.FIN_BTWTABELWAARDE_VERLEGD as F_FIN_BTWTABELWAARDE_VERLEGD, " & _
"F.FIN_BTWTABEL_KEY as F_FIN_BTWTABEL_KEY, " & _
"F1.FIN_BTWTABEL_KEY as F1_FIN_BTWTABEL_KEY, " & _
"F1.FIN_BTWTABEL_OMSCHRIJVING as F1_FIN_BTWTABEL_OMSCHRIJVING " & _
" from FIN_BTWTABELWAARDE F, FIN_BTWTABEL F1" & _
" where F1.FIN_BTWTABEL_KEY=F.FIN_BTWTABEL_KEY "
'-------------------------------
'-------------------------------
' BTWTabelwaardegrid Open Event begin
' BTWTabelwaardegrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the link to the record page
'-------------------------------
SetVar "FormAction", sActionFileName
'-------------------------------
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListBTWTabelwaardegrid", ""
Parse "BTWTabelwaardegridNoRecords", False
SetVar "BTWTabelwaardegridNavigator", ""
Parse "FormBTWTabelwaardegrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Prepare the lists of values
'-------------------------------
aFIN_BTWTABELWAARDE_VERLEGD = Split(""&FCLTLCL(";Nee;1;Ja")&"", ";")
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 25
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormBTWTabelwaardegrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "BTWTabelwaardegridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldFIN_BTWTABEL_KEY = GetValue(rs, "F1_FIN_BTWTABEL_OMSCHRIJVING")
fldFIN_BTWTABELWAARDE_CODE_URLLink = "fin_btwtabelwaarderecord.asp"
fldFIN_BTWTABELWAARDE_CODE_FIN_BTWTABELWAARDE_KEY = GetValue(rs, "F_FIN_BTWTABELWAARDE_KEY")
fldFIN_BTWTABELWAARDE_CODE = GetValue(rs, "F_FIN_BTWTABELWAARDE_CODE")
fldFIN_BTWTABELWAARDE_KEY = GetValue(rs, "F_FIN_BTWTABELWAARDE_KEY")
fldFIN_BTWTABELWAARDE_OMS_URLLink = "fin_btwtabelwaarderecord.asp"
fldFIN_BTWTABELWAARDE_OMS_FIN_BTWTABELWAARDE_KEY = GetValue(rs, "F_FIN_BTWTABELWAARDE_KEY")
fldFIN_BTWTABELWAARDE_OMS = GetValue(rs, "F_FIN_BTWTABELWAARDE_OMS")
fldFIN_BTWTABELWAARDE_PERC = GetValue(rs, "F_FIN_BTWTABELWAARDE_PERC")
fldFIN_BTWTABELWAARDE_VERLEGD = GetValue(rs, "F_FIN_BTWTABELWAARDE_VERLEGD")
'-------------------------------
' BTWTabelwaardegrid Show begin
'-------------------------------
'-------------------------------
' BTWTabelwaardegrid Show Event begin
' BTWTabelwaardegrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "FIN_BTWTABELWAARDE_KEY", ToHTML(fldFIN_BTWTABELWAARDE_KEY)
SetVar "FIN_BTWTABEL_KEY", ToHTML(fldFIN_BTWTABEL_KEY)
SetVar "FIN_BTWTABELWAARDE_CODE", ToHTML(fldFIN_BTWTABELWAARDE_CODE)
SetVar "FIN_BTWTABELWAARDE_CODE_URLLink", fldFIN_BTWTABELWAARDE_CODE_URLLink
SetVar "PrmFIN_BTWTABELWAARDE_CODE_FIN_BTWTABELWAARDE_KEY", ToURL(fldFIN_BTWTABELWAARDE_CODE_FIN_BTWTABELWAARDE_KEY)
SetVar "FIN_BTWTABELWAARDE_OMS", ToHTML(fldFIN_BTWTABELWAARDE_OMS)
SetVar "FIN_BTWTABELWAARDE_OMS_URLLink", fldFIN_BTWTABELWAARDE_OMS_URLLink
SetVar "PrmFIN_BTWTABELWAARDE_OMS_FIN_BTWTABELWAARDE_KEY", ToURL(fldFIN_BTWTABELWAARDE_OMS_FIN_BTWTABELWAARDE_KEY)
SetVar "FIN_BTWTABELWAARDE_PERC", fldFIN_BTWTABELWAARDE_PERC
fldFIN_BTWTABELWAARDE_VERLEGD = getValFromLOV(fldFIN_BTWTABELWAARDE_VERLEGD, aFIN_BTWTABELWAARDE_VERLEGD)
SetVar "FIN_BTWTABELWAARDE_VERLEGD", ToHTML(fldFIN_BTWTABELWAARDE_VERLEGD)
Parse "DListBTWTabelwaardegrid", True
'-------------------------------
' BTWTabelwaardegrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' BTWTabelwaardegrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "BTWTabelwaardegridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "BTWTabelwaardegridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "BTWTabelwaardegridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "BTWTabelwaardegridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "BTWTabelwaardegridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "BTWTabelwaardegridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "BTWTabelwaardegridCurrentPage", iPage
Parse "BTWTabelwaardegridNavigator", False
end if
'-------------------------------
' BTWTabelwaardegrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "BTWTabelwaardegridNoRecords", ""
Parse "FormBTWTabelwaardegrid", False
'-------------------------------
' BTWTabelwaardegrid Close Event begin
' BTWTabelwaardegrid Close Event end
'-------------------------------
End Sub
'===============================
'===============================
' Display Search Form
'-------------------------------
Sub BTWTabelwaardeSearch_Show()
Dim sFormTitle: sFormTitle = ""
Dim sActionFileName: sActionFileName = "fin_btwtabelwaardegrid.asp"
Dim sFIN_BTWTABEL_KEYDisplayValue: sFIN_BTWTABEL_KEYDisplayValue = ""
'-------------------------------
' BTWTabelwaardeSearch Open Event begin
' BTWTabelwaardeSearch Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
SetVar "ActionPage", sActionFileName
'-------------------------------
' Set variables with search parameters
'-------------------------------
fldFIN_BTWTABEL_KEY = GetParam("FIN_BTWTABEL_KEY")
'-------------------------------
' BTWTabelwaardeSearch Show begin
'-------------------------------
'-------------------------------
' BTWTabelwaardeSearch Show Event begin
' BTWTabelwaardeSearch Show Event end
'-------------------------------
SetVar "BTWTabelwaardeSearchLBFIN_BTWTABEL_KEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sFIN_BTWTABEL_KEYDisplayValue
Parse "BTWTabelwaardeSearchLBFIN_BTWTABEL_KEY", True
openrs rsFIN_BTWTABEL_KEY, "select FIN_BTWTABEL_KEY, FIN_BTWTABEL_OMSCHRIJVING from FIN_BTWTABEL order by 2"
while not rsFIN_BTWTABEL_KEY.EOF
SetVar "ID", GetValue(rsFIN_BTWTABEL_KEY, 0) : SetVar "Value", GetValue(rsFIN_BTWTABEL_KEY, 1)
if cstr(GetValue(rsFIN_BTWTABEL_KEY, 0)) = cstr(fldFIN_BTWTABEL_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "BTWTabelwaardeSearchLBFIN_BTWTABEL_KEY", True
rsFIN_BTWTABEL_KEY.MoveNext
wend
set rsFIN_BTWTABEL_KEY = nothing
'-------------------------------
' BTWTabelwaardeSearch Show end
'-------------------------------
'-------------------------------
' BTWTabelwaardeSearch Close Event begin
' BTWTabelwaardeSearch Close Event end
'-------------------------------
Parse "FormBTWTabelwaardeSearch", False
End Sub
'===============================
%>

View File

@@ -1,93 +0,0 @@
<html>
<head>
<title>BTW tabel waardes</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormBTWTabelwaardeSearchHeader-->
<!--EndFormBTWTabelwaardeSearchHeader-->
<!--BeginFormBTWTabelwaardeSearch--><form method="POST" action="{ActionPage}" name="BTWTabelwaardeSearch">
<input type="hidden" name="FormName" value="BTWTabelwaardeSearch"><input type="hidden" name="FormAction" value="search">
<table class="FormTABLE">
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">BTW Tabel</font></td>
<td class="DataTD"><select name="FIN_BTWTABEL_KEY"><!--BeginBTWTabelwaardeSearchLBFIN_BTWTABEL_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndBTWTabelwaardeSearchLBFIN_BTWTABEL_KEY--></select></td>
<td><input type="submit" value="Zoeken"></td>
</tr>
</table>
</form><!--EndFormBTWTabelwaardeSearch-->
<!--BeginFormBTWTabelwaardeSearchFooter-->
<!--EndFormBTWTabelwaardeSearchFooter-->
</td>
</tr>
</table>
<table>
<tr>
<td valign="top">
<!--BeginFormBTWTabelwaardegridHeader-->
<!--EndFormBTWTabelwaardegridHeader-->
<!--BeginFormBTWTabelwaardegrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="6"><a name="BTWTabelwaardegrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormBTWTabelwaardegrid_Sorting=1&FormBTWTabelwaardegrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Key</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormBTWTabelwaardegrid_Sorting=2&FormBTWTabelwaardegrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">BTW tabel</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormBTWTabelwaardegrid_Sorting=3&FormBTWTabelwaardegrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Code</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormBTWTabelwaardegrid_Sorting=4&FormBTWTabelwaardegrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Omschrijving</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormBTWTabelwaardegrid_Sorting=5&FormBTWTabelwaardegrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Percentage</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormBTWTabelwaardegrid_Sorting=6&FormBTWTabelwaardegrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Verlegd</font></a></td>
</tr>
<!--BeginDListBTWTabelwaardegrid-->
<tr>
<td class="DataTD"><font class="DataFONT">{FIN_BTWTABELWAARDE_KEY}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{FIN_BTWTABEL_KEY}&nbsp;</font></td>
<td class="DataTD"><a href="{FIN_BTWTABELWAARDE_CODE_URLLink}?FIN_BTWTABELWAARDE_KEY={PrmFIN_BTWTABELWAARDE_CODE_FIN_BTWTABELWAARDE_KEY}&{TransitParams}"><font class="DataFONT">{FIN_BTWTABELWAARDE_CODE}</font></a>&nbsp;</td>
<td class="DataTD"><a href="{FIN_BTWTABELWAARDE_OMS_URLLink}?FIN_BTWTABELWAARDE_KEY={PrmFIN_BTWTABELWAARDE_OMS_FIN_BTWTABELWAARDE_KEY}&{TransitParams}"><font class="DataFONT">{FIN_BTWTABELWAARDE_OMS}</font></a>&nbsp;</td>
<td class="DataTD"><font class="DataFONT">{FIN_BTWTABELWAARDE_PERC}&nbsp;</font></td>
<td class="DataTD"><font class="DataFONT">{FIN_BTWTABELWAARDE_VERLEGD}&nbsp;</font></td>
</tr>
<!--EndDListBTWTabelwaardegrid-->
<!--BeginBTWTabelwaardegridNoRecords-->
<tr><td colspan="6" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndBTWTabelwaardegridNoRecords-->
<tr>
<td colspan="6" class="ColumnTD">
<font class="ColumnFONT">
<a href="{FormAction}?{TransitParams}"><font class="ColumnFONT">Toevoegen</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<!--BeginBTWTabelwaardegridNavigator-->
<a href{BTWTabelwaardegridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormBTWTabelwaardegrid_Page=1#BTWTabelwaardegrid"><font class="ColumnFONT"><<</font></a>
<a href{BTWTabelwaardegridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormBTWTabelwaardegrid_Page={PrevPage}#BTWTabelwaardegrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginBTWTabelwaardegridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormBTWTabelwaardegrid_Page={NavigatorPageNumber}#BTWTabelwaardegrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndBTWTabelwaardegridNavigatorPages-->van {BTWTabelwaardegridPageCount} ]
<a href{BTWTabelwaardegridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormBTWTabelwaardegrid_Page={NextPage}#BTWTabelwaardegrid"><font class="ColumnFONT">></font></a>
<a href{BTWTabelwaardegridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormBTWTabelwaardegrid_Page=last#BTWTabelwaardegrid"><font class="ColumnFONT">>></font></a>
<!--EndBTWTabelwaardegridNavigator-->
</font>
</td>
</tr>
</table>
<!--EndFormBTWTabelwaardegrid-->
<!--BeginFormBTWTabelwaardegridFooter-->
<!--EndFormBTWTabelwaardegridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,405 +0,0 @@
<%
'
' Filename: fin_btwtabelwaarderecord.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' fin_btwtabelwaarderecord CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' fin_btwtabelwaarderecord CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "fin_btwtabelwaarderecord.asp"
sTemplateFileName = "fin_btwtabelwaarderecord.html"
'===============================
'===============================
' fin_btwtabelwaarderecord PageSecurity begin
' fin_btwtabelwaarderecord PageSecurity end
'===============================
'===============================
' fin_btwtabelwaarderecord Open Event begin
' fin_btwtabelwaarderecord Open Event end
'===============================
'===============================
' fin_btwtabelwaarderecord OpenAnyPage Event begin
' fin_btwtabelwaarderecord OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' fin_btwtabelwaarderecord Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sBTWTabelWaardeRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "BTWTabelWaardeRecord"
BTWTabelWaardeRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
BTWTabelWaardeRecord_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' fin_btwtabelwaarderecord Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' fin_btwtabelwaarderecord Close Event begin
' fin_btwtabelwaarderecord Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub BTWTabelWaardeRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sParams : sParams = "?"
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKFIN_BTWTABELWAARDE_KEY : pPKFIN_BTWTABELWAARDE_KEY = ""
Dim fldFIN_BTWTABEL_KEY : fldFIN_BTWTABEL_KEY = ""
Dim fldFIN_BTWTABELWAARDE_CODE : fldFIN_BTWTABELWAARDE_CODE = ""
Dim fldFIN_BTWTABELWAARDE_OMS : fldFIN_BTWTABELWAARDE_OMS = ""
Dim fldFIN_BTWTABELWAARDE_PERC : fldFIN_BTWTABELWAARDE_PERC = ""
Dim fldFIN_BTWTABELWAARDE_VERLEGD : fldFIN_BTWTABELWAARDE_VERLEGD = ""
'-------------------------------
'-------------------------------
' BTWTabelWaardeRecord Action begin
'-------------------------------
sActionFileName = "fin_btwtabelwaardegrid.asp"
sParams = sParams & "FIN_BTWTABEL_KEY=" & ToURL(GetParam("Trn_FIN_BTWTABEL_KEY"))
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' BTWTabelWaardeRecord BeforeCancel Event begin
' BTWTabelWaardeRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKFIN_BTWTABELWAARDE_KEY = GetParam("PK_FIN_BTWTABELWAARDE_KEY")
if IsEmpty(pPKFIN_BTWTABELWAARDE_KEY) then exit sub
sWhere = "FIN_BTWTABELWAARDE_KEY=" & ToSQL(pPKFIN_BTWTABELWAARDE_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldFIN_BTWTABELWAARDE_KEY = GetParam("Rqd_FIN_BTWTABELWAARDE_KEY")
fldFIN_BTWTABEL_KEY = GetParam("FIN_BTWTABEL_KEY")
fldFIN_BTWTABELWAARDE_CODE = GetParam("FIN_BTWTABELWAARDE_CODE")
fldFIN_BTWTABELWAARDE_OMS = GetParam("FIN_BTWTABELWAARDE_OMS")
fldFIN_BTWTABELWAARDE_PERC = GetParam("FIN_BTWTABELWAARDE_PERC")
fldFIN_BTWTABELWAARDE_VERLEGD = getCheckBoxValue(GetParam("FIN_BTWTABELWAARDE_VERLEGD"), "1", "0", "Number")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if not isNumeric(fldFIN_BTWTABEL_KEY) then
sBTWTabelWaardeRecordErr = sBTWTabelWaardeRecordErr & "De waarde in veld BTW Tabel is niet correct.<br>"
end if
if not isNumeric(fldFIN_BTWTABELWAARDE_PERC) then
sBTWTabelWaardeRecordErr = sBTWTabelWaardeRecordErr & "De waarde in veld Percentage is niet correct.<br>"
end if
'-------------------------------
' BTWTabelWaardeRecord Check Event begin
cn.execute "alter session set NLS_DATE_FORMAT='DD-MM-YYYY'"
fldFIN_BTWTABELWAARDE_PERC = SafeToDouble(fldFIN_BTWTABELWAARDE_PERC)
' BTWTabelWaardeRecord Check Event end
'-------------------------------
If len(sBTWTabelWaardeRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' BTWTabelWaardeRecord Insert Event begin
' BTWTabelWaardeRecord Insert Event end
'-------------------------------
sSQL = "insert into FIN_BTWTABELWAARDE (" & _
"FIN_BTWTABELWAARDE_KEY," & _
"FIN_BTWTABEL_KEY," & _
"FIN_BTWTABELWAARDE_CODE," & _
"FIN_BTWTABELWAARDE_OMS," & _
"FIN_BTWTABELWAARDE_PERC," & _
"FIN_BTWTABELWAARDE_VERLEGD)" & _
" values (" & _
ToSQL(fldFIN_BTWTABELWAARDE_KEY, "Number") & "," & _
ToSQL(fldFIN_BTWTABEL_KEY, "Number") & "," & _
ToSQL(fldFIN_BTWTABELWAARDE_CODE, "Text") & "," & _
ToSQL(fldFIN_BTWTABELWAARDE_OMS, "Text") & "," & _
ToSQL(fldFIN_BTWTABELWAARDE_PERC, "Number") & "," & _
fldFIN_BTWTABELWAARDE_VERLEGD & _
")"
case "update"
'-------------------------------
' BTWTabelWaardeRecord Update Event begin
' BTWTabelWaardeRecord Update Event end
'-------------------------------
sSQL = "update FIN_BTWTABELWAARDE set " & _
"FIN_BTWTABEL_KEY=" & ToSQL(fldFIN_BTWTABEL_KEY, "Number") & _
",FIN_BTWTABELWAARDE_CODE=" & ToSQL(fldFIN_BTWTABELWAARDE_CODE, "Text") & _
",FIN_BTWTABELWAARDE_OMS=" & ToSQL(fldFIN_BTWTABELWAARDE_OMS, "Text") & _
",FIN_BTWTABELWAARDE_PERC=" & ToSQL(fldFIN_BTWTABELWAARDE_PERC, "Number") & _
",FIN_BTWTABELWAARDE_VERLEGD=" & fldFIN_BTWTABELWAARDE_VERLEGD
sSQL = sSQL & " where " & sWhere
case "delete"
'-------------------------------
' BTWTabelWaardeRecord Delete Event begin
dim tmpkey
tmpkey = "PK_"&strToTable(sActionFileName)&"_KEY"
sSql = customFacDelete(sActionFileName,getParam(tmpkey))
set tmpkey = Nothing
' BTWTabelWaardeRecord Delete Event end
'-------------------------------
if sSQL = "" then
sSQL = "delete from FIN_BTWTABELWAARDE where " & sWhere
end if
end select
'-------------------------------
'-------------------------------
' BTWTabelWaardeRecord BeforeExecute Event begin
' BTWTabelWaardeRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sBTWTabelWaardeRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sBTWTabelWaardeRecordErr = ProcessError
on error goto 0
if len(sBTWTabelWaardeRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName & sParams
'-------------------------------
' BTWTabelWaardeRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub BTWTabelWaardeRecord_Show()
'-------------------------------
' BTWTabelWaardeRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Details BTW waarde"
Dim bPK : bPK = True
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sBTWTabelWaardeRecordErr = "" then
fldFIN_BTWTABELWAARDE_KEY = GetParam("FIN_BTWTABELWAARDE_KEY")
fldFIN_BTWTABEL_KEY = GetParam("FIN_BTWTABEL_KEY")
SetVar "Trn_FIN_BTWTABEL_KEY", GetParam("FIN_BTWTABEL_KEY")
SetVar "Rqd_FIN_BTWTABELWAARDE_KEY", GetParam("FIN_BTWTABELWAARDE_KEY")
pFIN_BTWTABELWAARDE_KEY = GetParam("FIN_BTWTABELWAARDE_KEY")
SetVar "BTWTabelWaardeRecordError", ""
else
fldFIN_BTWTABEL_KEY = GetParam("FIN_BTWTABEL_KEY")
fldFIN_BTWTABELWAARDE_CODE = GetParam("FIN_BTWTABELWAARDE_CODE")
fldFIN_BTWTABELWAARDE_OMS = GetParam("FIN_BTWTABELWAARDE_OMS")
fldFIN_BTWTABELWAARDE_PERC = GetParam("FIN_BTWTABELWAARDE_PERC")
fldFIN_BTWTABELWAARDE_VERLEGD = getCheckBoxValue(GetParam("FIN_BTWTABELWAARDE_VERLEGD"), "1", "0", "Number")
SetVar "Rqd_FIN_BTWTABELWAARDE_KEY", GetParam("Rqd_FIN_BTWTABELWAARDE_KEY")
SetVar "Trn_FIN_BTWTABEL_KEY", GetParam("Trn_FIN_BTWTABEL_KEY")
pFIN_BTWTABELWAARDE_KEY = GetParam("PK_FIN_BTWTABELWAARDE_KEY")
SetVar "sBTWTabelWaardeRecordErr", sBTWTabelWaardeRecordErr
SetVar "FormTitle", sFormTitle
Parse "BTWTabelWaardeRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pFIN_BTWTABELWAARDE_KEY) then bPK = False
sWhere = sWhere & "FIN_BTWTABELWAARDE_KEY=" & ToSQL(pFIN_BTWTABELWAARDE_KEY, "Number")
SetVar "PK_FIN_BTWTABELWAARDE_KEY", pFIN_BTWTABELWAARDE_KEY
'-------------------------------
'-------------------------------
' BTWTabelWaardeRecord Open Event begin
' BTWTabelWaardeRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from FIN_BTWTABELWAARDE where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "BTWTabelWaardeRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldFIN_BTWTABELWAARDE_KEY = GetValue(rs, "FIN_BTWTABELWAARDE_KEY")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sBTWTabelWaardeRecordErr = "" then
fldFIN_BTWTABEL_KEY = GetValue(rs, "FIN_BTWTABEL_KEY")
fldFIN_BTWTABELWAARDE_CODE = GetValue(rs, "FIN_BTWTABELWAARDE_CODE")
fldFIN_BTWTABELWAARDE_OMS = GetValue(rs, "FIN_BTWTABELWAARDE_OMS")
fldFIN_BTWTABELWAARDE_PERC = GetValue(rs, "FIN_BTWTABELWAARDE_PERC")
fldFIN_BTWTABELWAARDE_VERLEGD = GetValue(rs, "FIN_BTWTABELWAARDE_VERLEGD")
end if
SetVar "BTWTabelWaardeRecordInsert", ""
Parse "BTWTabelWaardeRecordEdit", False
'-------------------------------
' BTWTabelWaardeRecord ShowEdit Event begin
' BTWTabelWaardeRecord ShowEdit Event end
'-------------------------------
else
if sBTWTabelWaardeRecordErr = "" then
fldFIN_BTWTABELWAARDE_KEY = ToHTML(GetParam("FIN_BTWTABELWAARDE_KEY"))
fldFIN_BTWTABEL_KEY = ToHTML(GetParam("FIN_BTWTABEL_KEY"))
fldFIN_BTWTABELWAARDE_PERC= "0"
end if
SetVar "BTWTabelWaardeRecordEdit", ""
Parse "BTWTabelWaardeRecordInsert", False
'-------------------------------
' BTWTabelWaardeRecord ShowInsert Event begin
' BTWTabelWaardeRecord ShowInsert Event end
'-------------------------------
end if
Parse "BTWTabelWaardeRecordCancel", false
'-------------------------------
' BTWTabelWaardeRecord Show Event begin
' BTWTabelWaardeRecord Show Event end
'-------------------------------
'-------------------------------
' Show form field
'-------------------------------
SetVar "FIN_BTWTABELWAARDE_KEY", ToHTML(fldFIN_BTWTABELWAARDE_KEY)
SetVar "BTWTabelWaardeRecordLBFIN_BTWTABEL_KEY", ""
openrs rsFIN_BTWTABEL_KEY, "select FIN_BTWTABEL_KEY, FIN_BTWTABEL_OMSCHRIJVING from FIN_BTWTABEL order by 2"
while not rsFIN_BTWTABEL_KEY.EOF
SetVar "ID", GetValue(rsFIN_BTWTABEL_KEY, 0) : SetVar "Value", GetValue(rsFIN_BTWTABEL_KEY, 1)
if cstr(GetValue(rsFIN_BTWTABEL_KEY, 0)) = cstr(fldFIN_BTWTABEL_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "BTWTabelWaardeRecordLBFIN_BTWTABEL_KEY", True
rsFIN_BTWTABEL_KEY.MoveNext
wend
set rsFIN_BTWTABEL_KEY = nothing
SetVar "FIN_BTWTABELWAARDE_CODE", ToHTML(fldFIN_BTWTABELWAARDE_CODE)
SetVar "FIN_BTWTABELWAARDE_OMS", ToHTML(fldFIN_BTWTABELWAARDE_OMS)
SetVar "FIN_BTWTABELWAARDE_PERC", ToHTML(fldFIN_BTWTABELWAARDE_PERC)
if (LCase(fldFIN_BTWTABELWAARDE_VERLEGD) = LCase("1")) then
SetVar "FIN_BTWTABELWAARDE_VERLEGD_CHECKED", "CHECKED"
else
SetVar "FIN_BTWTABELWAARDE_VERLEGD_CHECKED", ""
end if
Parse "FormBTWTabelWaardeRecord", False
'-------------------------------
' BTWTabelWaardeRecord Close Event begin
' BTWTabelWaardeRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' BTWTabelWaardeRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,107 +0,0 @@
<html>
<head>
<title>BTW Tabel waardes</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormBTWTabelWaardeRecordHeader-->
<!--EndFormBTWTabelWaardeRecordHeader-->
<!--BeginFormBTWTabelWaardeRecord-->
<form method="POST" action="{FileName}" name="BTWTabelWaardeRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginBTWTabelWaardeRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sBTWTabelWaardeRecordErr}</font></td>
</tr>
<!--EndBTWTabelWaardeRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{FIN_BTWTABELWAARDE_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">BTW Tabel</font></td>
<td class="DataTD"><select name="FIN_BTWTABEL_KEY"><!--BeginBTWTabelWaardeRecordLBFIN_BTWTABEL_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndBTWTabelWaardeRecordLBFIN_BTWTABEL_KEY--></select></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Code</font></td>
<td class="DataTD"><input type="text" name="FIN_BTWTABELWAARDE_CODE" maxlength="10" value="{FIN_BTWTABELWAARDE_CODE}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Omschrijving</font></td>
<td class="DataTD"><input type="text" name="FIN_BTWTABELWAARDE_OMS" maxlength="30" value="{FIN_BTWTABELWAARDE_OMS}" size="60"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Percentage</font></td>
<td class="DataTD"><input type="text" name="FIN_BTWTABELWAARDE_PERC" maxlength="6" value="{FIN_BTWTABELWAARDE_PERC}" size="6"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Verlegd</font></td>
<td class="DataTD"><input {FIN_BTWTABELWAARDE_VERLEGD_CHECKED} type="checkbox" name="FIN_BTWTABELWAARDE_VERLEGD"></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginBTWTabelWaardeRecordInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.BTWTabelWaardeRecord.FormAction.value = 'insert';">
<!--EndBTWTabelWaardeRecordInsert-->
<!--BeginBTWTabelWaardeRecordEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginBTWTabelWaardeRecordUpdate-->
<input type="submit" value="Bewaren" onclick="document.BTWTabelWaardeRecord.FormAction.value = 'update';"/>
<!--EndBTWTabelWaardeRecordUpdate-->
<!--BeginBTWTabelWaardeRecordDelete-->
<input type="submit" value="Verwijderen" onclick="document.BTWTabelWaardeRecord.FormAction.value = 'delete';"/>
<!--EndBTWTabelWaardeRecordDelete-->
<!--EndBTWTabelWaardeRecordEdit-->
<!--BeginBTWTabelWaardeRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.BTWTabelWaardeRecord.FormAction.value = 'cancel';"/>
<!--EndBTWTabelWaardeRecordCancel-->
<input type="hidden" name="FormName" value="BTWTabelWaardeRecord"/>
<input type="hidden" name="Trn_FIN_BTWTABEL_KEY" value="{Trn_FIN_BTWTABEL_KEY}"/>
<input type="hidden" name="Rqd_FIN_BTWTABELWAARDE_KEY" value="{Rqd_FIN_BTWTABELWAARDE_KEY}"/>
<input type="hidden" name="PK_FIN_BTWTABELWAARDE_KEY" value="{PK_FIN_BTWTABELWAARDE_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormBTWTabelWaardeRecord-->
<!--BeginFormBTWTabelWaardeRecordFooter-->
<!--EndFormBTWTabelWaardeRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,346 +0,0 @@
<%
'
' Filename: mld_meldbrongrid.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' mld_meldbrongrid CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' mld_meldbrongrid CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "mld_meldbrongrid.asp"
sTemplateFileName = "mld_meldbrongrid.html"
'===============================
'===============================
' mld_meldbrongrid PageSecurity begin
' mld_meldbrongrid PageSecurity end
'===============================
'===============================
' mld_meldbrongrid Open Event begin
' mld_meldbrongrid Open Event end
'===============================
'===============================
' mld_meldbrongrid OpenAnyPage Event begin
' mld_meldbrongrid OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' mld_meldbrongrid Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
MeldbronGrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' mld_meldbrongrid Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' mld_meldbrongrid Close Event begin
' mld_meldbrongrid Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub MeldbronGrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Meldbronnen"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 25
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
Dim sActionFileName : sActionFileName = "mld_meldbronrecord.asp"
SetVar "TransitParams", ""
SetVar "FormParams", ""
'-------------------------------
' Build ORDER BY statement
'-------------------------------
iSort = GetParam("FormMeldbronGrid_Sorting")
iSorted = GetParam("FormMeldbronGrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormMeldbronGrid_Sorting=" & iSort & "&FormMeldbronGrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormMeldbronGrid_Sorting=" & iSort & "&FormMeldbronGrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by M.MLD_MELDBRON_KEY" & sDirection
if iSort = 2 then sOrder = " order by M.MLD_MELDBRON_OMSCHRIJVING" & sDirection
if iSort = 3 then sOrder = " order by M.MLD_MELDBRON_DEFAULT" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select M.MLD_MELDBRON_DEFAULT as M_MLD_MELDBRON_DEFAULT, " & _
"M.MLD_MELDBRON_KEY as M_MLD_MELDBRON_KEY, " & _
"M.MLD_MELDBRON_OMSCHRIJVING as M_MLD_MELDBRON_OMSCHRIJVING " & _
" from MLD_V_AANWEZIGMELDBRON M "
'-------------------------------
'-------------------------------
' MeldbronGrid Open Event begin
' MeldbronGrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the link to the record page
'-------------------------------
SetVar "FormAction", sActionFileName
'-------------------------------
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListMeldbronGrid", ""
Parse "MeldbronGridNoRecords", False
SetVar "MeldbronGridNavigator", ""
Parse "FormMeldbronGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 25
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormMeldbronGrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "MeldbronGridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldMLD_MELDBRON_DEFAULT = GetValue(rs, "M_MLD_MELDBRON_DEFAULT")
fldMLD_MELDBRON_KEY = GetValue(rs, "M_MLD_MELDBRON_KEY")
fldMLD_MELDBRON_OMSCHRIJVING_URLLink = "mld_meldbronrecord.asp"
fldMLD_MELDBRON_OMSCHRIJVING_MLD_MELDBRON_KEY = GetValue(rs, "M_MLD_MELDBRON_KEY")
fldMLD_MELDBRON_OMSCHRIJVING = GetValue(rs, "M_MLD_MELDBRON_OMSCHRIJVING")
'-------------------------------
' MeldbronGrid Show begin
'-------------------------------
'-------------------------------
' MeldbronGrid Show Event begin
' MeldbronGrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "MLD_MELDBRON_KEY", ToHTML(fldMLD_MELDBRON_KEY)
SetVar "MLD_MELDBRON_OMSCHRIJVING", ToHTML(fldMLD_MELDBRON_OMSCHRIJVING)
SetVar "MLD_MELDBRON_OMSCHRIJVING_URLLink", fldMLD_MELDBRON_OMSCHRIJVING_URLLink
SetVar "PrmMLD_MELDBRON_OMSCHRIJVING_MLD_MELDBRON_KEY", ToURL(fldMLD_MELDBRON_OMSCHRIJVING_MLD_MELDBRON_KEY)
SetVar "MLD_MELDBRON_DEFAULT", ToHTML(fldMLD_MELDBRON_DEFAULT)
Parse "DListMeldbronGrid", True
'-------------------------------
' MeldbronGrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' MeldbronGrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "MeldbronGridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "MeldbronGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "MeldbronGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "MeldbronGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "MeldbronGridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "MeldbronGridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "MeldbronGridCurrentPage", iPage
Parse "MeldbronGridNavigator", False
end if
'-------------------------------
' MeldbronGrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "MeldbronGridNoRecords", ""
Parse "FormMeldbronGrid", False
'-------------------------------
' MeldbronGrid Close Event begin
' MeldbronGrid Close Event end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,64 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Meldbronnen</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormMeldbronGridHeader-->
<!--EndFormMeldbronGridHeader-->
<!--BeginFormMeldbronGrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="3"><a name="MeldbronGrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormMeldbronGrid_Sorting=1&FormMeldbronGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Key</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormMeldbronGrid_Sorting=2&FormMeldbronGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Omschrijving</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormMeldbronGrid_Sorting=3&FormMeldbronGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Default</font></a></td>
</tr>
<!--BeginDListMeldbronGrid-->
<tr>
<td class="DataTD"><font class="DataFONT">{MLD_MELDBRON_KEY}&nbsp;</font></td>
<td class="DataTD"><a href="{MLD_MELDBRON_OMSCHRIJVING_URLLink}?MLD_MELDBRON_KEY={PrmMLD_MELDBRON_OMSCHRIJVING_MLD_MELDBRON_KEY}&{TransitParams}"><font class="DataFONT">{MLD_MELDBRON_OMSCHRIJVING}</font></a>&nbsp;</td>
<td class="DataTD"><font class="DataFONT">{MLD_MELDBRON_DEFAULT}&nbsp;</font></td>
</tr>
<!--EndDListMeldbronGrid-->
<!--BeginMeldbronGridNoRecords-->
<tr><td colspan="3" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndMeldbronGridNoRecords-->
<tr>
<td colspan="3" class="ColumnTD">
<font class="ColumnFONT">
<a href="{FormAction}?{TransitParams}"><font class="ColumnFONT">Toevoegen</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<!--BeginMeldbronGridNavigator-->
<a href{MeldbronGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormMeldbronGrid_Page=1#MeldbronGrid"><font class="ColumnFONT"><<</font></a>
<a href{MeldbronGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormMeldbronGrid_Page={PrevPage}#MeldbronGrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginMeldbronGridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormMeldbronGrid_Page={NavigatorPageNumber}#MeldbronGrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndMeldbronGridNavigatorPages-->van {MeldbronGridPageCount} ]
<a href{MeldbronGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormMeldbronGrid_Page={NextPage}#MeldbronGrid"><font class="ColumnFONT">></font></a>
<a href{MeldbronGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormMeldbronGrid_Page=last#MeldbronGrid"><font class="ColumnFONT">>></font></a>
<!--EndMeldbronGridNavigator-->
</font>
</td>
</tr>
</table>
<!--EndFormMeldbronGrid-->
<!--BeginFormMeldbronGridFooter-->
<!--EndFormMeldbronGridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,351 +0,0 @@
<%
'
' Filename: mld_meldbronrecord.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' mld_meldbronrecord CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' mld_meldbronrecord CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "mld_meldbronrecord.asp"
sTemplateFileName = "mld_meldbronrecord.html"
'===============================
'===============================
' mld_meldbronrecord PageSecurity begin
' mld_meldbronrecord PageSecurity end
'===============================
'===============================
' mld_meldbronrecord Open Event begin
' mld_meldbronrecord Open Event end
'===============================
'===============================
' mld_meldbronrecord OpenAnyPage Event begin
' mld_meldbronrecord OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' mld_meldbronrecord Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sMeldbronRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "MeldbronRecord"
MeldbronRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
MeldbronRecord_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' mld_meldbronrecord Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' mld_meldbronrecord Close Event begin
' mld_meldbronrecord Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub MeldbronRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKMLD_MELDBRON_KEY : pPKMLD_MELDBRON_KEY = ""
Dim fldMLD_MELDBRON_OMSCHRIJVING : fldMLD_MELDBRON_OMSCHRIJVING = ""
Dim fldMLD_MELDBRON_DEFAULT : fldMLD_MELDBRON_DEFAULT = ""
'-------------------------------
'-------------------------------
' MeldbronRecord Action begin
'-------------------------------
sActionFileName = "mld_meldbrongrid.asp"
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' MeldbronRecord BeforeCancel Event begin
' MeldbronRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKMLD_MELDBRON_KEY = GetParam("PK_MLD_MELDBRON_KEY")
if IsEmpty(pPKMLD_MELDBRON_KEY) then exit sub
sWhere = "MLD_MELDBRON_KEY=" & ToSQL(pPKMLD_MELDBRON_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldMLD_MELDBRON_OMSCHRIJVING = GetParam("MLD_MELDBRON_OMSCHRIJVING")
fldMLD_MELDBRON_DEFAULT = getCheckBoxValue(GetParam("MLD_MELDBRON_DEFAULT"), "1", "", "Number")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if IsEmpty(fldMLD_MELDBRON_OMSCHRIJVING) then
sMeldbronRecordErr = sMeldbronRecordErr & "De waarde in veld Omschrijving is verplicht.<br>"
end if
'-------------------------------
' MeldbronRecord Check Event begin
' MeldbronRecord Check Event end
'-------------------------------
If len(sMeldbronRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' MeldbronRecord Insert Event begin
' MeldbronRecord Insert Event end
'-------------------------------
sSQL = "insert into MLD_V_AANWEZIGMELDBRON (" & _
"MLD_MELDBRON_OMSCHRIJVING," & _
"MLD_MELDBRON_DEFAULT)" & _
" values (" & _
ToSQL(fldMLD_MELDBRON_OMSCHRIJVING, "Text") & "," & _
fldMLD_MELDBRON_DEFAULT & _
")"
case "update"
'-------------------------------
' MeldbronRecord Update Event begin
' MeldbronRecord Update Event end
'-------------------------------
sSQL = "update MLD_V_AANWEZIGMELDBRON set " & _
"MLD_MELDBRON_OMSCHRIJVING=" & ToSQL(fldMLD_MELDBRON_OMSCHRIJVING, "Text") & _
",MLD_MELDBRON_DEFAULT=" & fldMLD_MELDBRON_DEFAULT
sSQL = sSQL & " where " & sWhere
case "delete"
'-------------------------------
' MeldbronRecord Delete Event begin
dim tmpkey
tmpkey = "PK_"&strToTable(sActionFileName)&"_KEY"
sSql = customFacDelete(sActionFileName,getParam(tmpkey))
set tmpkey = Nothing
' MeldbronRecord Delete Event end
'-------------------------------
if sSQL = "" then
sSQL = "delete from MLD_V_AANWEZIGMELDBRON where " & sWhere
end if
end select
'-------------------------------
'-------------------------------
' MeldbronRecord BeforeExecute Event begin
' MeldbronRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sMeldbronRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sMeldbronRecordErr = ProcessError
on error goto 0
if len(sMeldbronRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName
'-------------------------------
' MeldbronRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub MeldbronRecord_Show()
'-------------------------------
' MeldbronRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Details meldbron"
Dim bPK : bPK = True
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sMeldbronRecordErr = "" then
pMLD_MELDBRON_KEY = GetParam("MLD_MELDBRON_KEY")
SetVar "MeldbronRecordError", ""
else
fldMLD_MELDBRON_OMSCHRIJVING = GetParam("MLD_MELDBRON_OMSCHRIJVING")
fldMLD_MELDBRON_DEFAULT = getCheckBoxValue(GetParam("MLD_MELDBRON_DEFAULT"), "1", "", "Number")
pMLD_MELDBRON_KEY = GetParam("PK_MLD_MELDBRON_KEY")
SetVar "sMeldbronRecordErr", sMeldbronRecordErr
SetVar "FormTitle", sFormTitle
Parse "MeldbronRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pMLD_MELDBRON_KEY) then bPK = False
sWhere = sWhere & "MLD_MELDBRON_KEY=" & ToSQL(pMLD_MELDBRON_KEY, "Number")
SetVar "PK_MLD_MELDBRON_KEY", pMLD_MELDBRON_KEY
'-------------------------------
'-------------------------------
' MeldbronRecord Open Event begin
' MeldbronRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from MLD_V_AANWEZIGMELDBRON where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "MeldbronRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldMLD_MELDBRON_KEY = GetValue(rs, "MLD_MELDBRON_KEY")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sMeldbronRecordErr = "" then
fldMLD_MELDBRON_OMSCHRIJVING = GetValue(rs, "MLD_MELDBRON_OMSCHRIJVING")
fldMLD_MELDBRON_DEFAULT = GetValue(rs, "MLD_MELDBRON_DEFAULT")
end if
SetVar "MeldbronRecordInsert", ""
Parse "MeldbronRecordEdit", False
'-------------------------------
' MeldbronRecord ShowEdit Event begin
' MeldbronRecord ShowEdit Event end
'-------------------------------
else
SetVar "MeldbronRecordEdit", ""
Parse "MeldbronRecordInsert", False
'-------------------------------
' MeldbronRecord ShowInsert Event begin
' MeldbronRecord ShowInsert Event end
'-------------------------------
end if
Parse "MeldbronRecordCancel", false
'-------------------------------
' MeldbronRecord Show Event begin
' MeldbronRecord Show Event end
'-------------------------------
'-------------------------------
' Show form field
'-------------------------------
SetVar "MLD_MELDBRON_KEY", ToHTML(fldMLD_MELDBRON_KEY)
SetVar "MLD_MELDBRON_OMSCHRIJVING", ToHTML(fldMLD_MELDBRON_OMSCHRIJVING)
if (LCase(fldMLD_MELDBRON_DEFAULT) = LCase("1")) then
SetVar "MLD_MELDBRON_DEFAULT_CHECKED", "CHECKED"
else
SetVar "MLD_MELDBRON_DEFAULT_CHECKED", ""
end if
Parse "FormMeldbronRecord", False
'-------------------------------
' MeldbronRecord Close Event begin
' MeldbronRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' MeldbronRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,90 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Details meldbron</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormMeldbronRecordHeader-->
<!--EndFormMeldbronRecordHeader-->
<!--BeginFormMeldbronRecord-->
<form method="POST" action="{FileName}" name="MeldbronRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginMeldbronRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sMeldbronRecordErr}</font></td>
</tr>
<!--EndMeldbronRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{MLD_MELDBRON_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Omschrijving</font></td>
<td class="DataTD"><input type="text" name="MLD_MELDBRON_OMSCHRIJVING" maxlength="30" value="{MLD_MELDBRON_OMSCHRIJVING}" size="30"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Default</font></td>
<td class="DataTD"><input {MLD_MELDBRON_DEFAULT_CHECKED} type="checkbox" name="MLD_MELDBRON_DEFAULT"></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginMeldbronRecordInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.MeldbronRecord.FormAction.value = 'insert';">
<!--EndMeldbronRecordInsert-->
<!--BeginMeldbronRecordEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginMeldbronRecordUpdate-->
<input type="submit" value="Bewaren" onclick="document.MeldbronRecord.FormAction.value = 'update';"/>
<!--EndMeldbronRecordUpdate-->
<!--BeginMeldbronRecordDelete-->
<input type="submit" value="Verwijderen" onclick="document.MeldbronRecord.FormAction.value = 'delete';"/>
<!--EndMeldbronRecordDelete-->
<!--EndMeldbronRecordEdit-->
<!--BeginMeldbronRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.MeldbronRecord.FormAction.value = 'cancel';"/>
<!--EndMeldbronRecordCancel-->
<input type="hidden" name="FormName" value="MeldbronRecord"/>
<input type="hidden" name="PK_MLD_MELDBRON_KEY" value="{PK_MLD_MELDBRON_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormMeldbronRecord-->
<!--BeginFormMeldbronRecordFooter-->
<!--EndFormMeldbronRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,343 +0,0 @@
<%
'
' Filename: prs_kostenplaatsgrpgrid.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' prs_kostenplaatsgrpgrid CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' prs_kostenplaatsgrpgrid CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "prs_kostenplaatsgrpgrid.asp"
sTemplateFileName = "prs_kostenplaatsgrpgrid.html"
'===============================
'===============================
' prs_kostenplaatsgrpgrid PageSecurity begin
' prs_kostenplaatsgrpgrid PageSecurity end
'===============================
'===============================
' prs_kostenplaatsgrpgrid Open Event begin
' prs_kostenplaatsgrpgrid Open Event end
'===============================
'===============================
' prs_kostenplaatsgrpgrid OpenAnyPage Event begin
' prs_kostenplaatsgrpgrid OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' prs_kostenplaatsgrpgrid Show begin
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
KostenplaatsgrpGrid_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' prs_kostenplaatsgrpgrid Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' prs_kostenplaatsgrpgrid Close Event begin
' prs_kostenplaatsgrpgrid Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Display Grid Form
'-------------------------------
Sub KostenplaatsgrpGrid_Show()
'-------------------------------
' Initialize variables
'-------------------------------
Dim rs
Dim sWhere : sWhere = ""
Dim sOrder : sOrder = ""
Dim sSQL : sSQL = ""
Dim sFormTitle: sFormTitle = "Kostenplaatsgroepen"
Dim HasParam : HasParam = false
Dim iSort : iSort = ""
Dim iSorted : iSorted = ""
Dim sDirection : sDirection = ""
Dim sSortParams : sSortParams = ""
Dim iRecordsPerPage : iRecordsPerPage = 30
Dim iCounter : iCounter = 0
Dim iPage : iPage = 0
Dim bEof : bEof = False
Dim iTmpI : iTmpI = 0
Dim iTmpJ : iTmpJ = 0
Dim sCountSQL : sCountSQL = ""
Dim sActionFileName : sActionFileName = "prs_kostenplaatsgrprecord.asp"
SetVar "TransitParams", ""
SetVar "FormParams", ""
'-------------------------------
' Build ORDER BY statement
'-------------------------------
sOrder = " order by P.PRS_KOSTENPLAATSGRP_OMS Asc"
iSort = GetParam("FormKostenplaatsgrpGrid_Sorting")
iSorted = GetParam("FormKostenplaatsgrpGrid_Sorted")
sDirection = ""
if IsEmpty(iSort) then
SetVar "Form_Sorting", ""
else
if iSort = iSorted then
SetVar "Form_Sorting", ""
sDirection = " DESC"
sSortParams = "FormKostenplaatsgrpGrid_Sorting=" & iSort & "&FormKostenplaatsgrpGrid_Sorted=" & iSort & "&"
else
SetVar "Form_Sorting", iSort
sDirection = " ASC"
sSortParams = "FormKostenplaatsgrpGrid_Sorting=" & iSort & "&FormKostenplaatsgrpGrid_Sorted=" & "&"
end if
if iSort = 1 then sOrder = " order by P.PRS_KOSTENPLAATSGRP_KEY" & sDirection
if iSort = 2 then sOrder = " order by P.PRS_KOSTENPLAATSGRP_OMS" & sDirection
end if
'-------------------------------
' Build base SQL statement
'-------------------------------
sSQL = "select P.PRS_KOSTENPLAATSGRP_KEY as P_PRS_KOSTENPLAATSGRP_KEY, " & _
"P.PRS_KOSTENPLAATSGRP_OMS as P_PRS_KOSTENPLAATSGRP_OMS " & _
" from PRS_KOSTENPLAATSGRP P "
'-------------------------------
'-------------------------------
' KostenplaatsgrpGrid Open Event begin
' KostenplaatsgrpGrid Open Event end
'-------------------------------
'-------------------------------
' Assemble full SQL statement
'-------------------------------
sSQL = sSQL & sWhere & sOrder
if sCountSQL = "" then
iTmpI = instr(lcase(sSQL), "select")
iTmpJ = instr(lcase(sSQL), "from") - 1
sCountSQL = replace(sSQL, mid(sSQL, iTmpI + 6, iTmpJ - 6), " count(*) ")
iTmpI = instr(lcase(sCountSQl), "order by")
if iTmpI > 1 then sCountSQL = left(sCountSQL, iTmpI - 1)
end if
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Process the link to the record page
'-------------------------------
SetVar "FormAction", sActionFileName
'-------------------------------
'-------------------------------
' Process the parameters for sorting
'-------------------------------
SetVar "SortParams", sSortParams
'-------------------------------
'-------------------------------
' Open the recordset
'-------------------------------
openrs rs, sSQL
'-------------------------------
'-------------------------------
' Process empty recordset
'-------------------------------
if rs.eof then
set rs = nothing
SetVar "DListKostenplaatsgrpGrid", ""
Parse "KostenplaatsgrpGridNoRecords", False
SetVar "KostenplaatsgrpGridNavigator", ""
Parse "FormKostenplaatsgrpGrid", False
exit sub
end if
'-------------------------------
'-------------------------------
' Initialize page counter and records per page
'-------------------------------
iRecordsPerPage = 30
iCounter = 0
'-------------------------------
'-------------------------------
' Process page scroller
'-------------------------------
iPage = GetParam("FormKostenplaatsgrpGrid_Page")
openrs rsCount, sCountSQL
dResult = CLng(rsCount.fields(0).value) / iRecordsPerPage
iPageCount = int(dResult)
if iPageCount < dResult then iPageCount = iPageCount + 1
SetVar "KostenplaatsgrpGridPageCount", iPageCount
set rsCount = nothing
if IsEmpty(iPage) then
iPage = 1
else
if iPage = "last" then iPage = iPageCount
end if
while not rs.eof and iCounter < (iPage-1)*iRecordsPerPage
rs.movenext
iCounter = iCounter + 1
wend
iCounter = 0
'-------------------------------
'-------------------------------
' Display grid based on recordset
'-------------------------------
while not rs.EOF and iCounter < iRecordsPerPage
'-------------------------------
' Create field variables based on database fields
'-------------------------------
fldPRS_KOSTENPLAATSGRP_KEY = GetValue(rs, "P_PRS_KOSTENPLAATSGRP_KEY")
fldPRS_KOSTENPLAATSGRP_OMS_URLLink = "prs_kostenplaatsgrprecord.asp"
fldPRS_KOSTENPLAATSGRP_OMS_PRS_KOSTENPLAATSGRP_KEY = GetValue(rs, "P_PRS_KOSTENPLAATSGRP_KEY")
fldPRS_KOSTENPLAATSGRP_OMS = GetValue(rs, "P_PRS_KOSTENPLAATSGRP_OMS")
'-------------------------------
' KostenplaatsgrpGrid Show begin
'-------------------------------
'-------------------------------
' KostenplaatsgrpGrid Show Event begin
' KostenplaatsgrpGrid Show Event end
'-------------------------------
'-------------------------------
' Replace Template fields with database values
'-------------------------------
SetVar "PRS_KOSTENPLAATSGRP_KEY", ToHTML(fldPRS_KOSTENPLAATSGRP_KEY)
SetVar "PRS_KOSTENPLAATSGRP_OMS", ToHTML(fldPRS_KOSTENPLAATSGRP_OMS)
SetVar "PRS_KOSTENPLAATSGRP_OMS_URLLink", fldPRS_KOSTENPLAATSGRP_OMS_URLLink
SetVar "PrmPRS_KOSTENPLAATSGRP_OMS_PRS_KOSTENPLAATSGRP_KEY", ToURL(fldPRS_KOSTENPLAATSGRP_OMS_PRS_KOSTENPLAATSGRP_KEY)
Parse "DListKostenplaatsgrpGrid", True
'-------------------------------
' KostenplaatsgrpGrid Show end
'-------------------------------
'-------------------------------
' Move to the next record and increase record counter
'-------------------------------
rs.MoveNext
iCounter = iCounter + 1
wend
'-------------------------------
'-------------------------------
' KostenplaatsgrpGrid Navigation begin
'-------------------------------
bEof = rs.eof
if rs.eof and iPage = 1 then
SetVar "KostenplaatsgrpGridNavigator", ""
else
iCounter = 1
iHasPages = iPage
iDisplayPages = 0
iNumberOfPages = 10
iHasPages = iPageCount
if (iHasPages - iPage) < int(iNumberOfPages/2) then
iStartPage = iHasPages - iNumberOfPages
else
iStartPage = iPage - iNumberOfPages + int(iNumberOfPages/2)
end if
if iStartPage < 0 then iStartPage = 0
for iPageCount = iStartPage + 1 to iPage - 1
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "KostenplaatsgrpGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
next
SetVar "NavigatorPageSwitch", "_"
SetVar "NavigatorPageNumber", iPage
SetVar "NavigatorPageNumberView", iPage
Parse "KostenplaatsgrpGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
SetVar "NavigatorPageSwitch", ""
iPageCount = iPage + 1
while iDisplayPages < iNumberOfPages and iStartPage + iDisplayPages < iHasPages
SetVar "NavigatorPageNumber", iPageCount
SetVar "NavigatorPageNumberView", iPageCount
Parse "KostenplaatsgrpGridNavigatorPages", true
iDisplayPages = iDisplayPages + 1
iPageCount = iPageCount + 1
wend
if bEof then
SetVar "KostenplaatsgrpGridNavigatorLastPage", "_"
else
SetVar "NextPage", (iPage + 1)
end if
if iPage = 1 then
SetVar "KostenplaatsgrpGridNavigatorFirstPage", "_"
else
SetVar "PrevPage", (iPage - 1)
end if
SetVar "KostenplaatsgrpGridCurrentPage", iPage
Parse "KostenplaatsgrpGridNavigator", False
end if
'-------------------------------
' KostenplaatsgrpGrid Navigation end
'-------------------------------
'-------------------------------
' Finish form processing
'-------------------------------
set rs = nothing
SetVar "KostenplaatsgrpGridNoRecords", ""
Parse "FormKostenplaatsgrpGrid", False
'-------------------------------
' KostenplaatsgrpGrid Close Event begin
' KostenplaatsgrpGrid Close Event end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,62 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Kostenplaats groep</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormKostenplaatsgrpGridHeader-->
<!--EndFormKostenplaatsgrpGridHeader-->
<!--BeginFormKostenplaatsgrpGrid--><table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><a name="KostenplaatsgrpGrid"><font class="FormHeaderFONT">{FormTitle}</font></a></td>
</tr>
<tr>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormKostenplaatsgrpGrid_Sorting=1&FormKostenplaatsgrpGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Key</font></a></td>
<td class="ColumnTD"><a href="{FileName}?{FormParams}FormKostenplaatsgrpGrid_Sorting=2&FormKostenplaatsgrpGrid_Sorted={Form_Sorting}&"><font class="ColumnFONT">Omschrijving</font></a></td>
</tr>
<!--BeginDListKostenplaatsgrpGrid-->
<tr>
<td class="DataTD"><font class="DataFONT">{PRS_KOSTENPLAATSGRP_KEY}&nbsp;</font></td>
<td class="DataTD"><a href="{PRS_KOSTENPLAATSGRP_OMS_URLLink}?PRS_KOSTENPLAATSGRP_KEY={PrmPRS_KOSTENPLAATSGRP_OMS_PRS_KOSTENPLAATSGRP_KEY}&{TransitParams}"><font class="DataFONT">{PRS_KOSTENPLAATSGRP_OMS}</font></a>&nbsp;</td>
</tr>
<!--EndDListKostenplaatsgrpGrid-->
<!--BeginKostenplaatsgrpGridNoRecords-->
<tr><td colspan="2" class="DataTD"><font class="DataFONT">Geen records</font></td></tr>
<!--EndKostenplaatsgrpGridNoRecords-->
<tr>
<td colspan="2" class="ColumnTD">
<font class="ColumnFONT">
<a href="{FormAction}?{TransitParams}"><font class="ColumnFONT">Toevoegen</font></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<!--BeginKostenplaatsgrpGridNavigator-->
<a href{KostenplaatsgrpGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormKostenplaatsgrpGrid_Page=1#KostenplaatsgrpGrid"><font class="ColumnFONT"><<</font></a>
<a href{KostenplaatsgrpGridNavigatorFirstPage}="{FileName}?{FormParams}{SortParams}FormKostenplaatsgrpGrid_Page={PrevPage}#KostenplaatsgrpGrid"><font class="ColumnFONT"><</font></a>
[ <!--BeginKostenplaatsgrpGridNavigatorPages--><a href{NavigatorPageSwitch}="{FileName}?{FormParams}{SortParams}FormKostenplaatsgrpGrid_Page={NavigatorPageNumber}#KostenplaatsgrpGrid"><font class="ColumnFONT">{NavigatorPageNumberView}</font></a>&nbsp;<!--EndKostenplaatsgrpGridNavigatorPages-->van {KostenplaatsgrpGridPageCount} ]
<a href{KostenplaatsgrpGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormKostenplaatsgrpGrid_Page={NextPage}#KostenplaatsgrpGrid"><font class="ColumnFONT">></font></a>
<a href{KostenplaatsgrpGridNavigatorLastPage}="{FileName}?{FormParams}{SortParams}FormKostenplaatsgrpGrid_Page=last#KostenplaatsgrpGrid"><font class="ColumnFONT">>></font></a>
<!--EndKostenplaatsgrpGridNavigator-->
</font>
</td>
</tr>
</table>
<!--EndFormKostenplaatsgrpGrid-->
<!--BeginFormKostenplaatsgrpGridFooter-->
<!--EndFormKostenplaatsgrpGridFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,354 +0,0 @@
<%
'
' Filename: prs_kostenplaatsgrprecord.asp
' Generated with CodeCharge 2.0.5
' ASP 2.0 & Templates.ccp build 11/30/2001
'
'-------------------------------
'
' prs_kostenplaatsgrprecord CustomIncludes Event begin
%>
<!-- #INCLUDE FILE="Common.asp" -->
<%
' prs_kostenplaatsgrprecord CustomIncludes Event end
'===============================
' Save Page and File Name available into variables
'-------------------------------
sFileName = "prs_kostenplaatsgrprecord.asp"
sTemplateFileName = "prs_kostenplaatsgrprecord.html"
'===============================
'===============================
' prs_kostenplaatsgrprecord PageSecurity begin
' prs_kostenplaatsgrprecord PageSecurity end
'===============================
'===============================
' prs_kostenplaatsgrprecord Open Event begin
' prs_kostenplaatsgrprecord Open Event end
'===============================
'===============================
' prs_kostenplaatsgrprecord OpenAnyPage Event begin
' prs_kostenplaatsgrprecord OpenAnyPage Event end
'===============================
'===============================
'Save the name of the form and type of action into the variables
'-------------------------------
sAction = GetParam("FormAction")
sForm = GetParam("FormName")
'===============================
' prs_kostenplaatsgrprecord Show begin
'===============================
' Perform the form's action
'-------------------------------
' Initialize error variables
'-------------------------------
sKostenplaatsgrpRecordErr = ""
'-------------------------------
' Select the FormAction
'-------------------------------
Select Case sForm
Case "KostenplaatsgrpRecord"
KostenplaatsgrpRecordAction(sAction)
end select
'===============================
'===============================
' Display page
'-------------------------------
' Load HTML template for this page
'-------------------------------
LoadTemplate sAppPath & sTemplateFileName, "main"
'-------------------------------
' Load HTML template of Header and Footer
'-------------------------------
'-------------------------------
SetVar "FileName", sFileName
'-------------------------------
' Step through each form
'-------------------------------
KostenplaatsgrpRecord_Show
'-------------------------------
' Process page templates
'-------------------------------
Parse "main", False
'-------------------------------
' Output the page to the browser
'-------------------------------
Response.write PrintVar("main")
' prs_kostenplaatsgrprecord Show end
'-------------------------------
' Destroy all object variables
'-------------------------------
' prs_kostenplaatsgrprecord Close Event begin
' prs_kostenplaatsgrprecord Close Event end
cn.Close
Set cn = Nothing
UnloadTemplate
'===============================
'===============================
' Action of the Record Form
'-------------------------------
Sub KostenplaatsgrpRecordAction(sAction)
'-------------------------------
' Initialize variables
'-------------------------------
Dim bExecSQL: bExecSQL = true
Dim sActionFileName : sActionFileName = ""
Dim sWhere : sWhere = ""
Dim bErr : bErr = False
Dim pPKPRS_KOSTENPLAATSGRP_KEY : pPKPRS_KOSTENPLAATSGRP_KEY = ""
Dim fldPRS_KOSTENPLAATSGRP_OMS : fldPRS_KOSTENPLAATSGRP_OMS = ""
Dim fldPRS_PERSLID_KEY : fldPRS_PERSLID_KEY = ""
'-------------------------------
'-------------------------------
' KostenplaatsgrpRecord Action begin
'-------------------------------
sActionFileName = "prs_kostenplaatsgrpgrid.asp"
'-------------------------------
' CANCEL action
'-------------------------------
if sAction = "cancel" then
'-------------------------------
' KostenplaatsgrpRecord BeforeCancel Event begin
' KostenplaatsgrpRecord BeforeCancel Event end
'-------------------------------
cn.Close
Set cn = Nothing
response.redirect sActionFileName
end if
'-------------------------------
'-------------------------------
' Build WHERE statement
'-------------------------------
if sAction = "update" or sAction = "delete" then
pPKPRS_KOSTENPLAATSGRP_KEY = GetParam("PK_PRS_KOSTENPLAATSGRP_KEY")
if IsEmpty(pPKPRS_KOSTENPLAATSGRP_KEY) then exit sub
sWhere = "PRS_KOSTENPLAATSGRP_KEY=" & ToSQL(pPKPRS_KOSTENPLAATSGRP_KEY, "Number")
end if
'-------------------------------
'-------------------------------
' Load all form fields into variables
'-------------------------------
fldPRS_KOSTENPLAATSGRP_OMS = GetParam("PRS_KOSTENPLAATSGRP_OMS")
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
'-------------------------------
' Validate fields
'-------------------------------
if sAction = "insert" or sAction = "update" then
if not isNumeric(fldPRS_PERSLID_KEY) then
sKostenplaatsgrpRecordErr = sKostenplaatsgrpRecordErr & "De waarde in veld Verantwoordelijke is niet correct.<br>"
end if
'-------------------------------
' KostenplaatsgrpRecord Check Event begin
' KostenplaatsgrpRecord Check Event end
'-------------------------------
If len(sKostenplaatsgrpRecordErr) > 0 then
exit sub
end if
end if
'-------------------------------
'-------------------------------
' Create SQL statement
'-------------------------------
select case sAction
case "insert"
'-------------------------------
' KostenplaatsgrpRecord Insert Event begin
' KostenplaatsgrpRecord Insert Event end
'-------------------------------
sSQL = "insert into PRS_KOSTENPLAATSGRP (" & _
"PRS_KOSTENPLAATSGRP_OMS," & _
"PRS_PERSLID_KEY)" & _
" values (" & _
ToSQL(fldPRS_KOSTENPLAATSGRP_OMS, "Text") & "," & _
ToSQL(fldPRS_PERSLID_KEY, "Number") & _
")"
case "update"
'-------------------------------
' KostenplaatsgrpRecord Update Event begin
' KostenplaatsgrpRecord Update Event end
'-------------------------------
sSQL = "update PRS_KOSTENPLAATSGRP set " & _
"PRS_KOSTENPLAATSGRP_OMS=" & ToSQL(fldPRS_KOSTENPLAATSGRP_OMS, "Text") & _
",PRS_PERSLID_KEY=" & ToSQL(fldPRS_PERSLID_KEY, "Number")
sSQL = sSQL & " where " & sWhere
case "delete"
'-------------------------------
' KostenplaatsgrpRecord Delete Event begin
' KostenplaatsgrpRecord Delete Event end
'-------------------------------
sSQL = "delete from PRS_KOSTENPLAATSGRP where " & sWhere
end select
'-------------------------------
'-------------------------------
' KostenplaatsgrpRecord BeforeExecute Event begin
' KostenplaatsgrpRecord BeforeExecute Event end
'-------------------------------
'-------------------------------
' Execute SQL statement
'-------------------------------
if len(sKostenplaatsgrpRecordErr) > 0 then Exit Sub
on error resume next
if bExecSQL then
cn.execute sSQL
end if
sKostenplaatsgrpRecordErr = ProcessError
on error goto 0
if len(sKostenplaatsgrpRecordErr) > 0 then Exit Sub
cn.Close
Set cn = Nothing
response.redirect sActionFileName
'-------------------------------
' KostenplaatsgrpRecord Action end
'-------------------------------
end sub
'===============================
'===============================
' Display Record Form
'-------------------------------
Sub KostenplaatsgrpRecord_Show()
'-------------------------------
' KostenplaatsgrpRecord Show begin
'-------------------------------
Dim sWhere : sWhere = ""
Dim sFormTitle: sFormTitle = "Details kostenplaatsgroep"
Dim bPK : bPK = True
Dim sPRS_PERSLID_KEYDisplayValue: sPRS_PERSLID_KEYDisplayValue = "n.v.t."
'-------------------------------
' Load primary key and form parameters
'-------------------------------
if sKostenplaatsgrpRecordErr = "" then
pPRS_KOSTENPLAATSGRP_KEY = GetParam("PRS_KOSTENPLAATSGRP_KEY")
SetVar "KostenplaatsgrpRecordError", ""
else
fldPRS_KOSTENPLAATSGRP_OMS = GetParam("PRS_KOSTENPLAATSGRP_OMS")
fldPRS_PERSLID_KEY = GetParam("PRS_PERSLID_KEY")
pPRS_KOSTENPLAATSGRP_KEY = GetParam("PK_PRS_KOSTENPLAATSGRP_KEY")
SetVar "sKostenplaatsgrpRecordErr", sKostenplaatsgrpRecordErr
SetVar "FormTitle", sFormTitle
Parse "KostenplaatsgrpRecordError", False
end if
'-------------------------------
'-------------------------------
' Load all form fields
'-------------------------------
'-------------------------------
' Build WHERE statement
if IsEmpty(pPRS_KOSTENPLAATSGRP_KEY) then bPK = False
sWhere = sWhere & "PRS_KOSTENPLAATSGRP_KEY=" & ToSQL(pPRS_KOSTENPLAATSGRP_KEY, "Number")
SetVar "PK_PRS_KOSTENPLAATSGRP_KEY", pPRS_KOSTENPLAATSGRP_KEY
'-------------------------------
'-------------------------------
' KostenplaatsgrpRecord Open Event begin
' KostenplaatsgrpRecord Open Event end
'-------------------------------
SetVar "FormTitle", sFormTitle
'-------------------------------
' Build SQL statement and open recordset
'-------------------------------
sSQL = "select * from PRS_KOSTENPLAATSGRP where " & sWhere
openrs rs, sSQL
bIsUpdateMode = (bPK and not(sAction = "insert" and sForm = "KostenplaatsgrpRecord") and not rs.eof)
'-------------------------------
'-------------------------------
' Load all fields into variables from recordset or input parameters
'-------------------------------
if bIsUpdateMode then
fldPRS_KOSTENPLAATSGRP_KEY = GetValue(rs, "PRS_KOSTENPLAATSGRP_KEY")
'-------------------------------
' Load data from recordset when form displayed first time
'-------------------------------
if sKostenplaatsgrpRecordErr = "" then
fldPRS_KOSTENPLAATSGRP_OMS = GetValue(rs, "PRS_KOSTENPLAATSGRP_OMS")
fldPRS_PERSLID_KEY = GetValue(rs, "PRS_PERSLID_KEY")
end if
SetVar "KostenplaatsgrpRecordInsert", ""
Parse "KostenplaatsgrpRecordEdit", False
'-------------------------------
' KostenplaatsgrpRecord ShowEdit Event begin
' KostenplaatsgrpRecord ShowEdit Event end
'-------------------------------
else
SetVar "KostenplaatsgrpRecordEdit", ""
Parse "KostenplaatsgrpRecordInsert", False
'-------------------------------
' KostenplaatsgrpRecord ShowInsert Event begin
' KostenplaatsgrpRecord ShowInsert Event end
'-------------------------------
end if
Parse "KostenplaatsgrpRecordCancel", false
'-------------------------------
' KostenplaatsgrpRecord Show Event begin
' KostenplaatsgrpRecord Show Event end
'-------------------------------
'-------------------------------
' Show form field
'-------------------------------
SetVar "PRS_KOSTENPLAATSGRP_KEY", ToHTML(fldPRS_KOSTENPLAATSGRP_KEY)
SetVar "PRS_KOSTENPLAATSGRP_OMS", ToHTML(fldPRS_KOSTENPLAATSGRP_OMS)
SetVar "KostenplaatsgrpRecordLBPRS_PERSLID_KEY", ""
SetVar "Selected", ""
SetVar "ID", ""
SetVar "Value", sPRS_PERSLID_KEYDisplayValue
Parse "KostenplaatsgrpRecordLBPRS_PERSLID_KEY", True
openrs rsPRS_PERSLID_KEY, "select p.prs_perslid_key, p.prs_perslid_naam ||DECODE(NVL(p.prs_perslid_voorletters, ''),'','',', '|| p.prs_perslid_voorletters )||DECODE(NVL(p.prs_perslid_tussenvoegsel, ''),'','',' '|| p.prs_perslid_tussenvoegsel )||DECODE(NVL(p.prs_perslid_voornaam, ''),'','',' ('||p.prs_perslid_voornaam||')') from prs_perslid p, fac_v_webuser f where p.prs_perslid_key = f.prs_perslid_key order by 2"
while not rsPRS_PERSLID_KEY.EOF
SetVar "ID", GetValue(rsPRS_PERSLID_KEY, 0) : SetVar "Value", GetValue(rsPRS_PERSLID_KEY, 1)
if cstr(GetValue(rsPRS_PERSLID_KEY, 0)) = cstr(fldPRS_PERSLID_KEY) then SetVar "Selected", "SELECTED" else SetVar "Selected", ""
Parse "KostenplaatsgrpRecordLBPRS_PERSLID_KEY", True
rsPRS_PERSLID_KEY.MoveNext
wend
set rsPRS_PERSLID_KEY = nothing
Parse "FormKostenplaatsgrpRecord", False
'-------------------------------
' KostenplaatsgrpRecord Close Event begin
' KostenplaatsgrpRecord Close Event end
'-------------------------------
Set rs = Nothing
'-------------------------------
' KostenplaatsgrpRecord Show end
'-------------------------------
End Sub
'===============================
%>

View File

@@ -1,90 +0,0 @@
<html>
<head>
<title>Facilitor Management Online - Details kostenplaats groep</title>
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 / Templates.ccp build 11/01/2001">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><link rel="stylesheet" href="Site.css" type="text/css"></head>
<body class="PageBODY">
{Header}
<table>
<tr>
<td valign="top">
<!--BeginFormKostenplaatsgrpRecordHeader-->
<!--EndFormKostenplaatsgrpRecordHeader-->
<!--BeginFormKostenplaatsgrpRecord-->
<form method="POST" action="{FileName}" name="KostenplaatsgrpRecord">
<table class="FormTABLE">
<tr>
<td class="FormHeaderTD" colspan="2"><font class="FormHeaderFONT">{FormTitle}</font></td>
</tr>
<!--BeginKostenplaatsgrpRecordError-->
<tr>
<td class="DataTD" colspan="2"><font class="DataFONT">{sKostenplaatsgrpRecordErr}</font></td>
</tr>
<!--EndKostenplaatsgrpRecordError-->
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Key</font></td>
<td class="DataTD"><font class="DataFONT">{PRS_KOSTENPLAATSGRP_KEY}&nbsp;</font></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Omschrijving</font></td>
<td class="DataTD"><input type="text" name="PRS_KOSTENPLAATSGRP_OMS" maxlength="60" value="{PRS_KOSTENPLAATSGRP_OMS}" size="30"></td>
</tr>
<tr>
<td class="FieldCaptionTD"><font class="FieldCaptionFONT">Verantwoordelijke</font></td>
<td class="DataTD"><select name="PRS_PERSLID_KEY"><!--BeginKostenplaatsgrpRecordLBPRS_PERSLID_KEY--><option value="{ID}" {Selected}>{Value}</option><!--EndKostenplaatsgrpRecordLBPRS_PERSLID_KEY--></select></td>
</tr>
<tr>
<td colspan="2" align="right">
<!-- *** Buttons *** -->
<!--BeginKostenplaatsgrpRecordInsert-->
<input type="hidden" value="insert" name="FormAction">
<input type="submit" value="Toevoegen" onclick="document.KostenplaatsgrpRecord.FormAction.value = 'insert';">
<!--EndKostenplaatsgrpRecordInsert-->
<!--BeginKostenplaatsgrpRecordEdit-->
<input type="hidden" value="update" name="FormAction"/>
<!--BeginKostenplaatsgrpRecordUpdate-->
<input type="submit" value="Bewaren" onclick="document.KostenplaatsgrpRecord.FormAction.value = 'update';"/>
<!--EndKostenplaatsgrpRecordUpdate-->
<!--BeginKostenplaatsgrpRecordDelete-->
<input type="submit" value="Verwijderen" onclick="document.KostenplaatsgrpRecord.FormAction.value = 'delete';"/>
<!--EndKostenplaatsgrpRecordDelete-->
<!--EndKostenplaatsgrpRecordEdit-->
<!--BeginKostenplaatsgrpRecordCancel-->
<input type="submit" value="Annuleren" onclick="document.KostenplaatsgrpRecord.FormAction.value = 'cancel';"/>
<!--EndKostenplaatsgrpRecordCancel-->
<input type="hidden" name="FormName" value="KostenplaatsgrpRecord"/>
<input type="hidden" name="PK_PRS_KOSTENPLAATSGRP_KEY" value="{PK_PRS_KOSTENPLAATSGRP_KEY}"/>
</td>
</tr>
</table>
</form>
<!--EndFormKostenplaatsgrpRecord-->
<!--BeginFormKostenplaatsgrpRecordFooter-->
<!--EndFormKostenplaatsgrpRecordFooter-->
</td>
</tr>
</table>
{Footer}
</body>
</html>

View File

@@ -1,101 +0,0 @@
<%@language = "javascript" %>
<% /* $Revision$
$Id$
File: workflow_graph.asp
Description: Maak een mooie grafiek
Parameters: start_key (REQUIRED)
Context:
Note: as-is
*/ %>
<%
DOCTYPE_Disable = 1;
%>
<!-- #include file="../Shared/common.inc" -->
<%
var chl = [];
var start_key = getQParamInt("start_key", -1);
var sql = "SELECT mld_workflowstep_omschrijving,"
+ " mld_workflowstep_start_key,"
+ " mld_workflowstep_key,"
+ " mld_stdmelding_omschrijving"
+ " FROM mld_workflowstep ws,"
+ " mld_stdmelding ms"
+ " WHERE ws.mld_stdmelding_key = ms.mld_stdmelding_key";
if (start_key > 0) sql +=" AND (ws.mld_workflowstep_key = "+start_key+" OR ws.mld_workflowstep_start_key = "+start_key+")";
var oRs = Oracle.Execute(sql);
while (!oRs.Eof)
{
var to = oRs("mld_workflowstep_key").Value;
chl.push("WS_"+to+ " [ label=\""+oRs("mld_workflowstep_omschrijving").Value+"\\n["+oRs("mld_stdmelding_omschrijving").Value+"]\"]");
oRs.MoveNext();
}
/* var sql = "SELECT mld_workflowstep_omschrijving,"
+ " mld_workflowstep_start_key,"
+ " mld_workflowstep_key"
+ " FROM mld_workflowstep"
+ " WHERE mld_workflowstep_start_key IS NOT NULL";
var oRs = Oracle.Execute(sql);
while (!oRs.Eof)
{
var from = oRs("mld_workflowstep_start_key").Value;
var to = oRs("mld_workflowstep_key").Value;
chl.push("WS_"+from + "--" + "WS_"+to); // + " [ label=\"Test\"]"
oRs.MoveNext();
}
*/
var sql = "SELECT mld_workflowrule_omschrijving,"
+ " mld_workflowrule_condition,"
+ " mld_workflowstep_key,"
+ " mld_workflowstep_next_key"
+ " FROM mld_workflowrule";
if (start_key > 0) sql += " WHERE mld_workflowstep_key IN (SELECT mld_workflowstep_key FROM mld_workflowstep ws WHERE ws.mld_workflowstep_key = "+start_key+" OR ws.mld_workflowstep_start_key = "+start_key+")";
var oRs = Oracle.Execute(sql);
while (!oRs.Eof)
{
var from = oRs("mld_workflowstep_key").Value;
var to = oRs("mld_workflowstep_next_key").Value;
var cond = oRs("mld_workflowrule_condition").Value;
chl.push("WS_"+from + "->" + "WS_"+to + " [ label=\""+oRs("mld_workflowrule_omschrijving").Value+ (cond?"\\nCOND: "+cond:"") +"\"]");
oRs.MoveNext();
}
ttl = "";
// url = "http://chart.apis.google.com/chart?"
post = ""//"http://chart.apis.google.com/chart?"
+ "&cht=gv:dot"
+ "&chl=digraph{"+chl.join(";")+"}"
var objXMLHTTP = Server.CreateObject("MSXML2.ServerXMLHTTP.6.0")
objXMLHTTP.open("POST",
"http://chart.apis.google.com/chart",
false);
//objXMLHTTP.setRequestHeader("Content-Type", "text/xml; charset=utf-8");
objXMLHTTP.send(post);
if (objXMLHTTP.status==200)
{ Response.contenttype = "image/png";
Response.BinaryWrite(objXMLHTTP.responseBody);
}
else
{
Response.Write("Mislukt, status = " + objXMLHTTP.status);
Response.Write(objXMLHTTP.statusText);
Response.Write(objXMLHTTP.responseText);
}
%>

View File

@@ -1,225 +0,0 @@
<%@language = "javascript" %>
<%
/* $Revision$
$Id$
File: workflow_overview.asp
Description: Toont een workflow met flexkenmerken wat overzichtelijker
Parameters: start_key (REQUIRED)
Context:
Note: as-is
*/ %>
<!-- #include file="../Shared/common.inc" -->
<!-- #include file="../Shared/iface.inc" -->
<head>
<%
var start_key = getQParamInt("start_key");
var colorise = getQParam("color", 1);
var authparams = user.checkAutorisation("WEB_PRSSYS");
%>
<% FCLTHeader.Generate(); %>
<script type="text/javascript">
function mld_refresh()
{
if (!validateForm("wf"))
return false;
FcltMgr.reload();
}
function mld_cancel()
{
FcltMgr.closeDetail(window, { cancel: true } );
}
$( document ).ready(function() {
$(".sk").hover(function(){
$("."+this.className.split(' ').join('.')).toggleClass('border');
});$(".sk").click(function(){
$("."+this.className.split(' ').join('.')).toggleClass('border');
});
});
</script>
<style>
table { margin: 10px; }
tr.sk { border-left: 5px solid #fafafa; border-right: 5px solid #fafafa; }
tr.border { border-left: 5px solid #f00; border-right: 5px solid #f00; }
tr.hdr { border-left: 5px solid #fff; border-right: 5px solid #fff; }
tr.hdr th {border-right: 1px solid #ddd}
tr.sk td { color: #ffffff; padding: 3px 6px; border-right: 1px solid #ddd; }
td.nr { text-align: center;}
</style>
</head>
<body>
<form id="wf" name="wf" action="workflow_overview.asp" method="post">
<%
BLOCK_START("mldWFOverview", L("lcl_mld_workflow_overview") );
//RWCHECKBOXTR("color", "fldcheck", "Kleurtjes", (colorise==1?" checked":""))
makeOverview();
BLOCK_END();
var buttons = [ {title: L("lcl_refresh"), icon: "refresh.png", action: "mld_refresh()"}
, {title: L("lcl_cancel"), icon: "cancel.png", action: "mld_cancel()" } ];
CreateButtons(buttons);
IFACE.FORM_END();
var graphurl = "./workflow_graph.asp?start_key=" + start_key;
%>
<img src="<%=safe.htmlattr(graphurl)%>">
</form>
</body>
</html>
<%
function makeOverview()
{
var keys = [];
var desc;
var allkenmerken = {}; // een rule condition heeft altijd betrekking op de kenmerken van de
// vorige step. Die onthouden we in allkenmerken
// start_key wordt verondersteld een root_key te zijn
var desc = buildStepHTML(start_key, allkenmerken);
Response.Write("<tr><td>"+desc+"</td></tr>");
keys.push(start_key);
for (i = 0;i < 10 && keys.length; i++) // Maximaal 10 stappen?
{
var isMerge = keys.length > 1;
var sql = "SELECT DISTINCT ws.mld_workflowstep_key,"
+ " ws.mld_workflowstep_omschrijving,"
+ " wr.mld_workflowrule_condition"
+ " FROM mld_workflowrule wr,"
+ " mld_workflowstep ws"
+ " WHERE wr.mld_workflowstep_key IN ("+keys.join(",")+")"
+ " AND wr.mld_workflowstep_next_key NOT IN ("+keys.join(",")+")"
+ " AND ws.mld_workflowstep_key = wr.mld_workflowstep_next_key"
+ " ORDER BY mld_workflowstep_omschrijving";
var oRs = Oracle.Execute(sql);
Response.Write("<tr>");
keys.length = 0; // Opnieuw opbouwen voor volgende niveau
while (!oRs.Eof)
{
step_key = oRs("mld_workflowstep_key").Value;
keys.push(oRs("mld_workflowstep_key").Value );
desc = buildStepHTML(step_key, allkenmerken, isMerge)
var condition = oRs("mld_workflowrule_condition").Value;
var condition_friendly_safe = condition || "";
if (condition)
{
for (var key in allkenmerken)
condition_friendly_safe = condition_friendly_safe.replace(new RegExp(":flex" + key, 'g'), "<em>" + safe.html(allkenmerken[key]) + "</em>");
desc = "<strong>WHEN:</strong> " + safe.html(condition) + "<br><strong>FRIENDLY:</strong> " + condition_friendly_safe + "<br>" + desc;
}
Response.Write("<td style='vertical-align:top;border:1px solid grey;'>"+ desc+"</td>");
oRs.MoveNext();
}
Response.Write("</tr>");
}
}
function buildStepHTML(step_key, allkenmerken, isMerge)
{
var pad = 'ffffff';
var sql = "SELECT mld_workflowstep_omschrijving,"
+ " mld_workflowstep_jointype,"
+ " ms.mld_stdmelding_omschrijving,"
+ " ms.mld_stdmelding_key,"
+ " md.ins_discipline_key,"
+ " md.ins_srtdiscipline_key,"
+ " FLOOR( (SELECT MAX(mld_srtkenmerk_key) FROM mld_srtkenmerk)/100 + 1)*100 maxclr"
+ " FROM mld_workflowstep ws,"
+ " mld_stdmelding ms,"
+ " mld_discipline md"
+ " WHERE ws.mld_stdmelding_key = ms.mld_stdmelding_key"
+ " AND md.ins_discipline_key = ms.mld_ins_discipline_key"
+ " AND ws.mld_workflowstep_key = " + step_key
+ " ORDER BY mld_workflowstep_omschrijving";
var oRs = Oracle.Execute(sql);
var maxClr = oRs("maxclr").value;
var desc = "<p>Step: <b>"+oRs("mld_workflowstep_omschrijving").Value+"</b>"
if (isMerge)
{
var jointype = oRs("mld_workflowstep_jointype").Value;
desc += "<br>JOIN: " + (jointype?"OR":"AND");
}
desc += "<br/>"+L('lcl_complain')+": "+oRs("mld_stdmelding_omschrijving").Value;
desc += "</p>";
var sql1 = " SELECT mkm.mld_kenmerk_key,"
+ " mkm.mld_kenmerk_niveau,"
+ " mkm.mld_kenmerk_verplicht,"
+ " mkm.mld_kenmerk_groep,"
+ " mld_kenmerk_volgnummer,"
+ " mld_kenmerk_toonbaar,"
+ " mld_srtkenmerk_omschrijving,"
+ " mld_srtkenmerk_kenmerktype,"
+ " mkm.mld_srtkenmerk_key"
+ " FROM mld_kenmerk mkm,"
+ " mld_srtkenmerk msk,"
+ " (SELECT 'S' mld_kenmerk_niveau,"
+ " mld_stdmelding_key ref_mld_stdmelding_key,"
+ " mld_stdmelding_key,"
+ " ins_discipline_key,"
+ " m2.ins_srtdiscipline_key"
+ " FROM mld_stdmelding md, mld_discipline m2"
+ " WHERE md.mld_ins_discipline_key = m2.ins_discipline_key"
+ " UNION ALL"
+ " SELECT 'D' mld_kenmerk_niveau,"
+ " ins_discipline_key ref_mld_stdmelding_key,"
+ " NULL mld_stdmelding_key,"
+ " ins_discipline_key ins_discipline_key,"
+ " ins_srtdiscipline_key"
+ " FROM mld_discipline m2"
+ " UNION ALL"
+ " SELECT 'T' mld_kenmerk_niveau,"
+ " ins_srtdiscipline_key ref_mld_stdmelding_key,"
+ " NULL mld_stdmelding_key,"
+ " NULL ins_discipline_key,"
+ " ins_srtdiscipline_key"
+ " FROM ins_srtdiscipline m2) s"
+ " WHERE mkm.mld_kenmerk_verwijder IS NULL"
+ " AND mkm.mld_stdmelding_key = ref_mld_stdmelding_key"
+ " AND mkm.mld_kenmerk_niveau = s.mld_kenmerk_niveau"
+ " AND mkm.mld_srtkenmerk_key = msk.mld_srtkenmerk_key"
+ " AND s.ins_srtdiscipline_key = "+oRs("ins_srtdiscipline_key").Value
+ " AND (s.ins_discipline_key = "+oRs("ins_discipline_key").Value
+ " OR ('T' = mkm.mld_kenmerk_niveau AND s.ins_srtdiscipline_key = "+oRs("ins_srtdiscipline_key").Value+"))"
+ " AND (s.mld_stdmelding_key = "+oRs("mld_stdmelding_key").Value
+ " OR ('D' = mkm.mld_kenmerk_niveau AND s.ins_discipline_key = "+oRs("ins_discipline_key").Value+")"
+ " OR ('T' = mkm.mld_kenmerk_niveau AND s.ins_srtdiscipline_key = "+oRs("ins_srtdiscipline_key").Value+"))"
+ " ORDER BY mld_kenmerk_volgnummer";
var oRs1 = Oracle.Execute(sql1);
desc += "<table><tr class='hdr'><th>key</th><th>nr</th><th>kenmerk</th><th>grp</th><th>verpl</th><th>ntw</th><th>niv</th></tr>";
while (!oRs1.Eof) // over alle kenmerken van deze melding
{
allkenmerken[oRs1("mld_kenmerk_key").value] = oRs1("mld_srtkenmerk_omschrijving").Value;
if (colorise != -1) {
clr = Math.round(oRs1("mld_srtkenmerk_key").value / maxClr * 255*255*255).toString(16);
clr = pad.substring(0, pad.length - clr.length) + clr;
}
desc += "<tr class='sk sk"+oRs1("mld_srtkenmerk_key").value+"' style='background-color: #"+clr+";'>"
+ "<td class='nr'>"+oRs1("mld_kenmerk_key").Value+"</td>"
+ "<td class='nr'>"+oRs1("mld_kenmerk_volgnummer").Value+"</td>"
+ "<td>"+oRs1("mld_srtkenmerk_omschrijving").Value+"</td>"
+ "<td class='nr'>"+(oRs1("mld_kenmerk_groep").Value>=1?oRs1("mld_kenmerk_groep").Value:"")+"</td>"
+ "<td class='nr'>"+(oRs1("mld_kenmerk_verplicht").Value>=1?oRs1("mld_kenmerk_verplicht").Value:"")+"</td>"
+ "<td class='nr'>"+(oRs1("mld_kenmerk_toonbaar").Value==1?"1":"")+"</td>"
+ "<td class='nr'>"+oRs1("mld_kenmerk_niveau").Value+"</td>"
+ "</tr>";
oRs1.MoveNext();
}
desc +="</table>";
oRs.Close();
return desc;
}
%>