1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202
|
<UserControl x:Class="WpfERP.View.CommandeFournisseurView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:View="clr-namespace:WpfERP.View;assembly="
xmlns:ViewModel="clr-namespace:ViewModel;assembly=ViewModel"
mc:Ignorable="d"
d:DesignHeight="800" d:DesignWidth="1000"
xmlns:ig="http://schemas.infragistics.com/xaml"
xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
MinHeight="400" MinWidth="800"
MaxHeight="800" MaxWidth="1000">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="420"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto"/>
<RowDefinition/>
</Grid.RowDefinitions>
<Grid Grid.Column="0" Grid.Row="0" Margin="5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="100"/>
<ColumnDefinition Width="300"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="*"/>
<RowDefinition Height="auto"/>
</Grid.RowDefinitions>
<TextBlock Grid.Column="0" Grid.Row="0" Text="N° de Cde" />
<TextBox Grid.Column="1" Grid.Row="0" Text="{Binding CommandeFournisseur.NumeroCommande}" />
<TextBlock Grid.Column="0" Grid.Row="1" Text="Demandeur" />
<TextBox Grid.Column="1" Grid.Row="1" Text="{Binding CommandeFournisseur.Personne.Nom}" />
<TextBlock Grid.Column="0" Grid.Row="2" Text="Livraison" />
<TextBox Grid.Column="1" Grid.Row="2" Text="{Binding CommandeFournisseur.Etablissement.Nom}" />
<CheckBox Grid.Column="0" Grid.Row="4" Grid.ColumnSpan="2" IsChecked="{Binding CommandeFournisseur.RegleParDemandeur}" Content="Réglée par le Demandeur"/>
<Grid Grid.Column="1" Grid.Row="4" HorizontalAlignment="Right" Margin="70 0 0 0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="70"/>
<ColumnDefinition />
</Grid.ColumnDefinitions>
<TextBlock Grid.Column="0" Text="Monnaie" HorizontalAlignment="Left"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding ListeDevise}"
SelectedValue="{Binding CommandeFournisseur.Devise.ID}"
SelectedValuePath="ID" HorizontalAlignment="Right" Width="150"
>
<ComboBox.ItemTemplate>
<DataTemplate>
<TextBlock Background="Transparent">
<TextBlock.Text>
<MultiBinding StringFormat="{}{0} - {1}">
<Binding Path="Symbole" />
<Binding Path="Libelle"/>
</MultiBinding>
</TextBlock.Text>
</TextBlock>
</DataTemplate>
</ComboBox.ItemTemplate>
</ComboBox>
</Grid>
</Grid>
<ig:XamGrid Grid.Column="0" Grid.Row="1" Grid.ColumnSpan="2" x:Name="dataGrid"
ItemsSource="{Binding CommandeFournisseurLignes}"
AutoGenerateColumns="false"
DeleteKeyAction="DeleteRowOfActiveCell">
<ig:XamGrid.Columns>
<ig:TextColumn Key="Affaire.ID"/>
<ig:TextColumn Key="Description"/>
<ig:TextColumn Key="PrixUnitaire"/>
<ig:TextColumn Key="Quantite"/>
<ig:TextColumn Key="Total_HT"/>
<ig:TemplateColumn HeaderText="Supprimer" Key="CommandeFournisseur" HorizontalContentAlignment="Center">
<ig:TemplateColumn.ItemTemplate>
<DataTemplate>
<Button Template="{StaticResource commandsItemTemplate}"/>
</DataTemplate>
</ig:TemplateColumn.ItemTemplate>
</ig:TemplateColumn>
</ig:XamGrid.Columns>
<ig:XamGrid.SelectionSettings>
<ig:SelectionSettings CellClickAction="SelectRow" CellSelection="Single" RowSelection="Single"></ig:SelectionSettings>
</ig:XamGrid.SelectionSettings>
<ig:XamGrid.RowSelectorSettings>
<ig:RowSelectorSettings Visibility="Hidden"/>
</ig:XamGrid.RowSelectorSettings>
<!--Edition de ligne via double click-->
<ig:XamGrid.EditingSettings>
<ig:EditingSettings AllowEditing="Row" IsMouseActionEditingEnabled="DoubleClick"
IsEnterKeyEditingEnabled="True" IsF2EditingEnabled="True"
IsOnCellActiveEditingEnabled="False" />
</ig:XamGrid.EditingSettings>
<!--Ajout de ligne via double click-->
<ig:XamGrid.AddNewRowSettings>
<ig:AddNewRowSettings AllowAddNewRow="Top"
IsEnterKeyEditingEnabled="True"
IsF2EditingEnabled="False"
IsMouseActionEditingEnabled="DoubleClick"
IsOnCellActiveEditingEnabled="True"/>
</ig:XamGrid.AddNewRowSettings>
</ig:XamGrid>
<Grid Grid.Column="1" Grid.Row="0" Margin="5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="100"/>
<ColumnDefinition Width="100"/>
<ColumnDefinition Width="120"/>
<ColumnDefinition Width="100"/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="auto" />
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<TextBlock Grid.Column="0" Grid.ColumnSpan="4" Grid.Row="0" Text="Informations Fournisseur" TextAlignment="Center" Margin="0 5"/>
<Label Grid.Column="0" Grid.Row="1">Nom :</Label>
<!--<TextBlock Grid.Column="0" Grid.Row="1" Text="Nom" />-->
<TextBox Grid.Column="1" Grid.Row="1" Text="123456" />
<ComboBox Grid.Column="1" Grid.Row="1"
ItemsSource="{Binding ListeFournisseur}"
SelectedValue="{Binding CommandeFournisseur.IDFournisseur}"
DisplayMemberPath="Nom"
SelectedValuePath="ID"
/>
<Label Grid.Row="1" Grid.Column="2">Autre Fournisseur :</Label>
<!--<TextBlock Grid.Column="2" Grid.Row="1" Text="Autre Fournisseur" />-->
<TextBox Grid.Column="3" Grid.Row="1" Text="" />
<Label Grid.Column="0" Grid.Row="2">N° de Devis</Label>
<!--<TextBlock Grid.Column="0" Grid.Row="2" Text="N° de Devis" />-->
<TextBox Grid.Column="1" Grid.Row="2" Text="{Binding CommandeFournisseur.NumeroDevis}" />
<Label Grid.Column="2" Grid.Row="2">Contact : </Label>
<!--<TextBlock Grid.Column="2" Grid.Row="2" Text="Contact" />-->
<TextBox Grid.Column="3" Grid.Row="2" Text="" />
<Label Grid.Column="0" Grid.Row="3">Téléphone : </Label>
<!--<TextBlock Grid.Column="0" Grid.Row="3" Text="Téléphone" />-->
<TextBox Grid.Column="1" Grid.Row="3" Text="" />
<Label Grid.Column="2" Grid.Row="3">Fax :</Label>
<!--<TextBlock Grid.Column="2" Grid.Row="3" Text="Fax" />-->
<TextBox Grid.Column="3" Grid.Row="3" Text="" />
<Label Grid.Column="0" Grid.Row="4">Délai :</Label>
<!--<TextBlock Grid.Column="0" Grid.Row="4" Text="Délai" />-->
<TextBox Grid.Column="1" Grid.Row="4" Text="" />
<Label Grid.Column="2" Grid.Row="4">Règlement :</Label>
<!--<TextBlock Grid.Column="2" Grid.Row="4" Text="Règlement" />-->
<TextBox Grid.Column="3" Grid.Row="4" Text="" />
<Label Grid.Column="0" Grid.Row="5">Commentaire :</Label>
<!--<TextBlock Grid.Column="0" Grid.Row="5" Text="Commentaire" />-->
<TextBox Grid.Column="1" Grid.ColumnSpan="3" Grid.Row="5" Text="" />
</Grid>
</Grid>
</UserControl> |
Partager