From 4971c5ce4e61f93dfa5640aa80e50f9011cf3a49 Mon Sep 17 00:00:00 2001 From: yibo <361071264@qq.com> Date: Sat, 2 Mar 2019 11:00:02 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=A2=E6=88=B7=E7=AB=AF=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- B3DealerClient/BL/CarcassInStoreBL.cs | 4 +- B3DealerClient/BL/FreshInStoreBL.cs | 6 +- .../BO/CarcassInStore/CarcassInStore.cs | 2 +- .../BO/FreshInStore/FreshInStore.cs | 2 +- B3DealerClient/BO/NameIDPair.cs | 41 +- B3DealerClient/BO/NotificationObject.cs | 2 + .../CarcassInStoreConfig.cs | 2 + .../CarcassInStoreContext.cs | 40 +- .../CarcassInStoreWindow.xaml | 11 +- .../CarcassInStoreWindow.xaml.cs | 44 +- .../CarcassSaleOutContext.cs | 22 +- .../CarcassSaleOutWindow.xaml.cs | 396 +++++++++--------- .../FreshInStoreWindow_/FreshInStoreConfig.cs | 1 + .../FreshInStoreContext.cs | 37 +- .../FreshInStoreWindow.xaml | 6 +- .../FreshInStoreWindow.xaml.cs | 28 +- .../FreshSaleOutContext.cs | 22 +- .../FreshSaleOutWindow.xaml.cs | 10 +- 18 files changed, 380 insertions(+), 296 deletions(-) diff --git a/B3DealerClient/BL/CarcassInStoreBL.cs b/B3DealerClient/BL/CarcassInStoreBL.cs index 9332d61..cac340e 100644 --- a/B3DealerClient/BL/CarcassInStoreBL.cs +++ b/B3DealerClient/BL/CarcassInStoreBL.cs @@ -80,11 +80,11 @@ namespace B3DealerClient.BL del.EExecute(); } - public static long FinishInStore(long id) + public static long FinishInStore(long id,long inStoreID) { var target = GetBillReceive(id); - return RpcFacade.Call(MethodPath + "FinishInStore", JsonConvert.SerializeObject(target)); + return RpcFacade.Call(MethodPath + "FinishInStore", JsonConvert.SerializeObject(target), inStoreID); } } } diff --git a/B3DealerClient/BL/FreshInStoreBL.cs b/B3DealerClient/BL/FreshInStoreBL.cs index 3074385..24d8247 100644 --- a/B3DealerClient/BL/FreshInStoreBL.cs +++ b/B3DealerClient/BL/FreshInStoreBL.cs @@ -50,17 +50,17 @@ namespace B3DealerClient.BL } } - public static long FinishInStore(long id) + public static long FinishInStore(long id, long inStoreID) { var target = GetReceiveInfo(id); - return RpcFacade.Call(MethodPath + "FreshFinishInStore", JsonConvert.SerializeObject(target)); + return RpcFacade.Call(MethodPath + "FreshFinishInStore", JsonConvert.SerializeObject(target), inStoreID); } private static IList GetReceiveInfo(long id) { var query = new DmoQuery(typeof(FreshInStore_Record)); - query.Where.Conditions.Add(DQCondition.EQ("BillID",id)); + query.Where.Conditions.Add(DQCondition.EQ("BillID", id)); return query.EExecuteList(); } diff --git a/B3DealerClient/BO/CarcassInStore/CarcassInStore.cs b/B3DealerClient/BO/CarcassInStore/CarcassInStore.cs index 9a2d711..52830f0 100644 --- a/B3DealerClient/BO/CarcassInStore/CarcassInStore.cs +++ b/B3DealerClient/BO/CarcassInStore/CarcassInStore.cs @@ -16,7 +16,7 @@ namespace B3DealerClient.BO public DateTime? ArrivedDate { get; set; } - public string Store_Name { get; set; } + //public string Store_Name { get; set; } private bool mSelected; public bool Selected diff --git a/B3DealerClient/BO/FreshInStore/FreshInStore.cs b/B3DealerClient/BO/FreshInStore/FreshInStore.cs index b7f4625..5438a77 100644 --- a/B3DealerClient/BO/FreshInStore/FreshInStore.cs +++ b/B3DealerClient/BO/FreshInStore/FreshInStore.cs @@ -16,7 +16,7 @@ namespace B3DealerClient.BO public DateTime? ArrivedDate { get; set; } - public string Store_Name { get; set; } + //public string Store_Name { get; set; } private bool mSelected; public bool Selected diff --git a/B3DealerClient/BO/NameIDPair.cs b/B3DealerClient/BO/NameIDPair.cs index 16b3d02..1a47994 100644 --- a/B3DealerClient/BO/NameIDPair.cs +++ b/B3DealerClient/BO/NameIDPair.cs @@ -6,45 +6,10 @@ using System.Threading.Tasks; namespace B3DealerClient.BO { - public class NameIDPair : NotificationObject + public class NameIDPair { - private long? mID; - public long? ID - { - get { return mID; } - set - { - mID = value; - RaisePropertyChanged("ID"); - } - } + public long ID { get; set; } - private string mName; - public string Name - { - get { return mName; } - set - { - mName = value; - RaisePropertyChanged("Name"); - } - } - - public void Clear() - { - Fill(null, null); - } - - public void Fill(long? id, string name) - { - ID = id; - Name = name; - } - - public void Fill(NameIDPair copy) - { - ID = copy.ID; - Name = copy.Name; - } + public string Name { get; set; } } } diff --git a/B3DealerClient/BO/NotificationObject.cs b/B3DealerClient/BO/NotificationObject.cs index fde0d1d..052d6c3 100644 --- a/B3DealerClient/BO/NotificationObject.cs +++ b/B3DealerClient/BO/NotificationObject.cs @@ -18,5 +18,7 @@ namespace B3DealerClient.BO this.PropertyChanged.Invoke(this, new PropertyChangedEventArgs(propertyName)); } } + + public static readonly long? NullLong = null; } } diff --git a/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreConfig.cs b/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreConfig.cs index 64b4097..5be87c7 100644 --- a/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreConfig.cs +++ b/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreConfig.cs @@ -11,6 +11,8 @@ namespace B3DealerClient.Windows.CarcassInStoreWindow_ { public NameIDPair Store { get; set; } + public NameIDPair InStore { get; set; } + public decimal? HookWeight { get; set; } public decimal? Pics { get; set; } diff --git a/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreContext.cs b/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreContext.cs index b6a6ae3..f2245a9 100644 --- a/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreContext.cs +++ b/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreContext.cs @@ -33,11 +33,39 @@ namespace B3DealerClient.Windows.CarcassInStoreWindow_ } } - private NameIDPair mSupplier = new NameIDPair(); - public NameIDPair Supplier { get { return mSupplier; } } + private NameIDPair mSupplier; + public NameIDPair Supplier + { + get { return mSupplier; } + set + { + mSupplier = value; + RaisePropertyChanged("Supplier"); + } + } - private NameIDPair mStore = new NameIDPair(); - public NameIDPair Store { get { return mStore; } } + private NameIDPair mStore; + public NameIDPair Store + { + get { return mStore; } + set + { + mStore = value; + RaisePropertyChanged("Store"); + } + } + + private NameIDPair mInStore; + public NameIDPair InStore + { + get { return mInStore; } + set + { + mInStore = value; + RaisePropertyChanged("InStore"); + RaisePropertyChanged("CanInStore"); + } + } private decimal? mHookWeight; public decimal? HookWeight @@ -74,7 +102,7 @@ namespace B3DealerClient.Windows.CarcassInStoreWindow_ } private CarcassInStore mDmo = null; - public CarcassInStore Dmo { get { return mDmo; } set { mDmo = value; RaisePropertyChanged("Dmo"); } } + public CarcassInStore Dmo { get { return mDmo; } set { mDmo = value; RaisePropertyChanged("Dmo"); RaisePropertyChanged("CanInStore"); } } private CarcassInStore_Detail mDetail = null; public CarcassInStore_Detail Detail { get { return mDetail; } set { mDetail = value; RaisePropertyChanged("Detail"); RaisePropertyChanged("CanSave"); } } @@ -95,5 +123,7 @@ namespace B3DealerClient.Windows.CarcassInStoreWindow_ public CarcassInStore_Receive Receive { get { return mReceive; } set { mReceive = value; RaisePropertyChanged("Receive"); } } public bool CanSave { get { return Pics > 0 && Weight > 0 && mDetail != null; } } + + public bool CanInStore { get { return InStore != null && mDmo != null; } } } } diff --git a/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreWindow.xaml b/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreWindow.xaml index 3810bca..23fc34d 100644 --- a/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreWindow.xaml +++ b/B3DealerClient/Windows/CarcassInStoreWindow_/CarcassInStoreWindow.xaml @@ -14,6 +14,9 @@ +