Skip to content

Commit

Permalink
fix: Review email
Browse files Browse the repository at this point in the history
  • Loading branch information
chavda-bhavik committed Oct 24, 2024
1 parent 618ae64 commit 75ab3f9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
7 changes: 3 additions & 4 deletions apps/api/src/app/review/review.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import {
import { APIMessages } from '@shared/constants';
import { JwtAuthGuard } from '@shared/framework/auth.gaurd';
import { validateUploadStatus } from '@shared/helpers/upload.helpers';
import { Defaults, ACCESS_KEY_NAME, UploadStatusEnum, ReviewDataTypesEnum, IJwtPayload } from '@impler/shared';
import { Defaults, ACCESS_KEY_NAME, UploadStatusEnum, ReviewDataTypesEnum } from '@impler/shared';

import {
Replace,
Expand All @@ -29,7 +29,6 @@ import {
UpdateRecords,
} from './usecases';

import { UserSession } from '@shared/framework/user.decorator';
import { validateNotFound } from '@shared/helpers/common.helper';
import { DeleteRecordsDto, UpdateRecordDto, ReplaceDto } from './dtos';
import { PaginationResponseDto } from '@shared/dtos/pagination-response.dto';
Expand Down Expand Up @@ -124,7 +123,7 @@ export class ReviewController {
@ApiOperation({
summary: 'Confirm review data for uploaded file',
})
async doConfirmReview(@UserSession() user: IJwtPayload, @Param('uploadId', ValidateMongoId) _uploadId: string) {
async doConfirmReview(@Param('uploadId', ValidateMongoId) _uploadId: string) {
const uploadInformation = await this.getUpload.execute({
uploadId: _uploadId,
select: 'status _validDataFileId _invalidDataFileId totalRecords invalidRecords _templateId',
Expand All @@ -136,7 +135,7 @@ export class ReviewController {
// upload files with status reviewing can only be confirmed
validateUploadStatus(uploadInformation.status as UploadStatusEnum, [UploadStatusEnum.REVIEWING]);

return this.startProcess.execute(_uploadId, user.email);
return this.startProcess.execute(_uploadId);
}

@Put(':uploadId/record')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export class StartProcess {
private paymentAPIService: PaymentAPIService
) {}

async execute(_uploadId: string, email: string) {
async execute(_uploadId: string) {
let uploadInfo = await this.uploadRepository.getUploadWithTemplate(_uploadId, ['destination']);
let importedData;
const destination = (uploadInfo._templateId as unknown as TemplateEntity)?.destination;
Expand Down Expand Up @@ -72,7 +72,7 @@ export class StartProcess {
uploadedFileId: uploadInfo._uploadedFileId,
});

return { uploadInfo, importedData, email };
return { uploadInfo, importedData };
}

async getImportedData({
Expand Down

0 comments on commit 75ab3f9

Please sign in to comment.