コード例 #1
0
 public void Put(int VD_ID, [FromBody] Voucher_OtherDetailsn voc)
 {
     voc.VD_ID = VD_ID;
     if (ModelState.IsValid)
     {
         VoucherRepository.Update(voc);
     }
 }
コード例 #2
0
 public void Update(Voucher_OtherDetailsn voc)
 {
     using (IDbConnection dbConnection = Connection)
     {
         string sQuery = " UPDATE Voucher_OtherDetails SET VoucherID = @VoucherID,"
                         + " Particulars = @Particulars, Amount = @Amount,"
                         + "Note=@Note"
                         + " WHERE VD_ID = @VD_ID";
         dbConnection.Open();
         dbConnection.Execute(sQuery, voc);
     }
 }