Format campaign last modified date for better readability
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
f1776df710
commit
a4d67fdf46
1 changed files with 9 additions and 1 deletions
|
|
@ -26,6 +26,14 @@ import { ExportIcon } from './icons/ExportIcon';
|
|||
import { XIcon } from './icons/XIcon';
|
||||
import apiService from '../services/apiService';
|
||||
|
||||
const formatDate = (isoDateString: string): string => {
|
||||
const date = new Date(isoDateString);
|
||||
return date.toLocaleDateString('en-US', {
|
||||
month: 'short',
|
||||
day: 'numeric',
|
||||
year: 'numeric'
|
||||
});
|
||||
};
|
||||
|
||||
export const initialCampaigns = [
|
||||
{
|
||||
|
|
@ -347,7 +355,7 @@ const CampaignList: React.FC<{
|
|||
</td>
|
||||
<td className="px-6 py-4 whitespace-nowrap text-sm text-gray-700">{campaign.agencyLead}</td>
|
||||
<td className="px-6 py-4 whitespace-nowrap text-sm text-gray-700">{campaign.agency}</td>
|
||||
<td className="px-6 py-4 whitespace-nowrap text-sm text-gray-700">{campaign.lastModified}</td>
|
||||
<td className="px-6 py-4 whitespace-nowrap text-sm text-gray-700">{formatDate(campaign.lastModified)}</td>
|
||||
</tr>
|
||||
);
|
||||
})}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue