'use client';

import { useSearchParams } from 'next/navigation';
import { OrderManagementListClient, OrderDetailForm } from '@/components/business/construction/order-management';

export default function OrderManagementPage() {
  const searchParams = useSearchParams();
  const mode = searchParams.get('mode');

  if (mode === 'new') {
    return <OrderDetailForm mode="create" />;
  }

  return <OrderManagementListClient />;
}
