UI Knopf und das außenrum angelegt, Version erhöht
This commit is contained in:
parent
40dbb741ff
commit
66897668cc
@ -110,11 +110,20 @@
|
|||||||
<Label Grid.Column="0" Grid.Row="7" Margin="0,0,10,0" HorizontalContentAlignment="Right" Name="labelCancelled" VerticalContentAlignment="Center" FontWeight="Bold" />
|
<Label Grid.Column="0" Grid.Row="7" Margin="0,0,10,0" HorizontalContentAlignment="Right" Name="labelCancelled" VerticalContentAlignment="Center" FontWeight="Bold" />
|
||||||
<Label Grid.Column="1" Grid.Row="7" Margin="0,0,10,0" HorizontalContentAlignment="Right" Name="labelHIS" VerticalContentAlignment="Center" Content="{x:Static p:Resources.textSendToHIS}" />
|
<Label Grid.Column="1" Grid.Row="7" Margin="0,0,10,0" HorizontalContentAlignment="Right" Name="labelHIS" VerticalContentAlignment="Center" Content="{x:Static p:Resources.textSendToHIS}" />
|
||||||
<ComboBox Grid.Column="2" Grid.Row="7" Margin="2" Name="comboBoxInitialHis" VerticalContentAlignment="Center" SelectedValuePath="Key" DisplayMemberPath="Value" SelectedValue="{Binding Path=InitialHIS}" />
|
<ComboBox Grid.Column="2" Grid.Row="7" Margin="2" Name="comboBoxInitialHis" VerticalContentAlignment="Center" SelectedValuePath="Key" DisplayMemberPath="Value" SelectedValue="{Binding Path=InitialHIS}" />
|
||||||
<Button Grid.Column="3" Grid.Row="7" Margin="2" Name="buttonExcelImport" Content="{x:Static p:Resources.textExcelImport}" Click="buttonExcelImport_Click">
|
<Button Grid.Column="3" Grid.Row="7" Margin="2" Name="buttonExcelImport" Click="buttonExcelImport_Click">
|
||||||
<!-- hier könnte noch ein nettes Icon hin -->
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="{x:Static p:Resources.textExcelImport}"></TextBlock>
|
||||||
|
<Image Source="../Resources/excel.png" Margin="10,0,5,0" Height="16"/>
|
||||||
|
</StackPanel>
|
||||||
|
</Button>
|
||||||
|
<Button Grid.Column="4" Grid.Row="7" Margin="2" Name="buttonExcelExport" Click="buttonExcelExport_Click">
|
||||||
|
<StackPanel Orientation="Horizontal">
|
||||||
|
<TextBlock Text="{x:Static p:Resources.textExcelExport}"></TextBlock>
|
||||||
|
<Image Source="../Resources/excel.png" Margin="10,0,5,0" Height="16"/>
|
||||||
|
</StackPanel>
|
||||||
</Button>
|
</Button>
|
||||||
|
|
||||||
<StackPanel Orientation="Horizontal" Grid.Column="3" Grid.Row="7" Visibility="Hidden" Name="stackPanelLock">
|
<StackPanel Orientation="Horizontal" Grid.Column="5" Grid.Row="7" Visibility="Hidden" Name="stackPanelLock">
|
||||||
<Image Source="../Resources/lock.png" Margin="0,0,5,0" Height="24" />
|
<Image Source="../Resources/lock.png" Margin="0,0,5,0" Height="24" />
|
||||||
<TextBlock Name="textBlockLockUserName" VerticalAlignment="Center" />
|
<TextBlock Name="textBlockLockUserName" VerticalAlignment="Center" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|||||||
@ -754,6 +754,9 @@ namespace ENI2.DetailViewControls
|
|||||||
this.OnRequestValidate();
|
this.OnRequestValidate();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// update class fields from named excel sheet
|
||||||
|
/// </summary>
|
||||||
private void buttonExcelImport_Click(object sender, RoutedEventArgs e)
|
private void buttonExcelImport_Click(object sender, RoutedEventArgs e)
|
||||||
{
|
{
|
||||||
SelectImportClassesDialog sicd = new SelectImportClassesDialog();
|
SelectImportClassesDialog sicd = new SelectImportClassesDialog();
|
||||||
@ -789,6 +792,36 @@ namespace ENI2.DetailViewControls
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// export all classes to excel reference sheet
|
||||||
|
/// </summary>
|
||||||
|
private void buttonExcelExport_Click(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
string filename = string.Format("{0}_{1}_ref.xlsx", this.Core.Shipname, this.Core.DisplayId);
|
||||||
|
SaveFileDialog sfd = new SaveFileDialog()
|
||||||
|
{
|
||||||
|
Filter = "Excel Files|*.xls;*.xlsx",
|
||||||
|
FileName = filename
|
||||||
|
};
|
||||||
|
if(sfd.ShowDialog() ?? false)
|
||||||
|
{
|
||||||
|
Util.UIHelper.SetBusyState();
|
||||||
|
|
||||||
|
ExcelManager em = new ExcelManager();
|
||||||
|
string resultMessage = "";
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
em.Export(sfd.FileName, this.Core, this.Messages, out resultMessage);
|
||||||
|
MessageBox.Show("Exported " + sfd.FileName, "Export successful", MessageBoxButton.OK, MessageBoxImage.Information);
|
||||||
|
}
|
||||||
|
catch(Exception ex)
|
||||||
|
{
|
||||||
|
MessageBox.Show(resultMessage, "Export failed: " + ex.Message, MessageBoxButton.OK, MessageBoxImage.Error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region mouse wheel
|
#region mouse wheel
|
||||||
|
|||||||
@ -37,7 +37,7 @@
|
|||||||
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
|
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
|
||||||
<WebPage>publish.html</WebPage>
|
<WebPage>publish.html</WebPage>
|
||||||
<ApplicationRevision>0</ApplicationRevision>
|
<ApplicationRevision>0</ApplicationRevision>
|
||||||
<ApplicationVersion>6.8.1.0</ApplicationVersion>
|
<ApplicationVersion>6.9.0.0</ApplicationVersion>
|
||||||
<UseApplicationTrust>false</UseApplicationTrust>
|
<UseApplicationTrust>false</UseApplicationTrust>
|
||||||
<CreateDesktopShortcut>true</CreateDesktopShortcut>
|
<CreateDesktopShortcut>true</CreateDesktopShortcut>
|
||||||
<PublishWizardCompleted>true</PublishWizardCompleted>
|
<PublishWizardCompleted>true</PublishWizardCompleted>
|
||||||
@ -788,6 +788,7 @@
|
|||||||
<Resource Include="Resources\document_down.png" />
|
<Resource Include="Resources\document_down.png" />
|
||||||
<Resource Include="Resources\undo.png" />
|
<Resource Include="Resources\undo.png" />
|
||||||
<Resource Include="Resources\Logo.gif" />
|
<Resource Include="Resources\Logo.gif" />
|
||||||
|
<Resource Include="Resources\excel.png" />
|
||||||
<Content Include="x64\SQLite.Interop.dll">
|
<Content Include="x64\SQLite.Interop.dll">
|
||||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
|
|||||||
@ -52,6 +52,23 @@ namespace ENI2.Import
|
|||||||
_log.Error(ex);
|
_log.Error(ex);
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// TODO: ich finde man müsste den Folder zu "excel" umbenennen es ist ja nicht nur "import"..
|
||||||
|
|
||||||
|
internal void Export(string fileName, MessageCore core, List<Message> messages, out string resultMessage)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException();
|
||||||
|
|
||||||
|
// Create ExcelWriter
|
||||||
|
|
||||||
|
// Open reference Sheet
|
||||||
|
|
||||||
|
// somehow loop across all messages and derive their label names from it
|
||||||
|
|
||||||
|
// save excel
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
21
ENI2/Properties/Resources.Designer.cs
generated
21
ENI2/Properties/Resources.Designer.cs
generated
@ -370,6 +370,16 @@ namespace ENI2.Properties {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
||||||
|
/// </summary>
|
||||||
|
public static System.Drawing.Bitmap excel {
|
||||||
|
get {
|
||||||
|
object obj = ResourceManager.GetObject("excel", resourceCulture);
|
||||||
|
return ((System.Drawing.Bitmap)(obj));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
/// Looks up a localized resource of type System.Drawing.Bitmap.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@ -2092,7 +2102,16 @@ namespace ENI2.Properties {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Looks up a localized string similar to Excel Import.
|
/// Looks up a localized string similar to Excel export.
|
||||||
|
/// </summary>
|
||||||
|
public static string textExcelExport {
|
||||||
|
get {
|
||||||
|
return ResourceManager.GetString("textExcelExport", resourceCulture);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Looks up a localized string similar to Excel import.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static string textExcelImport {
|
public static string textExcelImport {
|
||||||
get {
|
get {
|
||||||
|
|||||||
@ -1739,7 +1739,7 @@
|
|||||||
<value>..\Resources\undo.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
<value>..\Resources\undo.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="textExcelImport" xml:space="preserve">
|
<data name="textExcelImport" xml:space="preserve">
|
||||||
<value>Excel Import</value>
|
<value>Excel import</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="textSelectAll" xml:space="preserve">
|
<data name="textSelectAll" xml:space="preserve">
|
||||||
<value>Select all</value>
|
<value>Select all</value>
|
||||||
@ -1753,4 +1753,10 @@
|
|||||||
<data name="Logo" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
<data name="Logo" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
<value>..\Resources\Logo.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
<value>..\Resources\Logo.gif;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="excel" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||||
|
<value>..\Resources\excel.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||||
|
</data>
|
||||||
|
<data name="textExcelExport" xml:space="preserve">
|
||||||
|
<value>Excel export</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
BIN
ENI2/Resources/excel.png
Normal file
BIN
ENI2/Resources/excel.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.5 KiB |
@ -2,6 +2,6 @@
|
|||||||
|
|
||||||
[assembly: AssemblyCompany("schick Informatik")]
|
[assembly: AssemblyCompany("schick Informatik")]
|
||||||
[assembly: AssemblyProduct("BSMD NSW interface")]
|
[assembly: AssemblyProduct("BSMD NSW interface")]
|
||||||
[assembly: AssemblyInformationalVersion("6.8.1")]
|
[assembly: AssemblyInformationalVersion("6.9.0")]
|
||||||
[assembly: AssemblyCopyright("Copyright © 2014-2021 schick Informatik")]
|
[assembly: AssemblyCopyright("Copyright © 2014-2021 schick Informatik")]
|
||||||
[assembly: AssemblyTrademark("")]
|
[assembly: AssemblyTrademark("")]
|
||||||
@ -1,4 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
|
||||||
[assembly: AssemblyVersion("6.8.1.*")]
|
[assembly: AssemblyVersion("6.9.0.*")]
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user