private bool DeleteAuthor() { try { BUS_TacGia deleteAuthor = new BUS_TacGia(); deleteAuthor.deleteTacGia(this.authorId); return(true); } catch (Exception e) { return(false); } }
private bool InsertAuthor() { try { BUS_TacGia insertAuthor = new BUS_TacGia(); int gioitinh = 1; if (radGTMale.Checked == false) { gioitinh = 0; } DTO_Tacgia dtoAuthor = new DTO_Tacgia(0, txtAuthorName.Text, dtpNgaySinh.Value.ToString("MM/dd/yyyy"), gioitinh); insertAuthor.insertTacGia(dtoAuthor); return(true); } catch (Exception e) { return(false); } }