feat: migrate timestamps to int64 and security improvements

- Convert all time.Time fields to int64 Unix milliseconds (UTC)
- Add PostgreSQL migration to convert timestamp columns to bigint
- Reduce Binance sync window from 7 days to 24 hours
- Fix dashboard trader name visibility (add nofx-text-main color)
- Add position value column to history table
- Remove hardcoded API keys from test files
This commit is contained in:
tinkle-community
2026-01-06 15:56:07 +08:00
parent 5c4c9cdc99
commit 799d8b9c2e
22 changed files with 1620 additions and 231 deletions

View File

@@ -303,6 +303,11 @@ function PositionRow({ position }: { position: HistoricalPosition }) {
{displayQty.toFixed(4)}
</td>
{/* Position Value (Entry Price * Quantity) */}
<td className="py-3 px-4 text-right font-mono" style={{ color: '#EAECEF' }}>
{formatNumber(entryPrice * displayQty)}
</td>
{/* P&L */}
<td className="py-3 px-4 text-right">
<div className="font-mono font-semibold" style={{ color: pnlColor }}>
@@ -764,6 +769,12 @@ export function PositionHistory({ traderId }: PositionHistoryProps) {
>
{t('positionHistory.qty', language)}
</th>
<th
className="py-3 px-4 text-right text-xs font-semibold uppercase tracking-wider"
style={{ color: '#848E9C' }}
>
{t('positionHistory.value', language)}
</th>
<th
className="py-3 px-4 text-right text-xs font-semibold uppercase tracking-wider"
style={{ color: '#848E9C' }}