프로젝트

일반

사용자정보

통계
| 브랜치(Branch): | 개정판:

markus / ConvertService / ServiceBase / Markus.Service.StationController / Views / DataBaseView.xaml @ 3bde451b

이력 | 보기 | 이력해설 | 다운로드 (22.2 KB)

1
<UserControl
2
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
3
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
4
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
5
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
6
             xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
7
             xmlns:controls="clr-namespace:Markus.Service.StationController.Controls"
8
             xmlns:VM="clr-namespace:Markus.Service.StationController.ViewModel"
9
             xmlns:Data="clr-namespace:Markus.Service.StationController.Data"
10
             xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
11
             xmlns:local="clr-namespace:Markus.Service.StationController.Views" x:Class="Markus.Service.StationController.Views.DataBaseView"
12
             mc:Ignorable="d"  Background="White" DataContext="{DynamicResource DataBaseItemsModel}" 
13
    d:DesignHeight="450" d:DesignWidth="1000">
14
    <UserControl.Resources>
15
        <Style TargetType="telerik:GridViewCell" x:Key="StretchCellStyle">
16
            <Setter Property="Margin" Value="0"/>
17
            <Setter Property="Padding" Value="0"/>
18
            <Setter Property="VerticalContentAlignment" Value="Stretch"/>
19
            <Setter Property="HorizontalContentAlignment" Value="Stretch"/>
20
        </Style>
21
        <Style TargetType="{x:Type telerik:GridViewHeaderCell}">
22
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
23
            <Setter Property="Background" Value="Gray"/>
24
        </Style>
25
        <Style TargetType="{x:Type telerik:GridViewCell}">
26
            <Setter Property="HorizontalContentAlignment" Value="Center"/>
27
        </Style>
28
        <Style TargetType="{x:Type controls:RowIndexColumn}">
29
            <Setter Property="TextAlignment" Value="Center"/>
30
        </Style>
31
        <VM:DataBaseItemsModel x:Key="DataBaseItemsModel"/>
32
        <DataTemplate x:Key="RowDetailsTemplate">
33
            <local:DataBaseViewInfo />
34
        </DataTemplate>
35
    </UserControl.Resources>
36
    <!--<UserControl.DataContext>
37
        <VM:DataBaseItemsModel/>
38
    </UserControl.DataContext>-->
39
    <i:Interaction.Triggers>
40
        <i:EventTrigger  EventName="Loaded">
41
            <i:InvokeCommandAction Command="{Binding LoadedCommand}"/>
42
        </i:EventTrigger>
43
        <i:EventTrigger  EventName="Unloaded">
44
            <i:InvokeCommandAction Command="{Binding ClosingCommand}"/>
45
        </i:EventTrigger>
46
    </i:Interaction.Triggers>
47
    <Grid HorizontalAlignment="Stretch" ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto" VerticalAlignment="Stretch">
48
        <Grid.RowDefinitions>
49
            <RowDefinition Height="Auto"/>
50
            <RowDefinition Height="*"/>
51
        </Grid.RowDefinitions>
52
        <StackPanel Margin="0,10" Orientation="Horizontal" HorizontalAlignment="Right" Grid.Row="0"  Height="20" >
53
            <TextBlock Text="Display Count : " VerticalAlignment="Center"/>
54
            <telerik:RadComboBox x:Name="ComboCount" Width="100" SelectedItem="{Binding SelectedCount, Mode=TwoWay}" Margin="0,0,10,0" SelectedValuePath="DisplayMember"
55
                  DisplayMemberPath="ValueMember" ItemsSource="{Binding SelectedCountList}" SelectedIndex="0" />
56
            <TextBlock Text="Status Type : " Margin="10,0,0,0"  VerticalAlignment="Center"/>
57
            <telerik:RadComboBox Width="100" SelectedItem="{Binding SelectedStatus, Mode=TwoWay}" SelectedIndex="4"
