/// <summary> /// 根据传入Sales Order对象修改SO /// </summary> public static bool EditSO(Model.SOMastData.SalesOrder so) { try { if (so == null) { throw new Exception("SalesOrder is null"); } // 执行建立SO string retSql = String.Empty; factory.EditSO(so, ref retSql); return(true); } catch (Exception ex) { LogHelper.WriteLog(new Log() { message = ex.Message }, "EditSO"); return(false); } }
/// <summary> /// 根据传入Sales Order对象建立SO /// </summary> public static string CreateSO(Model.SOMastData.SalesOrder so) { try { if (so == null) { throw new Exception("SalesOrder is null"); } // Now Time //string now = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff"); // 设置SO建立时间 so.createDate = DateTime.Now.ToString(); // 执行建立SO return(factory.CreateSO(so)); } catch (Exception ex) { LogHelper.WriteLog(new Log() { message = ex.Message }, "CreateSO"); return(null); } }
/// <summary> /// 根据传入Guid取得对应的SO信息 /// </summary> public static Model.SOMastData.SalesOrder GetSO(string guid) { try { if (guid == null) { throw new Exception("Guid is null"); } // 执行建立SO Model.SOMastData.SalesOrder so = factory.GetSO(guid); return(so); } catch (Exception ex) { LogHelper.WriteLog(new Log() { message = ex.Message }, "GetSO"); return(null); } }