| @ -0,0 +1,43 @@ | |||||
| using System; | |||||
| using System.Collections.Generic; | |||||
| using System.Linq; | |||||
| using System.Text; | |||||
| using BWP.B3ClientService.BO; | |||||
| using Forks.EnterpriseServices.DomainObjects2.DQuery; | |||||
| using Forks.EnterpriseServices.JsonRpc; | |||||
| using Newtonsoft.Json; | |||||
| using TSingSoft.WebPluginFramework; | |||||
| namespace BWP.B3ClientService.Rpcs.BillRpc | |||||
| { | |||||
| [Rpc] | |||||
| public static class SaleOutStoreRpc | |||||
| { | |||||
| [Rpc] | |||||
| public static string SyncList(DateTime date, string customerName, string sendLineName, string billstate) | |||||
| { | |||||
| var dmoquery = new DmoQuery(typeof(SaleOutStore)); | |||||
| dmoquery.Where.Conditions.Add(DQCondition.GreaterThanOrEqual("LoadTime", date)); | |||||
| dmoquery.Where.Conditions.Add(DQCondition.LessThan("LoadTime", date.AddDays(1))); | |||||
| if (!string.IsNullOrWhiteSpace(customerName)) | |||||
| { | |||||
| dmoquery.Where.Conditions.Add(DQCondition.EQ("Customer_Name",customerName)); | |||||
| } | |||||
| if (!string.IsNullOrWhiteSpace(sendLineName)) | |||||
| { | |||||
| dmoquery.Where.Conditions.Add(DQCondition.EQ("DeliverGoodsLine_Name", sendLineName)); | |||||
| } | |||||
| if (!string.IsNullOrWhiteSpace(sendLineName)) | |||||
| { | |||||
| dmoquery.Where.Conditions.Add(DQCondition.EQ("BillState", billstate)); | |||||
| } | |||||
| var list = dmoquery.EExecuteList().Cast<SaleOutStore>().ToList(); | |||||
| return JsonConvert.SerializeObject(list); | |||||
| } | |||||
| } | |||||
| } | |||||