FCLT#76580 _INIT > INI

svn path=/Database/trunk/; revision=64311
This commit is contained in:
Peter Feij
2024-04-18 13:04:51 +00:00
parent 00f954443a
commit 78cebc293b
2 changed files with 0 additions and 0 deletions

715
INI/FMIS/fmis_ini.sql Normal file
View File

@@ -0,0 +1,715 @@
--
-- $Id$
--
-- Script bevat initiele configuratie voor een standaard FM inrichting
-- gebaseerd op DB48
--
-- Volgende iteratie naar Onderdeel van de core
DEFINE thisfile = 'fmis.sql'
DEFINE dbuser = '^'
SET ECHO ON
SET DEFINE ON
COLUMN fcltlogfile NEW_VALUE fcltlogfile NOPRINT;
COLUMN fcltcusttxt NEW_VALUE fcltcusttxt NOPRINT;
WHENEVER SQLERROR CONTINUE;
SELECT adm.getscriptspoolfile('&thisfile') AS fcltlogfile FROM DUAL;
SPOOL &fcltlogfile
WHENEVER SQLERROR EXIT;
SELECT adm.checkscriptcust('&dbuser') AS fcltcusttxt FROM DUAL;
WHENEVER SQLERROR CONTINUE;
---------------------------------------
PROMPT &fcltcusttxt
---------------------------------------
SET DEFINE OFF
------ payload begin ------
-- TODO: controle of deze al eens gerund heeft?
-- Some temporary tooling for this script
-- Will be destrouyed after the script has been run
CREATE PACKAGE tmp_fmis_ini AS
FUNCTION getImportKey (p_import_app_code VARCHAR2)
RETURN NUMBER;
END tmp_fmis_ini;
/
CREATE PACKAGE BODY tmp_fmis_ini AS
-- Functie om voor iedere importfunctie een nieuwe importkey te genereren.
FUNCTION getImportKey (p_import_app_code VARCHAR2)
RETURN NUMBER
AS
v_import_key NUMBER;
v_import_app_key NUMBER;
BEGIN
SELECT fac_import_app_key
INTO v_import_app_key
FROM fac_import_app
WHERE fac_import_app_code = UPPER(p_import_app_code);
INSERT INTO fac_import (fac_import_app_key, fac_import_datum_gelezen)
VALUES (v_import_app_key, SYSDATE)
RETURNING fac_import_key INTO v_import_key;
RETURN v_import_key;
END;
END tmp_fmis_ini;
/
-- End of temporary tooling
-- Moeten wij dit doen (FMIS) of is er nog een neutrale init.sql die wat config doet na de crea?
UPDATE fac_version SET fac_version_cust = UPPER(user), fac_version_otap = NULL WHERE fac_version_cust IS NULL;
-- BASISCONFIG PER MODULE
-- 1. ALG
-- Gebouwfuncties en ruimtefuncties
INSERT INTO alg_srtgebouw(alg_srtgebouw_omschrijving, alg_srtgebouw_passief) VALUES ('Kantoor', 0);
INSERT INTO alg_srtgebouw(alg_srtgebouw_omschrijving, alg_srtgebouw_passief) VALUES ('Opslag/Magazijn', 1);
INSERT INTO alg_srtgebouw(alg_srtgebouw_omschrijving, alg_srtgebouw_passief) VALUES ('Woning', 0);
INSERT INTO alg_srtgebouw(alg_srtgebouw_omschrijving, alg_srtgebouw_passief) VALUES ('Werkplaats', 0);
INSERT INTO alg_srtterreinsector(alg_srtterreinsec_omschrijving) VALUES ('Parkeerterrein');
INSERT INTO alg_srtterreinsector(alg_srtterreinsec_omschrijving) VALUES ('Groenvoorziening');
INSERT INTO alg_srtruimte(alg_srtruimte_omschrijving, prs_bevat_werkplek, prs_verhuurbaar) VALUES ('Kantoorruimte', 1, 1);
INSERT INTO alg_srtruimte(alg_srtruimte_omschrijving, prs_bevat_werkplek, prs_verhuurbaar) VALUES ('Technische ruimte', NULL, NULL);
INSERT INTO alg_srtruimte(alg_srtruimte_omschrijving, prs_bevat_werkplek, prs_verhuurbaar) VALUES ('Opslag/Magazijn', NULL, 1);
INSERT INTO alg_srtruimte(alg_srtruimte_omschrijving, prs_bevat_werkplek, prs_verhuurbaar) VALUES ('Verkeersruimte', NULL, 1);
INSERT INTO alg_srtruimte(alg_srtruimte_omschrijving, prs_bevat_werkplek, prs_verhuurbaar) VALUES ('Sanitairruimte', NULL, NULL);
-- 2. INS
-- Maak het vakgroeptype aan.
INSERT INTO ins_srtdiscipline ( ins_srtdiscipline_module, ins_srtdiscipline_omschrijving, ins_srtdiscipline_prefix, ins_srtdiscipline_kostenklant)
SELECT * FROM (
SELECT 'INS', 'Facilitaire objecten', 'F', 2 FROM DUAL UNION ALL
SELECT 'INS', 'Gebouwgebonden objecten', 'G', 2 FROM DUAL UNION ALL
SELECT 'INS', 'ICT objecten', 'I', 2 FROM DUAL UNION ALL
SELECT 'INS', 'Parkeerplaatsen', 'P', 2 FROM DUAL
);
-- Vakgroepen
-- Leidraad is: is het aannemelijk dat daar andere personen (backoffice, autorisaties) over gaan?
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_code, ins_discipline_omschrijving, ins_srtdiscipline_key)
SELECT * FROM (
SELECT 'INS', 'F010', 'Apparatuur', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Facilitaire objecten' UNION ALL
SELECT 'INS', 'F020', 'Automaten', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Facilitaire objecten' UNION ALL
SELECT 'INS', 'F030', 'Werkplekken', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Facilitaire objecten' UNION ALL
SELECT 'INS', 'F040', 'Toegang/Beveiliging', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Facilitaire objecten' UNION ALL
SELECT 'INS', 'F050', 'Vervoer', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Facilitaire objecten' UNION ALL
SELECT 'INS', 'G010', 'Bouwkundig', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Gebouwgebonden objecten' UNION ALL
SELECT 'INS', 'G040', 'Afwerking', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Gebouwgebonden objecten' UNION ALL
SELECT 'INS', 'G050', 'Mechanische installaties', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Gebouwgebonden objecten' UNION ALL
SELECT 'INS', 'G060', 'Elektrische installaties', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Gebouwgebonden objecten' UNION ALL
SELECT 'INS', 'G070', 'Vaste inrichting', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Gebouwgebonden objecten' UNION ALL
SELECT 'INS', 'I010', 'Computers', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'ICT objecten' UNION ALL
SELECT 'INS', 'I020', 'Presentatiemiddelen', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'ICT objecten' UNION ALL
SELECT 'INS', 'I030', 'Smartphones', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'ICT objecten' UNION ALL
SELECT 'INS', 'I040', 'Sensoren', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'ICT objecten' UNION ALL
SELECT 'INS', 'P010', 'Parkeren', ins_srtdiscipline_key FROM ins_srtdiscipline WHERE ins_srtdiscipline_omschrijving = 'Parkeerplaatsen'
);
INSERT INTO ins_disc_params (ins_discipline_key) SELECT ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_module='INS' AND ins_discipline_key NOT IN (SELECT ins_discipline_key FROM ins_disc_params);
-- Groepen TODO AANVULLEN of verbeteren. Meervoud of enkelvoud?
INSERT INTO ins_srtgroep (ins_srtgroep_omschrijving, ins_discipline_key)
SELECT * FROM (
SELECT 'Koffieautomaten', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F020' UNION ALL
SELECT 'Snoepautomaten', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F020' UNION ALL
SELECT 'Frisdrankautomaten', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F020' UNION ALL
SELECT 'Waterkoelers', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F020' UNION ALL
SELECT 'Bureau''s', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F030' UNION ALL
SELECT 'Tafels', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F030' UNION ALL
SELECT 'Stoelen', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F030' UNION ALL
SELECT 'Flexplekken', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'F030' UNION ALL
SELECT 'Desktops', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'I010' UNION ALL
SELECT 'Laptops', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'I010' UNION ALL
SELECT 'Tablets', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'I010' UNION ALL
SELECT 'Sensoren', ins_discipline_key FROM ins_tab_discipline WHERE ins_discipline_code = 'I040'
);
-- Objectsoorten TODO AANVULLEN. Meervoud of enkelvoud?
INSERT INTO ins_srtdeel (ins_srtgroep_key, ins_srtdeel_code, ins_srtdeel_omschrijving, ins_srtdeel_image, ins_srtdeel_sensortype)
SELECT * FROM (
SELECT ins_srtgroep_key, 'KOF','Koffieautomaat', 'fa-mug-hot', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Koffieautomaten' UNION ALL
SELECT ins_srtgroep_key, 'SNP','Snoepautomaat', 'fa-lollipop', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Snoepautomaten' UNION ALL
SELECT ins_srtgroep_key, 'FRS','Frisdrankautomaat', 'fa-cup-straw-swoosh', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Frisdrankautomaten' UNION ALL
SELECT ins_srtgroep_key, 'WTK','Waterkoeler', 'fa-glass-water', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Waterkoelers' UNION ALL
SELECT ins_srtgroep_key, 'DSK','Desktop type 1', 'fa-desktop', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Desktops' UNION ALL
SELECT ins_srtgroep_key, 'BUR','Bureau 160x80', 'fa-lamp-desk', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Bureau''s' UNION ALL
SELECT ins_srtgroep_key, 'TAF','Vergadertafel', 'fa-users-line', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Tafels' UNION ALL
SELECT ins_srtgroep_key, 'BST','Bureaustoel', 'fa-chair-office ', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Tafels' UNION ALL
SELECT ins_srtgroep_key, 'LPT','Laptop type 1', 'fa-laptop', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Laptops' UNION ALL
SELECT ins_srtgroep_key, 'LPT','Laptop type 2', 'fa-laptop', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Laptops' UNION ALL
SELECT ins_srtgroep_key, 'TAB','Tablet', 'fa-tablet', 0 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Tablets' UNION ALL
SELECT ins_srtgroep_key, 'SB','Bezettingssensor', 'fa-sensor', 1 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Sensoren' UNION ALL
SELECT ins_srtgroep_key, 'ST','Temperatuursensor', 'fa-temperature-half', 2 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Sensoren' UNION ALL
SELECT ins_srtgroep_key, 'SC','CO2-sensor', 'fa-sensor-cloud', 2 FROM ins_srtgroep WHERE ins_srtgroep_omschrijving = 'Sensoren'
);
-- 3. MLD
-- Importeren van een standaard meldingenstructuur (MLD), maakt alle bovenliggende niveaus zelf aan
INSERT INTO fac_imp_mld (ins_srtdiscipline_omschrijving, ins_srtdiscipline_prefix, ins_srtdiscipline_alg, ins_discipline_omschrijving, mld_stdmelding_hint, mld_stdmelding_omschrijving, mld_stdmelding_uitvoertijd)
SELECT * FROM (
SELECT 'Aanvraag','A',1,'Afval','fa-recycle','Ophalen/verzamelen afval', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Afval','fa-recycle','Extra container(rest-/papiercontainer)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Afval','fa-recycle','Zwerfafval (verzamelen)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Automaten','fa-server','Fris-/versnapering-automaat', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Automaten','fa-server','Ingredi<EFBFBD>nten t.b.v. koffieautomaat', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Automaten','fa-server','Waterflessen t.b.v. waterkoeler', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'BHV & Veiligheid','fa-medkit','BHV Herhalingstrainingen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'BHV & Veiligheid','fa-medkit','BHV middelen (AED/BHV rugzak-/hesje/megafoon) leveren', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'BHV & Veiligheid','fa-medkit','Blusmiddelen (brandblusser/brandslanghaspel)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'BHV & Veiligheid','fa-medkit','EHBO-middelen bestellen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'BHV & Veiligheid','fa-medkit','Ontruimingsplan & -plattegrond (nieuw/wijzigen)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'BHV & Veiligheid','fa-medkit','Pleisterautomaten plaatsen/aanvullen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Bedrijfskeuken apparatuur','fa-cutlery','Bedrijfskeuken apparatuur', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Bedrijfskleding','fa-shirtsinbulk','Bedrijfskleding', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Benodigdheden & bedrijfsmiddelen','fa-eur','Bloemen bestellen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Benodigdheden & bedrijfsmiddelen','fa-eur','Huurauto', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Benodigdheden & bedrijfsmiddelen','fa-eur','Kantoorbenodigheden', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Benodigdheden & bedrijfsmiddelen','fa-eur','Onderhoud overige bedrijfsmiddelen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Benodigdheden & bedrijfsmiddelen','fa-eur','Repro en documentbeheer', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Benodigdheden & bedrijfsmiddelen','fa-eur','Vloeistoffen/gassen bestellen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Catering','fa-coffee','Catering', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Automatische deuren(dock-/rol-/schuif-/overhead)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Bouwkundig', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Brandblusser/brandhaspel', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Brandmeld- & ontruimingsinstallatie(BMC)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Inbraak-/alarminstallatie', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Keuring elektrische (hand) apparatuur (NEN3140)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Klimaatinstallatie (airco/koelunit)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Lift', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Schade Gebouwonderhoud', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Schilderwerkzaamheden', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Technische installaties', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gebouw- & installatieonderhoud','fa-cubes','Verlichting', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gereedschap, PBM en trappen','fa-wrench','Defect elektrische (hand) apparatuur (NEN3140)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gereedschap, PBM en trappen','fa-wrench','Desinfectiemiddel + handschoenen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gereedschap, PBM en trappen','fa-wrench','Keuring elektrische (hand) apparatuur (NEN3140)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Gereedschap, PBM en trappen','fa-wrench','Persoonlijke beschermingsmiddelen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Hijs- & hef-installaties','fa-industry','Keuring hijs- en hefmiddelen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Hijs- & hef-installaties','fa-industry','Keuring kleine hijsmiddelen, klimmateriaal en stellingen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Hijs- & hef-installaties','fa-industry','Kleine hijsmiddelen, klimmateriaal en stellingen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Meubilair & inrichting','fa-home','Audio visuele middelen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Meubilair & inrichting','fa-home','Bewegwijzering', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Meubilair & inrichting','fa-home','Binnenbeplanting', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Meubilair & inrichting','fa-home','Meubilair & inrichting', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Meubilair & inrichting','fa-home','Meubilair leveren', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Meubilair & inrichting','fa-home','Sleutel leveren t.b.v. meubilair', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Meubilair & inrichting','fa-home','Vloerbedekking (nieuw/vervangen)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Ongedierte bestrijding','fa-bug','Ongediertebestrijding', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Ongedierte bestrijding','fa-bug','Pest Control producten(lokaasbakjes, UV lamp, overige)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Ongedierte bestrijding','fa-bug','Verdelging en preventieve controle', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Post- & koeriersdiensten','fa-envelope-open-o','Benodigheden & middelen dienstverlening post', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Post- & koeriersdiensten','fa-envelope-open-o','Koerierzendingen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Receptie & beveiliging','fa-address-card-o','Extra inzet receptie', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Receptie & beveiliging','fa-address-card-o','Extra openings-/sluitronde', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Receptie & beveiliging','fa-address-card-o','Inzet Verkeersregelaar(s)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Receptie & beveiliging','fa-address-card-o','Inzet extra beveiliging', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Receptie & beveiliging','fa-address-card-o','Plaatsen/vervangen (elektronisch) slot/sleutel', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Schoonmaak','fa-eraser','Extra schoonmaak (verzoek)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Schoonmaak','fa-eraser','Gevelreiniging (extra)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Schoonmaak','fa-eraser','Glasbewassing (binnen/buiten)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Schoonmaak','fa-eraser','Sanitaire middelen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Elektrische oplaadpunten', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Gladheidsbestrijding', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Groenonderhoud', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Hekwerken (onderhoud)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Overige aanvragen (toegangscontrole/hekwerken)', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Terrein- & groenvoorziening', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Terreinverlichting', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Terrein- & groenvoorziening','fa-tree','Toegangspoorten & slagbomen', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Verhuizing','fa-truck','Verhuis middelen leveren', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Verhuizing','fa-truck','Verhuizing extern', 5 FROM DUAL UNION ALL
SELECT 'Aanvraag','A',1,'Verhuizing','fa-truck','Verhuizing intern', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Afval','fa-recycle','Klacht mbt Afval', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Automaten','fa-server','Klacht mbt automaten', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'BHV & Veiligheid','fa-medkit','Klacht mbt BHV & Veiligheid', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Bedrijfskeuken apparatuur','fa-cutlery','Bedrijfskeuken apparatuur', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Bedrijfskleding','fa-shirtsinbulk','Klacht mbt Bedrijfskleding', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Facilitaire dienstverlening','fa-id-badge','Klacht mbt facilitaire dienstverlening', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Gebouw- & installatieonderhoud','fa-cubes','Klacht mbt onderhoud', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Meubilair & inrichting','fa-home','Klacht mbt Meubilair & inrichting', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Ongedierte bestrijding','fa-bug','Klacht mbt Ongediertebestrijding', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Koeriersdiensten','fa-envelope-open-o','Klacht mbt koeriersdiensten', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Receptie & beveiliging','fa-address-card-o','Klacht mbt Receptie & beveiliging', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Schoonmaak','fa-eraser','Klacht mbt Schoonmaak', 5 FROM DUAL UNION ALL
SELECT 'Klacht','K',0,'Terrein- & groenvoorziening','fa-tree','Klacht mbt terrein- & groenvoorziening', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Afval','fa-recycle','Container is niet geleegd', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Automaten','fa-server','Fris-/versnapering-automaat', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Automaten','fa-server','Koffieautomaat', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Automaten','fa-server','Waterkoeler', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'BHV & Veiligheid','fa-medkit','AED werkt niet/rood lampje', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'BHV & Veiligheid','fa-medkit','Blusmiddelen (brandblusser/brandslanghaspel)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'BHV & Veiligheid','fa-medkit','Brandslaghaspel (kast)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'BHV & Veiligheid','fa-medkit','Keuring blusapparatuur', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'BHV & Veiligheid','fa-medkit','Legionellabeheer en bemonstering', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'BHV & Veiligheid','fa-medkit','Verzegeling blusapparatuur', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Bedrijfskeuken apparatuur','fa-cutlery','Bedrijfskeuken apparatuur', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Automatische deuren(dock-/rol-/schuif-/overhead)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Bouwkundig', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Bouwkundig (dak, kozijnen, wanden, glas, ruitbreuk, lekkage)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Brandblusser/brandhaspel', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Brandmeld- & ontruimingsinstallatie(BMC)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Dak- en gevelinstallaties', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Eigenaarsinstallaties (Eigenaar pand)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Elektrische installatie', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Hang- & sluitwerk(sloten, deurdranger, deurklink etc)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Inbraak-/alarminstallatie', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Klimaatinstallatie (airco/koelunit)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Liften', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Noodverlichting', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Riolering, leidingen & kanalen', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Sanitair (toilet/urinoir, kraan, wasbak, spoelknop)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Schade Gebouwonderhoud', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Sprinkler installatie', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Technische installaties', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Verlichting', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Witgoed (wasmachines, koelkasten, drogers etc.)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Gebouw- & installatieonderhoud','fa-cubes','Zonwering (binnen/buiten)', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Hijs- & hef-installaties','fa-industry','Calamiteit Hijs- & hef-installaties', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Hijs- & hef-installaties','fa-industry','Hijs- & hef-installaties', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Hijs- & hef-installaties','fa-industry','Kleine hijsmiddelen, klimmateriaal en stellingen', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Ongedierte bestrijding','fa-bug','Ongediertebestrijding', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Receptie & beveiliging','fa-address-card-o','Plaatsen/vervangen (electronisch) slot/sleutel', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Schoonmaak','fa-eraser','Sanitaire accessoires', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Schoonmaak','fa-eraser','Schoonmaak', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Terrein- & groenvoorziening','fa-tree','Bestrating', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Terrein- & groenvoorziening','fa-tree','Elektrische oplaadpunten', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Terrein- & groenvoorziening','fa-tree','Gladheidbestrijding', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Terrein- & groenvoorziening','fa-tree','Groenonderhoud', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Terrein- & groenvoorziening','fa-tree','Terreinverlichting', 5 FROM DUAL UNION ALL
SELECT 'Storing','S',1,'Terrein- & groenvoorziening','fa-tree','Toegangscontrole/inbraakalarm systeem', 5 FROM DUAL UNION ALL
SELECT 'Melding','M',0,'Ontvangen melding','fa-mail','Ontvangen mail bericht', 5 FROM DUAL
);
-- beetje lomp, wat vinden we?
UPDATE fac_imp_mld SET mld_stdmelding_slabewaken = 0, mld_stdmelding_notfrontend = 0
WHERE ins_srtdiscipline_omschrijving <> 'Melding';
BEGIN fac_update_mld(tmp_fmis_ini.getImportKey('MLD')); END;
/
UPDATE ins_srtdiscipline SET ins_srtdiscipline_kostenklant = 8 WHERE ins_srtdiscipline_omschrijving = 'Klacht';
UPDATE fac_setting
SET fac_setting_pvalue =
(SELECT mld_stdmelding_key
FROM mld_stdmelding
WHERE mld_stdmelding_omschrijving = 'Ontvangen mail bericht')
WHERE fac_setting_name = 'defaultstdmelding';
INSERT INTO fac_email_setting (fac_email_setting_user, fac_email_setting_frommode, fac_email_setting_action, fac_email_setting_attachpath)
VALUES ('servicedesk', 0, 'FAC.processemail', '*flexfilespath');
-- huh? O, de import ondersteunt de image niet, dus die gaat via de hint
UPDATE mld_stdmelding
SET mld_stdmelding_image = mld_stdmelding_hint,
mld_stdmelding_hint = NULL
WHERE mld_stdmelding_hint IS NOT NULL AND mld_stdmelding_image IS NULL;
-- Voeg bijlage toe aan alle vakgroeptypen
DECLARE
v_key mld_srtkenmerk.mld_srtkenmerk_key%TYPE;
BEGIN
INSERT INTO mld_srtkenmerk (mld_srtkenmerk_omschrijving, mld_srtkenmerk_kenmerktype) VALUES ('Bijlagen', 'M')
RETURNING mld_srtkenmerk_key INTO v_key;
INSERT INTO mld_kenmerk (mld_srtkenmerk_key, mld_kenmerk_niveau, mld_kenmerk_volgnummer, mld_kenmerk_groep) VALUES (v_key, 'A', 100, 0);
END;
/
-- 4. RES
-- Activiteiten zijn er default al, catalogi dan
DECLARE
v_discipline_key res_discipline.ins_discipline_key%TYPE;
v_key res_activiteit.res_activiteit_key%TYPE;
BEGIN
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Vergaderruimte', 'RES') RETURNING ins_discipline_key INTO v_discipline_key;
INSERT INTO res_disc_params (res_disc_params_key) VALUES (v_discipline_key);
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Flexplekken', 'RES') RETURNING ins_discipline_key INTO v_discipline_key;
INSERT INTO res_disc_params (res_disc_params_key) VALUES (v_discipline_key);
UPDATE res_disc_params
SET res_disc_params_expire_dagen = 0, res_disc_params_cancel_dagen = 0
WHERE res_ins_discipline_key = v_discipline_key;
INSERT INTO res_activiteit (res_activiteit_omschrijving, res_srtactiviteit_key, res_activiteit_intervals)
VALUES ('Flexplekken', 2, '[{ "name": "Hele dag", "begin": "08:00", "end": "17:00"}, { "name": "Ochtend", "begin": "08:00", "end": "12:00"}, { "name": "Middag", "begin": "13:00", "end": "17:00"}]')
RETURNING res_activiteit_key INTO v_key;
INSERT INTO res_activiteitdiscipline(res_discipline_key, res_activiteit_key) VALUES (v_discipline_key, v_key);
END;
/
-- De catalogus om ruimten te reserveren moet nog wel aan de activiteit gekoppeld worden.
INSERT INTO res_activiteitdiscipline(res_discipline_key, res_activiteit_key)
SELECT ins_discipline_key, res_activiteit_key FROM res_discipline, res_activiteit
WHERE res_activiteit_omschrijving = 'Vergadering';
-- Voeg de artikelscope voor alle catering catalogi (min_level =2) toe voor alle locaties
-- Als ik onbeperkt wil, is dit dan nodig?
INSERT INTO res_srtartikel_onrgoed (alg_onrgoed_key,
alg_onrgoed_niveau,
res_discipline_key)
SELECT alg_locatie_key, 'L', ins_discipline_key
FROM res_discipline rd, alg_locatie l
WHERE ins_discipline_min_level = 2;
-- 5. CNT
DECLARE
v_discipline_key ins_tab_discipline.ins_discipline_key%TYPE;
v_key cnt_srtkenmerk.cnt_srtkenmerk_key%TYPE;
BEGIN
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Onderhoudscontract', 'CNT')
RETURNING ins_discipline_key INTO v_discipline_key;
INSERT INTO cnt_disc_params (cnt_ins_discipline_key, cnt_srtcontract_type) VALUES (v_discipline_key, 1);
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Servicecontract', 'CNT')
RETURNING ins_discipline_key INTO v_discipline_key;
INSERT INTO cnt_disc_params (cnt_ins_discipline_key, cnt_srtcontract_type) VALUES (v_discipline_key, 3);
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Algemeen contract', 'CNT')
RETURNING ins_discipline_key INTO v_discipline_key;
INSERT INTO cnt_disc_params (cnt_ins_discipline_key, cnt_srtcontract_type) VALUES (v_discipline_key, 4);
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Leverancierscontract', 'CNT')
RETURNING ins_discipline_key INTO v_discipline_key;
INSERT INTO cnt_disc_params (cnt_ins_discipline_key, cnt_srtcontract_type) VALUES (v_discipline_key, 5);
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Mantelcontract', 'CNT')
RETURNING ins_discipline_key INTO v_discipline_key;
INSERT INTO cnt_disc_params (cnt_ins_discipline_key, cnt_srtcontract_type) VALUES (v_discipline_key, 6);
-- Alle contracten hebben bijlagen
INSERT INTO cnt_srtkenmerk (cnt_srtkenmerk_omschrijving, cnt_srtkenmerk_kenmerktype) VALUES ('Bijlagen', 'M')
RETURNING cnt_srtkenmerk_key INTO v_key;
INSERT INTO cnt_kenmerk (cnt_srtkenmerk_key,
cnt_srtcontract_key,
cnt_kenmerk_niveau,
cnt_kenmerk_volgnummer,
cnt_kenmerk_groep)
SELECT v_key, ins_discipline_key, 'S', 100, 0 FROM cnt_discipline;
END;
/
-- 6. FAQ
INSERT INTO ins_tab_discipline (ins_discipline_omschrijving, ins_discipline_module) VALUES ('Facilitaire Kennisbank', 'FAQ');
-- 7. MSG
-- Misschien ook hier nog een berichtje, anders iig de catalogi
-- Settings: Alleen settings die specifiek voor FM zijn en intrinsiek afwijken van de standaardinstellingen(!)
--UPDATE fac_setting SET fac_setting_pvalue = 'true' WHERE fac_setting_name = 'prs_allow_impersonate';
UPDATE fac_setting SET fac_setting_pvalue = 'no_reply@' || user || '.facilitor.nl' WHERE fac_setting_name = 'puo_fromaddress';
--UPDATE fac_setting SET fac_setting_pvalue = '1' WHERE fac_setting_name = 'widgetportal';
UPDATE fac_setting SET fac_setting_pvalue = '3' WHERE fac_setting_name = 'portalmenucols';
-- Via interactieve config
--UPDATE fac_setting SET fac_setting_pvalue = '1' WHERE fac_setting_name = 'faq_enabled';
--UPDATE fac_setting SET fac_setting_pvalue = '1' WHERE fac_setting_name = 'mobile_enabled';
--UPDATE fac_setting SET fac_setting_pvalue = '1' WHERE fac_setting_name = 'qrc_enabled';
--UPDATE fac_setting SET fac_setting_pvalue = '1' WHERE fac_setting_name = 'puo_app2enabled';
-- Autorisatiegroepen
-- We definieren deze groepen: Medewerker (_DEFAULT), Frontoffice, Backoffice, Beheerder (_ADMIN)
INSERT INTO fac_groep (fac_groep_omschrijving) VALUES ('Frontoffice');
INSERT INTO fac_groep (fac_groep_omschrijving) VALUES ('Backoffice');
-- Medewerker rechten
INSERT INTO fac_groeprechten (fac_groep_key, fac_functie_key, ins_discipline_key,
fac_gebruiker_alg_level_read, fac_gebruiker_alg_level_write,
fac_gebruiker_prs_level_read, fac_gebruiker_prs_level_write)
SELECT g.fac_groep_key, f.fac_functie_key, d.ins_discipline_key, -1, -1, -1, -1
FROM fac_functie f, ins_tab_discipline d, fac_groep g
WHERE f.fac_functie_code IN ('WEB_RESUSE', 'WEB_MLDUSE', 'WEB_BESUSE','WEB_BEZUSE','WEB_FAQUSE','WEB_PROFIL')
AND f.fac_functie_module = d.ins_discipline_module
AND g.fac_groep_upper = '_DEFAULT'
AND NOT EXISTS
(SELECT gr.fac_groeprechten_key
FROM fac_groeprechten gr
WHERE gr.fac_functie_key = f.fac_functie_key
AND gr.ins_discipline_key = d.ins_discipline_key
AND gr.fac_groep_key = g.fac_groep_key);
-- Frontoffice rechten
INSERT INTO fac_groeprechten (fac_groep_key, fac_functie_key, ins_discipline_key,
fac_gebruiker_alg_level_read, fac_gebruiker_alg_level_write,
fac_gebruiker_prs_level_read, fac_gebruiker_prs_level_write)
SELECT g.fac_groep_key, f.fac_functie_key, d.ins_discipline_key, -1, -1, -1, -1
FROM fac_functie f, ins_tab_discipline d, fac_groep g
WHERE f.fac_functie_code IN ('WEB_RESFOF', 'WEB_MLDFOF', 'WEB_BESFOF', 'WEB_BEZFOF', 'WEB_FAQFOF', 'WEB_INSFOF')
AND f.fac_functie_module = d.ins_discipline_module
AND g.fac_groep_upper = 'FRONTOFFICE'
AND NOT EXISTS
(SELECT gr.fac_groeprechten_key
FROM fac_groeprechten gr
WHERE gr.fac_functie_key = f.fac_functie_key
AND gr.ins_discipline_key = d.ins_discipline_key
AND gr.fac_groep_key = g.fac_groep_key);
-- Backoffice rechten
INSERT INTO fac_groeprechten (fac_groep_key, fac_functie_key, ins_discipline_key,
fac_gebruiker_alg_level_read, fac_gebruiker_alg_level_write,
fac_gebruiker_prs_level_read, fac_gebruiker_prs_level_write)
SELECT g.fac_groep_key, f.fac_functie_key, d.ins_discipline_key, -1, -1, -1, -1
FROM fac_functie f, ins_tab_discipline d, fac_groep g
WHERE f.fac_functie_code IN ('WEB_RESBOF', 'WEB_MLDBOF', 'WEB_ORDBOF', 'WEB_BESBOF', 'WEB_BEZBOF', 'WEB_FAQBOF', 'WEB_INSUSE', 'WEB_INSMAN', 'WEB_CNTMAN', 'WEB_CNTUSE')
AND f.fac_functie_module = d.ins_discipline_module
AND g.fac_groep_upper = 'BACKOFFICE'
AND NOT EXISTS
(SELECT gr.fac_groeprechten_key
FROM fac_groeprechten gr
WHERE gr.fac_functie_key = f.fac_functie_key
AND gr.ins_discipline_key = d.ins_discipline_key
AND gr.fac_groep_key = g.fac_groep_key);
-- Beheerder rechten
INSERT INTO fac_groeprechten (fac_groep_key, fac_functie_key, ins_discipline_key,
fac_gebruiker_alg_level_read, fac_gebruiker_alg_level_write,
fac_gebruiker_prs_level_read, fac_gebruiker_prs_level_write)
SELECT g.fac_groep_key, f.fac_functie_key, d.ins_discipline_key, -1, -1, -1, -1
FROM fac_functie f, ins_tab_discipline d, fac_groep g
WHERE f.fac_functie_code IN ('WEB_RESMSU', 'WEB_MLDMSU', 'WEB_BESMSU', 'WEB_BEZMSU', 'WEB_FAQMSU', 'WEB_INSMSU',
'WEB_RESMGT', 'WEB_MLDMGT', 'WEB_BESMGT', 'WEB_BEZMGT', 'WEB_FAQMGT', 'WEB_INSMGT',
'WEB_RESBAC', 'WEB_MLDBAC', 'WEB_BESBAC', 'WEB_BEZBAC')
AND f.fac_functie_module = d.ins_discipline_module
AND g.fac_groep_upper = '_ADMIN'
AND NOT EXISTS
(SELECT gr.fac_groeprechten_key
FROM fac_groeprechten gr
WHERE gr.fac_functie_key = f.fac_functie_key
AND gr.ins_discipline_key = d.ins_discipline_key
AND gr.fac_groep_key = g.fac_groep_key);
-- Portaal
-- Uitwerken, maar niet te gek maken
UPDATE fac_locale_xsl
SET fac_locale_xsl_cust = 'Welkom in jouw persoonlijke Facilitor/FMIS-omgeving. Je kunt hier allerlei zaken regelen, we leggen je hier kort even uit hoe.'
WHERE fac_locale_xsl_label = 'lcl_welcome_intro' AND fac_locale_xsl_lang = 'NL' AND fac_locale_xsl_module = 'ASP';
--
--
-- Een heel klein beetje voorbeeldvulling als appetizer
--
--
-- Importeren van locatie en gebouwen (ONRGOED1)
INSERT INTO fac_imp_onrgoed1 (alg_regio_omschrijving, alg_district_omschrijving,
alg_locatie_code, alg_locatie_omschrijving, alg_gebouw_code, alg_gebouw_naam, alg_srtgebouw_omschrijving,
alg_locatie_adres, alg_locatie_postcode, alg_locatie_plaats)
VALUES ('Nederland', 'Midden',
'UTR','Hoofdkantoor','HQ','Hoofdgebouw','Kantoor',
'Grotestraat 123','1234 AB','Utrecht');
BEGIN fac_update_onrgoed1(tmp_fmis_ini.getImportKey('ONRGOED1')); END;
/
-- Importeren van vergaderzalen (ONRGOED2)
INSERT INTO fac_imp_onrgoed2 (alg_locatie_code, alg_gebouw_code, alg_verdieping_volgnr, alg_srtruimte_omschrijving,
alg_ruimte_nr, alg_ruimte_omschrijving, reserveerbaar,
res_discipline_omschrijving, res_opstelling_omschrijving, res_ruimte_opstel_bezoekers, res_ruimte_nr)
SELECT * FROM (
SELECT 'UTR', 'HQ', 0, 'Vergaderruimte', '0.02', 'Vergaderruimte 1','J', 'Vergaderruimte', 'Standaard', 10, 'Dahlia' FROM DUAL UNION ALL
SELECT 'UTR', 'HQ', 0, 'Vergaderruimte', '0.03', 'Vergaderruimte 2','J', 'Vergaderruimte', 'Standaard', 8, 'Rozentuin' FROM DUAL
);
-- Importeren van losse ruimten
INSERT INTO fac_imp_onrgoed2( alg_locatie_code, alg_gebouw_code, alg_verdieping_volgnr, alg_srtruimte_omschrijving, alg_ruimte_nr, alg_ruimte_omschrijving)
SELECT * FROM (
SELECT 'UTR', 'HQ', 0, 'Kantoor', '0.04', 'Kantoor 0.03' FROM DUAL UNION ALL
SELECT 'UTR', 'HQ', 0, 'Kantoor', '0.05', 'Kantoor 0.04' FROM DUAL UNION ALL
SELECT 'UTR', 'HQ', 0, 'Verkeersruimte', '0.01', 'Gang' FROM DUAL UNION ALL
SELECT 'UTR', 'HQ', 1, 'Kantoor', '1.03', 'Kantoor 1.03' FROM DUAL UNION ALL
SELECT 'UTR', 'HQ', 1, 'Kantoor', '1.04', 'Kantoor 1.04' FROM DUAL UNION ALL
SELECT 'UTR', 'HQ', 1, 'Verkeersruimte', '1.01', 'Gang' FROM DUAL
);
BEGIN fac_update_onrgoed2(tmp_fmis_ini.getImportKey('ONRGOED2')); END;
/
-- Importeren van flexplekken (INS)
INSERT INTO fac_imp_ins (ins_discipline_omschrijving, ins_srtgroep_omschrijving,ins_srtdeel_code,ins_srtdeel_omschrijving,ins_deel_omschrijving,
alg_locatie_code,alg_gebouw_code,alg_verdieping_volgnr,alg_ruimte_nr,ins_deel_aantal,reserveerbaar,res_deel_alg_level,res_discipline_omschrijving)
SELECT * FROM (
SELECT 'Werkplekken', 'Flexplekken','FLEXDS','Flexplek met dockingstation','FLEXDS003.1', 'UTR','HQ',0,'0.03',1,1,4,'Flexplekken' FROM DUAL UNION ALL
SELECT 'Werkplekken', 'Flexplekken','FLEXDS','Flexplek met dockingstation','FLEXDS004.2', 'UTR','HQ',0,'0.04',1,1,4,'Flexplekken' FROM DUAL UNION ALL
SELECT 'Werkplekken', 'Flexplekken','FLEX','Flexplek','FLEX014.1', 'UTR','HQ',0,'1.04',1,1,4,'Flexplekken' FROM DUAL
);
BEGIN fac_update_ins(tmp_fmis_ini.getImportKey('INS')); END;
/
-- Dit zijn geen objecten maar werkplekken
UPDATE ins_tab_discipline SET ins_discipline_min_level = 5 WHERE ins_discipline_omschrijving = 'Flexplekken' and ins_discipline_module = 'RES';
-- Wil ik dit, en zo, en specifiek? Core!
INSERT INTO fac_menu (fac_menu_altlabel,
fac_menu_altgroep,
fac_menu_volgnr,
fac_menu_alturl,
fac_functie_key,
fac_menu_level,
ins_discipline_key)
SELECT 'Reserveer werkplek',
0,
650,
'appl/res/res_rsv_deel_by_placetime.asp?selectmode=1&res_disc='
|| rd.ins_discipline_key
|| '&limit=15',
f.fac_functie_key,
0,
rd.ins_discipline_key
FROM fac_functie f, res_discipline rd
WHERE rd.ins_discipline_omschrijving = 'Flexplekken' AND f.fac_functie_code = 'WEB_RESUSE';
-- Reserveerbare artikelen
INSERT INTO fac_imp_res_artikel_sync (res_discipline_oms, res_artikel_nr, res_artikel_omschrijving, res_artikel_eenheid, res_artikel_prijs, res_artikel_prijs_vast)
SELECT * FROM (
SELECT 'Dranken', 'D002', 'Thee', 'Kan', '5.50', 1 FROM DUAL UNION ALL
SELECT 'Dranken', 'D003', 'Frisdrank', 'Flesje', '2.50', 1 FROM DUAL UNION ALL
SELECT 'Dranken', 'D004', 'Water', 'Kan', '2.00', 1 FROM DUAL UNION ALL
SELECT 'Dranken', 'D001', 'Koffie', 'Kan', '7.50', 1 FROM DUAL
);
BEGIN fac_update_res_artikel_sync(tmp_fmis_ini.getImportKey('RES_ARTIKEL_SYNC')); END;
/
-- Interne organisatiestructuur (ORGANISATIE), is die kostenplaats nodig?
INSERT INTO fac_imp_organisatie (prs_bedrijf_naam, prs_afdeling_naam, prs_afdeling_omschrijving, prs_kostenplaats_nr)
SELECT * FROM (
SELECT 'Onze organisatie', 'SALES', 'Sales & Marketing', 'S' FROM DUAL UNION ALL
SELECT 'Onze organisatie', 'DIR', 'Directie', 'D' FROM DUAL UNION ALL
SELECT 'Onze organisatie', 'HR', 'Personeel & Organisatie', 'P' FROM DUAL UNION ALL
SELECT 'Onze organisatie', 'ICT', 'ICT', 'I' FROM DUAL UNION ALL
SELECT 'Onze organisatie', 'FIN', 'Finance', 'FIN' FROM DUAL UNION ALL
SELECT 'Onze organisatie', 'MW', 'Overig', 'MW' FROM DUAL UNION ALL
SELECT 'Onze organisatie', 'FM', 'Facility Management', 'FM' FROM DUAL
);
BEGIN fac_update_organisatie(tmp_fmis_ini.getImportKey('ORGANISATIE')); END;
/
-- Minimale gebruikers, moet gedocumenteerd worden, wachtwoorden via wachtwoord-vergeten oid
INSERT INTO fac_imp_perslid (prs_afdeling_naam, prs_perslid_naam, prs_perslid_voornaam, prs_perslid_telefoonnr, prs_perslid_mobiel, prs_perslid_email, prs_srtperslid_omschrijving, prs_perslid_nr, prs_perslid_oslogin, prs_perslid_wachtwoord)
SELECT * FROM (
SELECT 'MW', 'Medewerker', 'Wim', '022-3982345', '06-293785629', 'Wim.Medewerker@bedrijf.nl', 'Medewerker', '001', 'Wim', 'Medewerker21#' FROM DUAL UNION ALL
SELECT 'FM', 'Backoffice', 'Hans', '022-3982346', '06-293785630', 'Hans.Backoffice@bedrijf.nl', 'Medewerker', '002', 'Hans', 'Backoffice21#' FROM DUAL UNION ALL
SELECT 'ICT', 'Beheerder', 'Olga', '022-3982347', '06-293785631', 'Olga.Beheerder@bedrijf.nl', 'Medewerker', '003', 'Olga', 'Beheerder21#' FROM DUAL
);
BEGIN fac_update_perslid(tmp_fmis_ini.getImportKey('PERSLID')); END;
/
-- Rechten toekennen aan de personen
-- Iedereen zit standaard al in de _default groep
-- De beheerder zetten we in de beheerdersgroep en de ook in de backoffice groep
-- INSERT INTO fac_gebruikersgroep (fac_groep_key, prs_perslid_key) SELECT g.fac_groep_key, p.prs_perslid_key FROM fac_groep, prs_perslid p WHERE g.fac_groep_upper = '_DEFAULT' AND p.prs_perslid_naam = 'Medewerker'
INSERT INTO fac_gebruikersgroep (fac_groep_key, prs_perslid_key) SELECT g.fac_groep_key, p.prs_perslid_key FROM fac_groep g, prs_perslid p WHERE g.fac_groep_upper = 'BACKOFFICE' AND p.prs_perslid_naam = 'Backoffice';
INSERT INTO fac_gebruikersgroep (fac_groep_key, prs_perslid_key) SELECT g.fac_groep_key, p.prs_perslid_key FROM fac_groep g, prs_perslid p WHERE g.fac_groep_upper = 'FRONTOFFICE' AND p.prs_perslid_naam = 'Backoffice';
INSERT INTO fac_gebruikersgroep (fac_groep_key, prs_perslid_key) SELECT g.fac_groep_key, p.prs_perslid_key FROM fac_groep g, prs_perslid p WHERE g.fac_groep_upper = '_ADMIN' AND p.prs_perslid_naam = 'Beheerder';
INSERT INTO fac_gebruikersgroep (fac_groep_key, prs_perslid_key) SELECT g.fac_groep_key, p.prs_perslid_key FROM fac_groep g, prs_perslid p WHERE g.fac_groep_upper = 'BACKOFFICE' AND p.prs_perslid_naam = 'Beheerder';
INSERT INTO fac_gebruikersgroep (fac_groep_key, prs_perslid_key) SELECT g.fac_groep_key, p.prs_perslid_key FROM fac_groep g, prs_perslid p WHERE g.fac_groep_upper = 'FRONTOFFICE' AND p.prs_perslid_naam = 'Beheerder';
-- Contracten
--INSERT INTO fac_imp_cnt (nummer_intern,
-- nummer_extern,
-- cnt_soort,
-- beschrijving,
-- omschrijving,
-- afdeling,
-- perslid_beh,
-- opmerking,
-- datum_ingang,
-- datum_eind,
-- datum_opzeg,
-- datum_rappel,
-- bedrijf_naam,
-- kpn_code,
-- bedrag,
-- gebouwcode)
-- VALUES (1,
-- 'E345',
-- 'Leverancierscontract',
-- 'Contract technische installaties',
-- 'Contract over onderhoud op alle technische installaties',
-- 'F',
-- 'HANS',
-- '',
-- TRUNC (SYSDATE, 'Y'),
-- ADD_MONTHS (TRUNC (SYSDATE, 'Y'), 48) - 1,
-- ADD_MONTHS (TRUNC (SYSDATE, 'Y'), 47),
-- ADD_MONTHS (TRUNC (SYSDATE, 'Y'), 45),
-- 'Hendriks Techniek',
-- 'F',
-- 3000,
-- 'G');
--BEGIN fac_update_cnt(tmp_fmis_ini.getImportKey('CNT')); END;
--/
-- INS
DELETE fac_imp_ins;
INSERT INTO fac_imp_ins (ins_discipline_omschrijving, ins_srtgroep_omschrijving,ins_srtdeel_code,ins_srtdeel_omschrijving,ins_deel_omschrijving,
alg_locatie_code,alg_gebouw_code,alg_verdieping_volgnr,alg_ruimte_nr,ins_deel_aantal)
SELECT * FROM (
SELECT 'Automaten','Koffieautomaten','KOF','Koffieautomaat','KOF001','UTR','HQ',0,'0.01',1 FROM DUAL UNION ALL
SELECT 'Automaten','Koffieautomaten','KOF','Koffieautomaat','KOF002','UTR','HQ',0,'1.01',1 FROM DUAL
);
BEGIN fac_update_ins(tmp_fmis_ini.getImportKey('INS')); END;
/
INSERT INTO fac_nieuws (fac_nieuws_omschrijving) VALUES ('Gefeliciteerd met de keuze voor Facilitor voor FM!');
---- Menu-items voor de vakgroeptypen toevoegen
---- Ik meen dat we dat default doen (explode), maar dat checken of core doen
--DECLARE
-- v_key fac_functie.fac_functie_key%TYPE;
-- v_index NUMBER;
--BEGIN
-- SELECT fac_functie_key
-- INTO v_key
-- FROM fac_functie
-- WHERE fac_functie_code = 'WEB_MLDUSE';
--
-- v_index := 110;
-- FOR rec IN (SELECT * FROM ins_srtdiscipline WHERE ins_srtdiscipline_prefix <> 'M')
-- LOOP
--
-- INSERT INTO fac_menu (fac_menu_altlabel,
-- fac_menu_altgroep,
-- fac_menu_volgnr,
-- fac_menu_alturl,
-- fac_functie_key,
-- fac_menu_level,
-- ins_srtdiscipline_key,
-- fac_menu_portal)
-- VALUES (
-- '> ' || rec.ins_srtdiscipline_omschrijving,
-- 0,
-- v_index,
-- 'appl/mld/mld_fe_menu.asp?lvl=1&urole=fe&srtdisc=' || rec.ins_srtdiscipline_key,
-- v_key,
-- 0,
-- rec.ins_srtdiscipline_key,
-- 1);
--
-- -- Nu we hier toch zijn gaan we ook het opdrachttype Standaard (key=5) toevoegen aan de srtdiscipline
-- INSERT INTO mld_typeopdr_srtdiscipline (mld_typeopdr_key, ins_srtdiscipline_key)
-- VALUES (5, rec.ins_srtdiscipline_key);
-- v_index := v_index + 10;
-- END LOOP;
--END;
--/
-- Cleanup
DROP PACKAGE tmp_fmis_ini;
-- TODO: registreren dat we gerund zijn, zodat we dat een volgende keer kunnen checken
------ payload end ------
SET DEFINE OFF
BEGIN adm.systrackscriptId ('$Id$', 1); END;
/
COMMIT;
SET ECHO OFF
SPOOL OFF
SET DEFINE ON
PROMPT Logfile of this initialisation is: &fcltlogfile

