Browse Source

Verbesserter Webanwendung Manager #4

userinfo_gueltigkeit
Daniel Quathamer 1 year ago
parent
commit
ee0a39e3ff
  1. 6
      .classpath
  2. 49
      src/de/memtext/util/FileUtils.java
  3. 4
      src/de/superx/bin/KettleExecutor.java
  4. 2
      src/de/superx/bin/SimpleTransform.java
  5. 8
      src/de/superx/bin/fm/EtlStarter.java
  6. 3
      src/de/superx/common/Maske.java
  7. 4
      src/de/superx/common/TemplateProcessor.java
  8. 343
      src/de/superx/etl/EtlUtils.java
  9. 26
      src/de/superx/sec/StringCheck.java
  10. 13
      src/de/superx/servlet/SxPool.java
  11. 15
      src/de/superx/servlet/UserInitializer.java
  12. 113
      src/de/superx/sxrest/LogsProvider.java
  13. 63
      src/de/superx/sxrest/MaskLogs.java
  14. 2
      superx/WEB-INF/conf/edustore/db/bin/saxon_transform.x
  15. 7
      superx/WEB-INF/conf/edustore/db/bin/sx_transform.x
  16. 4
      superx/WEB-INF/conf/edustore/db/conf/function.xsl
  17. 8
      superx/WEB-INF/conf/edustore/db/conf/module_upgrade.xsl
  18. 2
      superx/WEB-INF/conf/edustore/db/install/conf/builddatum.txt
  19. 2
      superx/WEB-INF/conf/edustore/db/install/conf/his1/dbconv/sch.eduetl/sichten.tab
  20. 2
      superx/WEB-INF/conf/edustore/db/install/conf/his1/dbconv/view.eduetl/dim_kreis.view
  21. 135
      superx/WEB-INF/conf/edustore/db/install/conf/his1/edustore_doc/kern_load.txt
  22. 29618
      superx/WEB-INF/conf/edustore/db/install/conf/kern.html
  23. 2
      superx/WEB-INF/conf/edustore/db/install/conf/kern.rtf
  24. 9
      superx/WEB-INF/conf/edustore/db/install/conf/kern.xml
  25. 2
      superx/WEB-INF/conf/edustore/db/install/conf/sx_fields_fuellen.sql
  26. 4
      superx/WEB-INF/conf/edustore/db/install/conf/sx_tables_fuellen.sql
  27. 360
      superx/WEB-INF/conf/edustore/db/install/kern_install_ids.sql
  28. 349
      superx/WEB-INF/conf/edustore/db/install/kern_install_pg.sql
  29. 6
      superx/WEB-INF/conf/edustore/db/install/masken/71770_maskeninfo.unl
  30. 2
      superx/WEB-INF/conf/edustore/db/install/prozeduren/proc_sp_user_orga_child_ids.sql
  31. 16
      superx/WEB-INF/conf/edustore/db/install/prozeduren/proc_sp_user_themen_ids.sql
  32. 2
      superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/kern_feste_konstanten_fuellen.sql
  33. 87660
      superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/release_unloads/dim_datum.unl
  34. 4
      superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/release_unloads/sx_captions.unl
  35. 2
      superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/release_unloads/sx_repository.unl
  36. 5
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_pre_upgrade_ids.sql
  37. 4
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_fields_ids.sql
  38. 2
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_fields_pg.sql
  39. 345
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_functions_ids.sql
  40. 345
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_functions_pg.sql
  41. 4
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_tables_ids.sql
  42. 2
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_tables_pg.sql
  43. 30
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_views_ids.sql
  44. 6
      superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_views_pg.sql
  45. 49
      superx/WEB-INF/conf/edustore/db/install/upgrade/kernmodul_upgrade_man.sql
  46. 1
      superx/WEB-INF/conf/obsoletfiles.txt
  47. 40
      superx/WEB-INF/http_get_masken_blacklist.txt
  48. 18
      superx/WEB-INF/http_get_masken_whitelist_vorlage.txt
  49. 2
      superx/WEB-INF/kern_dbforms-config_ids.xml
  50. 2
      superx/WEB-INF/kern_dbforms-config_pg.xml
  51. BIN
      superx/WEB-INF/lib/ifxjdbc-4.50.4.1.jar
  52. BIN
      superx/WEB-INF/lib/ifxjdbc.jar
  53. BIN
      superx/WEB-INF/lib/superx5.0.jar
  54. 2
      superx/edit/kern/sichten_edit.jsp
  55. 211
      superx/edit/kern/webapp_manager.jsp
  56. 34
      superx/edit/not_authenticated.htm
  57. 33
      superx/edit/not_authorized.htm
  58. BIN
      superx/images/superx_logo.png
  59. 1
      superx/xml/maskComponents_html.xsl
  60. 6
      superx/xml/menue_html.xsl
  61. 2
      superx/xml/menue_html_dojo.xsl
  62. 34
      superx/xml/pageComponents_html.xsl
  63. 17
      superx/xml/resultset_html.xsl

6
.classpath

@ -297,11 +297,6 @@ @@ -297,11 +297,6 @@
<attribute name="module" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="lib" path="/home/superx/git/kern/superx/WEB-INF/lib/ifxjdbc.jar">
<attributes>
<attribute name="module" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="lib" path="/home/superx/git/kern/superx/WEB-INF/lib/imap.jar">
<attributes>
<attribute name="module" value="true"/>
@ -867,5 +862,6 @@ @@ -867,5 +862,6 @@
<classpathentry kind="lib" path="superx/WEB-INF/lib/saxon-he-10.5.jar"/>
<classpathentry kind="lib" path="superx/WEB-INF/lib/saxon-xqj-10.5.jar"/>
<classpathentry kind="lib" path="superx/WEB-INF/lib/saxon-he-test-10.5.jar"/>
<classpathentry kind="lib" path="superx/WEB-INF/lib/ifxjdbc-4.50.4.1.jar"/>
<classpathentry kind="output" path="superx/WEB-INF/classes"/>
</classpath>

49
src/de/memtext/util/FileUtils.java

@ -3,6 +3,7 @@ package de.memtext.util; @@ -3,6 +3,7 @@ package de.memtext.util;
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.BufferedReader;
import java.io.ByteArrayOutputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
@ -10,6 +11,7 @@ import java.io.FileOutputStream; @@ -10,6 +11,7 @@ import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.RandomAccessFile;
import java.io.StringWriter;
import java.net.URL;
import java.net.URLConnection;
@ -321,5 +323,52 @@ public class FileUtils { @@ -321,5 +323,52 @@ public class FileUtils {
return fileContents;
}
/*
Unix tail -n in java
Returns n lines from the end of a (potentially big) textfile, useful für big Logfiles
*/
public static String tail(File myFile, int nLines) throws IOException {
int numberOfLines = 0;
StringBuilder builder = new StringBuilder();
try (RandomAccessFile randomAccessFile = new RandomAccessFile(myFile, "r")) {
try (ByteArrayOutputStream myByteArrayOutputStream = new ByteArrayOutputStream()) {
long fileLength = myFile.length() - 1;
/*
* go to the end of the file:
*/
randomAccessFile.seek(fileLength);
for (long myPointer = fileLength; myPointer >= 0; myPointer--) {
randomAccessFile.seek(myPointer);
byte b = (byte) randomAccessFile.read();
if (b == '\n') {
numberOfLines++;
// identify last line, often terminated with a line separator
if (numberOfLines == (nLines + 1))
break;
}
myByteArrayOutputStream.write(b);
fileLength = fileLength - myPointer;
}
/*
* Read in reverse order
*/
byte[] a = myByteArrayOutputStream.toByteArray();
int start = 0;
int mid = a.length / 2;
int end = a.length - 1;
while (start < mid) {
byte temp = a[end];
a[end] = a[start];
a[start] = temp;
start++;
end--;
}// End while-loop
return new String(a).trim();
} // End try-with-resources
} // End 2 try-with-resources
}
}

4
src/de/superx/bin/KettleExecutor.java

