/* eslint-disable unicorn/prefer-module */ import type * as recordTypes from "../types/recordTypes"; import type * as globalTypes from "../types/globalTypes"; import type { cityssmGlobal } from "@cityssm/bulma-webapp-js/src/types"; declare const cityssm: cityssmGlobal; (() => { const los = exports.los as globalTypes.LOS; const urlPrefix = document.querySelector("main").dataset.urlPrefix; const workOrderPrints: string[] = exports.workOrderPrints; const searchFilterFormElement = document.querySelector( "#form--searchFilters" ) as HTMLFormElement; los.initializeDatePickers(searchFilterFormElement); const searchResultsContainerElement = document.querySelector( "#container--searchResults" ) as HTMLElement; const limit = Number.parseInt( (document.querySelector("#searchFilter--limit") as HTMLInputElement).value, 10 ); const offsetElement = document.querySelector("#searchFilter--offset") as HTMLInputElement; const getWorkOrders = () => { const offset = Number.parseInt(offsetElement.value, 10); searchResultsContainerElement.innerHTML = '
| Work Order Number | " + "Work Order Description | " + "Date | " + "Progress | " + (workOrderPrints.length > 0 ? '' : "") + " |
|---|