budgest table add name and remove commited column
This commit is contained in:
@@ -561,7 +561,7 @@ const OwnerProjectDetail = () => {
|
||||
<Plus size={14} /> Add Cost
|
||||
</button>
|
||||
</div>
|
||||
<p className="text-xs text-zinc-400 mb-6 font-mono">Allocated vs Committed vs Actual ($k)</p>
|
||||
<p className="text-xs text-zinc-400 mb-6 font-mono">Allocated vs Actual ($k)</p>
|
||||
<div className="h-64 bg-zinc-50 dark:bg-black/20 rounded-xl p-4 border border-zinc-200 dark:border-white/5">
|
||||
<ResponsiveContainer width="99%" height={256} minWidth={1} minHeight={1}>
|
||||
<BarChart data={budgetChartData} barGap={2}>
|
||||
@@ -569,7 +569,6 @@ const OwnerProjectDetail = () => {
|
||||
<YAxis tick={{ fontSize: 11, fill: '#a1a1aa' }} axisLine={false} tickLine={false} />
|
||||
<Tooltip content={<CustomTooltip />} />
|
||||
<Bar dataKey="allocated" name="Allocated" fill="#3b82f6" radius={[4, 4, 0, 0]} />
|
||||
<Bar dataKey="committed" name="Committed" fill="#f59e0b" radius={[4, 4, 0, 0]} />
|
||||
<Bar dataKey="actual" name="Actual" fill="#22c55e" radius={[4, 4, 0, 0]} />
|
||||
</BarChart>
|
||||
</ResponsiveContainer>
|
||||
@@ -580,8 +579,8 @@ const OwnerProjectDetail = () => {
|
||||
<table className="w-full text-left border-collapse min-w-[600px]">
|
||||
<thead className="bg-zinc-100 dark:bg-[#18181b]/80 border-b border-zinc-200 dark:border-white/10">
|
||||
<tr>
|
||||
{['Category', 'Allocated', 'Committed', 'Actual', 'Variance'].map(h => (
|
||||
<th key={h} className={`px-5 py-4 text-xs font-bold uppercase tracking-wider text-zinc-400 ${h !== 'Category' ? 'text-right' : ''}`}>{h}</th>
|
||||
{['Name', 'Category', 'Allocated', 'Actual', 'Variance'].map(h => (
|
||||
<th key={h} className={`px-5 py-4 text-xs font-bold uppercase tracking-wider text-zinc-400 ${h !== 'Name' && h !== 'Category' ? 'text-right' : ''}`}>{h}</th>
|
||||
))}
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -590,9 +589,9 @@ const OwnerProjectDetail = () => {
|
||||
const variance = b.actual - b.allocated;
|
||||
return (
|
||||
<tr key={i} className="hover:bg-zinc-50 dark:hover:bg-white/5 transition-colors">
|
||||
<td className="px-5 py-4 text-sm text-zinc-500 dark:text-zinc-400">{b.name || '—'}</td>
|
||||
<td className="px-5 py-4 font-bold text-sm text-zinc-900 dark:text-white">{b.category}</td>
|
||||
<td className="px-5 py-4 text-right font-mono text-sm text-zinc-600 dark:text-zinc-300">{formatCurrency(b.allocated)}</td>
|
||||
<td className="px-5 py-4 text-right font-mono text-sm text-amber-500">{formatCurrency(b.committed)}</td>
|
||||
<td className="px-5 py-4 text-right font-mono text-sm text-[#00f0ff]">{formatCurrency(b.actual)}</td>
|
||||
<td className={`px-5 py-4 text-right font-mono text-sm font-bold ${variance > 0 ? 'text-[#ff4500]' : 'text-[#39ff14]'}`}>
|
||||
{variance > 0 ? '+' : ''}{formatCurrency(variance)}
|
||||
|
||||
Reference in New Issue
Block a user