WIP: left over open files for long...
This commit is contained in:
parent
0a2398c5c1
commit
76aa74990e
165 changed files with 4299 additions and 3373 deletions
|
|
@ -16,5 +16,6 @@
|
|||
<module>vasc-frontend-web-jsf</module>
|
||||
<module>vasc-frontend-web-export</module>
|
||||
<module>vasc-frontend-cxf</module>
|
||||
<module>vasc-frontend-api</module>
|
||||
</modules>
|
||||
</project>
|
||||
23
vasc-frontend/vasc-frontend-api/.project
Normal file
23
vasc-frontend/vasc-frontend-api/.project
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>vasc-frontend-api</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.jdt.core.javabuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.m2e.core.maven2Builder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>org.eclipse.m2e.core.maven2Nature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
||||
11
vasc-frontend/vasc-frontend-api/pom.xml
Normal file
11
vasc-frontend/vasc-frontend-api/pom.xml
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-frontend</artifactId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-api</artifactId>
|
||||
<name>vasc-frontend-api</name>
|
||||
<description>vasc-frontend-api</description>
|
||||
</project>
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* @author willemc
|
||||
*
|
||||
*/
|
||||
package net.forwardfire.vasc.frontend.api.event;
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* @author willemc
|
||||
*
|
||||
*/
|
||||
package net.forwardfire.vasc.frontend.api;
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
package net.forwardfire.vasc.frontend.api.view;
|
||||
|
||||
public class VascView {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
package net.forwardfire.vasc.frontend.api.view;
|
||||
|
||||
public interface VascViewComponent {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
package net.forwardfire.vasc.frontend.api.view;
|
||||
|
||||
public interface VascViewContainer {
|
||||
|
||||
int getChildCount();
|
||||
VascViewContainer getChild(int i);
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
/**
|
||||
*
|
||||
*/
|
||||
package net.forwardfire.vasc.frontend.api.view;
|
||||
|
||||
/**
|
||||
* @author willemc
|
||||
*
|
||||
*/
|
||||
public class VascViewField {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
package net.forwardfire.vasc.frontend.api.view;
|
||||
|
||||
public class VascViewFieldPanel {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* @author willemc
|
||||
*
|
||||
*/
|
||||
package net.forwardfire.vasc.frontend.api.view;
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
package net.forwardfire.vasc.frontend.api.view.table;
|
||||
|
||||
import net.forwardfire.vasc.frontend.api.view.VascViewComponent;
|
||||
|
||||
public class VascViewTable implements VascViewComponent {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
package net.forwardfire.vasc.frontend.api.view.table;
|
||||
|
||||
import net.forwardfire.vasc.frontend.api.view.VascViewComponent;
|
||||
|
||||
public class VascViewTableColumn {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
*
|
||||
*/
|
||||
/**
|
||||
* @author willemc
|
||||
*
|
||||
*/
|
||||
package net.forwardfire.vasc.frontend.api.view.table;
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
package net.forwardfire.vasc.frontend.api;
|
||||
|
||||
import net.forwardfire.vasc.frontend.api.view.VascView;
|
||||
|
||||
public class TestViewApi {
|
||||
|
||||
|
||||
public void testViewApi() {
|
||||
|
||||
VascView view = new VascView();
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
@ -1,51 +1,51 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend-cxf</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-cxf-server</artifactId>
|
||||
<name>vasc-frontend-cxf-server</name>
|
||||
<description>vasc-frontend-cxf-server</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-frontend-cxf-client</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-transports-http</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-databinding-jaxb</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-frontend-jaxws</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-frontend-jaxrs</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>servlet-api</artifactId>
|
||||
<version>${servlet-api.version}</version>
|
||||
<type>jar</type>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend-cxf</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-cxf-server</artifactId>
|
||||
<name>vasc-frontend-cxf-server</name>
|
||||
<description>vasc-frontend-cxf-server</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-frontend-cxf-client</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-transports-http</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-databinding-jaxb</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-frontend-jaxws</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.cxf</groupId>
|
||||
<artifactId>cxf-rt-frontend-jaxrs</artifactId>
|
||||
<version>${cxf-rt.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax</groupId>
|
||||
<artifactId>javaee-api</artifactId>
|
||||
<version>${javaee-api.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
|
|
|||
|
|
@ -1,35 +1,41 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-swing</artifactId>
|
||||
<name>vasc-frontend-swing</name>
|
||||
<description>vasc-frontend-swing</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.michaelbaranov</groupId>
|
||||
<artifactId>microba</artifactId>
|
||||
<version>${microba.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>de.odysseus.juel</groupId>
|
||||
<artifactId>juel</artifactId>
|
||||
<version>${juel.version}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc.test</groupId>
|
||||
<artifactId>vasc-test-frontend</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-swing</artifactId>
|
||||
<name>vasc-frontend-swing</name>
|
||||
<description>vasc-frontend-swing</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-frontend-api</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.michaelbaranov</groupId>
|
||||
<artifactId>microba</artifactId>
|
||||
<version>${microba.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>de.odysseus.juel</groupId>
|
||||
<artifactId>juel</artifactId>
|
||||
<version>${juel.version}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc.test</groupId>
|
||||
<artifactId>vasc-test-frontend</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
|
|
|||
|
|
@ -33,9 +33,9 @@ import javax.swing.JLabel;
|
|||
import javax.swing.JList;
|
||||
import javax.swing.ListCellRenderer;
|
||||
|
||||
import net.forwardfire.vasc.backend.select.VascBackendSelectItem;
|
||||
import net.forwardfire.vasc.core.VascEntry;
|
||||
import net.forwardfire.vasc.core.VascEntryField;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItem;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItemModel;
|
||||
import net.forwardfire.vasc.core.ui.VascUIComponent;
|
||||
import net.forwardfire.vasc.core.ui.VascValueModel;
|
||||
|
|
@ -69,7 +69,7 @@ public class SwingList implements VascUIComponent {
|
|||
comboBox.addActionListener(new ActionListener() {
|
||||
@Override
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
VascSelectItem i = (VascSelectItem)((JComboBox)e.getSource()).getSelectedItem();
|
||||
VascBackendSelectItem i = (VascBackendSelectItem)((JComboBox)e.getSource()).getSelectedItem();
|
||||
try {
|
||||
model.setValue(i.getValue());
|
||||
} catch (VascException ee) {
|
||||
|
|
@ -83,7 +83,7 @@ public class SwingList implements VascUIComponent {
|
|||
if (model.getValue()!=null) {
|
||||
for (int i=0;i<comboBox.getModel().getSize();i++) {
|
||||
Object o = comboBox.getModel().getElementAt(i);
|
||||
VascSelectItem i2 = (VascSelectItem)o;
|
||||
VascBackendSelectItem i2 = (VascBackendSelectItem)o;
|
||||
if ( model.getValue().equals(i2.getValue()) ) {
|
||||
comboBox.setSelectedItem(i2);
|
||||
return comboBox;
|
||||
|
|
@ -167,7 +167,7 @@ class MyCellRenderer extends JLabel implements ListCellRenderer {
|
|||
|
||||
@Override
|
||||
public Component getListCellRendererComponent(JList list,Object value,int index,boolean isSelected,boolean cellHasFocus) {
|
||||
VascSelectItem i = (VascSelectItem)value;
|
||||
VascBackendSelectItem i = (VascBackendSelectItem)value;
|
||||
if (i!=null) {
|
||||
setText(i.getLabel());
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -14,6 +14,11 @@
|
|||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-frontend-api</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<!-- SWT depency TODO: linux only, wait for 3.4 !!
|
||||
<dependency>
|
||||
<groupId>org.eclipse.swt.gtk.linux</groupId>
|
||||
|
|
|
|||
|
|
@ -25,10 +25,10 @@ package net.forwardfire.vasc.frontend.swt;
|
|||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
import net.forwardfire.vasc.backend.select.VascBackendSelectItem;
|
||||
import net.forwardfire.vasc.core.VascEntry;
|
||||
import net.forwardfire.vasc.core.actions.GlobalVascAction;
|
||||
import net.forwardfire.vasc.core.entry.VascEntryFrontendEventListener;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItem;
|
||||
import net.forwardfire.vasc.frontend.VascFrontendPageInfoNumber;
|
||||
|
||||
import org.eclipse.swt.SWT;
|
||||
|
|
|
|||
|
|
@ -128,7 +128,7 @@ public class SwtVascEditDialog extends Dialog {
|
|||
String name = null;
|
||||
try {
|
||||
Serializable bean = entry.getVascFrontendController().getVascEntryState().getEntryDataObject();
|
||||
name = dis.getVascEntryFieldValue().getDisplayValue(dis.getBackendName(), bean);
|
||||
name = ""+dis.getVascEntryFieldValue().getValue(dis.getBackendName(), bean);
|
||||
} catch (VascBackendException e) {
|
||||
throw new RuntimeException("Could not display value from "+entry.getId(),e);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -656,7 +656,7 @@ public class SwtVascFrontend extends AbstractVascFrontend {
|
|||
|
||||
//if (vtc.getVascColumnRenderer()==null) {
|
||||
try {
|
||||
return vtc.getVascEntryFieldValue().getDisplayValue(vtc.getBackendName(),(Serializable) bean);
|
||||
return ""+vtc.getVascEntryFieldValue().getValue(vtc.getBackendName(),(Serializable) bean);
|
||||
} catch (Exception e) {
|
||||
logger.log(Level.WARNING,"Error in get value: '"+vtc.getVascEntryFieldValue()+"' error: "+e.getMessage(),e);
|
||||
return "Err";
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@ package net.forwardfire.vasc.frontend.swt.ui;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import net.forwardfire.vasc.backend.select.VascBackendSelectItem;
|
||||
import net.forwardfire.vasc.core.VascEntry;
|
||||
import net.forwardfire.vasc.core.VascEntryField;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItem;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItemModel;
|
||||
import net.forwardfire.vasc.core.ui.VascUIComponent;
|
||||
import net.forwardfire.vasc.core.ui.VascValueModel;
|
||||
|
|
@ -54,7 +54,7 @@ public class SwtList implements VascUIComponent {
|
|||
private Combo combo = null;
|
||||
private Color orgBackgroundColor = null;
|
||||
private Color errorColor = null;
|
||||
private List<VascSelectItem> data = null;
|
||||
private List<VascBackendSelectItem> data = null;
|
||||
|
||||
@Override
|
||||
public Object createComponent(final VascEntry entry,VascEntryField entryField,final VascValueModel model,Object gui) throws VascException {
|
||||
|
|
@ -70,7 +70,7 @@ public class SwtList implements VascUIComponent {
|
|||
combo.addSelectionListener(new SelectionAdapter() {
|
||||
@Override
|
||||
public void widgetSelected(SelectionEvent e) {
|
||||
VascSelectItem item = findItem(combo.getText());
|
||||
VascBackendSelectItem item = findItem(combo.getText());
|
||||
if (item!=null) {
|
||||
try {
|
||||
model.setValue(item.getValue());
|
||||
|
|
@ -82,7 +82,7 @@ public class SwtList implements VascUIComponent {
|
|||
});
|
||||
|
||||
// sets default selected
|
||||
for (VascSelectItem i:data) {
|
||||
for (VascBackendSelectItem i:data) {
|
||||
Object iValue = i.getValue();
|
||||
Object mValue = model.getValue();
|
||||
if (iValue==null && mValue==null) {
|
||||
|
|
@ -107,7 +107,7 @@ public class SwtList implements VascUIComponent {
|
|||
if (data==null | combo==null) {
|
||||
return;
|
||||
}
|
||||
for (VascSelectItem i:data) {
|
||||
for (VascBackendSelectItem i:data) {
|
||||
if (i.isDisabled()) {
|
||||
continue;
|
||||
}
|
||||
|
|
@ -115,8 +115,8 @@ public class SwtList implements VascUIComponent {
|
|||
}
|
||||
}
|
||||
|
||||
private VascSelectItem findItem(String text) {
|
||||
for (VascSelectItem i:data) {
|
||||
private VascBackendSelectItem findItem(String text) {
|
||||
for (VascBackendSelectItem i:data) {
|
||||
if (i.getLabel().equals(text)) {
|
||||
return i;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,32 +1,37 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-web-export</artifactId>
|
||||
<name>vasc-frontend-web-export</name>
|
||||
<description>vasc-frontend-web-export</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core-ejb3-client</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>servlet-api</artifactId>
|
||||
<version>${servlet-api.version}</version>
|
||||
<type>jar</type>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-web-export</artifactId>
|
||||
<name>vasc-frontend-web-export</name>
|
||||
<description>vasc-frontend-web-export</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-frontend-api</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core-ejb3-client</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax</groupId>
|
||||
<artifactId>javaee-api</artifactId>
|
||||
<version>${javaee-api.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
|
|
|||
|
|
@ -1,49 +1,42 @@
|
|||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-web-jsf</artifactId>
|
||||
<name>vasc-frontend-web-jsf</name>
|
||||
<description>vasc-frontend-web-jsf</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core-ejb3-client</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>servlet-api</artifactId>
|
||||
<version>${servlet-api.version}</version>
|
||||
<type>jar</type>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>jstl</artifactId>
|
||||
<version>${jstl.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.servlet.jsp</groupId>
|
||||
<artifactId>jsp-api</artifactId>
|
||||
<version>${jsp-api.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.glassfish</groupId>
|
||||
<artifactId>javax.faces</artifactId>
|
||||
<version>${javax.faces.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<artifactId>vasc-frontend</artifactId>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<version>0.4.2-SNAPSHOT</version>
|
||||
</parent>
|
||||
<artifactId>vasc-frontend-web-jsf</artifactId>
|
||||
<name>vasc-frontend-web-jsf</name>
|
||||
<description>vasc-frontend-web-jsf</description>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-frontend-api</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.forwardfire.vasc</groupId>
|
||||
<artifactId>vasc-core-ejb3-client</artifactId>
|
||||
<version>${project.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax</groupId>
|
||||
<artifactId>javaee-api</artifactId>
|
||||
<version>${javaee-api.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.glassfish</groupId>
|
||||
<artifactId>javax.faces</artifactId>
|
||||
<version>${javax.faces.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import java.io.Serializable;
|
|||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import net.forwardfire.vasc.backend.VascBackendState;
|
||||
import net.forwardfire.vasc.backend.list.VascBackendListRequest;
|
||||
import net.forwardfire.vasc.core.VascController;
|
||||
import net.forwardfire.vasc.core.VascEntry;
|
||||
import net.forwardfire.vasc.core.VascEntryField;
|
||||
|
|
@ -58,7 +58,7 @@ public abstract class AbstractJSFVascFacesControllerBase {
|
|||
getVascController().getVascEntryConfigController().configVascFrontendController(getVascController(), entry);
|
||||
|
||||
// set def para
|
||||
VascBackendState state = entry.getVascFrontendController().getVascEntryState().getVascBackendState();
|
||||
VascBackendListRequest state = entry.getVascFrontendController().getVascEntryState().getVascBackendState();
|
||||
for (String key2:entry.getEntryParameterKeys()) {
|
||||
Object value = entry.getEntryParameter(key2);
|
||||
state.setDataParameter(key2, value);
|
||||
|
|
|
|||
|
|
@ -32,8 +32,8 @@ import java.util.ResourceBundle;
|
|||
import javax.naming.Context;
|
||||
import javax.naming.InitialContext;
|
||||
|
||||
import net.forwardfire.vasc.backend.VascBackend;
|
||||
import net.forwardfire.vasc.backend.VascBackendControllerLocal;
|
||||
import net.forwardfire.vasc.backend.crud.VascBackendCrud;
|
||||
import net.forwardfire.vasc.backend.proxy.VascBackendProxyEventExecutor;
|
||||
import net.forwardfire.vasc.core.VascController;
|
||||
import net.forwardfire.vasc.core.VascEntryControllerLocal;
|
||||
|
|
@ -193,7 +193,7 @@ abstract public class AbstractJSFVascFacesControllerEJB extends AbstractJSFVascF
|
|||
for (String id:entryIds) {
|
||||
VascEntryLocal ve = (VascEntryLocal)vascManager.getVascEntry(id);
|
||||
String backendId = ve.getBackendId();
|
||||
VascBackend vb = new VascServiceRemoteBackend(vascManager,backendId);
|
||||
VascBackendCrud vb = new VascServiceRemoteBackend(vascManager,backendId);
|
||||
|
||||
for (String key:ve.getEntryParameterKeys()) {
|
||||
Object value = ve.getEntryParameter(key);
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ import javax.faces.model.SelectItem;
|
|||
import javax.servlet.ServletOutputStream;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import net.forwardfire.vasc.backend.VascBackend;
|
||||
import net.forwardfire.vasc.backend.crud.VascBackendCrud;
|
||||
import net.forwardfire.vasc.core.VascEntry;
|
||||
import net.forwardfire.vasc.core.VascEntryField;
|
||||
import net.forwardfire.vasc.core.VascEntryState;
|
||||
|
|
@ -106,7 +106,7 @@ public class JSFVascEntrySupportBean implements Serializable {
|
|||
editSelectItemModels = new HashMap<String,Object>(6);
|
||||
|
||||
// cache some values
|
||||
VascBackend backend = entry.getVascFrontendController().getVascEntryState().getVascBackend();
|
||||
VascBackendCrud backend = entry.getVascFrontendController().getVascEntryState().getVascBackend();
|
||||
backendPageable = backend.isPageable();
|
||||
backendMoveable = backend.isRecordMoveable();
|
||||
backendSearchable = backend.isSearchable();
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ package net.forwardfire.vasc.frontend.web.jsf;
|
|||
import java.io.Serializable;
|
||||
|
||||
import net.forwardfire.vasc.backend.VascBackendException;
|
||||
import net.forwardfire.vasc.backend.VascEntryFieldValue;
|
||||
import net.forwardfire.vasc.backend.VascBackendAccessDataRecord;
|
||||
import net.forwardfire.vasc.core.VascEntry;
|
||||
import net.forwardfire.vasc.core.VascEntryField;
|
||||
import net.forwardfire.vasc.frontend.VascFrontendDataSelector.EntryFieldSelectType;
|
||||
|
|
@ -79,7 +79,7 @@ public class VascDataBackendBean implements Serializable {
|
|||
private Object getValue(int index) {
|
||||
try {
|
||||
VascEntryField field = getFieldIdByIndex(entry,index);
|
||||
VascEntryFieldValue value = field.getVascEntryFieldValue();
|
||||
VascBackendAccessDataRecord value = field.getVascEntryFieldValue();
|
||||
if (isRealValue()) {
|
||||
return value.getValue(field.getBackendName(), record);
|
||||
}
|
||||
|
|
@ -92,7 +92,7 @@ public class VascDataBackendBean implements Serializable {
|
|||
private void setValue(int index,Object valueObject) {
|
||||
try {
|
||||
VascEntryField field = getFieldIdByIndex(entry,index);
|
||||
VascEntryFieldValue<Serializable> value = field.getVascEntryFieldValue();
|
||||
VascBackendAccessDataRecord<Serializable> value = field.getVascEntryFieldValue();
|
||||
value.setValue(field.getBackendName(), record,(Serializable)valueObject); // TODO: rm cast
|
||||
} catch (VascBackendException e) {
|
||||
throw new RuntimeException("Could not set value on record.",e);
|
||||
|
|
|
|||
|
|
@ -35,9 +35,9 @@ import javax.faces.context.FacesContext;
|
|||
import javax.faces.convert.Converter;
|
||||
import javax.faces.convert.ConverterException;
|
||||
|
||||
import net.forwardfire.vasc.backend.select.VascBackendSelectItem;
|
||||
import net.forwardfire.vasc.core.VascEntry;
|
||||
import net.forwardfire.vasc.core.VascEntryField;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItem;
|
||||
import net.forwardfire.vasc.core.ui.VascValueModel;
|
||||
import net.forwardfire.vasc.core.VascException;
|
||||
import net.forwardfire.vasc.frontend.web.jsf.JSFVascUIComponent;
|
||||
|
|
@ -130,7 +130,7 @@ class VascConverter implements Converter,Serializable {
|
|||
if (value == null) { return null; }
|
||||
if ((value=value.trim()).length() == 0) { return null; }
|
||||
|
||||
for (VascSelectItem v:testModel.getVascItems()) {
|
||||
for (VascBackendSelectItem v:testModel.getVascItems()) {
|
||||
if (value.equals(v.getKeyValue())) {
|
||||
return v.getValue();
|
||||
}
|
||||
|
|
@ -147,7 +147,7 @@ class VascConverter implements Converter,Serializable {
|
|||
if (component == null) { throw new NullPointerException("component may not be null"); }
|
||||
if (value == null) { return ""; }
|
||||
|
||||
for (VascSelectItem v:testModel.getVascItems()) {
|
||||
for (VascBackendSelectItem v:testModel.getVascItems()) {
|
||||
if (value.equals(v.getValue())) {
|
||||
return v.getKeyValue();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,8 +31,8 @@ import java.util.ListIterator;
|
|||
|
||||
import javax.faces.model.SelectItem;
|
||||
|
||||
import net.forwardfire.vasc.backend.select.VascBackendSelectItem;
|
||||
import net.forwardfire.vasc.core.VascEntryField;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItem;
|
||||
import net.forwardfire.vasc.core.ui.VascSelectItemModel;
|
||||
import net.forwardfire.vasc.core.VascException;
|
||||
|
||||
|
|
@ -49,12 +49,12 @@ public class JSFListModel implements Serializable,List<SelectItem> {
|
|||
|
||||
private static final long serialVersionUID = -5266070864271715383L;
|
||||
private VascEntryField entryField;
|
||||
private List<VascSelectItem> items = null;
|
||||
private List<VascBackendSelectItem> items = null;
|
||||
private List<SelectItem> selectItems = null;
|
||||
private boolean refresh = true;
|
||||
|
||||
public JSFListModel() {
|
||||
items = new ArrayList<VascSelectItem>(40);
|
||||
items = new ArrayList<VascBackendSelectItem>(40);
|
||||
selectItems = new ArrayList<SelectItem>(40);
|
||||
}
|
||||
|
||||
|
|
@ -63,7 +63,7 @@ public class JSFListModel implements Serializable,List<SelectItem> {
|
|||
this.entryField=entryField;
|
||||
}
|
||||
|
||||
public List<VascSelectItem> getVascItems() {
|
||||
public List<VascBackendSelectItem> getVascItems() {
|
||||
refresh();
|
||||
return items;
|
||||
}
|
||||
|
|
@ -91,12 +91,12 @@ public class JSFListModel implements Serializable,List<SelectItem> {
|
|||
} catch (VascException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
for (VascSelectItem v:items) {
|
||||
for (VascBackendSelectItem v:items) {
|
||||
selectItems.add(convert(v));
|
||||
}
|
||||
}
|
||||
|
||||
private SelectItem convert(VascSelectItem v) {
|
||||
private SelectItem convert(VascBackendSelectItem v) {
|
||||
SelectItem si = new SelectItem();
|
||||
si.setLabel(v.getLabel());
|
||||
si.setValue(v.getValue());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue