From 277d9f3399dbb7f3b335a38d3cd6ef0fe8a56731 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Uwe=20M=C3=BCller?= Date: Wed, 19 Jul 2017 04:45:28 +0200 Subject: [PATCH] add memberAsset --- .../java/de/hsadmin/web/GenericEditorFactory.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/web/src/main/java/de/hsadmin/web/GenericEditorFactory.java b/web/src/main/java/de/hsadmin/web/GenericEditorFactory.java index af95cbc..0a0331c 100644 --- a/web/src/main/java/de/hsadmin/web/GenericEditorFactory.java +++ b/web/src/main/java/de/hsadmin/web/GenericEditorFactory.java @@ -55,6 +55,11 @@ public class GenericEditorFactory implements IEditorFactory, Serializable { return getMemberShareActionEditor(action, propertyInfo, session, whereContext); } } + if ("memberAsset".equals(module)) { + if ("action".equals(inputName)) { + return getMemberAssetActionEditor(action, propertyInfo, session, whereContext); + } + } return getEditor(action, propertyInfo); } @@ -70,6 +75,14 @@ public class GenericEditorFactory implements IEditorFactory, Serializable { field.setEnabled(isWriteAble(propertyInfo, action)); return field; } + + private IHSEditor getMemberAssetActionEditor(String action, PropertyInfo propertyInfo, HSAdminSession session, Map whereContext) { + final String[] items = new String[] { " PAYMENT", "PAYBACK", "ADOPTION", "HANDOVER", "LOSS", "CLEARING", "PRESCRIPTION" }; + final HSSelect field = new HSSelect(propertyInfo, 0, Arrays.asList(items)); + field.setWidth("100%"); + field.setEnabled(isWriteAble(propertyInfo, action)); + return field; + } private IHSEditor getEMailTargetEditor(final String action, final PropertyInfo propertyInfo, final HSAdminSession session, final Map whereContext) {