Eigenes Logo oben links
This commit is contained in:
@@ -649,6 +649,11 @@ namespace BeWo
|
||||
AppSettings.ShowInfoButtonInCalender = showInfoButtonInCalender;
|
||||
|
||||
BS.Shared.Settings.ApplicationSettings.SupportConceptExpirationLimitInMonths = AppSettings.HilfeplanAuslaufAuswahl;
|
||||
|
||||
if(MainControl is object)
|
||||
{
|
||||
MainControl.UpdateMandator();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -61,9 +61,9 @@
|
||||
HorizontalAlignment="Stretch"
|
||||
Grid.IsSharedSizeScope="True">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto" />
|
||||
<ColumnDefinition Width="auto" />
|
||||
<ColumnDefinition Width="*" />
|
||||
<ColumnDefinition Width="150" />
|
||||
<ColumnDefinition x:Name="column2" Width="150" />
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
@@ -71,8 +71,9 @@
|
||||
</Grid.RowDefinitions>
|
||||
<!--<Frame x:Name="chatFrame" Grid.Column="2" Grid.Row="0" />-->
|
||||
<TextBlock
|
||||
x:Name="txt_logo"
|
||||
Width="Auto"
|
||||
Margin="5,2,0,0"
|
||||
Margin="5,2,5,2"
|
||||
HorizontalAlignment="Center">
|
||||
<Hyperlink
|
||||
Foreground="Transparent"
|
||||
@@ -99,7 +100,35 @@
|
||||
</InlineUIContainer>
|
||||
</Hyperlink>
|
||||
</TextBlock>
|
||||
|
||||
<TextBlock
|
||||
x:Name="txt_logo2"
|
||||
Width="Auto"
|
||||
Margin="5,2,5,2"
|
||||
HorizontalAlignment="Center">
|
||||
<Hyperlink
|
||||
x:Name="hyperlink_2"
|
||||
Foreground="Transparent"
|
||||
RequestNavigate="Hyperlink_OnRequestNavigate"
|
||||
TargetName="newWindow">
|
||||
<InlineUIContainer>
|
||||
<Image
|
||||
x:Name="image2"
|
||||
Width="130"
|
||||
HorizontalAlignment="Left"
|
||||
RenderTransformOrigin="0.5,0.5"
|
||||
Style="{StaticResource toolbarImageStyle}">
|
||||
<Image.RenderTransform>
|
||||
<TransformGroup>
|
||||
<ScaleTransform ScaleX="1" ScaleY="1" />
|
||||
<SkewTransform AngleX="0" AngleY="0" />
|
||||
<RotateTransform Angle="0" />
|
||||
<TranslateTransform X="0" Y="0" />
|
||||
</TransformGroup>
|
||||
</Image.RenderTransform>
|
||||
</Image>
|
||||
</InlineUIContainer>
|
||||
</Hyperlink>
|
||||
</TextBlock>
|
||||
<!--<TextBlock HorizontalAlignment="Right" Width="Auto" Margin="0,2,5,0" Grid.Column="2">
|
||||
<Hyperlink NavigateUri="http://www.bewoplaner.de" TargetName="newWindow" Foreground="Transparent" RequestNavigate="Hyperlink_OnRequestNavigate">
|
||||
<InlineUIContainer>
|
||||
|
||||
@@ -27,6 +27,7 @@ using BeWo.View.Navigation;
|
||||
using BeWo.ViewModel;
|
||||
|
||||
using BS.Shared;
|
||||
using BS.Shared.Core;
|
||||
using BS.Shared.DataContracts;
|
||||
using BS.Shared.Extensions;
|
||||
using BS.Shared.Translation;
|
||||
@@ -168,6 +169,8 @@ namespace BeWo
|
||||
#if DEBUG
|
||||
//DebugHelperViewButton.Visibility = Visibility.Visible;
|
||||
#endif
|
||||
|
||||
UpdateMandator();
|
||||
}
|
||||
|
||||
public List<ModalViewWindow> OpenedModalViewWindows { get; set; }
|
||||
@@ -787,6 +790,42 @@ namespace BeWo
|
||||
}, (s, e) => e.CanExecute = _CurrentDetailView != null));
|
||||
}
|
||||
|
||||
internal void UpdateMandator()
|
||||
{
|
||||
if (BeWoApp.Mandator is null)
|
||||
return;
|
||||
|
||||
var url = BeWoApp.Mandator.Website.ToNullIfEmpty();
|
||||
|
||||
var haslogo = BeWoApp.Mandator.Logo?.Original is object;
|
||||
|
||||
if (haslogo)
|
||||
{
|
||||
image2.Source = Utils.CreateBitmapImageFromByteArray(BeWoApp.Mandator.Logo.Original);
|
||||
|
||||
Grid.SetColumn(txt_logo, 2);
|
||||
txt_logo2.Visibility = Visibility.Visible;
|
||||
|
||||
if(Uri.TryCreate(url, UriKind.RelativeOrAbsolute, out Uri res))
|
||||
{
|
||||
hyperlink_2.NavigateUri = res;
|
||||
}
|
||||
else
|
||||
{
|
||||
hyperlink_2.NavigateUri = null;
|
||||
}
|
||||
|
||||
column2.Width = new GridLength(1, GridUnitType.Auto);
|
||||
}
|
||||
else
|
||||
{
|
||||
Grid.SetColumn(txt_logo, 0);
|
||||
txt_logo2.Visibility = Visibility.Collapsed;
|
||||
|
||||
column2.Width = new GridLength(150);
|
||||
}
|
||||
}
|
||||
|
||||
private void NavigateToParentView(BeWoView beWoView)
|
||||
{
|
||||
if (beWoView is CustomerNavigationView && !_Views.ContainsKey(UIContext.Customer))
|
||||
@@ -1192,7 +1231,13 @@ namespace BeWo
|
||||
private void Hyperlink_OnRequestNavigate(object sender, RequestNavigateEventArgs e)
|
||||
{
|
||||
// Hier Token anfordern; Hier nicht notwendig -> Link auf www.beyondsoft.de
|
||||
Process.Start(new ProcessStartInfo((sender as Hyperlink).NavigateUri.ToString()));
|
||||
|
||||
var url = (sender as Hyperlink).NavigateUri.ToString();
|
||||
|
||||
if (string.IsNullOrWhiteSpace(url))
|
||||
return;
|
||||
|
||||
Process.Start(new ProcessStartInfo(url));
|
||||
}
|
||||
|
||||
private void button_Support_Click(object sender, RoutedEventArgs e)
|
||||
@@ -1800,5 +1845,5 @@ namespace BeWo
|
||||
NavigateTo(GetViewForUIContext(UIContext.Scheduling));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -14,8 +14,6 @@ namespace BeWo.ViewModel
|
||||
private byte[] _Original;
|
||||
private byte[] _MediumThumbnail;
|
||||
private byte[] _SmallThumbnail;
|
||||
private BitmapImage _BitmapImage;
|
||||
private ImageSource _ImageSource;
|
||||
|
||||
public ImageVM() : this(new ImageDC())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user