FSN#39054 Budgetcontrole uitbreiding: BGT module savepoint
svn path=/Website/trunk/; revision=32819
This commit is contained in:
1
APPL/API/.gitignore
vendored
Normal file
1
APPL/API/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
TESTER
|
||||
155
APPL/API2/model_bgt_budget.inc
Normal file
155
APPL/API2/model_bgt_budget.inc
Normal file
@@ -0,0 +1,155 @@
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
|
||||
File: model_bgt_budget.inc
|
||||
|
||||
Description: model voor bgt_budget
|
||||
|
||||
Context:
|
||||
|
||||
Notes:
|
||||
*/
|
||||
%>
|
||||
<%
|
||||
|
||||
function model_bgt_budget()
|
||||
{
|
||||
this.table = "bgt_budget";
|
||||
this.primary = "bgt_budget_key";
|
||||
this.records_name = "bgt_budgets";
|
||||
this.record_name = "bgt_budget";
|
||||
this.autfunction = "WEB_BGTUSE";
|
||||
this.record_title = L("bgt_budget");
|
||||
this.records_title = L("bgt_budget_m");
|
||||
|
||||
this.fields = {
|
||||
"id": {
|
||||
"dbs": "bgt_budget_key",
|
||||
"label": "Key",
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"filter": "exact",
|
||||
"seq": "bgt_s_bgt_budget_key"
|
||||
},
|
||||
"catalog": {
|
||||
"dbs": "ins_discipline_key",
|
||||
"label": L("bgt_discipline_omschrijving"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"insertonly": true,
|
||||
"foreign": {
|
||||
"tbl": "ins_tab_discipline",
|
||||
"key": "ins_discipline_key",
|
||||
"desc": "ins_discipline_omschrijving",
|
||||
"where": "ins_discipline_module = 'BGT' AND ins_discipline_verwijder IS NULL"
|
||||
}
|
||||
},
|
||||
"group": {
|
||||
"dbs": "bgt_srtgroep_key",
|
||||
"label": L("bgt_srtgroep_omschrijving"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"insertonly": true,
|
||||
"foreign": {
|
||||
"tbl": "bgt_srtgroep",
|
||||
"key": "bgt_srtgroep_key",
|
||||
"desc": "bgt_srtgroep_omschrijving"
|
||||
}
|
||||
},
|
||||
"costcategory": {
|
||||
"dbs": "bgt_kostenrubriek_key",
|
||||
"label": L("bgt_kostenrubriek_oms"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"insertonly": true,
|
||||
"foreign": {
|
||||
"tbl": "bgt_kostenrubriek",
|
||||
"key": "bgt_kostenrubriek_key",
|
||||
"desc": "bgt_kostenrubriek_oms"
|
||||
}
|
||||
},
|
||||
"costtypegroup": {
|
||||
"dbs": "prs_kostensoortgrp_key",
|
||||
"label": L("prs_kostensoortgrp_key"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"insertonly": true,
|
||||
"foreign": {
|
||||
"tbl": "prs_kostensoortgrp",
|
||||
"key": "prs_kostensoortgrp_key",
|
||||
"desc": "prs_kostensoortgrp_oms"
|
||||
},
|
||||
"LOVinit": "",
|
||||
"filter": "exact"
|
||||
},
|
||||
"cost_category": {
|
||||
"dbs": "prs_kostensoort_key",
|
||||
"label": L("prs_kostensoort_key"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"insertonly": true,
|
||||
"foreign": {
|
||||
"tbl": "prs_kostensoort",
|
||||
"key": "prs_kostensoort_key",
|
||||
"desc": "prs_kostensoort_opmerking"
|
||||
}
|
||||
},
|
||||
"limit": {
|
||||
"dbs": "bgt_budget_limiet",
|
||||
"label": L("bgt_budget_limiet"),
|
||||
"typ": "float",
|
||||
"iscurrency": "true",
|
||||
"required": true
|
||||
},
|
||||
"begin": {
|
||||
"dbs": "bgt_budget_begin",
|
||||
"label": L("bgt_budget_begin"),
|
||||
"typ": "date",
|
||||
"required": true
|
||||
},
|
||||
"end": {
|
||||
"dbs": "bgt_budget_eind",
|
||||
"label": L("bgt_budget_eind"),
|
||||
"typ": "date",
|
||||
"required": false
|
||||
},
|
||||
"costgroup": {
|
||||
"dbs": "prs_kostenplaatsgrp_key",
|
||||
"label": L("prs_kostenplaatsgrp_key"),
|
||||
"typ": "key",
|
||||
"foreign": {
|
||||
"tbl": "prs_kostenplaatsgrp",
|
||||
"key": "prs_kostenplaatsgrp_key",
|
||||
"desc": "prs_kostenplaatsgrp_oms"
|
||||
}
|
||||
},
|
||||
"account": {
|
||||
"dbs": "prs_kostenplaats_key",
|
||||
"label": L("prs_kostenplaats_key"),
|
||||
"typ": "key",
|
||||
"foreign": {
|
||||
"tbl": "prs_kostenplaats",
|
||||
"key": "prs_kostenplaats_key",
|
||||
"desc": "prs_kostenplaats_nr"
|
||||
}
|
||||
},
|
||||
"expirationdate": {
|
||||
"dbs": "bgt_budget_vervaldatum",
|
||||
"label": L("bgt_budget_vervaldatum"),
|
||||
"hidden_fld": true,
|
||||
"typ": "date"
|
||||
}
|
||||
};
|
||||
|
||||
this.edit = {
|
||||
"modal": true
|
||||
}
|
||||
|
||||
|
||||
this.REST_GET = generic_REST_GET(this);
|
||||
this.REST_POST = generic_REST_POST(this);
|
||||
this.REST_PUT = generic_REST_PUT(this);
|
||||
this.REST_DELETE = generic_REST_DELETE(this);
|
||||
}
|
||||
%>
|
||||
41
APPL/API2/model_bgt_disc_params.inc
Normal file
41
APPL/API2/model_bgt_disc_params.inc
Normal file
@@ -0,0 +1,41 @@
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
|
||||
File: model_bgt_disc_params.inc
|
||||
|
||||
Description: Vanuit CodeCharge gegenereerd model voor bgt_discipline
|
||||
|
||||
Context:
|
||||
|
||||
Notes: *uitsluitend* gebruikt als include van model_bgt_discipline
|
||||
*/
|
||||
%>
|
||||
<%
|
||||
model_bgt_disc_params =
|
||||
{
|
||||
"table": "bgt_disc_params",
|
||||
"primary": "bgt_disc_params_key",
|
||||
"records_name": "bgt_disc_params",
|
||||
"record_name": "bgt_disc_params",
|
||||
"autfunction": "WEB_BGTMAN",
|
||||
|
||||
|
||||
"fields": {
|
||||
"id": {
|
||||
"dbs": "bgt_disc_params_key",
|
||||
"label": "Key",
|
||||
"typ": "key",
|
||||
"seq": "bgt_s_bgt_disc_params_key"
|
||||
},
|
||||
"bgt_ins_discipline_key": {
|
||||
"dbs": "bgt_ins_discipline_key",
|
||||
"label": "Foreign key",
|
||||
"typ": "key",
|
||||
"hidden_fld": true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
api2.generic_REST(model_bgt_disc_params);
|
||||
%>
|
||||
89
APPL/API2/model_bgt_discipline.inc
Normal file
89
APPL/API2/model_bgt_discipline.inc
Normal file
@@ -0,0 +1,89 @@
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
|
||||
File: model_bgt_discipline.inc
|
||||
|
||||
Description: Model voor budget disciplines
|
||||
|
||||
Context:
|
||||
|
||||
Notes: intern hebben we een apart model voor bgt_disc_params
|
||||
Naar de buitenwereld presenteren we het als <20><>n model
|
||||
*/
|
||||
%>
|
||||
<!-- #include file="model_bgt_disc_params.inc" -->
|
||||
<%
|
||||
|
||||
function model_bgt_discipline(disc_key, params)
|
||||
{
|
||||
// E<>n model voor de buitenwereld
|
||||
var disc = new _model_bgt_discipline();
|
||||
api2.merge_disc_params_model(this, disc);
|
||||
|
||||
this.REST_GET = generic_REST_GET(disc, // Let op: de originele _model
|
||||
{ "GET": {
|
||||
wheres: [ "ins_tab_discipline.ins_discipline_module = 'BGT'"
|
||||
]
|
||||
}
|
||||
}
|
||||
)
|
||||
|
||||
this.REST_POST = generic_REST_POST(disc);
|
||||
this.REST_PUT = generic_REST_PUT(disc);
|
||||
this.REST_DELETE = generic_REST_DELETE(this, {});
|
||||
}
|
||||
|
||||
function _model_bgt_discipline()
|
||||
{
|
||||
this.table = "ins_tab_discipline";
|
||||
this.primary = "ins_discipline_key";
|
||||
this.records_name = "ins_tab_disciplines";
|
||||
this.record_name = "ins_tab_discipline";
|
||||
this.autfunction = "WEB_BGTMAN";
|
||||
this.record_title = L("bgt_discipline");
|
||||
this.records_title = L("bgt_discipline_m");
|
||||
|
||||
this.fields = {
|
||||
"id": {
|
||||
"dbs": "ins_discipline_key",
|
||||
"label": "Key",
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"filter": "exact",
|
||||
"seq": "ins_s_ins_discipline_key"
|
||||
},
|
||||
"module": {
|
||||
"dbs": "ins_discipline_module",
|
||||
"label": L("bgt_discipline_module"),
|
||||
"typ": "varchar",
|
||||
"hidden_fld": true,
|
||||
"defaultvalue": "BGT"
|
||||
},
|
||||
"name": {
|
||||
"dbs": "ins_discipline_omschrijving",
|
||||
"label": L("bgt_discipline_omschrijving"),
|
||||
"typ": "varchar",
|
||||
"translate": true,
|
||||
"required": true
|
||||
},
|
||||
"sequence": {
|
||||
"dbs": "ins_discipline_volgnr",
|
||||
"label": L("bgt_discipline_volgnr"),
|
||||
"typ": "number"
|
||||
},
|
||||
"vat": {
|
||||
"dbs": "ins_discipline_btw",
|
||||
"label": L("bgt_discipline_btw"),
|
||||
"typ": "check",
|
||||
"default": "false"
|
||||
}
|
||||
};
|
||||
/* Velden van BGT_DISC_PARAMS komen er dynamisch bij */
|
||||
this.disc_params = {
|
||||
model: model_bgt_disc_params,
|
||||
joinfield: "bgt_ins_discipline_key"
|
||||
};
|
||||
//this.soft_delete = "ins_discipline_verwijder"; // ik wil er iig niet standaard op kunnen filteren
|
||||
}
|
||||
%>
|
||||
67
APPL/API2/model_bgt_kostenrubriek.inc
Normal file
67
APPL/API2/model_bgt_kostenrubriek.inc
Normal file
@@ -0,0 +1,67 @@
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
|
||||
File: model_bgt_kostenrubriek.inc
|
||||
|
||||
Description: Vanuit CodeCharge gegenereerd model voor bgt_kostenrubriek
|
||||
|
||||
Context:
|
||||
|
||||
Notes:
|
||||
*/
|
||||
%>
|
||||
<!-- #include file="model_prs_kostensoortgrp.inc" -->
|
||||
<%
|
||||
|
||||
function model_bgt_kostenrubriek()
|
||||
{
|
||||
this.table = "bgt_kostenrubriek";
|
||||
this.primary = "bgt_kostenrubriek_key";
|
||||
this.records_name = "bgt_kostenrubrieks";
|
||||
this.record_name = "bgt_kostenrubriek";
|
||||
this.autfunction = "WEB_BGTMAN";
|
||||
this.record_title = L("bgt_kostenrubriek");
|
||||
this.records_title = L("bgt_kostenrubriek_m");
|
||||
|
||||
this.fields = {
|
||||
"id": {
|
||||
"dbs": "bgt_kostenrubriek_key",
|
||||
"label": "Key",
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"filter": "exact",
|
||||
"seq": "bgt_s_bgt_kostenrubriek_key"
|
||||
},
|
||||
"group": {
|
||||
"dbs" : "bgt_srtgroep_key",
|
||||
"label": L("bgt_srtgroep_omschrijving"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"foreign": {
|
||||
"tbl": "bgt_srtgroep",
|
||||
"key": "bgt_srtgroep_key",
|
||||
"desc": "bgt_srtgroep_omschrijving",
|
||||
"where": "bgt_srtgroep_verwijder IS NULL"
|
||||
}
|
||||
},
|
||||
"name": {
|
||||
"dbs": "bgt_kostenrubriek_oms",
|
||||
"label": L("bgt_kostenrubriek_oms"),
|
||||
"typ": "varchar",
|
||||
"required": true,
|
||||
"translate": true
|
||||
},
|
||||
"code": {
|
||||
"dbs": "bgt_kostenrubriek_code",
|
||||
"label": L("bgt_kostenrubriek_code"),
|
||||
"typ": "varchar"
|
||||
}
|
||||
};
|
||||
|
||||
this.REST_GET = generic_REST_GET(this);
|
||||
this.REST_POST = generic_REST_POST(this);
|
||||
this.REST_PUT = generic_REST_PUT(this);
|
||||
this.REST_DELETE = generic_REST_DELETE(this);
|
||||
}
|
||||
%>
|
||||
82
APPL/API2/model_bgt_srtgroep.inc
Normal file
82
APPL/API2/model_bgt_srtgroep.inc
Normal file
@@ -0,0 +1,82 @@
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
|
||||
File: model_bgt_srtgroep.inc
|
||||
|
||||
Description: Vanuit CodeCharge gegenereerd model voor bgt_srtgroep
|
||||
|
||||
Context:
|
||||
|
||||
Notes:
|
||||
*/
|
||||
%>
|
||||
<!-- #include file="../api2/model_bgt_kostenrubriek.inc" -->
|
||||
<%
|
||||
|
||||
function model_bgt_srtgroep()
|
||||
{
|
||||
this.table = "bgt_srtgroep";
|
||||
this.primary = "bgt_srtgroep_key";
|
||||
this.records_name = "bgt_srtgroeps";
|
||||
this.record_name = "bgt_srtgroep";
|
||||
this.soft_delete = "bgt_srtgroep_verwijder";
|
||||
this.autfunction = "WEB_BGTMAN";
|
||||
this.record_title = L("bgt_srtgroep");
|
||||
this.records_title = L("bgt_srtgroep_m");
|
||||
|
||||
|
||||
this.fields = {
|
||||
"id": {
|
||||
"dbs": "bgt_srtgroep_key",
|
||||
"label": "Key",
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"filter": "exact",
|
||||
"seq": "bgt_s_bgt_srtgroep_key",
|
||||
"defaultvalue": null
|
||||
},
|
||||
"catalog": {
|
||||
"dbs": "ins_discipline_key",
|
||||
"label": L("bgt_discipline_omschrijving"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"insert_only": true,
|
||||
"foreign": {
|
||||
"tbl": "ins_tab_discipline",
|
||||
"key": "ins_discipline_key",
|
||||
"desc": "ins_discipline_omschrijving",
|
||||
"where": "ins_discipline_module = 'BGT' AND ins_discipline_verwijder IS NULL"
|
||||
}
|
||||
},
|
||||
"name": {
|
||||
"dbs": "bgt_srtgroep_omschrijving",
|
||||
"label": L("bgt_srtgroep_omschrijving"),
|
||||
"typ": "varchar",
|
||||
"required": true,
|
||||
"translate": true
|
||||
},
|
||||
"code": {
|
||||
"dbs": "bgt_srtgroep_code",
|
||||
"label": L("bgt_srtgroep_code"),
|
||||
"typ": "varchar"
|
||||
},
|
||||
"sequence": {
|
||||
"dbs": "bgt_srtgroep_volgnr",
|
||||
"label": L("bgt_srtgroep_volgnr"),
|
||||
"typ": "number"
|
||||
}
|
||||
};
|
||||
|
||||
// if (!S("bgt_enabled"))
|
||||
// {
|
||||
// this.fields.catalog.hidden_fld = true
|
||||
// this.fields.catalog.default_value = 1
|
||||
// }
|
||||
|
||||
this.REST_GET = generic_REST_GET(this);
|
||||
this.REST_POST = generic_REST_POST(this);
|
||||
this.REST_PUT = generic_REST_PUT(this);
|
||||
this.REST_DELETE = generic_REST_DELETE(this);
|
||||
}
|
||||
%>
|
||||
@@ -11,6 +11,7 @@
|
||||
Notes:
|
||||
*/
|
||||
%>
|
||||
<!-- #include file="../api2/model_bgt_budget.inc" -->
|
||||
<%
|
||||
|
||||
function model_prs_kostensoort()
|
||||
@@ -34,29 +35,12 @@ function model_prs_kostensoort()
|
||||
"seq": "prs_s_prs_kostensoort_key"
|
||||
},
|
||||
"name": {
|
||||
"dbs": "prs_kostensoort_oms",
|
||||
"label": L("prs_kostensoort_oms"),
|
||||
"typ": "varchar",
|
||||
"filter": "like"
|
||||
},
|
||||
"altcode": {
|
||||
"dbs": "prs_kostensoort_altcode",
|
||||
"label": L("prs_kostensoort_altcode"),
|
||||
"typ": "varchar"
|
||||
},
|
||||
"description": {
|
||||
"dbs": "prs_kostensoort_opmerking",
|
||||
"label": L("prs_kostensoort_opmerking"),
|
||||
"typ": "varchar",
|
||||
"translate": true,
|
||||
"filter": "like"
|
||||
},
|
||||
"refcode": {
|
||||
"dbs": "prs_kostensoort_refcode",
|
||||
"label": L("prs_kostensoort_refcode"),
|
||||
"typ": "varchar",
|
||||
"translate": true
|
||||
},
|
||||
"group": {
|
||||
"dbs": "prs_kostensoortgrp_key",
|
||||
"label": L("prs_kostensoortgrp_key"),
|
||||
@@ -69,6 +53,26 @@ function model_prs_kostensoort()
|
||||
"LOVinit": "",
|
||||
"filter": "exact"
|
||||
},
|
||||
"code": {
|
||||
"dbs": "prs_kostensoort_oms",
|
||||
"label": L("prs_kostensoort_oms"),
|
||||
"typ": "varchar",
|
||||
"required": true,
|
||||
"filter": "like"
|
||||
},
|
||||
"altcode": {
|
||||
"dbs": "prs_kostensoort_altcode",
|
||||
"label": L("prs_kostensoort_altcode"),
|
||||
"typ": "varchar"
|
||||
},
|
||||
|
||||
"refcode": {
|
||||
"dbs": "prs_kostensoort_refcode",
|
||||
"label": L("prs_kostensoort_refcode"),
|
||||
"typ": "varchar",
|
||||
"translate": true
|
||||
},
|
||||
|
||||
"charge": {
|
||||
"dbs": "prs_kostensoort_doorbelasten",
|
||||
"label": L("prs_kostensoort_doorbelasten"),
|
||||
@@ -91,6 +95,13 @@ function model_prs_kostensoort()
|
||||
}
|
||||
};
|
||||
|
||||
this.includes = {
|
||||
"budget": {
|
||||
"model": new model_bgt_budget(),
|
||||
"joinfield": "cost_category",
|
||||
"enable_update": true
|
||||
}
|
||||
};
|
||||
|
||||
this.REST_GET = generic_REST_GET(this);
|
||||
this.REST_POST = generic_REST_POST(this);
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
Notes:
|
||||
*/
|
||||
%>
|
||||
<!-- #include file="../api2/model_prs_kostensoort.inc" -->
|
||||
<%
|
||||
|
||||
function model_prs_kostensoortgrp()
|
||||
@@ -41,6 +42,17 @@ function model_prs_kostensoortgrp()
|
||||
"required": true,
|
||||
"filter": "like"
|
||||
},
|
||||
"rubriek": {
|
||||
"dbs" : "bgt_kostenrubriek_key",
|
||||
"label": L("bgt_kostenrubriek"),
|
||||
"typ": "key",
|
||||
"required": true,
|
||||
"foreign": {
|
||||
"tbl": "bgt_kostenrubriek",
|
||||
"key": "bgt_kostenrubriek_key",
|
||||
"desc": "bgt_kostenrubriek_oms"
|
||||
}
|
||||
},
|
||||
"altcode": {
|
||||
"dbs": "prs_kostensoortgrp_altcode",
|
||||
"label": L("prs_kostensoortgrp_altcode"),
|
||||
@@ -49,7 +61,6 @@ function model_prs_kostensoortgrp()
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
this.REST_GET = generic_REST_GET(this);
|
||||
this.REST_POST = generic_REST_POST(this);
|
||||
this.REST_PUT = generic_REST_PUT(this);
|
||||
|
||||
153
APPL/BGT/bgt_search.asp
Normal file
153
APPL/BGT/bgt_search.asp
Normal file
@@ -0,0 +1,153 @@
|
||||
<%@language = "javascript" %>
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
File: mjb/mjb_search.asp
|
||||
Description: Menuoptie BGT Totaaloverzicht
|
||||
Parameters:
|
||||
Context:
|
||||
Note: OPZET UNDER CONSTRUCTION
|
||||
|
||||
@todo
|
||||
- project (dis_key) is vereist
|
||||
- deelproject (bgt_srtgroep) is optioneel. Indien gegeven dan niet muteerbaar getoond, anders te kiezen default leeg
|
||||
- zoektekst zoekt fuzzy door vanalles, zoveel als dat er tijd voor is
|
||||
- groepering kan als groupby ook optioneel worden meegegeven
|
||||
|
||||
|
||||
*/ %>
|
||||
<!-- #include file="../Shared/common.inc" -->
|
||||
<!-- #include file="../Shared/iface.inc" -->
|
||||
<!-- #include file="../Shared/selector.inc" -->
|
||||
|
||||
<!-- #include file="../Shared/disciplineselector.inc" -->
|
||||
<!-- #include file="../Shared/srtgroepselector.inc" -->
|
||||
<!-- #include file="../Shared/srtdeelselector.inc" -->
|
||||
<%
|
||||
|
||||
FCLTHeader.Requires({ plugins:["suggest", "jQuery"],
|
||||
js: [ "jQuery-ui.js"]
|
||||
});
|
||||
|
||||
/***** Get webform parameters *****/
|
||||
var autosearch = getQParamInt("autosearch", 0) == 1;
|
||||
|
||||
var groep = getQParam("groep", ""); // Categorie/Groep
|
||||
if (groep == -1) groep = "";
|
||||
var bgtdisc_key = getQParamInt("dis_key"); // Discipline initialisatie
|
||||
var srtgroep = getQParamInt("srtgroep", -1); // Groep
|
||||
|
||||
|
||||
/*if (bgtdisc_key <= 0) // Als er maar eentje is selecteer die automatisch
|
||||
{
|
||||
var sql = "SELECT ins_discipline_key"
|
||||
+ " FROM bgt_disc_params cdp, bgt_discipline cd"
|
||||
+ " WHERE cdp.ctr_ins_discipline_key = cd.ins_discipline_key"
|
||||
+ " AND cd.ins_discipline_verwijder IS NULL"
|
||||
+ " AND cdp.ctr_disc_params_ismjob = 1";
|
||||
var oRs = Oracle.Execute(sql);
|
||||
if (!oRs.Eof)
|
||||
{
|
||||
var key = oRs("ins_discipline_key").Value;
|
||||
oRs.MoveNext();
|
||||
if (oRs.Eof)
|
||||
bgtdisc_key = key;
|
||||
}
|
||||
oRs.Close();
|
||||
}
|
||||
*/
|
||||
if (bgtdisc_key > 0)
|
||||
lcl.set_dialect(bgtdisc_key, "INS_TAB_DISCIPLINE_KEY");
|
||||
|
||||
var autfunctionBGTUSE = "WEB_BGTUSE";
|
||||
var authparamsBGTUSE = user.checkAutorisation("WEB_BGTUSE");
|
||||
|
||||
%>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<% FCLTHeader.Generate(); %>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
function doSubmit()
|
||||
{
|
||||
document.forms.u2.submit();
|
||||
}
|
||||
<% if (autosearch) { %>
|
||||
$(document).ready(function() { doSubmit(); });
|
||||
<%}%>
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body id="searchbody">
|
||||
<div id="search">
|
||||
<form name="u2" target="workFrame" action="bgt_search_list.asp" method="get">
|
||||
|
||||
<input type=hidden name="autfunctionBGTUSE" id="autfunctionBGTUSE" value="<%=autfunctionBGTUSE%>">
|
||||
<input type=hidden name="dis_key" value="<%=bgtdisc_key%>">
|
||||
|
||||
<% BLOCK_START("searchtable", L("lcl_filterblok"));%>
|
||||
<tr>
|
||||
<td class="searchkolom1"><!-- start column 1 -->
|
||||
<table><!-- x rijen, 2 kolommen: label + veld -->
|
||||
<!-- Object -->
|
||||
<tr class="primsearch">
|
||||
<td class="label"><label for="search"><%=L("lcl_search")%>:</label></td>
|
||||
<td><input type="text" class="fldseaerch" name="search" value=""></td>
|
||||
</tr>
|
||||
<%
|
||||
// Soort groep
|
||||
FCLTsrtgroepselector("srtgroep",
|
||||
"sgSrtgroep",
|
||||
{ label: L("bgt_srtgroep_omschrijving"),
|
||||
srtgroep_key: srtgroep,
|
||||
autfunction: autfunctionBGTUSE,
|
||||
trclass: "primsearch noxd",
|
||||
whenEmpty: L("lcl_search_generic")
|
||||
});
|
||||
|
||||
|
||||
|
||||
%>
|
||||
</table>
|
||||
</td><!-- end column 1 -->
|
||||
|
||||
<!-- Second column -->
|
||||
<td valign=top>
|
||||
<table><!-- x rijen, 2 kolommen: label + veld -->
|
||||
<% sql = "SELECT 1, " + safe.qL("bgt_srtgroep_omschrijving") + ", 1 FROM DUAL"
|
||||
+ " UNION SELECT 2, " + safe.qL("bgt_kostenrubriek_oms") + ", 2 FROM DUAL"
|
||||
+ " UNION SELECT 3, " + safe.qL("bgt_srtgroep_omschrijving") + ", 3 FROM DUAL"
|
||||
+ " UNION SELECT 4, " + safe.qL("prs_kostensoort_opmerking") + ", 4 FROM DUAL"
|
||||
+ " UNION SELECT 5, " + safe.qL("bgt_opdrachten") + ", 5 FROM DUAL"
|
||||
+ " UNION SELECT 6, " + safe.qL("bgt_facturen") + ", 6 FROM DUAL";
|
||||
|
||||
|
||||
FCLTselector("groupby",
|
||||
sql,
|
||||
{ label: L("lcl_mjb_group")
|
||||
});
|
||||
%> </table>
|
||||
</td><!-- end column 2-->
|
||||
</tr>
|
||||
|
||||
<% BLOCK_END();
|
||||
var buttons = [{title: L("lcl_search"), action: "doSubmit()" }];
|
||||
CreateButtons(buttons, { entersubmit: true} );
|
||||
%>
|
||||
</form>
|
||||
|
||||
</div><!--search-->
|
||||
|
||||
<div id="result">
|
||||
<iframe width="100%" height="100%"
|
||||
src="../Shared/empty.asp"
|
||||
name="workFrame" id="workFrame"
|
||||
onload='FcltMgr.iframeLoaded(this)'
|
||||
frameborder="0" scrolling="no">
|
||||
</iframe>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
137
APPL/BGT/bgt_search_list.asp
Normal file
137
APPL/BGT/bgt_search_list.asp
Normal file
@@ -0,0 +1,137 @@
|
||||
<%@language = "javascript" %>
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
|
||||
File: bgt_search_list.asp
|
||||
Description:
|
||||
Parameters:
|
||||
|
||||
Context:
|
||||
|
||||
Note: UNDER CONSTRUCTION
|
||||
|
||||
|
||||
- actions op kolommen:
|
||||
- budget > budgetmutaties (tbd)
|
||||
- opdrachten > naar opdrachtnen bij deze kostensoort
|
||||
- facturen > naar facturen van (opdrachten van) deze kostensoort
|
||||
|
||||
- totaalregel moet totaaltelling geven
|
||||
|
||||
- groepering is leuk stukje
|
||||
|
||||
*/ %>
|
||||
<!-- #include file="../Shared/common.inc" -->
|
||||
<!-- #include file="../Shared/resultset_table_v2.inc" -->
|
||||
<!-- #include file="../Shared/json2.js" -->
|
||||
|
||||
<%
|
||||
FCLTHeader.Requires({plugins: ["jQuery"]});
|
||||
|
||||
|
||||
|
||||
// FORM parameters: de waarde indien aanwezig, anders null
|
||||
// Vaak is een lege selectie ook een -1, dus dan is-ie wel aanwezig, maar hoeft niet
|
||||
// als filter te worden toegepast. Dan is null dus gelijk aan -1, qua betekenis,
|
||||
// Vandaar dat een default van -1 ipv null ook mag
|
||||
// In eerste instantie identificeren we elk veld gewoon 1-op-1.
|
||||
var outputmode = getQParamInt("outputmode", 0); // 0 = screen, 1 = print, 2 = excel etc
|
||||
var print = (outputmode == 1 || outputmode == 5);
|
||||
var excel = (outputmode == 2 || outputmode == 6);
|
||||
|
||||
|
||||
var bgtdisc_key = getQParamInt("dis_key"); // bgt discipline is echt vereist
|
||||
var bgt_srtgroep_key = getQParamInt("srtgroep_key", -1);
|
||||
if (bgtdisc_key > 0)
|
||||
lcl.set_dialect(bgtdisc_key, "INS_TAB_DISCIPLINE_KEY");
|
||||
|
||||
var params = { };
|
||||
var transitParam = buildTransitParam([]);
|
||||
%>
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<%
|
||||
FCLTHeader.Generate({ outputmode: outputmode });
|
||||
%>
|
||||
</head>
|
||||
<body id="listbody">
|
||||
<%
|
||||
|
||||
// zoiets moet het dan gaan worden. Vast nog wat verfijnder. UNIONs met reserve e.d. nodig?
|
||||
var sql = "SELECT "
|
||||
+ " kr.bgt_kostenrubriek_oms rubriek, "
|
||||
+ " ksg.prs_kostensoortgrp_oms groep, "
|
||||
+ " ks.prs_kostensoort_opmerking onderdeel, "
|
||||
+ " bud.bgt_budget_limiet budget, "
|
||||
+ " SUM (o.mld_opdr_kosten) gecontracteerd, "
|
||||
+ " bud.bgt_budget_limiet - SUM (o.mld_opdr_kosten) tecontracteren, "
|
||||
+ " SUM (f.fin_factuur_totaal) gefactureerd, "
|
||||
+ " SUM (o.mld_opdr_kosten) - SUM (f.fin_factuur_totaal) tefactureren, "
|
||||
+ " bgt_budget_key,"
|
||||
+ " bgt_srtgroep_omschrijving deelproject,"
|
||||
+ " ins_discipline_omschrijving project"
|
||||
+ " FROM mld_opdr o, "
|
||||
+ " prs_kostensoort ks, "
|
||||
+ " prs_kostensoortgrp ksg, "
|
||||
+ " bgt_kostenrubriek kr, "
|
||||
+ " bgt_budget bud, "
|
||||
+ " bgt_srtgroep sg, "
|
||||
+ " ins_tab_discipline id, "
|
||||
+ " fin_factuur f "
|
||||
+ " WHERE o.prs_kostensoort_key(+) = ks.prs_kostensoort_key "
|
||||
+ " AND ksg.bgt_kostenrubriek_key = kr.bgt_kostenrubriek_key "
|
||||
+ " AND ks.prs_kostensoort_key(+) = bud.prs_kostensoort_key "
|
||||
+ " AND sg.bgt_srtgroep_key = kr.bgt_srtgroep_key "
|
||||
+ " AND ksg.prs_kostensoortgrp_key(+) = ks.prs_kostensoortgrp_key "
|
||||
+ " AND f.mld_opdr_key(+) = o.mld_opdr_key "
|
||||
+ " AND id.ins_discipline_key = sg.ins_discipline_key "
|
||||
+ " AND sg.ins_discipline_key = " + bgtdisc_key
|
||||
+ " GROUP BY bgt_kostenrubriek_oms, "
|
||||
+ " prs_kostensoortgrp_oms, "
|
||||
+ " prs_kostensoort_opmerking, "
|
||||
+ " bgt_budget_limiet , "
|
||||
+ " bgt_budget_key , "
|
||||
+ " bgt_srtgroep_omschrijving , "
|
||||
+ " ins_discipline_omschrijving "
|
||||
+ " ORDER BY kr.bgt_kostenrubriek_oms, "
|
||||
+ " ksg.prs_kostensoortgrp_oms, "
|
||||
+ " ks.prs_kostensoort_opmerking ";
|
||||
|
||||
var buttons = [];
|
||||
buttons.push({ icon: "page_refresh.png", title: L("lcl_refresh"), action: "FcltMgr.reload()" });
|
||||
|
||||
|
||||
var rst = new ResultsetTable({ keyColumn: "bgt_budget_key", //fnkeyFunction,
|
||||
sql: sql,
|
||||
ID: "bgttable",
|
||||
//rowData: fnrowData,
|
||||
//rowClass: fnrowClass,
|
||||
//suppressKeyRepeat: "deelproject",
|
||||
//rowActionEnabler: fnrowActionEnabler,
|
||||
//totalShow: true,
|
||||
//filterParams: params,
|
||||
outputmode: outputmode,
|
||||
title: L("bgt_totaaloverzicht"),
|
||||
showAll: true,
|
||||
buttons: buttons
|
||||
});
|
||||
// negatieve getallen .negative maken
|
||||
|
||||
rst.addColumn(new Column({caption: L("bgt_discipline_omschrijving"), content: "project", purpose: (bgtdisc_key>-1 ? PRINTING_ONLY : PRINT_AND_VIEW)}));
|
||||
rst.addColumn(new Column({caption: L("bgt_srtgroep_omschrijving"), content: "deelproject", purpose: (bgt_srtgroep_key>-1 ? PRINTING_ONLY : PRINT_AND_VIEW)}));
|
||||
rst.addColumn(new Column({caption: L("bgt_kostenrubriek_oms"), content: "rubriek"}));
|
||||
rst.addColumn(new Column({caption: L("bgt_srtgroep_omschrijving"), content: "groep"}));
|
||||
rst.addColumn(new Column({caption: L("prs_kostensoort_opmerking"), content: "onderdeel"}));
|
||||
rst.addColumn(new Column({caption: L("bgt_budget_limiet"), content: "budget", datatype: "currency", total: true}));
|
||||
rst.addColumn(new Column({caption: L("bgt_opdrachten"), content: "gecontracteerd", datatype: "currency", total: true }));
|
||||
rst.addColumn(new Column({caption: L("bgt_opdrachtentogo"), content: "tecontracteren", datatype: "currency", total: true }));
|
||||
rst.addColumn(new Column({caption: L("bgt_facturen"), content: "gefactureerd", datatype: "currency", total: true }));
|
||||
rst.addColumn(new Column({caption: L("bgt_facturentogo"), content: "tefactureren", datatype: "currency", total: true }));
|
||||
|
||||
var count = rst.processResultset();
|
||||
|
||||
%>
|
||||
</body>
|
||||
</html>
|
||||
31
APPL/MGT/bgt_budget.asp
Normal file
31
APPL/MGT/bgt_budget.asp
Normal file
@@ -0,0 +1,31 @@
|
||||
<%@language = "javascript" %>
|
||||
|
||||
<!-- #include file="../scf/scaffolding.inc" -->
|
||||
<!-- #include file="../api2/model_bgt_budget.inc" -->
|
||||
|
||||
<%
|
||||
var this_model = new model_bgt_budget();
|
||||
|
||||
scaffolding(this_model,
|
||||
{
|
||||
"search": {
|
||||
"autosearch": true,
|
||||
"filters": [
|
||||
"catalog",
|
||||
"group",
|
||||
"cost_category"
|
||||
]
|
||||
},
|
||||
"list": {
|
||||
"columns": [
|
||||
"costcategory",
|
||||
"costtypegroup",
|
||||
"cost_category",
|
||||
"limit"
|
||||
]
|
||||
},
|
||||
"edit":{
|
||||
"modal": true
|
||||
}
|
||||
});
|
||||
%>
|
||||
55
APPL/MGT/bgt_discipline.asp
Normal file
55
APPL/MGT/bgt_discipline.asp
Normal file
@@ -0,0 +1,55 @@
|
||||
<%@language = "javascript" %>
|
||||
<% /*
|
||||
$Revision$
|
||||
$Id$
|
||||
|
||||
File: bgt_discipline.asp
|
||||
|
||||
Description: fac_management aanroep van model_bgt_discipline
|
||||
|
||||
Context:
|
||||
|
||||
Notes:
|
||||
*/
|
||||
%>
|
||||
<!-- #include file="../scf/scaffolding.inc" -->
|
||||
<!-- #include file="../mgt/mgt_tools.inc" -->
|
||||
<!-- #include file="../api2/model_bgt_discipline.inc" -->
|
||||
<%
|
||||
var this_model = new model_bgt_discipline();
|
||||
|
||||
scaffolding(this_model,
|
||||
{
|
||||
"search": {
|
||||
"autosearch": true
|
||||
},
|
||||
"list": {
|
||||
"columns": [
|
||||
//"id",
|
||||
"sequence",
|
||||
"name",
|
||||
"vat"
|
||||
]
|
||||
},
|
||||
"show": {
|
||||
"requires": {
|
||||
"js": ["./mgt_tools.js"]
|
||||
},
|
||||
"buttons": [
|
||||
{
|
||||
"title": L("lcl_lcl_terminologie"),
|
||||
"action": "edit_terminologie",
|
||||
"icon": "doc_text_image.png"
|
||||
}
|
||||
]
|
||||
},
|
||||
"wrap": {
|
||||
"frames": [{ url: "bgt_srtgroep.asp?mode=list&ins_discipline={0}",
|
||||
autfunction: "WEB_BGTMAN"
|
||||
},
|
||||
{ url: "fac_functie.asp?mode=list&ins_discipline={0}",
|
||||
autfunction: "WEB_PRSSYS"
|
||||
}]
|
||||
}
|
||||
});
|
||||
%>
|
||||
29
APPL/MGT/bgt_kostenrubriek.asp
Normal file
29
APPL/MGT/bgt_kostenrubriek.asp
Normal file
@@ -0,0 +1,29 @@
|
||||
<%@language = "javascript" %>
|
||||
|
||||
<!-- #include file="../scf/scaffolding.inc" -->
|
||||
<!-- #include file="../api2/model_bgt_kostenrubriek.inc" -->
|
||||
|
||||
<%
|
||||
var this_model = new model_bgt_kostenrubriek();
|
||||
|
||||
scaffolding(this_model,
|
||||
{
|
||||
"search": {
|
||||
"autosearch": true,
|
||||
"filters": [
|
||||
"name"
|
||||
]
|
||||
},
|
||||
"list": {
|
||||
"columns": [
|
||||
"name",
|
||||
"code"
|
||||
]
|
||||
},
|
||||
"wrap": {
|
||||
"frames": [{ url: "prs_kostensoortgrp.asp?mode=list&rubriek={0}",
|
||||
autfunction: "WEB_FINMSU"
|
||||
}]
|
||||
}
|
||||
});
|
||||
%>
|
||||
33
APPL/MGT/bgt_srtgroep.asp
Normal file
33
APPL/MGT/bgt_srtgroep.asp
Normal file
@@ -0,0 +1,33 @@
|
||||
<%@language = "javascript" %>
|
||||
|
||||
<!-- #include file="../scf/scaffolding.inc" -->
|
||||
<!-- #include file="../api2/model_bgt_srtgroep.inc" -->
|
||||
|
||||
<%
|
||||
var this_model = new model_bgt_srtgroep();
|
||||
|
||||
scaffolding(this_model,
|
||||
{
|
||||
"search": {
|
||||
"autosearch": true,
|
||||
"filters": [
|
||||
"catalog",
|
||||
"name"
|
||||
]
|
||||
},
|
||||
"list": {
|
||||
"columns": [
|
||||
//"id",
|
||||
"catalog",
|
||||
"name",
|
||||
"sequence"
|
||||
]
|
||||
},
|
||||
"wrap": {
|
||||
"frames": [{ url: "bgt_kostenrubriek.asp?mode=list&bgt_srtgroep={0}",
|
||||
autfunction: "WEB_BGTUSE"
|
||||
}]
|
||||
}
|
||||
|
||||
});
|
||||
%>
|
||||
33
APPL/MGT/bgt_srtgroep_budgetcontrol.asp
Normal file
33
APPL/MGT/bgt_srtgroep_budgetcontrol.asp
Normal file
@@ -0,0 +1,33 @@
|
||||
<%@language = "javascript" %>
|
||||
|
||||
<!-- #include file="../scf/scaffolding.inc" -->
|
||||
<!-- #include file="../api2/model_bgt_srtgroep.inc" -->
|
||||
|
||||
<%
|
||||
var this_model = new model_bgt_srtgroep();
|
||||
|
||||
scaffolding(this_model,
|
||||
{
|
||||
"search": {
|
||||
"autosearch": true,
|
||||
"filters": [
|
||||
"catalog",
|
||||
"name"
|
||||
]
|
||||
},
|
||||
"list": {
|
||||
"columns": [
|
||||
//"id",
|
||||
"catalog",
|
||||
"name",
|
||||
"sequence"
|
||||
]
|
||||
},
|
||||
"wrap": {
|
||||
"frames": [{ url: "bgt_budgetconsole.asp?mode=list&bgt_srtgroep={0}",
|
||||
autfunction: "WEB_BGTUSE"
|
||||
}]
|
||||
}
|
||||
|
||||
});
|
||||
%>
|
||||
@@ -22,22 +22,21 @@ scaffolding(this_model,
|
||||
"search": {
|
||||
"autosearch": true,
|
||||
"filters": [
|
||||
"description",
|
||||
"group",
|
||||
"name",
|
||||
"group"
|
||||
"code"
|
||||
]
|
||||
},
|
||||
"list": {
|
||||
"columns": [
|
||||
"id",
|
||||
"group",
|
||||
"name",
|
||||
"description",
|
||||
"refcode",
|
||||
"group"
|
||||
"code",
|
||||
"refcode"
|
||||
]
|
||||
},
|
||||
"edit":{
|
||||
"modal": true
|
||||
"xxxmodal": true
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
@@ -22,18 +22,21 @@ scaffolding(this_model,
|
||||
"search": {
|
||||
"autosearch": true,
|
||||
"filters": [
|
||||
"name"
|
||||
"name",
|
||||
"rubriek"
|
||||
]
|
||||
},
|
||||
"list": {
|
||||
"columns": [
|
||||
"id",
|
||||
"rubriek",
|
||||
"name",
|
||||
"altcode"
|
||||
]
|
||||
},
|
||||
"edit":{
|
||||
"modal": true
|
||||
"wrap": {
|
||||
"frames": [{ url: "prs_kostensoort.asp?mode=list&group={0}",
|
||||
autfunction: "WEB_FINMSU"
|
||||
}]
|
||||
}
|
||||
});
|
||||
%>
|
||||
Reference in New Issue
Block a user