예제 #1
0
        public bool EditDrugBatch(DrugBatch drugBatch)
        {
            DrugBatch ret = DrugBatchRepository.GetInstance().Update(drugBatch);

            if (ret != null)
            {
                return(true);
            }
            else
            {
                return(false);
            }
        }
예제 #2
0
        public List <DrugBatch> getPharmacyDrugBatch(string DrugPk)
        {
            lock (this)
            {
                ClsObject PatientEncounter = new ClsObject();
                ClsUtility.Init_Hashtable();
                ClsUtility.AddParameters("@DrugPk", SqlDbType.Int, DrugPk);

                DataTable theDT = (DataTable)PatientEncounter.ReturnObject(ClsUtility.theParams, "sp_getPharmacyBatch", ClsUtility.ObjectEnum.DataTable);

                List <DrugBatch> list = new List <DrugBatch>();

                for (int i = 0; i < theDT.Rows.Count; i++)
                {
                    DrugBatch drg = new DrugBatch();
                    drg.id    = theDT.Rows[i]["id"].ToString();
                    drg.batch = theDT.Rows[i]["Name"].ToString();
                    list.Add(drg);
                }

                return(list);
            }
        }
예제 #3
0
 public bool EditDrugBatch(DrugBatch drugBatch)
 {
     return(iDrugService.EditDrugBatch(drugBatch));
 }
예제 #4
0
 public bool DeleteDrugBatch(DrugBatch drugBatch)
 {
     return(iDrugService.DeleteDrugBatch(drugBatch));
 }
예제 #5
0
 public DrugBatch AddDrugBatch(DrugBatch drugBatch)
 {
     return(iDrugService.AddDrugBatch(drugBatch));
 }
예제 #6
0
 public DrugIncrementerViewModel(Drug drug, ILogWriter logWriter)
 {
     _logWriter = logWriter;
     batch      = new DrugBatch(drug);
 }
예제 #7
0
 public DrugIncrementerViewModel()
 {
     batch = new DrugBatch();
 }
예제 #8
0
 public bool DeleteDrugBatch(DrugBatch drugBatch)
 {
     return(DrugBatchRepository.GetInstance().Delete(drugBatch.DrugId));
 }
예제 #9
0
 public DrugBatch AddDrugBatch(DrugBatch drugBatch)
 {
     return(DrugBatchRepository.GetInstance().Create(drugBatch));
 }