Example #1
0
 private ServiceModel GetServiceModel(DataTable table)
 {
     ServiceModel setmodel = new ServiceModel();
     if (table == null || table.Rows.Count == 0) return null;
     setmodel.ServiceID = Int32.Parse(table.Rows[0]["Id"].ToString());
     setmodel.ServiceSale = table.Rows[0]["SZservice"].ToString();
     setmodel.ServiceContent = table.Rows[0]["Content"].ToString();
     setmodel.ServiceAfterSale = table.Rows[0]["SHservice"].ToString();
     setmodel.SetUpdateTime = ((DateTime)table.Rows[0]["Update_Time"]).ToString("yyyy/MM/dd HH:mm:ss.fff ");
     return setmodel;
 }
Example #2
0
 private DbParameter[] ExecutionSelectSet(ServiceModel DataPar)
 {
     DbParameter[] sqliteparList = new DbParameter[5];
     sqliteparList[0] = Db_Sqlite.CreateDbParameter("@UpdateTime", DataPar.SetUpdateTime);
     sqliteparList[1] = Db_Sqlite.CreateDbParameter("@Id", DataPar.ServiceID);
     sqliteparList[2] = Db_Sqlite.CreateDbParameter("@Sale", DataPar.ServiceSale);
     sqliteparList[3] = Db_Sqlite.CreateDbParameter("@AfterSale", DataPar.ServiceAfterSale);
     sqliteparList[4] = Db_Sqlite.CreateDbParameter("@Content", DataPar.ServiceContent);
     return sqliteparList;
 }