added mssql db creds and modified contacts api
This commit is contained in:
parent
4c66a1a252
commit
2413ba955e
18
ormconfig.ts
18
ormconfig.ts
@ -15,17 +15,17 @@ export const OracleConfig: any = {
|
|||||||
export const MssqlConfig: any = {
|
export const MssqlConfig: any = {
|
||||||
// type: 'mssql',
|
// type: 'mssql',
|
||||||
|
|
||||||
server: 'localhost',
|
// server: 'localhost',
|
||||||
user: 'mssql1433',
|
// user: 'mssql1433',
|
||||||
password: 'root',
|
// password: 'root',
|
||||||
database: 'CarnetDB',
|
|
||||||
|
|
||||||
// server: '172.31.18.76',
|
|
||||||
// port: 1433,
|
|
||||||
// user: 'Carnetsys',
|
|
||||||
// password: 'Carnet1234',
|
|
||||||
// database: 'CarnetDB',
|
// database: 'CarnetDB',
|
||||||
|
|
||||||
|
server: '172.31.18.76',
|
||||||
|
port: 1433,
|
||||||
|
user: 'Carnetsys',
|
||||||
|
password: 'Carnet1234',
|
||||||
|
database: 'CarnetDB',
|
||||||
|
|
||||||
// entities: [__dirname + '/**/*.entity{.ts,.js}'],
|
// entities: [__dirname + '/**/*.entity{.ts,.js}'],
|
||||||
// synchronize: true,
|
// synchronize: true,
|
||||||
|
|
||||||
|
|||||||
@ -152,7 +152,10 @@ export class ManageFeeService {
|
|||||||
throw new BadRequestException()
|
throw new BadRequestException()
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rows[0].ERRORMESG) {
|
console.warn(rows);
|
||||||
|
|
||||||
|
|
||||||
|
if (rows.length>0 && rows[0].ERRORMESG) {
|
||||||
console.log(rows[0].ERRORMESG);
|
console.log(rows[0].ERRORMESG);
|
||||||
throw new BadRequestException(rows[0].ERRORMESG)
|
throw new BadRequestException(rows[0].ERRORMESG)
|
||||||
}
|
}
|
||||||
@ -379,6 +382,11 @@ export class ManageFeeService {
|
|||||||
throw new BadRequestException();
|
throw new BadRequestException();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (rows.length>0 && rows[0].ERRORMESG) {
|
||||||
|
console.log(rows[0].ERRORMESG);
|
||||||
|
throw new BadRequestException(rows[0].ERRORMESG)
|
||||||
|
}
|
||||||
|
|
||||||
return rows;
|
return rows;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error instanceof BadRequestException) {
|
if (error instanceof BadRequestException) {
|
||||||
@ -449,6 +457,11 @@ export class ManageFeeService {
|
|||||||
throw new BadRequestException();
|
throw new BadRequestException();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (rows.length>0 && rows[0].ERRORMESG) {
|
||||||
|
console.log(rows[0].ERRORMESG);
|
||||||
|
throw new BadRequestException(rows[0].ERRORMESG)
|
||||||
|
}
|
||||||
|
|
||||||
return rows;
|
return rows;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error instanceof BadRequestException) {
|
if (error instanceof BadRequestException) {
|
||||||
@ -519,6 +532,11 @@ export class ManageFeeService {
|
|||||||
throw new BadRequestException();
|
throw new BadRequestException();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (rows.length>0 && rows[0].ERRORMESG) {
|
||||||
|
console.log(rows[0].ERRORMESG);
|
||||||
|
throw new BadRequestException(rows[0].ERRORMESG)
|
||||||
|
}
|
||||||
|
|
||||||
return rows;
|
return rows;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error instanceof BadRequestException) {
|
if (error instanceof BadRequestException) {
|
||||||
|
|||||||
@ -68,7 +68,7 @@ export class RegionService {
|
|||||||
FROM all_source
|
FROM all_source
|
||||||
WHERE name = :pkgName AND type = 'PACKAGE BODY'
|
WHERE name = :pkgName AND type = 'PACKAGE BODY'
|
||||||
ORDER BY line`,
|
ORDER BY line`,
|
||||||
{ pkgName: 'MANAGEPREPARER_PKG' }, // bind variable
|
{ pkgName: 'USCIB_MANAGED_PKG' }, // bind variable
|
||||||
{ outFormat: oracledb.OUT_FORMAT_OBJECT }
|
{ outFormat: oracledb.OUT_FORMAT_OBJECT }
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -106,7 +106,7 @@ export class SpContactsService {
|
|||||||
throw new BadRequestException(fres[0].ERRORMESG)
|
throw new BadRequestException(fres[0].ERRORMESG)
|
||||||
}
|
}
|
||||||
|
|
||||||
return fres;
|
return { statusCode: 201, message: "Createdted Successfully", ...fres[0] };
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error instanceof BadRequestException) {
|
if (error instanceof BadRequestException) {
|
||||||
throw error;
|
throw error;
|
||||||
@ -244,7 +244,7 @@ export class SpContactsService {
|
|||||||
throw new BadRequestException(fres[0].ERRORMESG)
|
throw new BadRequestException(fres[0].ERRORMESG)
|
||||||
}
|
}
|
||||||
|
|
||||||
return fres;
|
return { statusCode: 200, message: "Updated Successfully" };
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
if (error instanceof BadRequestException) {
|
if (error instanceof BadRequestException) {
|
||||||
this.logger.warn(error.message);
|
this.logger.warn(error.message);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user