Initial commit , susee
This commit is contained in:
parent
1a45d222c8
commit
7f207916bd
53
.gitignore
vendored
53
.gitignore
vendored
@ -1,50 +1,3 @@
|
||||
# These are some examples of commonly ignored file patterns.
|
||||
# You should customize this list as applicable to your project.
|
||||
# Learn more about .gitignore:
|
||||
# https://www.atlassian.com/git/tutorials/saving-changes/gitignore
|
||||
|
||||
# Node artifact files
|
||||
node_modules/
|
||||
dist/
|
||||
|
||||
# Compiled Java class files
|
||||
*.class
|
||||
|
||||
# Compiled Python bytecode
|
||||
*.py[cod]
|
||||
|
||||
# Log files
|
||||
*.log
|
||||
|
||||
# Package files
|
||||
*.jar
|
||||
|
||||
# Maven
|
||||
target/
|
||||
dist/
|
||||
|
||||
# JetBrains IDE
|
||||
.idea/
|
||||
|
||||
# Unit test reports
|
||||
TEST*.xml
|
||||
|
||||
# Generated by MacOS
|
||||
.DS_Store
|
||||
|
||||
# Generated by Windows
|
||||
Thumbs.db
|
||||
|
||||
# Applications
|
||||
*.app
|
||||
*.exe
|
||||
*.war
|
||||
|
||||
# Large media files
|
||||
*.mp4
|
||||
*.tiff
|
||||
*.avi
|
||||
*.flv
|
||||
*.mov
|
||||
*.wmv
|
||||
|
||||
/node_modules
|
||||
/storage
|
||||
.env
|
||||
16
app/config/db.config.js
Normal file
16
app/config/db.config.js
Normal file
@ -0,0 +1,16 @@
|
||||
require('dotenv').config();
|
||||
|
||||
const { logMsg } = require('../services/logger');
|
||||
module.exports = {
|
||||
|
||||
"development": {
|
||||
"username": process.env.USER_NAME,
|
||||
"password": process.env.PASSWORD,
|
||||
"database": process.env.DATABASE,
|
||||
"port": process.env.PORT,
|
||||
"host": process.env.HOST,
|
||||
"dialect": "mssql",
|
||||
"logging": (message) =>(logMsg.info(message))
|
||||
|
||||
}
|
||||
};
|
||||
20
app/controllers/test.controller.js
Normal file
20
app/controllers/test.controller.js
Normal file
@ -0,0 +1,20 @@
|
||||
const { sequelize,Test} = require('../models')
|
||||
const { logMsg } = require('../services/logger.js');
|
||||
|
||||
exports.Welcome = (req, res) =>
|
||||
{
|
||||
try
|
||||
{
|
||||
const Msg = "Welcome....!";
|
||||
console.log(Msg);
|
||||
logMsg.info("Api Call Success");
|
||||
res.send({'status':200 , message:"Success." ,'data': Msg});
|
||||
|
||||
} catch(err) {
|
||||
res.status(500).send({'status':404,
|
||||
message: err.message || "Some error occurred while inserting statements." ,'data': "No data"
|
||||
}); } //end of try catch
|
||||
|
||||
};
|
||||
|
||||
|
||||
27
app/models/AcHistoryAndDPD.js
Normal file
27
app/models/AcHistoryAndDPD.js
Normal file
@ -0,0 +1,27 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class AcHistoryAndDPD extends Model {
|
||||
|
||||
}
|
||||
AcHistoryAndDPD.init(
|
||||
|
||||
{
|
||||
temp_id: { type: DataTypes.INTEGER },
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
BorrowerCurrentDetailsID: { type: DataTypes.INTEGER },
|
||||
CFHistory24Monthsmonth: { type: DataTypes.DATE },
|
||||
CFHistory24MonthsACorDPD: { type: DataTypes.STRING },
|
||||
CFHistory24MonthsOSAmount: { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_ac_history_and_dpd',
|
||||
modelName: 'AcHistoryAndDPD',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return AcHistoryAndDPD
|
||||
}
|
||||
272
app/models/BorrowerProfile.js
Normal file
272
app/models/BorrowerProfile.js
Normal file
@ -0,0 +1,272 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class BorrowerProfile extends Model {
|
||||
|
||||
}
|
||||
BorrowerProfile.init(
|
||||
{
|
||||
temp_id : { type: DataTypes.INTEGER },
|
||||
ApplicationRefno : { type: DataTypes.INTEGER },
|
||||
ReportIssuesCode : { type: DataTypes.STRING },
|
||||
ReportIssuesMsg : { type: DataTypes.STRING },
|
||||
ReportIssuesDescription : { type: DataTypes.STRING },
|
||||
ReportHeaderDaysPasswrdToExpire : { type: DataTypes.STRING },
|
||||
ReportHeaderReportOrderNo : { type: DataTypes.STRING },
|
||||
ReportHeaderReportOrderedBy : { type: DataTypes.STRING },
|
||||
ReportHeaderMemberDetails : { type: DataTypes.STRING },
|
||||
ReportHeaderApplicationRefNo : { type: DataTypes.INTEGER },
|
||||
ReportHeaderMemberRefNo : { type: DataTypes.STRING },
|
||||
ReportHeaderInquiryPurpose : { type: DataTypes.STRING },
|
||||
EnqInfoBorrowerName : { type: DataTypes.STRING },
|
||||
EnqInfoPan : { type: DataTypes.STRING },
|
||||
EnqInfoCin : { type: DataTypes.STRING },
|
||||
EnqInfoTin : { type: DataTypes.STRING },
|
||||
EnqInfoCrn : { type: DataTypes.STRING },
|
||||
EnqInfoAddressCount : { type: DataTypes.INTEGER },
|
||||
EnqInfoAddressAddressLine0 : { type: DataTypes.STRING },
|
||||
EnqInfoAddressAddressLine1 : { type: DataTypes.STRING },
|
||||
EnqInfoAddressAddressLine2 : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDName : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDBLC : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDClassOfActivity0 : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDClassOfActivity1 : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDClassOfActivity2 : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDBusinessCatg : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDBusinessIndustryType : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDSalesFigure : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDNoOfEmp : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDYear : { type: DataTypes.STRING },
|
||||
BorrowerProfileBACDRegaddress : { type: DataTypes.STRING },
|
||||
BorrowerProfileBACDTelephoneNo : { type: DataTypes.INTEGER },
|
||||
BorrowerProfileBACDfaxNo : { type: DataTypes.STRING },
|
||||
BorrowerProfileBACDMobileNo : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDRInstCurrent : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDRInstLst24Mnths : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDROutCurrent : { type: DataTypes.STRING },
|
||||
BorrowerProfileBDROutLst24Mnths : { type: DataTypes.STRING },
|
||||
RankName : { type: DataTypes.STRING },
|
||||
RankValue : { type: DataTypes.STRING },
|
||||
RankExclusionReason : { type: DataTypes.STRING },
|
||||
RankMessage : { type: DataTypes.STRING },
|
||||
CPSInstMsg : { type: DataTypes.STRING },
|
||||
CPSInstTotalLenders : { type: DataTypes.INTEGER },
|
||||
CPSInsttotalCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSInsttotalCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSInsttotalCFBP : { type: DataTypes.STRING },
|
||||
CPSInstTotalCFGP : { type: DataTypes.STRING },
|
||||
CPSInstOpenCF : { type: DataTypes.INTEGER },
|
||||
CPSInsTotalOutstandingBorrower : { type: DataTypes.INTEGER },
|
||||
CPSInsTotalOutstandingGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSInsTotalOutstandingBP : { type: DataTypes.INTEGER },
|
||||
CPSInsTotalOutstandingGP : { type: DataTypes.INTEGER },
|
||||
CPSInsLtstCFOpndDate : { type: DataTypes.STRING },
|
||||
CPSInsDCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSInsDCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSInsDCFBP : { type: DataTypes.STRING },
|
||||
CPSInsDCFGP : { type: DataTypes.STRING },
|
||||
CPSInsDOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSInsDOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSInsDOSBP : { type: DataTypes.INTEGER },
|
||||
CPSInsDOSGP : { type: DataTypes.INTEGER },
|
||||
CPSOutMsg : { type: DataTypes.STRING },
|
||||
CPSOutOPSBMsg : { type: DataTypes.STRING },
|
||||
CPSOutOPSBTotalLenders : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBTotalCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBTotalCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBTotalCFBP : { type: DataTypes.STRING },
|
||||
CPSOutOPSBTotalCFGP : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBOpenCF : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBTOBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBTOGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBTOBP : { type: DataTypes.STRING },
|
||||
CPSOutOPSBTOGP : { type: DataTypes.STRING },
|
||||
CPSOutOPSBDCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBDCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBDCFBP : { type: DataTypes.STRING },
|
||||
CPSOutOPSBDCFGP : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBDOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBDOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPSBDOSBP : { type: DataTypes.STRING },
|
||||
CPSOutOPSBDOSGP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBMsg : { type: DataTypes.STRING },
|
||||
CPSOutOPFBTotalLenders : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBTCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBTCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBTCFBP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBTCFGP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBOpenCF : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBTOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBTOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBTOSBP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBTOSGP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBDCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBDCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBDCFBP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBDCFGP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBDOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBDOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOPFBDOSBP : { type: DataTypes.STRING },
|
||||
CPSOutOPFBDOSGP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCMsg : { type: DataTypes.STRING },
|
||||
CPSOutNBFCTotalLenders : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCTCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCTCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCTCFBP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCTCFGP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCOpenCF : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCTOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCTOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCTOSBP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCTOSGP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCDCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCDCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCDCFBP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCDCFGP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCDOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCDOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutNBFCDOSBP : { type: DataTypes.STRING },
|
||||
CPSOutNBFCDOSGP : { type: DataTypes.STRING },
|
||||
CPSOutOutsideTotalMsg : { type: DataTypes.STRING },
|
||||
CPSOutOutsideTotalTotalLenders : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalTCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalTCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalTCFBP : { type: DataTypes.STRING },
|
||||
CPSOutOutsideTotalTCFGP : { type: DataTypes.STRING },
|
||||
CPSOutOutsideTotalOpenCF : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalTOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalTOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalTOSBP : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalTOSGP : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalLtstCFOpndDate : { type: DataTypes.STRING },
|
||||
CPSOutOutsideTotalDCFBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalDCFGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalDCFBP : { type: DataTypes.STRING },
|
||||
CPSOutOutsideTotalDCFGP : { type: DataTypes.STRING },
|
||||
CPSOutOutsideTotalDOSBorrower : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalDOSGuarantor : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalDOSBP : { type: DataTypes.INTEGER },
|
||||
CPSOutOutsideTotalDOSGP : { type: DataTypes.INTEGER },
|
||||
CPSTotalTotalLenders : { type: DataTypes.INTEGER },
|
||||
CPSTotalTotalCF : { type: DataTypes.INTEGER },
|
||||
CPSTotalOpenCF : { type: DataTypes.INTEGER },
|
||||
CPSTotalTotalOutstanding : { type: DataTypes.INTEGER },
|
||||
CPSTotalLtstCFOpndDate : { type: DataTypes.STRING },
|
||||
CPSTotalDCF : { type: DataTypes.INTEGER },
|
||||
CPSTotalDOS : { type: DataTypes.INTEGER },
|
||||
EnqSSMsg : { type: DataTypes.STRING },
|
||||
EnqSSInstNOEMnths1 : { type: DataTypes.INTEGER },
|
||||
EnqSSInstNOEMnths2to3 : { type: DataTypes.INTEGER },
|
||||
EnqSSInstNOEMnths4to6 : { type: DataTypes.INTEGER },
|
||||
EnqSSInstNOEMnths7to12 : { type: DataTypes.INTEGER },
|
||||
EnqSSInstNOEMnths12to24 : { type: DataTypes.INTEGER },
|
||||
EnqSSInstNOEGrtrThan24Mnths : { type: DataTypes.INTEGER },
|
||||
EnqSSInstNOETotal : { type: DataTypes.INTEGER },
|
||||
EnqSSInstNOEMstRecentDate : { type: DataTypes.STRING },
|
||||
EnqSSOutNOEMnths1 : { type: DataTypes.INTEGER },
|
||||
EnqSSOutNOEMnths2to3 : { type: DataTypes.INTEGER },
|
||||
EnqSSOutNOEMnths4to6 : { type: DataTypes.INTEGER },
|
||||
EnqSSOutNOEMnths7to12 : { type: DataTypes.INTEGER },
|
||||
EnqSSOutNOEMnthsGrtrThan24Mnths : { type: DataTypes.INTEGER },
|
||||
EnqSSOutNOETotal : { type: DataTypes.INTEGER },
|
||||
EnqSSETMnths1 : { type: DataTypes.INTEGER },
|
||||
EnqSSETMnths2to3 : { type: DataTypes.INTEGER },
|
||||
EnqSSETMnths4to6 : { type: DataTypes.INTEGER },
|
||||
EnqSSETMnths7to12 : { type: DataTypes.INTEGER },
|
||||
EnqSSETMnths12to24 : { type: DataTypes.INTEGER },
|
||||
EnqSSETGrtrThan24Mnths : { type: DataTypes.INTEGER },
|
||||
EnqSSETTotal : { type: DataTypes.INTEGER },
|
||||
EnqSSETMstRecentDate : { type: DataTypes.STRING },
|
||||
DISMsg : { type: DataTypes.STRING },
|
||||
DISMsgOfBorrower : { type: DataTypes.STRING },
|
||||
DISMsgOfBorrowerInst : { type: DataTypes.STRING },
|
||||
DISMsgOfBorrowerOut : { type: DataTypes.STRING },
|
||||
DISMsgOfRelatedPartie : { type: DataTypes.STRING },
|
||||
DISMsgOfRelatedPartiesInst : { type: DataTypes.STRING },
|
||||
DISMsgOfRelatedPartiesOut : { type: DataTypes.STRING },
|
||||
DISMsgOfGuarantedParties : { type: DataTypes.STRING },
|
||||
DISDIBInstWilfulDefault : { type: DataTypes.INTEGER },
|
||||
DISDIBInstSFNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBInstSFAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBInstWOffNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBInstWOffAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBInstSettledNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBInstSettledAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBInstInvokedNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBInstInvokedAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBInstOverdueCFNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBInstOverdueCFAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBInstDishonoredCheque : { type: DataTypes.INTEGER },
|
||||
DISDIBOutWilfulDefault : { type: DataTypes.INTEGER },
|
||||
DISDIBOutSFNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBOutSFAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBOutWOffNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBOutWOffAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBOutSettledNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBOutSettledAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBOutInvokedNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBOutInvokedAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBOutOverdueCFNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBOutOverdueCFAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBOutDishonoredCheque : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalWilfulDefault : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalSFNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalSFAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalWOffNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalWOffAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalSettledNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalSettledAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalInvokedNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalInvokedAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalOverdueCFNOS : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalOverdueCFAmt : { type: DataTypes.INTEGER },
|
||||
DISDIBTotalDishonoredCheque : { type: DataTypes.INTEGER },
|
||||
DISGOBInstWilfulDefault : { type: DataTypes.INTEGER },
|
||||
DISGOBInstSFNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBInstSFAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBInstWOffNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBInstWOffAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBInstSettledNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBInstSettledAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBInstInvokedNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBInstInvokedAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBInstOverdueCFNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBInstOverdueCFAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBInstDishonoredCheque : { type: DataTypes.INTEGER },
|
||||
DISGOBOutWilfulDefault : { type: DataTypes.INTEGER },
|
||||
DISGOBOutSFNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBOutSFAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBOutWOffNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBOutWOffAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBOutSettledNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBOutSettledAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBOutInvokedNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBOutInvokedAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBOutOverdueCFNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBOutOverdueCFAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBOutDishonoredCheque : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalWilfulDefault : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalSFNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalSFAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalWOffNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalWOffAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalSettledNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalSettledAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalInvokedNOS : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalInvokedAmt : { type: DataTypes.INTEGER },
|
||||
DISGOBTotalOverdueCFNOS : { type: DataTypes.INTEGER },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_borrower_profile',
|
||||
modelName: 'BorrowerProfile',
|
||||
}
|
||||
)
|
||||
|
||||
return BorrowerProfile
|
||||
}
|
||||
28
app/models/BorrowidDetail.js
Normal file
28
app/models/BorrowidDetail.js
Normal file
@ -0,0 +1,28 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class BorrowidDetail extends Model {
|
||||
|
||||
}
|
||||
BorrowidDetail.init(
|
||||
|
||||
{
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
BorrowerProfileBIDPan: { type: DataTypes.STRING },
|
||||
BorrowerProfileBIDCin: { type: DataTypes.STRING },
|
||||
BorrowerProfileBIDTin: { type: DataTypes.STRING },
|
||||
BorrowerProfileBIDRegistrationNo: { type: DataTypes.STRING },
|
||||
BorrowerProfileBIDServiceTaxNo: { type: DataTypes.STRING },
|
||||
BorrowerProfileLastReportedDate: { type: DataTypes.DATE },
|
||||
temp_id: { type: DataTypes.INTEGER }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_borrower_id_detail',
|
||||
modelName: 'BorrowidDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return BorrowidDetail
|
||||
}
|
||||
59
app/models/ConAccountTranscation.js
Normal file
59
app/models/ConAccountTranscation.js
Normal file
@ -0,0 +1,59 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConAccountTranscation extends Model {
|
||||
|
||||
}
|
||||
ConAccountTranscation.init(
|
||||
|
||||
{
|
||||
AccountTranDetailsID: { type: DataTypes.INTEGER },
|
||||
MemberReferenceNumber: { type: DataTypes.INTEGER },
|
||||
ReportingMemberShortName: { type: DataTypes.STRING },
|
||||
AccountNumber: { type: DataTypes.STRING },
|
||||
AccountType: { type: DataTypes.STRING },
|
||||
OwnershipIndicator: { type: DataTypes.STRING },
|
||||
DateOpenedDisbursed: { type: DataTypes.DATE },
|
||||
DateOfLastPayment: { type: DataTypes.DATE },
|
||||
DateClosed: { type: DataTypes.DATE },
|
||||
DateReportedAndCertified: { type: DataTypes.DATE },
|
||||
HighCreditSanctionedAmount: { type: DataTypes.INTEGER },
|
||||
CurrentBalance: { type: DataTypes.INTEGER },
|
||||
AmountOverdue: { type: DataTypes.INTEGER },
|
||||
PaymentHistory1: { type: DataTypes.STRING }, //
|
||||
PaymentHistory2: { type: DataTypes.STRING }, //
|
||||
PaymentHistoryStartDate: { type: DataTypes.DATE },
|
||||
PaymentHistoryEndDate: { type: DataTypes.DATE },
|
||||
SuitFiledWilfulDefault: { type: DataTypes.STRING }, //
|
||||
WrittenOffAndSettledStatus: { type: DataTypes.STRING },
|
||||
ValueOfCollateral: { type: DataTypes.STRING },
|
||||
TypeOfCollateral: { type: DataTypes.STRING },
|
||||
CreditLimit: { type: DataTypes.INTEGER },
|
||||
CashLimit: { type: DataTypes.INTEGER },
|
||||
RateOfInterest: { type: DataTypes.INTEGER },
|
||||
RepaymentTenure: { type: DataTypes.INTEGER },
|
||||
EMIAmount: { type: DataTypes.INTEGER },
|
||||
WrittenOffAmountTotal: { type: DataTypes.INTEGER },
|
||||
WrittenOffAmountPrincipal: { type: DataTypes.INTEGER }, //
|
||||
SettlementAmount: { type: DataTypes.INTEGER },
|
||||
PaymentFrequency: { type: DataTypes.STRING },
|
||||
ActualPaymentAmount: { type: DataTypes.INTEGER },
|
||||
DateOfEntryForErrorCode: { type: DataTypes.STRING },
|
||||
ErrorCode: { type: DataTypes.STRING }, //
|
||||
DateOfEntryForCIBILRemarksCode: { type: DataTypes.STRING },//
|
||||
CIBILRemarksCode: { type: DataTypes.STRING },
|
||||
DateOfEntryForErrorDisputeRemarksCode: { type: DataTypes.STRING },
|
||||
ErrorDisputeRemarksCode1: { type: DataTypes.STRING },
|
||||
ErrorDisputeRemarksCode2: { type: DataTypes.STRING },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'con_account_transaction_detail',
|
||||
modelName: 'ConAccountTranscation',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConAccountTranscation
|
||||
}
|
||||
35
app/models/ConAddressDetail.js
Normal file
35
app/models/ConAddressDetail.js
Normal file
@ -0,0 +1,35 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConAddressDetail extends Model {
|
||||
|
||||
}
|
||||
ConAddressDetail.init(
|
||||
|
||||
{
|
||||
AddressDetailsId: { type: DataTypes.INTEGER },
|
||||
MemberReferenceNumber: { type: DataTypes.INTEGER },
|
||||
AddressLine1: { type: DataTypes.STRING },
|
||||
AddressLine2: { type: DataTypes.STRING },
|
||||
AddressLine3: { type: DataTypes.STRING },
|
||||
AddressLine4: { type: DataTypes.STRING },
|
||||
AddressLine5: { type: DataTypes.STRING },
|
||||
State: { type: DataTypes.STRING },
|
||||
PINCode: { type: DataTypes.INTEGER },
|
||||
AddressCategory: { type: DataTypes.STRING },
|
||||
ResidenceCode: { type: DataTypes.STRING },
|
||||
DateReported: { type: DataTypes.DATE },
|
||||
MemberShortName: { type: DataTypes.STRING },
|
||||
EnrichedThroughEnquiry: { type: DataTypes.STRING }
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'con_address_detail',
|
||||
modelName: 'ConAddressDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConAddressDetail
|
||||
}
|
||||
60
app/models/ConBorrowerDetail.js
Normal file
60
app/models/ConBorrowerDetail.js
Normal file
@ -0,0 +1,60 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConBorrowDetail extends Model {
|
||||
|
||||
}
|
||||
ConBorrowDetail.init(
|
||||
|
||||
{
|
||||
BDeatailsID: { type: DataTypes.INTEGER },
|
||||
MemberReferenceNumber: { type: DataTypes.INTEGER },
|
||||
EnquiryMemberUserID: { type: DataTypes.STRING }, //
|
||||
SubjectReturnCode: { type: DataTypes.INTEGER },
|
||||
EnquiryControlNumber: { type: DataTypes.INTEGER },
|
||||
DateTimeProcessed: { type: DataTypes.DATE },
|
||||
ConsumerNameField1: { type: DataTypes.STRING },
|
||||
ConsumerNameField2: { type: DataTypes.STRING },
|
||||
ConsumerNameField3: { type: DataTypes.STRING },
|
||||
ConsumerNameField4: { type: DataTypes.STRING },
|
||||
ConsumerNameField5: { type: DataTypes.STRING },
|
||||
DateofBirth: { type: DataTypes.DATE },
|
||||
Gender: { type: DataTypes.STRING },
|
||||
DateofEntryforErrorCode: { type: DataTypes.DATE }, //
|
||||
ErrorSegmentTag: { type: DataTypes.STRING }, //
|
||||
ErrorCode: { type: DataTypes.STRING }, //
|
||||
DateofEntryforCIBILRemarksCode: { type: DataTypes.STRING },//
|
||||
CIBILRemarks: { type: DataTypes.STRING }, //
|
||||
DateofEntryforErrorDisputeRemarksCode: { type: DataTypes.STRING }, //
|
||||
ErrorDisputeRemarksCode: { type: DataTypes.STRING }, //
|
||||
ErrorDisputeRemarksCode2: { type: DataTypes.STRING }, //
|
||||
AccountType: { type: DataTypes.STRING },
|
||||
DateReportedAndCertified: { type: DataTypes.DATE },
|
||||
Occupation: { type: DataTypes.STRING },
|
||||
Income: { type: DataTypes.INTEGER },
|
||||
NetGrossIncomeIndicator: { type: DataTypes.STRING },
|
||||
MonthlyAnnualIncomeIndicator: { type: DataTypes.STRING },
|
||||
DateOfEntryforErrorCode1: { type: DataTypes.STRING }, //
|
||||
ErrorCode1: { type: DataTypes.STRING }, //
|
||||
DateOfEntryForCIBILRemarksCode1: { type: DataTypes.STRING }, //
|
||||
CIBILRemarksCode: { type: DataTypes.STRING }, //
|
||||
DateOfEntryForErrorDisputeRemarksCode1: { type: DataTypes.STRING }, //
|
||||
ErrorDisputeRemarksCode1: { type: DataTypes.STRING }, //
|
||||
ATErrorDisputeRemarksCode1: { type: DataTypes.STRING }, //
|
||||
ATErrorDisputeRemarksCode2: { type: DataTypes.STRING },
|
||||
DateOfEntry: { type: DataTypes.DATE },
|
||||
DisputeRemarksLine: { type: DataTypes.STRING }, //
|
||||
EMailID: { type: DataTypes.STRING },
|
||||
AccountNumber: { type: DataTypes.STRING }
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'con_borrower_detail',
|
||||
modelName: 'ConBorrowDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConBorrowDetail
|
||||
}
|
||||
26
app/models/ConDPDTranscationDetail.js
Normal file
26
app/models/ConDPDTranscationDetail.js
Normal file
@ -0,0 +1,26 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConDPDTranscation extends Model {
|
||||
|
||||
}
|
||||
ConDPDTranscation.init(
|
||||
|
||||
{
|
||||
detail_id: { type: DataTypes.INTEGER },
|
||||
account_tran_detail_id: { type: DataTypes.INTEGER },
|
||||
member_ref_no: { type: DataTypes.STRING }, //
|
||||
start_date: { type: DataTypes.DATE },
|
||||
code: { type: DataTypes.STRING }, //
|
||||
entry_date: { type: DataTypes.DATE }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'emp_details',
|
||||
modelName: 'ConDPDTranscation',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConDPDTranscation
|
||||
}
|
||||
26
app/models/ConEnquieyDetail.js
Normal file
26
app/models/ConEnquieyDetail.js
Normal file
@ -0,0 +1,26 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConEnquiryDetail extends Model {
|
||||
|
||||
}
|
||||
ConEnquiryDetail.init(
|
||||
|
||||
{
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
EnquiryDetailsCreditLender: { type: DataTypes.STRING },
|
||||
EnquiryDetailsEnquiryDt: { type: DataTypes.STRING },
|
||||
EnquiryDetailsEnquiryPurpose: { type: DataTypes.STRING },
|
||||
EnquiryDetailsEnquiryAmt: { type: DataTypes.INTEGER },
|
||||
temp_id: { type: DataTypes.INTEGER }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_enquiry_detail',
|
||||
modelName: 'ConEnquiryDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConEnquiryDetail
|
||||
}
|
||||
27
app/models/ConIDDetail.js
Normal file
27
app/models/ConIDDetail.js
Normal file
@ -0,0 +1,27 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConIDDetail extends Model {
|
||||
|
||||
}
|
||||
ConIDDetail.init(
|
||||
|
||||
{
|
||||
id_detail_id: { type: DataTypes.INTEGER },
|
||||
member_ref_no: { type: DataTypes.STRING }, //
|
||||
id_type: { type: DataTypes.DATE },
|
||||
id_number: { type: DataTypes.STRING }, //
|
||||
issue_date: { type: DataTypes.DATE },
|
||||
expiration_date: { type: DataTypes.DATE },
|
||||
enrich_through_enquiry: { type: DataTypes.DATE }, //
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'emp_details',
|
||||
modelName: 'ConIDDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConIDDetail
|
||||
}
|
||||
26
app/models/ConPhoneDetail.js
Normal file
26
app/models/ConPhoneDetail.js
Normal file
@ -0,0 +1,26 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConPhoneDetail extends Model {
|
||||
|
||||
}
|
||||
ConPhoneDetail.init(
|
||||
|
||||
{
|
||||
phone_detail_id: { type: DataTypes.INTEGER },
|
||||
member_ref_no: { type: DataTypes.STRING }, //
|
||||
telephone_number: { type: DataTypes.INTEGER },
|
||||
telephone_extention: { type: DataTypes.INTEGER },
|
||||
telephone_type: { type: DataTypes.STRING },
|
||||
enrich_through_enquiry: { type: DataTypes.STRING }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'emp_details',
|
||||
modelName: 'ConPhoneDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConPhoneDetail
|
||||
}
|
||||
44
app/models/ConScoreDetail.js
Normal file
44
app/models/ConScoreDetail.js
Normal file
@ -0,0 +1,44 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class ConScoreDetail extends Model {
|
||||
|
||||
}
|
||||
ConScoreDetail.init(
|
||||
|
||||
{
|
||||
score_detail_id: { type: DataTypes.INTEGER },
|
||||
member_ref_no: { type: DataTypes.STRING }, //
|
||||
score_name: { type: DataTypes.STRING },
|
||||
score_card_name: { type: DataTypes.STRING },
|
||||
score_card_version: { type: DataTypes.INTEGER },
|
||||
score_date: { type: DataTypes.DATE },
|
||||
score: { type: DataTypes.INTEGER },
|
||||
exclution_code_1: { type: DataTypes.DATE },//
|
||||
exclution_code_2: { type: DataTypes.DATE }, //
|
||||
exclution_code_3: { type: DataTypes.DATE },//
|
||||
exclution_code_4: { type: DataTypes.DATE },//
|
||||
exclution_code_5: { type: DataTypes.DATE },//
|
||||
exclution_code_6: { type: DataTypes.DATE },//
|
||||
exclution_code_7: { type: DataTypes.DATE },//
|
||||
exclution_code_8: { type: DataTypes.DATE },//
|
||||
exclution_code_9: { type: DataTypes.DATE },//
|
||||
exclution_code_10: { type: DataTypes.DATE },//
|
||||
reason_code_1: { type: DataTypes.STRING },
|
||||
reason_code_2: { type: DataTypes.STRING },
|
||||
reason_code_3: { type: DataTypes.STRING },
|
||||
reason_code_4: { type: DataTypes.STRING },
|
||||
reason_code_5: { type: DataTypes.STRING },
|
||||
error_code: { type: DataTypes.STRING } //
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'emp_details',
|
||||
modelName: 'ConScoreDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return ConScoreDetail
|
||||
}
|
||||
74
app/models/CreditFacilityCurrentDertail.js
Normal file
74
app/models/CreditFacilityCurrentDertail.js
Normal file
@ -0,0 +1,74 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class CreditFacilityCurrentDertail extends Model {
|
||||
|
||||
}
|
||||
CreditFacilityCurrentDertail.init(
|
||||
|
||||
{
|
||||
temp_id: { type: DataTypes.INTEGER },
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
CreditFacilityDetailsBorrowerSecMsg: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDDerivative: { type: DataTypes.STRING },
|
||||
CreditFacilityCDAccountNo: { type: DataTypes.STRING },
|
||||
CreditFacilityCDcfSrNo: { type: DataTypes.STRING },
|
||||
CreditFacilityCDcfType: { type: DataTypes.STRING },
|
||||
CreditFacilityCDcfMember: { type: DataTypes.STRING },
|
||||
CreditFacilityCDAssetCDPDueDpd: { type: DataTypes.STRING },
|
||||
CreditFacilityCDStatus: { type: DataTypes.STRING },
|
||||
CreditFacilityCDStatusDate: { type: DataTypes.DATE },
|
||||
CreditFacilityCDLstReportedDate: { type: DataTypes.DATE },
|
||||
CreditFacilityCDAmtCurrency: { type: DataTypes.STRING },
|
||||
CreditFacilityCDAmtSanctionedAmt: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtSanctionedAmtDP: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtoutstandingBalance: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtmarkToMarket: { type: DataTypes.STRING },
|
||||
CreditFacilityCDAmtOverdue: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtHighCredit: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtinstallmentAmt: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtSuitFiledAmt: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtLastRepaid: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtWrittenOFF: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtSettled: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDAmtNaorc: { type: DataTypes.STRING },
|
||||
CreditFacilityCDAmtContrctCAsNPA: { type: DataTypes.STRING },
|
||||
CreditFacilityCDAmtNAmtOfContracts: { type: DataTypes.STRING },
|
||||
CreditFacilityCDDatesSanctionedDt: { type: DataTypes.DATE },
|
||||
CreditFacilityCDDatesLoanExpiryDt: { type: DataTypes.DATE },
|
||||
CreditFacilityCDDatesLoanRenewalDt: { type: DataTypes.DATE },
|
||||
CreditFacilityCDDatesSuitFiledDt: { type: DataTypes.STRING },
|
||||
CreditFacilityCDDatesWilfulDefault: { type: DataTypes.STRING },
|
||||
CreditFacilityCDODRepaymentFrequency: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDODTenure: { type: DataTypes.INTEGER },
|
||||
CreditFacilityCDODWAMPContracts: { type: DataTypes.STRING },
|
||||
CreditFacilityCDODRestructingReason: { type: DataTypes.STRING },
|
||||
CreditFacilityCDODABSecurityCoverage: { type: DataTypes.STRING },
|
||||
CreditFacilityCDODGuaranteeCoverage: { type: DataTypes.STRING },
|
||||
CreditFacilityOverdueDetailsMsg: { type: DataTypes.STRING },
|
||||
CreditFacilityOverdueDetailsDPD1to30Amt: { type: DataTypes.INTEGER },
|
||||
CreditFacilityOverdueDetailsDPD31to60amt: { type: DataTypes.INTEGER },
|
||||
CreditFacilityOverdueDetailsDPD61t090amt: { type: DataTypes.INTEGER },
|
||||
CreditFacilityOverdueDetailsDPD91to180amt: { type: DataTypes.INTEGER },
|
||||
CreditFacilityOverdueDetailsDPDabove180amt: { type: DataTypes.INTEGER },
|
||||
ChequeDDIFundsMsg: { type: DataTypes.STRING },
|
||||
ChequeDDIFundsCD3monthcount: { type: DataTypes.STRING },
|
||||
ChequeDDIFundsCD4to6monthcount: { type: DataTypes.STRING },
|
||||
ChequeDDIFundsCD7to9monthcount: { type: DataTypes.STRING },
|
||||
ChequeDDIFundsCD10to12monthcount: { type: DataTypes.INTEGER },
|
||||
CFSecurityDetailsMsg: { type: DataTypes.STRING },
|
||||
CreditFacilityGuarantorDVecMsg: { type: DataTypes.STRING },
|
||||
|
||||
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_credit_facility_current_detail',
|
||||
modelName: 'CreditFacilityCurrentDertail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return CreditFacilityCurrentDertail
|
||||
}
|
||||
26
app/models/EnquieyDetail.js
Normal file
26
app/models/EnquieyDetail.js
Normal file
@ -0,0 +1,26 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class EnquiryDetail extends Model {
|
||||
|
||||
}
|
||||
EnquiryDetail.init(
|
||||
|
||||
{
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
EnquiryDetailsCreditLender: { type: DataTypes.STRING },
|
||||
EnquiryDetailsEnquiryDt: { type: DataTypes.STRING },
|
||||
EnquiryDetailsEnquiryPurpose: { type: DataTypes.STRING },
|
||||
EnquiryDetailsEnquiryAmt: { type: DataTypes.INTEGER },
|
||||
temp_id: { type: DataTypes.INTEGER }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_enquiry_detail',
|
||||
modelName: 'EnquiryDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return EnquiryDetail
|
||||
}
|
||||
37
app/models/GuarantorDetail.js
Normal file
37
app/models/GuarantorDetail.js
Normal file
@ -0,0 +1,37 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class GuarantorDetail extends Model {
|
||||
|
||||
}
|
||||
GuarantorDetail.init(
|
||||
|
||||
{
|
||||
temp_id: { type: DataTypes.INTEGER },
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
BorrowerCurrentDetailsID: { type: DataTypes.INTEGER },
|
||||
GuarantorDetailsName: { type: DataTypes.STRING },
|
||||
GuarantorDetailsRelatedType: { type: DataTypes.STRING },
|
||||
GuarantorDetailsDOB: { type: DataTypes.DATE },
|
||||
GuarantorDetailsGender: { type: DataTypes.STRING },
|
||||
GuarantorDetailsDOI: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBusinessCateg: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBusinessIndstryType: { type: DataTypes.STRING },
|
||||
GuarantorDetailsMsg: { type: DataTypes.STRING },
|
||||
GuarantorAddressCDAddress: { type: DataTypes.STRING },
|
||||
GuarantorAddressCDTelephoneNo: { type: DataTypes.DATE },
|
||||
GuarantorAddressCDfaxNo: { type: DataTypes.STRING },
|
||||
GuarantorAddressCDMobileNo: { type: DataTypes.STRING },
|
||||
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_guarantor_detail',
|
||||
modelName: 'GuarantorDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return GuarantorDetail
|
||||
}
|
||||
37
app/models/GuarantorIDDetail.js
Normal file
37
app/models/GuarantorIDDetail.js
Normal file
@ -0,0 +1,37 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class GuarantorIDDetail extends Model {
|
||||
|
||||
}
|
||||
GuarantorIDDetail.init(
|
||||
|
||||
{
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
CFGuarantorDetailsID: { type: DataTypes.INTEGER },
|
||||
GuarantorDetailsBIDlastReportedDate: { type: DataTypes.DATE },
|
||||
GuarantorDetailsBIDPan: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDRegNo: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDCin: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDTin: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDServiceTaxNo: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDDin: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDVoterID: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDPassportNo: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDUid: { type: DataTypes.INTEGER },
|
||||
GuarantorDetailsBIDdrivingLicenseNo: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDRationCard: { type: DataTypes.STRING },
|
||||
GuarantorDetailsBIDOtherID: { type: DataTypes.STRING },
|
||||
BorrowerCurrentDetailsID: { type: DataTypes.INTEGER },
|
||||
temp_id: { type: DataTypes.INTEGER }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_guarantor_id_detail',
|
||||
modelName: 'GuarantorIDDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return GuarantorIDDetail
|
||||
}
|
||||
30
app/models/LocationDetail.js
Normal file
30
app/models/LocationDetail.js
Normal file
@ -0,0 +1,30 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class LocationDetail extends Model {
|
||||
|
||||
}
|
||||
LocationDetail.init(
|
||||
|
||||
{
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
LocationType: { type: DataTypes.STRING },
|
||||
firstReportedDate: { type: DataTypes.DATE },
|
||||
LastReportedDate: { type: DataTypes.DATE },
|
||||
Address: { type: DataTypes.STRING },
|
||||
NoOfInstitutions: { type: DataTypes.INTEGER },
|
||||
contactNumber: { type: DataTypes.STRING }, // doubt
|
||||
faxNumber: { type: DataTypes.STRING }, // doubt
|
||||
temp_id: { type: DataTypes.INTEGER }
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_location_detail',
|
||||
modelName: 'LocationDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return LocationDetail
|
||||
}
|
||||
23
app/models/MonthBucket.js
Normal file
23
app/models/MonthBucket.js
Normal file
@ -0,0 +1,23 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class MonthBucket extends Model {
|
||||
|
||||
}
|
||||
MonthBucket.init(
|
||||
|
||||
{
|
||||
createdon : { type: DataTypes.DATE },
|
||||
updatedon : { type: DataTypes.DATE },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_ac_history_and_dpd',
|
||||
modelName: 'MonthBucket',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return MonthBucket
|
||||
}
|
||||
35
app/models/OpEnquietAmount.js
Normal file
35
app/models/OpEnquietAmount.js
Normal file
@ -0,0 +1,35 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class OpEnquiryAmount extends Model {
|
||||
|
||||
}
|
||||
OpEnquiryAmount.init(
|
||||
|
||||
{
|
||||
enquiry_amount_count_cedit_facility : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_1 : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_2_to_3 : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_4_to_6 : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_7_to_12 : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_13_to_24 : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_25_to_36 : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_greater_than_36 : { type: DataTypes.STRING },
|
||||
enquiry_amount_count_total : { type: DataTypes.STRING },
|
||||
is_active : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'op_enquiry_amount_and_count_unique_enquiries',
|
||||
modelName: 'OpEnquiryAmount',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return OpEnquiryAmount
|
||||
}
|
||||
43
app/models/OpFacilityOpAndCl.js
Normal file
43
app/models/OpFacilityOpAndCl.js
Normal file
@ -0,0 +1,43 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class OpFacilityOpAndCl extends Model {
|
||||
|
||||
}
|
||||
OpFacilityOpAndCl.init(
|
||||
|
||||
{
|
||||
facility_type_id : { type: DataTypes.INTEGER },
|
||||
opened_1 : { type: DataTypes.INTEGER },
|
||||
closed_1 : { type: DataTypes.INTEGER },
|
||||
opened_2_to_3 : { type: DataTypes.INTEGER },
|
||||
closed_2_to_3 : { type: DataTypes.INTEGER },
|
||||
opened_4_to_6 : { type: DataTypes.INTEGER },
|
||||
closed_4_to_6 : { type: DataTypes.INTEGER },
|
||||
opened_7_to_12 : { type: DataTypes.INTEGER },
|
||||
closed_7_to_12 : { type: DataTypes.INTEGER },
|
||||
opened_13_to_24 : { type: DataTypes.INTEGER },
|
||||
closed_13_to_24 : { type: DataTypes.INTEGER },
|
||||
opened_25_to_36 : { type: DataTypes.INTEGER },
|
||||
closed_25_to_36 : { type: DataTypes.INTEGER },
|
||||
opened_greater_than_36 : { type: DataTypes.INTEGER },
|
||||
closed_greater_than_36 : { type: DataTypes.INTEGER },
|
||||
opened_total : { type: DataTypes.INTEGER },
|
||||
closed_total : { type: DataTypes.INTEGER },
|
||||
is_active : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'op_facility_op_and_cl',
|
||||
modelName: 'OpFacilityOpAndCl',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return OpFacilityOpAndCl
|
||||
}
|
||||
27
app/models/OpFacilityTypeMaster.js
Normal file
27
app/models/OpFacilityTypeMaster.js
Normal file
@ -0,0 +1,27 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class OpFacilityTypeMaster extends Model {
|
||||
|
||||
}
|
||||
OpFacilityTypeMaster.init(
|
||||
|
||||
{
|
||||
value : { type: DataTypes.STRING },
|
||||
is_active : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'op_facility_type_master',
|
||||
modelName: 'OpFacilityTypeMaster',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return OpFacilityTypeMaster
|
||||
}
|
||||
40
app/models/OpRtrSummary.js
Normal file
40
app/models/OpRtrSummary.js
Normal file
@ -0,0 +1,40 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class OpRtrSummary extends Model {
|
||||
|
||||
}
|
||||
OpRtrSummary.init(
|
||||
|
||||
{
|
||||
los_id : { type: DataTypes.STRING },
|
||||
ref_no : { type: DataTypes.STRING },
|
||||
account_type : { type: DataTypes.STRING },
|
||||
consumer_name : { type: DataTypes.STRING },
|
||||
ownership : { type: DataTypes.STRING },
|
||||
reported_and_certified_date : { type: DataTypes.DATE },
|
||||
opened_date : { type: DataTypes.DATE },
|
||||
repayment_tenure : { type: DataTypes.INTEGER },
|
||||
status : { type: DataTypes.STRING },
|
||||
current_dpd : { type: DataTypes.STRING },
|
||||
dpd0_6 : { type: DataTypes.STRING },
|
||||
dpd7_12 : { type: DataTypes.STRING },
|
||||
dpd13_24 : { type: DataTypes.STRING },
|
||||
dpd25_36 : { type: DataTypes.STRING },
|
||||
is_active : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'op_rtr_summary_of_active_loans',
|
||||
modelName: 'OpRtrSummary',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return OpRtrSummary
|
||||
}
|
||||
35
app/models/OpSanctionAmount.js
Normal file
35
app/models/OpSanctionAmount.js
Normal file
@ -0,0 +1,35 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class OpSanctionAmount extends Model {
|
||||
|
||||
}
|
||||
OpSanctionAmount.init(
|
||||
|
||||
{
|
||||
sanction_amount_count_cedit_facility : { type: DataTypes.STRING },
|
||||
sanction_amount_count_1 : { type: DataTypes.STRING },
|
||||
sanction_amount_count_2_to_3 : { type: DataTypes.STRING },
|
||||
sanction_amount_count_4_to_6 : { type: DataTypes.STRING },
|
||||
sanction_amount_count_7_to_12 : { type: DataTypes.STRING },
|
||||
sanction_amount_count_13_to_24 : { type: DataTypes.STRING },
|
||||
sanction_amount_count_25_to_36 : { type: DataTypes.STRING },
|
||||
sanction_amount_count_greater_than_36 : { type: DataTypes.STRING },
|
||||
sanction_amount_count_total : { type: DataTypes.STRING },
|
||||
is_active : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'op_sanction_amount_frequency',
|
||||
modelName: 'OpSanctionAmount',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return OpSanctionAmount
|
||||
}
|
||||
42
app/models/OpSnapshotOfClosedLoans.js
Normal file
42
app/models/OpSnapshotOfClosedLoans.js
Normal file
@ -0,0 +1,42 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class OpSnapshotOfClosedLoans extends Model {
|
||||
|
||||
}
|
||||
OpSnapshotOfClosedLoans.init(
|
||||
|
||||
{
|
||||
account_type : { type: DataTypes.STRING },
|
||||
consumer_name : { type: DataTypes.STRING },
|
||||
ownership : { type: DataTypes.STRING },
|
||||
reported_and_certified_date : { type: DataTypes.DATE },
|
||||
opened_date : { type: DataTypes.DATE },
|
||||
sanctioned_amount : { type: DataTypes.INTEGER },
|
||||
current_balance : { type: DataTypes.INTEGER },
|
||||
repayment_tenure : { type: DataTypes.STRING },
|
||||
emi_amount : { type: DataTypes.INTEGER },
|
||||
overdue_amount : { type: DataTypes.INTEGER },
|
||||
status : { type: DataTypes.STRING },
|
||||
current_dpd : { type: DataTypes.STRING },
|
||||
highest_dpd_month_wise_bucket_or_count_0_to_6 : { type: DataTypes.STRING },
|
||||
highest_dpd_month_wise_bucket_or_count_07_to_12 : { type: DataTypes.STRING },
|
||||
highest_dpd_month_wise_bucket_or_count_13_to_24 : { type: DataTypes.STRING },
|
||||
highest_dpd_month_wise_bucket_or_count_25_to_36 : { type: DataTypes.STRING },
|
||||
is_active : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'op_snapshot_of_closed_loans',
|
||||
modelName: 'OpSnapshotOfClosedLoans',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return OpSnapshotOfClosedLoans
|
||||
}
|
||||
35
app/models/OpSummaryView.js
Normal file
35
app/models/OpSummaryView.js
Normal file
@ -0,0 +1,35 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class OpSummaryView extends Model {
|
||||
|
||||
}
|
||||
OpSummaryView.init(
|
||||
|
||||
{
|
||||
account_count_total : { type: DataTypes.INTEGER },
|
||||
account_count_overdue : { type: DataTypes.STRING },
|
||||
account_count_zero_balance : { type: DataTypes.STRING },
|
||||
account_count_total_nil_overdue : { type: DataTypes.STRING },
|
||||
advances_high_credit : { type: DataTypes.STRING },
|
||||
balances_current : { type: DataTypes.INTEGER },
|
||||
balances_overdue : { type: DataTypes.INTEGER },
|
||||
date_opened_latest : { type: DataTypes.DATE },
|
||||
date_opened_closed : { type: DataTypes.DATE },
|
||||
is_active : { type: DataTypes.INTEGER },
|
||||
createdAt : { type: DataTypes.DATE },
|
||||
createdby : { type: DataTypes.INTEGER },
|
||||
updatedAt : { type: DataTypes.DATE },
|
||||
updatedby : { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'op_summary_view_of_unique_credit_facilities',
|
||||
modelName: 'OpSummaryView',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return OpSummaryView
|
||||
}
|
||||
38
app/models/RelationshipDetail.js
Normal file
38
app/models/RelationshipDetail.js
Normal file
@ -0,0 +1,38 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class RelationshipDetail extends Model {
|
||||
|
||||
}
|
||||
RelationshipDetail.init(
|
||||
|
||||
{
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
RelationshipHeader: { type: DataTypes.STRING },
|
||||
RelationshipName: { type: DataTypes.STRING },
|
||||
RelatedType: { type: DataTypes.STRING },
|
||||
Relationship: { type: DataTypes.STRING },
|
||||
PercentageOfControl: { type: DataTypes.STRING },
|
||||
RDDOI: { type: DataTypes.STRING },
|
||||
RDDOB: { type: DataTypes.DATE },
|
||||
RDGender: { type: DataTypes.STRING },
|
||||
RDBusinessCatg: { type: DataTypes.STRING },
|
||||
RDBusinessIndustryType: { type: DataTypes.STRING },
|
||||
RDClassOfActivity1: { type: DataTypes.STRING },
|
||||
RDBACDAddress: { type: DataTypes.STRING },
|
||||
RDBACDTelephoneNo: { type: DataTypes.STRING },
|
||||
RDBACDfaxNo: { type: DataTypes.STRING },
|
||||
RDBACDMobileNo: { type: DataTypes.STRING },
|
||||
RDlastReportedDate: { type: DataTypes.DATE },
|
||||
temp_id: { type: DataTypes.INTEGER }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_relationship_detail',
|
||||
modelName: 'RelationshipDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return RelationshipDetail
|
||||
}
|
||||
34
app/models/RelationshipIDDetail.js
Normal file
34
app/models/RelationshipIDDetail.js
Normal file
@ -0,0 +1,34 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class RelationshipIDDetail extends Model {
|
||||
|
||||
}
|
||||
RelationshipIDDetail.init(
|
||||
|
||||
{
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
RDBorrwerIDDetailsPan: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsDin: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsVoterID: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsPassportNo: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsDrivingLicenseNo: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsUid: { type: DataTypes.INTEGER },
|
||||
RDBorrwerIDDetailsRegistrationNo: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsCin: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsTin: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsServiceTaxNumber: { type: DataTypes.STRING },
|
||||
RDBorrwerIDDetailsRationCard: { type: DataTypes.STRING },
|
||||
RelationShipIDDetails: { type: DataTypes.INTEGER },
|
||||
temp_id: { type: DataTypes.INTEGER }
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_relationship_id_detail',
|
||||
modelName: 'RelationshipIDDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return RelationshipIDDetail
|
||||
}
|
||||
31
app/models/SecurityDetail.js
Normal file
31
app/models/SecurityDetail.js
Normal file
@ -0,0 +1,31 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class SecurityDetail extends Model {
|
||||
|
||||
}
|
||||
SecurityDetail.init(
|
||||
|
||||
{
|
||||
temp_id: { type: DataTypes.INTEGER },
|
||||
ApplicationRefno: { type: DataTypes.INTEGER },
|
||||
BorrowerCurrentDetailsID: { type: DataTypes.INTEGER },
|
||||
CFSecurityDetailsRelatedType: { type: DataTypes.STRING },
|
||||
CFSecurityDetailsClassification: { type: DataTypes.STRING },
|
||||
CFSecurityDetailsValue: { type: DataTypes.INTEGER },
|
||||
CFSecurityDetailsCurrency: { type: DataTypes.STRING },
|
||||
CFSecurityDetailsvalidationDt: { type: DataTypes.DATE },
|
||||
CFSecurityDetailslastReportedDt: { type: DataTypes.DATE },
|
||||
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'com_security_detail',
|
||||
modelName: 'SecurityDetail',
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
return SecurityDetail
|
||||
}
|
||||
31
app/models/Test.js
Normal file
31
app/models/Test.js
Normal file
@ -0,0 +1,31 @@
|
||||
'use strict'
|
||||
const { Model } = require('sequelize')
|
||||
module.exports = (sequelize, DataTypes) => {
|
||||
class Test extends Model {
|
||||
/**
|
||||
* Helper method for defining associations.
|
||||
* This method is not a part of Sequelize lifecycle.
|
||||
* The `models/index` file will call this method automatically.
|
||||
*/
|
||||
// define association here
|
||||
// static associate({ Financials }) {
|
||||
// this.hasMany(Financials, { foreignKey: 'entity_id', as: 'financialsData' })
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
Test.init(
|
||||
{
|
||||
losid: { type: DataTypes.STRING },
|
||||
createdby: { type: DataTypes.INTEGER },
|
||||
updatedby: { type: DataTypes.INTEGER },
|
||||
|
||||
},
|
||||
{
|
||||
sequelize,
|
||||
tableName: 'test',
|
||||
modelName: 'Test',
|
||||
}
|
||||
)
|
||||
return Test
|
||||
}
|
||||
39
app/models/index.js
Normal file
39
app/models/index.js
Normal file
@ -0,0 +1,39 @@
|
||||
'use strict';
|
||||
|
||||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
const Sequelize = require('sequelize');
|
||||
const basename = path.basename(__filename);
|
||||
const env = process.env.NODE_ENV || 'development';
|
||||
const config = require(__dirname + '/../config/db.config.js')[env];
|
||||
//console.log(env);
|
||||
//console.log(config);
|
||||
const db = {};
|
||||
|
||||
let sequelize;
|
||||
if (config.use_env_variable) {
|
||||
sequelize = new Sequelize(process.env[config.use_env_variable], config);
|
||||
} else {
|
||||
sequelize = new Sequelize(config.database, config.username, config.password, config);
|
||||
}
|
||||
|
||||
fs
|
||||
.readdirSync(__dirname)
|
||||
.filter(file => {
|
||||
return (file.indexOf('.') !== 0) && (file !== basename) && (file.slice(-3) === '.js');
|
||||
})
|
||||
.forEach(file => {
|
||||
const model = require(path.join(__dirname, file))(sequelize, Sequelize.DataTypes);
|
||||
db[model.name] = model;
|
||||
});
|
||||
|
||||
Object.keys(db).forEach(modelName => {
|
||||
if (db[modelName].associate) {
|
||||
db[modelName].associate(db);
|
||||
}
|
||||
});
|
||||
|
||||
db.sequelize = sequelize;
|
||||
db.Sequelize = Sequelize;
|
||||
|
||||
module.exports = db;
|
||||
30
app/routes/routes.js
Normal file
30
app/routes/routes.js
Normal file
@ -0,0 +1,30 @@
|
||||
module.exports = app => {
|
||||
const request = require("request");
|
||||
const cors=require('cors');
|
||||
const Mycontroller = require("../controllers/test.controller.js");
|
||||
const { logMsg } = require('../services/logger.js');
|
||||
var router = require("express").Router();
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @swagger
|
||||
* /api/demo:
|
||||
* get:
|
||||
* summary: Demo Api
|
||||
* description: Welcome Message
|
||||
* responses:
|
||||
* 200:
|
||||
* description: success
|
||||
*/
|
||||
router.get("/demo", Mycontroller.Welcome);
|
||||
|
||||
|
||||
|
||||
// routes started here
|
||||
app.use('/api', router);
|
||||
};
|
||||
|
||||
|
||||
27
app/services/logger.js
Normal file
27
app/services/logger.js
Normal file
@ -0,0 +1,27 @@
|
||||
/**
|
||||
* Configurations of logger.
|
||||
*/
|
||||
var winston = require('winston');
|
||||
require('winston-daily-rotate-file');
|
||||
|
||||
var transport = new winston.transports.DailyRotateFile({
|
||||
filename: 'storage/log/msg.log',
|
||||
datePattern: 'YYYY-MM-DD',
|
||||
zippedArchive: true,
|
||||
maxSize: '20m',
|
||||
maxFiles: '14d'
|
||||
});
|
||||
|
||||
transport.on('rotate', function(oldFilename, newFilename) {
|
||||
// do something fun
|
||||
});
|
||||
|
||||
const logger = winston.createLogger({
|
||||
transports: [
|
||||
transport
|
||||
]
|
||||
});
|
||||
module.exports = {
|
||||
'logMsg': logger,
|
||||
};
|
||||
|
||||
8555
package-lock.json
generated
Normal file
8555
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
29
package.json
Normal file
29
package.json
Normal file
@ -0,0 +1,29 @@
|
||||
{
|
||||
"name": "smc_cet_creditpd_backend",
|
||||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "server.js",
|
||||
"scripts": {
|
||||
"start": "nodemon server.js"
|
||||
},
|
||||
"keywords": [],
|
||||
"author": "",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"body-parser": "^1.19.0",
|
||||
"cors": "^2.8.5",
|
||||
"dotenv": "^10.0.0",
|
||||
"express": "^4.17.1",
|
||||
"log4js": "^6.3.0",
|
||||
"mssql": "^7.2.0",
|
||||
"request": "^2.88.2",
|
||||
"sequelize": "^6.6.5",
|
||||
"swagger-jsdoc": "^6.1.0",
|
||||
"swagger-ui-express": "^4.1.6",
|
||||
"winston": "^3.3.3",
|
||||
"winston-daily-rotate-file": "^4.5.5"
|
||||
},
|
||||
"devDependencies": {
|
||||
"nodemon": "^2.0.12"
|
||||
}
|
||||
}
|
||||
62
server.js
Normal file
62
server.js
Normal file
@ -0,0 +1,62 @@
|
||||
require('dotenv').config();
|
||||
const express = require('express')
|
||||
const app = express()
|
||||
//it is used to clear cache
|
||||
app.use(function(req, res, next) {
|
||||
res.set("Cache-Control", "no-cache, no-store, must-revalidate, max-age=0")
|
||||
res.set("Pragma", "no-cache")
|
||||
res.set("Expires", 0)
|
||||
next()
|
||||
})
|
||||
const {logMsg} = require('./app/services/logger.js');
|
||||
|
||||
const swaggerJsdoc = require('swagger-jsdoc');
|
||||
const swaggerUi = require('swagger-ui-express');
|
||||
|
||||
|
||||
|
||||
const options = {
|
||||
definition: {
|
||||
openapi: '3.0.0',
|
||||
info: {
|
||||
title: 'Smc_cet_cibil_staging',
|
||||
version: '1.0.0',
|
||||
},
|
||||
},
|
||||
apis: ['./app/routes/routes.js'], // files containing annotations as above
|
||||
};
|
||||
|
||||
const swaggerDocument = swaggerJsdoc(options);
|
||||
app.use('/api-docs', swaggerUi.serve, swaggerUi.setup(swaggerDocument));
|
||||
|
||||
|
||||
/**
|
||||
* @openapi
|
||||
* /:
|
||||
* get:
|
||||
* description: Welcome to swagger-jsdoc!
|
||||
* responses:
|
||||
* 200:
|
||||
* description: Returns a mysterious string.
|
||||
*/
|
||||
|
||||
|
||||
app.get("/", (req, res) => {
|
||||
res.json({ message: "Welcome to the application." });
|
||||
logMsg.info("Server Sent A Welcome to the application!");
|
||||
|
||||
});
|
||||
|
||||
|
||||
app.use(express.json())
|
||||
app.use(express.urlencoded({ extended: true }));
|
||||
|
||||
|
||||
require("./app/routes/routes.js")(app);
|
||||
|
||||
const PORT_NUMBER = process.env.SERVER_PORT
|
||||
app.listen({ port: PORT_NUMBER }, async () => {
|
||||
console.log('Server up on http://localhost:8080')
|
||||
|
||||
//await sequelize.authenticate()
|
||||
})
|
||||
Loading…
Reference in New Issue
Block a user