public ActionResult IndexDataImportHandling(OISettingEntity model) { if (!string.IsNullOrEmpty(model.ORB_DATA_IMPORT_DUPLICATE_RESOLUTION)) { OISettingFacade fac = new OISettingFacade(this.CurrentClient.ApplicationDBConnectionString); fac.UpdateOrbDataImportHandling(model, "OrbDataImportHandling"); return(Json(new { result = true, message = DandBSettingLang.msgSettingUpdate }, JsonRequestBehavior.AllowGet)); } else { return(Json(new { result = true, message = DandBSettingLang.msgInvadilState }, JsonRequestBehavior.AllowGet)); } }
public static SelectList GetAllOrbTags(string ConnectionString, string LobTag = "", string SecurityTag = "") { OISettingFacade fac = new OISettingFacade(ConnectionString); DataTable dt = fac.GetAllOrbTags(LobTag, SecurityTag, Helper.oUser != null ? Convert.ToString(Helper.oUser.UserId) : ""); List <SelectListItem> lstTags = new List <SelectListItem>(); for (int i = 0; i < dt.Rows.Count; i++) { lstTags.Add(new SelectListItem { Value = dt.Rows[i]["Tag"].ToString(), Text = dt.Rows[i]["TagName"].ToString() }); } return(new SelectList(lstTags, "Value", "Text")); }
public ActionResult OIBackgroundProcessSettings(OISettingEntity model) { if (!string.IsNullOrEmpty(model.ORB_BATCH_SIZE) && !string.IsNullOrEmpty(model.ORB_BATCH_WAITTIME_SECS) && !string.IsNullOrEmpty(model.ORB_MAX_PARALLEL_THREADS)) { OISettingFacade fac = new OISettingFacade(this.CurrentClient.ApplicationDBConnectionString); fac.UpdateOrbBackgroundSetting(model, "OrbBackgroundSetting"); Helper.IsEnableCorporateTreeEnrichment = model.ORB_ENABLE_CORPORATE_TREE_ENRICHMENT; return(Json(new { result = true, message = DandBSettingLang.msgSettingUpdate }, JsonRequestBehavior.AllowGet)); } else { return(Json(new { result = true, message = DandBSettingLang.msgInvadilState }, JsonRequestBehavior.AllowGet)); } }
public JsonResult ResetOISystemsData() { try { OISettingFacade fac = new OISettingFacade(this.CurrentClient.ApplicationDBConnectionString); // Reset System Data fac.ResetOISystemData(); return(new JsonResult { Data = DandBSettingLang.msgResetDataSuccessfully }); } catch (Exception ex) { return(new JsonResult { Data = DandBSettingLang.msgResetDataUnsuccessfully }); } }
public ActionResult IndexOILicense(OISettingEntity model) { if (!string.IsNullOrEmpty(model.ORB_API_KEY)) { //Update API License in Main Portal DB OISettingFacade fac = new OISettingFacade(this.CurrentClient.ApplicationDBConnectionString); fac.UpdateOrbCredentials(model, "OrbCredentialsSetting"); //OI - License management for OI API. (MP-590) //Update API License in ClientMasert DB fac = new OISettingFacade(StringCipher.Decrypt(Helper.GetMasterConnctionstring(), General.passPhrase)); //Get SubDomain string[] hostParts = new System.Uri(Request.Url.AbsoluteUri).Host.Split('.'); string SubDomain = hostParts[0]; fac.UpdateOIAPILicenseForClients(SubDomain, model.ORB_API_KEY); // MP-846 Admin database cleanup and code cleanup.-CLIENT return(Json(new { result = true, message = DandBSettingLang.msgSettingUpdate }, JsonRequestBehavior.AllowGet)); } else { return(Json(new { result = true, message = DandBSettingLang.msgInvadilState }, JsonRequestBehavior.AllowGet)); } }
//Get columns names for display in mapping public List <string> GetcolumnName(string ImportType, string ConnectionString) { SettingFacade sfac = new SettingFacade(ConnectionString); DataTable dtInpCompany = new DataTable(); List <string> columnName = new List <string>(); if (ImportType.ToLower().Trim() == "match refresh") { dtInpCompany = sfac.GetImportDataRefreshColumnsName(); } else if (ImportType.ToLower().Trim() == "data import") { dtInpCompany = sfac.GetInpCompanyColumnsName(); } else if (ImportType.ToLower().Trim() == "orb data import") { OIImportDataFacade orbfac = new OIImportDataFacade(this.CurrentClient.ApplicationDBConnectionString); dtInpCompany = orbfac.GetOIStgInputCompanyColumnsName(); } //added orb enrichment only dropdown in upload configuration else if (ImportType.ToLower().Trim() == "orb match refresh") { OISettingFacade oisfac = new OISettingFacade(this.CurrentClient.ApplicationDBConnectionString); dtInpCompany = oisfac.GetOIImportDataColumnsName(); } if (dtInpCompany.Rows.Count > 0) { for (int k = 0; k < dtInpCompany.Rows.Count; k++) //loop through the columns. { if (Convert.ToString(dtInpCompany.Rows[k][0]) != "ImportRowId" && Convert.ToString(dtInpCompany.Rows[k][0]) != "ImportProcessId") { if (ImportType.ToLower().Trim() == "orb data import" || ImportType.ToLower().Trim() == "orb match refresh") { if (Convert.ToString(dtInpCompany.Rows[k][0]) == "Address1") { columnName.Add("Street Line Address1"); } else if (Convert.ToString(dtInpCompany.Rows[k][0]) == "Address2") { columnName.Add("Street Line Address2"); } else if (Convert.ToString(dtInpCompany.Rows[k][0]) == "AltAddress1") { columnName.Add("Street Line Alt. Address1"); } else if (Convert.ToString(dtInpCompany.Rows[k][0]) == "AltAddress2") { columnName.Add("Street Line Alt. Address2"); } else { columnName.Add(Convert.ToString(dtInpCompany.Rows[k][0])); } } else { if (Convert.ToString(dtInpCompany.Rows[k][0]) == "Address") { columnName.Add("Street Line Address1"); } else if (Convert.ToString(dtInpCompany.Rows[k][0]) == "Address1") { columnName.Add("Street Line Address2"); } else if (Convert.ToString(dtInpCompany.Rows[k][0]) == "AltAddress") { columnName.Add("Street Line Alt. Address1"); } else if (Convert.ToString(dtInpCompany.Rows[k][0]) == "AltAddress1") { columnName.Add("Street Line Alt. Address2"); } else { columnName.Add(Convert.ToString(dtInpCompany.Rows[k][0])); } } } } } return(columnName); }