Skip to content

Commit

Permalink
page for creation of new report..fixed saving form reprot type via de…
Browse files Browse the repository at this point in the history
…bug pages..
  • Loading branch information
katkav committed Apr 6, 2015
1 parent 495a58c commit 963dcae
Show file tree
Hide file tree
Showing 29 changed files with 898 additions and 350 deletions.
Expand Up @@ -25,6 +25,7 @@
import com.evolveum.midpoint.web.page.admin.configuration.*;
import com.evolveum.midpoint.web.page.admin.home.PageDashboard;
import com.evolveum.midpoint.web.page.admin.reports.PageCreatedReports;
import com.evolveum.midpoint.web.page.admin.reports.PageNewReport;
import com.evolveum.midpoint.web.page.admin.reports.PageReports;
import com.evolveum.midpoint.web.page.admin.resources.PageResourceEdit;
import com.evolveum.midpoint.web.page.admin.resources.PageResourceWizard;
Expand Down Expand Up @@ -151,6 +152,7 @@ private MenuBarItem createResourcesItems() {

private MenuBarItem createReportsItems() {
MenuBarItem reports = new MenuBarItem(createStringResource("PageAdmin.menu.top.reports"), null);
reports.addMenuItem(new MenuItem(createStringResource("PageAdmin.menu.top.reports.new"), PageNewReport.class));
reports.addMenuItem(new MenuItem(createStringResource("PageAdmin.menu.top.reports.list"), PageReports.class));
reports.addMenuItem(new MenuItem(createStringResource("PageAdmin.menu.top.reports.created"), PageCreatedReports.class));

Expand Down
Expand Up @@ -101,6 +101,7 @@ PageAdmin.menu.top.serverTasks=Server tasks
PageAdmin.menu.top.serverTasks.list=List tasks
PageAdmin.menu.top.serverTasks.new=New task
PageAdmin.menu.top.reports=Reports
PageAdmin.menu.top.reports.new= New report
PageAdmin.menu.top.reports.list=Reports
PageAdmin.menu.top.reports.created=Created reports
PageAdmin.menu.top.configuration=Configuration
Expand Down
Expand Up @@ -303,9 +303,9 @@ public void savePerformed(AjaxRequestTarget target) {
}

//quick fix for now (MID-1910), maybe it should be somewhere in model..
if (isReport(oldObject)){
ReportTypeUtil.applyConfigurationDefinition((PrismObject)newObject, delta, getPrismContext());
}
// if (isReport(oldObject)){
// ReportTypeUtil.applyConfigurationDefinition((PrismObject)newObject, delta, getPrismContext());
// }

Collection<ObjectDelta<? extends ObjectType>> deltas = (Collection) MiscUtil.createCollection(delta);
ModelExecuteOptions options = new ModelExecuteOptions();
Expand Down
@@ -0,0 +1,64 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright (c) 2010-2013 Evolveum
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
<body>
<wicket:extend>
<form class="form-horizontal" wicket:id="mainForm">

<div class="form-group">
<label class="col-lg-2 control-label"><wicket:message key="PageNewReport.getObjectsFrom"/></label>

<div class="col-lg-2">
<div wicket:id="importRadioGroup">
<div class="radio">
<label>
<input wicket:id="fileRadio" type="radio">
<wicket:message key="PageNewReport.file"/>
</label>
</div>
<div class="radio">
<label>
<input wicket:id="xmlRadio" type="radio">
<wicket:message key="PageNewReport.embeddedEditor"/>
</label>
</div>
</div>
</div>
</div>

<div class="form-group" wicket:id="input">
<div class="col-lg-12" wicket:id="inputAce">
<textarea wicket:id="aceEditor"></textarea>
</div>

<label class="col-lg-2 control-label" wicket:id="inputFileLabel"></label>
<div class="col-lg-2" wicket:id="inputFile">
<input wicket:id="fileInput" type="file"/>

<p class="help-block"><wicket:message key="PageNewReport.message.help"/></p>
</div>
</div>

<div class="main-button-bar" wicket:id="buttonBar">
<a class="btn btn-primary" wicket:id="importFileButton"/>
<a class="btn btn-primary" wicket:id="importXmlButton"/>
</div>
</form>
</wicket:extend>
</body>
</html>

0 comments on commit 963dcae

Please sign in to comment.