58
                   DisplayMemberPath="DisplayName" SelectedValuePath="Value" ItemsSource="{Binding StatusCodeList}" Height="20"/>
59
            <telerik:RadToggleButton Content="  엑셀 저장  " Margin="10,0" Height="20" Command="{Binding DataSaveFileGemBoxCommand, Mode=OneWay}"/>
60
            <!--<telerik:RadToggleButton Content=" Filter" Command="{Binding DataFilterCommand, Mode=OneWay}"/>-->
61
        </StackPanel>
62
        <Grid HorizontalAlignment="Left" VerticalAlignment="Top" Grid.Row="1" ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto" >
63
            <Grid.ColumnDefinitions>
64
                <ColumnDefinition Width="387*"/>
65
                <ColumnDefinition Width="13*"/>
66
            </Grid.ColumnDefinitions>
67
            <Grid.RowDefinitions>
68
                <RowDefinition/>
69
            </Grid.RowDefinitions>
70
            <StackPanel Orientation="Vertical" MaxHeight="850" Grid.Row="0">
71
                <StackPanel Orientation="Vertical">
72
                    <controls:DatabaseFilter ProjectNo="{Binding ProjectNumberFilter,Mode=TwoWay}" UniqueKey="{Binding UniqueKeyFilter,Mode=TwoWay}" Service_ID="{Binding Service_IDFilter, Mode=TwoWay}"
73
                                             Docuemnt_Name="{Binding Document_NameFilter, Mode=TwoWay}" Docuemnt_NO="{Binding Docuemnt_NOFilter, Mode=TwoWay}" Reconverter="{Binding ReconverterFilter, Mode=TwoWay}"
74
                                             Revision="{Binding RevisionFilter, Mode=TwoWay}" GroupNO="{Binding GroupNOFilter, Mode=TwoWay}"/>
75
                    <StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
76
                        <telerik:RadToggleButton Content=" Convert 추가" Command="{Binding ConverAddCommand, Mode=OneWay}" Width="100" Margin="0,0,20,0" HorizontalAlignment="Right"/>
77
                        <telerik:RadToggleButton Content=" 검색" Command="{Binding DataFilterCommand, Mode=OneWay}" Width="100" Margin="0,0,20,0" HorizontalAlignment="Right"/>
78
                        <telerik:RadToggleButton Content=" 초기화" Command="{Binding ResetCommand, Mode=OneWay}" Width="100" Margin="0,0,20,0" HorizontalAlignment="Right"/>
79
                    </StackPanel>
80
                </StackPanel>
81

    
82
                <DockPanel LastChildFill="True">
83
                    <telerik:RadExpander ExpandDirection="Down"  BorderThickness="0" Grid.Row="1" MaxHeight="{Binding DataBase_ItemsHeight, Mode=OneWay}"
84
                  ScrollViewer.HorizontalScrollBarVisibility="Auto"  ScrollViewer.VerticalScrollBarVisibility="Auto"  IsExpanded="True" 
85
                             telerik:AnimationManager.IsAnimationEnabled="False" >
86
                        <telerik:RadExpander.Header>
87
                            <Grid>
88
                                <Grid.ColumnDefinitions>
89
                                    <ColumnDefinition Width="Auto"/>
90
                                    <ColumnDefinition Width="Auto"/>
91
                                </Grid.ColumnDefinitions>
92
                                <TextBlock Text="DataBase Items : "/>
93
                                <TextBlock Text="{Binding SelectedCount.DisplayMember, StringFormat=\{0:d\}}" Grid.Column="1"/>
94
                            </Grid>
95
                        </telerik:RadExpander.Header>
96
                
97
                        <telerik:RadGridView x:Name="dataGrid1"  GroupRenderMode="Flat" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"  
98
                                                         ItemsSource="{Binding FilterConvertSourceView}" 
99
                             SelectedItem="{Binding SelectFilterConvert, Mode=TwoWay}"
100
                             RowDetailsTemplate="{StaticResource RowDetailsTemplate}"  
101
                                                         AutoGenerateColumns="False"
102
                             ColumnWidth="*" CanUserFreezeColumns="False"
103
                             Grid.Row="1"  ScrollViewer.CanContentScroll="True" IsFilteringAllowed="True"
104
                             LeftFrozenColumnCount="6" 
105
                             RightFrozenColumnCount="0">
106
                            <telerik:RadContextMenu.ContextMenu>
107
                                <telerik:RadContextMenu x:Name= "GridContextMenu">
108
                                    <telerik:RadMenuItem  Header="Convert"  Command="{Binding ConvertCommand}"/>
109
                                    <telerik:RadMenuItem Header="Validation"  Command="{Binding ValidateCommand}"/>
110
                                    <telerik:RadMenuItem Header="Delete"  Command="{Binding DeleteCommand}"/>
111
                                </telerik:RadContextMenu>
112
                            </telerik:RadContextMenu.ContextMenu>
113
                            <telerik:RadGridView.Columns>
114
                                <telerik:GridViewToggleRowDetailsColumn />
115
                                <controls:RowIndexColumn Header="#" Width="30" CellStyle="{StaticResource RowNumberStyle}" />
116
                                <telerik:GridViewDataColumn Header="Convert ID "
117
                                                                                        DataMemberBinding="{Binding ConvertID}" Width="1.5*" />
118
                                <telerik:GridViewDataColumn x:Name="commend" Header="Markus " Width="0.5*"  CellStyle="{StaticResource StretchCellStyle}">
119
                                    <telerik:GridViewDataColumn.CellTemplate>
120
                                        <DataTemplate>
121
                                            <telerik:RadButton Content="Click" BorderThickness="0"
122
                                                   Background="Transparent"
123
                                                   Command="{Binding MarkusLinkCommand, Source={StaticResource DataBaseItemsModel}}" CommandParameter="{Binding DataContext, RelativeSource={RelativeSource Self}}"/>
124
                                        </DataTemplate>
125
                                    </telerik:GridViewDataColumn.CellTemplate>
126
                                </telerik:GridViewDataColumn>
127
                                <telerik:GridViewDataColumn Header="ProjectNO" 
128
                                                                                        DataMemberBinding="{Binding ProjectNumber}" Width="*" />
129
                                <telerik:GridViewDataColumn Header="UniqueKey"
130
                                                                                        DataMemberBinding="{Binding UniqueKey}" Width="*" />
131
                                <telerik:GridViewDataColumn Header="ConvertState"
132
                                                                                        DataMemberBinding="{Binding ConvertState, Mode=TwoWay}" Width="*" />
133
                                <telerik:GridViewDataColumn Header="CurrentPageNo"
134
                                                                                        DataMemberBinding="{Binding CurrentPageNo, Mode=TwoWay}" Width="*" />
135
                                <telerik:GridViewDataColumn Header="TotalPageNo"
136
                                                                                        DataMemberBinding="{Binding TotalPage, Mode=TwoWay}" Width="*"  />
137
                                <telerik:GridViewDynamicHyperlinkColumn Header="원본파일"
138
                                                        NavigateUrlFormatString=" {0}"
139
                                                                                                            NavigateUrlMemberPaths="OriginfilePath"
140
                                                                                                                Width="2*">
141
                                    <telerik:GridViewDynamicHyperlinkColumn.CellTemplate>
142
                                        <DataTemplate>
143
                                            <TextBlock Text="{Binding FileName}"/>
144
                                        </DataTemplate>
145
                                    </telerik:GridViewDynamicHyperlinkColumn.CellTemplate>
146
                                </telerik:GridViewDynamicHyperlinkColumn>
147
                                <telerik:GridViewDataColumn Header=" ConvertPath"
