Browse Source

PullModelPage

pull/505/merge
Peter Forstmeier 11 years ago
parent
commit
eb4423fffc
  1. 5
      src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/ICSharpCode.Reporting.Addin.csproj
  2. 35
      src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/BaseSettingsPage.xaml.cs
  3. 17
      src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/PullModelPage.xaml
  4. 44
      src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/PullModelPage.xaml.cs
  5. 3
      src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/PushDataReport.xaml
  6. 2
      src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/ReportWizard.xaml
  7. 3
      src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/WizardPageType.cs

5
src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/ICSharpCode.Reporting.Addin.csproj

@ -150,6 +150,10 @@ @@ -150,6 +150,10 @@
<DependentUpon>BaseSettingsPage.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
<Compile Include="src\ReportWizard\Dialog\PullModelPage.xaml.cs">
<DependentUpon>PullModelPage.xaml</DependentUpon>
<SubType>Code</SubType>
</Compile>
<Compile Include="src\ReportWizard\Dialog\PushDataReport.xaml.cs">
<DependentUpon>PushDataReport.xaml</DependentUpon>
<SubType>Code</SubType>
@ -241,6 +245,7 @@ @@ -241,6 +245,7 @@
</ItemGroup>
<ItemGroup>
<Page Include="src\ReportWizard\Dialog\BaseSettingsPage.xaml" />
<Page Include="src\ReportWizard\Dialog\PullModelPage.xaml" />
<Page Include="src\ReportWizard\Dialog\PushDataReport.xaml" />
<Page Include="src\ReportWizard\Dialog\ReportWizard.xaml" />
<Page Include="src\ReportWizard\Dialog\WelcomePage.xaml" />

35
src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/BaseSettingsPage.xaml.cs

@ -47,7 +47,6 @@ namespace ICSharpCode.Reporting.Addin.ReportWizard.Dialog{ @@ -47,7 +47,6 @@ namespace ICSharpCode.Reporting.Addin.ReportWizard.Dialog{
void UpdateContext(){
Console.WriteLine("Legal at bbbb {0}",_Legal.IsChecked);
context.DataModel = (PushPullModel) _DataModel.SelectedItem;
context.ReportType = (ReportType) _ReportType.SelectedItem;
context.ReportName = this._ReportName.Text;
@ -57,17 +56,33 @@ Console.WriteLine("Legal at bbbb {0}",_Legal.IsChecked); @@ -57,17 +56,33 @@ Console.WriteLine("Legal at bbbb {0}",_Legal.IsChecked);
}
void _DataModel_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e){
void _DataModel_SelectionChanged(object sender, SelectionChangedEventArgs e){
var cbo = (ComboBox) sender;
if (((PushPullModel)cbo.SelectedItem) == PushPullModel.FormSheet) {
this.CanFinish = true;
this.CanSelectNextPage = false;
this._ReportType.SelectedItem = ReportType.FormSheet;
} else {
this._ReportType.SelectedItem = ReportType.DataReport;
this.CanFinish = false;
this.CanSelectNextPage = true;
var pushPullModel = (PushPullModel)cbo.SelectedItem;
switch (pushPullModel) {
case PushPullModel.PushData: {
this._ReportType.SelectedItem = ReportType.DataReport;
this.CanFinish = false;
this.CanSelectNextPage = true;
NextPage = new PushDataReport();
NextPage.PreviousPage = this;
break;
}
case PushPullModel.PullData: {
CanSelectNextPage = true;
NextPage = new PullModelPage();
NextPage.PreviousPage = this;
break;
}
case PushPullModel.FormSheet: {
this.CanFinish = true;
this._ReportType.SelectedItem = ReportType.FormSheet;
break;
}
}
}
}

17
src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/PullModelPage.xaml

@ -0,0 +1,17 @@ @@ -0,0 +1,17 @@
<xctk:WizardPage x:Class="ICSharpCode.Reporting.Addin.ReportWizard.Dialog.PullModelPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
xmlns:System="clr-namespace:System;assembly=mscorlib"
xmlns:sdr="clr-namespace:ICSharpCode.Reporting.Globals;assembly=ICSharpCode.Reporting"
CanSelectPreviousPage="true"
CanSelectNextPage="false"
CanCancel="true"
CanFinish="false"
PageType="Interior"
>
<Grid>
<TextBlock Text="Pull Model not available at the moment" FontSize="16"
HorizontalAlignment="Center" VerticalAlignment="Center"></TextBlock>
</Grid>
</xctk:WizardPage>

44
src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/PullModelPage.xaml.cs

@ -0,0 +1,44 @@ @@ -0,0 +1,44 @@
/*
* Created by SharpDevelop.
* User: Peter Forstmeier
* Date: 16.08.2014
* Time: 16:43
*
* To change this template use Tools | Options | Coding | Edit Standard Headers.
*/
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using Xceed.Wpf.Toolkit;
namespace ICSharpCode.Reporting.Addin.ReportWizard.Dialog
{
/// <summary>
/// Interaction logic for PullModelPage.xaml
/// </summary>
public partial class PullModelPage : WizardPage,IHasContext
{
public PullModelPage()
{
InitializeComponent();
}
#region IHasContext implementation
public ICSharpCode.Reporting.Addin.ReportWizard.ViewModels.IWizardContext Context {
get {
throw new NotImplementedException();
}
}
public WizardPageType ReportPageType {
get { return WizardPageType.PullModelPage;}
}
#endregion
}
}

3
src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/PushDataReport.xaml

@ -3,13 +3,12 @@ @@ -3,13 +3,12 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
xmlns:System="clr-namespace:System;assembly=mscorlib"
xmlns:sdr="clr-namespace:ICSharpCode.Reporting.Globals;assembly=ICSharpCode.Reporting"
Name="PushData"
Title="SharpDevelop Reporting"
Description="Welcome to Sharpdevelop Reporting Wizard"
PageType="Interior"
CanFinish="true"
CanFinish="true"
CancelButtonVisibility="Visible">
<Grid ShowGridLines="True">

2
src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/Dialog/ReportWizard.xaml

@ -16,7 +16,7 @@ @@ -16,7 +16,7 @@
<local:BaseSettingsPage></local:BaseSettingsPage>
<local:PushDataReport></local:PushDataReport>
<!-- <local:PushDataReport></local:PushDataReport>-->
<!--<xctk:WizardPage PageType="Interior"
Title="dritte Seite"

3
src/AddIns/Misc/Reporting/ICSharpCode.Reporting.Addin/src/ReportWizard/WizardPageType.cs

@ -15,6 +15,7 @@ namespace ICSharpCode.Reporting.Addin.ReportWizard @@ -15,6 +15,7 @@ namespace ICSharpCode.Reporting.Addin.ReportWizard
/// </summary>
public enum WizardPageType {
BaseSettingsPage,
PushModelPage
PushModelPage,
PullModelPage
}
}

Loading…
Cancel
Save