订单列表每一行的表头
This commit is contained in:
1 parent
edc7913637
commit
44503f91cf
14 files changed
+186
-59
No files matched your search
@@ -85,6 +85,7 @@
|
|||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="BaseWindows\BaseWindow.cs" />
|
<Compile Include="BaseWindows\BaseWindow.cs" />
|
||||||
<Compile Include="Converters\TextToVisibilityConverter.cs" />
|
<Compile Include="Converters\TextToVisibilityConverter.cs" />
|
||||||
|
<Compile Include="Converters\VisibleToVisibilityConverter.cs" />
|
||||||
<Compile Include="Ctrls\OrderCtrls\OrderListRowCtrl.xaml.cs">
|
<Compile Include="Ctrls\OrderCtrls\OrderListRowCtrl.xaml.cs">
|
||||||
<DependentUpon>OrderListRowCtrl.xaml</DependentUpon>
|
<DependentUpon>OrderListRowCtrl.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -107,6 +108,7 @@
|
|||||||
<DependentUpon>Icons.xaml</DependentUpon>
|
<DependentUpon>Icons.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="UserControls\UcImageButton.cs" />
|
<Compile Include="UserControls\UcImageButton.cs" />
|
||||||
|
<Compile Include="UserControls\UcWaterMarkTextBox.cs" />
|
||||||
<Compile Include="UserControls\UcWindowBoxes.xaml.cs">
|
<Compile Include="UserControls\UcWindowBoxes.xaml.cs">
|
||||||
<DependentUpon>UcWindowBoxes.xaml</DependentUpon>
|
<DependentUpon>UcWindowBoxes.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -187,6 +189,10 @@
|
|||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
</Page>
|
</Page>
|
||||||
|
<Page Include="Styles\UcWaterMarkTextBoxStyle.xaml">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
</Page>
|
||||||
<Page Include="ToolCtrls\Icons.xaml">
|
<Page Include="ToolCtrls\Icons.xaml">
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
|||||||
@@ -2,9 +2,12 @@
|
|||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:local="clr-namespace:_29WxOrderWpf"
|
xmlns:local="clr-namespace:_29WxOrderWpf"
|
||||||
|
xmlns:converters="clr-namespace:_29WxOrderWpf.Converters"
|
||||||
StartupUri="MainWindow.xaml">
|
StartupUri="MainWindow.xaml">
|
||||||
<Application.Resources>
|
<Application.Resources>
|
||||||
<ResourceDictionary>
|
<ResourceDictionary>
|
||||||
|
<converters:HasTextToVisibilityConverter x:Key="HasTextVisibility"/>
|
||||||
|
<converters:NotHasTextToVisibilityConverter x:Key="NotHasTextVisibility"/>
|
||||||
<ResourceDictionary.MergedDictionaries>
|
<ResourceDictionary.MergedDictionaries>
|
||||||
<ResourceDictionary Source="Styles/BaseWindowStyle.xaml" />
|
<ResourceDictionary Source="Styles/BaseWindowStyle.xaml" />
|
||||||
<ResourceDictionary Source="Styles/BaseDataGridStyle.xaml" />
|
<ResourceDictionary Source="Styles/BaseDataGridStyle.xaml" />
|
||||||
|
|||||||
@@ -0,0 +1,24 @@
|
|||||||
|
using NaiBa.Util.Extension;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Globalization;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows;
|
||||||
|
using System.Windows.Data;
|
||||||
|
|
||||||
|
namespace _29WxOrderWpf.Converters
|
||||||
|
{
|
||||||
|
public class VisibleToVisibilityConverter : IValueConverter
|
||||||
|
{
|
||||||
|
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
|
||||||
|
{
|
||||||
|
return value.ParseToBool() ? Visibility.Visible : Visibility.Collapsed;
|
||||||
|
}
|
||||||
|
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException(); // 单向绑定可不实现
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -9,10 +9,7 @@
|
|||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
d:DesignHeight="450" d:DesignWidth="800" Loaded="Window_Loaded">
|
d:DesignHeight="450" d:DesignWidth="800" Loaded="Window_Loaded">
|
||||||
|
|
||||||
<UserControl.Resources>
|
|
||||||
<converters:NotHasTextToVisibilityConverter x:Key="NotHasTextVisibility"/>
|
|
||||||
</UserControl.Resources>
|
|
||||||
|
|
||||||
<Grid Background="{StaticResource ListCtrlBackColorBrush}">
|
<Grid Background="{StaticResource ListCtrlBackColorBrush}">
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
<RowDefinition Height="50"></RowDefinition>
|
<RowDefinition Height="50"></RowDefinition>
|
||||||
@@ -26,7 +23,6 @@
|
|||||||
<ColumnDefinition Width="*"></ColumnDefinition>
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
||||||
<ColumnDefinition Width="*"></ColumnDefinition>
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
|
||||||
<ColumnDefinition Width="*"></ColumnDefinition>
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
||||||
<ColumnDefinition Width="*"></ColumnDefinition>
|
<ColumnDefinition Width="*"></ColumnDefinition>
|
||||||
@@ -35,14 +31,28 @@
|
|||||||
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
||||||
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
<ColumnDefinition Width="Auto"></ColumnDefinition>
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<TextBox x:Name="txtShopName" Grid.Column="0" Margin="4,0,-4,0" BorderBrush="{StaticResource mainColorBrush}" BorderThickness="1" Height="28" VerticalContentAlignment="Center"
|
<TextBox x:Name="txtShopName" Grid.Column="0" Margin="4,0,-4,0" BorderBrush="{StaticResource pageColorBrush}" BorderThickness="1" Height="28" VerticalContentAlignment="Center"
|
||||||
Style="{StaticResource BaseRoundCornerTextBoxStyle}" />
|
Style="{StaticResource BaseRoundCornerTextBoxStyle}" />
|
||||||
<TextBlock Text="全部店铺" Grid.Column="0" Margin="8,0,8,0" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray" Visibility="{Binding ElementName=txtShopName,Path=Text,Converter={StaticResource NotHasTextVisibility}}"></TextBlock>
|
<TextBlock Text="全部店铺" Grid.Column="0" Margin="8,0,8,0" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray" Visibility="{Binding ElementName=txtShopName,Path=Text,Converter={StaticResource NotHasTextVisibility}}"></TextBlock>
|
||||||
<Button Grid.Column="1" x:Name="btnMultiShopChoice" Style="{StaticResource BasePageButtonStyle}" Margin="-4,0,0,0" Grid.Row="4" Content=" ... " Width="28" Height="28" Click="btnMultiShopChoice_Click"></Button>
|
<Button Grid.Column="1" x:Name="btnMultiShopChoice" Style="{StaticResource BasePageButtonStyle}" Margin="-4,0,4,0" Grid.Row="4" Content=" ... " Width="28" Height="28" Click="btnMultiShopChoice_Click"></Button>
|
||||||
<TextBox x:Name="txtGoodsName" Grid.Column="2" Margin="4,0" BorderBrush="{StaticResource mainColorBrush}" BorderThickness="1" Height="28" VerticalContentAlignment="Center"
|
<TextBox x:Name="txtGoodsName" Grid.Column="2" Margin="0,0,4,0" BorderBrush="{StaticResource pageColorBrush}" BorderThickness="1" Height="28" VerticalContentAlignment="Center"
|
||||||
Style="{StaticResource BaseRoundCornerTextBoxStyle}"/>
|
Style="{StaticResource BaseRoundCornerTextBoxStyle}"/>
|
||||||
<TextBlock Text="商品标题" Grid.Column="2" Margin="8,0,8,0" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray" Visibility="{Binding ElementName=txtGoodsName,Path=Text,Converter={StaticResource NotHasTextVisibility}}"></TextBlock>
|
<TextBlock Text="商品标题" Grid.Column="2" Margin="8,0,8,0" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray" Visibility="{Binding ElementName=txtGoodsName,Path=Text,Converter={StaticResource NotHasTextVisibility}}"></TextBlock>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<ComboBox x:Name="cmbUserNameMobile" Margin="4,0" VerticalContentAlignment="Center" Style="{StaticResource BaseComboBoxStyle}" Grid.Column="3" Width="70" Height="28" Text="成交时间"/>
|
||||||
|
<Border Grid.Column="3" Margin="0,0,0,0" BorderBrush="{StaticResource pageColorBrush}" BorderThickness="1,1,1,1" Height="28" VerticalAlignment="Center" CornerRadius="4,0,0,4"/>
|
||||||
|
<Border Grid.Column="4" Margin="0,0,0,0" BorderBrush="{StaticResource pageColorBrush}" BorderThickness="0,1,1,1" Height="28" VerticalAlignment="Center" CornerRadius="0,0,0,0"/>
|
||||||
|
<DatePicker x:Name="dateStart" Grid.Column="4" Margin="0,0,4,0" VerticalAlignment="Center" BorderThickness="0" />
|
||||||
|
|
||||||
|
<Border Grid.Column="5" Margin="0,0,0,0" BorderBrush="{StaticResource pageColorBrush}" BorderThickness="0,1,1,1" Height="28" VerticalAlignment="Center" CornerRadius="0,4,4,0"/>
|
||||||
|
<DatePicker x:Name="dateEnd" Grid.Column="5" Margin="0,0,4,0" VerticalAlignment="Center" BorderThickness="0" />
|
||||||
|
|
||||||
|
<Button Grid.Column="10" x:Name="btnRefresh" Style="{StaticResource BasePageButtonStyle}" Margin="4,0,0,0" Grid.Row="4" Content="过滤" Width="48" Height="28" Click="btnSearch_Click"></Button>
|
||||||
|
<Button Grid.Column="11" x:Name="btnSearch" Style="{StaticResource BasePageButtonStyle}" Margin="4,0,4,0" Grid.Row="4" Content="读单" Width="48" Height="28" Click="btnSearch_Click"></Button>
|
||||||
|
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
<Grid x:Name="gridListHeader" Margin="4,0" Grid.Row="1">
|
<Grid x:Name="gridListHeader" Margin="4,0" Grid.Row="1">
|
||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
@@ -74,7 +84,7 @@
|
|||||||
<ListBox.ItemTemplate>
|
<ListBox.ItemTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
<!--此处绑定将数据源传递给子自定义控件OrderListRowCtrl-->
|
<!--此处绑定将数据源传递给子自定义控件OrderListRowCtrl-->
|
||||||
<local:OrderListRowCtrl DataContext="{Binding}"></local:OrderListRowCtrl>
|
<local:OrderListRowCtrl Visibility="{Binding }" DataContext="{Binding}"></local:OrderListRowCtrl>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</ListBox.ItemTemplate>
|
</ListBox.ItemTemplate>
|
||||||
</ListBox>
|
</ListBox>
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
using AllBase;
|
using _29WxOrderWpf.BaseWindows;
|
||||||
|
using AllBase;
|
||||||
using AllBase.Extension;
|
using AllBase.Extension;
|
||||||
using AllBase.Helper;
|
using AllBase.Helper;
|
||||||
using AllBase.Model;
|
using AllBase.Model;
|
||||||
@@ -48,8 +49,11 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
//dgOrder.Items.Add(1111111);
|
//dgOrder.Items.Add(1111111);
|
||||||
|
|
||||||
//dgOrder.ItemsSource = lstOrder;
|
//dgOrder.ItemsSource = lstOrder;
|
||||||
|
|
||||||
//lbxOrder.ItemsSource = lstOrder;
|
//lbxOrder.ItemsSource = lstOrder;
|
||||||
|
|
||||||
|
dateStart.SelectedDate = DateTime.Now.Date.AddDays(-30);
|
||||||
|
dateEnd.SelectedDate = DateTime.Now.Date.AddDays(1).AddSeconds(-1);
|
||||||
|
|
||||||
Task.Run(() =>
|
Task.Run(() =>
|
||||||
{
|
{
|
||||||
while (!MainWindow.Instance.hasReadShop)
|
while (!MainWindow.Instance.hasReadShop)
|
||||||
@@ -78,6 +82,8 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
{
|
{
|
||||||
int page = 0;
|
int page = 0;
|
||||||
int totalPage = 1;
|
int totalPage = 1;
|
||||||
|
int pageSize = 50;
|
||||||
|
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
if (page >= totalPage)
|
if (page >= totalPage)
|
||||||
@@ -88,8 +94,8 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
page++;
|
page++;
|
||||||
var url = BaseClass.Build29WxObjString("order/get_order_list");
|
var url = BaseClass.Build29WxObjString("order/get_order_list");
|
||||||
var data = UserLogin.GetSignaturex() + "&page=" + page;
|
var data = UserLogin.GetSignaturex() + "&page=" + page;
|
||||||
|
data += "&page_size=" + pageSize;
|
||||||
var shop_id = string.Join(",", GlobalConfig.ShopLoginList.Select(s => s.ErpShopId).Where(s => !s.IsNullOrEmpty()));
|
var shop_id = string.Join(",", GlobalConfig.ShopLoginList.Select(s => s.ErpShopId).Where(s => !s.IsNullOrEmpty()));
|
||||||
data += "&erp_shop_id_in=" + shop_id;
|
|
||||||
Dispatcher.Invoke(new Action(() =>
|
Dispatcher.Invoke(new Action(() =>
|
||||||
{
|
{
|
||||||
if (!string.IsNullOrEmpty(txtShopName.Text.Trim()))
|
if (!string.IsNullOrEmpty(txtShopName.Text.Trim()))
|
||||||
@@ -97,6 +103,11 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
var shopNames = txtShopName.Text.Trim().Split(';').Where(s => !s.IsNullOrEmpty()).ToList();
|
var shopNames = txtShopName.Text.Trim().Split(';').Where(s => !s.IsNullOrEmpty()).ToList();
|
||||||
shop_id = string.Join(",", GlobalConfig.ShopLoginList.Where(s => shopNames.Contains(s.ShopAccount)).Select(s => s.ErpShopId).Where(s => !s.IsNullOrEmpty()));
|
shop_id = string.Join(",", GlobalConfig.ShopLoginList.Where(s => shopNames.Contains(s.ShopAccount)).Select(s => s.ErpShopId).Where(s => !s.IsNullOrEmpty()));
|
||||||
}
|
}
|
||||||
|
var startTime = BaseClass.DateTimeToTimestampSeconds(dateStart.SelectedDate.Value);
|
||||||
|
var endTime = BaseClass.DateTimeToTimestampSeconds(dateEnd.SelectedDate.Value);
|
||||||
|
data += "&erp_shop_id_in=" + shop_id;
|
||||||
|
data += "&start_time=" + startTime;
|
||||||
|
data += "&end_time=" + endTime;
|
||||||
}));
|
}));
|
||||||
Thread.Sleep(200);
|
Thread.Sleep(200);
|
||||||
var html = GetHtml.PostUtf8(url, data);
|
var html = GetHtml.PostUtf8(url, data);
|
||||||
@@ -133,24 +144,13 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
}
|
}
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var totalCount = BaseRegex.GetIntJson(ref html, "count");
|
||||||
|
totalPage = Math.Ceiling(1m * totalCount / pageSize).ParseToInt();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void Path_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
|
|
||||||
{
|
|
||||||
var orderId = ((sender as Border)?.Tag).ParseToString();
|
|
||||||
try
|
|
||||||
{
|
|
||||||
Clipboard.SetText(orderId);
|
|
||||||
}
|
|
||||||
catch (Exception ex)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private void btnMultiShopChoice_Click(object sender, RoutedEventArgs e)
|
private void btnMultiShopChoice_Click(object sender, RoutedEventArgs e)
|
||||||
{
|
{
|
||||||
MainWindow.Instance.shopListCtrl.IsVisibleChanged -= ShopListCtrl_IsVisibleChanged;
|
MainWindow.Instance.shopListCtrl.IsVisibleChanged -= ShopListCtrl_IsVisibleChanged;
|
||||||
@@ -166,9 +166,12 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
if (list != null)
|
if (list != null)
|
||||||
this.txtShopName.Text = string.Join(";", list.Where(s => s.IsSelect == true).Select(s => s.ShopAccount));
|
this.txtShopName.Text = string.Join(";", list.Where(s => s.IsSelect == true).Select(s => s.ShopAccount));
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
MainWindow.Instance.shopListCtrl.IsVisibleChanged -= ShopListCtrl_IsVisibleChanged;
|
MainWindow.Instance.shopListCtrl.IsVisibleChanged -= ShopListCtrl_IsVisibleChanged;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void btnSearch_Click(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
using NaiBa.Util.Extension;
|
using _29WxOrderWpf.BaseWindows;
|
||||||
|
using NaiBa.Util.Extension;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
@@ -25,17 +26,5 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Path_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
|
|
||||||
{
|
|
||||||
var orderId = ((sender as Border)?.Tag).ParseToString();
|
|
||||||
try
|
|
||||||
{
|
|
||||||
Clipboard.SetText(orderId);
|
|
||||||
}
|
|
||||||
catch (Exception ex)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3,9 +3,9 @@
|
|||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:local="clr-namespace:_29WxOrderWpf.Ctrls.OrderCtrls"
|
xmlns:local="clr-namespace:_29WxOrderWpf.Ctrls.OrderCtrls" xmlns:usercontrols="clr-namespace:_29WxOrderWpf.UserControls"
|
||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
d:DesignHeight="150" d:DesignWidth="800">
|
d:DesignHeight="50" d:DesignWidth="800">
|
||||||
|
|
||||||
<Border Background="{StaticResource ListRowBorderColorBrush}" CornerRadius="12,12,0,0" >
|
<Border Background="{StaticResource ListRowBorderColorBrush}" CornerRadius="12,12,0,0" >
|
||||||
<Grid>
|
<Grid>
|
||||||
@@ -16,14 +16,33 @@
|
|||||||
<ColumnDefinition Width="auto"/>
|
<ColumnDefinition Width="auto"/>
|
||||||
<ColumnDefinition Width="auto"/>
|
<ColumnDefinition Width="auto"/>
|
||||||
<ColumnDefinition Width="auto"/>
|
<ColumnDefinition Width="auto"/>
|
||||||
|
<ColumnDefinition Width="auto"/>
|
||||||
|
<ColumnDefinition Width="auto"/>
|
||||||
|
<ColumnDefinition Width="auto"/>
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<TextBox Grid.Column="0" Margin="8,8,0,8" VerticalAlignment="Center" FontSize="14" Background="Transparent" IsReadOnly="True" Text="店铺单号:" BorderThickness="0" />
|
<TextBox Grid.Column="0" Margin="8,8,-4,8" VerticalAlignment="Center" FontSize="14" Background="Transparent" IsReadOnly="True" Text="店铺单号:" BorderThickness="0" />
|
||||||
<TextBox Grid.Column="1" Margin="0,8,8,8" VerticalAlignment="Center" FontSize="14" Background="Transparent" IsReadOnly="True"
|
<TextBox x:Name="txtOrderId" Grid.Column="1" Margin="0,8,4,8" VerticalAlignment="Center" FontSize="14" Background="Transparent" IsReadOnly="True" Text="{Binding order_id}" BorderThickness="0" />
|
||||||
Text="{Binding order_id}" BorderThickness="0" />
|
<TextBlock Text="订单号" Grid.Column="1" Margin="0,8,4,8" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray" Visibility="{Binding ElementName=txtOrderId,Path=Text,Converter={StaticResource NotHasTextVisibility}}"></TextBlock>
|
||||||
|
|
||||||
<Border Grid.Column="2" Width="12" Background="Transparent" Height="12" VerticalAlignment="Center" Cursor="Hand"
|
<Border Grid.Column="2" Width="12" Background="Transparent" Height="12" VerticalAlignment="Center" Cursor="Hand"
|
||||||
Tag="{Binding order_id}" MouseLeftButtonDown="Path_MouseLeftButtonDown">
|
Tag="{Binding order_id}" MouseLeftButtonDown="Path_MouseLeftButtonDown">
|
||||||
<Path Margin="0,0,0,0" Fill="#409eff" Tag="{Binding order_id}" MouseLeftButtonDown="Path_MouseLeftButtonDown" Data="M80 432a128 128 0 0 1 128-128h384a128 128 0 0 1 128 128v384a128 128 0 0 1-128 128h-384a128 128 0 0 1-128-128v-384z m128-64a64 64 0 0 0-64 64v384a64 64 0 0 0 64 64h384a64 64 0 0 0 64-64v-384a64 64 0 0 0-64-64h-384z M816 144h-384a64 64 0 0 0-64 64 32 32 0 0 1-64 0 128 128 0 0 1 128-128h384a128 128 0 0 1 128 128v384a128 128 0 0 1-128 128 32 32 0 0 1 0-64 64 64 0 0 0 64-64v-384a64 64 0 0 0-64-64z" Stretch="Uniform" />
|
<Path Margin="0,0,0,0" Fill="#409eff" Tag="{Binding order_id}" MouseLeftButtonDown="Path_MouseLeftButtonDown" Data="M80 432a128 128 0 0 1 128-128h384a128 128 0 0 1 128 128v384a128 128 0 0 1-128 128h-384a128 128 0 0 1-128-128v-384z m128-64a64 64 0 0 0-64 64v384a64 64 0 0 0 64 64h384a64 64 0 0 0 64-64v-384a64 64 0 0 0-64-64h-384z M816 144h-384a64 64 0 0 0-64 64 32 32 0 0 1-64 0 128 128 0 0 1 128-128h384a128 128 0 0 1 128 128v384a128 128 0 0 1-128 128 32 32 0 0 1 0-64 64 64 0 0 0 64-64v-384a64 64 0 0 0-64-64z" Stretch="Uniform" />
|
||||||
</Border>
|
</Border>
|
||||||
|
<Border Grid.Column="3" Margin="8,0,0,0" Background="#e8fbf9" BorderBrush="#d0fbea" BorderThickness="1" MinWidth="30" Height="24" CornerRadius="2">
|
||||||
|
<Grid>
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition></ColumnDefinition>
|
||||||
|
<ColumnDefinition></ColumnDefinition>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Border Background="#0397b5" CornerRadius="2,0,10,2">
|
||||||
|
<TextBox Grid.Column="0" Margin="2,0,2,1" Foreground="White" VerticalContentAlignment="Center" VerticalAlignment="Center" Background="Transparent" IsReadOnly="True" Text="剩余" BorderThickness="0" />
|
||||||
|
</Border>
|
||||||
|
<TextBox Grid.Column="1" Margin="2,0,2,1" Foreground="#0397b5" VerticalContentAlignment="Center" VerticalAlignment="Center" Background="Transparent" IsReadOnly="True" Text="0小时0分0秒" BorderThickness="0" />
|
||||||
|
</Grid>
|
||||||
|
</Border>
|
||||||
|
<Image Margin="8,8,0,8" Grid.Column="4" Width="24" Height="24" Source="{StaticResource OrderWeishopIcon}"></Image>
|
||||||
|
<TextBox x:Name="txtShopName" Grid.Column="5" Margin="0,8,0,8" VerticalAlignment="Center" FontSize="14" Background="Transparent" IsReadOnly="True" Text="{Binding shop_name}" BorderThickness="0" />
|
||||||
|
<TextBlock Text="店铺名称" Grid.Column="5" Margin="0,8,4,8" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray" Visibility="{Binding ElementName=txtOrderId,Path=Text,Converter={StaticResource NotHasTextVisibility}}"></TextBlock>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Border>
|
</Border>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
using NaiBa.Util.Extension;
|
using _29WxOrderWpf.BaseWindows;
|
||||||
|
using NaiBa.Util.Extension;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
@@ -35,6 +36,7 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
|||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
BaseMsgWindow.ShowError(MainWindow.Instance, "复制失败 " + ex.Message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -99,13 +99,13 @@
|
|||||||
</Setter>
|
</Setter>
|
||||||
</Style>
|
</Style>
|
||||||
<Style x:Key="BasePageButtonStyle" TargetType="Button">
|
<Style x:Key="BasePageButtonStyle" TargetType="Button">
|
||||||
<Setter Property="Foreground" Value="{DynamicResource mainColorLightBrush}"/>
|
<Setter Property="Foreground" Value="{DynamicResource pageColorLightBrush}"/>
|
||||||
<Setter Property="BorderThickness" Value="0"/>
|
<Setter Property="BorderThickness" Value="0"/>
|
||||||
<Setter Property="Template">
|
<Setter Property="Template">
|
||||||
<Setter.Value>
|
<Setter.Value>
|
||||||
<ControlTemplate TargetType="Button">
|
<ControlTemplate TargetType="Button">
|
||||||
<Border x:Name="buttonBorder" Background="{DynamicResource mainColorBrush}" Cursor="Hand"
|
<Border x:Name="buttonBorder" Background="{DynamicResource pageColorBrush}" Cursor="Hand"
|
||||||
BorderBrush="{DynamicResource mainColorDarkBrush}" CornerRadius="4"
|
BorderBrush="{DynamicResource pageColorDarkBrush}" CornerRadius="4"
|
||||||
BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}">
|
BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}">
|
||||||
<ContentPresenter Content="{TemplateBinding Content}"
|
<ContentPresenter Content="{TemplateBinding Content}"
|
||||||
ContentStringFormat="{TemplateBinding ContentStringFormat}"
|
ContentStringFormat="{TemplateBinding ContentStringFormat}"
|
||||||
@@ -116,10 +116,10 @@
|
|||||||
</Border>
|
</Border>
|
||||||
<ControlTemplate.Triggers>
|
<ControlTemplate.Triggers>
|
||||||
<Trigger Property="IsMouseOver" Value="True">
|
<Trigger Property="IsMouseOver" Value="True">
|
||||||
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource mainColorDarkBrush}"/>
|
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource pageColorDarkBrush}"/>
|
||||||
</Trigger>
|
</Trigger>
|
||||||
<Trigger Property="IsPressed" Value="True">
|
<Trigger Property="IsPressed" Value="True">
|
||||||
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource mainColorDarkBrush}"/>
|
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource pageColorDarkBrush}"/>
|
||||||
</Trigger>
|
</Trigger>
|
||||||
<Trigger Property="IsEnabled" Value="False">
|
<Trigger Property="IsEnabled" Value="False">
|
||||||
<Setter Property="Opacity" Value="0.5" />
|
<Setter Property="Opacity" Value="0.5" />
|
||||||
@@ -130,13 +130,13 @@
|
|||||||
</Setter>
|
</Setter>
|
||||||
</Style>
|
</Style>
|
||||||
<Style x:Key="BasePageButtonLightStyle" TargetType="Button">
|
<Style x:Key="BasePageButtonLightStyle" TargetType="Button">
|
||||||
<Setter Property="Foreground" Value="{DynamicResource mainColorBrush}"/>
|
<Setter Property="Foreground" Value="{DynamicResource pageColorBrush}"/>
|
||||||
<Setter Property="BorderThickness" Value="1"/>
|
<Setter Property="BorderThickness" Value="1"/>
|
||||||
<Setter Property="Template">
|
<Setter Property="Template">
|
||||||
<Setter.Value>
|
<Setter.Value>
|
||||||
<ControlTemplate TargetType="Button">
|
<ControlTemplate TargetType="Button">
|
||||||
<Border x:Name="buttonBorder" Background="{DynamicResource mainColorLightBrush}" Cursor="Hand"
|
<Border x:Name="buttonBorder" Background="{DynamicResource pageColorLightBrush}" Cursor="Hand"
|
||||||
BorderBrush="{DynamicResource mainColorBrush}" CornerRadius="4"
|
BorderBrush="{DynamicResource pageColorBrush}" CornerRadius="4"
|
||||||
BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}">
|
BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}">
|
||||||
<ContentPresenter Content="{TemplateBinding Content}"
|
<ContentPresenter Content="{TemplateBinding Content}"
|
||||||
ContentStringFormat="{TemplateBinding ContentStringFormat}"
|
ContentStringFormat="{TemplateBinding ContentStringFormat}"
|
||||||
@@ -147,12 +147,12 @@
|
|||||||
</Border>
|
</Border>
|
||||||
<ControlTemplate.Triggers>
|
<ControlTemplate.Triggers>
|
||||||
<Trigger Property="IsMouseOver" Value="True">
|
<Trigger Property="IsMouseOver" Value="True">
|
||||||
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource mainColorDarkBrush}"/>
|
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource pageColorDarkBrush}"/>
|
||||||
<Setter Property="Foreground" Value="{DynamicResource mainColorLightBrush}"/>
|
<Setter Property="Foreground" Value="{DynamicResource pageColorLightBrush}"/>
|
||||||
</Trigger>
|
</Trigger>
|
||||||
<Trigger Property="IsPressed" Value="True">
|
<Trigger Property="IsPressed" Value="True">
|
||||||
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource mainColorDarkBrush}"/>
|
<Setter Property="Background" TargetName="buttonBorder" Value="{DynamicResource pageColorDarkBrush}"/>
|
||||||
<Setter Property="Foreground" Value="{DynamicResource mainColorLightBrush}"/>
|
<Setter Property="Foreground" Value="{DynamicResource pageColorLightBrush}"/>
|
||||||
</Trigger>
|
</Trigger>
|
||||||
<Trigger Property="IsEnabled" Value="False">
|
<Trigger Property="IsEnabled" Value="False">
|
||||||
<Setter Property="Opacity" Value="0.5" />
|
<Setter Property="Opacity" Value="0.5" />
|
||||||
|
|||||||
@@ -8,6 +8,9 @@
|
|||||||
<GradientStop Color="#FF98638f" Offset="0.0"/>
|
<GradientStop Color="#FF98638f" Offset="0.0"/>
|
||||||
<GradientStop Color="#FF6b5393" Offset="1.0"/>
|
<GradientStop Color="#FF6b5393" Offset="1.0"/>
|
||||||
</LinearGradientBrush>
|
</LinearGradientBrush>
|
||||||
|
<SolidColorBrush x:Key="pageColorBrush" Color="#FF98638f"/>
|
||||||
|
<SolidColorBrush x:Key="pageColorLightBrush" Color="#f5ebff"/>
|
||||||
|
<SolidColorBrush x:Key="pageColorDarkBrush" Color="#FF6b5393"/>
|
||||||
|
|
||||||
<SolidColorBrush x:Key="ListCtrlBackColorBrush" Color="#FFFFFFFF"/>
|
<SolidColorBrush x:Key="ListCtrlBackColorBrush" Color="#FFFFFFFF"/>
|
||||||
<SolidColorBrush x:Key="ListHeadBackColorBrush" Color="#FFf8f8f9"/>
|
<SolidColorBrush x:Key="ListHeadBackColorBrush" Color="#FFf8f8f9"/>
|
||||||
|
|||||||
@@ -13,4 +13,5 @@
|
|||||||
<BitmapImage x:Key="imgBaseMsgErr" UriSource="/Resources/BaseMsgErr.png"/>
|
<BitmapImage x:Key="imgBaseMsgErr" UriSource="/Resources/BaseMsgErr.png"/>
|
||||||
<BitmapImage x:Key="imgBaseMsgInfo" UriSource="/Resources/BaseMsgInfo.png"/>
|
<BitmapImage x:Key="imgBaseMsgInfo" UriSource="/Resources/BaseMsgInfo.png"/>
|
||||||
<BitmapImage x:Key="imgBaseMsgQue" UriSource="/Resources/BaseMsgQue.png"/>
|
<BitmapImage x:Key="imgBaseMsgQue" UriSource="/Resources/BaseMsgQue.png"/>
|
||||||
|
<BitmapImage x:Key="OrderWeishopIcon" UriSource="/Resources/order_weishop_icon.png" />
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
|
xmlns:local="clr-namespace:_29WxOrderWpf.UserControls">
|
||||||
|
|
||||||
|
<Style TargetType="{x:Type local:UcWaterMarkTextBox}">
|
||||||
|
<Setter Property="Background" Value="Transparent"/>
|
||||||
|
<Setter Property="BorderBrush" Value="Transparent"/>
|
||||||
|
<Setter Property="BorderThickness" Value="1"/>
|
||||||
|
<Setter Property="WaterMark" Value="请输入"/>
|
||||||
|
<!--<Setter Property="Text" Value=""/>-->
|
||||||
|
<Setter Property="Template">
|
||||||
|
<Setter.Value>
|
||||||
|
<ControlTemplate TargetType="{x:Type local:UcWaterMarkTextBox}">
|
||||||
|
<Border x:Name="border" CornerRadius="4" BorderBrush="{TemplateBinding BorderBrush}"
|
||||||
|
BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="True">
|
||||||
|
<Grid>
|
||||||
|
<ScrollViewer x:Name="PART_ContentHost" Focusable="False" HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Hidden"/>
|
||||||
|
<!--<TextBlock Text="{TemplateBinding WaterMark}" Grid.Column="2" Margin="8,0,8,0" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray"
|
||||||
|
Visibility="{Binding ElementName=txtGoodsName,Path=Text,Converter={StaticResource NotHasTextVisibility}}"></TextBlock>-->
|
||||||
|
<TextBlock Text="{TemplateBinding WaterMark}" Grid.Column="2" Margin="8,0,8,0" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray"
|
||||||
|
></TextBlock>
|
||||||
|
|
||||||
|
<TextBlock Text="33333" Grid.Column="2" Margin="8,0,8,0" VerticalAlignment="Center" IsHitTestVisible="False" Foreground="LightGray"
|
||||||
|
></TextBlock>
|
||||||
|
</Grid>
|
||||||
|
</Border>
|
||||||
|
</ControlTemplate>
|
||||||
|
</Setter.Value>
|
||||||
|
</Setter>
|
||||||
|
<!--去除高亮框-->
|
||||||
|
<Style.Triggers>
|
||||||
|
<Trigger Property="IsKeyboardFocusWithin" Value="True">
|
||||||
|
<Setter Property="BorderBrush" Value="Transparent"/>
|
||||||
|
<Setter Property="BorderThickness" Value="0"/>
|
||||||
|
</Trigger>
|
||||||
|
</Style.Triggers>
|
||||||
|
</Style>
|
||||||
|
</ResourceDictionary>
|
||||||
@@ -0,0 +1,26 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using System.Windows;
|
||||||
|
using System.Windows.Controls;
|
||||||
|
|
||||||
|
namespace _29WxOrderWpf.UserControls
|
||||||
|
{
|
||||||
|
public class UcWaterMarkTextBox : TextBox
|
||||||
|
{
|
||||||
|
public UcWaterMarkTextBox()
|
||||||
|
{
|
||||||
|
this.DataContext = this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static readonly DependencyProperty WaterMarkProperty = DependencyProperty.Register(
|
||||||
|
"WaterMark", typeof(string), typeof(UcWaterMarkTextBox), null);
|
||||||
|
public string WaterMark
|
||||||
|
{
|
||||||
|
get { return (string)GetValue(WaterMarkProperty); }
|
||||||
|
set { SetValue(WaterMarkProperty, value); }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -10,6 +10,9 @@ namespace AllBase.Model
|
|||||||
public class oms_wei_order_info
|
public class oms_wei_order_info
|
||||||
{
|
{
|
||||||
public bool is_select { get; set; }
|
public bool is_select { get; set; }
|
||||||
|
public bool is_visible { get; set; } = true;
|
||||||
|
|
||||||
|
|
||||||
public long id { get; set; }
|
public long id { get; set; }
|
||||||
public long shop_id { get; set; }
|
public long shop_id { get; set; }
|
||||||
public string shop_name { get; set; }
|
public string shop_name { get; set; }
|
||||||
|
|||||||
Reference in new issue
Block a user