using YLErp.Modules.EodModule.SettlementModule; namespace YLErp.Modules.EodModule.CompanySpecial { public class DongZhengService { public static void EodExecute(EodSettlementContextV2 context) { try { if (context is null) { throw new ArgumentNullException(nameof(context)); } var dateStr = context.SettleDate.ToString("yyyyMMdd"); var targetPath = Path.Combine("F:"); if (!Directory.Exists(targetPath)) { targetPath = Path.Combine("D:\\list\\wait", dateStr); } else { targetPath = Path.Combine("F:\\list\\wait", dateStr); } if (Directory.Exists(targetPath)) { Directory.Delete(targetPath, true); } } catch (Exception ex) { LogFactory.GetLogger("DongZhengService").Error(ex); } } } }