swagger config started
This commit is contained in:
parent
5e7be5ca17
commit
d65df441bb
79
package-lock.json
generated
79
package-lock.json
generated
@ -12,6 +12,7 @@
|
||||
"@nestjs/common": "^11.0.1",
|
||||
"@nestjs/core": "^11.0.1",
|
||||
"@nestjs/platform-express": "^11.0.1",
|
||||
"@nestjs/swagger": "^11.0.6",
|
||||
"@nestjs/typeorm": "^11.0.0",
|
||||
"class-transformer": "^0.5.1",
|
||||
"class-validator": "^0.14.1",
|
||||
@ -2226,6 +2227,12 @@
|
||||
"node": ">=8"
|
||||
}
|
||||
},
|
||||
"node_modules/@microsoft/tsdoc": {
|
||||
"version": "0.15.1",
|
||||
"resolved": "https://registry.npmjs.org/@microsoft/tsdoc/-/tsdoc-0.15.1.tgz",
|
||||
"integrity": "sha512-4aErSrCR/On/e5G2hDP0wjooqDdauzEbIq8hIkIe5pXV0rtWJZvdCEKL0ykZxex+IxIwBp0eGeV48hQN07dXtw==",
|
||||
"license": "MIT"
|
||||
},
|
||||
"node_modules/@napi-rs/nice": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/@napi-rs/nice/-/nice-1.0.1.tgz",
|
||||
@ -2647,6 +2654,26 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"node_modules/@nestjs/mapped-types": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/@nestjs/mapped-types/-/mapped-types-2.1.0.tgz",
|
||||
"integrity": "sha512-W+n+rM69XsFdwORF11UqJahn4J3xi4g/ZEOlJNL6KoW5ygWSmBB2p0S2BZ4FQeS/NDH72e6xIcu35SfJnE8bXw==",
|
||||
"license": "MIT",
|
||||
"peerDependencies": {
|
||||
"@nestjs/common": "^10.0.0 || ^11.0.0",
|
||||
"class-transformer": "^0.4.0 || ^0.5.0",
|
||||
"class-validator": "^0.13.0 || ^0.14.0",
|
||||
"reflect-metadata": "^0.1.12 || ^0.2.0"
|
||||
},
|
||||
"peerDependenciesMeta": {
|
||||
"class-transformer": {
|
||||
"optional": true
|
||||
},
|
||||
"class-validator": {
|
||||
"optional": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"node_modules/@nestjs/platform-express": {
|
||||
"version": "11.0.10",
|
||||
"resolved": "https://registry.npmjs.org/@nestjs/platform-express/-/platform-express-11.0.10.tgz",
|
||||
@ -2685,6 +2712,39 @@
|
||||
"typescript": ">=4.8.2"
|
||||
}
|
||||
},
|
||||
"node_modules/@nestjs/swagger": {
|
||||
"version": "11.0.6",
|
||||
"resolved": "https://registry.npmjs.org/@nestjs/swagger/-/swagger-11.0.6.tgz",
|
||||
"integrity": "sha512-W/0aQWiEfEcXKd/dYO0DbVpYhlKNVMAhO4haahUyrYe20eXaaDY0T5exA2U8IsCcXZePWZuodRUiiXo8jcMYbA==",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@microsoft/tsdoc": "0.15.1",
|
||||
"@nestjs/mapped-types": "2.1.0",
|
||||
"js-yaml": "4.1.0",
|
||||
"lodash": "4.17.21",
|
||||
"path-to-regexp": "8.2.0",
|
||||
"swagger-ui-dist": "5.19.0"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@fastify/static": "^8.0.0",
|
||||
"@nestjs/common": "^11.0.1",
|
||||
"@nestjs/core": "^11.0.1",
|
||||
"class-transformer": "*",
|
||||
"class-validator": "*",
|
||||
"reflect-metadata": "^0.1.12 || ^0.2.0"
|
||||
},
|
||||
"peerDependenciesMeta": {
|
||||
"@fastify/static": {
|
||||
"optional": true
|
||||
},
|
||||
"class-transformer": {
|
||||
"optional": true
|
||||
},
|
||||
"class-validator": {
|
||||
"optional": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"node_modules/@nestjs/testing": {
|
||||
"version": "11.0.10",
|
||||
"resolved": "https://registry.npmjs.org/@nestjs/testing/-/testing-11.0.10.tgz",
|
||||
@ -2803,6 +2863,13 @@
|
||||
"url": "https://opencollective.com/unts"
|
||||
}
|
||||
},
|
||||
"node_modules/@scarf/scarf": {
|
||||
"version": "1.4.0",
|
||||
"resolved": "https://registry.npmjs.org/@scarf/scarf/-/scarf-1.4.0.tgz",
|
||||
"integrity": "sha512-xxeapPiUXdZAE3che6f3xogoJPeZgig6omHEy1rIY5WVsB3H2BHNnZH+gHG6x91SCWyQCzWGsuL2Hh3ClO5/qQ==",
|
||||
"hasInstallScript": true,
|
||||
"license": "Apache-2.0"
|
||||
},
|
||||
"node_modules/@sec-ant/readable-stream": {
|
||||
"version": "0.4.1",
|
||||
"resolved": "https://registry.npmjs.org/@sec-ant/readable-stream/-/readable-stream-0.4.1.tgz",
|
||||
@ -4377,7 +4444,6 @@
|
||||
"version": "2.0.1",
|
||||
"resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
|
||||
"integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
|
||||
"dev": true,
|
||||
"license": "Python-2.0"
|
||||
},
|
||||
"node_modules/array-buffer-byte-length": {
|
||||
@ -9122,7 +9188,6 @@
|
||||
"version": "4.1.0",
|
||||
"resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz",
|
||||
"integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==",
|
||||
"dev": true,
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"argparse": "^2.0.1"
|
||||
@ -9372,7 +9437,6 @@
|
||||
"version": "4.17.21",
|
||||
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
|
||||
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
|
||||
"dev": true,
|
||||
"license": "MIT"
|
||||
},
|
||||
"node_modules/lodash.includes": {
|
||||
@ -12131,6 +12195,15 @@
|
||||
"url": "https://github.com/sponsors/ljharb"
|
||||
}
|
||||
},
|
||||
"node_modules/swagger-ui-dist": {
|
||||
"version": "5.19.0",
|
||||
"resolved": "https://registry.npmjs.org/swagger-ui-dist/-/swagger-ui-dist-5.19.0.tgz",
|
||||
"integrity": "sha512-bSVZeYaqanMFeW5ZY3+EejFbsjkjazYxm1I7Lz3xayYz5XU3m2aUzvuPC0jI95WCQdduszHYV3ER4buQoy8DXA==",
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"@scarf/scarf": "=1.4.0"
|
||||
}
|
||||
},
|
||||
"node_modules/symbol-observable": {
|
||||
"version": "4.0.0",
|
||||
"resolved": "https://registry.npmjs.org/symbol-observable/-/symbol-observable-4.0.0.tgz",
|
||||
|
||||
@ -23,6 +23,7 @@
|
||||
"@nestjs/common": "^11.0.1",
|
||||
"@nestjs/core": "^11.0.1",
|
||||
"@nestjs/platform-express": "^11.0.1",
|
||||
"@nestjs/swagger": "^11.0.6",
|
||||
"@nestjs/typeorm": "^11.0.0",
|
||||
"class-transformer": "^0.5.1",
|
||||
"class-validator": "^0.14.1",
|
||||
|
||||
@ -1,12 +0,0 @@
|
||||
import { Controller, Get } from '@nestjs/common';
|
||||
import { AppService } from './app.service';
|
||||
|
||||
@Controller()
|
||||
export class AppController {
|
||||
constructor(private readonly appService: AppService) {}
|
||||
|
||||
@Get()
|
||||
getHello(): string {
|
||||
return this.appService.getHello();
|
||||
}
|
||||
}
|
||||
@ -1,12 +1,10 @@
|
||||
import { Module } from '@nestjs/common';
|
||||
import { AppController } from './app.controller';
|
||||
import { AppService } from './app.service';
|
||||
import { DbModule } from './db/db.module';
|
||||
import { OracleModule } from './oracle/oracle.module';
|
||||
|
||||
@Module({
|
||||
imports: [DbModule, OracleModule],
|
||||
controllers: [AppController],
|
||||
providers: [AppService],
|
||||
controllers: [],
|
||||
providers: [],
|
||||
})
|
||||
export class AppModule {}
|
||||
|
||||
@ -1,8 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common';
|
||||
|
||||
@Injectable()
|
||||
export class AppService {
|
||||
getHello(): string {
|
||||
return 'Hello World!';
|
||||
}
|
||||
}
|
||||
17
src/main.ts
17
src/main.ts
@ -1,10 +1,27 @@
|
||||
import { NestFactory } from '@nestjs/core';
|
||||
import { AppModule } from './app.module';
|
||||
import { ValidationPipe } from '@nestjs/common';
|
||||
import { SwaggerModule, DocumentBuilder } from '@nestjs/swagger';
|
||||
import { SwaggerDocumentOptions } from '@nestjs/swagger';
|
||||
|
||||
async function bootstrap() {
|
||||
const app = await NestFactory.create(AppModule);
|
||||
app.useGlobalPipes(new ValidationPipe());
|
||||
|
||||
const config = new DocumentBuilder()
|
||||
.setTitle('API')
|
||||
.setDescription('API description')
|
||||
.setVersion('1.0')
|
||||
.addServer("http://localhost:3000", "Development Server 1")
|
||||
.addServer("https://dev.alphaomegainfosys.com/test-api", "Development Server 2")
|
||||
.build();
|
||||
|
||||
const options: SwaggerDocumentOptions = {
|
||||
autoTagControllers: false,
|
||||
};
|
||||
const documentFactory = () => SwaggerModule.createDocument(app, config, options);
|
||||
SwaggerModule.setup('api', app, documentFactory);
|
||||
|
||||
await app.listen(process.env.PORT ?? 3000);
|
||||
}
|
||||
bootstrap();
|
||||
|
||||
@ -3,6 +3,7 @@ import { OracleService } from './oracle.service';
|
||||
import { CreateBasicFeeDTO, CreateBondRateDTO, CreateCargoRateDTO, CreateCarnetSequenceDTO, CreateCfFeeDTO, CreateCsFeeDTO, CreateEfFeeDTO, CreateFeeCommDTO, CreateParamRecordDTO, CreateTableRecordDTO, InsertNewServiceProviderDTO, InsertRegionsDto, InsertSPContactsDTO, UpdateBasicFeeDTO, UpdateBondRateDTO, UpdateCargoRateDTO, UpdateCfFeeDTO, UpdateCsFeeDTO, UpdateEfFeeDTO, UpdateFeeCommDTO, UpdateParamRecordDTO, UpdateRegionDto, UpdateServiceProviderDTO, UpdateSPContactsDTO } from './oracle.dto';
|
||||
import { ParamTableService } from './paramTable.service';
|
||||
import { ManageFeeService } from './manageFee.service';
|
||||
import { ApiOperation, ApiTags } from '@nestjs/swagger';
|
||||
|
||||
@Controller('oracle')
|
||||
export class OracleController {
|
||||
@ -13,16 +14,19 @@ export class OracleController {
|
||||
|
||||
// Regions
|
||||
|
||||
@ApiTags('Regions - Oracle')
|
||||
@Post('/InsertRegions')
|
||||
insertRegions(@Body() body: InsertRegionsDto) {
|
||||
return this.oarcleService.insertRegions(body.p_region, body.p_name);
|
||||
}
|
||||
|
||||
@ApiTags('Regions - Oracle')
|
||||
@Patch('/UpdateRegion')
|
||||
updateRegions(@Body() body: UpdateRegionDto) {
|
||||
return this.oarcleService.updateRegions(body.p_regionID, body.p_name);
|
||||
}
|
||||
|
||||
@ApiTags('Regions - Oracle')
|
||||
@Get('/GetRegions')
|
||||
getRegions() {
|
||||
return this.oarcleService.getRegions();
|
||||
@ -30,6 +34,7 @@ export class OracleController {
|
||||
|
||||
// Service Provider [ SP ]
|
||||
|
||||
@ApiTags('SP - Oracle')
|
||||
@Post('/InsertNewServiceProvider')
|
||||
insertNewServiceProvider(@Body() body: InsertNewServiceProviderDTO) {
|
||||
return this.oarcleService.insertNewServiceProvider(
|
||||
@ -50,6 +55,7 @@ export class OracleController {
|
||||
)
|
||||
}
|
||||
|
||||
@ApiTags('SP - Oracle')
|
||||
@Put('/UpdateServiceProvider')
|
||||
updateServiceProider(@Body() body: UpdateServiceProviderDTO) {
|
||||
return this.oarcleService.updateServiceProvider(
|
||||
@ -71,11 +77,13 @@ export class OracleController {
|
||||
)
|
||||
}
|
||||
|
||||
@ApiTags('SP - Oracle')
|
||||
@Get('/GetAllServiceproviders')
|
||||
getAllServiceproviders() {
|
||||
return this.oarcleService.getAllServiceproviders();
|
||||
}
|
||||
|
||||
@ApiTags('SP - Oracle')
|
||||
@Get('/GetSelectedServiceprovider/:id')
|
||||
getSelectedServiceprovider(@Param('id', ParseIntPipe) id: number) {
|
||||
return this.oarcleService.getServiceproviderByID(id);
|
||||
@ -84,6 +92,7 @@ export class OracleController {
|
||||
|
||||
// SPContacts
|
||||
|
||||
@ApiTags('SPContacts - Oracle')
|
||||
@Post('/InsertSPContacts')
|
||||
insertSPContacts(@Body() body: InsertSPContactsDTO) {
|
||||
return this.oarcleService.insertSPContacts(
|
||||
@ -100,11 +109,13 @@ export class OracleController {
|
||||
)
|
||||
}
|
||||
|
||||
@ApiTags('SPContacts - Oracle')
|
||||
@Post('/SetSPDefaultcontact/:id')
|
||||
setSPDefaultcontact(@Param('id', ParseIntPipe) id: number) {
|
||||
return this.oarcleService.setSPDefaultcontact(id)
|
||||
}
|
||||
|
||||
@ApiTags('SPContacts - Oracle')
|
||||
@Put('/UpdateSPContacts')
|
||||
updateSPContacts(@Body() body: UpdateSPContactsDTO) {
|
||||
return this.oarcleService.updateSPContacts(
|
||||
@ -120,11 +131,13 @@ export class OracleController {
|
||||
)
|
||||
}
|
||||
|
||||
@ApiTags('SPContacts - Oracle')
|
||||
@Post('/InactivateSPContact/:id')
|
||||
inactivateSPContact(@Param('id', ParseIntPipe) id: number) {
|
||||
return this.oarcleService.inactivateSPContact(id)
|
||||
}
|
||||
|
||||
@ApiTags('SPContacts - Oracle')
|
||||
@Get('/GetSPDefaultcontact/:id')
|
||||
getSPDefaultcontact(@Param('id', ParseIntPipe) id: number) {
|
||||
return this.oarcleService.getSPDefaultcontacts(id)
|
||||
@ -137,6 +150,7 @@ export class OracleController {
|
||||
|
||||
// Carnet Sequence
|
||||
|
||||
@ApiTags('Carnet Sequence - Oracle')
|
||||
@Post('/CreateCarnetSequence/')
|
||||
createCarnetSequence(@Body() body: CreateCarnetSequenceDTO) {
|
||||
return this.oarcleService.createCarnetSequence(
|
||||
@ -148,6 +162,7 @@ export class OracleController {
|
||||
)
|
||||
}
|
||||
|
||||
@ApiTags('Carnet Sequence - Oracle')
|
||||
@Get('/GetCarnetSequence/:id')
|
||||
getCarnetSequence(@Param('id', ParseIntPipe) id: number) {
|
||||
return this.oarcleService.getCarnetSequence(id)
|
||||
@ -155,6 +170,7 @@ export class OracleController {
|
||||
|
||||
// param table
|
||||
|
||||
@ApiTags('Param Table - Oracle')
|
||||
@Get('/GetParamValues')
|
||||
@UsePipes()
|
||||
getParamValues(
|
||||
@ -164,11 +180,13 @@ export class OracleController {
|
||||
return this.paramTableService.GETPARAMVALUES(id ? Number(id) : undefined, type);
|
||||
}
|
||||
|
||||
@ApiTags('Param Table - Oracle')
|
||||
@Post('/CreateTableRecord')
|
||||
createTableRecord(@Body() body: CreateTableRecordDTO) {
|
||||
return this.paramTableService.CREATETABLERECORD(body.P_USERID, body.P_TABLEFULLDESC)
|
||||
}
|
||||
|
||||
@ApiTags('Param Table - Oracle')
|
||||
@Post('/CreateParamRecord')
|
||||
createParamRecord(@Body() body: CreateParamRecordDTO) {
|
||||
return this.paramTableService.CREATEPARAMRECORD(
|
||||
@ -186,17 +204,21 @@ export class OracleController {
|
||||
)
|
||||
}
|
||||
|
||||
@ApiTags('Param Table - Oracle')
|
||||
@Patch('/UpdateParamRecord')
|
||||
UpdateParamRecord(@Body() body: UpdateParamRecordDTO) {
|
||||
return this.paramTableService.UPDATEPARAMRECORD(body)
|
||||
}
|
||||
|
||||
@ApiTags('Param Table - Oracle')
|
||||
@Patch('/InActivateParamRecord')
|
||||
inActivateParamRecord(@Query('pid') pid,@Query('uid') uid) {
|
||||
return this.paramTableService.INACTIVATEPARAMRECORD(pid?Number(pid):pid,uid)
|
||||
}
|
||||
|
||||
@ApiTags('Param Table - Oracle')
|
||||
@Patch('/ReActivateParamRecord')
|
||||
@ApiOperation({ summary: 'Retrieve all users', description: 'This endpoint returns a list of all users.' })
|
||||
reActivateParamRecord(@Query('pid') pid,@Query('uid') uid) {
|
||||
return this.paramTableService.REACTIVATEPARAMRECORD(pid?Number(pid):pid,uid)
|
||||
}
|
||||
@ -204,106 +226,127 @@ export class OracleController {
|
||||
|
||||
// ManageFee
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Post('/CreateBasicFee')
|
||||
CreateBasicFee(@Body() body: CreateBasicFeeDTO) {
|
||||
return this.manageFeeService.CREATEBASICFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Post('/CreateBondRate')
|
||||
CreateBondRate(@Body() body: CreateBondRateDTO) {
|
||||
return this.manageFeeService.CREATEBONDRATE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Post('/CreateCargoRate')
|
||||
CreateCargoRate(@Body() body: CreateCargoRateDTO) {
|
||||
return this.manageFeeService.CREATECARGORATE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Post('/CreateCfFee')
|
||||
CreateCfFee(@Body() body: CreateCfFeeDTO) {
|
||||
return this.manageFeeService.CREATECFFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Post('/CreateCsFee')
|
||||
CreateCsFee(@Body() body: CreateCsFeeDTO) {
|
||||
return this.manageFeeService.CREATECSFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Post('/CreateEfFee')
|
||||
CreateEeFee(@Body() body: CreateEfFeeDTO) {
|
||||
return this.manageFeeService.CREATEEFFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Post('/CreateFeeComm')
|
||||
CreateFeeComm(@Body() body: CreateFeeCommDTO) {
|
||||
return this.manageFeeService.CREATEFEECOMM(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Patch('/UpdateBasicFee')
|
||||
UpdateBasicFee(@Body() body: UpdateBasicFeeDTO) {
|
||||
return this.manageFeeService.UPDATEBASICFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Patch('/UpdateBondRate')
|
||||
UpdateBondRate(@Body() body: UpdateBondRateDTO) {
|
||||
return this.manageFeeService.UPDATEBONDRATE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Patch('/UpdateCargoRate')
|
||||
UpdateCargoRate(@Body() body: UpdateCargoRateDTO) {
|
||||
return this.manageFeeService.UPDATECARGORATE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Patch('/UpdateCfFee')
|
||||
UpdateCfFee(@Body() body: UpdateCfFeeDTO) {
|
||||
return this.manageFeeService.UPDATECFFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Patch('/UpdateCsFee')
|
||||
UpdateCsFee(@Body() body: UpdateCsFeeDTO) {
|
||||
return this.manageFeeService.UPDATECSFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Patch('/UpdateEfFee')
|
||||
UpdateEfFee(@Body() body: UpdateEfFeeDTO) {
|
||||
return this.manageFeeService.UPDATEEFFEE(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Patch('/UpdateFeeComm')
|
||||
UpdateFeeComm(@Body() body: UpdateFeeCommDTO) {
|
||||
return this.manageFeeService.UPDATEFEECOMM(body)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Get('/GetBasicFeeRates/:id')
|
||||
GetBasicFeeRates(@Param('id', ParseIntPipe) id: number) {
|
||||
return this.manageFeeService.GETBASICFEERATES(id)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Get('/GetBondRates/:id')
|
||||
GetBondRates( @Param('id', ParseIntPipe) id: number) {
|
||||
return this.manageFeeService.GETBONDRATES(id)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Get('/GetCargoRates/:id')
|
||||
GetCargoRates( @Param('id', ParseIntPipe) id: number) {
|
||||
return this.manageFeeService.GETCARGORATES(id)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Get('/GetCfFeeRates/:id')
|
||||
GetCfFeeRates( @Param('id', ParseIntPipe) id: number) {
|
||||
return this.manageFeeService.GETCFFEERATES(id)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Get('/GetCsFeeRates/:id')
|
||||
GetCsFeeRates( @Param('id', ParseIntPipe) id: number) {
|
||||
return this.manageFeeService.GETCSFEERATES(id)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Get('/GetEfFeeRates/:id')
|
||||
GetEfFeeRates( @Param('id', ParseIntPipe) id: number) {
|
||||
return this.manageFeeService.GETEFFEERATES(id)
|
||||
}
|
||||
|
||||
@ApiTags('Manage Fee - Oracle')
|
||||
@Get('/GetFeeComm/:id')
|
||||
GetFeeComm( @Param('id', ParseIntPipe) id: number) {
|
||||
return this.manageFeeService.GETFEECOMM(id)
|
||||
|
||||
@ -1,17 +1,22 @@
|
||||
import { ApiProperty } from '@nestjs/swagger';
|
||||
import { IsEmail, IsNumber, IsOptional, IsString } from 'class-validator';
|
||||
|
||||
export class InsertRegionsDto {
|
||||
@ApiProperty()
|
||||
@IsString()
|
||||
p_region: string;
|
||||
|
||||
@ApiProperty()
|
||||
@IsString()
|
||||
p_name: string;
|
||||
}
|
||||
|
||||
export class UpdateRegionDto {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_regionID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_name: string;
|
||||
}
|
||||
@ -22,92 +27,121 @@ export class UpdateRegionDto {
|
||||
// }
|
||||
|
||||
export class InsertNewServiceProviderDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_name: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_lookupcode: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_address1: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsString()
|
||||
p_address2: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_city: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_state: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_zip: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_country: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_issuingregion: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_replacementregion: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_bondsurety: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_cargopolicyno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_cargosurety: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_user_id: string;
|
||||
}
|
||||
|
||||
export class UpdateServiceProviderDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_spid: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_name: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_lookupcode: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_address1: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsString()
|
||||
p_address2: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_city: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_state: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_zip: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_country: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_issuingregion: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_replacementregion: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_bondsurety: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_cargopolicyno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_cargosurety: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_user_id: string;
|
||||
}
|
||||
@ -118,424 +152,550 @@ export class UpdateServiceProviderDTO {
|
||||
// }
|
||||
|
||||
export class InsertSPContactsDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_spid: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_defcontactflag: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_firstname: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_lastname: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_title: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_phoneno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_mobileno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_faxno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsEmail()
|
||||
p_emailaddress: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_user_id: string;
|
||||
}
|
||||
|
||||
export class UpdateSPContactsDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_spcontactid: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_firstname: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_lastname: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_title: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_phoneno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_mobileno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_faxno: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsEmail()
|
||||
p_emailaddress: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_user_id: string;
|
||||
}
|
||||
|
||||
export class CreateCarnetSequenceDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_spid: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_regionid: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_startnumber: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
p_endnumber: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
p_carnettype: string
|
||||
p_carnettype: string;
|
||||
}
|
||||
|
||||
export class CreateTableRecordDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_TABLEFULLDESC: string
|
||||
P_TABLEFULLDESC: string;
|
||||
}
|
||||
|
||||
export class CreateParamRecordDTO {
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsNumber()
|
||||
P_SPID?: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_PARAMTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_PARAMDESC: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_PARAMVALUE: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE1?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE2?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE3?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE4?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE5?: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SORTSEQ: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
|
||||
export class UpdateParamRecordDTO {
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsNumber()
|
||||
P_SPID?: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_PARAMID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_PARAMDESC: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE1?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE2?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE3?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE4?: string;
|
||||
|
||||
@ApiProperty({ required: false })
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
P_ADDLPARAMVALUE5?: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SORTSEQ: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class CreateBasicFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_STARTCARNETVALUE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_ENDCARNETVALUE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_FEES: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class CreateBondRateDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_HOLDERTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USCIBMEMBERFLAG: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_SPCLCOMMODITY: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_SPCLCOUNTRY: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class CreateCargoRateDTO {
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_CARNETTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_STARTSETS: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_ENDSETS: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class CreateCfFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_STARTSETS: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_ENDSETS: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_CUSTOMERTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_CARNETTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class CreateCsFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_CUSTOMERTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_CARNETTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class CreateEfFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_CUSTOMERTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_DELIVERYTYPE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_STARTTIME: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_ENDTIME: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_TIMEZONE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_FEES: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class CreateFeeCommDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_SPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_PARAMID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_COMMRATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class UpdateBasicFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_BASICFEESETUPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_FEES: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class UpdateBondRateDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_BONDRATESETUPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class UpdateCargoRateDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_CARGORATESETUPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class UpdateCfFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_CFFEESETUPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class UpdateCsFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_CSFEESETUPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class UpdateEfFeeDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_EFFEESETUPID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_FEES: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
|
||||
export class UpdateFeeCommDTO {
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_FEECOMMID: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsNumber()
|
||||
P_RATE: number;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_EFFDATE: string;
|
||||
|
||||
@ApiProperty({ required: true })
|
||||
@IsString()
|
||||
P_USERID: string;
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user