@ -46,7 +46,7 @@ public class KettleExecutor { @@ -46,7 +46,7 @@ public class KettleExecutor {
public StringBuffer perform() throws IOException, SQLException, DBServletException {
try {
initSxJob();
EtlStarter es = new EtlStarter();
EtlStarter es = new EtlStarter(this.mandantenID);
if (!isModusVorschau()) {
check_sql("vor");
}
@ -136,6 +136,8 @@ public class KettleExecutor { @@ -136,6 +136,8 @@ public class KettleExecutor {
String mandantenID = GetOpts.getValue("-mandantenID");
String job_uniquename = GetOpts.getValue("-job_uniquename");
String webinfpfad=GetOpts.getValue("-WEB_INF_PFAD");
if(webinfpfad != null && !webinfpfad.equals(""))
SuperXManager.setWEB_INFPfad(GetOpts.getValue("-WEB_INF_PFAD"));
SuperXManager.setModuleDir(GetOpts.getValue("-MODULE_PFAD"));
String path_to_uploadfile = "";

2
src/de/superx/bin/SimpleTransform.java

@ -63,7 +63,7 @@ public class SimpleTransform { @@ -63,7 +63,7 @@ public class SimpleTransform {
_out = GetOpts.getValue("-OUT");
if (GetOpts.isPresent("-method"))
method = GetOpts.getValue("-method");
if (GetOpts.isPresent("-param"))
if (GetOpts.isPresent("-params"))
_params = GetOpts.getValue("-params");
//logger.initRaw(dosql.class)

8
src/de/superx/bin/fm/EtlStarter.java

@ -38,9 +38,11 @@ public class EtlStarter implements TemplateTransformModel { @@ -38,9 +38,11 @@ public class EtlStarter implements TemplateTransformModel {
public static final String PARAM_KEY_STEP = "etl_step";
public static final String PARAM_LOGLEVEL = "log_level";
private static Logger logger = Logger.getLogger(EtlStarter.class);
private String mandantenId = "default";
private LogLevel logLevel = LogLevel.BASIC;
public EtlStarter(String mandantenId) {
this.mandantenId = mandantenId;
}
@Override
public Writer getWriter(Writer paramWriter, Map paramMap) throws TemplateModelException, IOException {
logger.info("**EtlStarter**");
@ -210,7 +212,7 @@ public class EtlStarter implements TemplateTransformModel { @@ -210,7 +212,7 @@ public class EtlStarter implements TemplateTransformModel {
String jobfile = "file:///home/superx/data-integration/exceltest.kjb";
Map<String, String> jobParams = new HashMap<String, String>();
jobParams.put("PATH_TO_EXCELFILE", "/home/superx/tmp/testexcel2.xlsx");
EtlStarter es = new EtlStarter();
EtlStarter es = new EtlStarter("default");
es.kettleCallEmbedded("default",jobfile, jobParams,false);
}

3
src/de/superx/common/Maske.java

@ -1038,8 +1038,7 @@ public class Maske extends NamedIdObject implements Serializable { @@ -1038,8 +1038,7 @@ public class Maske extends NamedIdObject implements Serializable {
: this.navi;
StringBuffer result = new StringBuffer("<?xml version=\"1.0\" encoding=\"" + SqlStringUtils.getEncoding()
+ "\"?>\n<ergebnisse MandantenID=\"" + mandantenID + "\" jsessionid=\"" + request.getSession().getId()
+ "\" datum=\"" + DateUtils.getTodayString() + "\" zeit=\"" + DateUtils.getNowString() + "\" isMakro=\""
+ "\"?>\n<ergebnisse MandantenID=\"" + mandantenID + "\" datum=\"" + DateUtils.getTodayString() + "\" zeit=\"" + DateUtils.getNowString() + "\" isMakro=\""
+ (isMakro() ? "true" : "false") + "\" " + "hisinone_active=\""
+ (SuperXManager.isHis1 ? "true" : "false") + "\" " + "hisinone_refapp=\"" + SuperXManager.his1_refapp
+ "\" showNavigation=\"" + showNavigation + "\">\n");

4
src/de/superx/common/TemplateProcessor.java

@ -90,7 +90,7 @@ public class TemplateProcessor { @@ -90,7 +90,7 @@ public class TemplateProcessor {
// die Formatierungseinstellung wird u.a. für sortnr gebraucht,
// sonst erscheint z.B. 1000 als 1.000
myCfg.setSetting("number_format", "###########.####");
// TODO myCfg.setSharedVariable("etl", new EtlStarter(mandantenID));
myCfg.setSharedVariable("etl", new EtlStarter(mandantenID));
} catch (TemplateException e) {
System.out.println("FreeMarker warning: " + e);
e.printStackTrace();
@ -220,7 +220,7 @@ public class TemplateProcessor { @@ -220,7 +220,7 @@ public class TemplateProcessor {
List<String> results = new ArrayList<String>();
for (Iterator it = roh.iterator(); it.hasNext();) {
SxResultRow zeile = (SxResultRow) it.next();
results.add((String) zeile.get(0));
results.add( zeile.get(0).toString());
}
hmap.put(varname, results);

343
src/de/superx/etl/EtlUtils.java

@ -0,0 +1,343 @@ @@ -0,0 +1,343 @@
/*
* de.superx.etl - a package for controlling ETL routines
* Copyright (C) 2021 Daniel Quathamer <danielq@memtext.de>
*
* This package is licensed under the CampusSource License;
* http://www.campussource.de/org/license/
*/
package de.superx.etl;
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.StringReader;
import java.io.StringWriter;
import java.io.UnsupportedEncodingException;
import java.net.URISyntaxException;
import java.util.Enumeration;
import java.util.Properties;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
import javax.xml.xpath.XPath;
import javax.xml.xpath.XPathConstants;
import javax.xml.xpath.XPathExpressionException;
import javax.xml.xpath.XPathFactory;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
import de.superx.servlet.SuperXManager;
/**
*/
public class EtlUtils {
public static final String NEWLINE=System.getProperty("line.separator");
public static final String PATHSEP=File.separator;
public static String WEBINFDIR=SuperXManager.getWEB_INFPfad();
public static String SUPERX_DIR=(System.getProperties().containsKey("SUPERX_DIR")? System.getProperty("SUPERX_DIR"):"");
public static String MODUL_ROOT_PFAD=(System.getProperties().containsKey("MODULE_PFAD")? System.getProperty("MODULE_PFAD"):SUPERX_DIR+PATHSEP+"db"+PATHSEP+"module");
public static String MODUL_ROHDATEN_SUBPFAD=PATHSEP+"rohdaten"+PATHSEP;
public static void main(String args[]) {
try {
String webinfdir=getWebinfDirectory();;
System.out.println(webinfdir);
} catch (URISyntaxException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
public static Properties convertStringToProperty(String inp) throws IOException
{
Properties myProps = new Properties();
myProps.load(new StringReader(inp));
return myProps;
}
/* Ein EtlJob hat vordefininierte Parameter, die zur Laufzeit durch die runTimeParams ersetzt werden.
* Der merge findet hier statt:
*/
public static Properties mergeParamProperties(Properties params, Properties runTimeParams)
{
if(params==null) {
//Job ist noch unbekannt, oder hat keine vordef. Parameter
//in diesem Falle werden die Standardparameter übergeben (Modulpfade, SUPERX_DIR)
params=runTimeParams;
}
else
{
String parsedParam;
Enumeration runTimeParamNames = runTimeParams.propertyNames();
while (runTimeParamNames.hasMoreElements()) {
String runTimeParamName = (String)runTimeParamNames.nextElement();
String runTimeParamValue = runTimeParams.getProperty(runTimeParamName);
Enumeration paramNames = params.propertyNames();
while (paramNames.hasMoreElements()) {
String paramName=(String)paramNames.nextElement();
String paramValue=params.getProperty(paramName);
if(paramName.equals(runTimeParamName) ) {
paramValue=runTimeParamValue;
params.setProperty(paramName, paramValue);
}
if(paramValue.indexOf("$"+runTimeParamName)>-1) {
paramValue=de.memtext.util.StringUtils.replace(paramValue,"$"+runTimeParamName, runTimeParamValue);
params.setProperty(paramName, paramValue);
}
}
}
}
return params;
}
public static String parseStringAgainstParams(String targetString, Properties params)
{
String parsedParam;
Enumeration paramNames = params.propertyNames();
while (paramNames.hasMoreElements()) {
String paramName = (String)paramNames.nextElement();
String paramValue = params.getProperty(paramName);
if(targetString.indexOf("$"+paramName)>-1) {
targetString=de.memtext.util.StringUtils.replace(targetString,"$"+paramName, paramValue);
}
}
return targetString;
}
public static void initJobEnvironment()
{
String initVar="";
if(System.getProperty("WEBINFDIR") ==null)
{
try {
initVar=de.superx.servlet.SuperXManager.getWEB_INFPfad();
if(initVar==null || initVar.equals("."))
{
//ermittle webinfdir
initVar=getWebinfDirectory();
}
} catch (Exception e) {
// do nothing, try another
}
WEBINFDIR=initVar;
}
if(System.getProperty("SUPERX_DIR") ==null)
{
SUPERX_DIR=WEBINFDIR+PATHSEP+"conf"+PATHSEP+"edustore";
}
}
private static String getJarName()
{
return new File(EtlUtils.class.getProtectionDomain()
.getCodeSource()
.getLocation()
.getPath())
.getName();
}
private static boolean runningFromJar()
{
String jarName = getJarName();
return jarName.contains(".jar");
}
public static String getWebinfDirectory() throws URISyntaxException
{
if (runningFromJar())
{
return getWebinfDirectoryFromJar();
} else
{
return getWebinfDirectoryFromClass();
}
}
private static String getWebinfDirectoryFromClass()
{
File f= new File(EtlUtils.class.getProtectionDomain()
.getCodeSource()
.getLocation()
.getPath()+PATHSEP+"..");
String class_path=f.getAbsolutePath();
return class_path;
}
private static String getWebinfDirectoryFromJar() throws URISyntaxException
{
File f1=new File(EtlUtils.class.getProtectionDomain().getCodeSource().getLocation().toURI().getPath());
//now we're got superx.jar, go up one level
File f2=new File(f1.getParent());
//now we've got WEB-INF/lib, return WEB-INF:
return f2.getParent();
}
/* die folgenden 2 Methoden
* getFileContentsWithEncoding
* saveFileContentsWithEncoding
* sind in kern5.0 in de.superx.util.FileUtils
* wg. abwärtskompatiblität hierhin kopiert, sollten langfristig wieder weg
*/
public static String getFileContentsWithEncoding(String filePath, String encoding) {
File f = new File(filePath);
if (!f.exists()) {
System.out.println("Fehler: Datei " + filePath + " existiert nicht.");
return null;
}
String fileContents = "";
if (encoding == null || encoding.trim().equals("")) {
encoding = System.getProperty("file.encoding");
}
try {
// --- IputStream und OutputStream generieren ---//
FileInputStream fis = new FileInputStream(f);
// Wenn Quelldatei Unicode, dann speziellen Reader nutzen
BufferedReader in;
//BufferedReader ist schneller bei großen Dateien
in = new BufferedReader(new InputStreamReader(fis, encoding));
// --- Output-Stream der temporären Datei erzeugen ---//
StringWriter out = new StringWriter();
// --- Verarbeiten der Datei ---//
String text;
text = in.readLine();
while (text != null) { // Datei nicht leer
out.write(text);
out.write(System.getProperty("line.separator"));
text = in.readLine();
}
if (!(out == null)) {
fileContents = out.toString();
}
} catch (FileNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (UnsupportedEncodingException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return fileContents;
}
public static void saveFileContentsWithEncoding(String filename, String contents, String encoding) throws
FileNotFoundException,
IOException
{
File f = new File(filename);
BufferedReader in;
BufferedWriter out;
//Default encoding ist utf-8
if (encoding == null) encoding = System.getProperty("file.encoding");
// --- Output-Stream der temporären Datei erzeugen ---//
out = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(f), encoding));
out.write(contents);
out.close();
}//Ende der Methode
/*SAX Document aus XML-Datei erzeugen */
public static Document buildDocumentFromXmlFile(String srcFile)
throws ParserConfigurationException, FileNotFoundException, SAXException, IOException {
Document mydomres;
org.xml.sax.InputSource is;
DocumentBuilderFactory dfactory = DocumentBuilderFactory.newInstance();
DocumentBuilder builder = dfactory.newDocumentBuilder();
FileInputStream in = new FileInputStream(srcFile);
is=new org.xml.sax.InputSource(in);
mydomres = builder.newDocument();
mydomres = builder.parse(is);
return mydomres;
}
/***
* TODO: nach merge in master diese Methode löschen, und auf de.memtext.util.XMLUtils.parseXml(String) verweisen
* @author Witt This function parses XML-containing string into documents while
* preserving the namespaces and is primarily meant to be used withing
* (jUnit) test cases
* @param xmlString
* @return
* @throws ParserConfigurationException
* @throws SAXException
* @throws IOException
*/
public static Document parseXml(String xmlString) throws ParserConfigurationException, SAXException, IOException {
DocumentBuilderFactory myFactory = DocumentBuilderFactory.newInstance();
myFactory.setNamespaceAware(true);
DocumentBuilder myBuilder;
myBuilder = myFactory.newDocumentBuilder();
Document myDocument = myBuilder.parse(new InputSource(new StringReader(xmlString)));
return myDocument;
}
/**
* @param src
* @param tidInXmlFile
* @return
* @throws ParserConfigurationException
* @throws SAXException
* @throws IOException
* @throws XPathExpressionException
*/
public static boolean isNodeValueInXml(String src, String searchPath, String expectedValue)
throws ParserConfigurationException, SAXException, IOException, XPathExpressionException {
boolean b=false;
Document mydomres =de.superx.etl.EtlUtils.parseXml(src);
XPathFactory factory = new net.sf.saxon.xpath.XPathFactoryImpl();
XPath xPath = factory.newXPath();
Node myNode=(Node) xPath.compile(searchPath).evaluate(
mydomres, XPathConstants.NODE);
if(myNode!=null)
{
String foundValue=de.memtext.util.XMLUtils.getTheValue(myNode);
if(!(foundValue==null) && foundValue.trim().equals(expectedValue))
b=true;
}
return b;
}
public static String translateReturnCode(int returnCode)
{
String returnString="Fehlerhaft";
if(returnCode==0)
returnString="Erfolg";
return returnString;
}
}

26
src/de/superx/sec/StringCheck.java

@ -0,0 +1,26 @@ @@ -0,0 +1,26 @@
package de.superx.sec;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
/*
* Check for letters, numbers and characters that don't cause problems in SQL when enclosed in ''
*/
public class StringCheck implements InputCheck {
public static String STRING_CHECK = "string";
private static String LETTER = "\\p{gc=L}"; // Unicode General Category "Letter"
private static String DECIMAL = "\\p{gc=Nd}"; // Unicode General Category "Decimal Number"
private static String SEPARATOR = "\\p{gc=Z}"; // Unicode General Category "Separator,space"
private static String CURRENCY = "\\p{gc=Sc}"; // Unicode General Category "Currency"
private static String ALLOWED_CHARS="()\\[\\]&/$§=\\,!#*~"; //Characters that don't cause problems in SQL when enclosed in ''
private static Pattern STRING = Pattern.compile("\\A[" + LETTER + DECIMAL + SEPARATOR + CURRENCY + ALLOWED_CHARS+"\\.:\\-\\_/\\n\\r@\\^]*\\z");
@Override
public boolean check(String input) {
if (input.equals("--leer--")) {
return true;
}
Matcher matcher = STRING.matcher(input);
return matcher.find();
}
}

13
src/de/superx/servlet/SxPool.java

@ -3,6 +3,7 @@ package de.superx.servlet; @@ -3,6 +3,7 @@ package de.superx.servlet;
import java.io.File;
import java.io.IOException;
import java.lang.reflect.InvocationTargetException;
import java.net.URISyntaxException;
import java.security.InvalidKeyException;
import java.security.NoSuchAlgorithmException;
import java.security.SignatureException;
@ -341,7 +342,15 @@ public class SxPool extends GenericObjectPool implements NamedObjectI { @@ -341,7 +342,15 @@ public class SxPool extends GenericObjectPool implements NamedObjectI {
loginP = rs.getInt(1);
}
isErweitertesProtokollWanted = loginP == 1;
String myWEBINFFilePath=SuperXManager.getWEB_INFPfad();
//bei Kommandozerilenaufrufen ist WEB-INF nicht aus dem Servlet Manager ermittelbar:
if(myWEBINFFilePath==null || myWEBINFFilePath.equals("."))
try {
myWEBINFFilePath= de.superx.etl.EtlUtils.getWebinfDirectory();
} catch (URISyntaxException e1) {
// Default ist user.dir:
myWEBINFFilePath=System.getProperty("user.dir");
} //
rs = st.executeQuery("select tid from sx_repository where id='WEBINFDIR'");
int tid = 0;
while (rs.next()) {
@ -353,7 +362,7 @@ public class SxPool extends GenericObjectPool implements NamedObjectI { @@ -353,7 +362,7 @@ public class SxPool extends GenericObjectPool implements NamedObjectI {
}
try (PreparedStatement pst = con
.prepareStatement("update sx_repository set content=? where id='WEBINFDIR'")) {
pst.setString(1, SuperXManager.getWEB_INFPfad());
pst.setString(1, myWEBINFFilePath);
pst.execute();
}
}

15
src/de/superx/servlet/UserInitializer.java

@ -691,7 +691,22 @@ public class UserInitializer { @@ -691,7 +691,22 @@ public class UserInitializer {
+ "<input type=submit value=\"Abschicken\">" + "</form>" + "</body></html>";
}
private static boolean isGuestUser(Connection con, String kennung) throws SQLException {
boolean result = false;
try (PreparedStatement pst = con
.prepareStatement("select name from userinfo where benutzer = ?");) {
pst.setString(1, kennung);
try (ResultSet rs = pst.executeQuery()) {
if (rs.next()) {
String name = rs.getString("name");
result = name != null && name.trim().equals("Gastkennung");
}
}
}
return result;
}
/**
* @return Returns the oldsha.
*/

113
src/de/superx/sxrest/LogsProvider.java

@ -0,0 +1,113 @@ @@ -0,0 +1,113 @@
package de.superx.sxrest;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;
import javax.ws.rs.core.Context;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Request;
import java.io.File;
import javax.servlet.http.HttpServletRequest;
import de.memtext.util.DateUtils;
import de.memtext.util.FileUtils;
import de.superx.common.SxUser;
import de.superx.servlet.SuperXManager;
@Path("/logs")
public class LogsProvider {
@Context
Request request;
@GET
@Path("/{logtype}")
@Produces(MediaType.TEXT_PLAIN)
public String printLogs(@PathParam("logtype") String logtype,
@QueryParam("loglines") Integer loglines,
@Context HttpServletRequest request) {
String returntext="";
SxUser user = (SxUser) request.getSession().getAttribute("user");
String mandantenid= (String) request.getSession().getAttribute("MandantenID");
if(mandantenid==null || mandantenid.equals(""))
mandantenid="default";
if (user == null || !user.isAdmin()) {
returntext="Fehlende Rechte";
}
else
{
if(logtype.equals("activity")|| logtype.equals("fmsql")|| logtype.equals("sql") || logtype.equals("xml"))
{
returntext = getMaskLogs(mandantenid,logtype);
}
else
returntext=getTomcatLogs(mandantenid,logtype,loglines);
}
return returntext;
}
private String getMaskLogs(String mandantenid,String logtype)
{
String logString;
if(mandantenid.equalsIgnoreCase(SuperXManager.getLastMaskenSqlMandantid()))
{
switch (logtype) {
case "activity" :
logString=SuperXManager.activityLog.toString().replace("<br>", "\n");
break;
case "fmsql" :
logString=SuperXManager.getLastFMMaskenSql();
break;
case "sql" :
logString=SuperXManager.getLastMaskenSql();
break;
case "xml" :
logString=SuperXManager.getLastXml();
break;
default :
logString="Protokoll "+logtype+ " kann nicht gelesen werden";
}
}
else
logString="Bitte wiederholen Sie den Aufruf mit dem jew. Mandant";
return logString;
}
private String getTomcatLogs(String mandantenid,String logtype, Integer loglines)
{
String logFilePath="";
if(loglines==null )
loglines=100;
switch (logtype) {
case "serverlog" :
logFilePath=System.getProperty("catalina.base")+File.separator+ "logs"+File.separator+"catalina.out";
break;
case "serverlogsql" :
logFilePath=System.getProperty("catalina.base")+File.separator+ "logs"+File.separator+"superx_"+mandantenid+".log";
break;
case "serverlogxml" :
logFilePath=System.getProperty("catalina.base")+File.separator+ "logs"+File.separator+"superx_"+mandantenid+"_xml.log";
break;
default:
throw new RuntimeException("Logtype " + logtype + " not supported!");
}
String logString="Protokoll "+logFilePath+ " kann nicht gelesen werden";
File logfile = new File(logFilePath);
if(logfile.exists())
{
try {
logString=FileUtils.tail(logfile,Integer.valueOf(loglines));
}
catch (Exception e)
{
logString+=": "+ e.toString();
}
}
return logString;
}
}

63
src/de/superx/sxrest/MaskLogs.java

@ -1,63 +0,0 @@ @@ -1,63 +0,0 @@
package de.superx.sxrest;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
import javax.ws.rs.core.Context;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Request;
import javax.servlet.http.HttpServletRequest;
import de.memtext.util.DateUtils;
import de.superx.common.SxUser;
import de.superx.servlet.SuperXManager;
@Path("/masklogs")
public class MaskLogs {
@Context
Request request;
@GET
@Path("/{param}")
@Produces(MediaType.TEXT_PLAIN)
public String printLogs(@PathParam("param") String logtype,@Context HttpServletRequest request) {
String returntext="";
SxUser user = (SxUser) request.getSession().getAttribute("user");
String mandantenid= (String) request.getSession().getAttribute("MandantenID");
if(mandantenid==null || mandantenid.equals(""))
mandantenid="default";
if (user == null || !user.isAdmin()) {
returntext="Fehlende Rechte";
}
else
{
if(mandantenid.equalsIgnoreCase(SuperXManager.getLastMaskenSqlMandantid()))
{
if(logtype.equals("activity"))
{
returntext += SuperXManager.activityLog.toString().replace("<br>", "\n");
}
if(logtype.equals("fmsql"))
{
returntext += SuperXManager.getLastFMMaskenSql();
}
if(logtype.equals("sql"))
{
returntext += SuperXManager.getLastMaskenSql();
}
if(logtype.equals("xml"))
{
returntext = SuperXManager.getLastXml();
}
}
else
returntext="Bitte wiederholen Sie den Aufruf mit dem jew. Mandant";
}
return returntext;
}
}

2
superx/WEB-INF/conf/edustore/db/bin/saxon_transform.x

@ -55,7 +55,7 @@ then @@ -55,7 +55,7 @@ then
#java net.sf.saxon.Transform -o "$OUT" "$IN" "$XSL" "$param"
else
CP=".:$JDBC_CLASSPATH"
echo java -cp "..." $JAVA_OPTS net.sf.saxon.Transform -o "$OUT" "$IN" "$XSL" $param
#echo java -cp "..." $JAVA_OPTS net.sf.saxon.Transform -o "$OUT" "$IN" "$XSL" $param
java -cp "$CP" $JAVA_OPTS net.sf.saxon.Transform -xsl:$XSL -s:$IN -o:"$OUT"
fi

7
superx/WEB-INF/conf/edustore/db/bin/sx_transform.x

@ -6,7 +6,6 @@ @@ -6,7 +6,6 @@
#-------------------------------------------------------------------
# Shellvariablen setzen und eine XMl-Datei via XSL tranformieren
# Aufruf: sx_transform.x <xml-Datei> <xsl-Datei> <Ausgabedatei> <Ausgabeformat (text, xml,html,pdf,rtf)>(optional) <Ausgabedatei>(optional)
#-------------------------------------------------------------------
#Wenn in Unterscript ein Fehler auch dieses Script beenden
function exitAfterError
@ -16,7 +15,7 @@ function exitAfterError @@ -16,7 +15,7 @@ function exitAfterError
trap exitAfterError ERR
if [ "$1" = "" ]
then echo "Aufruf: sx_transform.x -IN:<xml-Datei> -XSL:<xsl-Datei> -OUT:<Ausgabedatei> -method:<Ausgabeformat (text,xml,html,pdf,rtf)>(optional) -param:<Parameter>(optional)"
then echo "Aufruf: sx_transform.x -IN:<xml-Datei> -XSL:<xsl-Datei> -OUT:<Ausgabedatei> -method:<Ausgabeformat (text,xml,html,pdf,rtf)>(optional) -params:<Parameter>(optional)"
echo " "
echo "Aktion: sx_transform.x transformiert eine XMl-Datei via XSL"
echo "Wenn pdf als Ausgabeformat angegeben ist, dann wird eine PDF-Datei erzeugt."
@ -30,7 +29,7 @@ IN="$1" @@ -30,7 +29,7 @@ IN="$1"
XSL="$2"
OUT="$3"
method="$4"
param="$5"
params="$5"
if [ "$method" = "" ]
#Default setting: XML
then method="-method:XML"
@ -44,7 +43,7 @@ if [ "$method" = "-method:pdf" ] @@ -44,7 +43,7 @@ if [ "$method" = "-method:pdf" ]
else
if [ "$method" = "-method:rtf" ]
then
java $JAVA_OPTS -cp $CP -Dlog.priority.jfor=ERROR de.superx.bin.SimpleTransform -logger:$LOGGER_PROPERTIES $IN $XSL $OUT -method:rtf $param
java $JAVA_OPTS -cp $CP -Dlog.priority.jfor=ERROR de.superx.bin.SimpleTransform -logger:$LOGGER_PROPERTIES $IN $XSL $OUT -method:rtf $params
#CP=".:$JDBC_CLASSPATH:$SUPERX_DIR/webserver/tomcat/common/endorsed/$TOMCAT_LIB/jfor-0.7.2rc1.jar:/home/superx/tmp/ttt/xerces-1.2.3.jar:/home/superx/tmp/ttt/logkit-1.0.1.jar"
#java -cp $CP ch.codeconsult.jfor.main.CmdLineConverter tmp.fo tmp.rtf
else

4
superx/WEB-INF/conf/edustore/db/conf/function.xsl

@ -5,9 +5,9 @@ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> @@ -5,9 +5,9 @@ xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:param name="dbsystem"/>
<xsl:text>--Funktion / Prozedur </xsl:text><xsl:value-of select="name" /><xsl:text>
</xsl:text>
<xsl:call-template name="log">
<!--<xsl:call-template name="log">
<xsl:with-param name="msg" select="concat('Erzeuge Funktion ',name)" />
</xsl:call-template>
</xsl:call-template>-->
<xsl:for-each select="src">
<xsl:choose>
<xsl:when test="file != '' ">

8
superx/WEB-INF/conf/edustore/db/conf/module_upgrade.xsl

@ -391,7 +391,7 @@ select ]]></xsl:text> @@ -391,7 +391,7 @@ select ]]></xsl:text>
<xsl:text>relname,relname as tabelle from pg_class JOIN pg_namespace ON pg_namespace.oid = pg_class.relnamespace WHERE pg_namespace.nspname = 'public' AND relname::varchar(200)</xsl:text>
</xsl:when>
<xsl:when test="$dbsystem='INFORMIX'">
tabid,tabname as tabelle from systables where tabname
tabname as tabelle from systables where tabname
</xsl:when>
<xsl:when test="$dbsystem='HSQLDB'">
lcase(table_name),lcase(table_name) as tabelle from system_tables where lcase(table_name)
@ -484,7 +484,7 @@ and A.attnum >0 @@ -484,7 +484,7 @@ and A.attnum >0
and C.relname::varchar(255) </xsl:text>
</xsl:when>
<xsl:when test="$dbsystem='INFORMIX'">
a.colno,(trim(b.tabname) || '.' || trim(a.colname))::varchar(255) as feld
(trim(b.tabname) || '.' || trim(a.colname))::varchar(255) as feld
from syscolumns a, systables b
where a.tabid = b.tabid and b.tabname
</xsl:when>
@ -557,7 +557,7 @@ and N.nspname||'.'||C.relname </xsl:text> @@ -557,7 +557,7 @@ and N.nspname||'.'||C.relname </xsl:text>
</xsl:text>
<xsl:text><![CDATA[<sqlvars>]]>
</xsl:text>
<xsl:text><![CDATA[<sqlvar name="views">
<xsl:text><![CDATA[<sqlvar name="views" type="list">
select ]]></xsl:text>
<xsl:choose>
@ -565,7 +565,7 @@ select ]]></xsl:text> @@ -565,7 +565,7 @@ select ]]></xsl:text>
<xsl:text>relname,relname as tabelle from pg_class where relname::varchar(200)</xsl:text>
</xsl:when>
<xsl:when test="$dbsystem='INFORMIX'">
tabid,tabname as tabelle from systables where tabname
tabname as tabelle from systables where tabname
</xsl:when>
<xsl:when test="$dbsystem='HSQLDB'">
lcase(TABLE_NAME),lcase(TABLE_NAME) as tabelle from SYSTEM_VIEWS where lcase(TABLE_NAME)

2
superx/WEB-INF/conf/edustore/db/install/conf/builddatum.txt

@ -1 +1 @@ @@ -1 +1 @@
21.02.2022
16.08.2023

2
superx/WEB-INF/conf/edustore/db/install/conf/his1/dbconv/sch.eduetl/sichten.tab

@ -9,7 +9,7 @@ name_intern NCHAR(200) , @@ -9,7 +9,7 @@ name_intern NCHAR(200) ,
name NCHAR(200) ,
beschreibung NCHAR(255) ,
sortnr INTEGER default 0 not null,
quelle NCHAR(255) ,
quelle TEXT ,
alt_hier_id NCHAR(150) ,
treecfgtable NCHAR(255) ,
treecfgid NCHAR(150) ,

2
superx/WEB-INF/conf/edustore/db/install/conf/his1/dbconv/view.eduetl/dim_kreis.view

@ -18,6 +18,6 @@ bland_astat) as @@ -18,6 +18,6 @@ bland_astat) as
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz');
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
;

135
superx/WEB-INF/conf/edustore/db/install/conf/his1/edustore_doc/kern_load.txt

@ -1,135 +0,0 @@ @@ -1,135 +0,0 @@
=Schnittstellen kern=
{| class="prettytable" border="1"
|-
|SuperX-Version
|2
|-
|Modulversion
|4.9
|-
|Sachgebiet
|Administration id 0
|-
|Systeminfo
|Administration id 9
|-
|Thema
|Administration
|-
|Themenbaum-Ast
|Abfragen
|}
==Ladeschritt 1: tmp_hochschulinfo==
Die Tabelle tmp_hochschulinfo wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 2: tmp_userinfo==
Die Tabelle tmp_userinfo wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 3: tmp_user_group_bez==
Die Tabelle tmp_user_group_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 4: tmp_user_institution==
Die Tabelle tmp_user_institution wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 5: tmp_user_masken_bez==
Die Tabelle tmp_user_masken_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 6: tmp_user_pw==
Die Tabelle tmp_user_pw wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 7: tmp_user_sachgeb_bez==
Die Tabelle tmp_user_sachgeb_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 8: tmp_user_sichtarten==
Die Tabelle tmp_user_sichtarten wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 9: tmp_user_sichten==
Die Tabelle tmp_user_sichten wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 10: tmp_group_field_pref==
Die Tabelle tmp_group_field_pref wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 11: tmp_group_masken_bez==
Die Tabelle tmp_group_masken_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 12: tmp_group_sachgeb_bez==
Die Tabelle tmp_group_sachgeb_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 13: tmp_group_sichtarten==
Die Tabelle tmp_group_sichtarten wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 14: tmp_group_sichten==
Die Tabelle tmp_group_sichten wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 15: tmp_groupinfo==
Die Tabelle tmp_groupinfo wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 16: tmp_fin_user_kam==
Die Tabelle tmp_fin_user_kam wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 17: tmp_konstanten==
Die Tabelle tmp_konstanten wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 18: tmp_unload_params==
Die Tabelle tmp_unload_params wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 19: tmp_sx_repository==
Die Tabelle tmp_sx_repository wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 20: tmp_themenbaum==
Die Tabelle tmp_themenbaum wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 21: tmp_maskeninfo==
Die Tabelle tmp_maskeninfo wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 22: tmp_felderinfo==
Die Tabelle tmp_felderinfo wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 23: tmp_masken_felder_bez==
Die Tabelle tmp_masken_felder_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 24: tmp_maske_system_bez==
Die Tabelle tmp_maske_system_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 25: tmp_sachgeb_maske_bez==
Die Tabelle tmp_sachgeb_maske_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 26: tmp_sx_stylesheets==
Die Tabelle tmp_sx_stylesheets wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 27: tmp_sx_mask_style==
Die Tabelle tmp_sx_mask_style wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 28: tmp_stylesheet_field==
Die Tabelle tmp_stylesheet_field wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 29: tmp_macro_masken_bez==
Die Tabelle tmp_macro_masken_bez wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 30: tmp_macro_feld_wert==
Die Tabelle tmp_macro_feld_wert wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 31: tmp_sx_captions==
Die Tabelle tmp_sx_captions wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 32: tmp_sichten==
Die Tabelle tmp_sichten wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 33: tmp_man_catalogue==
Die Tabelle tmp_man_catalogue wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 34: tmp_man_catalogue_rpt==
Die Tabelle tmp_man_catalogue_rpt wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 35: tmp_man_zahl_wert==
Die Tabelle tmp_man_zahl_wert wird nur temporär werdend des Ladens erzeugt.
==Ladeschritt 36: tmp_kenn_zahl_wert==
Die Tabelle tmp_kenn_zahl_wert wird nur temporär werdend des Ladens erzeugt.

29618
superx/WEB-INF/conf/edustore/db/install/conf/kern.html

File diff suppressed because one or more lines are too long

2
superx/WEB-INF/conf/edustore/db/install/conf/kern.rtf

File diff suppressed because one or more lines are too long

9
superx/WEB-INF/conf/edustore/db/install/conf/kern.xml

@ -300,7 +300,7 @@ @@ -300,7 +300,7 @@
notnull="true" description="Sortiernummer">
<comment>kann für Sortierungen benutzt werden</comment>
</column>
<column name="quelle" type="CHAR" size="255" default=""
<column name="quelle" type="TEXT" size="255" default=""
notnull="false" description="Quelle">
<comment>Angabe einer Tabelle mit
key,parent,name,gueltig_seit,gueltig_bis oder Prozedur, die mit
@ -1912,7 +1912,8 @@ @@ -1912,7 +1912,8 @@
</privileges>
</table>
<!--since4.6 -->
<table name="dbconnections">
<table name="dbconnections" thema="Administration"
typ="Schlüsseltabelle">
<columns><column name="id" type ="VARCHAR" size ="255" default ="" notnull ="true" />
<column name="name" type ="VARCHAR" size ="255" default ="" notnull ="true" />
<column name="driver" type ="VARCHAR" size ="255" default ="" notnull ="false" />
@ -8533,7 +8534,7 @@ where dimension_bp_id=(select D.tid from dimension_bp D where D.apnr='bluep_absc @@ -8533,7 +8534,7 @@ where dimension_bp_id=(select D.tid from dimension_bp D where D.apnr='bluep_absc
<column name="bland_astat" type="VARCHAR" size="" default=""
notnull="false" description="Amtl. Schlüssel Bundesland" />
</columns>
<sql dbsystem="POSTGRES"><![CDATA[
<sql dbsystem=""><![CDATA[
SELECT
apnr,
TRIM(level3_char) AS astat,
@ -8545,7 +8546,7 @@ where dimension_bp_id=(select D.tid from dimension_bp D where D.apnr='bluep_absc @@ -8545,7 +8546,7 @@ where dimension_bp_id=(select D.tid from dimension_bp D where D.apnr='bluep_absc
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz');
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
]]></sql>
</view>
</views>

2
superx/WEB-INF/conf/edustore/db/install/conf/sx_fields_fuellen.sql

@ -12839,7 +12839,7 @@ values('sichten', @@ -12839,7 +12839,7 @@ values('sichten',
'quelle',
'Quelle',
'Angabe einer Tabelle mit key,parent,name,gueltig_seit,gueltig_bis oder Prozedur, die mit sp_ anfängt',
'CHAR',
'TEXT',
'255',
0,
1,

4
superx/WEB-INF/conf/edustore/db/install/conf/sx_tables_fuellen.sql

@ -97,10 +97,10 @@ values('db_version','','Ein Verzeichnis der Modul-Versionen nach dem Schema der @@ -97,10 +97,10 @@ values('db_version','','Ein Verzeichnis der Modul-Versionen nach dem Schema der
insert into tmp_tables (name,caption,description,table_type,systeminfo_id,systeminfo_orig,thema,sachgebiete_id)
values('dbconnections','','',
'',
'Schlüsseltabelle',
9,
9,
'',
'Administration',
0);
insert into tmp_tables (name,caption,description,table_type,systeminfo_id,systeminfo_orig,thema,sachgebiete_id)

360
superx/WEB-INF/conf/edustore/db/install/kern_install_ids.sql

@ -209,7 +209,7 @@ name_intern NCHAR(200) , @@ -209,7 +209,7 @@ name_intern NCHAR(200) ,
name NCHAR(200) ,
beschreibung NCHAR(255) ,
sortnr INTEGER default 0 not null,
quelle NCHAR(255) ,
quelle TEXT ,
alt_hier_id NCHAR(150) ,
treecfgtable NCHAR(255) ,
treecfgid NCHAR(150) ,
@ -3715,71 +3715,34 @@ kfz, @@ -3715,71 +3715,34 @@ kfz,
bland_druck,
bland_kurz,
bland_astat) as
SELECT
apnr,
TRIM(level3_char) AS astat,
druck,
TRIM(level1_char) AS kfz,
TRIM(level2_str) AS bland_druck,
TRIM(level2_char) AS bland_kurz,
TRIM(level3_str) AS bland_astat
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
;
--Funktion / Prozedur sp_user_themen
select now(),'Erzeuge Funktion sp_user_themen'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_themen_ids.sql
--Funktion / Prozedur sp_user_orga
select now(),'Erzeuge Funktion sp_user_orga'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_ids.sql
--Funktion / Prozedur sp_user_orga_child
select now(),'Erzeuge Funktion sp_user_orga_child'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_child_ids.sql
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
CREATE FUNCTION week(dt date)
RETURNS smallint
WITH(NOT VARIANT)
@ -3795,89 +3758,19 @@ RETURN 1 + (nbdays + WEEKDAY(day1)) / 7; @@ -3795,89 +3758,19 @@ RETURN 1 + (nbdays + WEEKDAY(day1)) / 7;
END FUNCTION;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
--Funktion / Prozedur current
select now(),'Erzeuge Funktion current'
from xdummy;
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
--Funktion / Prozedur suchen_ersetzen
select now(),'Erzeuge Funktion suchen_ersetzen'
from xdummy;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
--Funktion / Prozedur time_stamp
select now(),'Erzeuge Funktion time_stamp'
from xdummy;
--Funktion / Prozedur date_val
select now(),'Erzeuge Funktion date_val'
from xdummy;
create procedure date_val(datstr char(100))
returning date;
define p_date date;
@ -3886,121 +3779,36 @@ from xdummy; @@ -3886,121 +3779,36 @@ from xdummy;
end procedure;
--Funktion / Prozedur date
select now(),'Erzeuge Funktion date'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur now
select now(),'Erzeuge Funktion now'
from xdummy;
create procedure now()
returning datetime year to second;
return CURRENT;
end procedure;
--Funktion / Prozedur timestamp_to_date
select now(),'Erzeuge Funktion timestamp_to_date'
from xdummy;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
create procedure string_not_null(p_str char(255))
returning char(255);
return nvl(p_str,'');
end procedure;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
--Funktion / Prozedur timestamp_str
select now(),'Erzeuge Funktion timestamp_str'
from xdummy;
--Funktion / Prozedur date_str
select now(),'Erzeuge Funktion date_str'
from xdummy;
CREATE procedure date_str(datum date) RETURNING varchar(255);
return '' || datum;
end procedure;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
create procedure val(p_str char(255))
returning integer;
define p_val integer ;
@ -4008,198 +3816,58 @@ let p_val=(select p_str::integer from xdummy); @@ -4008,198 +3816,58 @@ let p_val=(select p_str::integer from xdummy);
return p_val::integer;
end procedure;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
create procedure decval(p_str varchar(255))
returning decimal(16,2);
return p_str::decimal(16,2);
end procedure;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
create procedure decval(p_str char(255))
returning decimal(16,2);
return p_str::decimal(16,2);
end procedure;
--Funktion / Prozedur sp_filter_orga
select now(),'Erzeuge Funktion sp_filter_orga'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_filter_orga_ids.sql
--Funktion / Prozedur sp_update_sequence
select now(),'Erzeuge Funktion sp_update_sequence'
from xdummy;
--Funktion / Prozedur sp_bool_to_smallint
select now(),'Erzeuge Funktion sp_bool_to_smallint'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur sp_get_subquery_str
select now(),'Erzeuge Funktion sp_get_subquery_str'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_subquery_str_ids.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_ids.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_short_ids.sql
--Funktion / Prozedur sp_get_benutzer
select now(),'Erzeuge Funktion sp_get_benutzer'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_benutzer_ids.sql
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_trunc_string_ids.sql
--Funktion / Prozedur sp_table_exists
select now(),'Erzeuge Funktion sp_table_exists'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_table_exists_ids.sql
--Funktion / Prozedur sp_view_exists
select now(),'Erzeuge Funktion sp_view_exists'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_view_exists_ids.sql
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_today_ids.sql
--Funktion / Prozedur to_number
select now(),'Erzeuge Funktion to_number'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_to_number_ids.sql
--Funktion / Prozedur sp_get_dbform_right
select now(),'Erzeuge Funktion sp_get_dbform_right'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_dbform_right_ids.sql
--Funktion / Prozedur add_sem
select now(),'Erzeuge Funktion add_sem'
from xdummy;
--Funktion / Prozedur sp_set_organigramm_eb
select now(),'Erzeuge Funktion sp_set_organigramm_eb'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_eb_ids.sql
--Funktion / Prozedur sp_set_organigramm_lehr
select now(),'Erzeuge Funktion sp_set_organigramm_lehr'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_lehr_ids.sql
--Funktion / Prozedur trim_all_whitespace
select now(),'Erzeuge Funktion trim_all_whitespace'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/trim_all_whitespace_ids.sql
--Install-Schritt: Füllen der Kernmodul-Tabellen

349
superx/WEB-INF/conf/edustore/db/install/kern_install_pg.sql

@ -246,7 +246,7 @@ name_intern CHAR(200) , @@ -246,7 +246,7 @@ name_intern CHAR(200) ,
name CHAR(200) ,
beschreibung CHAR(255) ,
sortnr INTEGER default 0 not null,
quelle CHAR(255) ,
quelle TEXT ,
alt_hier_id CHAR(150) ,
treecfgtable CHAR(255) ,
treecfgid CHAR(150) ,
@ -4915,163 +4915,63 @@ bland_astat) as @@ -4915,163 +4915,63 @@ bland_astat) as
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz');
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
;
--Funktion / Prozedur sp_user_themen
select now(),'Erzeuge Funktion sp_user_themen'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_themen_pg.sql
--Funktion / Prozedur sp_user_orga
select now(),'Erzeuge Funktion sp_user_orga'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_pg.sql
--Funktion / Prozedur sp_user_orga_child
select now(),'Erzeuge Funktion sp_user_orga_child'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_child_pg.sql
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
Create or replace Function day(date) RETURNS smallint STABLE
AS 'select extract(day from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
Create or replace Function day(timestamptz) RETURNS smallint STABLE
AS 'select extract(day from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
Create or replace Function month(date) RETURNS smallint STABLE
AS 'select extract(month from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
Create or replace Function month(timestamptz) RETURNS smallint STABLE
AS 'select extract(month from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
Create or replace Function year(date) RETURNS smallint STABLE
AS 'select extract(year from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
Create or replace Function year(timestamptz) RETURNS smallint STABLE
AS 'select extract(year from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
Create or replace Function week(date) RETURNS smallint STABLE
AS 'select extract(week from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
Create or replace Function week(timestamptz) RETURNS smallint STABLE
AS 'select extract(week from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
Create or replace Function second(time) RETURNS smallint STABLE
AS 'select extract(second from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
Create or replace Function second(timestamptz) RETURNS smallint STABLE
AS 'select extract(second from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
Create or replace Function minute(time) RETURNS smallint STABLE
AS 'select extract(minute from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
Create or replace Function minute(timestamptz) RETURNS smallint STABLE
AS 'select extract(minute from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
Create or replace Function hour(time) RETURNS smallint STABLE
AS 'select extract(hour from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
Create or replace Function hour(timestamptz) RETURNS smallint STABLE
AS 'select extract(hour from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur current
select now(),'Erzeuge Funktion current'
from xdummy;
Create or replace Function current() RETURNS timestamptz STABLE
AS 'select now() ' LANGUAGE sql;
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
Create or replace Function today() RETURNS date STABLE
AS 'select current_date ' LANGUAGE sql;
--Funktion / Prozedur suchen_ersetzen
select now(),'Erzeuge Funktion suchen_ersetzen'
from xdummy;
Create or replace Function suchen_ersetzen(text,text,text) returns text
as '
Declare zs text;
@ -5093,393 +4993,148 @@ k := position(alt in s1); @@ -5093,393 +4993,148 @@ k := position(alt in s1);
END;
' LANGUAGE plpgsql;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
Create or replace Function weekday(date) RETURNS text STABLE
AS 'select to_char($1,''Dy'')::text ' LANGUAGE sql;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
Create or replace Function weekday(timestamptz) RETURNS text STABLE
AS 'select weekday(date($1))::text ' LANGUAGE sql;
--Funktion / Prozedur time_stamp
select now(),'Erzeuge Funktion time_stamp'
from xdummy;
Create or replace Function time_stamp(text) RETURNS timestamptz STABLE
AS 'select to_timestamp($1,''DD.MM.YYYY HH24.MI.SS'')' LANGUAGE sql;
--Funktion / Prozedur date_val
select now(),'Erzeuge Funktion date_val'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_date_val_pg.sql
--Funktion / Prozedur date
select now(),'Erzeuge Funktion date'
from xdummy;
Create or replace Function date(text) RETURNS date STABLE
AS 'select to_date($1,''DD.MM.YYYY'')' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
Create or replace Function nvl(float,integer) RETURNS float STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
Create or replace Function nvl(decimal,integer) RETURNS decimal STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(numeric,numeric) RETURNS numeric STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(smallint,smallint) RETURNS smallint STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(integer,integer) RETURNS integer STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(varchar,char) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where
$1 is null;' LANGUAGE sql;
--Funktion / Prozedur now
select now(),'Erzeuge Funktion now'
from xdummy;
--Funktion / Prozedur timestamp_to_date
select now(),'Erzeuge Funktion timestamp_to_date'
from xdummy;
CREATE or replace FUNCTION timestamp_to_date(timestamptz) RETURNS date STABLE
AS 'select to_date(day($1)||''.'' || month($1) || ''.'' || year($1),''DD.MM.YYYY'')' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(char) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(text) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(varchar) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(integer) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur timestamp_str
select now(),'Erzeuge Funktion timestamp_str'
from xdummy;
CREATE or replace FUNCTION timestamp_str(timestamptz) RETURNS text STABLE
AS 'select to_char($1,''DD.MM.YYYY HH24:MI:SS '');' LANGUAGE sql;
--Funktion / Prozedur date_str
select now(),'Erzeuge Funktion date_str'
from xdummy;
CREATE or replace FUNCTION date_str(date) RETURNS text STABLE
AS 'select to_char($1,''DD.MM.YYYY'') ;' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(text) RETURNS integer STABLE
AS 'select to_number($1,repeat(''9'',length($1) ))::integer where trim($1) !='''' and $1 ~ ''0*[0-9][0-9]*'' ' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(char(255)) RETURNS integer STABLE
AS 'select to_number($1,repeat(''9'',length($1) ))::integer where trim($1) !='''' and $1 ~ ''0*[0-9][0-9]*'' ' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(varchar(255)) RETURNS integer STABLE
AS 'select to_number($1,repeat(''9'',length($1) ))::integer where trim($1) !='''' and $1 ~ ''0*[0-9][0-9]*''' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(integer) RETURNS integer STABLE
AS 'select $1::integer ' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(smallint) RETURNS integer STABLE
AS 'select $1::integer ' LANGUAGE sql;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
CREATE or replace FUNCTION decval(varchar(255)) RETURNS numeric(16,2) STABLE
AS 'select to_number($1,''S9999999999999D99'' ) where trim($1) !='''' ' LANGUAGE sql;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
CREATE or replace FUNCTION decval(text) RETURNS numeric(16,2) STABLE
AS 'select to_number($1,''S9999999999999D99'' ) where trim($1) !='''' ' LANGUAGE sql;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
CREATE or replace FUNCTION decval(char(255)) RETURNS numeric(16,2) STABLE
AS 'select to_number($1,''S9999999999999D99'' ) where trim($1) !='''' ' LANGUAGE sql;
--Funktion / Prozedur sp_filter_orga
select now(),'Erzeuge Funktion sp_filter_orga'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_filter_orga_pg.sql
--Funktion / Prozedur sp_update_sequence
select now(),'Erzeuge Funktion sp_update_sequence'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_update_sequence_pg.sql
--Funktion / Prozedur sp_bool_to_smallint
select now(),'Erzeuge Funktion sp_bool_to_smallint'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_bool_to_smallint_pg.sql
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(varchar,varchar) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(char,char) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(text,text) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(char,varchar) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where
$1 is null;' LANGUAGE 'sql';
--Funktion / Prozedur sp_get_subquery_str
select now(),'Erzeuge Funktion sp_get_subquery_str'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_subquery_str_pg.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_pg.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_short_pg.sql
--Funktion / Prozedur sp_get_benutzer
select now(),'Erzeuge Funktion sp_get_benutzer'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_benutzer_pg.sql
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_trunc_string_pg.sql
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
--Funktion / Prozedur sp_table_exists
select now(),'Erzeuge Funktion sp_table_exists'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_table_exists_pg.sql
--Funktion / Prozedur sp_view_exists
select now(),'Erzeuge Funktion sp_view_exists'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_view_exists_pg.sql
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
--Funktion / Prozedur to_number
select now(),'Erzeuge Funktion to_number'
from xdummy;
--Funktion / Prozedur sp_get_dbform_right
select now(),'Erzeuge Funktion sp_get_dbform_right'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_dbform_right_pg.sql
--Funktion / Prozedur add_sem
select now(),'Erzeuge Funktion add_sem'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/add_sem_pg.sql
--Funktion / Prozedur sp_set_organigramm_eb
select now(),'Erzeuge Funktion sp_set_organigramm_eb'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_eb_pg.sql
--Funktion / Prozedur sp_set_organigramm_lehr
select now(),'Erzeuge Funktion sp_set_organigramm_lehr'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_lehr_pg.sql
--Funktion / Prozedur trim_all_whitespace
select now(),'Erzeuge Funktion trim_all_whitespace'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/trim_all_whitespace_pg.sql
--Install-Schritt: Füllen der Kernmodul-Tabellen

6
superx/WEB-INF/conf/edustore/db/install/masken/71770_maskeninfo.unl

@ -1,6 +1,6 @@ @@ -1,6 +1,6 @@
71770^Gastzugang einrichten^--Freemarker Template\
<sqlvars>\
<sqlvar name="already_exists">select count(*) from userinfo where benutzer='<<neue Gastkennung>>'</sqlvar>\
<sqlvar name="already_exists">select count(*) from userinfo where benutzer=<<neue Gastkennung>> </sqlvar>\
</sqlvars>\
\
create temp table tmp_ergebnis (variable varchar(255),wert varchar(255),nextedit varchar(255));\
@ -23,9 +23,9 @@ CREATE temp TABLE tmp_user (\ @@ -23,9 +23,9 @@ CREATE temp TABLE tmp_user (\
\
\
insert into tmp_user (tid,benutzer, name,kennwort, max_versuch,akt_versuch,administration,archiv_recht, passwd_sha)\
select distinct max(tid)+1,'<<neue Gastkennung>>','Gastkennung','obsolet', 10, 0,0,0,<<Gastpasswort>> from userinfo \
select distinct max(tid)+1,<<neue Gastkennung>>,'Gastkennung','obsolet', 10, 0,0,0,<<Gastpasswort>> from userinfo \
where (select administration from userinfo where tid=<<UserID>>)= 1 \
and (select count(*) from userinfo where benutzer='<<neue Gastkennung>>')=0\
and (select count(*) from userinfo where benutzer=<<neue Gastkennung>>)=0\
;\
\
update tmp_user set inst=<<Inst.-Rechte>>;\

2
superx/WEB-INF/conf/edustore/db/install/prozeduren/proc_sp_user_orga_child_ids.sql

@ -213,7 +213,7 @@ create temp table tmp_institut_u_1( @@ -213,7 +213,7 @@ create temp table tmp_institut_u_1(
O.lehre,O.gueltig_seit,O.gueltig_bis
from organigramm O, user_institution U
where
O.gueltig_seit <= p_datum and O.gueltig_bis >= p_datum and
O.gueltig_seit <= p_datum and O.gueltig_bis >= p_datum
and (U.gueltig_seit is null or U.gueltig_seit <= today())
and (U.gueltig_bis is null or U.gueltig_bis >= today()) and
U.userid = p_userid and

16
superx/WEB-INF/conf/edustore/db/install/prozeduren/proc_sp_user_themen_ids.sql

@ -60,8 +60,8 @@ select T.tid,M.name, T.maskeninfo_id, T.parent, M.erlaeuterung ,T.sort,T.css_cla @@ -60,8 +60,8 @@ select T.tid,M.name, T.maskeninfo_id, T.parent, M.erlaeuterung ,T.sort,T.css_cla
and U.userinfo_id =
p_userid
and T.gueltig_seit<=p_datum and T.gueltig_bis>=p_datum
and (M.macro = 2 or M.macro is null
or M.macro = p_makros);
and (M.frontend = 2 or M.frontend is null
or M.frontend = p_makros);
--alle Abfragen für die die Gruppe berechtigt (Einzelrechte)
insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_class)
@ -72,8 +72,8 @@ insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_c @@ -72,8 +72,8 @@ insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_c
and U.userinfo_id =
p_userid
and T.gueltig_seit<=p_datum and T.gueltig_bis>=p_datum
and (M.macro = 2 or M.macro is null
or M.macro = p_makros);
and (M.frontend = 2 or M.frontend is null
or M.frontend = p_makros);
--alle Abfragen aus Sachgebieten für die der Nutzer Rechte hat
insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_class)
select T.tid,M.name, T.maskeninfo_id, T.parent, M.erlaeuterung ,T.sort,T.css_class
@ -84,8 +84,8 @@ insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_c @@ -84,8 +84,8 @@ insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_c
(select sachgebiete_id from user_sachgeb_bez U where U.userinfo_id=
p_userid
)))
and (M.macro = 2 or M.macro is null
or M.macro = p_makros);
and (M.frontend = 2 or M.frontend is null
or M.frontend = p_makros);
--alle Abfragen für die Einzelrechte in user_masken_bez angegeben
insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_class)
select T.tid,M.name, T.maskeninfo_id, T.parent, M.erlaeuterung ,T.sort,T.css_class
@ -95,8 +95,8 @@ insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_c @@ -95,8 +95,8 @@ insert into tmp_themenbaum(tid,name,maskeninfo_id,parent,erlaeuterung,sort,css_c
B.userinfo_id = p_userid
and (M.tid = B.maskeninfo_id
or B.maskeninfo_id = 0)
and (M.macro = 2 or M.macro is null
or M.macro = p_makros)
and (M.frontend = 2 or M.frontend is null
or M.frontend = p_makros)
;
--Nun sind nur die Masken drin, zu denen der User Rechte hat.

2
superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/kern_feste_konstanten_fuellen.sql

@ -202,7 +202,7 @@ update konstanten set (defaultvalue, @@ -202,7 +202,7 @@ update konstanten set (defaultvalue,
gruppe,
sachgebiete_id
from tmp_konstanten T
where T.beschreibung=konstanten.beschreibung;
where T.beschreibung=konstanten.beschreibung));
</#if>

87660
superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/release_unloads/dim_datum.unl

File diff suppressed because it is too large Load Diff

4
superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/release_unloads/sx_captions.unl

@ -96,7 +96,7 @@ @@ -96,7 +96,7 @@
274^doku_71220_mask_url^^^^de^Bedienung_der_Grunddaten_und_Basisberichte.xhtml^Doku-Link für die Maske Gruppe kopieren^^19^^^
275^doku_71220_table_url^^^^de^Bedienung_der_Grunddaten_und_Basisberichte.xhtml^Doku-Link für die Tabelle Gruppe kopieren^^19^^^
276^WIKI_WELCOME^^^^de^Willkommen zu SuperX^=Willkommen zu SuperX=\
[[Image:Superx-big.gif]]\
[[Image:superx_logo.png]]\
Geben Sie links Ihren Benutzernamen und Ihr Kennwort ein. Danach erscheint das Menü mit den Abfragen.\
Ein Benutzerhandbuch finden Sie [http://benutzerhandbuch.superx-projekt.de hier].\
\
@ -106,6 +106,8 @@ Die WWW-Adresse von SuperX lautet [http://www.superx-projekt.de www.superx-proje @@ -106,6 +106,8 @@ Die WWW-Adresse von SuperX lautet [http://www.superx-projekt.de www.superx-proje
|- \
||Community|| http://community.superx-projekt.de\
|-\
||Module|| http://module.superx-projekt.de\
|-\
||Download|| http://download.superx-projekt.de\
|-\
||Weitere Infos und Support || info@superx-projekt.de\

2
superx/WEB-INF/conf/edustore/db/install/schluesseltabellen/release_unloads/sx_repository.unl

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
1^WELCOME_XML^servlet/SuperXmlAnmeldung^Standardberichte^icon-chart-bar^^WELCOME_LINK^^^0^1^0^0^^1^01.01.1900^31.12.3000^
2^WELCOME_SAIKU^saiku/index.html^Datenanalyse^icon-chart-pie^^WELCOME_LINK^^^0^2^0^0^^1^01.01.1900^31.12.3000^
2^WELCOME_SAIKU^saiku/index.html^Datenanalyse^icon-chart-pie^^WELCOME_LINK^^^0^2^0^0^^0^01.01.1900^31.12.3000^
3^WELCOME_MAN^xml/management/index.jsp^Management^icon-sellsy^^WELCOME_LINK^^^0^3^0^0^^0^01.01.1900^31.12.3000^
4^WELCOME_JOOLAP^joolap/index.htm^Joolap^icon-magic^^WELCOME_LINK^^^0^4^0^0^^0^01.01.1900^31.12.3000^
5^WELCOME_APPLET^applet/index.jsp^Applet^icon-list-alt^^WELCOME_LINK^^^0^5^0^0^^0^01.01.1900^31.12.3000^

5
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_pre_upgrade_ids.sql

@ -113,3 +113,8 @@ alter table maskeninfo add (frontend smallint before breite); @@ -113,3 +113,8 @@ alter table maskeninfo add (frontend smallint before breite);
alter table maskeninfo drop column ist_angular;
</#if>
-- Kern 5.0 neuer Welcome Link:
delete from sx_repository
where id='WELCOME_XML';

4
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_fields_ids.sql

@ -5,7 +5,7 @@ @@ -5,7 +5,7 @@
<sqlvar name="fields" type="list">
select
a.colno,(trim(b.tabname) || '.' || trim(a.colname))::varchar(255) as feld
(trim(b.tabname) || '.' || trim(a.colname))::varchar(255) as feld
from syscolumns a, systables b
where a.tabid = b.tabid and b.tabname
in ('sichtart_rechttabelle',
@ -587,7 +587,7 @@ alter table sichten add ( sortnr INTEGER default 0 not null); @@ -587,7 +587,7 @@ alter table sichten add ( sortnr INTEGER default 0 not null);
select now(),'field sichten.quelle will be added'
from xdummy;
alter table sichten add ( quelle NCHAR(255) );
alter table sichten add ( quelle TEXT );
</#if>

2
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_fields_pg.sql

@ -716,7 +716,7 @@ alter table sichten add column sortnr INTEGER default 0 not null; @@ -716,7 +716,7 @@ alter table sichten add column sortnr INTEGER default 0 not null;
select now(),'field sichten.quelle will be added'
from xdummy;
alter table sichten add column quelle CHAR(255) ;
alter table sichten add column quelle TEXT ;
</#if>

345
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_functions_ids.sql

@ -1,69 +1,19 @@ @@ -1,69 +1,19 @@
--SQL Script automatisch generiert von SuperX module_upgrade.xsl
--Funktion / Prozedur sp_user_themen
select now(),'Erzeuge Funktion sp_user_themen'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_themen_ids.sql
--Funktion / Prozedur sp_user_orga
select now(),'Erzeuge Funktion sp_user_orga'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_ids.sql
--Funktion / Prozedur sp_user_orga_child
select now(),'Erzeuge Funktion sp_user_orga_child'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_child_ids.sql
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
CREATE FUNCTION week(dt date)
RETURNS smallint
WITH(NOT VARIANT)
@ -79,89 +29,19 @@ RETURN 1 + (nbdays + WEEKDAY(day1)) / 7; @@ -79,89 +29,19 @@ RETURN 1 + (nbdays + WEEKDAY(day1)) / 7;
END FUNCTION;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
--Funktion / Prozedur current
select now(),'Erzeuge Funktion current'
from xdummy;
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
--Funktion / Prozedur suchen_ersetzen
select now(),'Erzeuge Funktion suchen_ersetzen'
from xdummy;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
--Funktion / Prozedur time_stamp
select now(),'Erzeuge Funktion time_stamp'
from xdummy;
--Funktion / Prozedur date_val
select now(),'Erzeuge Funktion date_val'
from xdummy;
create procedure date_val(datstr char(100))
returning date;
define p_date date;
@ -170,121 +50,36 @@ from xdummy; @@ -170,121 +50,36 @@ from xdummy;
end procedure;
--Funktion / Prozedur date
select now(),'Erzeuge Funktion date'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur now
select now(),'Erzeuge Funktion now'
from xdummy;
create procedure now()
returning datetime year to second;
return CURRENT;
end procedure;
--Funktion / Prozedur timestamp_to_date
select now(),'Erzeuge Funktion timestamp_to_date'
from xdummy;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
create procedure string_not_null(p_str char(255))
returning char(255);
return nvl(p_str,'');
end procedure;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
--Funktion / Prozedur timestamp_str
select now(),'Erzeuge Funktion timestamp_str'
from xdummy;
--Funktion / Prozedur date_str
select now(),'Erzeuge Funktion date_str'
from xdummy;
CREATE procedure date_str(datum date) RETURNING varchar(255);
return '' || datum;
end procedure;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
create procedure val(p_str char(255))
returning integer;
define p_val integer ;
@ -292,197 +87,57 @@ let p_val=(select p_str::integer from xdummy); @@ -292,197 +87,57 @@ let p_val=(select p_str::integer from xdummy);
return p_val::integer;
end procedure;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
create procedure decval(p_str varchar(255))
returning decimal(16,2);
return p_str::decimal(16,2);
end procedure;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
create procedure decval(p_str char(255))
returning decimal(16,2);
return p_str::decimal(16,2);
end procedure;
--Funktion / Prozedur sp_filter_orga
select now(),'Erzeuge Funktion sp_filter_orga'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_filter_orga_ids.sql
--Funktion / Prozedur sp_update_sequence
select now(),'Erzeuge Funktion sp_update_sequence'
from xdummy;
--Funktion / Prozedur sp_bool_to_smallint
select now(),'Erzeuge Funktion sp_bool_to_smallint'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
--Funktion / Prozedur sp_get_subquery_str
select now(),'Erzeuge Funktion sp_get_subquery_str'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_subquery_str_ids.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_ids.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_short_ids.sql
--Funktion / Prozedur sp_get_benutzer
select now(),'Erzeuge Funktion sp_get_benutzer'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_benutzer_ids.sql
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_trunc_string_ids.sql
--Funktion / Prozedur sp_table_exists
select now(),'Erzeuge Funktion sp_table_exists'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_table_exists_ids.sql
--Funktion / Prozedur sp_view_exists
select now(),'Erzeuge Funktion sp_view_exists'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_view_exists_ids.sql
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_today_ids.sql
--Funktion / Prozedur to_number
select now(),'Erzeuge Funktion to_number'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_to_number_ids.sql
--Funktion / Prozedur sp_get_dbform_right
select now(),'Erzeuge Funktion sp_get_dbform_right'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_dbform_right_ids.sql
--Funktion / Prozedur add_sem
select now(),'Erzeuge Funktion add_sem'
from xdummy;
--Funktion / Prozedur sp_set_organigramm_eb
select now(),'Erzeuge Funktion sp_set_organigramm_eb'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_eb_ids.sql
--Funktion / Prozedur sp_set_organigramm_lehr
select now(),'Erzeuge Funktion sp_set_organigramm_lehr'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_lehr_ids.sql
--Funktion / Prozedur trim_all_whitespace
select now(),'Erzeuge Funktion trim_all_whitespace'
from xdummy;
! DOSQL $SUPERX_DIR/db/install/prozeduren/trim_all_whitespace_ids.sql

345
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_functions_pg.sql

@ -1,160 +1,60 @@ @@ -1,160 +1,60 @@
--SQL Script automatisch generiert von SuperX module_upgrade.xsl
--Funktion / Prozedur sp_user_themen
select now(),'Erzeuge Funktion sp_user_themen'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_themen_pg.sql
--Funktion / Prozedur sp_user_orga
select now(),'Erzeuge Funktion sp_user_orga'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_pg.sql
--Funktion / Prozedur sp_user_orga_child
select now(),'Erzeuge Funktion sp_user_orga_child'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_user_orga_child_pg.sql
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
Create or replace Function day(date) RETURNS smallint STABLE
AS 'select extract(day from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur day
select now(),'Erzeuge Funktion day'
from xdummy;
Create or replace Function day(timestamptz) RETURNS smallint STABLE
AS 'select extract(day from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
Create or replace Function month(date) RETURNS smallint STABLE
AS 'select extract(month from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur month
select now(),'Erzeuge Funktion month'
from xdummy;
Create or replace Function month(timestamptz) RETURNS smallint STABLE
AS 'select extract(month from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
Create or replace Function year(date) RETURNS smallint STABLE
AS 'select extract(year from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur year
select now(),'Erzeuge Funktion year'
from xdummy;
Create or replace Function year(timestamptz) RETURNS smallint STABLE
AS 'select extract(year from $1)::smallint 'LANGUAGE sql;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
Create or replace Function week(date) RETURNS smallint STABLE
AS 'select extract(week from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur week
select now(),'Erzeuge Funktion week'
from xdummy;
Create or replace Function week(timestamptz) RETURNS smallint STABLE
AS 'select extract(week from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
Create or replace Function second(time) RETURNS smallint STABLE
AS 'select extract(second from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur second
select now(),'Erzeuge Funktion second'
from xdummy;
Create or replace Function second(timestamptz) RETURNS smallint STABLE
AS 'select extract(second from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
Create or replace Function minute(time) RETURNS smallint STABLE
AS 'select extract(minute from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur minute
select now(),'Erzeuge Funktion minute'
from xdummy;
Create or replace Function minute(timestamptz) RETURNS smallint STABLE
AS 'select extract(minute from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
Create or replace Function hour(time) RETURNS smallint STABLE
AS 'select extract(hour from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur hour
select now(),'Erzeuge Funktion hour'
from xdummy;
Create or replace Function hour(timestamptz) RETURNS smallint STABLE
AS 'select extract(hour from $1)::smallint ' LANGUAGE sql;
--Funktion / Prozedur current
select now(),'Erzeuge Funktion current'
from xdummy;
Create or replace Function current() RETURNS timestamptz STABLE
AS 'select now() ' LANGUAGE sql;
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
Create or replace Function today() RETURNS date STABLE
AS 'select current_date ' LANGUAGE sql;
--Funktion / Prozedur suchen_ersetzen
select now(),'Erzeuge Funktion suchen_ersetzen'
from xdummy;
Create or replace Function suchen_ersetzen(text,text,text) returns text
as '
Declare zs text;
@ -176,392 +76,147 @@ k := position(alt in s1); @@ -176,392 +76,147 @@ k := position(alt in s1);
END;
' LANGUAGE plpgsql;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
Create or replace Function weekday(date) RETURNS text STABLE
AS 'select to_char($1,''Dy'')::text ' LANGUAGE sql;
--Funktion / Prozedur weekday
select now(),'Erzeuge Funktion weekday'
from xdummy;
Create or replace Function weekday(timestamptz) RETURNS text STABLE
AS 'select weekday(date($1))::text ' LANGUAGE sql;
--Funktion / Prozedur time_stamp
select now(),'Erzeuge Funktion time_stamp'
from xdummy;
Create or replace Function time_stamp(text) RETURNS timestamptz STABLE
AS 'select to_timestamp($1,''DD.MM.YYYY HH24.MI.SS'')' LANGUAGE sql;
--Funktion / Prozedur date_val
select now(),'Erzeuge Funktion date_val'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_date_val_pg.sql
--Funktion / Prozedur date
select now(),'Erzeuge Funktion date'
from xdummy;
Create or replace Function date(text) RETURNS date STABLE
AS 'select to_date($1,''DD.MM.YYYY'')' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
Create or replace Function nvl(float,integer) RETURNS float STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
Create or replace Function nvl(decimal,integer) RETURNS decimal STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(numeric,numeric) RETURNS numeric STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(smallint,smallint) RETURNS smallint STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(integer,integer) RETURNS integer STABLE
AS 'select coalesce($1,$2);' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(varchar,char) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where
$1 is null;' LANGUAGE sql;
--Funktion / Prozedur now
select now(),'Erzeuge Funktion now'
from xdummy;
--Funktion / Prozedur timestamp_to_date
select now(),'Erzeuge Funktion timestamp_to_date'
from xdummy;
CREATE or replace FUNCTION timestamp_to_date(timestamptz) RETURNS date STABLE
AS 'select to_date(day($1)||''.'' || month($1) || ''.'' || year($1),''DD.MM.YYYY'')' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(char) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(text) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(varchar) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur string_not_null
select now(),'Erzeuge Funktion string_not_null'
from xdummy;
CREATE or replace FUNCTION string_not_null(integer) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select '''' where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur timestamp_str
select now(),'Erzeuge Funktion timestamp_str'
from xdummy;
CREATE or replace FUNCTION timestamp_str(timestamptz) RETURNS text STABLE
AS 'select to_char($1,''DD.MM.YYYY HH24:MI:SS '');' LANGUAGE sql;
--Funktion / Prozedur date_str
select now(),'Erzeuge Funktion date_str'
from xdummy;
CREATE or replace FUNCTION date_str(date) RETURNS text STABLE
AS 'select to_char($1,''DD.MM.YYYY'') ;' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(text) RETURNS integer STABLE
AS 'select to_number($1,repeat(''9'',length($1) ))::integer where trim($1) !='''' and $1 ~ ''0*[0-9][0-9]*'' ' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(char(255)) RETURNS integer STABLE
AS 'select to_number($1,repeat(''9'',length($1) ))::integer where trim($1) !='''' and $1 ~ ''0*[0-9][0-9]*'' ' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(varchar(255)) RETURNS integer STABLE
AS 'select to_number($1,repeat(''9'',length($1) ))::integer where trim($1) !='''' and $1 ~ ''0*[0-9][0-9]*''' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(integer) RETURNS integer STABLE
AS 'select $1::integer ' LANGUAGE sql;
--Funktion / Prozedur val
select now(),'Erzeuge Funktion val'
from xdummy;
CREATE or replace FUNCTION val(smallint) RETURNS integer STABLE
AS 'select $1::integer ' LANGUAGE sql;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
CREATE or replace FUNCTION decval(varchar(255)) RETURNS numeric(16,2) STABLE
AS 'select to_number($1,''S9999999999999D99'' ) where trim($1) !='''' ' LANGUAGE sql;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
CREATE or replace FUNCTION decval(text) RETURNS numeric(16,2) STABLE
AS 'select to_number($1,''S9999999999999D99'' ) where trim($1) !='''' ' LANGUAGE sql;
--Funktion / Prozedur decval
select now(),'Erzeuge Funktion decval'
from xdummy;
CREATE or replace FUNCTION decval(char(255)) RETURNS numeric(16,2) STABLE
AS 'select to_number($1,''S9999999999999D99'' ) where trim($1) !='''' ' LANGUAGE sql;
--Funktion / Prozedur sp_filter_orga
select now(),'Erzeuge Funktion sp_filter_orga'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_filter_orga_pg.sql
--Funktion / Prozedur sp_update_sequence
select now(),'Erzeuge Funktion sp_update_sequence'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_update_sequence_pg.sql
--Funktion / Prozedur sp_bool_to_smallint
select now(),'Erzeuge Funktion sp_bool_to_smallint'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_bool_to_smallint_pg.sql
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(varchar,varchar) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(char,char) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(text,text) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where $1 is null;' LANGUAGE sql;
--Funktion / Prozedur nvl
select now(),'Erzeuge Funktion nvl'
from xdummy;
CREATE or replace FUNCTION nvl(char,varchar) RETURNS text STABLE
AS 'select $1::text where $1 is not null union select $2::text where
$1 is null;' LANGUAGE 'sql';
--Funktion / Prozedur sp_get_subquery_str
select now(),'Erzeuge Funktion sp_get_subquery_str'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_subquery_str_pg.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_pg.sql
--Funktion / Prozedur sp_get_keylist_str
select now(),'Erzeuge Funktion sp_get_keylist_str'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_keylist_str_short_pg.sql
--Funktion / Prozedur sp_get_benutzer
select now(),'Erzeuge Funktion sp_get_benutzer'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_benutzer_pg.sql
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_trunc_string_pg.sql
--Funktion / Prozedur sp_trunc_string
select now(),'Erzeuge Funktion sp_trunc_string'
from xdummy;
--Funktion / Prozedur sp_table_exists
select now(),'Erzeuge Funktion sp_table_exists'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_table_exists_pg.sql
--Funktion / Prozedur sp_view_exists
select now(),'Erzeuge Funktion sp_view_exists'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_sp_view_exists_pg.sql
--Funktion / Prozedur today
select now(),'Erzeuge Funktion today'
from xdummy;
--Funktion / Prozedur to_number
select now(),'Erzeuge Funktion to_number'
from xdummy;
--Funktion / Prozedur sp_get_dbform_right
select now(),'Erzeuge Funktion sp_get_dbform_right'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_get_dbform_right_pg.sql
--Funktion / Prozedur add_sem
select now(),'Erzeuge Funktion add_sem'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/add_sem_pg.sql
--Funktion / Prozedur sp_set_organigramm_eb
select now(),'Erzeuge Funktion sp_set_organigramm_eb'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_eb_pg.sql
--Funktion / Prozedur sp_set_organigramm_lehr
select now(),'Erzeuge Funktion sp_set_organigramm_lehr'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/proc_set_organigramm_lehr_pg.sql
--Funktion / Prozedur trim_all_whitespace
select now(),'Erzeuge Funktion trim_all_whitespace'
from xdummy;
\! DOSQL $SUPERX_DIR/db/install/prozeduren/trim_all_whitespace_pg.sql

4
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_tables_ids.sql

@ -5,7 +5,7 @@ @@ -5,7 +5,7 @@
<sqlvar name="tables" type="list">
select
tabid,tabname as tabelle from systables where tabname
tabname as tabelle from systables where tabname
in ('sichtart_rechttabelle',
'group_field_pref',
'stylesheet_field',
@ -425,7 +425,7 @@ name_intern NCHAR(200) , @@ -425,7 +425,7 @@ name_intern NCHAR(200) ,
name NCHAR(200) ,
beschreibung NCHAR(255) ,
sortnr INTEGER default 0 not null,
quelle NCHAR(255) ,
quelle TEXT ,
alt_hier_id NCHAR(150) ,
treecfgtable NCHAR(255) ,
treecfgid NCHAR(150) ,

2
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_tables_pg.sql

@ -584,7 +584,7 @@ name_intern CHAR(200) , @@ -584,7 +584,7 @@ name_intern CHAR(200) ,
name CHAR(200) ,
beschreibung CHAR(255) ,
sortnr INTEGER default 0 not null,
quelle CHAR(255) ,
quelle TEXT ,
alt_hier_id CHAR(150) ,
treecfgtable CHAR(255) ,
treecfgid CHAR(150) ,

30
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_views_ids.sql

@ -2,10 +2,10 @@ @@ -2,10 +2,10 @@
--SQL Script automatisch generiert von SuperX module_upgrade.xsl
--Freemarker Template
<sqlvars>
<sqlvar name="views">
<sqlvar name="views" type="list">
select
tabid,tabname as tabelle from systables where tabname
tabname as tabelle from systables where tabname
in ('user_groups',
'menu_element_fieldmode',
'menu_element_mandatory',
@ -614,6 +614,19 @@ kfz, @@ -614,6 +614,19 @@ kfz,
bland_druck,
bland_kurz,
bland_astat) as
SELECT
apnr,
TRIM(level3_char) AS astat,
druck,
TRIM(level1_char) AS kfz,
TRIM(level2_str) AS bland_druck,
TRIM(level2_char) AS bland_kurz,
TRIM(level3_str) AS bland_astat
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
;
</#if>
@ -1040,6 +1053,19 @@ kfz, @@ -1040,6 +1053,19 @@ kfz,
bland_druck,
bland_kurz,
bland_astat) as
SELECT
apnr,
TRIM(level3_char) AS astat,
druck,
TRIM(level1_char) AS kfz,
TRIM(level2_str) AS bland_druck,
TRIM(level2_char) AS bland_kurz,
TRIM(level3_str) AS bland_astat
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
;
</#if>

6
superx/WEB-INF/conf/edustore/db/install/upgrade/kern_upgrade_views_pg.sql

@ -2,7 +2,7 @@ @@ -2,7 +2,7 @@
--SQL Script automatisch generiert von SuperX module_upgrade.xsl
--Freemarker Template
<sqlvars>
<sqlvar name="views">
<sqlvar name="views" type="list">
select relname,relname as tabelle from pg_class where relname::varchar(200) in ('user_groups',
'menu_element_fieldmode',
@ -641,7 +641,7 @@ bland_astat) as @@ -641,7 +641,7 @@ bland_astat) as
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz');
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
;
</#if>
@ -1080,7 +1080,7 @@ bland_astat) as @@ -1080,7 +1080,7 @@ bland_astat) as
FROM
dim_bp_apnr
WHERE
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz');
dimension_bp_id = (SELECT tid FROM dimension_bp WHERE apnr='bluep_hzbkfz')
;
</#if>

49
superx/WEB-INF/conf/edustore/db/install/upgrade/kernmodul_upgrade_man.sql

@ -1,4 +1,7 @@ @@ -1,4 +1,7 @@
--freemarker template
<#include "SQL_lingua_franca"/>
<#include "SuperX_general"/>
<sqlvars>
<sqlvar name="konstanten">
select apnr,beschreibung from konstanten
@ -133,7 +136,32 @@ where filename in ('tabelle2jasperreport_generic.xsl'); @@ -133,7 +136,32 @@ where filename in ('tabelle2jasperreport_generic.xsl');
update sx_repository set content='servlet/SuperXmlAnmeldung'
where id='WELCOME_XML'
and content='xml/index.jsp';
and (content='xml/index.jsp' or content='/xml/index.jsp') ;
--Default Welcome Page in kern 5.0
update sx_captions set contents_long='=Willkommen zu SuperX=
[[Image:superx_logo.png]]
Geben Sie links Ihren Benutzernamen und Ihr Kennwort ein. Danach erscheint das Menü mit den Abfragen.
Ein Benutzerhandbuch finden Sie [http://benutzerhandbuch.superx-projekt.de hier].
Weitere Ressourcen
Die WWW-Adresse von SuperX lautet [http://www.superx-projekt.de www.superx-projekt.de], eine ganze Domain nur für SuperX. Darunter finden sich noch weitere Subdomains bzw Mailadressen.
{| border="1"
|-
||Community|| http://community.superx-projekt.de
|-
||Module|| http://module.superx-projekt.de
|-
||Download|| http://download.superx-projekt.de
|-
||Weitere Infos und Support || info@superx-projekt.de
|-
|}
'
where id='WIKI_WELCOME' and locale='de' and contents_long ilike '%forum%';
alter table sichten alter column quelle type text;
</#if>
@ -141,3 +169,22 @@ and content='xml/index.jsp'; @@ -141,3 +169,22 @@ and content='xml/index.jsp';
update sx_captions set contents_short='http://www.superx-projekt.de/doku/kern_modul/benutzer/'
where id='REPORT_DOCUMENTATION_URL'
and 2=(select apnr from konstanten where beschreibung='PLATTFORM');
--kern 5.0 Duplikate 'Benutzer verwalten' bei Themenbaum entfernen:
<@selectintotmp source="themenbaum T" target="tmp_dummy" select="T.tid,T.parent,null::integer as richtig"/>
where name='Benutzer verwalten';
<@informixnolog/>;
update tmp_dummy set richtig=(select min(T.tid)
from themenbaum T where T.name='Benutzer verwalten'
and T.parent is not null);
update themenbaum set parent=(select min(T.richtig)
from tmp_dummy T where T.richtig is not null)
where parent in (select D.tid from tmp_dummy D);
delete from themenbaum where tid in (select T.tid from tmp_dummy T
where T.tid !=T.richtig);
drop table tmp_dummy;

1
superx/WEB-INF/conf/obsoletfiles.txt

@ -31,6 +31,7 @@ WEB-INF/lib/commons-beanutils-1.6.jar @@ -31,6 +31,7 @@ WEB-INF/lib/commons-beanutils-1.6.jar
WEB-INF/lib/commons-digester-1.5.jar
WEB-INF/lib/itext-1.01.jar
WEB-INF/lib/itext-1.02b.jar
WEB-INF/lib/ifxjdbc.jar
WEB-INF/lib/xercesImpl.jar
WEB-INF/lib/jcommon-0.9.6.jar
WEB-INF/lib/jfreechart-0.9.21.jar

40
superx/WEB-INF/http_get_masken_blacklist.txt

@ -15,10 +15,18 @@ @@ -15,10 +15,18 @@
70630
# Maske: Feld löschen
70620
# Maske: Feld bearbeiten
70640
# Maske: Maske kopieren
70350
# Maske: Maske löschen
70370
# Maske: Gruppe einrichten
71120
# Maske: Gruppe löschen
71140
# Gruppe kopieren
71220
# Maske: Tabelle hochladen (CSV)
71240
# Maske: Datensieb erstellen
@ -37,6 +45,8 @@ @@ -37,6 +45,8 @@
23160
# Maske: Flächendaten anzeigen/einfrieren
10300
# Maske: Flächendaten löschen
10340
# Maske: Dokument hochladen
32320
# Maske: Grunddaten und Kennzahlen hinzufügen (Datei)
@ -53,11 +63,41 @@ @@ -53,11 +63,41 @@
19910
# Maske: CNW erzeugen
25160
# Maske: CNW kopieren
25420
# Maske: LDS Tabelle hochladen
25600
# Maske: Studiengang erzeugen
25380
# Maske: Studiengang zuordnen
25140
# Maske: Studiengang löschen / abwickeln
25120
# Maske: Studiengangs-Merkmale übertragen
25520
# Maske: Studiengang-Kosten zuweisen
25400
# Maske: Prüfungen Gewichtungsvorschau
160240
# Maske: Studierende Gewichtungsvorschau
160200
# Maske: Wirtschaftsplan, Leerstellenbericht und Großforschungsprojekte abrufen
32140
# Maske: Entladeparameter bearbeiten
71260
# Maske: Hoererstatus bearbeiten
160580
# Maske: Promovierendenstatistik zusammenstellen
34000
# Maske Stud-Prüf-Statistik (nov.) zusammenstellen
39020
# Maske: Stud-Prüf-Statistik (nov.) gelieferte Prüfungen markieren
39140
# Maske: Stud-Prüf-Statistik gelieferte Prüfungen markieren aus Lieferdatei
39160
# Maske: AKL-Daten zusammenstellen und exportieren
39320
# Maske: Passwort ändern
70060
# Maske: Benutzerdaten ändern
71010

18
superx/WEB-INF/http_get_masken_whitelist_vorlage.txt

@ -8,7 +8,6 @@ @@ -8,7 +8,6 @@
10270
10280
10320
10340
10360
10380
10400
@ -248,8 +247,6 @@ @@ -248,8 +247,6 @@
25060
25080
25100
25120
25140
25180
25200
25220
@ -260,9 +257,6 @@ @@ -260,9 +257,6 @@
25320
25340
25360
25380
25400
25420
25440
25460
25480
@ -331,17 +325,11 @@ @@ -331,17 +325,11 @@
33200
33220
33230
34000
34020
39020
39040
39100
39120
39140
39160
39180
39240
39320
39360
39380
41000
@ -353,27 +341,22 @@ @@ -353,27 +341,22 @@
41130
42000
44410
70060
70160
70170
70510
70570
70600
71000
71010
71030
71040
71050
71080
71090
71100
71120
71160
71180
71190
71200
71220
71260
71280
71300
71320
@ -403,7 +386,6 @@ @@ -403,7 +386,6 @@
160480
160500
160520
160580
160600
160620
160640

2
superx/WEB-INF/kern_dbforms-config_ids.xml

@ -1060,7 +1060,7 @@ @@ -1060,7 +1060,7 @@
<field name="sortnr" description="Sortiernummer" fieldType="int" size="6" isKey="" defaultValue="0" sortable="">
<comment>kann für Sortierungen benutzt werden</comment>
</field>
<field name="quelle" description="Quelle" fieldType="char" size="255" isKey="" sortable="">
<field name="quelle" description="Quelle" fieldType="blob" size="32000" isKey="" sortable="">
<comment>Angabe einer Tabelle mit
key,parent,name,gueltig_seit,gueltig_bis oder Prozedur, die mit
sp_ anfängt</comment>

2
superx/WEB-INF/kern_dbforms-config_pg.xml

@ -1060,7 +1060,7 @@ @@ -1060,7 +1060,7 @@
<field name="sortnr" description="Sortiernummer" fieldType="int" size="6" isKey="" defaultValue="0" sortable="">
<comment>kann für Sortierungen benutzt werden</comment>
</field>
<field name="quelle" description="Quelle" fieldType="char" size="255" isKey="" sortable="">
<field name="quelle" description="Quelle" fieldType="long varchar" size="32000" isKey="" sortable="">
<comment>Angabe einer Tabelle mit
key,parent,name,gueltig_seit,gueltig_bis oder Prozedur, die mit
sp_ anfängt</comment>

BIN
superx/WEB-INF/lib/ifxjdbc-4.50.4.1.jar

Binary file not shown.

BIN
superx/WEB-INF/lib/ifxjdbc.jar

Binary file not shown.

BIN
superx/WEB-INF/lib/superx5.0.jar

Binary file not shown.

2
superx/edit/kern/sichten_edit.jsp

@ -202,7 +202,7 @@ dbConnectionName="<%= mandantenid %>" ><input type="hidden" name="${_csrf.parame @@ -202,7 +202,7 @@ dbConnectionName="<%= mandantenid %>" ><input type="hidden" name="${_csrf.parame
<td class="db_label">
<db:message key="Quelle"/></td><td align="left">
<div id="fld_quelle">
<db:textField nullFieldValue="" styleClass="clsInputStyle" onBlur="" maxlength="255" size="40" id="inp_sichtenquelle" fieldName="quelle"/>
<db:textArea nullFieldValue="" onBlur="" styleClass="clsInputStyle" wrap="virtual" rows="6" cols="80" fieldName="quelle"/>
</div>
<span style="display:none" connectId="fld_quelle" dojoType="tooltip">Angabe einer Tabelle mit
key,parent,name,gueltig_seit,gueltig_bis oder Prozedur, die mit

211
superx/edit/kern/webapp_manager.jsp

@ -2,6 +2,12 @@ @@ -2,6 +2,12 @@
<%@page pageEncoding="utf-8" contentType="text/html; charset=UTF-8" %>
<%@ page import ="de.superx.servlet.ServletUtils" %>
<%@ page import ="de.superx.servlet.SxPools" %>
<%@ page import ="java.lang.management.*" %>
<%@ page import ="java.util.List" %>
<%@ page import ="java.util.Properties" %>
<%@ page import ="java.util.Enumeration" %>
<%@ page import ="java.io.File" %>
<%@ page import ="de.memtext.util.FileUtils" %>
<html>
@ -71,7 +77,7 @@ var xhttp = new XMLHttpRequest(); @@ -71,7 +77,7 @@ var xhttp = new XMLHttpRequest();
}
function getMaskLogs(logtype,caption)
function getLogs(logtype,caption,loglines)
{
document.getElementById("MaskHeader").innerHTML="Protokolle";
@ -83,17 +89,61 @@ var xhttp = new XMLHttpRequest(); @@ -83,17 +89,61 @@ var xhttp = new XMLHttpRequest();
//alert(this.responseText);
}
};
xhttp.open("GET", "../../sxrest/masklogs/"+logtype, true);
xhttp.open("GET", "../../sxrest/logs/"+logtype+"?loglines="+loglines, true);
xhttp.send();
}
function showLogElem(outElem,caption)
{
document.getElementById("LogHeader").innerHTML=caption;
//document.getElementById("LogSubHeader").innerHTML=caption;
const allElems = ["catalinaOut", "sqlOut", "xmlOut"];
for (const element of allElems) {
if(outElem==element)
document.getElementById(element).style.display="block";
else
document.getElementById(element).style.display="none";
}
}
</script>
<body>
<%
Object userobject=request.getSession().getAttribute("UserID");
String userid;
if(userobject == null)
{
%>
<jsp:forward page="/edit/not_authenticated.htm"/>
<%
}
else
userid=userobject.toString();
Object mandantobject=request.getSession().getAttribute("MandantenID");
String mandantenid="";
if(mandantobject != null)
mandantenid=mandantobject.toString();
//der superx-Default-Mandant ist bei dbforms ein Leerstring
if(mandantenid.equals("default"))
mandantenid="";
String db_form_name="userinfo";
String erlaubt="0";
%>
<%@ include file="/edit/check_authentication.inc" %>
<%
if(erlaubt.equals("0"))
{
%>
<jsp:forward page="/edit/not_authorized.htm"/>
<%
}
//init Variables:
String EntwicklungsmodusAn="";
String EntwicklungsmodusAus="checked";
@ -106,15 +156,35 @@ if(de.superx.servlet.SuperXManager.isDevelopmentMode) @@ -106,15 +156,35 @@ if(de.superx.servlet.SuperXManager.isDevelopmentMode)
}
String sxversion=de.superx.servlet.SuperXManager.sxversion;
String builddatum=de.superx.servlet.SuperXManager.builddatum;
String mandantenid=ServletUtils.getMandantenID(request);
String finRechteInfos=SxPools.getPoolFinRechteInfos();
String platform=de.superx.servlet.SuperXManager.isHis1?"HISinOne":"SuperX";
String webinfpfad=de.superx.servlet.SuperXManager.getWEB_INFPfad();
String javaVersion=System.getProperties().get("java.version").toString();
//String jvmMemory=String.valueOf(Runtime.totalMemory()/(1024* 1024));
RuntimeMXBean runtimeMXBean = ManagementFactory.getRuntimeMXBean();
List<String> jvmArgs = runtimeMXBean.getInputArguments();
Properties props = new Properties();
String dbpropfile="db.properties";
if(mandantenid.equals(""))
mandantenid="default";
if(!mandantenid.equalsIgnoreCase("default"))
dbpropfile="db_"+mandantenid+".properties";
String dbproppath=webinfpfad+ File.separator+dbpropfile;
java.io.FileInputStream is = new java.io.FileInputStream(dbproppath);
if (is != null) {
props.load(is);
is.close();
} else {
System.err.println("kann "+ dbproppath +" nicht einlesen");
}
String tab = request.getParameter("tab");
if(tab == null)
tab="";
%>
<!-- START NAV -->
<nav class="navbar is-white">
@ -140,6 +210,13 @@ if(tab == null) @@ -140,6 +210,13 @@ if(tab == null)
<a class="navbar-item" href="webapp_manager.jsp?tab=mask">
Masken
</a>
<a class="navbar-item" href="webapp_manager.jsp?tab=db">
Datenbank
</a>
<a class="navbar-item" href="webapp_manager.jsp?tab=log">
Logs
</a>
</div>
</div>
@ -151,13 +228,9 @@ if(tab == null) @@ -151,13 +228,9 @@ if(tab == null)
<div class="columns">
<div class="column is-3 ">
<aside class="menu is-hidden-mobile">
<p class="menu-label">
Untermenü
</p>
<ul class="menu-list">
<li><a class="is-active">Startseite</a></li>
<!--<li><a>Customers</a></li>
<li><a>Other</a></li>-->
<li><a class="is-active">Untermenü</a></li>
</ul>
<%
if(tab.equals("mask"))
@ -167,26 +240,31 @@ if(tab.equals("mask")) @@ -167,26 +240,31 @@ if(tab.equals("mask"))
Maskenprotokolle
</p>
<ul class="menu-list">
<li><a onClick="getMaskLogs('activity','Letzte Maske');">Letzte Maske</a></li>
<li><a onClick="getMaskLogs('fmsql','SQL vor Freemarker-Transformation');">SQL vor Freemarker-Transf.</a></li>
<li><a onClick="getMaskLogs('sql','SQL nach Freemarker-Transformation');">SQL nach Freemarker-Transf.</a></li>
<li><a onClick="getMaskLogs('xml','XML-Ergebnis');">XML-Ergebnis</a></li>
<li><a onClick="getLogs('activity','Letzte Maske',100000);">Letzte Maske</a></li>
<li><a onClick="getLogs('fmsql','SQL vor Freemarker-Transformation',100000);">SQL vor Freemarker-Transf.</a></li>
<li><a onClick="getLogs('sql','SQL nach Freemarker-Transformation',100000);">SQL nach Freemarker-Transf.</a></li>
<li><a onClick="getLogs('xml','XML-Ergebnis',100000);">XML-Ergebnis</a></li>
</ul>
<!-- <p class="menu-label">
Masken-Sicherung
<%
} //Ende Masken Menü
if(tab.equals("log"))
{
%>
<p class="menu-label">
Server-Logdateien
</p>
<ul class="menu-list">
<li><a onClick="getMaskMenu('load');">Masken-Quellcode exportieren</a></li>
<li><a onClick="getMaskMenu('save');">Masken-Quellcode importieren</a></li>
<li><a onClick="getLogs('serverlog','Server log',document.forms['log'].elements['loglines'].value);">Server log</a></li>
<li><a onClick="getLogs('serverlogsql','SQL-Log',document.forms['log'].elements['loglines'].value);">SQL log</a></li>
<li><a onClick="getLogs('serverlogxml','XML-Log',document.forms['log'].elements['loglines'].value);">XML log</a></li>
</ul>
-->
<%
} //Ende Masken Menü
<%
} //Ende log Menü
%>
</aside>
</div>
<div class="column is-9">
@ -208,33 +286,23 @@ if(tab.equals("")) @@ -208,33 +286,23 @@ if(tab.equals(""))
</div>
</section>
<section class="info-tiles">
<!-- <div class="tile is-ancestor has-text-centered">
<div class="tile is-ancestor has-text-centered">
<div class="tile is-parent">
<article class="tile is-child box">
<p class="title">Entwicklungs-<br />modus</p>
<p class="subtitle">SQL einzeln abarbeiten?</p>
<form name="DevelopmentMode">
<div class="control">
<label class="radio">
<input type="radio" name="Entwicklungsmodus" <%=EntwicklungsmodusAus %> >
Aus
</label>
<label class="radio">
<input type="radio" name="Entwicklungsmodus" <%=EntwicklungsmodusAn %> >
Ein
</label>
<button class="button has-tooltip-multiline has-tooltip-right"
data-tooltip="Im Entwicklungsmodus werden alle SQL-Befehle von Abfragen einzeln an die Datenbank geschickt. Das dauert l&auml;nger, erm&ouml;glicht aber bessere Fehlermeldungen. Achtung: bei Informix sollten Sie den Entwicklungsmodus nicht ausschalten, der JDBC-Treiber arbeitet dann instabil."
onClick="toggleDevelopmentMode(document.forms['DevelopmentMode'].elements['Entwicklungsmodus'][1].checked);return false;"
>Übernehmen</button>
<br />
<span id="toggleDevelopmentmodeStatus"></span>
</form>
</div>
<p class="title">Serverumgebung</p>
<p class="subtitle">JVM-Parameter</p>
<textarea name="env" readonly="readonly" rows="10" cols="30"><%
out.println("Java Version:"+javaVersion.trim());
out.println("WEB-INF-Pfad: "+ webinfpfad);
for (String arg : jvmArgs) {
out.println(arg);
}
%></textarea>
</article>
</div>-->
</div>
<div class="tile is-parent">
<article class="tile is-child box">
<p class="title">Server Cache</p>
@ -309,36 +377,61 @@ if(tab.equals("mask")) @@ -309,36 +377,61 @@ if(tab.equals("mask"))
</section>
<%
} //Ende Mask Content
%>
<%
if(tab.equals("action"))
if(tab.equals("db"))
{
%>
<section class="section">
<div class="container">
<h1 class="title" id="MaskHeader">Komponenten</h1>
<h1 class="title" id="MaskHeader">Datenbank</h1>
<h2 class="subtitle">
<div id="MaskSubHeader">Install / Upgrade / Hauptladeroutinen / Unterladeroutinen </div>
<div id="MaskSubHeader">Verbindungsparameter</div>
</h2>
<p align="left"><%
Enumeration propNames = props.propertyNames();
while (propNames.hasMoreElements()) {
String propName = (String)propNames.nextElement();
String propValue = props.getProperty(propName);
if(propName.equals("connectionPassword"))
out.println(propName+": ...<br />");
else
out.println(propName+": "+ propValue+"<br />");
<div class="bd-snippet-code highlight-full ">
<figure class="highlight"><div class="buttons has-addons is-right">
<button class="button is-small is-info" onClick="copyText('Inhalt');">Kopieren</button>
}
%>
</p>
</div>
</section>
<%
} //Ende db Content
if(tab.equals("log"))
{
%>
<section class="section">
<form name="log" >
<div class="container" id="loadMask" >
<h1 class="title" id="MaskHeader">Server-Logdateien</h1>
<h2 class="subtitle">
<div id="MaskSubHeader">Logtyp</div>
</h2>
<div> (max. <input type="text" size="5" maxlength="5" name="loglines" value="100" /> Zeilen)
<textarea id="Inhalt" name="Inhalt" class="textarea" placeholder="Inhalt..." rows="20"></textarea>
<textarea id="Inhalt" class="textarea" placeholder="Inhalt..." rows="20"></textarea>
<!--<div id="Inhalt">...</div>-->
</figure>
</div>
</div>
</section>
</form>
</section>
<%
} //Ende Action Content
} //Ende log Content
%>
</div>
</div>
</div>
</div>
<!--<script async type="text/javascript" src="../js/bulma.js"></script>-->

34
superx/edit/not_authenticated.htm

@ -3,32 +3,24 @@ @@ -3,32 +3,24 @@
<title>Not authenticated</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<base target="_self">
<LINK REL="stylesheet" type="text/css" href="../style/superx.css"/>
<LINK REL="stylesheet" type="text/css" href="../../style/superx.css"/>
<link rel="stylesheet" href="../../style/bulma.css" />
</head>
<body>
<div id="bg">
<div id="inhalt">
<h1>Session ist abgelaufen</h1>
<p>
<STRONG>Ihre Sitzung ist abgelaufen.</STRONG><br />
<section class="hero is-info">
<div class="hero-body">
<p class="title">
Session ist abgelaufen
</p>
<p class="subtitle">
Ihre Sitzung ist abgelaufen.<br />
Der Server speichert ihre Benutzereingaben f&uuml;r eine gewisse Zeit, und wenn Sie regelm&auml;&szlig;ig Eingaben t&auml;tigen
wird ihre Sitzung problemlos gespeichert. Bei l&auml;ngerer Inaktivit&auml;t oder hoher Server-Last kann es jedoch passieren, dass Ihre Sitzung nicht gespeichert bleibt.
In diesem Falle m&uuml;ssen Sie sich zur <a href="../../xml/index.htm" target="_parent">Startseite</a> begeben und neu anmelden.
</P>
<div id="fuss">
In diesem Falle m&uuml;ssen Sie sich zur <a href="../../">Startseite</a> begeben und neu anmelden.
</p>
</div>
</section>
<!-- /seite_empfehlen.php -->
<br /><br /><br /><br /><br /><br /><br /><br /><br /><br />
</div>
</div>
<!-- Ende Inhaltsbereich -->
<!-- Ende Linkboxen und Subnavigation dritte Ebene-->
</div>
<!-- Ende Backgroundlayer -->
<!-- -->
</body>
</html>

33
superx/edit/not_authorized.htm

@ -3,30 +3,23 @@ @@ -3,30 +3,23 @@
<title>Not authorized</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<base target="_self">
<LINK REL="stylesheet" type="text/css" href="../style/superx.css"/>
<link rel="stylesheet" href="../../style/bulma.css" />
</head>
<body>
<div id="bg">
<div id="inhalt">
<h1>Fehlende Rechte</h1>
<p>
<STRONG>Ihre Benutzerkennung besitzt nicht die Rechte f&uuml;r diese Aktion.</STRONG><br />
Bitten wenden Sie sich an Ihren Administrator, um die Rechte zu bekommen. Melden Sie sich dann neu an auf der <a href="../../index.htm" target="_parent">Startseite</a>.
</P>
<div id="fuss">
<section class="hero is-info">
<div class="hero-body">
<p class="title">
Fehlende Rechte
</p>
<p class="subtitle">
Ihre Benutzerkennung besitzt nicht die Rechte f&uuml;r diese Aktion.
<br />
Bitten wenden Sie sich an Ihren Administrator, um die Rechte zu bekommen. Melden Sie sich dann neu an auf der <a href="../../" target="_parent">Startseite</a>.
<!-- /seite_empfehlen.php -->
<br /><br /><br /><br /><br /><br /><br /><br /><br /><br />
</div>
</div>
<!-- Ende Inhaltsbereich -->
</p>
</div>
</section>
<!-- Ende Linkboxen und Subnavigation dritte Ebene-->
</div>
<!-- Ende Backgroundlayer -->
<!-- -->
</body>
</html>

BIN
superx/images/superx_logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

1
superx/xml/maskComponents_html.xsl

@ -1478,7 +1478,6 @@ jQuery.ajaxPrefilter( function( s ) { @@ -1478,7 +1478,6 @@ jQuery.ajaxPrefilter( function( s ) {
var caption;
var jsessionid=']]></xsl:text><xsl:value-of select="/maske/@jsessionid"/><xsl:text>';
var maskentid=</xsl:text><xsl:value-of select="/maske/@tid"/><xsl:text>;
var maskenname='</xsl:text><xsl:value-of select="/maske/@name"/><xsl:text>';
var mandantenID='</xsl:text><xsl:value-of select="/maske/@MandantenID"/><xsl:text>';
var felder = new Array();
</xsl:text>

6
superx/xml/menue_html.xsl

@ -223,14 +223,14 @@ @@ -223,14 +223,14 @@
</xsl:if>
<li style="list-style:none"><p class="listlevel">&#160;</p></li>
<xsl:choose>
<xsl:when test="/*/@hisinone_active='true'">
<xsl:when test="/*/@hisinone_active='true' or starts-with(/menue/nachricht, 'gast')">
</xsl:when>
<xsl:otherwise>
<li style="list-style:none" class="ebene1"><p class="listlevel"><a class="ebene_his_1 icon icon-arrows-cw" tabindex="30" href="/superx/servlet/de.superx.servlet.SuperXmlPwChanger" target="_parent" style="cursor:pointer;">Passwort ändern</a></p></li>
<li style="list-style:none" class="ebene1"><p class="listlevel"><a class="ebene_his_1 icon icon-arrows-cw" tabindex="30" href="/superx/servlet/de.superx.servlet.SuperXmlPwChanger" target="_parent" style="cursor:pointer;">Passwort ändern <xsl:value-of select="/menue/user"/></a></p></li>
</xsl:otherwise>
</xsl:choose>
<li style="list-style:none"><p class="listlevel">&#160;</p></li>
<xsl:if test="$showLogoutLink='true'">
<xsl:if test="$showLogoutLink='true' and not(starts-with(/menue/nachricht, 'gast'))">
<li style="list-style:none" class="ebene1"><p class="listlevel"><a class="ebene_his_1 icon icon-logout" tabindex="30" href="/superx/servlet/SuperXmlAbmeldung" target="_parent" style="cursor:pointer;">Abmelden</a></p></li>
</xsl:if></ul>

2
superx/xml/menue_html_dojo.xsl

@ -99,7 +99,7 @@ @@ -99,7 +99,7 @@
<li style="list-style:none"><p class="listlevel">&#160;</p></li>
<!-- <li style="list-style:none" class="ebene1"><p class="listlevel"><a class="ebene_his_1" tabindex="30" onclick="top.document.getElementById('superxframes').cols='40,*'; scroll(0,0); top.document.getElementById('menue').scrolling='no'; document.getElementById('navigation_on_off').style.visibility='visible';" style="cursor:pointer;">Navigation ausblenden</a></p></li> -->
<li style="list-style:none"><p class="listlevel">&#160;</p></li>
<xsl:if test="$showLogoutLink='true'">
<xsl:if test="$showLogoutLink='true' and not(starts-with(/*/nachricht, 'gast')) and not(starts-with(/menue/user, 'gast')) ">
<li style="list-style:none" class="ebene1"><p class="listlevel"><a class="ebene_his_1 icon icon-logout" tabindex="30" href="/superx/servlet/SuperXmlAbmeldung" target="_parent" style="cursor:pointer;">Abmelden</a></p></li>
</xsl:if></ul>
</div>

34
superx/xml/pageComponents_html.xsl

@ -525,15 +525,26 @@ Bit zur Lösung des Problems bleibt dies auf Kommentar @@ -525,15 +525,26 @@ Bit zur Lösung des Problems bleibt dies auf Kommentar
</a>
<span class="separator">&#160;</span>
</td>
<xsl:if test="count(/ergebnisse/stylesheets/stylesheet[filename='rpta_assistent.xsl']) !=0
and /ergebnisse/user/@admin='true'">
<td>
<xsl:if test="count(/ergebnisse/stylesheets/stylesheet[filename='rpta_assistent.xsl']) !=0">
<td><input name="RPTContentype" type="hidden" value="" />
<input name="RPTPageFormat" type="hidden" value="A4" />
<a onMouseOver="window.status='Export starten';return true" onFocus="window.status='Download starten';return true" onMouseOut="window.status='Download starten';return true" style="cursor: pointer;"><xsl:attribute name="onclick"><xsl:text>setTemplatePropertiesAndSubmit('rpta_assistent.xsl|text/html');</xsl:text>
</xsl:attribute>
<img title="Berichtsassistent" alt="Berichtsassistent"
src="../images/icons/magic.svg" border="0" class="svg_icon" />
</a><span class="separator">&#160;</span> <span class="separator">&#160;</span>
</td>
<xsl:for-each select="/ergebnisse/stylesheets/stylesheet[stylesheet_type='XSL_JRXML']">
<td>
<a onMouseOver="window.status='Export xls starten';return true" onFocus="window.status='Download starten';return true" onMouseOut="window.status='Download starten';return true" style="cursor: pointer;">
<xsl:attribute name="onclick"><xsl:text>document.forms[0].elements['RPTContentype'].value='</xsl:text><xsl:value-of select="contenttype"/><xsl:text>';setTemplatePropertiesAndSubmit('</xsl:text><xsl:value-of select="filename"/><xsl:text>|application/jrxml');</xsl:text>
</xsl:attribute>
<img title="{caption}" alt="{description}"
src="{toolbar_icon_filepath}" border="0" class="svg_icon" />
</a>
<span class="separator">&#160;</span> <span class="separator">&#160;</span>
</td>
</xsl:for-each>
</xsl:if>
<xsl:if test="count(/ergebnisse/stylesheets/stylesheet[filename='viz_html_chart.xsl']) !=0
and /ergebnisse/user/@admin='true'">
@ -1478,9 +1489,12 @@ $( "#headerwiki2" ).load('/superx/xml/header_wiki.jsp'); @@ -1478,9 +1489,12 @@ $( "#headerwiki2" ).load('/superx/xml/header_wiki.jsp');
</xsl:attribute>
Startseite</a>
</li>
<xsl:if test="not(starts-with(/*/nachricht, 'gast')) and not(starts-with(/menue/user, 'gast')) ">
<li>
<a class="topMenuLink icon icon-logout" target="_parent" href="/superx/servlet/SuperXmlAbmeldung">Abmelden</a>
</li>
</xsl:if>
</ul>
</div>
@ -1666,9 +1680,19 @@ function setTemplatePropertiesAndSubmit(selectedValue) @@ -1666,9 +1680,19 @@ function setTemplatePropertiesAndSubmit(selectedValue)
var filename=selectedValue.substring(0,selectedValue.indexOf("|"));
var contenttype=selectedValue.substr(selectedValue.indexOf("|")+1);
document.forms[0].stylesheet.value=filename;
document.forms[0].contenttype.value=contenttype;
if(contenttype !="")
document.forms[0].contenttype.value=contenttype;
document.forms[0].target="_blank";
document.forms[0].submit();
document.forms[0].offset.value='0';
document.forms[0].maxoffset.value = '1000000';
document.forms[0].reuseresult.value = 'true';
if (isTreeTable) {
dojo.widget.byId("ttexdlg").show(); //ruft function exportandhidedlg auf
}
else
{
startExport();
}
}
</script>
<!--

17
superx/xml/resultset_html.xsl

@ -106,7 +106,22 @@ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> @@ -106,7 +106,22 @@ xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
</xsl:for-each>
User: <xsl:value-of select="/ergebnisse/user"/>&#160;
Stand: <xsl:value-of select="../stand" /></p>
Stand: <!--DQ / MM 19.05.2023 Zeitangabe bei Stand entfernen wenn es nicht ueber die neue Komponentenverwaltung läuft -->
<xsl:variable name="stand_korr">
<xsl:choose>
<xsl:when test="contains(../stand,'00:00:00')">
<xsl:value-of select="substring-before(../stand,'00:00:00')" />
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="../stand" />
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:value-of select="$stand_korr" />
</p>
<xsl:if test="../hinweis != ''">
<!-- 11.3.09 MB -->
<xsl:call-template name="newline_to_br">

Loading…
Cancel
Save