Добавлена кнопка "Сотрудники" в боковую панель для фулфилмент центров, улучшен интерфейс отображения товаров в избранном с изменением стилей на сетку. Перемещен статус наличия товара для лучшего восприятия.
This commit is contained in:
@ -11,7 +11,8 @@ import {
|
||||
Store,
|
||||
MessageCircle,
|
||||
Wrench,
|
||||
Warehouse
|
||||
Warehouse,
|
||||
Users
|
||||
} from 'lucide-react'
|
||||
|
||||
export function Sidebar() {
|
||||
@ -71,11 +72,16 @@ export function Sidebar() {
|
||||
router.push('/warehouse')
|
||||
}
|
||||
|
||||
const handleEmployeesClick = () => {
|
||||
router.push('/employees')
|
||||
}
|
||||
|
||||
const isSettingsActive = pathname === '/settings'
|
||||
const isMarketActive = pathname.startsWith('/market')
|
||||
const isMessengerActive = pathname.startsWith('/messenger')
|
||||
const isServicesActive = pathname.startsWith('/services')
|
||||
const isWarehouseActive = pathname.startsWith('/warehouse')
|
||||
const isEmployeesActive = pathname.startsWith('/employees')
|
||||
|
||||
return (
|
||||
<div className="fixed left-0 top-0 h-full w-56 bg-white/10 backdrop-blur-xl border-r border-white/20 p-3">
|
||||
@ -158,6 +164,22 @@ export function Sidebar() {
|
||||
</Button>
|
||||
)}
|
||||
|
||||
{/* Сотрудники - только для фулфилмент центров */}
|
||||
{user?.organization?.type === 'FULFILLMENT' && (
|
||||
<Button
|
||||
variant={isEmployeesActive ? "secondary" : "ghost"}
|
||||
className={`w-full justify-start text-left transition-all duration-200 h-8 text-xs ${
|
||||
isEmployeesActive
|
||||
? 'bg-white/20 text-white hover:bg-white/30'
|
||||
: 'text-white/80 hover:bg-white/10 hover:text-white'
|
||||
} cursor-pointer`}
|
||||
onClick={handleEmployeesClick}
|
||||
>
|
||||
<Users className="h-3 w-3 mr-2" />
|
||||
Сотрудники
|
||||
</Button>
|
||||
)}
|
||||
|
||||
{/* Склад - только для оптовиков */}
|
||||
{user?.organization?.type === 'WHOLESALE' && (
|
||||
<Button
|
||||
|
Reference in New Issue
Block a user