added refresh frminfo on refill delete, commented out 97 on frmrefillAdd
This commit is contained in:
parent
8d24db6807
commit
f83804237c
@ -941,7 +941,7 @@ namespace Louis__Pharmacy_CNSA212_FP
|
|||||||
string rxNumString = (row.Cells[0].Value).ToString();
|
string rxNumString = (row.Cells[0].Value).ToString();
|
||||||
Int32 rxNum = Int32.Parse(rxNumString);
|
Int32 rxNum = Int32.Parse(rxNumString);
|
||||||
|
|
||||||
frmRefill refill = new frmRefill(rxNum);
|
frmRefill refill = new frmRefill(rxNum, this);
|
||||||
refill.MdiParent = MdiParent;
|
refill.MdiParent = MdiParent;
|
||||||
refill.StartPosition = FormStartPosition.CenterScreen;
|
refill.StartPosition = FormStartPosition.CenterScreen;
|
||||||
refill.Show();
|
refill.Show();
|
||||||
|
@ -19,9 +19,12 @@ namespace Louis__Pharmacy_CNSA212_FP
|
|||||||
{
|
{
|
||||||
public DataSet ds = new DataSet();
|
public DataSet ds = new DataSet();
|
||||||
private int rxNum = 0;
|
private int rxNum = 0;
|
||||||
|
private frmInfo SourceForm = new frmInfo();
|
||||||
public frmRefill(int thisRxID)
|
public frmRefill(int thisRxID, frmInfo SenderForm)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
SourceForm = SenderForm;
|
||||||
|
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
rxNum = thisRxID;
|
rxNum = thisRxID;
|
||||||
frmRefill_Load(null, null);
|
frmRefill_Load(null, null);
|
||||||
@ -44,6 +47,19 @@ namespace Louis__Pharmacy_CNSA212_FP
|
|||||||
|
|
||||||
dgvRefills.DataSource = ds.Tables[0];
|
dgvRefills.DataSource = ds.Tables[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void frmRefill_reLoad(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
int rxID = 0;
|
||||||
|
|
||||||
|
DataGridViewRow row = new DataGridViewRow();
|
||||||
|
rxID = rxNum;
|
||||||
|
|
||||||
|
DataSet ds = new DataSet();
|
||||||
|
ds = PharmacyDataTier.GetRefill(rxID.ToString());
|
||||||
|
|
||||||
|
dgvRefills.DataSource = ds.Tables[0];
|
||||||
|
}
|
||||||
|
|
||||||
private void editToolStripMenuItem_Click(object sender, EventArgs e)
|
private void editToolStripMenuItem_Click(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
@ -80,6 +96,9 @@ namespace Louis__Pharmacy_CNSA212_FP
|
|||||||
|
|
||||||
PharmacyDataTier.DeleteRefill(refillID);
|
PharmacyDataTier.DeleteRefill(refillID);
|
||||||
PharmacyDataTier.DecrementPastRefills(rxID);
|
PharmacyDataTier.DecrementPastRefills(rxID);
|
||||||
|
|
||||||
|
frmRefill_reLoad(sender, e);
|
||||||
|
SourceForm.btnPrescriptionSearch_Click(sender,e);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void refreshrefills(object sender, EventArgs e)
|
public void refreshrefills(object sender, EventArgs e)
|
||||||
|
@ -94,7 +94,7 @@ namespace Louis__Pharmacy_CNSA212_FP
|
|||||||
medicationID = txtMedicationID.Text.Trim();
|
medicationID = txtMedicationID.Text.Trim();
|
||||||
rxNum = txtRxNumber.Text.Trim();
|
rxNum = txtRxNumber.Text.Trim();
|
||||||
|
|
||||||
frmRefill refill = new frmRefill(0);
|
// frmRefill refill = new frmRefill(0, this);
|
||||||
|
|
||||||
PharmacyDataTier.UpdateRefill(refillID, date, patientID, medicationID, rxNum);
|
PharmacyDataTier.UpdateRefill(refillID, date, patientID, medicationID, rxNum);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user