Beispiel #1
0
        /// <summary>
        /// 退单方法
        /// </summary>
        private void MethodTuiDan()
        {
            if (lblPatient.Text == "")
            {
                Mes.ShowDialog("提示", "当前没有处方");
                return;
            }
            if (PrescriptionID == "")
            {
                Mes.ShowDialog("提示", "请选择处方!");
                return;
            }

            BPConfirm b = new BPConfirm(btnTuiDan.Text, "不通过", PrescriptionID, DEmployeeID);

            if (b.ShowDialog() == DialogResult.OK)
            {
                try
                {
                    string str = "EXEC bl_backPrescription " + PrescriptionID + ",'" + b.eid + "','" + b.DoctorExplain + "'";
                    dbHelp.SetPIVAsDB(str);

                    string s = "SHJJ";
                    bPre.PivasRevPreFalse(lblGroupNo.Text, b.ecode, out s);
                    CheckPre.PREID = "";
                    CheckPre cp = (CheckPre)this.Parent.Parent.Parent.Parent;

                    if (cp.ckFlag == 0)
                    {
                        cp.GetSelPrescriptions();
                        //审方结束后的刷新操作
                        if (cp.dgvResult.Rows.Count > 0)
                        {
                        }
                        else
                        {
                            cp.getWards();
                        }
                    }
                    else
                    {
                        cp.GetSelPrescriptions(cp.ckID);
                        //审方结束后的刷新操作
                        if (cp.dgvResult.Rows.Count > 0)
                        {
                        }
                        else
                        {
                            cp.getWards();
                        }
                    }
                }
                catch (System.Exception ex)
                {
                    MessageBox.Show(ex.Message);
                }
            }
        }
Beispiel #2
0
        /// <summary>
        /// 重审方法
        /// </summary>
        private void MethodReCheck()
        {
            try
            {
                if (PrescriptionID == "")
                {
                    MessageBox.Show("请选处方!");
                    return;
                }

                if (Mes.ShowDialog("提示", "重审会覆盖之前的结果,确定要重审吗?") == DialogResult.Cancel)
                {
                    return;
                }
                string str = "EXEC [bl_Remonitor] '" + PrescriptionID + "'";
                dbHelp.SetPIVAsDB(str);
                dbHelp.SetPIVAsDB("DELETE FROM BPRecord WHERE PrescriptionID =  '" + PrescriptionID + "' ");
                CheckPre.PREID = PrescriptionID;
                CheckPre cp = (CheckPre)this.Parent.Parent.Parent.Parent;
                cp.GetSelPrescriptions();
                if (cp.dgvResult.Rows.Count > 0)
                {
                    //不需要刷新病区
                }
                else
                {
                    cp.getWards();//刷新病区
                }
            }
            catch (System.Exception ex)
            {
                MessageBox.Show(ex.Message);
            }
        }
Beispiel #3
0
        private void linkLabel1_Click(object sender, EventArgs e)
        {
            if (lblPatient.Text == "")
            {
                Mes.ShowDialog("提示", "当前没有处方");
                return;
            }
            if (PrescriptionID == "")
            {
                MessageBox.Show("请选择处方!");
                return;
            }

            string sql = "select *from Prescription  where PStatus<2 and PrescriptionID='" + PrescriptionID + "'";

            DataSet ds = dbHelp.GetPIVAsDB(sql);

            if (ds != null && ds.Tables[0].Rows.Count > 0)
            {
                if (Mes.ShowDialog("提示", "该操作不可逆,是否确定删除处方?") == DialogResult.Cancel)
                {
                    return;
                }

                int a = dbHelp.SetPIVAsDB(SQLStr.DeletePrescription(PrescriptionID));
                if (a > 0)
                {
                    MessageBox.Show("删除完成");
                }

                CheckPre.PREID = "";
                CheckPre cp = (CheckPre)this.Parent.Parent.Parent.Parent;

                cp.GetSelPrescriptions();
                //审方结束后的刷新操作

                cp.getWards();
            }
            else
            {
                MessageBox.Show("该处方正在执行,不能删除");
            }
        }