/// <summary> /// Prepare /// </summary> private void prepare() { mrs = new ManualResetEvent(true); makeEventLog(); #region Get Service User Common.BLL.Logic.GasStation.User lUser = new Common.BLL.Logic.GasStation.User(Common.Enum.EDatabase.GasStation); CommandResult opResult = lUser.getServiceUser(); serviceUser = opResult.model as Common.BLL.Entity.GasStation.User; #endregion }
private void writeToDB(string tagId) { int interval = 1; Common.BLL.Entity.GasStation.User serviceUser; Common.BLL.Logic.GasStation.Traffic lTraffic = new Common.BLL.Logic.GasStation.Traffic(Common.Enum.EDatabase.GasStation); Common.BLL.Entity.GasStation.Tag tag = new Common.BLL.Entity.GasStation.Tag() { tag = tagId }; Common.BLL.Logic.GasStation.User lUser = new Common.BLL.Logic.GasStation.User(Common.Enum.EDatabase.GasStation); CommandResult opResult = lUser.getServiceUser(); serviceUser = opResult.model as Common.BLL.Entity.GasStation.User; lTraffic.insertTagByService(tag, serviceUser, DateTime.Now, interval); }