Skip to content
This repository has been archived by the owner on Feb 29, 2024. It is now read-only.

Commit

Permalink
Merge pull request #316 from kmcwebdev/development
Browse files Browse the repository at this point in the history
Add reference number to approve request email schema and service
  • Loading branch information
csulit authored Oct 9, 2023
2 parents 4e270ea + a0822d0 commit 63da6af
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/finance/common/zod-schema/approve-email.schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { z } from 'zod';
export const ApproveRequestEmailSchema = z.object({
to: z.array(z.string().email()),
fullName: z.string().nonempty(),
referenceNo: z.string().nonempty(),
employeeId: z.string().nonempty(),
expenseType: z.string().nonempty(),
expenseDate: z.string().nonempty(),
Expand Down
2 changes: 2 additions & 0 deletions src/finance/services/reimbursement.approve.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ export class ReimbursementApproveService {
)
.returning([
'frr.reimbursement_request_id',
'frr.reference_no',
'frr.requestor_id',
'frr.expense_type_id',
'frr.amount',
Expand Down Expand Up @@ -181,6 +182,7 @@ export class ReimbursementApproveService {
const approveRequestEmailData: ApproveRequestEmailType = {
to: [requestor.email],
fullName: requestor.full_name,
referenceNo: updateReimbursementRequest.reference_no,
employeeId: requestor.employee_id,
expenseType: expenseType.expense_type,
expenseDate: updateReimbursementRequest.created_at.toString(),
Expand Down

0 comments on commit 63da6af

Please sign in to comment.