mirror of
https://dev.azure.com/TeilRad/sharee.bike%20App/_git/Code
synced 2024-11-05 02:26:29 +01:00
233 lines
No EOL
12 KiB
XML
233 lines
No EOL
12 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<ViewCell xmlns="http://xamarin.com/schemas/2014/forms"
|
|
xmlns:conv="clr-namespace:TINK.View"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
|
xmlns:d="http://xamarin.com/schemas/2014/forms/design"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:resources="clr-namespace:TINK.MultilingualResources;assembly=TINKLib"
|
|
xmlns:sharedGui="clr-namespace:ShareeSharedGuiLib.View"
|
|
mc:Ignorable="d"
|
|
x:Class="TINK.View.Bike.ILockItBike">
|
|
<ContentView>
|
|
<ContentView.Resources>
|
|
<conv:StringNotNullOrEmptyToVisibleConverter x:Key="Label_Converter"/>
|
|
</ContentView.Resources>
|
|
<StackLayout
|
|
Padding="10">
|
|
<!-- Name of the bike -->
|
|
<Label
|
|
FontAttributes="Bold"
|
|
FontSize="Large"
|
|
HorizontalTextAlignment="Center"
|
|
Text="{Binding Name}"/>
|
|
<!-- Id of the bike -->
|
|
<Label
|
|
FontAttributes="Bold"
|
|
HorizontalTextAlignment="Center"
|
|
IsVisible="{Binding DisplayId, Converter={StaticResource Label_Converter}}"
|
|
Text="{Binding DisplayId}"/>
|
|
<!-- Battery level -->
|
|
<!--<sharedGui:BarLevelView
|
|
Current="{Binding CurrentChargeBars}"
|
|
Maximum="{Binding MaxChargeBars}"
|
|
IsVisible="{Binding IsBatteryChargeVisible}"/>-->
|
|
<sharedGui:BarLevelView
|
|
Current="{Binding CurrentChargeBars}"
|
|
Maximum="{Binding MaxChargeBars}"
|
|
IsVisible="False"/>
|
|
<!-- Rental state -->
|
|
<Label
|
|
Text="{Binding StateText}"
|
|
TextColor="{Binding StateColor}"/>
|
|
<Label
|
|
Text="{Binding ErrorText}"
|
|
IsVisible="{Binding ErrorText, Converter={StaticResource Label_Converter}}"
|
|
TextColor="Red"/>
|
|
<!-- Button for Reserve / End Reservation / Open / Close & End -->
|
|
<Button
|
|
Text="{Binding ButtonText}"
|
|
IsVisible="{Binding IsButtonVisible}"
|
|
IsEnabled="{Binding IsIdle}"
|
|
Command="{Binding OnButtonClicked}"/>
|
|
<!-- Button for Find Lock / Open & Rent / Close -->
|
|
<Button
|
|
Text="{Binding LockitButtonText}"
|
|
IsVisible="{Binding IsLockitButtonVisible}"
|
|
IsEnabled="{Binding IsIdle}"
|
|
Command="{Binding OnLockitButtonClicked}"/>
|
|
<!--Possible SecondaryButton Style-->
|
|
<!--<Button
|
|
Style="{StaticResource SecondaryButton}"
|
|
Text="{Binding LockitButtonText}"
|
|
IsVisible="{Binding IsLockitButtonVisible}"
|
|
IsEnabled="{Binding IsIdle}"
|
|
Command="{Binding OnLockitButtonClicked}"/>-->
|
|
<!-- Copri Lock Label -->
|
|
<Label
|
|
Text="{x:Static resources:AppResources.StatusTextCopriLock}"
|
|
FontSize="Small"
|
|
IsVisible="{Binding IsBikeWithCopriLock}"/>
|
|
<!-- Rental description (tarif name, options and rental info -->
|
|
<Grid
|
|
RowSpacing="0"
|
|
IsVisible="{Binding TariffDescription.Header, Converter={StaticResource Label_Converter}}">
|
|
<Grid.RowDefinitions>
|
|
<!-- start tarif- entries -->
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<!-- start rental info -->
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<!-- Operator AGB -->
|
|
<RowDefinition Height="Auto" />
|
|
</Grid.RowDefinitions>
|
|
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="*" />
|
|
</Grid.ColumnDefinitions>
|
|
<!-- start tarif- entries (should be a CollectionView) -->
|
|
<Label
|
|
Text= "{x:Static resources:AppResources.MessageBikesManagementTariffDescriptionTariffHeader}"
|
|
IsVisible="{Binding TariffDescription.Header, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="0"
|
|
FontAttributes="Bold"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.Header}"
|
|
IsVisible="{Binding TariffDescription.Header, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="0"
|
|
Grid.Column="1"
|
|
FontAttributes="Bold"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry1.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry1.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="1"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry1.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry1.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="1"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry2.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry2.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="2"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry2.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry2.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="2"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry3.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry3.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="3"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry3.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry3.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="3"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry4.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry4.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="4"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry4.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry4.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="4"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry5.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry5.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="5"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry5.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry5.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="5"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry6.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry6.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="6"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry6.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry6.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="6"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry7.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry7.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="7"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry7.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry7.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="7"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry8.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry8.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="8"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry8.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry8.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="8"
|
|
Grid.Column="1"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.TarifEntry9.Description}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry9.Description, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="9"/>
|
|
<Label
|
|
Text="{Binding TariffDescription.TarifEntry9.Value}"
|
|
IsVisible="{Binding TariffDescription.TarifEntry9.Value, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="9"
|
|
Grid.Column="1"/>
|
|
<!-- start tarif- entries (should be a CollectionView) -->
|
|
<Label
|
|
Text= "{Binding TariffDescription.InfoEntry1}"
|
|
IsVisible="{Binding TariffDescription.InfoEntry1, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="10"
|
|
Grid.ColumnSpan="2"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.InfoEntry2}"
|
|
IsVisible="{Binding TariffDescription.InfoEntry2, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="11"
|
|
Grid.ColumnSpan="2"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.InfoEntry3}"
|
|
IsVisible="{Binding TariffDescription.InfoEntry3, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="12"
|
|
Grid.ColumnSpan="2"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.InfoEntry4}"
|
|
IsVisible="{Binding TariffDescription.InfoEntry4, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="13"
|
|
Grid.ColumnSpan="2"/>
|
|
<Label
|
|
Text= "{Binding TariffDescription.InfoEntry5}"
|
|
IsVisible="{Binding TariffDescription.InfoEntry5, Converter={StaticResource Label_Converter}}"
|
|
Grid.Row="14"
|
|
Grid.ColumnSpan="2"/>
|
|
<!-- AGB entry -->
|
|
<Label
|
|
TextType="Html"
|
|
Text="{Binding TariffDescription.OperatorAgb}"
|
|
IsVisible="{Binding TariffDescription.OperatorAgb, Converter={StaticResource Label_Converter}}"
|
|
Grid.ColumnSpan="2"
|
|
Grid.Row="15">
|
|
<Label.GestureRecognizers>
|
|
<TapGestureRecognizer Command="{Binding ShowAgbTappedCommand}"/>
|
|
</Label.GestureRecognizers>
|
|
</Label>
|
|
</Grid>
|
|
</StackLayout>
|
|
</ContentView>
|
|
</ViewCell> |