示例#1
0
 private void butDelete_Click(object sender, System.EventArgs e)
 {
     if (IsNew)
     {
         DialogResult = DialogResult.Cancel;
     }
     else
     {
         //SecurityLogs.MakeLogEntry("Adjustment Edit","Delete. patNum: "+Adjustments.Cur.PatNum.ToString());
         Commlogs.Delete(CommlogCur);
         DialogResult = DialogResult.OK;
     }
 }
示例#2
0
 private void butDelete_Click(object sender, System.EventArgs e)
 {
     //button not enabled if no permission
     if (IsNew)
     {
         DialogResult = DialogResult.Cancel;
         return;
     }
     if (!MsgBox.Show(this, MsgBoxButtons.OKCancel, "Delete?"))
     {
         return;
     }
     SecurityLogs.MakeLogEntry(Permissions.CommlogEdit, CommlogCur.PatNum, "Delete");
     Commlogs.Delete(CommlogCur);
     DialogResult = DialogResult.OK;
 }
示例#3
0
 ///<summary>Tries to delete the commlog passed in.  Throws exceptions if anything goes wrong.</summary>
 private void DeleteCommlog(Commlog commlog, string logText = "Delete")
 {
     Commlogs.Delete(commlog);
     SecurityLogs.MakeLogEntry(Permissions.CommlogEdit, commlog.PatNum, logText);
 }