Billing/Billing.Shared/Views/AddAccountPage.xaml
2022-03-07 21:31:27 +08:00

62 lines
3.3 KiB
XML

<?xml version="1.0" encoding="utf-8" ?>
<ui:BillingPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:r="clr-namespace:Billing.Languages"
xmlns:ui="clr-namespace:Billing.UI"
xmlns:v="clr-namespace:Billing.Views"
x:Class="Billing.Views.AddAccountPage"
x:Name="addAccountPage"
x:DataType="v:AddAccountPage"
BindingContext="{x:Reference addAccountPage}">
<ContentPage.Resources>
<ui:AccountCategoryConverter x:Key="categoryConverter"/>
<ui:IconConverter x:Key="iconConverter"/>
</ContentPage.Resources>
<ContentPage.ToolbarItems>
<ToolbarItem Order="Primary" IconImageSource="check.png" Command="{Binding CheckAccount}"/>
</ContentPage.ToolbarItems>
<ContentPage.Content>
<TableView Intent="Settings" HasUnevenRows="True">
<TableSection Title=" ">
<ui:OptionEditorCell x:Name="editorName" Height="120" Icon="pencil.png"
FontSize="20" Keyboard="Text"
Title="{r:Text AccountName}"
Text="{Binding AccountName, Mode=TwoWay}"
Placeholder="{r:Text AccountNamePlaceholder}"/>
<ui:OptionImageCell Height="44" Icon="face.png"
Title="{r:Text Icon}"
ImageSource="{Binding AccountIcon, Converter={StaticResource iconConverter}}"
TintColor="{DynamicResource PrimaryColor}"
Command="{Binding SelectIcon}"/>
<ui:OptionSelectCell Height="44" Icon="project.png"
Title="{r:Text Category}"
Detail="{Binding Category, Converter={StaticResource categoryConverter}}"
Command="{Binding SelectCategory}"/>
</TableSection>
<TableSection>
<TableSection.Title>
<OnPlatform x:TypeArguments="x:String" Android=" "/>
</TableSection.Title>
<ui:OptionEntryCell Height="44" Icon="sackdollar.png" Keyboard="Numeric"
Title="{r:Text Balance}"
Text="{Binding Initial, Mode=TwoWay}"
Placeholder="{r:Text BalancePlaceholder}"/>
<ui:OptionTextCell Height="44" Icon="yuan.png"
Title="{r:Text Currency}"
Detail="{r:Text CNY}"/>
</TableSection>
<TableSection>
<TableSection.Title>
<OnPlatform x:TypeArguments="x:String" Android=" "/>
</TableSection.Title>
<ui:OptionEditorCell Height="120" Icon="note.png" Keyboard="Plain"
Title="{r:Text Memo}"
Text="{Binding Memo, Mode=TwoWay}"
Placeholder="{r:Text MemoPlaceholder}"/>
</TableSection>
</TableView>
</ContentPage.Content>
</ui:BillingPage>