Move cart flow to catalog add and simplify checkout list

This commit is contained in:
Ruslan Bakiev
2026-04-02 18:28:57 +07:00
parent caa9b9fba5
commit 88e5c248f4
4 changed files with 261 additions and 156 deletions

View File

@@ -3,14 +3,28 @@ const props = defineProps<{
status: string;
}>();
const statusLabel = computed(() => {
if (props.status === 'NEW') return 'Уточнение цены';
if (props.status === 'MANAGER_PROCESSING') return 'В работе у менеджера';
if (props.status === 'WAITING_DOUBLE_CONFIRM') return 'Ожидает подтверждения';
if (props.status === 'CONFIRMED') return 'Подтвержден';
if (props.status === 'IN_PROGRESS') return 'Выполняется';
if (props.status === 'COMPLETED') return 'Завершен';
if (props.status === 'CLIENT_REJECTED') return 'Отклонен клиентом';
if (props.status === 'MANAGER_REJECTED') return 'Отклонен менеджером';
if (props.status === 'MANAGER_BLOCKED') return 'Заблокирован';
return props.status;
});
const className = computed(() => {
if (props.status === 'COMPLETED') return 'badge badge-success';
if (props.status === 'CLIENT_REJECTED' || props.status === 'MANAGER_REJECTED') return 'badge badge-error';
if (props.status === 'MANAGER_BLOCKED') return 'badge badge-warning';
if (props.status === 'NEW') return 'badge badge-warning';
return 'badge badge-info';
});
</script>
<template>
<span :class="className">{{ status }}</span>
<span :class="className">{{ statusLabel }}</span>
</template>