Exemplo n.º 1
0
        public static object Insert(DEVICE_STATUS_CLEAN parameterObject, string tableName)
        {
            Hashtable inparam = new Hashtable();
              if (parameterObject != null)
              {
                  if (parameterObject.aDatetime != null)
                  {
                      inparam.Add("aDatetime", parameterObject.aDatetime);
                  }
                  if (parameterObject.GPSIndex != null)
                  {
                      inparam.Add("GPSIndex", parameterObject.GPSIndex);
                  }
                  if (parameterObject.Height != null)
                  {
                      inparam.Add("Height", parameterObject.Height);
                  }
                  if (parameterObject.Hspeed != null)
                  {
                      inparam.Add("Hspeed", parameterObject.Hspeed);
                  }
                  if (parameterObject.Style != null)
                  {
                      inparam.Add("Style", parameterObject.Style);
                  }
                  if (parameterObject.X != null)
                  {
                      inparam.Add("X", parameterObject.X);
                  }
                  if (parameterObject.XSpeed != null)
                  {
                      inparam.Add("XSpeed", parameterObject.XSpeed);
                  }
                  if (parameterObject.Y != null)
                  {
                      inparam.Add("Y", parameterObject.Y);
                  }
                  if (parameterObject.YSpeed != null)
                  {
                      inparam.Add("YSpeed", parameterObject.YSpeed);
                  }

              }
              inparam.Add("tableName", tableName);

              return BaseDA.Insert2("InsertDEVICE_STATUS_CLEAN", inparam);
        }
Exemplo n.º 2
0
 public static IList<DEVICE_STATUS_CLEAN> QueryForList(string tableName, DEVICE_STATUS_CLEAN parameterObject = null)
 {
     Hashtable inparam = new Hashtable();
     if (parameterObject != null)
     {
         if (parameterObject.aDatetime.HasValue)
         {
             inparam.Add("aDatetime", parameterObject.aDatetime.Value);
         }
         if (parameterObject.Style.HasValue)
         {
             inparam.Add("Style", parameterObject.Style.Value);
         }
     }
     inparam.Add("tableName", tableName);
     return BaseDA.QueryForList<DEVICE_STATUS_CLEAN>("SelectDEVICE_STATUS_CLEANQuery", inparam);
 }