public int BasicDetails(string PhoneNumber, string FullName, string EmailId, string PANCard, string AdharCard, string KYCStatus, string UserStatus) { try { RegisterModel.PhoneNumber = PhoneNumber; RegisterModel.Date = DateTime.Now; RegisterModel.Status = UserStatus; //RegisterModel.CRN = "1"; //auto increment in db BasicModel.FullName = FullName; BasicModel.EmailId = EmailId; BasicModel.PhoneNumber = PhoneNumber; BasicModel.PANCard = PANCard; BasicModel.AdharCard = AdharCard; BasicModel.KYCStatus = KYCStatus; FeeModel.PhoneNumber = PhoneNumber; FeeModel.Status = "Pending"; int response = objRegister.SaveUser(RegisterModel); objFee.SaveOneTimeFee(FeeModel); return(objBasic.SaveBasicDetails(BasicModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "BasicDetails-POST"; int error = objError.InsertError(model); return(400); } }
public string GetDetails(string PhoneNumber) { try { OneTimeFee model = new OneTimeFee(); OneTimeFee FeeRecords = objProcessing.FetchFeeDetails(PhoneNumber); if (FeeRecords == null) { return("300"); } else { model.FeeTransactionNo = FeeRecords.FeeTransactionNo; model.Date = FeeRecords.Date; model.Status = FeeRecords.Status; model.OneTimeFeeID = FeeRecords.OneTimeFeeID; model.PhoneNumber = FeeRecords.PhoneNumber; model.Fee = FeeRecords.Fee; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "OneTimeFee-Get"; int error = objError.InsertError(model); return("400"); } }
public string GetDetails(string PhoneNumber) { try { ReferenceDetail model = new ReferenceDetail(); ReferenceDetail ReferenceRecords = objReference.FetchReferenceDetails(PhoneNumber); if (ReferenceRecords == null) { return("300"); } else { model.ReferenceId = ReferenceRecords.ReferenceId; model.Reference1 = ReferenceRecords.Reference1; model.ReferenceName1 = ReferenceRecords.ReferenceName1; model.Reference2 = ReferenceRecords.Reference2; model.ReferenceName2 = ReferenceRecords.ReferenceName2; model.PhoneNumber = ReferenceRecords.PhoneNumber; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "UserReference-GET"; int error = objError.InsertError(model); return("400"); } }
public string GetDetails(string PhoneNumber) { try { ProfessionalDetail model = new ProfessionalDetail(); ProfessionalDetail ProfessionRecord = objProfession.FetchProfessionalDetails(PhoneNumber); if (ProfessionRecord == null) { return("300"); } else { model.ProfessionalDetailsId = ProfessionRecord.ProfessionalDetailsId; model.CompanyName = ProfessionRecord.CompanyName; model.MonthlyIncome = ProfessionRecord.MonthlyIncome; model.YearOfExperience = ProfessionRecord.YearOfExperience; model.CurrentEMI = ProfessionRecord.CurrentEMI; model.CompanyAddress = ProfessionRecord.CompanyAddress; model.CompanyEmailId = ProfessionRecord.CompanyEmailId; model.PhoneNumber = ProfessionRecord.PhoneNumber; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "ProfessionalDetails-Get"; int error = objError.InsertError(model); return("400"); } }
public string GetDetails(string PhoneNumber) { try { model = objNotify.FetchNotifications(PhoneNumber); foreach (var item in model) { notifyModel.NotificationId = item.NotificationId; notifyModel.PhoneNumber = item.PhoneNumber; notifyModel.Title = item.Title; notifyModel.Message = item.Message; notifyModel.Date = item.Date; Nmodel.Add(notifyModel); } string jsonResult = JsonConvert.SerializeObject(Nmodel, Formatting.Indented); return(jsonResult); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "Get Notifications"; int error = objError.InsertError(model); return("400"); } }
public string GetDetails(string PhoneNumber) { try { BasicDetail model = new BasicDetail(); BasicDetail BasicRecords = objBasic.FetchBasicDetails(PhoneNumber); if (BasicRecords == null) { return("300"); } else { model.AdharCard = BasicRecords.AdharCard; model.BasicDetailsId = BasicRecords.BasicDetailsId; model.EmailId = BasicRecords.EmailId; model.FullName = BasicRecords.FullName; model.KYCStatus = BasicRecords.KYCStatus; model.PANCard = BasicRecords.PANCard; model.PhoneNumber = BasicRecords.PhoneNumber; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "BasicDetails-GET"; int error = objError.InsertError(model); return("400"); } }
public string GetDetails(string PhoneNumber) { try { PersonalDetail model = new PersonalDetail(); PersonalDetail PersonalRecords = objPersonal.FetchPersonalDetails(PhoneNumber); if (PersonalRecords == null) { return("300"); } else { model.PersonalDetailsId = PersonalRecords.PersonalDetailsId; model.PhoneNumber = PersonalRecords.PhoneNumber; model.FatherName = PersonalRecords.FatherName; model.MotherName = PersonalRecords.MotherName; model.DOB = PersonalRecords.DOB; model.MaritalStatus = PersonalRecords.MaritalStatus; model.CurrentAddress = PersonalRecords.CurrentAddress; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "PersonalDetails-GET"; int error = objError.InsertError(model); return("400"); } }
public string GetDetails(string PhoneNumber) { try { SignatureDocument model = new SignatureDocument(); SignatureDocument Documents = objDocuments.FetchSignature(PhoneNumber); if (Documents == null) { return("300"); } else { model.SignatureId = Documents.SignatureId; model.SignatureUrl = Documents.SignatureUrl; model.PhoneNumber = Documents.PhoneNumber; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "Signature-GET"; int error = objError.InsertError(model); return("400"); } }
public int LoanDetails(string PhoneNumber, decimal LoanAmount, int InterestRate, decimal ProcessingFee, decimal LatePayment, string Duration, string LoanStatus, string DueDate) { try { LoanModel.PhoneNumber = PhoneNumber; LoanModel.LoanStatus = LoanStatus; LoanModel.LoanAmount = LoanAmount; LoanModel.InterestRate = InterestRate; LoanModel.ProcessFee = ProcessingFee; LoanModel.LatePaymentCharges = LatePayment; LoanModel.Duration = Duration; //LoanModel.DateOfLoan = Convert.ToDateTime(DateOfLoan); //LoanModel.PaymentDate = Convert.ToDateTime(PaymentDate); //LoanModel.LoanTransactionNo = "LT111"; DateTime today = DateTime.Now; LoanModel.DueDate = today.AddDays(+14); return(objLoan.SaveLoanDetails(LoanModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "LoanDetails-POST"; int error = objError.InsertError(model); return(400); } }
public string GetDetails(string PhoneNumber) { try { LoanDetail model = new LoanDetail(); LoanDetail LoanRecords = objLoan.FetchLoan(PhoneNumber); if (LoanRecords == null) { model.LoanDetailsId = 0; model.PhoneNumber = ""; model.LoanAmount = 0; model.LoanStatus = ""; model.LoanTransactionNo = ""; model.InterestRate = 0; model.LatePaymentCharges = 0; model.ProcessFee = 0; model.Duration = ""; model.DateofLoan = DateTime.Now; model.DueDate = DateTime.Now; model.PaymentDate = DateTime.Now; model.PaymentReferenceNo = ""; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } else { model.LoanDetailsId = LoanRecords.LoanDetailsId; model.PhoneNumber = LoanRecords.PhoneNumber; model.LoanAmount = LoanRecords.LoanAmount; model.LoanStatus = LoanRecords.LoanStatus; model.LoanTransactionNo = LoanRecords.LoanTransactionNo; model.InterestRate = LoanRecords.InterestRate; model.LatePaymentCharges = LoanRecords.LatePaymentCharges; model.ProcessFee = LoanRecords.ProcessFee; model.Duration = LoanRecords.Duration; model.DateofLoan = LoanRecords.DateofLoan; model.DueDate = LoanRecords.DueDate; model.PaymentDate = LoanRecords.PaymentDate; model.PaymentReferenceNo = LoanRecords.PaymentReferenceNo; string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "LoanDetails-GET"; int error = objError.InsertError(model); return("400"); } }
public int Register(string PhoneNumber) { try { return(objRegister.CheckUser(PhoneNumber)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "Register-CheckUser"; int error = objError.InsertError(model); return(400); } }
public int GetDetails(string PhoneNumber) { try { return(objLoan.VerifyLoan(PhoneNumber)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "ExistLoan-GET"; int error = objError.InsertError(model); return(400); } }
public int BankStatement(string PhoneNumber, string BankStatementUrl, string token) { try { BankStatementModel.PhoneNumber = PhoneNumber; BankStatementModel.BankstatementDocumentUrl = BankStatementUrl + "&token=" + token; return(objDocuments.UpdateBankStatement(BankStatementModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "BankStatement-POST"; int error = objError.InsertError(model); return(400); } }
public int Signature(string PhoneNumber, string SignatureUrl, string token) { try { SignatureModel.PhoneNumber = PhoneNumber; SignatureModel.SignatureUrl = SignatureUrl + "&token=" + token; return(objDocuments.UpdateSignature(SignatureModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "Signature-POST"; int error = objError.InsertError(model); return(400); } }
public int AdharCard(string PhoneNumber, string AdharCardUrl, string token) { try { AdharModel.PhoneNumber = PhoneNumber; AdharModel.AdharCardUrl = AdharCardUrl + "&token=" + token; return(objDocuments.UpdateAdharCard(AdharModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "AdharCard-POST"; int error = objError.InsertError(model); return(400); } }
public int PaySlip(string PhoneNumber, string PaySlipUrl, string token) { try { PayslipModel.PhoneNumber = PhoneNumber; PayslipModel.PaySlipUrl = PaySlipUrl + "&token=" + token; return(objDocuments.UpdatePaySlip(PayslipModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "PaySlip-POST"; int error = objError.InsertError(model); return(400); } }
public int Payment(string PhoneNumber, string ReferenceNo, string Date) { try { LoanModel.PaymentReferenceNo = ReferenceNo; LoanModel.PaymentDate = Convert.ToDateTime(Date); LoanModel.PhoneNumber = PhoneNumber; return(objPayment.UpdatePayment(LoanModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "Payment-POST"; int error = objError.InsertError(model); return(400); } }
public int Reference1(string Reference1, string Name1, string PhoneNumber) { try { ReferenceModel.PhoneNumber = PhoneNumber; ReferenceModel.Reference1 = Reference1; ReferenceModel.ReferenceName1 = Name1; return(objReference.SaveReferenceDetails1(ReferenceModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "Reference1-POST"; int error = objError.InsertError(model); return(400); } }
public int ContactUs(string PhoneNumber, string Message) { try { model.PhoneNumber = PhoneNumber; model.Message = Message; model.Date = DateTime.Now; return(objContact.SaveEnquiry(model)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "ContactUs-POST"; int error = objError.InsertError(model); return(400); } }
public int OneTimeFee(string PhoneNumber, decimal Fee, string Date, string Status, string FeeTransactionNo) { try { FeeModel.PhoneNumber = PhoneNumber; FeeModel.Date = Convert.ToDateTime(Date); FeeModel.Fee = Fee; //FeeModel.Status = Status; FeeModel.FeeTransactionNo = FeeTransactionNo; return(objProcessing.SaveOneTimeFee(FeeModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "OneTImeFee-POST"; int error = objError.InsertError(model); return(400); } }
public int PersonalDetails(string FatherName, string MotherName, string DOB, string MaritalStatus, string CurrentAddress, string PhoneNumber) { try { PersonalModel.FatherName = FatherName; PersonalModel.MotherName = MotherName; PersonalModel.DOB = DOB; PersonalModel.MaritalStatus = MaritalStatus; PersonalModel.CurrentAddress = CurrentAddress; PersonalModel.PhoneNumber = PhoneNumber; return(objPersonal.SavePersonalDetails(PersonalModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "PersonalDetails-POST"; int error = objError.InsertError(model); return(400); } }
public int ProfessionalDetails(string PhoneNumber, string CompanyName, decimal MonthlyIncome, string Experience, decimal CurrentEMI, string CompanyAddress, string CompanyEmailId) { try { ProfessionModel.PhoneNumber = PhoneNumber; ProfessionModel.CompanyName = CompanyName; ProfessionModel.CompanyEmailId = CompanyEmailId; ProfessionModel.CompanyAddress = CompanyAddress; ProfessionModel.YearOfExperience = Experience; ProfessionModel.MonthlyIncome = MonthlyIncome; ProfessionModel.CurrentEMI = CurrentEMI; return(objProfession.SaveProfessionalDetails(ProfessionModel)); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "ProfessionalDetails-POST"; int error = objError.InsertError(model); return(400); } }
public string GetDetails(string PhoneNumber) { try { AdharCardDocument doc1 = objDocuments.FetchAdharCard(PhoneNumber); PANCardDocument doc2 = objDocuments.FetchPANCard(PhoneNumber); IDCardDocument doc3 = objDocuments.FetchIDCard(PhoneNumber); PaySlipDocument doc4 = objDocuments.FetchPaySlip(PhoneNumber); BankstatementDocument doc5 = objDocuments.FetchBankStatement(PhoneNumber); SelfieDocument doc6 = objDocuments.FetchSelfie(PhoneNumber); SignatureDocument doc7 = objDocuments.FetchSignature(PhoneNumber); string DefaultURL = "https://firebasestorage.googleapis.com/v0/b/totaq-6155d.appspot.com/o/noimage.png?alt=media&token=fe4a3c0f-e6f9-497f-827d-a9e0906ccf6b"; if (doc1 == null) { model.AdharCard = DefaultURL; } else { model.AdharCard = doc1.AdharCardUrl; } if (doc2 == null) { model.PANCard = DefaultURL; } else { model.PANCard = doc2.PANCardUrl; } if (doc3 == null) { model.IDCard = DefaultURL; } else { model.IDCard = doc3.IDCardUrl; } if (doc4 == null) { model.PaySlip = DefaultURL; } else { model.PaySlip = doc4.PaySlipUrl; } if (doc5 == null) { model.BankStatement = DefaultURL; } else { model.BankStatement = doc5.BankstatementDocumentUrl; } if (doc6 == null) { model.Selfie = DefaultURL; } else { model.Selfie = doc6.SelfieUrl; } if (doc7 == null) { model.Signature = DefaultURL; } else { model.Signature = doc7.SignatureUrl; } string jsonResult = JsonConvert.SerializeObject(model, Formatting.Indented); return(jsonResult); } catch (Exception ex) { ErrorLogDal objError = new ErrorLogDal(); ErrorLog model = new ErrorLog(); model.InnerException = ex.InnerException.InnerException.Message.ToString(); model.Source = "Documents-Get"; int error = objError.InsertError(model); return("400"); } }