148
                                                                                        DataMemberBinding="{Binding ConvertPath}" Width="2.5*" />
149
                                <telerik:GridViewDataColumn Header="CreateTime" 
150
                                                                                        DataMemberBinding="{Binding CreateTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
151
                                <telerik:GridViewDataColumn Header="StartTime" 
152
                                                                                        DataMemberBinding="{Binding StartTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
153
                                <telerik:GridViewDataColumn Header="EndTime" 
154
                                                                                        DataMemberBinding="{Binding EndTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
155
                            </telerik:RadGridView.Columns>
156
                        </telerik:RadGridView>
157
                    </telerik:RadExpander>
158
                </DockPanel>
159
                
160
                <telerik:RadExpander Grid.Row="2" ExpandDirection="Down" BorderThickness="0"  MaxHeight="{Binding RealConvert_Height,Mode=OneWay}"
161
                  ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto"
162
                             telerik:AnimationManager.IsAnimationEnabled="False" IsExpanded ="{Binding ConvertShow, Mode=TwoWay}">
163
                    <telerik:RadExpander.Header>
164
                        <Grid>
165
                            <Grid.ColumnDefinitions>
166
                                <ColumnDefinition Width="Auto"/>
167
                                <ColumnDefinition Width="Auto"/>
168
                            </Grid.ColumnDefinitions>
169
                            <TextBlock Text="RealConvert Items : "/>
170
                            <TextBlock Text="{Binding RealConvertSource.Count, StringFormat=\{0:d\}}" Grid.Column="1"/>
171
                        </Grid>
172
                    </telerik:RadExpander.Header>
173
                    <telerik:RadGridView Name="dataGrid2" GroupRenderMode="Flat" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"
174
                                                         ItemsSource="{Binding RealConvertSource}"
175
                             SelectedItem="{Binding SelectRealConvert, Mode=TwoWay}"
176
                             RowDetailsTemplate="{StaticResource RowDetailsTemplate}"
177
                                                         AutoGenerateColumns="False" CanUserFreezeColumns="False"
178
                             ColumnWidth="*"
179
                             Grid.Row="1"  ScrollViewer.CanContentScroll="False" IsFilteringAllowed="True">
180
                        <telerik:RadContextMenu.ContextMenu>
181
                            <telerik:RadContextMenu>
182
                                <telerik:RadMenuItem  Header="Convert"  Command="{Binding ConvertCommand}"/>
183
                                <telerik:RadMenuItem Header="Validation"  Command="{Binding ValidateCommand}"/>
184
                                <telerik:RadMenuItem Header="Delete"  Command="{Binding DeleteCommand}"/>
185
                            </telerik:RadContextMenu>
186
                        </telerik:RadContextMenu.ContextMenu>
187
                        <telerik:RadGridView.Columns>
188
                            <telerik:GridViewToggleRowDetailsColumn />
189
                            <controls:RowIndexColumn Header="#" Width="30" CellStyle="{StaticResource RowNumberStyle}" />
190

    
191
                            <telerik:GridViewDataColumn Header="Convert ID "
192
                                                                                        DataMemberBinding="{Binding ConvertID}" Width="1.5*" />
193

    
194
                            <telerik:GridViewDataColumn Header="Markus " Width="0.5*" CellStyle="{StaticResource StretchCellStyle}">
195
                                <telerik:GridViewDataColumn.CellTemplate>
196
                                    <DataTemplate>
197
                                        <telerik:RadButton Content="Click "  BorderThickness="0" Background="Transparent"
198
                                                   Command="{Binding MarkusLinkCommand, Source={StaticResource DataBaseItemsModel}}" CommandParameter="{Binding DataContext, RelativeSource={RelativeSource Self}}"/>
199
                                    </DataTemplate>
200
                                </telerik:GridViewDataColumn.CellTemplate>
201
                            </telerik:GridViewDataColumn>
