public List <tblBatteryComponentInfo> GetLineListById(int id) { try { IBattery iBattery = new WCMS_DAL_BatteryStation(); return(iBattery.GetLineListById(id)); } catch (Exception ex) { throw ex; } }
public List <tblBatteryComponentInfo> ProjectNameExist(tblBatteryComponentInfo tblLineSetup) { try { IBattery iAdmin = new WCMS_DAL_BatteryStation(); return(iAdmin.ProjectNameExist(tblLineSetup)); } catch (Exception ex) { throw ex; } }
public Result UpdateBatteryLine(tblBatteryComponentInfo productionLine) { try { IBattery iBattery = new WCMS_DAL_BatteryStation(); using (TransactionScope transaction = new TransactionScope(TransactionScopeOption.Required, ApplicationState.TransactionOptions)) { Result _Result = new Result(); _Result.IsSuccess = iBattery.UpdateBatteryLine(productionLine); if (_Result.IsSuccess) { transaction.Complete(); } return(_Result); } } catch (Exception ex) { throw ex; } }
public Result DeleteProductionLine(int id) { try { IBattery iBattery = new WCMS_DAL_BatteryStation(); using (TransactionScope transaction = new TransactionScope(TransactionScopeOption.Required, ApplicationState.TransactionOptions)) { Result _Result = new Result(); _Result.IsSuccess = iBattery.DeleteProductionLine(id); if (_Result.IsSuccess) { transaction.Complete(); } return(_Result); } } catch (Exception ex) { throw ex; } }