Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rewrite jasper report from initial-objects to new object collection r…
…eports
- Loading branch information
Showing
32 changed files
with
2,876 additions
and
1,767 deletions.
There are no files selected for viewing
72 changes: 72 additions & 0 deletions
72
.../java/com/evolveum/midpoint/gui/impl/factory/panel/AutoCompleteReferencePanelFactory.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
/* | ||
* Copyright (C) 2010-2020 Evolveum and contributors | ||
* | ||
* This work is dual-licensed under the Apache License 2.0 | ||
* and European Union Public License. See LICENSE file for details. | ||
*/ | ||
package com.evolveum.midpoint.gui.impl.factory.panel; | ||
|
||
import com.evolveum.midpoint.gui.api.component.autocomplete.AutoCompleteReferenceRenderer; | ||
import com.evolveum.midpoint.gui.api.factory.GuiComponentFactory; | ||
import com.evolveum.midpoint.gui.api.prism.wrapper.ItemWrapper; | ||
import com.evolveum.midpoint.gui.api.prism.wrapper.PrismReferenceWrapper; | ||
import com.evolveum.midpoint.gui.api.registry.GuiComponentRegistry; | ||
import com.evolveum.midpoint.gui.api.util.WebComponentUtil; | ||
import com.evolveum.midpoint.gui.impl.prism.wrapper.PrismReferenceValueWrapperImpl; | ||
import com.evolveum.midpoint.report.api.ReportConstants; | ||
import com.evolveum.midpoint.util.QNameUtil; | ||
import com.evolveum.midpoint.util.exception.SchemaException; | ||
import com.evolveum.midpoint.util.logging.Trace; | ||
import com.evolveum.midpoint.util.logging.TraceManager; | ||
import com.evolveum.midpoint.web.component.data.LinkedReferencePanel; | ||
import com.evolveum.midpoint.web.component.search.ReferenceAutocomplete; | ||
import com.evolveum.midpoint.web.component.search.ReferenceValueSearchPopupPanel; | ||
import com.evolveum.midpoint.xml.ns._public.common.common_3.CaseType; | ||
import com.evolveum.midpoint.xml.ns._public.common.common_3.ObjectReferenceType; | ||
|
||
import com.evolveum.midpoint.xml.ns._public.common.common_3.ObjectType; | ||
|
||
import org.apache.wicket.behavior.AttributeAppender; | ||
import org.apache.wicket.model.Model; | ||
import org.springframework.beans.factory.annotation.Autowired; | ||
import org.springframework.stereotype.Component; | ||
|
||
import javax.annotation.PostConstruct; | ||
|
||
/** | ||
* @author lskublik | ||
*/ | ||
@Component | ||
public class AutoCompleteReferencePanelFactory | ||
implements GuiComponentFactory<PrismReferencePanelContext<ObjectReferenceType>> { | ||
|
||
private static final Trace LOGGER = TraceManager.getTrace(AutoCompleteReferencePanelFactory.class); | ||
|
||
@Autowired private GuiComponentRegistry registry; | ||
|
||
@PostConstruct | ||
public void register() { | ||
registry.addToRegistry(this); | ||
} | ||
|
||
@Override | ||
public Integer getOrder() { | ||
return 100; | ||
} | ||
|
||
@Override | ||
public <IW extends ItemWrapper<?, ?>> boolean match(IW wrapper) { | ||
return QNameUtil.match(ObjectReferenceType.COMPLEX_TYPE, wrapper.getTypeName()) && | ||
ReportConstants.NS_EXTENSION.equals(wrapper.getNamespace()); | ||
} | ||
|
||
@Override | ||
public org.apache.wicket.Component createPanel(PrismReferencePanelContext<ObjectReferenceType> panelCtx) { | ||
ReferenceAutocomplete panel = new ReferenceAutocomplete(panelCtx.getComponentId(), panelCtx.getRealValueModel(), | ||
new AutoCompleteReferenceRenderer(), | ||
panelCtx.getPageBase()); | ||
panel.setOutputMarkupId(true); | ||
panel.add(AttributeAppender.append("style", "padding-top:5px")); //ugly hack to be aligned with prism-property-label | ||
return panel; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 0 additions & 21 deletions
21
gui/admin-gui/src/main/resources/initial-objects/080-report-audit.xml
This file was deleted.
Oops, something went wrong.
25 changes: 0 additions & 25 deletions
25
gui/admin-gui/src/main/resources/initial-objects/090-report-audit-jasper.xml
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.