feat(ui): добавить UI элементы для V2 системы поставок

- Добавить кнопку "Создать поставку V2" в dashboard фулфилмента
- Добавить кнопку "Принять на склад" для статуса SHIPPED
- Интегрировать с новой V2 архитектурой поставок

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Veronika Smirnova
2025-08-27 12:30:49 +03:00
parent 0f52d8da8b
commit 8391f40e87
2 changed files with 39 additions and 10 deletions

View File

@ -384,7 +384,22 @@ export function FulfillmentSuppliesDashboard() {
{/* КОНТЕНТ ДЛЯ НОВОЙ СИСТЕМЫ ПОСТАВОК V2 */} {/* КОНТЕНТ ДЛЯ НОВОЙ СИСТЕМЫ ПОСТАВОК V2 */}
{activeTab === 'fulfillment' && activeSubTab === 'consumables-v2' && ( {activeTab === 'fulfillment' && activeSubTab === 'consumables-v2' && (
<div className="h-full overflow-hidden"> <div className="h-full overflow-hidden">
<div className="text-white/80">Контент V2 системы (удален)</div> <div className="text-center py-12">
<Building2 className="h-16 w-16 text-white/40 mx-auto mb-6" />
<h3 className="text-xl font-semibold text-white mb-4">
Система поставок расходников V2
</h3>
<p className="text-white/60 mb-6 max-w-md mx-auto">
Создавайте заявки на расходники для фулфилмент-центра через новую систему V2
</p>
<a
href="/supplies/create-fulfillment-consumables-v2"
className="inline-flex items-center gap-2 bg-gradient-to-r from-purple-500 to-pink-500 hover:from-purple-600 hover:to-pink-600 text-white font-semibold py-3 px-6 rounded-lg transition-all duration-200 shadow-lg hover:shadow-xl"
>
<Package className="h-5 w-5" />
Создать поставку V2
</a>
</div>
</div> </div>
)} )}

View File

@ -614,6 +614,21 @@ export function MultiLevelSuppliesTable({
</Button> </Button>
) )
} }
if (status === 'SHIPPED') {
return (
<Button
size="sm"
onClick={(e) => {
e.stopPropagation()
onSupplyAction?.(id, 'receive')
}}
className="bg-green-500/20 hover:bg-green-500/30 text-green-300 border border-green-500/30"
>
<Package className="h-3 w-3 mr-1" />
Принять на склад
</Button>
)
}
break break
case 'LOGIST': // Логист case 'LOGIST': // Логист
@ -958,15 +973,14 @@ export function MultiLevelSuppliesTable({
</TableCell> </TableCell>
)} )}
<TableCell> <TableCell>
{/* 🔒 УСЛОВНЫЙ РЕНДЕРИНГ: Кнопки для WHOLESALE во вкладке "Новые" */} {/* 🔒 УСЛОВНЫЙ РЕНДЕРИНГ: Кнопки действий или статус */}
{userRole === 'WHOLESALE' && activeTab === 'new' && supply.status === 'PENDING' ? ( {(() => {
<ActionButtons const actionButtons = _renderActionButtons(supply)
supplyId={supply.id} if (actionButtons) {
onSupplyAction={onSupplyAction} return actionButtons
/> }
) : ( return <StatusBadge status={supply.status} />
<StatusBadge status={supply.status} /> })()}
)}
</TableCell> </TableCell>
</TableRow> </TableRow>