import { queryParams, type RouteQueryOptions, type RouteDefinition, type RouteFormDefinition } from './../../../../wayfinder'
/**
* @see \App\Http\Controllers\DispatchBoardController::index
* @see app/Http/Controllers/DispatchBoardController.php:63
* @route '/dispatch'
*/
export const index = (options?: RouteQueryOptions): RouteDefinition<'get'> => ({
    url: index.url(options),
    method: 'get',
})

index.definition = {
    methods: ["get","head"],
    url: '/dispatch',
} satisfies RouteDefinition<["get","head"]>

/**
* @see \App\Http\Controllers\DispatchBoardController::index
* @see app/Http/Controllers/DispatchBoardController.php:63
* @route '/dispatch'
*/
index.url = (options?: RouteQueryOptions) => {
    return index.definition.url + queryParams(options)
}

/**
* @see \App\Http\Controllers\DispatchBoardController::index
* @see app/Http/Controllers/DispatchBoardController.php:63
* @route '/dispatch'
*/
index.get = (options?: RouteQueryOptions): RouteDefinition<'get'> => ({
    url: index.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::index
* @see app/Http/Controllers/DispatchBoardController.php:63
* @route '/dispatch'
*/
index.head = (options?: RouteQueryOptions): RouteDefinition<'head'> => ({
    url: index.url(options),
    method: 'head',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::index
* @see app/Http/Controllers/DispatchBoardController.php:63
* @route '/dispatch'
*/
const indexForm = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: index.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::index
* @see app/Http/Controllers/DispatchBoardController.php:63
* @route '/dispatch'
*/
indexForm.get = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: index.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::index
* @see app/Http/Controllers/DispatchBoardController.php:63
* @route '/dispatch'
*/
indexForm.head = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: index.url({
        [options?.mergeQuery ? 'mergeQuery' : 'query']: {
            _method: 'HEAD',
            ...(options?.query ?? options?.mergeQuery ?? {}),
        }
    }),
    method: 'get',
})

index.form = indexForm

/**
* @see \App\Http\Controllers\DispatchBoardController::userLocations
* @see app/Http/Controllers/DispatchBoardController.php:50
* @route '/dispatch/user-locations'
*/
export const userLocations = (options?: RouteQueryOptions): RouteDefinition<'get'> => ({
    url: userLocations.url(options),
    method: 'get',
})

userLocations.definition = {
    methods: ["get","head"],
    url: '/dispatch/user-locations',
} satisfies RouteDefinition<["get","head"]>

/**
* @see \App\Http\Controllers\DispatchBoardController::userLocations
* @see app/Http/Controllers/DispatchBoardController.php:50
* @route '/dispatch/user-locations'
*/
userLocations.url = (options?: RouteQueryOptions) => {
    return userLocations.definition.url + queryParams(options)
}

/**
* @see \App\Http\Controllers\DispatchBoardController::userLocations
* @see app/Http/Controllers/DispatchBoardController.php:50
* @route '/dispatch/user-locations'
*/
userLocations.get = (options?: RouteQueryOptions): RouteDefinition<'get'> => ({
    url: userLocations.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::userLocations
* @see app/Http/Controllers/DispatchBoardController.php:50
* @route '/dispatch/user-locations'
*/
userLocations.head = (options?: RouteQueryOptions): RouteDefinition<'head'> => ({
    url: userLocations.url(options),
    method: 'head',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::userLocations
* @see app/Http/Controllers/DispatchBoardController.php:50
* @route '/dispatch/user-locations'
*/
const userLocationsForm = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: userLocations.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::userLocations
* @see app/Http/Controllers/DispatchBoardController.php:50
* @route '/dispatch/user-locations'
*/
userLocationsForm.get = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: userLocations.url(options),
    method: 'get',
})

/**
* @see \App\Http\Controllers\DispatchBoardController::userLocations
* @see app/Http/Controllers/DispatchBoardController.php:50
* @route '/dispatch/user-locations'
*/
userLocationsForm.head = (options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
    action: userLocations.url({
        [options?.mergeQuery ? 'mergeQuery' : 'query']: {
            _method: 'HEAD',
            ...(options?.query ?? options?.mergeQuery ?? {}),
        }
    }),
    method: 'get',
})

userLocations.form = userLocationsForm

const DispatchBoardController = { index, userLocations }

export default DispatchBoardController