import React, { useState } from 'react';
import { Head, Link, useForm } from '@inertiajs/react';
import EmployerLayout from '@/Layouts/EmployerLayout';
import {
Plus,
ArrowLeft,
Briefcase,
MapPin,
DollarSign,
Calendar,
LayoutGrid,
Users,
FileText,
Sparkles,
ShieldCheck
} from 'lucide-react';
export default function Create({ categories: initialCategories }) {
const categories = initialCategories || [
'Electrician', 'Mason', 'Plumber', 'Cleaner', 'Site Supervisor', 'Driver', 'General Helper'
];
const { data, setData, post, processing, errors } = useForm({
title: '',
category: '',
workers_needed: 1,
location: '',
salary: '',
job_type: 'Full Time',
start_date: '',
description: '',
requirements: ''
});
const handleSubmit = (e) => {
e.preventDefault();
// In a real app, we'd post to /employer/jobs
// post('/employer/jobs');
alert('Job posted successfully! Redirecting to Job List...');
window.location.href = '/employer/jobs';
};
return (
Fill in the details to find the perfect workers