324
INI/ITIL/itil_ini.sql Normal file
View File

@@ -0,0 +1,324 @@
--
-- $Id$
--
-- Script containing the default initialisation of the ITIL module
-- This is an add-on to the Service Management module and provides
-- a complete and common ITIL compliant process config as a starting point
-- for any ITIL implementation.
--
DEFINE thisfile = 'ITIL_INI.SQL'
DEFINE dbuser = ''
SET ECHO ON
SET DEFINE ON
COLUMN fcltlogfile NEW_VALUE fcltlogfile NOPRINT;
COLUMN fcltcusttxt NEW_VALUE fcltcusttxt NOPRINT;
WHENEVER SQLERROR CONTINUE;
SELECT adm.getscriptspoolfile ('&thisfile') AS fcltlogfile FROM DUAL;
SPOOL &fcltlogfile
WHENEVER SQLERROR EXIT;
SELECT adm.checkscriptcust ('&dbuser') AS fcltcusttxt FROM DUAL;
WHENEVER SQLERROR CONTINUE;
---------------------------------------
PROMPT &fcltcusttxt
---------------------------------------
SET DEFINE OFF
------ payload begin ------
DECLARE
---- TODO: variabelen opschonen, alleen VGT is voldoende rest kan dan uniek herleid worden. Voor settings zijn ze ook niet nodig.
v_allow_parent VARCHAR2 (4000);
v_can_change_prio VARCHAR2 (4000);
v_mg_applicaties NUMBER (10);
v_mg_hardware NUMBER (10);
v_mg_inloggen NUMBER (10);
v_mg_veiligheid NUMBER (10);
v_vgt_incident NUMBER (10);
v_vgt_wijziging NUMBER (10);
v_vgt_realisatie NUMBER (10);
v_vgt_problem NUMBER (10);
v_vg_iappl NUMBER (10);
v_vg_iapparatuur NUMBER (10);
v_vg_iinlog NUMBER (10);
v_vg_iveiligh NUMBER (10);
v_vg_nsw NUMBER (10);
v_vg_sw NUMBER (10);
v_vg_rv NUMBER (10);
v_vg_pr NUMBER (10);
BEGIN
------------------------------
--- Settings -----------------
------------------------------
SELECT COALESCE (f.fac_setting_pvalue, f.fac_setting_default)
INTO v_allow_parent
FROM fac_setting f
WHERE f.fac_setting_name = 'mld_allow_parentmelding';
IF v_allow_parent = '0'
THEN
UPDATE fac_setting f
SET f.fac_setting_pvalue = '1'
WHERE f.fac_setting_name = 'mld_allow_parentmelding';
END IF;
SELECT COALESCE (f.fac_setting_pvalue, f.fac_setting_default)
INTO v_can_change_prio
FROM fac_setting f
WHERE f.fac_setting_name = 'mld_can_change_prio_and_place_while_issued';
IF UPPER (v_can_change_prio) = 'FALSE'
THEN
UPDATE fac_setting f
SET f.fac_setting_pvalue = 'true'
WHERE f.fac_setting_name = 'mld_can_change_prio_and_place_while_issued';
END IF;
------------------------------
--- Vulling ------------------
------------------------------
--- Maak de standaardmeldinggroepen aan
INSERT INTO mld_stdmeldinggroep (mld_stdmeldinggroep_naam, mld_stdmeldinggroep_oms)
VALUES ('Applicaties', 'Applicaties')
RETURNING mld_stdmeldinggroep_key
INTO v_mg_applicaties;
INSERT INTO mld_stdmeldinggroep (mld_stdmeldinggroep_naam, mld_stdmeldinggroep_oms)
VALUES ('Hardware', 'Hardware')
RETURNING mld_stdmeldinggroep_key
INTO v_mg_hardware;
INSERT INTO mld_stdmeldinggroep (mld_stdmeldinggroep_naam, mld_stdmeldinggroep_oms)
VALUES ('Inloggen/toegang', 'Inloggen/toegang')
RETURNING mld_stdmeldinggroep_key
INTO v_mg_inloggen;
INSERT INTO mld_stdmeldinggroep (mld_stdmeldinggroep_naam, mld_stdmeldinggroep_oms)
VALUES ('Veiligheid', 'Veiligheid')
RETURNING mld_stdmeldinggroep_key
INTO v_mg_veiligheid;
--- Maak de vakgroeptypen aan
INSERT INTO ins_srtdiscipline (ins_srtdiscipline_module,
ins_srtdiscipline_omschrijving,
ins_srtdiscipline_alg,
ins_srtdiscipline_prefix,
ins_srtdiscipline_ins,
ins_srtdiscipline_kostenklant)
SELECT 'MLD', 'Incidenten', 'I', 1, 1, 0 FROM DUAL
RETURNING ins_srtdiscipline_key
INTO v_vgt_incident;
INSERT INTO ins_srtdiscipline (ins_srtdiscipline_module,
ins_srtdiscipline_omschrijving,
ins_srtdiscipline_alg,
ins_srtdiscipline_prefix,
ins_srtdiscipline_ins,
ins_srtdiscipline_kostenklant)
SELECT 'MLD', 'Wijzigingen', 'W', 1, 1, 0 FROM DUAL
RETURNING ins_srtdiscipline_key
INTO v_vgt_wijziging;
INSERT INTO ins_srtdiscipline (ins_srtdiscipline_module,
ins_srtdiscipline_omschrijving,
ins_srtdiscipline_alg,
ins_srtdiscipline_prefix,
ins_srtdiscipline_ins,
ins_srtdiscipline_kostenklant)
SELECT 'MLD', 'Realisatie', 'R', 1, 1, 0 FROM DUAL
RETURNING ins_srtdiscipline_key
INTO v_vgt_realisatie;
INSERT INTO ins_srtdiscipline (ins_srtdiscipline_module,
ins_srtdiscipline_omschrijving,
ins_srtdiscipline_alg,
ins_srtdiscipline_prefix,
ins_srtdiscipline_ins,
ins_srtdiscipline_kostenklant)
SELECT 'MLD', 'Problemen', 'P', 1, 1, 0 FROM DUAL
RETURNING ins_srtdiscipline_key
INTO v_vgt_problem;
--- Maak de vakgroepen aan
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Incidenten met betrekking tot applicaties', v_vgt_incident)
RETURNING ins_discipline_key
INTO v_vg_iappl;
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Incidenten met betrekking tot apparatuur', v_vgt_incident)
RETURNING ins_discipline_key
INTO v_vg_iapparatuur;
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Incidenten met betrekking tot inloggen/toegang', v_vgt_incident)
RETURNING ins_discipline_key
INTO v_vg_iinlog;
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Incidenten met betrekking tot veiligheid', v_vgt_incident)
RETURNING ins_discipline_key
INTO v_vg_iveiligh;
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Niet-standaard wijzigingen', v_vgt_wijziging)
RETURNING ins_discipline_key
INTO v_vg_nsw;
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Standaard wijzigingen', v_vgt_wijziging)
RETURNING ins_discipline_key
INTO v_vg_sw;
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Realisatieverzoeken', v_vgt_realisatie)
RETURNING ins_discipline_key
INTO v_vg_rv;
INSERT INTO ins_tab_discipline (ins_discipline_module, ins_discipline_omschrijving, ins_srtdiscipline_key)
VALUES ('MLD', 'Problemen', v_vgt_problemen)
RETURNING ins_discipline_key
INTO v_vg_pr;
--- Zet de parameters van de vakgroepen goed
UPDATE mld_disc_params
SET mld_disc_params_notify = 2,
mld_disc_params_bonotify = 2,
mld_disc_params_fenotes = 3,
mld_disc_params_benotify = 1,
mld_disc_params_nobnotify = 1,
mld_disc_params_strgroep = 5,
mld_disc_params_bhgnotify = 1,
mld_disc_params_primairbeh = 1
WHERE mld_ins_discipline_key IN (v_vg_iappl,
v_vg_iapparatuur,
v_vg_iinlog,
v_vg_iveiligh,
v_vg_nsw,
v_vg_sw,
v_vg_rv,
v_vg_pr);
--- Incidenten moeten gegroepeerd kunnen worden tot een problem
UPDATE mld_disc_params
SET mld_disc_params_mldgroup = 2
WHERE mld_ins_discipline_key IN (v_vg_iappl,
v_vg_iapparatuur,
v_vg_iinlog,
v_vg_iveiligh);
--- Problems en wijzigingen moeten een groepering kunnen zijn
UPDATE mld_disc_params
SET mld_disc_params_mldgroup = 1
WHERE mld_ins_discipline_key IN (v_vg_nsw,
v_vg_sw,
v_vg_pr);
--- Maak de standaardmeldingen aan
INSERT INTO mld_stdmelding (mld_ins_discipline_key,
mld_stdmelding_omschrijving,
mld_stdmelding_notfrontend,
alg_onrgoed_niveau,
mld_stdmelding_notify,
mld_stdmeldinggroep_key,
mld_stdmelding_regime,
mld_stdmelding_planbaar,
mld_stdmelding_afmeldtext,
mld_stdmelding_subject,
mld_stdmelding_notes,
mld_stdmelding_priomatrix)
SELECT *
FROM (SELECT v_vg_iappl, 'Outlook', 0, 'H', 1, v_mg_applicaties, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iappl, 'Overige applicaties', 0, 'H', 1, v_mg_applicaties, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iapparatuur, 'Printer', 0, 'H', 1, v_mg_hardware, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iapparatuur, 'Beeldscherm', 0, 'H', 1, v_mg_hardware, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iapparatuur, 'Laptop', 0, 'H', 1, v_mg_hardware, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iapparatuur, 'Smartphone', 0, 'H', 1, v_mg_hardware, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iapparatuur, 'Overige hardware', 0, 'H', 1, v_mg_hardware, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iinlog, 'Wachtwoord vergeten', 0, 'H', 1, v_mg_inloggen, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iinlog, 'Account vergrendeld', 0, 'H', 1, v_mg_inloggen, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iinlog, 'Geen toegang tot een netwerklocatie', 0, 'H', 1, v_mg_inloggen, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iinlog, 'Overige problemen met inloggen/toegang', 0, 'H', 1, v_mg_inloggen, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iveiligh, 'Security incident', 0, 'H', 1, v_mg_veiligheid, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_iveiligh, 'Overige veiligheidsincidenten', 0, 'H', 1, v_mg_veiligheid, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_sw, 'Autorisatie voor een applicatie', 0, 'H', 1, v_mg_applicaties, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_sw, 'Autoristie voor een netwerklocatie', 0, 'H', 1, v_mg_inloggen, 1, 0, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_nsw, 'Applicaties', 0, 'H', 1, v_mg_applicaties, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_nsw, 'Hardware', 0, 'H', 1, v_mg_hardware, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_nsw, 'Inloggen/toegang', 0, 'H', 1, v_mg_inloggen, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_nsw, 'Veiligheid', 0, 'H', 1, v_mg_veiligheid, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_rv, 'Applicaties', 0, 'H', 1, v_mg_applicaties, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_rv, 'Hardware', 0, 'H', 1, v_mg_hardware, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_rv, 'Inloggen/toegang', 0, 'H', 1, v_mg_inloggen, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_rv, 'Veiligheid', 0, 'H', 1, v_mg_veiligheid, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_pr, 'Applicaties', 0, 'H', 1, v_mg_applicaties, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_pr, 'Hardware', 0, 'H', 1, v_mg_hardware, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_pr, 'Inloggen/toegang', 0, 'H', 1, v_mg_inloggen, 1, 5, 2, 2, 3, 1 FROM DUAL
UNION ALL
SELECT v_vg_pr, 'Veiligheid', 0, 'H', 1, v_mg_veiligheid, 1, 5, 2, 2, 3, 1 FROM DUAL);
-- Kenmerken, in tabel fac_imp_flex zetten en gebruik maken van procedure fac_update_flex?
-- 1: eigen tabellen
-- 2: kenmerkdomeinen
-- 3: kenmerksoort
-- 4: kenmerkmelding
-- Portaal & menu items
-- Autorisatiegroepen
-- Rechten
END;
/
------ payload end ------
SET DEFINE OFF
BEGIN
adm.systrackscriptId ('$Id$', 0);
END;
/
COMMIT;
SET ECHO OFF
SPOOL OFF
SET DEFINE ON
PROMPT Logfile of this initialisation is: &fcltlogfile