Commit e89870e9 authored by Krishna Reddy Tamatam's avatar Krishna Reddy Tamatam

FOr v2.0 host

parent a51e4ea1
...@@ -51,6 +51,23 @@ namespace FTP_Services.Services.Controllers ...@@ -51,6 +51,23 @@ namespace FTP_Services.Services.Controllers
} }
} }
[HttpGet("GetSearchedHistoryPatients")]
public IActionResult GetSearchedHistoryPatients(string SearchText, int ProviderId, int LocationId, int DateType, string StartDate, string EndDate)
{
log.Debug("GetSearchedPatients ==> ");
try
{
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
// List<SearchPatients>? RequestsList = adapter.SearchedPatientsData(SearchText);
List<object>? RequestsList = adapter.SearchedPatientsHistoryData(SearchText, ProviderId, LocationId, DateType, StartDate, EndDate);
return Ok(RequestsList);
}
catch (Exception ex)
{
log.Error("Fail to get data for search patients - Error:" + ex.Message);
return NotFound("No results");
}
}
[HttpGet("GetSearchedPatients")] [HttpGet("GetSearchedPatients")]
public IActionResult GetSearchedPatients(string SearchText, int ProviderId, int LocationId, int DateType, string StartDate, string EndDate, int DischType) public IActionResult GetSearchedPatients(string SearchText, int ProviderId, int LocationId, int DateType, string StartDate, string EndDate, int DischType)
{ {
...@@ -69,6 +86,23 @@ namespace FTP_Services.Services.Controllers ...@@ -69,6 +86,23 @@ namespace FTP_Services.Services.Controllers
} }
} }
[HttpGet("GetAdmissionDataHistory")]
public IActionResult GetAdmissionDataHistory(int PatientID, int LocationID, int ProviderID, int DateType, string StartDate, string EndDate)
{
log.Debug("GetAdmissionDataHistory ==> ");
try
{
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
List<object>? RequestsList = adapter.GetAdmissionDataHistory(PatientID, LocationID, ProviderID, DateType, StartDate, EndDate);
return Ok(RequestsList);
}
catch (Exception ex)
{
log.Error("Fail to get data for GetAdmissionDataHistory - Error:" + ex.Message);
return NotFound("No results");
}
}
[HttpGet("GetAdmissionData")] [HttpGet("GetAdmissionData")]
public IActionResult GetAdmissionData(int PatientID, int LocationID, int ProviderID, int DateType, string StartDate, string EndDate, int DischType) public IActionResult GetAdmissionData(int PatientID, int LocationID, int ProviderID, int DateType, string StartDate, string EndDate, int DischType)
{ {
...@@ -86,35 +120,35 @@ namespace FTP_Services.Services.Controllers ...@@ -86,35 +120,35 @@ namespace FTP_Services.Services.Controllers
} }
} }
[HttpGet("LoadPhysicians")] [HttpGet("LoadPhysicians")]
public IActionResult GetLoadPhysicians(int LocationId) public IActionResult GetLoadPhysicians(int LocationId,Boolean IsOldData)
{ {
log.Debug("LoadPhysicians ==> "); log.Debug("LoadPhysicians ==> ");
try try
{ {
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings); FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
List<object>? RequestsList = adapter.GeLoadPhysicians(LocationId); List<object>? RequestsList = adapter.GeLoadPhysicians(LocationId,IsOldData);
return Ok(RequestsList); return Ok(RequestsList);
} }
catch (Exception ex) catch (Exception ex)
{ {
log.Error("Fail to get data for Admissions - Error:" + ex.Message); log.Error("Fail to get data for GetLoadPhysicians - Error:" + ex.Message);
return NotFound("No results"); return NotFound("No results");
} }
} }
[HttpGet("GetLocations")] [HttpGet("GetLocations")]
public IActionResult GetLocations(Boolean IsLoadAll) //int LocationId, public IActionResult GetLocations(Boolean IsLoadAll,Boolean IsOldData) //int LocationId,
{ {
log.Debug("GetLocations ==> "); log.Debug("GetLocations ==> ");
try try
{ {
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings); FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
List<object>? RequestsList = adapter.LoadLocations(IsLoadAll);//LocationId, List<object>? RequestsList = adapter.LoadLocations(IsLoadAll,IsOldData);//LocationId,
return Ok(RequestsList); return Ok(RequestsList);
} }
catch (Exception ex) catch (Exception ex)
{ {
log.Error("Fail to get data for search patients - Error:" + ex.Message); log.Error("Fail to get data for GetLocations - Error:" + ex.Message);
return NotFound("No results"); return NotFound("No results");
} }
} }
...@@ -199,7 +233,7 @@ namespace FTP_Services.Services.Controllers ...@@ -199,7 +233,7 @@ namespace FTP_Services.Services.Controllers
return NotFound("No results"); return NotFound("No results");
} }
} }
[HttpGet("GetProcedures")] [HttpGet("GetProcedures")]
public IActionResult GetProcedures() public IActionResult GetProcedures()
{ {
log.Debug("GetProcedures ==> "); log.Debug("GetProcedures ==> ");
...@@ -272,13 +306,13 @@ namespace FTP_Services.Services.Controllers ...@@ -272,13 +306,13 @@ namespace FTP_Services.Services.Controllers
} }
[HttpGet("GetPatientDocuments")] [HttpGet("GetPatientDocuments")]
public IActionResult GetPatientDocuments(int SPatientID, int SLocationID,int SAppointmentID,int SAdmissionID,int SDocID,string SDueFrom,string SDueTO) public IActionResult GetPatientDocuments(int SPatientID, int SLocationID, int SAppointmentID, int SAdmissionID, int SDocID, string SDueFrom, string SDueTO)
{ {
log.Debug("GetPatientDocuments ==> "); log.Debug("GetPatientDocuments ==> ");
try try
{ {
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings); FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
List<object>? RequestsList = adapter.PatientDocuments(SPatientID, SLocationID,SAppointmentID,SAdmissionID,SDocID, SDueFrom, SDueTO); List<object>? RequestsList = adapter.PatientDocuments(SPatientID, SLocationID, SAppointmentID, SAdmissionID, SDocID, SDueFrom, SDueTO);
return Ok(RequestsList); return Ok(RequestsList);
} }
catch (Exception ex) catch (Exception ex)
...@@ -305,13 +339,13 @@ namespace FTP_Services.Services.Controllers ...@@ -305,13 +339,13 @@ namespace FTP_Services.Services.Controllers
} }
} }
[HttpGet("GetAdmissionDischargeData")] [HttpGet("GetAdmissionDischargeData")]
public IActionResult GetAdmissionDischargeData(int SndAdmissionID) public IActionResult GetAdmissionDischargeData(int SndAdmissionID,int SndIsOldData)
{ {
log.Debug("GetPatientAdmissions ==> "); log.Debug("GetPatientAdmissions ==> ");
try try
{ {
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings); FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
List<object>? RequestsList = adapter.AdmissionDischargeData(SndAdmissionID); List<object>? RequestsList = adapter.AdmissionDischargeData(SndAdmissionID,SndIsOldData);
return Ok(RequestsList); return Ok(RequestsList);
} }
catch (Exception ex) catch (Exception ex)
...@@ -338,13 +372,13 @@ namespace FTP_Services.Services.Controllers ...@@ -338,13 +372,13 @@ namespace FTP_Services.Services.Controllers
// } // }
[HttpPost("UpdateImageCategory")] [HttpPost("UpdateImageCategory")]
public int UpdateImageCategory(int sndPatDocId,int sndDocTypeId,int sndUserID) public int UpdateImageCategory(int sndPatDocId, int sndDocTypeId, int sndUserID)
{ {
int savedCount = 0; int savedCount = 0;
try try
{ {
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings); FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
savedCount = adapter.UpdateImageCategory(sndPatDocId,sndDocTypeId,sndUserID); savedCount = adapter.UpdateImageCategory(sndPatDocId, sndDocTypeId, sndUserID);
} }
catch (Exception ex) catch (Exception ex)
{ {
...@@ -354,7 +388,7 @@ namespace FTP_Services.Services.Controllers ...@@ -354,7 +388,7 @@ namespace FTP_Services.Services.Controllers
} }
[HttpPost("UpdateImageSortNo")] [HttpPost("UpdateImageSortNo")]
public int UpdateImageSortNo ([FromBody] PatientImgDocSort PatImgDoc) public int UpdateImageSortNo([FromBody] PatientImgDocSort PatImgDoc)
{ {
int savedCount = 0; int savedCount = 0;
try try
...@@ -418,7 +452,7 @@ namespace FTP_Services.Services.Controllers ...@@ -418,7 +452,7 @@ namespace FTP_Services.Services.Controllers
return StatusCode(500, "Internal server error"); return StatusCode(500, "Internal server error");
} }
} }
...@@ -567,14 +601,14 @@ namespace FTP_Services.Services.Controllers ...@@ -567,14 +601,14 @@ namespace FTP_Services.Services.Controllers
// } // }
[HttpPost("DeletePatientDocument")] [HttpPost("DeletePatientDocument")]
public string DeletePatientDocument(int DocumentID, int UserID) public string DeletePatientDocument(int AdmissionId, int DocumentID, int UserID,int SndIsOldData)
{ {
log.Debug("DeletePatientDocument ==> "); log.Debug("DeletePatientDocument ==> ");
string DeletePT = ""; string DeletePT = "";
try try
{ {
FTPDataAdapter adapter = new FTPDataAdapter(_appSettings); FTPDataAdapter adapter = new FTPDataAdapter(_appSettings);
DeletePT = adapter.DeletePatientDocumentData(DocumentID, UserID); DeletePT = adapter.DeletePatientDocumentData(AdmissionId, DocumentID, UserID,SndIsOldData);
} }
catch (Exception ex) catch (Exception ex)
{ {
......
...@@ -16,7 +16,7 @@ namespace FTP_Services.Core.Models ...@@ -16,7 +16,7 @@ namespace FTP_Services.Core.Models
public string UploadedDate { get; set; } public string UploadedDate { get; set; }
public int AdmissionID { get; set; } public int AdmissionID { get; set; }
public int SortNo { get; set; } public int SortNo { get; set; }
public int IsOldData{get; set; }
public PatientDocumentDetailsModel() public PatientDocumentDetailsModel()
{ {
...@@ -33,7 +33,8 @@ namespace FTP_Services.Core.Models ...@@ -33,7 +33,8 @@ namespace FTP_Services.Core.Models
PatDocId = 0; PatDocId = 0;
UploadedDate = ""; UploadedDate = "";
AdmissionID = 0; AdmissionID = 0;
SortNo =1; SortNo = 1;
IsOldData = 1;
} }
} }
...@@ -260,7 +261,7 @@ namespace FTP_Services.Core.Models ...@@ -260,7 +261,7 @@ namespace FTP_Services.Core.Models
public int AdmissionTypeId { get; set; } public int AdmissionTypeId { get; set; }
public DateTime? DischargeDate { get; set; } public DateTime? DischargeDate { get; set; }
//public int DischargeTypeId { get; set; } //public int DischargeTypeId { get; set; }
public string DischargeType { get; set; } public string DischargeType { get; set; }
public string Cause { get; set; } public string Cause { get; set; }
public int UserId { get; set; } public int UserId { get; set; }
public bool IsWardChanged { get; set; } public bool IsWardChanged { get; set; }
...@@ -271,6 +272,8 @@ namespace FTP_Services.Core.Models ...@@ -271,6 +272,8 @@ namespace FTP_Services.Core.Models
public List<ProcedureModel> Procedures { get; set; } public List<ProcedureModel> Procedures { get; set; }
public string Diagnosis { get; set; } public string Diagnosis { get; set; }
public string MRD_OtherProcedures { get; set; } public string MRD_OtherProcedures { get; set; }
public int IsOldData { get; set; }
} }
// Supporting Models // Supporting Models
......
...@@ -138,7 +138,7 @@ if (app.Environment.IsDevelopment()) ...@@ -138,7 +138,7 @@ if (app.Environment.IsDevelopment())
} }
else else
{ {
app.Run(); //For Test Site //app.Run(); //For Test Site
app.Run("http://*:4708"); // For Production app.Run("http://*:4708"); // For Production
//app.Run("http://*:4709"); // For Admin //app.Run("http://*:4709"); // For Admin
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment