Exemple #1
0
        public string AddPharmacy(EmanifestPhmc pcm)
        {
            string result = "";

            try
            {
                string query = string.Format(dbQueries.sqlAddPh_Emanifest, pcm.Pharmacy, pcm.Pharmacyname, pcm.Address1, string.IsNullOrEmpty(pcm.Address2) ? "" : pcm.Address2, string.IsNullOrEmpty(pcm.City) ? "" : pcm.City,
                                             pcm.State, string.IsNullOrEmpty(pcm.Phone) ? "" : pcm.Phone, string.IsNullOrEmpty(pcm.Fax) ? "" : pcm.Fax, pcm.ZipCode, string.IsNullOrEmpty(pcm.DocuTrackEmail) ? "" : pcm.DocuTrackEmail);
                result = GetValue(query, "Emanifest");
            }
            catch (Exception ex)
            {
                return("Please try after some time, If it repeats please reach support team.");
            }
            return(result);
        }
Exemple #2
0
 public ActionResult AddPharmEmanifest(EmanifestPhmc emainfest)
 {
     TempData["data"] = "";
     if (ModelState.IsValid)
     {
         TempData["data"] = dbCommon.AddPharmacy(emainfest);
     }
     if (TempData["data"].ToString() == DBQueries.msgPharmacyCreationSuccess)
     {
         return(RedirectToAction("PharmacyCreation", new { view = "EmanifestPhmc" }));
     }
     else
     {
         return(View("EmanifestPhmc", emainfest));
     }
 }