Browse Source

Maske Spaltenlayout kopieren als Kopie von Maske kopieren erstellt

master
Marlies Winterstein 2 weeks ago
parent
commit
30cd8cbac8
  1. 9
      src-modules/module/rpta/masken/48410_felderinfo.unl
  2. 1
      src-modules/module/rpta/masken/48410_maske_system_bez.unl
  3. 6
      src-modules/module/rpta/masken/48410_masken_felder_bez.unl
  4. 124
      src-modules/module/rpta/masken/48410_maskeninfo.unl
  5. 1
      src-modules/module/rpta/masken/48410_sachgeb_maske_bez.unl

9
src-modules/module/rpta/masken/48410_felderinfo.unl

@ -0,0 +1,9 @@
48410^zu kopierendes Spaltenlayout^0^0^0^150^450^1^integer^30^1^1^<<SQL>> select tid, uniquename || ' - ' || caption from rpta_column_layout order by caption;^ ^ ^
48411^Neuer Name^2^0^0^150^250^1^char^100^1^0^^ ^ ^
48412^Neuer Schlüssel^1^0^0^150^200^1^char^30^1^0^^ ^ ^
48413^Erläuterung^12^0^0^150^400^4^char^240^0^0^^ ^ ^
48414^Art der Kopie^1065^0^0^100^150^1^char^30^1^1^<<SQL>> select 'makro','Makrobericht' from xdummy \
union select 'sximport','SX-Importkopie' from xdummy\
union select 'standard','Standardkopie' from xdummy\
;^hidden^<<SQL>> select 'standard','Standardkopie' from xdummy;^
48415^Achtung:^100^0^0^150^450^1^char^60^0^8^<<SQL>> select 'Vorhandene Spaltenlayouts mit gleichem Schlüssel werden überschrieben!' from xdummy;^ ^<<SQL>> select 'Vorhandene Spaltenlayouts mit gleichem Schlüssel werden überschrieben!' from xdummy;^

1
src-modules/module/rpta/masken/48410_maske_system_bez.unl

@ -0,0 +1 @@
48410^9^

6
src-modules/module/rpta/masken/48410_masken_felder_bez.unl

@ -0,0 +1,6 @@
48410^48410^
48410^48411^
48410^48412^
48410^48413^
48410^48414^
48410^48415^

124
src-modules/module/rpta/masken/48410_maskeninfo.unl