202

    
203
                            <telerik:GridViewDataColumn Header="ProjectNO" 
204
                                                                                        DataMemberBinding="{Binding ProjectNumber}" Width="*" />
205
                            <telerik:GridViewDataColumn Header="UniqueKey"
206
                                                                                        DataMemberBinding="{Binding UniqueKey}" Width="*" />
207
                            <telerik:GridViewDataColumn Header="ConvertState"
208
                                                                                        DataMemberBinding="{Binding ConvertState, Mode=TwoWay}" Width="*" />
209

    
210
                            <telerik:GridViewDataColumn Header="CurrentPageNo"
211
                                                                                        DataMemberBinding="{Binding CurrentPageNo, Mode=TwoWay}" Width="*" />
212
                            <telerik:GridViewDataColumn Header="TotalPageNo"
213
                                                                                        DataMemberBinding="{Binding TotalPage, Mode=TwoWay}" Width="*" />
214
                            <telerik:GridViewDynamicHyperlinkColumn x:Name="navigation" Header="원본파일"
215
                                                        NavigateUrlFormatString="{}{0}"
216
                                                                                                            NavigateUrlMemberPaths="OriginfilePath"
217
                                                                                                                Width="2*">
218
                                <telerik:GridViewDynamicHyperlinkColumn.CellTemplate>
219
                                    <DataTemplate>
220
                                        <TextBlock Text="{Binding FileName}"/>
221
                                    </DataTemplate>
222
                                </telerik:GridViewDynamicHyperlinkColumn.CellTemplate>
223
                            </telerik:GridViewDynamicHyperlinkColumn>
224
                            <telerik:GridViewDataColumn Header=" ConvertPath"
225
                                                                                        DataMemberBinding="{Binding ConvertPath}" Width="2.5*" />
226
                            <telerik:GridViewDataColumn Header="CreateTime"
227
                                                                                        DataMemberBinding="{Binding CreateTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
228
                            <telerik:GridViewDataColumn Header="StartTime"
229
                                                                                        DataMemberBinding="{Binding StartTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
230
                            <telerik:GridViewDataColumn Header="EndTime"
231
                                                                                        DataMemberBinding="{Binding EndTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
232
                        </telerik:RadGridView.Columns>
233
                    </telerik:RadGridView>
234
                </telerik:RadExpander>
235

    
236
                <telerik:RadExpander Grid.Row="3" ExpandDirection="Down" BorderThickness="0"  VerticalAlignment="Stretch"
237
                  ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto"  MaxHeight="{Binding Alive_Height,Mode=OneWay}"
238
                             telerik:AnimationManager.IsAnimationEnabled="False"  IsExpanded ="False">
239
                    <telerik:RadExpander.Header>
240
                        <Grid>
241
                            <Grid.RowDefinitions>
242
                                <RowDefinition Height="11*"/>
243
                                <RowDefinition Height="5*"/>
244
                            </Grid.RowDefinitions>
245
                            <Grid.ColumnDefinitions>
246
                                <ColumnDefinition Width="Auto"/>
247
                                <ColumnDefinition Width="Auto"/>
248
                            </Grid.ColumnDefinitions>
249
                            <TextBlock Text="Alive Items : " Grid.RowSpan="2"/>
250
                            <TextBlock Text="{Binding AliveItems.Count, StringFormat=\{0:d\}}" Grid.Column="1" Grid.RowSpan="2"/>
251
                        </Grid>
252
                    </telerik:RadExpander.Header>
253
                    <telerik:RadGridView GroupRenderMode="Flat" VerticalAlignment="Stretch" HorizontalAlignment="Stretch"
254
                                                         ItemsSource="{Binding AliveItems}"
255
                             SelectedItem="{Binding SelectAliveConvert, Mode=TwoWay}"
256
                                                         AutoGenerateColumns="False" CanUserFreezeColumns="False" RowDetailsTemplate="{StaticResource RowDetailsTemplate}"
