public void ROPRPAINVISIT_Delete() { DBObject dbObj = new DBObject() { DataBaseType = DBObject.DataBase.Oracle, ID = "cghopr", Password = "******", Node = "lnka2" }; DAOFactory factory = new DAOFactory(dbObj); var daoobject = factory.GetDataAccessObjectFactory(); //ROPRPAINVISIT roprpainvisit = new ROPRPAINVISIT() //{ // //CHTNO = "123", // //CSN = "11111", // //OPERNO = "1234567890", // //VSDAT = DateTime.Now.ToString("yyyyMMddHHmmss"), // EB1 = 15, // EB2 = 3, // EB1UINIT = "mg" //}; ROPRPAINVISIT w_roprpainvisit = new ROPRPAINVISIT() { CHTNO = "123", CSN = "11111", OPERNO = "1234567890", //VSDAT = "20150901102411" }; var target = daoobject.Delete(w_roprpainvisit); bool result = false; if (target.IsSuccess == true && target.EffectRows > 0) { result = true; } Assert.AreEqual(true, result); }
public void ROPRPAINVISIT_Insert() { DBObject dbObj = new DBObject() { DataBaseType = DBObject.DataBase.Oracle, ID = "cghopr", Password = "******", Node = "lnka2" }; DAOFactory factory = new DAOFactory(dbObj); var daoobject = factory.GetDataAccessObjectFactory(); //DateTime d = new DateTime(2015, 8, 31, 9, 30, 0); ROPRPAINVISIT roprpainvisit = new ROPRPAINVISIT() { CHTNO = "123", CSN = "11111", OPERNO = "1234567890", VSDAT = DateTime.Now.ToString("yyyyMMddHHmmss"), EB1 = 11, EB2 = 1 }; var target = daoobject.Insert(roprpainvisit); bool result = false; if (target.IsSuccess) { result = true; } Assert.AreEqual(true, result); }