Skip to content

Commit 894f640

Browse files
lint issues
1 parent 7d905ee commit 894f640

2 files changed

Lines changed: 7 additions & 6 deletions

File tree

src/components/PlannedCostDonutChart/PlannedCostDonutChart.jsx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -203,9 +203,7 @@ const PlannedCostDonutChart = () => {
203203
}
204204

205205
return (
206-
<div
207-
className={`${styles['planned-cost-container']} ${darkMode ? styles['dark-mode'] : ''}`}
208-
>
206+
<div className={`${styles['planned-cost-container']} ${darkMode ? styles['dark-mode'] : ''}`}>
209207
<h2 className={styles['chart-title']}>Planned Cost Breakdown by Type of Expenditure</h2>
210208

211209
{/* Project Filter */}
@@ -230,9 +228,7 @@ const PlannedCostDonutChart = () => {
230228
setSearchTerm('');
231229
}}
232230
/>
233-
<span
234-
className={`${styles['dropdown-arrow']} ${dropdownOpen ? styles.open : ''}`}
235-
>
231+
<span className={`${styles['dropdown-arrow']} ${dropdownOpen ? styles.open : ''}`}>
236232
&#9662;
237233
</span>
238234
{dropdownOpen && (

src/components/PlannedCostDonutChart/plannedCostService.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ export const fetchProjects = async () => {
1919

2020
return response.data || [];
2121
} catch (error) {
22+
// eslint-disable-next-line no-console
2223
console.error('Error fetching projects:', error);
2324
throw new Error('Failed to fetch projects');
2425
}
@@ -45,6 +46,7 @@ export const fetchPlannedCostBreakdown = async projectId => {
4546

4647
return response.data;
4748
} catch (error) {
49+
// eslint-disable-next-line no-console
4850
console.error('Error fetching planned cost breakdown:', error);
4951
throw new Error(error.response?.data?.message || 'Failed to fetch planned cost breakdown');
5052
}
@@ -77,6 +79,7 @@ export const createOrUpdatePlannedCost = async (projectId, category, plannedCost
7779

7880
return response.data;
7981
} catch (error) {
82+
// eslint-disable-next-line no-console
8083
console.error('Error creating/updating planned cost:', error);
8184
throw new Error(error.response?.data?.message || 'Failed to create/update planned cost');
8285
}
@@ -104,6 +107,7 @@ export const deletePlannedCost = async (projectId, category) => {
104107

105108
return response.data;
106109
} catch (error) {
110+
// eslint-disable-next-line no-console
107111
console.error('Error deleting planned cost:', error);
108112
throw new Error(error.response?.data?.message || 'Failed to delete planned cost');
109113
}
@@ -127,6 +131,7 @@ export const getAllPlannedCostsForProject = async projectId => {
127131

128132
return response.data || [];
129133
} catch (error) {
134+
// eslint-disable-next-line no-console
130135
console.error('Error fetching all planned costs:', error);
131136
throw new Error(error.response?.data?.message || 'Failed to fetch planned costs');
132137
}

0 commit comments

Comments
 (0)