| | |
| | | using System.ComponentModel; |
| | | using Kingdee.BOS.Contracts; |
| | | using Kingdee.BOS; |
| | | using Kingdee.BOS.Core; |
| | | using Kingdee.BOS.ServiceHelper; |
| | |
| | | using System; |
| | | using Kingdee.BOS.Util; |
| | | using System.Linq; |
| | | using ZD.Cloud.WebApi; |
| | | using Demo.Model.Model; |
| | | using Demo.Model.Model.PODemandPlan; |
| | | using System.Diagnostics; |
| | | using System.Collections.Generic; |
| | | using ZD.Share.Common; |
| | | using Kingdee.K3.Core.SCM.STK; |
| | | using Kingdee.BOS.Orm.DataEntity; |
| | | using Kingdee.K3.SCM.ServiceHelper; |
| | | using ZD.Cloud.WebApi; |
| | | |
| | | namespace Demo.TimedTaskPlugIn.PRD |
| | | { |
| | |
| | | [HotUpdate] |
| | | public class StockChangeDynamicAlignment : Kingdee.BOS.Contracts.IScheduleService |
| | | { |
| | | CloudClient cloudClient = new CloudClient("http://localhost/K3Cloud/"); |
| | | CloudClient cloudClient = new CloudClient("http://localhost//k3cloud/"); |
| | | public Context Context; |
| | | List<PRD_Inventory> ListInventory;//库存明细 |
| | | List<PRD_Inventory> ListInventoryByStockOrgId;//物料总库存 |
| | |
| | | Context = ctx; |
| | | string sql = @"/*dialect*/ select count(*) from |
| | | ( |
| | | select a.FSTOCKORGID,sum(b.FACTUALQTY)FACTUALQTY,b.FMATERIALID from T_PRD_PICKMTRL A |
| | | select a.FSTOCKORGID,sum(b.FACTUALQTY)FACTUALQTY,b.FMATERIALID from T_PRD_FEEDMTRL A |
| | | join T_PRD_PICKMTRLDATA b on a.FID =b.FID |
| | | where a.FAPPROVEDATE is not null and DATEDIFF(D,GETDATE(),FDATE)=0 |
| | | group by FSTOCKORGID,FMATERIALID |