@ -0,0 +1,124 @@
48410^Spaltenlayout kopieren^--freemarker template\
<#include "SQL_lingua_franca"/>\
<#include "SuperX_general"/>\
<sqlvars>\
<sqlvar name="start_serial">\
select max(tid)+1 from rpta_column2layout;\
</sqlvar>\
</sqlvars>\
--Autor: D. Quathamer\
--Datum: 2.4.2002\
\
<#assign zeichen1="<"> \
<#assign zeichen2=">"> \
<#assign zeichen3="/"> \
<#if SQLdialect='Postgres'>\
begin work;\
</#if>\
\
create temp table tmp_rpta_column_layout \
(\
tid integer NOT NULL, --vorher serial\
uniquename varchar(255) NOT NULL,\
caption varchar(255),\
resultset_id integer,\
whereclause text,\
description text,\
userinfo_id integer,\
sortnr integer,\
sortclause text,\
is_virtual smallint DEFAULT 1 NOT NULL\
);\
\
create temp table tmp_rpta_column2layout \
(\
tid serial NOT NULL, \
column_id integer,\
layout_id integer,\
sortnr smallint,\
is_visible smallint DEFAULT 1,\
visible_size smallint,\
format_code_id integer,\
targetfieldname varchar(255),\
caption varchar(255),\
description text\
);\
ALTER SEQUENCE tmp_rpta_column2layout_tid_seq RESTART with ${start_serial};\
insert into tmp_rpta_column_layout select * from rpta_column_layout where tid=<<zu kopierendes Spaltenlayout>>;\
\
insert into tmp_rpta_column2layout \
(\
column_id,\
layout_id,\
sortnr,\
is_visible,\
visible_size,\
format_code_id,\
targetfieldname,\
caption,\
description\
)\
select \
column_id,\
layout_id,\
sortnr,\
is_visible,\
visible_size,\
format_code_id,\
targetfieldname,\
caption,\
description\
from rpta_column2layout where layout_id=<<zu kopierendes Spaltenlayout>>;\
\
update tmp_rpta_column_layout set uniquename=<<Neuer Schlüssel>>;\
update tmp_rpta_column_layout set caption=<<Neuer Name>>; \
update tmp_rpta_column_layout set userinfo_id=<<UserID>>;\
/*update tmp_rpta_column_layout set description=<<Erläuterung>>;*/\
\
--Falls das neue Layout bereits existiert, wird es gelöscht:\
delete from rpta_column2layout where layout_id = (select tid from rpta_column_layout where uniquename=<<Neuer Schlüssel>>)\
and (select administration from userinfo where tid=<<UserID>>)= 1;\
delete from rpta_column_layout where uniquename=<<Neuer Schlüssel>>\
and (select administration from userinfo where tid=<<UserID>>)= 1;\
\
update tmp_rpta_column_layout set tid = (select (max(tid)+1) from rpta_column_layout);\
update tmp_rpta_column2layout set layout_id = (select tid from tmp_rpta_column_layout);\
\
\
insert into rpta_column_layout select * from tmp_rpta_column_layout \
where (select administration from userinfo where tid=<<UserID>>)= 1;\
insert into rpta_column2layout select * from tmp_rpta_column2layout \
where (select administration from userinfo where tid=<<UserID>>)= 1;\
\
\
<#if SQLdialect='Postgres'>\
commit;\
</#if>\
\
create temp table tmp_ergebnis \
(sp1 varchar(150),\
sp2 varchar(150), sp3 varchar(150)); \
\
insert into tmp_ergebnis (sp1,sp2)\
select 'Ergebnis', 'Benutzerrechte reichen nicht aus. Spaltenlayout wurde nicht kopiert' from xdummy where (select administration from userinfo where tid=<<UserID>>)!= 1;\
\
insert into tmp_ergebnis (sp1,sp2,sp3)\
select 'Neues Spaltenlayout:',uniquename || '- ' || caption,'../edit/rpta/rpta_column_layout_edit.jsp|tid=' || tid from rpta_column_layout where tid = (select tid from tmp_rpta_column_layout);\
--wird ja über edit vom Spaltenlayout angeboten\
--insert into tmp_ergebnis (sp1,sp2,sp3)\
--select 'Spalte:',column_id || '- ' || caption,'../edit/rpta/rpta_column2layout_edit.jsp|tid=' || tid from rpta_column2layout M where tid in (select tid from tmp_rpta_column2layout); \
\
select sp1,sp2,sp3 as nextedit from tmp_ergebnis ;^XIL List\
drop_and_delete movable_columns sizable_columns horizontal_scrolling\
white_space_color=COLOR_WHITE fixed_columns=2\
min_heading_height=35\
Column CID=0 heading_text="Ergebnis " center_heading\
row_selectable col_selectable heading_platform readonly\
width=50 text_size=100\
Column CID=1 heading_text=" Wert " center_heading\
row_selectable col_selectable heading_platform readonly\
width=50 text_size=100\
Column CID=2 heading_text=" Bearbeiten" center_heading\
row_selectable col_selectable heading_platform readonly\
width=50 text_size=100\
@@@^ ^ ^Eine neue Maske kopieren^drop table tmp_ergebnis;drop table tmp_rpta_column_layout;drop table tmp_rpta_column2layout;^^2^440^360^^1^^

1
src-modules/module/rpta/masken/48410_sachgeb_maske_bez.unl

@ -0,0 +1 @@
8^48410^
Loading…
Cancel
Save