Ky So 2 年之前
父節點
當前提交
27d1f73c73
共有 8 個文件被更改,包括 160 次插入1 次删除
  1. 4 0
      p/App.xaml
  2. 0 0
      p/Class/BaseConnect.cs
  3. 12 0
      p/Class/LoadList.cs
  4. 14 0
      p/Class/PageLoad.cs
  5. 12 0
      p/Class/PartialClass.cs
  6. 79 0
      p/PageService.xaml
  7. 28 0
      p/PageService.xaml.cs
  8. 11 1
      p/p.csproj

+ 4 - 0
p/App.xaml

@@ -11,5 +11,9 @@
             <Setter Property="FontFamily" Value="Monotype Corsiva"/>
             <Setter Property="Background" Value="#46b29d"/>
         </Style>
+        <Style TargetType="GroupBox">
+            <Setter Property="FontFamily" Value="Monotype Corsiva"/>
+            <Setter Property="Background" Value="#C6D7FF"/>
+        </Style>
     </Application.Resources>
 </Application>

+ 0 - 0
p/BaseConnect.cs → p/Class/BaseConnect.cs


+ 12 - 0
p/Class/LoadList.cs

@@ -0,0 +1,12 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace p.Class
+{
+    class LoadList
+    {
+    }
+}

+ 14 - 0
p/Class/PageLoad.cs

@@ -0,0 +1,14 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Controls;
+
+namespace p
+{
+    class PageLoad
+    {
+        public static Frame MainFrame; //за подгрузку страниц
+    }
+}

+ 12 - 0
p/Class/PartialClass.cs

@@ -0,0 +1,12 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace p.Class
+{
+    class PartialClass
+    {
+    }
+}

+ 79 - 0
p/PageService.xaml

@@ -0,0 +1,79 @@
+<Page x:Class="p.PageService"
+      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:local="clr-namespace:p"
+      mc:Ignorable="d" 
+      d:DesignHeight="450" d:DesignWidth="800"
+      Title="PageService">
+    <Page.Resources>
+        <DataTemplate x:Key="ServiceItems">
+            <Border BorderBrush="Black" BorderThickness="1">
+                <StackPanel Orientation="Horizontal" Background="{Binding green}">
+                    <GroupBox>
+                        <StackPanel Orientation="Horizontal" Width="600px">
+                            <Image x:Name="Image" Source="{Binding Logo}" Height="75px" Width="75px"/>
+                            <StackPanel Orientation="Vertical">
+                                <TextBlock x:Name="Title" Text="{Binding Title}"/>
+
+
+                                <StackPanel Orientation="Horizontal">
+                                    <Button x:Name="EditService" Content="Редактировать" Uid="{Binding Id_Agent}" Click="EditService_Click" Visibility="{Binding visiblebtn}" Margin="0 0 10 0"/>
+                                    <Button x:Name="DeleteServise" Content="Удалить" Uid="{Binding Id_Agent}" Click="DeleteServise_Click" Visibility="{Binding visiblebtn}" Margin="0 0 10 0"/>
+                                    <Button x:Name="NewZapis" Content="Записать"  Uid="{Binding Id_Agent}" Click="NewZapis_Click"/>
+                                </StackPanel>
+                            </StackPanel>
+
+                        </StackPanel>
+
+                    </GroupBox>
+                </StackPanel>
+            </Border>
+        </DataTemplate>
+    </Page.Resources>
+    <Grid>
+        <Grid.RowDefinitions>
+            <RowDefinition Height="70"/>
+            <RowDefinition Height="9*"/>
+            <RowDefinition Height="*"/>
+
+        </Grid.RowDefinitions>
+        <Grid.ColumnDefinitions>
+            <ColumnDefinition Width="7*"/>
+            <ColumnDefinition x:Name="ColumDefMain" Width="0"/>
+
+        </Grid.ColumnDefinitions>
+        <StackPanel Grid.Column="0" Grid.Row="0" Orientation="Horizontal">
+            <StackPanel Margin="0,0,0,0.4"/>
+            <GroupBox Header="" Margin="0,0,0,0.4">
+                <StackPanel Orientation="Horizontal"/>
+            </GroupBox>
+
+
+            <GroupBox Header="Введите агента" Width="201" Margin="0,0,0,0.4">
+                <StackPanel Orientation="Horizontal">
+                    <TextBox x:Name="SearchBarTxt" Width="176" Height="25" Margin="5,12,0,12" TextChanged="SearchBarTxt_TextChanged" FontSize="14"/>
+
+                </StackPanel>
+            </GroupBox>
+
+            <GroupBox Header="" Margin="0,0,0,0.4">
+                <StackPanel Orientation="Horizontal"/>
+            </GroupBox>
+
+
+
+            <GroupBox Header="Сортировка" Margin="0,0,0,0.4" Width="334">
+                <StackPanel Orientation="Horizontal" Margin="0,0,-2,0">
+                    <Button x:Name="CostSortButtum" Content="Цена" Click="CostSortButtum_Click" Width="130" Height="25" Margin="0,12,0,11"/>
+
+                </StackPanel>
+            </GroupBox>
+
+
+        </StackPanel>
+        <ListBox x:Name="ServiceList" ItemTemplate="{StaticResource ServiceItems}" Grid.Column="0" Grid.Row="1"/>
+        <TextBlock x:Name="kol_voZap" Grid.Column="0" Grid.Row="3"/>
+    </Grid>
+</Page>

+ 28 - 0
p/PageService.xaml.cs

@@ -0,0 +1,28 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+
+namespace p
+{
+    /// <summary>
+    /// Логика взаимодействия для PageService.xaml
+    /// </summary>
+    public partial class PageService : Page
+    {
+        public PageService()
+        {
+            InitializeComponent();
+        }
+    }
+}

+ 11 - 1
p/p.csproj

@@ -73,7 +73,9 @@
     <Compile Include="AgentType.cs">
       <DependentUpon>Model1.tt</DependentUpon>
     </Compile>
-    <Compile Include="BaseConnect.cs" />
+    <Compile Include="Class\BaseConnect.cs" />
+    <Compile Include="Class\LoadList.cs" />
+    <Compile Include="Class\PartialClass.cs" />
     <Compile Include="Material.cs">
       <DependentUpon>Model1.tt</DependentUpon>
     </Compile>
@@ -88,6 +90,10 @@
       <DesignTime>True</DesignTime>
       <DependentUpon>Model1.tt</DependentUpon>
     </Compile>
+    <Compile Include="Class\PageLoad.cs" />
+    <Compile Include="PageService.xaml.cs">
+      <DependentUpon>PageService.xaml</DependentUpon>
+    </Compile>
     <Compile Include="Product.cs">
       <DependentUpon>Model1.tt</DependentUpon>
     </Compile>
@@ -121,6 +127,10 @@
       <DependentUpon>MainWindow.xaml</DependentUpon>
       <SubType>Code</SubType>
     </Compile>
+    <Page Include="PageService.xaml">
+      <SubType>Designer</SubType>
+      <Generator>MSBuild:Compile</Generator>
+    </Page>
   </ItemGroup>
   <ItemGroup>
     <Compile Include="Model1.Context.cs">