Fixed change management rendering error
This commit is contained in:
@@ -36,6 +36,7 @@ import { useToast } from '../components/ui/Toast';
|
||||
import { ExportButton } from '../components/ui/ExportButton';
|
||||
import { ExportColumn } from '../utils/exportUtils';
|
||||
import { useTableSort, SortableTh } from '../utils/tableSort';
|
||||
import { ApprovalStatusBadge, PriorityBadge } from '../components/ui/StatusBadge';
|
||||
import { Issue, ChangeRequest, ApprovalStatus, ActivityStatus, Priority } from '../types';
|
||||
import {
|
||||
getApprovalStatusBadge,
|
||||
@@ -484,7 +485,7 @@ export const ChangeManagementPage: React.FC = () => {
|
||||
<div className="flex items-center gap-1.5 text-xs text-slate-400">
|
||||
<FolderKanban className="w-3.5 h-3.5 text-amber-400" />
|
||||
<select
|
||||
value={selectedProjectId}
|
||||
value={effectiveProjectId ? String(effectiveProjectId) : ''}
|
||||
onChange={(e) => setSelectedProjectId(e.target.value)}
|
||||
className="bg-slate-900 border border-slate-800 rounded-xl px-3 py-1.5 text-xs text-white focus:outline-none focus:border-amber-500 max-w-[180px] truncate"
|
||||
>
|
||||
@@ -587,7 +588,9 @@ export const ChangeManagementPage: React.FC = () => {
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td className="py-3.5 px-4 whitespace-nowrap">{getPriorityBadge(iss.priority)}</td>
|
||||
<td className="py-3.5 px-4 whitespace-nowrap">
|
||||
<PriorityBadge priority={iss.priority} />
|
||||
</td>
|
||||
<td className="py-3.5 px-4 whitespace-nowrap text-slate-300">
|
||||
<div className="flex items-center gap-1.5">
|
||||
<User className="w-3.5 h-3.5 text-slate-400" />
|
||||
@@ -678,7 +681,7 @@ export const ChangeManagementPage: React.FC = () => {
|
||||
<div className="flex items-center gap-1.5 text-xs text-slate-400">
|
||||
<FolderKanban className="w-3.5 h-3.5 text-amber-400" />
|
||||
<select
|
||||
value={selectedProjectId}
|
||||
value={effectiveProjectId ? String(effectiveProjectId) : ''}
|
||||
onChange={(e) => setSelectedProjectId(e.target.value)}
|
||||
className="bg-slate-900 border border-slate-800 rounded-xl px-3 py-1.5 text-xs text-white focus:outline-none focus:border-amber-500 max-w-[180px] truncate"
|
||||
>
|
||||
@@ -784,7 +787,9 @@ export const ChangeManagementPage: React.FC = () => {
|
||||
<td className="py-3.5 px-4 whitespace-nowrap font-mono font-semibold text-slate-200">
|
||||
{formatZAR(cr.revisedBudget || 0)}
|
||||
</td>
|
||||
<td className="py-3.5 px-4 whitespace-nowrap">{getApprovalStatusBadge(cr.status)}</td>
|
||||
<td className="py-3.5 px-4 whitespace-nowrap">
|
||||
<ApprovalStatusBadge status={cr.status} />
|
||||
</td>
|
||||
<td className="py-3.5 px-5 text-right whitespace-nowrap space-x-2">
|
||||
{cr.status === ApprovalStatus.Approved ? (
|
||||
<span className="text-xs font-semibold text-emerald-400 bg-emerald-500/10 px-2.5 py-1 rounded-lg border border-emerald-500/20">
|
||||
|
||||
Reference in New Issue
Block a user