<%@language = "javascript" %>

<!-- #include file="../scf/scaffolding.inc" -->
<!-- #include file="../api2/model_res_discipline.inc" -->

<%
    var disc_key = getQParamInt("id", getQParamInt("ins_discipline", -1)); // TODO: Dit moet beter
    var model = new model_res_discipline(disc_key);

    var scf_params =
        {
            "search": {
                "autosearch": true,
                "filters": [
                    "scope",
                    "costtype",
                    "name"
                    ],
                "transit": [
                    "scope",
                    "costtype"
                ]
            },
            "list": {
                "columns": [
                    "id",
                    "scope",
                    "name",
                    "costtype",
                    "sequence"
                ]
            },
            "edit": {
                "requires": {
                    js: ["./ins_discipline.js"]
                }
            },
            "layout": {
                "block": [
                    {
                        "icon": "fa-book-open",
                        "label": L("res_discipline")
                    },
                    {
                        "icon": "fa-books-medical",
                        "label": L("lcl_prs_details")
                    }
                ]
            },
            "wrap": {
                "frames": [
                    {
                        url: "fac_functie.asp?mode=list&ins_discipline={0}",
                        title: L("fac_functie_m"),
                        autfunction: "WEB_PRSSYS"
                    }
                ]
            },
            "multicolumn": true
        }

    scaffolding(model, scf_params);

%>
<% ASPPAGE_END(); %>