257
                             ColumnWidth="*"  ScrollViewer.CanContentScroll="False" IsFilteringAllowed="True" Grid.Row="1" >
258
                        <telerik:RadGridView.Columns>
259
                            <telerik:GridViewToggleRowDetailsColumn />
260
                            <controls:RowIndexColumn Header="#" Width="30" CellStyle="{StaticResource RowNumberStyle}" />
261

    
262
                            <telerik:GridViewDataColumn Header="Convert ID "
263
                                                                                        DataMemberBinding="{Binding ConvertID}" Width="1.5*"  />
264

    
265
                            <telerik:GridViewDataColumn Header="Markus " Width="0.5*" CellStyle="{StaticResource StretchCellStyle}">
266
                                <telerik:GridViewDataColumn.CellTemplate>
267
                                    <DataTemplate>
268
                                        <telerik:RadButton Content="Click "  BorderThickness="0" Background="Transparent"
269
                                                   Command="{Binding MarkusLinkCommand, Source={StaticResource DataBaseItemsModel}}" CommandParameter="{Binding DataContext, RelativeSource={RelativeSource Self}}"/>
270
                                    </DataTemplate>
271
                                </telerik:GridViewDataColumn.CellTemplate>
272
                            </telerik:GridViewDataColumn>
273

    
274
                            <telerik:GridViewDataColumn Header="ProjectNO" 
275
                                                                                        DataMemberBinding="{Binding ProjectNumber}" Width="*" />
276
                            <telerik:GridViewDataColumn Header="UniqueKey"
277
                                                                                        DataMemberBinding="{Binding UniqueKey}" Width="*" />
278
                            <telerik:GridViewDataColumn Header="ConvertState"
279
                                                                                        DataMemberBinding="{Binding ConvertState, Mode=TwoWay}" Width="*" />
280

    
281
                            <telerik:GridViewDataColumn Header="CurrentPageNo"
282
                                                                                        DataMemberBinding="{Binding CurrentPageNo, Mode=TwoWay}" Width="*" />
283
                            <telerik:GridViewDataColumn Header="TotalPageNo"
284
                                                                                        DataMemberBinding="{Binding TotalPage, Mode=TwoWay}" Width="*" />
285
                            <telerik:GridViewDynamicHyperlinkColumn  Header="원본파일"
286
                                                        NavigateUrlFormatString="{}{0}"
287
                                                                                                            NavigateUrlMemberPaths="OriginfilePath"
288
                                                                                                                Width="2*">
289
                                <telerik:GridViewDynamicHyperlinkColumn.CellTemplate>
290
                                    <DataTemplate>
291
                                        <TextBlock Text="{Binding FileName}"/>
292
                                    </DataTemplate>
293
                                </telerik:GridViewDynamicHyperlinkColumn.CellTemplate>
294
                            </telerik:GridViewDynamicHyperlinkColumn>
295
                            <telerik:GridViewDataColumn Header=" ConvertPath"
296
                                                                                        DataMemberBinding="{Binding ConvertPath}" Width="2.5*" />
297
                            <telerik:GridViewDataColumn Header="CreateTime"
298
                                                                                        DataMemberBinding="{Binding CreateTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
299
                            <telerik:GridViewDataColumn Header="StartTime"
300
                                                                                        DataMemberBinding="{Binding StartTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
301
                            <telerik:GridViewDataColumn Header="EndTime"
302
                                                                                        DataMemberBinding="{Binding EndTime, Mode=TwoWay, StringFormat=\{0:yyyy.MM.dd HH:mm:ss\}}" Width="*" />
303
                        </telerik:RadGridView.Columns>
304
                    </telerik:RadGridView>
305
                </telerik:RadExpander>
306

    
307
            </StackPanel>
308
        </Grid>
309
    </Grid>
310
</UserControl>
클립보드 이미지 추가 (최대 크기: 500 MB)