GLE-Layer-Bauvorhaben: Unterschied zwischen den Versionen
Aus kvwmap
Rahn (Diskussion | Beiträge) |
|||
(4 dazwischenliegende Versionen von 2 Benutzern werden nicht angezeigt) | |||
Zeile 4: | Zeile 4: | ||
# Bitte beachten: SYMBOLSCALE ist 10.000! | # Bitte beachten: SYMBOLSCALE ist 10.000! | ||
− | INSERT INTO layer (`Name`,`Datentyp`,`Gruppe`,`pfad`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`) VALUES('Bauvorhaben','0',@group_id,'SELECT *, \'\' AS antragsarten FROM bauvorhaben WHERE 1=1','the_geom from bauvorhaben as foo using unique oid using srid=2398','','','','','','', | + | INSERT INTO layer (`Name`,`Datentyp`,`Gruppe`,`pfad`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`) VALUES('Bauvorhaben','0',@group_id,'SELECT *, \'\' AS antragsarten FROM bauvorhaben WHERE 1=1','the_geom from bauvorhaben as foo using unique oid using srid=2398','','','','','','','','','',@connection,'','6','ergebnis','','15','pixels','2398',NULL,'1','100','100100','99','25001',NULL,'EPSG:2398','Bauvorhaben','1.1.0','image/png','60',NULL,NULL,NULL,NULL,'0','0'); |
SET @last_layer_id7273=LAST_INSERT_ID(); | SET @last_layer_id7273=LAST_INSERT_ID(); | ||
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7273,'antragsarten','antragsarten','','','unknown','','',NULL,NULL,'SubFormEmbeddedPK','7274,vorhaben_id,art;embedded','Datensätze zum Vorhaben','','3'); | INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7273,'antragsarten','antragsarten','','','unknown','','',NULL,NULL,'SubFormEmbeddedPK','7274,vorhaben_id,art;embedded','Datensätze zum Vorhaben','','3'); | ||
Zeile 13: | Zeile 13: | ||
SET @last_class_id=LAST_INSERT_ID(); | SET @last_class_id=LAST_INSERT_ID(); | ||
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_links','13','245 195 0','','0 0 0','8','18','360','',NULL,NULL,NULL,NULL,''); | INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_links','13','245 195 0','','0 0 0','8','18','360','',NULL,NULL,NULL,NULL,''); | ||
− | + | SET @last_style_id=LAST_INSERT_ID(); | |
INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); | INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); | ||
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360','',NULL,NULL,NULL,NULL,''); | INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360','',NULL,NULL,NULL,NULL,''); | ||
− | + | SET @last_style_id=LAST_INSERT_ID(); | |
INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); | INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); | ||
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Ablehnung',@last_layer_id7273,'(\'[ergebnis]\' eq \'Ablehnung\')','20',''); | INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Ablehnung',@last_layer_id7273,'(\'[ergebnis]\' eq \'Ablehnung\')','20',''); | ||
SET @last_class_id=LAST_INSERT_ID(); | SET @last_class_id=LAST_INSERT_ID(); | ||
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_unten','13','255 40 60','','0 0 0','8','18','360','',NULL,NULL,NULL,NULL,''); | INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_unten','13','255 40 60','','0 0 0','8','18','360','',NULL,NULL,NULL,NULL,''); | ||
− | + | SET @last_style_id=LAST_INSERT_ID(); | |
INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); | INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); | ||
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360','',NULL,NULL,NULL,NULL,''); | INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360','',NULL,NULL,NULL,NULL,''); | ||
− | + | SET @last_style_id=LAST_INSERT_ID(); | |
INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); | INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); | ||
INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Genehmigung',@last_layer_id7273,'(\'[ergebnis]\' eq \'Genehmigung\')','10',''); | INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Genehmigung',@last_layer_id7273,'(\'[ergebnis]\' eq \'Genehmigung\')','10',''); | ||
SET @last_class_id=LAST_INSERT_ID(); | SET @last_class_id=LAST_INSERT_ID(); | ||
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_oben','13','30 230 0','30 230 0','0 0 0','8','18','360','',NULL,NULL,NULL,NULL,''); | INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_oben','13','30 230 0','30 230 0','0 0 0','8','18','360','',NULL,NULL,NULL,NULL,''); | ||
− | + | SET @last_style_id=LAST_INSERT_ID(); | |
INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); | INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); | ||
INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360','',NULL,NULL,NULL,NULL,''); | INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360','',NULL,NULL,NULL,NULL,''); | ||
− | + | SET @last_style_id=LAST_INSERT_ID(); | |
INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); | INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); | ||
− | + | ||
INSERT INTO layer (`Name`,`Datentyp`,`Gruppe`,`pfad`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`) VALUES('Bauvorhaben Anträge','5',@group_id,'SELECT a.vorhaben_id, b.vorhaben_id||\' - \'||b.ergebnis as zum_vorhaben, art, nr, bezeichnung, bearbeiter, datum, bemerkung FROM bauvorhaben_antraege a, bauvorhaben b WHERE a.vorhaben_id=b.vorhaben_id','','','','','','','','500002','100','',@connection,'','6','','','15','pixels','2398','','1',NULL,NULL,'-1','-1','','EPSG:2398','Anträge zu Bauvorhaben','1.1.0','image/png','60','','','','','0','0'); | INSERT INTO layer (`Name`,`Datentyp`,`Gruppe`,`pfad`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`) VALUES('Bauvorhaben Anträge','5',@group_id,'SELECT a.vorhaben_id, b.vorhaben_id||\' - \'||b.ergebnis as zum_vorhaben, art, nr, bezeichnung, bearbeiter, datum, bemerkung FROM bauvorhaben_antraege a, bauvorhaben b WHERE a.vorhaben_id=b.vorhaben_id','','','','','','','','500002','100','',@connection,'','6','','','15','pixels','2398','','1',NULL,NULL,'-1','-1','','EPSG:2398','Anträge zu Bauvorhaben','1.1.0','image/png','60','','','','','0','0'); | ||
SET @last_layer_id7274=LAST_INSERT_ID(); | SET @last_layer_id7274=LAST_INSERT_ID(); | ||
Zeile 45: | Zeile 45: | ||
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'vorhaben_id','vorhaben_id','bauvorhaben_antraege','a','int2','','','1',NULL,'Text','','ID Vorhaben','','0'); | INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'vorhaben_id','vorhaben_id','bauvorhaben_antraege','a','int2','','','1',NULL,'Text','','ID Vorhaben','','0'); | ||
INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'zum_vorhaben','zum_vorhaben','','','text','','',NULL,NULL,'SubFormFK','7273,vorhaben_id;no_new_window','Bauvorhaben','','1'); | INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'zum_vorhaben','zum_vorhaben','','','text','','',NULL,NULL,'SubFormFK','7273,vorhaben_id;no_new_window','Bauvorhaben','','1'); | ||
− | + | ||
− | UPDATE layer_attributes SET options = REPLACE(options, '7273', @last_layer_id7273) WHERE layer_id IN( | + | UPDATE layer_attributes SET options = REPLACE(options, '7273', @last_layer_id7273) WHERE layer_id IN(@last_layer_id7273,@last_layer_id7274) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK'); |
− | UPDATE layer_attributes SET options = REPLACE(options, '7274', @last_layer_id7274) WHERE layer_id IN( | + | UPDATE layer_attributes SET options = REPLACE(options, '7274', @last_layer_id7274) WHERE layer_id IN(@last_layer_id7273,@last_layer_id7274) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK'); |
Aktuelle Version vom 20. Oktober 2011, 14:17 Uhr
SET @group_id = 1; SET @connection = 'user=xxxx password=xxxx dbname=kvwmapsp'; # Bitte beachten: SYMBOLSCALE ist 10.000! INSERT INTO layer (`Name`,`Datentyp`,`Gruppe`,`pfad`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`) VALUES('Bauvorhaben','0',@group_id,'SELECT *, \'\' AS antragsarten FROM bauvorhaben WHERE 1=1','the_geom from bauvorhaben as foo using unique oid using srid=2398',,,,,,,,,,@connection,,'6','ergebnis',,'15','pixels','2398',NULL,'1','100','100100','99','25001',NULL,'EPSG:2398','Bauvorhaben','1.1.0','image/png','60',NULL,NULL,NULL,NULL,'0','0'); SET @last_layer_id7273=LAST_INSERT_ID(); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7273,'antragsarten','antragsarten',,,'unknown',,,NULL,NULL,'SubFormEmbeddedPK','7274,vorhaben_id,art;embedded','Datensätze zum Vorhaben',,'3'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7273,'ergebnis','ergebnis','bauvorhaben','bauvorhaben','varchar',,,'1','50','Auswahlfeld','\'Genehmigung\',\'Ablehnung\',\'Zurückweisung/Rücknahme\,'Ergebnis',,'1'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7273,'the_geom','the_geom','bauvorhaben','bauvorhaben','geometry','POINT',,'1',NULL,'Geometrie',,,,'2'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7273,'vorhaben_id','vorhaben_id','bauvorhaben','bauvorhaben','int4',,,'1',NULL,'Text',,'Vorhaben-ID',,'0'); INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Zurückweisung/Rücknahme',@last_layer_id7273,'(\'[ergebnis]\' eq \'Zurückweisung/Rücknahme\')','30',); SET @last_class_id=LAST_INSERT_ID(); INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_links','13','245 195 0',,'0 0 0','8','18','360',,NULL,NULL,NULL,NULL,); SET @last_style_id=LAST_INSERT_ID(); INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360',,NULL,NULL,NULL,NULL,); SET @last_style_id=LAST_INSERT_ID(); INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Ablehnung',@last_layer_id7273,'(\'[ergebnis]\' eq \'Ablehnung\')','20',); SET @last_class_id=LAST_INSERT_ID(); INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_unten','13','255 40 60',,'0 0 0','8','18','360',,NULL,NULL,NULL,NULL,); SET @last_style_id=LAST_INSERT_ID(); INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360',,NULL,NULL,NULL,NULL,); SET @last_style_id=LAST_INSERT_ID(); INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1); INSERT INTO classes (`Name`,`Layer_ID`,`Expression`,`drawingorder`,`text`) VALUES('Genehmigung',@last_layer_id7273,'(\'[ergebnis]\' eq \'Genehmigung\')','10',); SET @last_class_id=LAST_INSERT_ID(); INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'pfeil_oben','13','30 230 0','30 230 0','0 0 0','8','18','360',,NULL,NULL,NULL,NULL,); SET @last_style_id=LAST_INSERT_ID(); INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,2); INSERT INTO styles (`symbol`,`symbolname`,`size`,`color`,`backgroundcolor`,`outlinecolor`,`minsize`,`maxsize`,`angle`,`angleitem`,`antialias`,`width`,`minwidth`,`maxwidth`,`sizeitem`) VALUES(NULL,'punkt','20','250 240 80','250 240 80','0 0 0','15','25','360',,NULL,NULL,NULL,NULL,); SET @last_style_id=LAST_INSERT_ID(); INSERT INTO u_styles2classes (style_id, class_id,drawingorder) VALUES (@last_style_id, @last_class_id,1);
INSERT INTO layer (`Name`,`Datentyp`,`Gruppe`,`pfad`,`Data`,`schema`,`document_path`,`tileindex`,`tileitem`,`labelangleitem`,`labelitem`,`labelmaxscale`,`labelminscale`,`labelrequires`,`connection`,`printconnection`,`connectiontype`,`classitem`,`filteritem`,`tolerance`,`toleranceunits`,`epsg_code`,`template`,`queryable`,`transparency`,`drawingorder`,`minscale`,`maxscale`,`offsite`,`ows_srs`,`wms_name`,`wms_server_version`,`wms_format`,`wms_connectiontimeout`,`wms_auth_username`,`wms_auth_password`,`wfs_geom`,`selectiontype`,`querymap`,`logconsume`) VALUES('Bauvorhaben Anträge','5',@group_id,'SELECT a.vorhaben_id, b.vorhaben_id||\' - \'||b.ergebnis as zum_vorhaben, art, nr, bezeichnung, bearbeiter, datum, bemerkung FROM bauvorhaben_antraege a, bauvorhaben b WHERE a.vorhaben_id=b.vorhaben_id',,,,,,,,'500002','100',,@connection,,'6',,,'15','pixels','2398',,'1',NULL,NULL,'-1','-1',,'EPSG:2398','Anträge zu Bauvorhaben','1.1.0','image/png','60',,,,,'0','0'); SET @last_layer_id7274=LAST_INSERT_ID(); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'art','art','bauvorhaben_antraege','a','varchar',,,'1','100','Auswahlfeld','\'Bauvoranfrage\',\'Bauantrag\',\'Widerspruch\',\'Klage\',\'Genehmigungsfreistellung\,'Antragsart',,'2'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'bearbeiter','bearbeiter','bauvorhaben_antraege','a','varchar',,,'1','30','Auswahlfeld','\'Müller\',\'Meier\',\'Schulze\,'Bearbeiter','Antragsbearbeitender Mitarbeiter','5'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'bemerkung','bemerkung','bauvorhaben_antraege','a','text',,,'1',NULL,'Textfeld',,'Bemerkung',,'7'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'bezeichnung','bezeichnung','bauvorhaben_antraege','a','text',,,'1',NULL,'Textfeld',,'Bezeichnung',,'4'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'datum','datum','bauvorhaben_antraege','a','date',,,'1',NULL,'Time',,'Datum Bescheid',,'6'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'nr','nr','bauvorhaben_antraege','a','varchar',,,'1','10','Text',,'Nummer',,'3'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'vorhaben_id','vorhaben_id','bauvorhaben_antraege','a','int2',,,'1',NULL,'Text',,'ID Vorhaben',,'0'); INSERT INTO layer_attributes (`layer_id`,`name`,`real_name`,`tablename`,`table_alias_name`,`type`,`geometrytype`,`constraints`,`nullable`,`length`,`form_element_type`,`options`,`alias`,`tooltip`,`order`) VALUES(@last_layer_id7274,'zum_vorhaben','zum_vorhaben',,,'text',,,NULL,NULL,'SubFormFK','7273,vorhaben_id;no_new_window','Bauvorhaben',,'1');
UPDATE layer_attributes SET options = REPLACE(options, '7273', @last_layer_id7273) WHERE layer_id IN(@last_layer_id7273,@last_layer_id7274) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK'); UPDATE layer_attributes SET options = REPLACE(options, '7274', @last_layer_id7274) WHERE layer_id IN(@last_layer_id7273,@last_layer_id7274) AND form_element_type IN ('SubFormPK', 'SubFormFK', 'SubFormEmbeddedPK');