diff --git a/worklenz-frontend/src/features/finance/ratecard-drawer/ratecard-drawer.tsx b/worklenz-frontend/src/features/finance/ratecard-drawer/ratecard-drawer.tsx
index 70db6293..2855cea0 100644
--- a/worklenz-frontend/src/features/finance/ratecard-drawer/ratecard-drawer.tsx
+++ b/worklenz-frontend/src/features/finance/ratecard-drawer/ratecard-drawer.tsx
@@ -1,4 +1,4 @@
-import { Drawer, Select, Typography, Flex, Button, Input, Table } from 'antd';
+import { Drawer, Select, Typography, Flex, Button, Input, Table, Popconfirm, Tooltip } from 'antd';
import React, { useEffect, useMemo, useState } from 'react';
import { useTranslation } from 'react-i18next';
import { useAppSelector } from '../../../hooks/useAppSelector';
@@ -7,7 +7,8 @@ import { deleteRateCard, fetchRateCardById, fetchRateCards, toggleRatecardDrawer
import { RatecardType, IJobType } from '@/types/project/ratecard.types';
import { IJobTitlesViewModel } from '@/types/job.types';
import { jobTitlesApiService } from '@/api/settings/job-titles/job-titles.api.service';
-import { DeleteOutlined } from '@ant-design/icons';
+import { DeleteOutlined, ExclamationCircleFilled } from '@ant-design/icons';
+import { colors } from '@/styles/colors';
interface PaginationType {
current: number;
@@ -220,7 +221,7 @@ const RatecardDrawer = ({
setAddingRowIndex(null);
}}
onBlur={() => {
- if (roles[index].job_title_id === ""){
+ if (roles[index].job_title_id === "") {
handleDeleteRole(index);
}
setEditingRowIndex(null);
@@ -244,7 +245,7 @@ const RatecardDrawer = ({
return (
setEditingRowIndex(index)}
+ // onClick={() => setEditingRowIndex(index)}
>
{record.jobtitle}
@@ -280,11 +281,25 @@ const RatecardDrawer = ({
title: t('actionsColumn') || 'Actions',
dataIndex: 'actions',
render: (_: any, __: any, index: number) => (
- }
- onClick={() => handleDeleteRole(index)}
- />
+ }
+ okText={t('deleteConfirmationOk')}
+ cancelText={t('deleteConfirmationCancel')}
+ onConfirm={async () => {
+ if (index) {
+ handleDeleteRole(index);
+ }
+ }}
+ >
+
+ }
+ />
+
+
+
),
},
];
@@ -344,7 +359,7 @@ const RatecardDrawer = ({
width={700}
footer={
-
+
}
>
@@ -356,13 +371,13 @@ const RatecardDrawer = ({
pagination={false}
footer={() => (
+ type="dashed"
+ onClick={handleAddRole}
+ block
+ style={{ margin: 0, padding: 0 }}
+ >
+ {t('addRoleButton')}
+
)}
/>