DJIN#53091 Dropdown object koppelen aan standaardmelding toont verwijderde disciplines
svn path=/Website/branches/v2017.3/; revision=37801
This commit is contained in:
@@ -22,6 +22,7 @@ function model_companies()
|
||||
this.primary = "prs_bedrijf_key";
|
||||
this.records_name = "companies";
|
||||
this.record_name = "company";
|
||||
this.autfunction = "WEB_PROFIL"; // we controleren zelf
|
||||
|
||||
|
||||
this.fields = {
|
||||
@@ -59,7 +60,8 @@ function model_companies()
|
||||
this.includes = {
|
||||
"custom_fields" : {
|
||||
"model": new model_custom_fields(this, new model_prs_kenmerk("B", { internal: true }), { readman: true, readuse: true, pNiveau: "B" }),
|
||||
"joinfield": "flexparentkey"
|
||||
"joinfield": "flexparentkey",
|
||||
"enable_update": true
|
||||
}
|
||||
};
|
||||
|
||||
@@ -88,12 +90,8 @@ function model_companies()
|
||||
|
||||
return json;
|
||||
};
|
||||
this.PUT = function (params) /* update company */
|
||||
{
|
||||
};
|
||||
this.POST = function (params) /* new company */
|
||||
{
|
||||
};
|
||||
this.REST_PUT = generic_REST_PUT(this);
|
||||
this.REST_POST = generic_REST_POST(this);
|
||||
this.DELETE = function (params) /* delete company */
|
||||
{
|
||||
};
|
||||
|
||||
@@ -10,13 +10,18 @@ function init_srtinstallatie()
|
||||
|
||||
var srtinstallatie_key = $("#objectkey").val();
|
||||
if (!srtinstallatie_key)
|
||||
{
|
||||
fill_discipline(-1);
|
||||
change_object_discipline(); // Initialisatie listboxen bij search.
|
||||
}
|
||||
else
|
||||
{
|
||||
var discipline_key = $("#objectdiscipline").val();
|
||||
var srtgroep_key = $("#objectgroup").val();
|
||||
var srtdeel_key = $("#objecttype").val();
|
||||
var niveau = $("#level").val();
|
||||
|
||||
fill_discipline(discipline_key);
|
||||
if (niveau == "D")
|
||||
{
|
||||
fill_srtgroep(discipline_key);
|
||||
@@ -53,6 +58,18 @@ function change_object_group(srtdeel_key)
|
||||
fill_srtdeel(discipline_key, srtgroep_key);
|
||||
}
|
||||
|
||||
function fill_discipline(discipline_key)
|
||||
{
|
||||
$.getJSON("../ins/get_ins_info_ajax.asp",
|
||||
{ req_info: "ins_srtinstallatie",
|
||||
niveau: "D",
|
||||
install_key: -1,
|
||||
init_key: discipline_key,
|
||||
available: srtinstallatieselector_available
|
||||
},
|
||||
process_info);
|
||||
}
|
||||
|
||||
function fill_srtgroep(discipline_key, srtgroep_key)
|
||||
{
|
||||
if (discipline_key > 0)
|
||||
@@ -85,7 +102,13 @@ function fill_srtdeel(discipline_key, srtgroep_key, srtdeel_key)
|
||||
|
||||
function process_info(data)
|
||||
{
|
||||
var select = (data.niveau=="G" ? $("#objectgroup") : $("#objecttype"));
|
||||
var select = null;
|
||||
switch(data.niveau)
|
||||
{
|
||||
case "D": select = $("#objectdiscipline"); break;
|
||||
case "G": select = $("#objectgroup"); break;
|
||||
case "S": select = $("#objecttype"); break;
|
||||
}
|
||||
|
||||
var sel_key = -1;
|
||||
var new_lov = '<option value="-1" ></option>';
|
||||
|
||||
Reference in New Issue
Block a user