'}function l(e){var n;const a=s(Number.parseInt(null!==(n=e.currentTarget.closest(".container--feeCategory").dataset.feeCategoryId)&&void 0!==n?n:"",10));let l;function i(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doUpdateFeeCategory`,e.currentTarget,e=>{var t;const n=e;n.success?(o=n.feeCategories,l(),r()):bulmaJS.alert({title:"Error Updating Fee Category",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}cityssm.openHtmlModal("adminFees-editFeeCategory",{onshow(e){e.querySelector("#feeCategoryEdit--feeCategoryId").value=a.feeCategoryId.toString(),e.querySelector("#feeCategoryEdit--feeCategory").value=a.feeCategory,a.isGroupedFee&&(e.querySelector("#feeCategoryEdit--isGroupedFee").checked=!0)},onshown(e,t){var n;bulmaJS.toggleHtmlClipped(),l=t,null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",i),e.querySelector("#feeCategoryEdit--feeCategory").focus()},onremoved:()=>{bulmaJS.toggleHtmlClipped()}})}function i(e){var n;const s=Number.parseInt(null!==(n=e.currentTarget.closest(".container--feeCategory").dataset.feeCategoryId)&&void 0!==n?n:"",10);bulmaJS.confirm({title:"Delete Fee Category?",message:"Are you sure you want to delete this fee category?",contextualColorName:"warning",okButton:{text:"Yes, Delete the Fee Category",callbackFunction:function(){cityssm.postJSON(`${t.urlPrefix}/admin/doDeleteFeeCategory`,{feeCategoryId:s},e=>{var t;const n=e;n.success?(o=n.feeCategories,r()):bulmaJS.alert({title:"Error Updating Fee Category",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}}})}function c(e){var n;const s=e.currentTarget,a=null!==(n=s.closest(".container--feeCategory").dataset.feeCategoryId)&&void 0!==n?n:"";cityssm.postJSON(`${t.urlPrefix}/admin/${"up"===s.dataset.direction?"doMoveFeeCategoryUp":"doMoveFeeCategoryDown"}`,{feeCategoryId:a,moveToEnd:e.shiftKey?"1":"0"},e=>{var t;const n=e;n.success?(o=n.feeCategories,r()):bulmaJS.alert({title:"Error Moving Fee Category",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}function d(e){var n;const s=Number.parseInt(null!==(n=e.currentTarget.closest(".container--feeCategory").dataset.feeCategoryId)&&void 0!==n?n:"",10);let a;function l(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doAddFee`,e.currentTarget,e=>{var t;const n=e;n.success?(o=n.feeCategories,a(),r()):bulmaJS.alert({title:"Error Adding Fee",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}cityssm.openHtmlModal("adminFees-addFee",{onshow(e){const n=e.querySelector("#feeAdd--feeCategoryId");for(const e of o){const t=document.createElement("option");t.value=e.feeCategoryId.toString(),t.textContent=e.feeCategory,e.feeCategoryId===s&&(t.selected=!0),n.append(t)}const a=e.querySelector("#feeAdd--occupancyTypeId");for(const e of exports.occupancyTypes){const t=document.createElement("option");t.value=e.occupancyTypeId.toString(),t.textContent=e.occupancyType,a.append(t)}const r=e.querySelector("#feeAdd--lotTypeId");for(const e of exports.lotTypes){const t=document.createElement("option");t.value=e.lotTypeId.toString(),t.textContent=e.lotType,r.append(t)}e.querySelector("#feeAdd--taxPercentage").value=exports.taxPercentageDefault.toString(),t.populateAliases(e)},onshown(e,t){var n,o,s;bulmaJS.toggleHtmlClipped(),a=t,null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",l),e.querySelector("#feeAdd--feeName").focus(),e.querySelector("#feeAdd--feeFunction").addEventListener("change",()=>{var t,n;const o=e.querySelector("#feeAdd--feeAmount"),s=e.querySelector("#feeAdd--feeFunction");""===s.value?(null===(t=s.closest(".select"))||void 0===t||t.classList.remove("is-success"),o.classList.add("is-success"),o.disabled=!1):(null===(n=s.closest(".select"))||void 0===n||n.classList.add("is-success"),o.classList.remove("is-success"),o.disabled=!0)}),null===(o=e.querySelector("#feeAdd--taxPercentage"))||void 0===o||o.addEventListener("keyup",()=>{const t=e.querySelector("#feeAdd--taxAmount"),n=e.querySelector("#feeAdd--taxPercentage");""===n.value?(n.classList.remove("is-success"),t.classList.add("is-success"),t.disabled=!1):(n.classList.add("is-success"),t.classList.remove("is-success"),t.disabled=!0)}),null===(s=e.querySelector("#feeAdd--includeQuantity"))||void 0===s||s.addEventListener("change",()=>{e.querySelector("#feeAdd--quantityUnit").disabled=""===e.querySelector("#feeAdd--includeQuantity").value})},onremoved(){bulmaJS.toggleHtmlClipped()}})}function u(e){var n,l;e.preventDefault();const i=e.currentTarget.closest(".container--fee"),c=Number.parseInt(null!==(n=i.dataset.feeId)&&void 0!==n?n:"",10),d=s(Number.parseInt(null!==(l=i.closest(".container--feeCategory").dataset.feeCategoryId)&&void 0!==l?l:"")),u=a(d,c);let f;function y(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doUpdateFeeAmount`,e.currentTarget,e=>{var t;const n=e;n.success?(o=n.feeCategories,f(),r()):bulmaJS.alert({title:"Error Updating Fee Amount",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}cityssm.openHtmlModal("adminFees-editFeeAmount",{onshow(e){var t,n,o;e.querySelector("#feeAmountEdit--feeId").value=u.feeId.toString(),e.querySelector("#feeAmountEdit--feeCategory").textContent=d.feeCategory,e.querySelector("#feeAmountEdit--feeName").textContent=null!==(t=u.feeName)&&void 0!==t?t:"",e.querySelector("#feeAmountEdit--feeAmount").value=null!==(o=null===(n=u.feeAmount)||void 0===n?void 0:n.toFixed(2))&&void 0!==o?o:"0"},onshown(e,t){var n;e.querySelector("#feeAmountEdit--feeAmount").select(),f=t,null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",y)}})}function f(e){var n,l;e.preventDefault();const i=e.currentTarget.closest(".container--fee"),c=Number.parseInt(null!==(n=i.dataset.feeId)&&void 0!==n?n:"",10),d=Number.parseInt(null!==(l=i.closest(".container--feeCategory").dataset.feeCategoryId)&&void 0!==l?l:""),u=a(s(d),c);let f,y;function m(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doUpdateFee`,e.currentTarget,e=>{var t;const n=e;n.success?(o=n.feeCategories,f(),r()):bulmaJS.alert({title:"Error Updating Fee",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}function v(e){e.preventDefault(),bulmaJS.confirm({title:"Delete Fee?",message:"Are you sure you want to delete this fee?",contextualColorName:"warning",okButton:{text:"Yes, Delete the Fee",callbackFunction:function(){cityssm.postJSON(`${t.urlPrefix}/admin/doDeleteFee`,{feeId:c},e=>{var t;const n=e;n.success?(o=n.feeCategories,f(),r()):bulmaJS.alert({title:"Error Deleting Fee",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}}})}function p(){var e,t;const n=y.querySelector("#feeEdit--feeAmount"),o=y.querySelector("#feeEdit--feeFunction");""===o.value?(null===(e=o.closest(".select"))||void 0===e||e.classList.remove("is-success"),n.classList.add("is-success"),n.disabled=!1):(null===(t=o.closest(".select"))||void 0===t||t.classList.add("is-success"),n.classList.remove("is-success"),n.disabled=!0)}function g(){const e=y.querySelector("#feeEdit--taxAmount"),t=y.querySelector("#feeEdit--taxPercentage");""===t.value?(t.classList.remove("is-success"),e.classList.add("is-success"),e.disabled=!1):(t.classList.add("is-success"),e.classList.remove("is-success"),e.disabled=!0)}function C(){const e=y.querySelector("#feeEdit--includeQuantity").value;y.querySelector("#feeEdit--quantityUnit").disabled=""===e}cityssm.openHtmlModal("adminFees-editFee",{onshow(e){var n,s,a,r,l,i,c;y=e,e.querySelector("#feeEdit--feeId").value=u.feeId.toString();const f=e.querySelector("#feeEdit--feeCategoryId");for(const e of o){const t=document.createElement("option");t.value=e.feeCategoryId.toString(),t.textContent=e.feeCategory,e.feeCategoryId===d&&(t.selected=!0),f.append(t)}e.querySelector("#feeEdit--feeName").value=null!==(n=u.feeName)&&void 0!==n?n:"",e.querySelector("#feeEdit--feeAccount").value=null!==(s=u.feeAccount)&&void 0!==s?s:"",e.querySelector("#feeEdit--feeDescription").value=null!==(a=u.feeDescription)&&void 0!==a?a:"";const m=e.querySelector("#feeEdit--occupancyTypeId");for(const e of exports.occupancyTypes){const t=document.createElement("option");t.value=e.occupancyTypeId.toString(),t.textContent=e.occupancyType,e.occupancyTypeId===u.occupancyTypeId&&(t.selected=!0),m.append(t)}const v=e.querySelector("#feeEdit--lotTypeId");for(const e of exports.lotTypes){const t=document.createElement("option");t.value=e.lotTypeId.toString(),t.textContent=e.lotType,e.lotTypeId===u.lotTypeId&&(t.selected=!0),v.append(t)}e.querySelector("#feeEdit--feeAmount").value=u.feeAmount?u.feeAmount.toFixed(2):"",null===(r=e.querySelector("#feeEdit--feeFunction"))||void 0===r||r.addEventListener("change",p),p(),e.querySelector("#feeEdit--taxAmount").value=u.taxAmount?u.taxAmount.toFixed(2):"";const S=e.querySelector("#feeEdit--taxPercentage");S.value=u.taxPercentage?u.taxPercentage.toString():"",S.addEventListener("keyup",g),g();const b=e.querySelector("#feeEdit--includeQuantity");null!==(l=u.includeQuantity)&&void 0!==l&&l&&(b.value="1"),b.addEventListener("change",C),e.querySelector("#feeEdit--quantityUnit").value=null!==(i=u.quantityUnit)&&void 0!==i?i:"",C(),null!==(c=u.isRequired)&&void 0!==c&&c&&(e.querySelector("#feeEdit--isRequired").value="1"),t.populateAliases(e)},onshown(e,t){var n,o;bulmaJS.toggleHtmlClipped(),f=t,null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",m),bulmaJS.init(e),null===(o=e.querySelector(".button--deleteFee"))||void 0===o||o.addEventListener("click",v)},onremoved(){bulmaJS.toggleHtmlClipped()}})}function y(e){var n;const s=e.currentTarget,a=null!==(n=s.closest(".container--fee").dataset.feeId)&&void 0!==n?n:"";cityssm.postJSON(`${t.urlPrefix}/admin/${"up"===s.dataset.direction?"doMoveFeeUp":"doMoveFeeDown"}`,{feeId:a,moveToEnd:e.shiftKey?"1":"0"},e=>{var t;const n=e;n.success?(o=n.feeCategories,r()):bulmaJS.alert({title:"Error Moving Fee",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}delete exports.feeCategories,null===(e=document.querySelector("#button--addFeeCategory"))||void 0===e||e.addEventListener("click",()=>{let e;function n(n){n.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doAddFeeCategory`,n.currentTarget,t=>{var n;const s=t;s.success?(o=s.feeCategories,e(),r()):bulmaJS.alert({title:"Error Creating Fee Category",message:null!==(n=s.errorMessage)&&void 0!==n?n:"",contextualColorName:"danger"})})}cityssm.openHtmlModal("adminFees-addFeeCategory",{onshown(t,o){var s;bulmaJS.toggleHtmlClipped(),t.querySelector("#feeCategoryAdd--feeCategory").focus(),e=o,null===(s=t.querySelector("form"))||void 0===s||s.addEventListener("submit",n)},onremoved(){bulmaJS.toggleHtmlClipped(),document.querySelector("#button--addFeeCategory").focus()}})}),r()})();
\ No newline at end of file
diff --git a/public-typescript/adminFees.ts b/public/javascripts/adminFees.ts
similarity index 99%
rename from public-typescript/adminFees.ts
rename to public/javascripts/adminFees.ts
index 0ce7d320..00c2160b 100644
--- a/public-typescript/adminFees.ts
+++ b/public/javascripts/adminFees.ts
@@ -4,13 +4,13 @@
import type { BulmaJS } from '@cityssm/bulma-js/types.js'
import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js'
-import type { LOS } from '../types/globalTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
import type {
Fee,
FeeCategory,
LotType,
OccupancyType
-} from '../types/recordTypes.js'
+} from '../../types/recordTypes.js'
declare const cityssm: cityssmGlobal
declare const bulmaJS: BulmaJS
diff --git a/public-typescript/adminLotTypes.d.ts b/public/javascripts/adminLotTypes.d.ts
similarity index 100%
rename from public-typescript/adminLotTypes.d.ts
rename to public/javascripts/adminLotTypes.d.ts
diff --git a/public-typescript/adminLotTypes.js b/public/javascripts/adminLotTypes.js
similarity index 100%
rename from public-typescript/adminLotTypes.js
rename to public/javascripts/adminLotTypes.js
diff --git a/public/javascripts/adminLotTypes.min.js b/public/javascripts/adminLotTypes.min.js
deleted file mode 100644
index 10a845f6..00000000
--- a/public/javascripts/adminLotTypes.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e;const t=exports.los,l=document.querySelector("#container--lotTypes");let o=exports.lotTypes;delete exports.lotTypes;const n=new Set;function i(e){var t;const l=e.currentTarget,o=l.closest(".container--lotType"),i=Number.parseInt(null!==(t=o.dataset.lotTypeId)&&void 0!==t?t:"",10);n.has(i)?n.delete(i):n.add(i),l.innerHTML=n.has(i)?'':'';const s=o.querySelectorAll(".panel-block");for(const e of s)e.classList.toggle("is-hidden")}function s(e){var l;const n=e;n.success?(o=n.lotTypes,T()):bulmaJS.alert({title:`Error Updating ${t.escapedAliases.Lot} Type`,message:null!==(l=n.errorMessage)&&void 0!==l?l:"",contextualColorName:"danger"})}function d(e){var l;const o=Number.parseInt(null!==(l=e.currentTarget.closest(".container--lotType").dataset.lotTypeId)&&void 0!==l?l:"",10);bulmaJS.confirm({title:`Delete ${t.escapedAliases.Lot} Type`,message:`Are you sure you want to delete this ${t.escapedAliases.lot} type?`,contextualColorName:"warning",okButton:{text:`Yes, Delete ${t.escapedAliases.Lot} Type`,callbackFunction:function(){cityssm.postJSON(`${t.urlPrefix}/admin/doDeleteLotType`,{lotTypeId:o},s)}}})}function a(e){var l;const n=Number.parseInt(null!==(l=e.currentTarget.closest(".container--lotType").dataset.lotTypeId)&&void 0!==l?l:"",10),i=o.find(e=>n===e.lotTypeId);let d;function a(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doUpdateLotType`,e.currentTarget,e=>{const t=e;s(t),t.success&&d()})}cityssm.openHtmlModal("adminLotTypes-editLotType",{onshow(e){t.populateAliases(e),e.querySelector("#lotTypeEdit--lotTypeId").value=n.toString(),e.querySelector("#lotTypeEdit--lotType").value=i.lotType},onshown(e,t){var l;d=t,e.querySelector("#lotTypeEdit--lotType").focus(),null===(l=e.querySelector("form"))||void 0===l||l.addEventListener("submit",a),bulmaJS.toggleHtmlClipped()},onremoved(){bulmaJS.toggleHtmlClipped()}})}function r(e){var l;const o=Number.parseInt(null!==(l=e.currentTarget.closest(".container--lotType").dataset.lotTypeId)&&void 0!==l?l:"",10);let i;function d(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doAddLotTypeField`,e.currentTarget,e=>{const t=e;n.add(o),s(t),t.success&&(i(),u(o,t.lotTypeFieldId))})}cityssm.openHtmlModal("adminLotTypes-addLotTypeField",{onshow(e){t.populateAliases(e),o&&(e.querySelector("#lotTypeFieldAdd--lotTypeId").value=o.toString())},onshown(e,t){var l;i=t,e.querySelector("#lotTypeFieldAdd--lotTypeField").focus(),null===(l=e.querySelector("form"))||void 0===l||l.addEventListener("submit",d),bulmaJS.toggleHtmlClipped()},onremoved(){bulmaJS.toggleHtmlClipped()}})}function c(e){const l=e.currentTarget,o=l.closest(".container--lotType").dataset.lotTypeId;cityssm.postJSON(`${t.urlPrefix}/admin/${"up"===l.dataset.direction?"doMoveLotTypeUp":"doMoveLotTypeDown"}`,{lotTypeId:o,moveToEnd:e.shiftKey?"1":"0"},s)}function u(e,l){var n;const i=(null!==(n=o.find(t=>t.lotTypeId===e).lotTypeFields)&&void 0!==n?n:[]).find(e=>e.lotTypeFieldId===l);let d,a,r,c,u;function p(){a.min=d.value}function y(){""===c.value?(d.disabled=!1,a.disabled=!1,r.disabled=!1):(d.disabled=!0,a.disabled=!0,r.disabled=!0)}function v(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doUpdateLotTypeField`,e.currentTarget,e=>{const t=e;s(t),t.success&&u()})}function T(){cityssm.postJSON(`${t.urlPrefix}/admin/doDeleteLotTypeField`,{lotTypeFieldId:l},e=>{const t=e;s(t),t.success&&u()})}function m(){bulmaJS.confirm({title:"Delete Field",message:"Are you sure you want to delete this field? Note that historical records that make use of this field will not be affected.",contextualColorName:"warning",okButton:{text:"Yes, Delete Field",callbackFunction:T}})}cityssm.openHtmlModal("adminLotTypes-editLotTypeField",{onshow(e){var l,o,n,s,u,p,v;t.populateAliases(e),e.querySelector("#lotTypeFieldEdit--lotTypeFieldId").value=i.lotTypeFieldId.toString(),e.querySelector("#lotTypeFieldEdit--lotTypeField").value=null!==(l=i.lotTypeField)&&void 0!==l?l:"",e.querySelector("#lotTypeFieldEdit--isRequired").value=i.isRequired?"1":"0",(d=e.querySelector("#lotTypeFieldEdit--minimumLength")).value=null!==(n=null===(o=i.minimumLength)||void 0===o?void 0:o.toString())&&void 0!==n?n:"",(a=e.querySelector("#lotTypeFieldEdit--maximumLength")).value=null!==(u=null===(s=i.maximumLength)||void 0===s?void 0:s.toString())&&void 0!==u?u:"",(r=e.querySelector("#lotTypeFieldEdit--pattern")).value=null!==(p=i.pattern)&&void 0!==p?p:"",(c=e.querySelector("#lotTypeFieldEdit--lotTypeFieldValues")).value=null!==(v=i.lotTypeFieldValues)&&void 0!==v?v:"",y()},onshown(e,t){var l,o;u=t,bulmaJS.init(e),bulmaJS.toggleHtmlClipped(),cityssm.enableNavBlocker(),null===(l=e.querySelector("form"))||void 0===l||l.addEventListener("submit",v),d.addEventListener("keyup",p),p(),c.addEventListener("keyup",y),null===(o=e.querySelector("#button--deleteLotTypeField"))||void 0===o||o.addEventListener("click",m)},onremoved(){bulmaJS.toggleHtmlClipped(),cityssm.disableNavBlocker()}})}function p(e){var t,l;e.preventDefault();const o=Number.parseInt(null!==(t=e.currentTarget.closest(".container--lotTypeField").dataset.lotTypeFieldId)&&void 0!==t?t:"",10);u(Number.parseInt(null!==(l=e.currentTarget.closest(".container--lotType").dataset.lotTypeId)&&void 0!==l?l:"",10),o)}function y(e){const l=e.currentTarget,o=l.closest(".container--lotTypeField").dataset.lotTypeFieldId;cityssm.postJSON(`${t.urlPrefix}/admin/${"up"===l.dataset.direction?"doMoveLotTypeFieldUp":"doMoveLotTypeFieldDown"}`,{lotTypeFieldId:o,moveToEnd:e.shiftKey?"1":"0"},s)}function v(e,l,o){var i,s;if(0===o.length)e.insertAdjacentHTML("beforeend",`
\n
There are no additional fields.
\n
`);else for(const d of o){const o=document.createElement("div");o.className="panel-block is-block container--lotTypeField",n.has(l)||o.classList.add("is-hidden"),o.dataset.lotTypeFieldId=d.lotTypeFieldId.toString(),o.innerHTML=`
`,null===(s=o.querySelector(".button--editLotTypeField"))||void 0===s||s.addEventListener("click",p),o.querySelector(".button--moveLotTypeFieldUp").addEventListener("click",y),o.querySelector(".button--moveLotTypeFieldDown").addEventListener("click",y),e.append(o)}}function T(){var e,s,u,p,y;if(l.innerHTML="",0!==o.length)for(const T of o){const o=document.createElement("div");o.className="panel container--lotType",o.dataset.lotTypeId=T.lotTypeId.toString(),o.innerHTML=`
There are no active ${t.escapedAliases.lot} types.\n
`)}null===(e=document.querySelector("#button--addLotType"))||void 0===e||e.addEventListener("click",()=>{let e;function l(l){l.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/admin/doAddLotType`,l.currentTarget,l=>{var n;const i=l;i.success?(e(),o=i.lotTypes,T()):bulmaJS.alert({title:`Error Adding ${t.escapedAliases.Lot} Type`,message:null!==(n=i.errorMessage)&&void 0!==n?n:"",contextualColorName:"danger"})})}cityssm.openHtmlModal("adminLotTypes-addLotType",{onshow(e){t.populateAliases(e)},onshown(t,o){var n;e=o,t.querySelector("#lotTypeAdd--lotType").focus(),null===(n=t.querySelector("form"))||void 0===n||n.addEventListener("submit",l),bulmaJS.toggleHtmlClipped()},onremoved(){bulmaJS.toggleHtmlClipped()}})}),T()})();
\ No newline at end of file
diff --git a/public-typescript/adminLotTypes.ts b/public/javascripts/adminLotTypes.ts
similarity index 99%
rename from public-typescript/adminLotTypes.ts
rename to public/javascripts/adminLotTypes.ts
index 34c4879a..fa10978d 100644
--- a/public-typescript/adminLotTypes.ts
+++ b/public/javascripts/adminLotTypes.ts
@@ -4,8 +4,8 @@
import type { BulmaJS } from '@cityssm/bulma-js/types.js'
import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js'
-import type { LOS } from '../types/globalTypes.js'
-import type { LotType, LotTypeField } from '../types/recordTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
+import type { LotType, LotTypeField } from '../../types/recordTypes.js'
declare const cityssm: cityssmGlobal
declare const bulmaJS: BulmaJS
diff --git a/public-typescript/adminOccupancyTypes.d.ts b/public/javascripts/adminOccupancyTypes.d.ts
similarity index 100%
rename from public-typescript/adminOccupancyTypes.d.ts
rename to public/javascripts/adminOccupancyTypes.d.ts
diff --git a/public-typescript/adminOccupancyTypes.js b/public/javascripts/adminOccupancyTypes.js
similarity index 100%
rename from public-typescript/adminOccupancyTypes.js
rename to public/javascripts/adminOccupancyTypes.js
diff --git a/public/javascripts/adminOccupancyTypes.min.js b/public/javascripts/adminOccupancyTypes.min.js
deleted file mode 100644
index 2d1ebc78..00000000
--- a/public/javascripts/adminOccupancyTypes.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e;const c=exports.los,n=document.querySelector("#container--occupancyTypes"),t=document.querySelector("#container--occupancyTypePrints");let a=exports.occupancyTypes;delete exports.occupancyTypes;let i=exports.allOccupancyTypeFields;delete exports.allOccupancyTypeFields;const l=new Set;function s(e){var c;const n=e.currentTarget,t=n.closest(".container--occupancyType"),a=Number.parseInt(null!==(c=t.dataset.occupancyTypeId)&&void 0!==c?c:"",10);l.has(a)?l.delete(a):l.add(a),n.innerHTML=l.has(a)?'':'';const i=t.querySelectorAll(".panel-block");for(const e of i)e.classList.toggle("is-hidden")}function o(e){var n;const t=e;t.success?(a=t.occupancyTypes,i=t.allOccupancyTypeFields,O()):bulmaJS.alert({title:`Error Updating ${c.escapedAliases.Occupancy} Type`,message:null!==(n=t.errorMessage)&&void 0!==n?n:"",contextualColorName:"danger"})}function d(e){var n;const t=Number.parseInt(null!==(n=e.currentTarget.closest(".container--occupancyType").dataset.occupancyTypeId)&&void 0!==n?n:"",10);bulmaJS.confirm({title:`Delete ${c.escapedAliases.Occupancy} Type`,message:`Are you sure you want to delete this ${c.escapedAliases.occupancy} type?`,contextualColorName:"warning",okButton:{text:`Yes, Delete ${c.escapedAliases.Occupancy} Type`,callbackFunction:function(){cityssm.postJSON(`${c.urlPrefix}/admin/doDeleteOccupancyType`,{occupancyTypeId:t},o)}}})}function p(e){var n;const t=Number.parseInt(null!==(n=e.currentTarget.closest(".container--occupancyType").dataset.occupancyTypeId)&&void 0!==n?n:"",10),i=a.find(e=>t===e.occupancyTypeId);let l;function s(e){e.preventDefault(),cityssm.postJSON(`${c.urlPrefix}/admin/doUpdateOccupancyType`,e.currentTarget,e=>{const c=e;o(c),c.success&&l()})}cityssm.openHtmlModal("adminOccupancyTypes-editOccupancyType",{onshow(e){c.populateAliases(e),e.querySelector("#occupancyTypeEdit--occupancyTypeId").value=t.toString(),e.querySelector("#occupancyTypeEdit--occupancyType").value=i.occupancyType},onshown(e,c){var n;l=c,e.querySelector("#occupancyTypeEdit--occupancyType").focus(),null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",s),bulmaJS.toggleHtmlClipped()},onremoved(){bulmaJS.toggleHtmlClipped()}})}function u(e){var n;const t=Number.parseInt(null!==(n=e.currentTarget.closest(".container--occupancyType").dataset.occupancyTypeId)&&void 0!==n?n:"",10);let a;function i(e){e.preventDefault(),cityssm.postJSON(`${c.urlPrefix}/admin/doAddOccupancyTypeField`,e.currentTarget,e=>{var c;const n=e;l.add(t),o(n),n.success&&(a(),y(t,null!==(c=n.occupancyTypeFieldId)&&void 0!==c?c:0))})}cityssm.openHtmlModal("adminOccupancyTypes-addOccupancyTypeField",{onshow(e){c.populateAliases(e),t&&(e.querySelector("#occupancyTypeFieldAdd--occupancyTypeId").value=t.toString())},onshown(e,c){var n;a=c,e.querySelector("#occupancyTypeFieldAdd--occupancyTypeField").focus(),null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",i),bulmaJS.toggleHtmlClipped()},onremoved(){bulmaJS.toggleHtmlClipped()}})}function r(e){const n=e.currentTarget,t=e.currentTarget.closest(".container--occupancyType").dataset.occupancyTypeId;cityssm.postJSON(`${c.urlPrefix}/admin/${"up"===n.dataset.direction?"doMoveOccupancyTypeUp":"doMoveOccupancyTypeDown"}`,{occupancyTypeId:t,moveToEnd:e.shiftKey?"1":"0"},o)}function y(e,n){var t;let l;e&&(l=a.find(c=>c.occupancyTypeId===e));const s=(l?null!==(t=l.occupancyTypeFields)&&void 0!==t?t:[]:i).find(e=>e.occupancyTypeFieldId===n);let d,p,u,r,y;function v(){p.min=d.value}function T(){""===r.value?(d.disabled=!1,p.disabled=!1,u.disabled=!1):(d.disabled=!0,p.disabled=!0,u.disabled=!0)}function m(e){e.preventDefault(),cityssm.postJSON(`${c.urlPrefix}/admin/doUpdateOccupancyTypeField`,e.currentTarget,e=>{const c=e;o(c),c.success&&y()})}function f(){cityssm.postJSON(`${c.urlPrefix}/admin/doDeleteOccupancyTypeField`,{occupancyTypeFieldId:n},e=>{const c=e;o(c),c.success&&y()})}function b(){bulmaJS.confirm({title:"Delete Field",message:"Are you sure you want to delete this field? Note that historical records that make use of this field will not be affected.",contextualColorName:"warning",okButton:{text:"Yes, Delete Field",callbackFunction:f}})}cityssm.openHtmlModal("adminOccupancyTypes-editOccupancyTypeField",{onshow:e=>{var n,t,a,i,l,o,y,v;c.populateAliases(e),e.querySelector("#occupancyTypeFieldEdit--occupancyTypeFieldId").value=s.occupancyTypeFieldId.toString(),e.querySelector("#occupancyTypeFieldEdit--occupancyTypeField").value=null!==(n=s.occupancyTypeField)&&void 0!==n?n:"",e.querySelector("#occupancyTypeFieldEdit--isRequired").value=null!==(t=s.isRequired)&&void 0!==t&&t?"1":"0",(d=e.querySelector("#occupancyTypeFieldEdit--minimumLength")).value=null!==(i=null===(a=s.minimumLength)||void 0===a?void 0:a.toString())&&void 0!==i?i:"",(p=e.querySelector("#occupancyTypeFieldEdit--maximumLength")).value=null!==(o=null===(l=s.maximumLength)||void 0===l?void 0:l.toString())&&void 0!==o?o:"",(u=e.querySelector("#occupancyTypeFieldEdit--pattern")).value=null!==(y=s.pattern)&&void 0!==y?y:"",(r=e.querySelector("#occupancyTypeFieldEdit--occupancyTypeFieldValues")).value=null!==(v=s.occupancyTypeFieldValues)&&void 0!==v?v:"",T()},onshown:(e,c)=>{var n,t;y=c,bulmaJS.init(e),bulmaJS.toggleHtmlClipped(),cityssm.enableNavBlocker(),null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",m),d.addEventListener("keyup",v),v(),r.addEventListener("keyup",T),null===(t=e.querySelector("#button--deleteOccupancyTypeField"))||void 0===t||t.addEventListener("click",b)},onremoved:()=>{bulmaJS.toggleHtmlClipped(),cityssm.disableNavBlocker()}})}function v(e){var c,n;e.preventDefault();const t=Number.parseInt(null!==(c=e.currentTarget.closest(".container--occupancyTypeField").dataset.occupancyTypeFieldId)&&void 0!==c?c:"",10);y(Number.parseInt(null!==(n=e.currentTarget.closest(".container--occupancyType").dataset.occupancyTypeId)&&void 0!==n?n:"",10),t)}function T(e){const n=e.currentTarget,t=e.currentTarget.closest(".container--occupancyTypeField").dataset.occupancyTypeFieldId;cityssm.postJSON(`${c.urlPrefix}/admin/${"up"===n.dataset.direction?"doMoveOccupancyTypeFieldUp":"doMoveOccupancyTypeFieldDown"}`,{occupancyTypeFieldId:t,moveToEnd:e.shiftKey?"1":"0"},o)}function m(e,n,t){var a,i;if(0===t.length)e.insertAdjacentHTML("beforeend",`
\n
There are no additional fields.
\n
`);else for(const s of t){const t=document.createElement("div");t.className="panel-block is-block container--occupancyTypeField",n&&!l.has(n)&&t.classList.add("is-hidden"),t.dataset.occupancyTypeFieldId=s.occupancyTypeFieldId.toString(),t.innerHTML=`
`,null===(i=t.querySelector(".button--editOccupancyTypeField"))||void 0===i||i.addEventListener("click",v),t.querySelector(".button--moveOccupancyTypeFieldUp").addEventListener("click",T),t.querySelector(".button--moveOccupancyTypeFieldDown").addEventListener("click",T),e.append(t)}}function f(e){var n;const t=null!==(n=e.currentTarget.closest(".container--occupancyTypePrintList").dataset.occupancyTypeId)&&void 0!==n?n:"";let a;function i(e){e.preventDefault(),cityssm.postJSON(`${c.urlPrefix}/admin/doAddOccupancyTypePrint`,e.currentTarget,e=>{const c=e;c.success&&a(),o(c)})}cityssm.openHtmlModal("adminOccupancyTypes-addOccupancyTypePrint",{onshow(e){c.populateAliases(e),e.querySelector("#occupancyTypePrintAdd--occupancyTypeId").value=t;const n=e.querySelector("#occupancyTypePrintAdd--printEJS");for(const[e,c]of Object.entries(exports.occupancyTypePrintTitles)){const t=document.createElement("option");t.value=e,t.textContent=c,n.append(t)}},onshown(e,c){var n;a=c,null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",i)}})}function b(e){const n=e.currentTarget,t=n.closest(".container--occupancyTypePrint").dataset.printEJS,a=n.closest(".container--occupancyTypePrintList").dataset.occupancyTypeId;cityssm.postJSON(`${c.urlPrefix}/admin/${"up"===n.dataset.direction?"doMoveOccupancyTypePrintUp":"doMoveOccupancyTypePrintDown"}`,{occupancyTypeId:a,printEJS:t,moveToEnd:e.shiftKey?"1":"0"},o)}function g(e){e.preventDefault();const n=e.currentTarget.closest(".container--occupancyTypePrint").dataset.printEJS,t=e.currentTarget.closest(".container--occupancyTypePrintList").dataset.occupancyTypeId;bulmaJS.confirm({title:"Delete Print",message:"Are you sure you want to remove this print option?",contextualColorName:"warning",okButton:{text:"Yes, Remove Print",callbackFunction:function(){cityssm.postJSON(`${c.urlPrefix}/admin/doDeleteOccupancyTypePrint`,{occupancyTypeId:t,printEJS:n},o)}}})}function S(e,n,t){var a;if(0===t.length)e.insertAdjacentHTML("beforeend",'
\n
\n
There are no prints associated with this record.
\n
\n
');else for(const n of t){const t=document.createElement("div");t.className="panel-block is-block container--occupancyTypePrint",t.dataset.printEJS=n;const i="*"===n?"(All Available Prints)":exports.occupancyTypePrintTitles[n];let l="fa-star";n.startsWith("pdf/")?l="fa-file-pdf":n.startsWith("screen/")&&(l="fa-file"),t.innerHTML=`
There are no active ${c.escapedAliases.occupancy} types.\n
`),void t.insertAdjacentHTML("afterbegin",`
There are no active ${c.escapedAliases.occupancy} types.\n
`);for(const e of a){const a=document.createElement("div");a.className="panel container--occupancyType",a.dataset.occupancyTypeId=e.occupancyTypeId.toString(),a.innerHTML=`
'}delete exports.workOrderTypes,document.querySelector("#form--addWorkOrderType").addEventListener("submit",t=>{t.preventDefault();const o=t.currentTarget;cityssm.postJSON(`${e.urlPrefix}/admin/doAddWorkOrderType`,o,e=>{var t,r;const n=e;n.success?(s=n.workOrderTypes,a(),o.reset(),null===(t=o.querySelector("input"))||void 0===t||t.focus()):bulmaJS.alert({title:"Error Adding Work Order Type",message:null!==(r=n.errorMessage)&&void 0!==r?r:"",contextualColorName:"danger"})})}),a(),Object.defineProperty(exports,"__esModule",{value:!0});let l=exports.workOrderMilestoneTypes;function c(t){t.preventDefault(),cityssm.postJSON(`${e.urlPrefix}/admin/doUpdateWorkOrderMilestoneType`,t.currentTarget,e=>{var t;const s=e;s.success?(l=s.workOrderMilestoneTypes,bulmaJS.alert({message:"Work Order Milestone Type Updated Successfully",contextualColorName:"success"})):bulmaJS.alert({title:"Error Updating Work Order Milestone Type",message:null!==(t=s.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}function d(t){const s=t.currentTarget.closest("tr"),o=s.dataset.workOrderMilestoneTypeId;bulmaJS.confirm({title:"Delete Work Order Milestone Type",message:"Are you sure you want to delete this work order milestone type? \n Note that no work orders will be removed.",messageIsHtml:!0,contextualColorName:"warning",okButton:{text:"Yes, Delete Work Order Milestone Type",callbackFunction:function(){cityssm.postJSON(`${e.urlPrefix}/admin/doDeleteWorkOrderMilestoneType`,{workOrderMilestoneTypeId:o},e=>{var t;const o=e;o.success?(0===(l=o.workOrderMilestoneTypes).length?u():s.remove(),bulmaJS.alert({message:"Work Order Milestone Type Deleted Successfully",contextualColorName:"success"})):bulmaJS.alert({title:"Error Deleting Work Order Milestone Type",message:null!==(t=o.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}}})}function i(t){const s=t.currentTarget,o=s.closest("tr").dataset.workOrderMilestoneTypeId;cityssm.postJSON(`${e.urlPrefix}/admin/${"up"===s.dataset.direction?"doMoveWorkOrderMilestoneTypeUp":"doMoveWorkOrderMilestoneTypeDown"}`,{workOrderMilestoneTypeId:o,moveToEnd:t.shiftKey?"1":"0"},e=>{var t;const s=e;s.success?(l=s.workOrderMilestoneTypes,u()):bulmaJS.alert({title:"Error Moving Work Order Milestone Type",message:null!==(t=s.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}function u(){var t,s;const o=document.querySelector("#container--workOrderMilestoneTypes");if(0!==l.length){o.innerHTML="";for(const r of l){const n=document.createElement("tr");n.dataset.workOrderMilestoneTypeId=r.workOrderMilestoneTypeId.toString(),n.innerHTML=`
'}delete exports.workOrderMilestoneTypes,document.querySelector("#form--addWorkOrderMilestoneType").addEventListener("submit",t=>{t.preventDefault();const s=t.currentTarget;cityssm.postJSON(`${e.urlPrefix}/admin/doAddWorkOrderMilestoneType`,s,e=>{var t,o;const r=e;r.success?(l=r.workOrderMilestoneTypes,u(),s.reset(),null===(t=s.querySelector("input"))||void 0===t||t.focus()):bulmaJS.alert({title:"Error Adding Work Order Milestone Type",message:null!==(o=r.errorMessage)&&void 0!==o?o:"",contextualColorName:"danger"})})}),u(),Object.defineProperty(exports,"__esModule",{value:!0});let p=exports.lotStatuses;function m(t){t.preventDefault(),cityssm.postJSON(`${e.urlPrefix}/admin/doUpdateLotStatus`,t.currentTarget,t=>{var s;const o=t;o.success?(p=o.lotStatuses,bulmaJS.alert({message:`${e.escapedAliases.Lot} Status Updated Successfully`,contextualColorName:"success"})):bulmaJS.alert({title:`Error Updating ${e.escapedAliases.Lot} Status`,message:null!==(s=o.errorMessage)&&void 0!==s?s:"",contextualColorName:"danger"})})}function y(t){const s=t.currentTarget.closest("tr"),o=s.dataset.lotStatusId;bulmaJS.confirm({title:`Delete ${e.escapedAliases.Lot} Status`,message:`Are you sure you want to delete this status? \n Note that no ${e.escapedAliases.lot} will be removed.`,messageIsHtml:!0,contextualColorName:"warning",okButton:{text:"Yes, Delete Status",callbackFunction:function(){cityssm.postJSON(`${e.urlPrefix}/admin/doDeleteLotStatus`,{lotStatusId:o},t=>{var o;const r=t;r.success?(0===(p=r.lotStatuses).length?T():s.remove(),bulmaJS.alert({message:`${e.escapedAliases.Lot} Status Deleted Successfully`,contextualColorName:"success"})):bulmaJS.alert({title:`Error Deleting ${e.escapedAliases.Lot} Status`,message:null!==(o=r.errorMessage)&&void 0!==o?o:"",contextualColorName:"danger"})})}}})}function v(t){const s=t.currentTarget,o=s.closest("tr").dataset.lotStatusId;cityssm.postJSON(`${e.urlPrefix}/admin/${"up"===s.dataset.direction?"doMoveLotStatusUp":"doMoveLotStatusDown"}`,{lotStatusId:o,moveToEnd:t.shiftKey?"1":"0"},t=>{var s;const o=t;o.success?(p=o.lotStatuses,T()):bulmaJS.alert({title:`Error Moving ${e.escapedAliases.Lot} Status`,message:null!==(s=o.errorMessage)&&void 0!==s?s:"",contextualColorName:"danger"})})}function T(){var t,s;const o=document.querySelector("#container--lotStatuses");if(0!==p.length){o.innerHTML="";for(const r of p){const n=document.createElement("tr");n.dataset.lotStatusId=r.lotStatusId.toString(),n.innerHTML=`
`
+
+ const fontAwesomeInputElement = tableRowElement.querySelector(
+ "input[name='fontAwesomeIconClass']"
+ ) as HTMLInputElement
+
+ fontAwesomeInputElement.addEventListener(
+ 'keyup',
+ refreshFontAwesomeIcon
+ )
+ fontAwesomeInputElement.addEventListener(
+ 'change',
+ refreshFontAwesomeIcon
+ )
+
+ tableRowElement
+ .querySelector('form')
+ ?.addEventListener('submit', updateLotOccupantType)
+ ;(
+ tableRowElement.querySelector(
+ '.button--moveLotOccupantTypeUp'
+ ) as HTMLButtonElement
+ ).addEventListener('click', moveLotOccupantType)
+ ;(
+ tableRowElement.querySelector(
+ '.button--moveLotOccupantTypeDown'
+ ) as HTMLButtonElement
+ ).addEventListener('click', moveLotOccupantType)
+
+ tableRowElement
+ .querySelector('.button--deleteLotOccupantType')
+ ?.addEventListener('click', deleteLotOccupantType)
+
+ containerElement.append(tableRowElement)
+ }
+ }
+ ;(
+ document.querySelector('#form--addLotOccupantType') as HTMLFormElement
+ ).addEventListener('submit', (submitEvent: SubmitEvent) => {
+ submitEvent.preventDefault()
+
+ const formElement = submitEvent.currentTarget as HTMLFormElement
+
+ cityssm.postJSON(
+ `${los.urlPrefix}/admin/doAddLotOccupantType`,
+ formElement,
+ (rawResponseJSON) => {
+ const responseJSON = rawResponseJSON as ResponseJSON
+
+ if (responseJSON.success) {
+ lotOccupantTypes = responseJSON.lotOccupantTypes
+ renderLotOccupantTypes()
+ formElement.reset()
+ formElement.querySelector('input')?.focus()
+ } else {
+ bulmaJS.alert({
+ title: `Error Adding ${los.escapedAliases.Lot} ${los.escapedAliases.Occupant} Type`,
+ message: responseJSON.errorMessage ?? '',
+ contextualColorName: 'danger'
+ })
+ }
+ }
+ )
+ })
+
+ renderLotOccupantTypes()
+ })()
+})()
diff --git a/public-typescript/dashboard.d.ts b/public/javascripts/dashboard.d.ts
similarity index 100%
rename from public-typescript/dashboard.d.ts
rename to public/javascripts/dashboard.d.ts
diff --git a/public-typescript/dashboard.js b/public/javascripts/dashboard.js
similarity index 100%
rename from public-typescript/dashboard.js
rename to public/javascripts/dashboard.js
diff --git a/public/javascripts/dashboard.min.js b/public/javascripts/dashboard.min.js
deleted file mode 100644
index 3138af00..00000000
--- a/public/javascripts/dashboard.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e;const o=exports.los,r=document.querySelectorAll(".fa-circle[data-work-order-number]");for(const t of r)t.style.color=o.getRandomColor(null!==(e=t.dataset.workOrderNumber)&&void 0!==e?e:"")})();
\ No newline at end of file
diff --git a/public-typescript/dashboard.ts b/public/javascripts/dashboard.ts
similarity index 91%
rename from public-typescript/dashboard.ts
rename to public/javascripts/dashboard.ts
index eaa8f232..c14e7940 100644
--- a/public-typescript/dashboard.ts
+++ b/public/javascripts/dashboard.ts
@@ -1,7 +1,7 @@
// eslint-disable-next-line @eslint-community/eslint-comments/disable-enable-pair
/* eslint-disable unicorn/prefer-module */
-import type { LOS } from '../types/globalTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
declare const exports: Record
;(() => {
diff --git a/public-typescript/lotEdit.d.ts b/public/javascripts/lotEdit.d.ts
similarity index 100%
rename from public-typescript/lotEdit.d.ts
rename to public/javascripts/lotEdit.d.ts
diff --git a/public-typescript/lotEdit.js b/public/javascripts/lotEdit.js
similarity index 100%
rename from public-typescript/lotEdit.js
rename to public/javascripts/lotEdit.js
diff --git a/public/javascripts/lotEdit.min.js b/public/javascripts/lotEdit.min.js
deleted file mode 100644
index 176ff2c0..00000000
--- a/public/javascripts/lotEdit.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e,t;const o=exports.los,n=document.querySelector("#lot--lotId").value,l=""===n;let s=l;function a(){var e;o.setUnsavedChanges(),null===(e=document.querySelector("button[type='submit'][form='form--lot']"))||void 0===e||e.classList.remove("is-light")}function i(){var e;o.clearUnsavedChanges(),null===(e=document.querySelector("button[type='submit'][form='form--lot']"))||void 0===e||e.classList.add("is-light")}const r=document.querySelector("#form--lot");r.addEventListener("submit",function(e){e.preventDefault(),cityssm.postJSON(`${o.urlPrefix}/lots/${l?"doCreateLot":"doUpdateLot"}`,r,e=>{var t;const n=e;n.success?(i(),l||s?window.location.href=o.getLotURL(n.lotId,!0,!0):bulmaJS.alert({message:`${o.escapedAliases.Lot} Updated Successfully`,contextualColorName:"success"})):bulmaJS.alert({title:`Error Updating ${o.escapedAliases.Lot}`,message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})});const d=r.querySelectorAll("input, select");for(const e of d)e.addEventListener("change",a);o.initializeUnlockFieldButtons(r),null===(e=document.querySelector("#button--deleteLot"))||void 0===e||e.addEventListener("click",e=>{e.preventDefault(),bulmaJS.confirm({title:`Delete ${o.escapedAliases.Lot}`,message:`Are you sure you want to delete this ${o.escapedAliases.lot}?`,contextualColorName:"warning",okButton:{text:`Yes, Delete ${o.escapedAliases.Lot}`,callbackFunction:function(){cityssm.postJSON(`${o.urlPrefix}/lots/doDeleteLot`,{lotId:n},e=>{var t;const n=e;n.success?(i(),window.location.href=o.getLotURL()):bulmaJS.alert({title:`Error Deleting ${o.escapedAliases.Lot}`,message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}}})});const m=document.querySelector("#lot--lotTypeId");if(l){const e=document.querySelector("#container--lotFields");m.addEventListener("change",()=>{""!==m.value?cityssm.postJSON(`${o.urlPrefix}/lots/doGetLotTypeFields`,{lotTypeId:m.value},t=>{var n,l,s;const a=t;if(0===a.lotTypeFields.length)return void(e.innerHTML=`
\n
\n There are no additional fields for this ${o.escapedAliases.lot} type.\n
\n
`);e.innerHTML="";let i="";for(const t of a.lotTypeFields){i+=`,${t.lotTypeFieldId.toString()}`;const o=`lotFieldValue_${t.lotTypeFieldId.toString()}`,a=`lot--${o}`,r=document.createElement("div");if(r.className="field",r.innerHTML=`\n `,r.querySelector("label").textContent=t.lotTypeField,""===t.lotTypeFieldValues){const e=document.createElement("input");e.className="input",e.id=a,e.name=o,e.type="text",e.required=t.isRequired,e.minLength=t.minimumLength,e.maxLength=t.maximumLength,""!==(null!==(n=t.pattern)&&void 0!==n?n:"")&&(e.pattern=null!==(l=t.pattern)&&void 0!==l?l:""),null===(s=r.querySelector(".control"))||void 0===s||s.append(e)}else{r.querySelector(".control").innerHTML=`
\n \n
`;const e=r.querySelector("select");e.required=t.isRequired;const n=t.lotTypeFieldValues.split("\n");for(const t of n){const o=document.createElement("option");o.value=t,o.textContent=t,e.append(o)}}e.append(r)}e.insertAdjacentHTML("beforeend",``)}):e.innerHTML=`
\n
Select the ${o.escapedAliases.lot} type to load the available fields.
\n
`})}else{const e=m.value;m.addEventListener("change",()=>{m.value!==e&&bulmaJS.confirm({title:"Confirm Change",message:`Are you sure you want to change the ${o.escapedAliases.lot} type?\n\n This change affects the additional fields associated with this record.`,contextualColorName:"warning",okButton:{text:"Yes, Keep the Change",callbackFunction(){s=!0}},cancelButton:{text:"Revert the Change",callbackFunction(){m.value=e}}})})}let c=exports.lotComments;function u(e){var t,l;const s=Number.parseInt(null!==(l=null===(t=e.currentTarget.closest("tr"))||void 0===t?void 0:t.dataset.lotCommentId)&&void 0!==l?l:"",10),a=c.find(e=>e.lotCommentId===s);let i,r;function d(e){e.preventDefault(),cityssm.postJSON(`${o.urlPrefix}/lots/doUpdateLotComment`,i,e=>{var t;const o=e;o.success?(c=o.lotComments,r(),v()):bulmaJS.alert({title:"Error Updating Comment",message:null!==(t=o.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}cityssm.openHtmlModal("lot-editComment",{onshow(e){var t,l,i,r;o.populateAliases(e),e.querySelector("#lotCommentEdit--lotId").value=n,e.querySelector("#lotCommentEdit--lotCommentId").value=s.toString(),e.querySelector("#lotCommentEdit--lotComment").value=null!==(t=a.lotComment)&&void 0!==t?t:"";const d=e.querySelector("#lotCommentEdit--lotCommentDateString");d.value=null!==(l=a.lotCommentDateString)&&void 0!==l?l:"";const m=cityssm.dateToString(new Date);d.max=a.lotCommentDateString<=m?m:null!==(i=a.lotCommentDateString)&&void 0!==i?i:"",e.querySelector("#lotCommentEdit--lotCommentTimeString").value=null!==(r=a.lotCommentTimeString)&&void 0!==r?r:""},onshown(e,t){bulmaJS.toggleHtmlClipped(),o.initializeDatePickers(e),e.querySelector("#lotCommentEdit--lotComment").focus(),(i=e.querySelector("form")).addEventListener("submit",d),r=t},onremoved(){bulmaJS.toggleHtmlClipped()}})}function p(e){var t,l;const s=Number.parseInt(null!==(l=null===(t=e.currentTarget.closest("tr"))||void 0===t?void 0:t.dataset.lotCommentId)&&void 0!==l?l:"",10);bulmaJS.confirm({title:"Remove Comment?",message:"Are you sure you want to remove this comment?",okButton:{text:"Yes, Remove Comment",callbackFunction:function(){cityssm.postJSON(`${o.urlPrefix}/lots/doDeleteLotComment`,{lotId:n,lotCommentId:s},e=>{var t;const o=e;o.success?(c=o.lotComments,v()):bulmaJS.alert({title:"Error Removing Comment",message:null!==(t=o.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}},contextualColorName:"warning"})}function v(){var e,t,o,n,l,s;const a=document.querySelector("#container--lotComments");if(0===c.length)return void(a.innerHTML='
\n ';for(const a of c){const r=document.createElement("tr");r.dataset.lotCommentId=null===(e=a.lotCommentId)||void 0===e?void 0:e.toString(),r.innerHTML=`
There are no additional fields for this ${a.escapedAliases.occupancy} type.
\n
`);e.innerHTML="";let l="";for(const t of o.occupancyTypeFields){l+=`,${t.occupancyTypeFieldId.toString()}`;const o=`lotOccupancyFieldValue_${t.occupancyTypeFieldId.toString()}`,a=`lotOccupancy--${o}`,s=document.createElement("div");if(s.className="field",s.innerHTML=``,s.querySelector("label").textContent=t.occupancyTypeField,""===(null!==(n=t.occupancyTypeFieldValues)&&void 0!==n?n:"")){const e=document.createElement("input");e.className="input",e.id=a,e.name=o,e.type="text",e.required=t.isRequired,e.minLength=t.minimumLength,e.maxLength=t.maximumLength,""!==(null!==(c=t.pattern)&&void 0!==c?c:"")&&(e.pattern=t.pattern),s.querySelector(".control").append(e)}else{s.querySelector(".control").innerHTML=`
\n \n
`;const e=s.querySelector("select");e.required=t.isRequired;const n=t.occupancyTypeFieldValues.split("\n");for(const t of n){const n=document.createElement("option");n.value=t,n.textContent=t,e.append(n)}}console.log(s),e.append(s)}e.insertAdjacentHTML("beforeend",``)}):e.innerHTML=`
\n
Select the ${a.escapedAliases.occupancy} type to load the available fields.
\n
`})}else{const e=y.value;y.addEventListener("change",()=>{y.value!==e&&bulmaJS.confirm({title:"Confirm Change",message:`Are you sure you want to change the ${a.escapedAliases.occupancy} type?\n\n This change affects the additional fields associated with this record, and may also affect the available fees.`,contextualColorName:"warning",okButton:{text:"Yes, Keep the Change",callbackFunction:()=>{r=!0}},cancelButton:{text:"Revert the Change",callbackFunction:()=>{y.value=e}}})})}const v=document.querySelector("#lotOccupancy--lotName");v.addEventListener("click",e=>{const t=e.currentTarget.value;let n,c,o,l;function s(e,t){document.querySelector("#lotOccupancy--lotId").value=e.toString(),document.querySelector("#lotOccupancy--lotName").value=t,i(),n()}function r(e){var t,n;e.preventDefault();const c=e.currentTarget;s(null!==(t=c.dataset.lotId)&&void 0!==t?t:"",null!==(n=c.dataset.lotName)&&void 0!==n?n:"")}function u(){l.innerHTML=a.getLoadingParagraphHTML("Searching..."),cityssm.postJSON(`${a.urlPrefix}/lots/doSearchLots`,o,e=>{var t,n;const c=e;if(0===c.count)return void(l.innerHTML='
\n
No results.
\n
');const o=document.createElement("div");o.className="panel";for(const e of c.lots){const c=document.createElement("a");c.className="panel-block is-block",c.href="#",c.dataset.lotId=e.lotId.toString(),c.dataset.lotName=e.lotName,c.innerHTML=`
\n `;for(const N of f){const f=document.createElement("tr");f.dataset.lotOccupantIndex=null===(e=N.lotOccupantIndex)||void 0===e?void 0:e.toString(),f.innerHTML=`
\n ';for(const i of e){const e=document.createElement("tr");e.dataset.lotOccupancyCommentId=null===(t=i.lotOccupancyCommentId)||void 0===t?void 0:t.toString(),e.innerHTML=`
';let O=0,g=0;for(const h of t){const t=document.createElement("tr");t.className="container--lotOccupancyFee",t.dataset.feeId=h.feeId.toString(),t.dataset.includeQuantity=null!==(e=h.includeQuantity)&&void 0!==e&&e?"1":"0",t.innerHTML=`
\n There are no ${a.escapedAliases.occupancy} records that meet the search criteria.\n
\n
`);const A=document.createElement("tbody"),M=cityssm.dateToString(new Date);for(const t of T.lotOccupancies){let e="";e=t.occupancyStartDateString<=M&&(""===t.occupancyEndDateString||t.occupancyEndDateString>=M)?`\n \n `:t.occupancyStartDateString>M?`\n \n `:`\n \n `;let s="";for(const a of null!==(n=t.lotOccupancyOccupants)&&void 0!==n?n:[])s+=`
`,null===(S=e.querySelector("table"))||void 0===S||S.append(A),e.insertAdjacentHTML("beforeend",a.getSearchResultsPagerHTML(s,T.offset,T.count)),null===(b=e.querySelector("button[data-page='previous']"))||void 0===b||b.addEventListener("click",o),null===(O=e.querySelector("button[data-page='next']"))||void 0===O||O.addEventListener("click",r)}function l(){e.innerHTML=a.getLoadingParagraphHTML(`Loading ${a.escapedAliases.Occupancies}...`),cityssm.postJSON(`${a.urlPrefix}/lotOccupancies/doSearchLotOccupancies`,t,c)}function i(){n.value="0",l()}function o(){n.value=Math.max(Number.parseInt(n.value,10)-s,0).toString(),l()}function r(){n.value=(Number.parseInt(n.value,10)+s).toString(),l()}const d=t.querySelectorAll("input, select");for(const a of d)a.addEventListener("change",i);t.addEventListener("submit",a=>{a.preventDefault()}),l()})();
\ No newline at end of file
diff --git a/public-typescript/lotOccupancySearch.ts b/public/javascripts/lotOccupancySearch.ts
similarity index 98%
rename from public-typescript/lotOccupancySearch.ts
rename to public/javascripts/lotOccupancySearch.ts
index 7aecda2f..d66489da 100644
--- a/public-typescript/lotOccupancySearch.ts
+++ b/public/javascripts/lotOccupancySearch.ts
@@ -3,8 +3,8 @@
import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js'
-import type { LOS } from '../types/globalTypes.js'
-import type { LotOccupancy } from '../types/recordTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
+import type { LotOccupancy } from '../../types/recordTypes.js'
declare const cityssm: cityssmGlobal
diff --git a/public-typescript/lotSearch.d.ts b/public/javascripts/lotSearch.d.ts
similarity index 100%
rename from public-typescript/lotSearch.d.ts
rename to public/javascripts/lotSearch.d.ts
diff --git a/public-typescript/lotSearch.js b/public/javascripts/lotSearch.js
similarity index 100%
rename from public-typescript/lotSearch.js
rename to public/javascripts/lotSearch.js
diff --git a/public/javascripts/lotSearch.min.js b/public/javascripts/lotSearch.min.js
deleted file mode 100644
index 27f5f72e..00000000
--- a/public/javascripts/lotSearch.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{const e=exports.los,t=document.querySelector("#form--searchFilters"),s=document.querySelector("#container--searchResults"),a=Number.parseInt(document.querySelector("#searchFilter--limit").value,10),n=document.querySelector("#searchFilter--offset");function r(t){var n,r,o,l,d,u,p;const h=t;if(0===h.lots.length)return void(s.innerHTML=`
\n
There are no ${e.escapedAliases.lots} that meet the search criteria.
\n
`);const m=document.createElement("tbody");for(const t of h.lots)m.insertAdjacentHTML("beforeend",`
`,s.insertAdjacentHTML("beforeend",e.getSearchResultsPagerHTML(a,h.offset,h.count)),null===(d=s.querySelector("table"))||void 0===d||d.append(m),null===(u=s.querySelector("button[data-page='previous']"))||void 0===u||u.addEventListener("click",c),null===(p=s.querySelector("button[data-page='next']"))||void 0===p||p.addEventListener("click",i)}function o(){s.innerHTML=e.getLoadingParagraphHTML(`Loading ${e.escapedAliases.Lots}...`),cityssm.postJSON(`${e.urlPrefix}/lots/doSearchLots`,t,r)}function l(){n.value="0",o()}function c(){n.value=Math.max(Number.parseInt(n.value,10)-a,0).toString(),o()}function i(){n.value=(Number.parseInt(n.value,10)+a).toString(),o()}const d=t.querySelectorAll("input, select");for(const e of d)e.addEventListener("change",l);t.addEventListener("submit",e=>{e.preventDefault()}),o()})();
\ No newline at end of file
diff --git a/public-typescript/lotSearch.ts b/public/javascripts/lotSearch.ts
similarity index 97%
rename from public-typescript/lotSearch.ts
rename to public/javascripts/lotSearch.ts
index 872a8710..33c403e5 100644
--- a/public-typescript/lotSearch.ts
+++ b/public/javascripts/lotSearch.ts
@@ -3,8 +3,8 @@
import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js'
-import type { LOS } from '../types/globalTypes.js'
-import type { Lot } from '../types/recordTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
+import type { Lot } from '../../types/recordTypes.js'
declare const cityssm: cityssmGlobal
diff --git a/public-typescript/lotView.d.ts b/public/javascripts/lotView.d.ts
similarity index 100%
rename from public-typescript/lotView.d.ts
rename to public/javascripts/lotView.d.ts
diff --git a/public-typescript/lotView.js b/public/javascripts/lotView.js
similarity index 100%
rename from public-typescript/lotView.js
rename to public/javascripts/lotView.js
diff --git a/public/javascripts/lotView.min.js b/public/javascripts/lotView.min.js
deleted file mode 100644
index 46de10bf..00000000
--- a/public/javascripts/lotView.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e;const t=document.querySelector("#lot--map");null!==t&&exports.los.highlightMap(t,null!==(e=t.dataset.mapKey)&&void 0!==e?e:"","success")})();
\ No newline at end of file
diff --git a/public-typescript/lotView.ts b/public/javascripts/lotView.ts
similarity index 89%
rename from public-typescript/lotView.ts
rename to public/javascripts/lotView.ts
index f027e209..a9e1474c 100644
--- a/public-typescript/lotView.ts
+++ b/public/javascripts/lotView.ts
@@ -1,7 +1,7 @@
// eslint-disable-next-line @eslint-community/eslint-comments/disable-enable-pair
/* eslint-disable unicorn/prefer-module */
-import type { LOS } from '../types/globalTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
declare const exports: Record
;(() => {
diff --git a/public-typescript/main.d.ts b/public/javascripts/main.d.ts
similarity index 100%
rename from public-typescript/main.d.ts
rename to public/javascripts/main.d.ts
diff --git a/public-typescript/main.js b/public/javascripts/main.js
similarity index 100%
rename from public-typescript/main.js
rename to public/javascripts/main.js
diff --git a/public/javascripts/main.min.js b/public/javascripts/main.min.js
deleted file mode 100644
index f1fe7db0..00000000
--- a/public/javascripts/main.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e,t,s,a;let o=!1;function n(){return o}function i(e){const t=e.currentTarget.closest(".field").querySelector("input, select");if(t.classList.remove("is-readonly"),"INPUT"===t.tagName)t.readOnly=!1,t.disabled=!1;else{const e=t.querySelectorAll("option");for(const t of e)t.disabled=!1}t.focus()}const c={type:"date",dateFormat:"yyyy-MM-dd",showFooter:!1,color:"info",displayMode:"dialog"};const r=Object.freeze({Map:cityssm.escapeHTML(exports.aliases.map),map:cityssm.escapeHTML(exports.aliases.map.toLowerCase()),Maps:cityssm.escapeHTML(exports.aliases.maps),maps:cityssm.escapeHTML(exports.aliases.maps.toLowerCase()),Lot:cityssm.escapeHTML(exports.aliases.lot),lot:cityssm.escapeHTML(exports.aliases.lot.toLowerCase()),Lots:cityssm.escapeHTML(exports.aliases.lots),lots:cityssm.escapeHTML(exports.aliases.lots.toLowerCase()),Occupancy:cityssm.escapeHTML(exports.aliases.occupancy),occupancy:cityssm.escapeHTML(exports.aliases.occupancy.toLowerCase()),Occupancies:cityssm.escapeHTML(exports.aliases.occupancies),occupancies:cityssm.escapeHTML(exports.aliases.occupancies.toLowerCase()),Occupant:cityssm.escapeHTML(exports.aliases.occupant),occupant:cityssm.escapeHTML(exports.aliases.occupant.toLowerCase()),Occupants:cityssm.escapeHTML(exports.aliases.occupants),occupants:cityssm.escapeHTML(exports.aliases.occupants.toLowerCase()),ExternalReceiptNumber:cityssm.escapeHTML(exports.aliases.externalReceiptNumber),externalReceiptNumber:cityssm.escapeHTML(exports.aliases.externalReceiptNumber.toLowerCase()),OccupancyStartDate:cityssm.escapeHTML(exports.aliases.occupancyStartDate),occupancyStartDate:cityssm.escapeHTML(exports.aliases.occupancyStartDate.toLowerCase()),WorkOrderOpenDate:cityssm.escapeHTML(exports.aliases.workOrderOpenDate),workOrderOpenDate:cityssm.escapeHTML(exports.aliases.workOrderOpenDate.toLowerCase()),WorkOrderCloseDate:cityssm.escapeHTML(exports.aliases.workOrderCloseDate),workOrderCloseDate:cityssm.escapeHTML(exports.aliases.workOrderCloseDate.toLowerCase())}),l=["red","green","orange","blue","pink","yellow","purple"],p=["bright","light","dark"];const u=null!==(t=null===(e=document.querySelector("main"))||void 0===e?void 0:e.dataset.urlPrefix)&&void 0!==t?t:"";function d(e,t,s,a){return u+"/"+e+(t?`/${t.toString()}`:"")+(t&&s?"/edit":"")+(a?`/?t=${Date.now().toString()}`:"")}const y=exports.dynamicsGPIntegrationIsEnabled,m={urlPrefix:u,apiKey:null!==(a=null===(s=document.querySelector("main"))||void 0===s?void 0:s.dataset.apiKey)&&void 0!==a?a:"",dynamicsGPIntegrationIsEnabled:y,highlightMap:function(e,t,s){let a,o=t;for(;null===(a=e.querySelector(`#${o}`))&&o.includes("-");)o=o.slice(0,Math.max(0,o.lastIndexOf("-")));if(null!==a){a.style.fill="",a.classList.add("highlight",`is-${s}`);const e=a.querySelectorAll("path");for(const t of e)t.style.fill=""}},initializeUnlockFieldButtons:function(e){const t=e.querySelectorAll(".is-unlock-field-button");for(const e of t)e.addEventListener("click",i)},initializeDatePickers:function(e){var t,s,a;const o=e.querySelectorAll("input[type='date']");for(const n of o){const o=Object.assign({},c);n.required&&(o.showClearButton=!1),""!==n.min&&(o.minDate=cityssm.dateStringToDate(n.min)),""!==n.max&&(o.maxDate=cityssm.dateStringToDate(n.max));const i=exports.bulmaCalendar.attach(n,o)[0];i.on("save",()=>{n.value=i.value(),n.dispatchEvent(new Event("change"))}),i.on("show",()=>{var e;null===(e=document.querySelector("html"))||void 0===e||e.classList.add("is-clipped")}),i.on("hide",()=>{bulmaJS.toggleHtmlClipped()});const r=e.querySelector(`#${i._id}`),l=r.querySelectorAll(".datepicker-nav button.is-text");for(const e of l)e.classList.add(`is-${null!==(t=c.color)&&void 0!==t?t:""}`),e.classList.remove("is-text");const p=r.querySelector(".datetimepicker-clear-button");null!==p&&(n.required?p.remove():(p.dataset.tooltip="Clear",p.setAttribute("aria-label","Clear"),p.innerHTML='×'));const u=document.querySelector(`label[for='${n.id}']`);null!==u&&(null===(s=r.querySelector(".datetimepicker-dummy-input"))||void 0===s||s.setAttribute("aria-label",null!==(a=u.textContent)&&void 0!==a?a:""))}},populateAliases:function(e){const t=e.querySelectorAll(".alias");for(const e of t)switch(e.dataset.alias){case"Map":e.textContent=exports.aliases.map;break;case"Lot":e.textContent=exports.aliases.lot;break;case"lot":e.textContent=exports.aliases.lot.toLowerCase();break;case"Occupancy":e.textContent=exports.aliases.occupancy;break;case"occupancy":e.textContent=exports.aliases.occupancy.toLowerCase();break;case"Occupant":e.textContent=exports.aliases.occupant;break;case"occupant":e.textContent=exports.aliases.occupant.toLowerCase();break;case"ExternalReceiptNumber":e.textContent=exports.aliases.externalReceiptNumber}},escapedAliases:r,getRandomColor:function(e){let t=e;return t.length<2&&(t+="a1"),exports.randomColor({seed:t+t,hue:l[t.codePointAt(t.length-1)%l.length],luminosity:p[t.codePointAt(t.length-2)%p.length]})},setUnsavedChanges:function(){n()||(o=!0,cityssm.enableNavBlocker())},clearUnsavedChanges:function(){o=!1,cityssm.disableNavBlocker()},hasUnsavedChanges:n,getMoveUpDownButtonFieldHTML:function(e,t,s=!0){return`
\n `},getMapURL:function(e="",t=!1,s=!1){return d("maps",e,t,s)},getLotURL:function(e="",t=!1,s=!1){return d("lots",e,t,s)},getLotOccupancyURL:function(e="",t=!1,s=!1){return d("lotOccupancies",e,t,s)},getWorkOrderURL:function(e="",t=!1,s=!1){return d("workOrders",e,t,s)}};exports.los=m})();
\ No newline at end of file
diff --git a/public-typescript/main.ts b/public/javascripts/main.ts
similarity index 99%
rename from public-typescript/main.ts
rename to public/javascripts/main.ts
index 266869b7..eaa315d4 100644
--- a/public-typescript/main.ts
+++ b/public/javascripts/main.ts
@@ -5,7 +5,7 @@ import type { BulmaJS } from '@cityssm/bulma-js/types.js'
import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js'
import type { Options as BulmaCalendarOptions } from 'bulma-calendar'
-import type { LOS } from '../types/globalTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
type RandomColorHue =
| 'red'
diff --git a/public-typescript/mapEdit.d.ts b/public/javascripts/mapEdit.d.ts
similarity index 100%
rename from public-typescript/mapEdit.d.ts
rename to public/javascripts/mapEdit.d.ts
diff --git a/public-typescript/mapEdit.js b/public/javascripts/mapEdit.js
similarity index 100%
rename from public-typescript/mapEdit.js
rename to public/javascripts/mapEdit.js
diff --git a/public/javascripts/mapEdit.min.js b/public/javascripts/mapEdit.min.js
deleted file mode 100644
index 848d9507..00000000
--- a/public/javascripts/mapEdit.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e;const t=exports.los,a=document.querySelector("#map--mapId").value,s=""===a,o=document.querySelector("#form--map");function l(){var e;t.setUnsavedChanges(),null===(e=document.querySelector("button[type='submit'][form='form--map']"))||void 0===e||e.classList.remove("is-light")}o.addEventListener("submit",function(e){e.preventDefault(),cityssm.postJSON(`${t.urlPrefix}/maps/${s?"doCreateMap":"doUpdateMap"}`,o,e=>{var a;const o=e;o.success?(function(){var e;t.clearUnsavedChanges(),null===(e=document.querySelector("button[type='submit'][form='form--map']"))||void 0===e||e.classList.add("is-light")}(),s?window.location.href=t.getMapURL(o.mapId,!0):bulmaJS.alert({message:`${t.escapedAliases.Map} Updated Successfully`,contextualColorName:"success"})):bulmaJS.alert({title:`Error Updating ${t.escapedAliases.Map}`,message:null!==(a=o.errorMessage)&&void 0!==a?a:"",contextualColorName:"danger"})})});const r=o.querySelectorAll("input, select");for(const e of r)e.addEventListener("change",l);null===(e=document.querySelector("#button--deleteMap"))||void 0===e||e.addEventListener("click",e=>{e.preventDefault(),bulmaJS.confirm({title:`Delete ${t.escapedAliases.Map}`,message:`Are you sure you want to delete this ${t.escapedAliases.map} and all related ${t.escapedAliases.lots}?`,contextualColorName:"warning",okButton:{text:`Yes, Delete ${t.escapedAliases.Map}`,callbackFunction:function(){cityssm.postJSON(`${t.urlPrefix}/maps/doDeleteMap`,{mapId:a},e=>{var a;const s=e;s.success?window.location.href=t.getMapURL():bulmaJS.alert({title:`Error Deleting ${t.escapedAliases.Map}`,message:null!==(a=s.errorMessage)&&void 0!==a?a:"",contextualColorName:"danger"})})}}})})})();
\ No newline at end of file
diff --git a/public-typescript/mapEdit.ts b/public/javascripts/mapEdit.ts
similarity index 98%
rename from public-typescript/mapEdit.ts
rename to public/javascripts/mapEdit.ts
index 119069c4..0573282b 100644
--- a/public-typescript/mapEdit.ts
+++ b/public/javascripts/mapEdit.ts
@@ -4,7 +4,7 @@
import type { BulmaJS } from '@cityssm/bulma-js/types.js'
import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js'
-import type { LOS } from '../types/globalTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
declare const cityssm: cityssmGlobal
declare const bulmaJS: BulmaJS
diff --git a/public-typescript/mapSearch.d.ts b/public/javascripts/mapSearch.d.ts
similarity index 100%
rename from public-typescript/mapSearch.d.ts
rename to public/javascripts/mapSearch.d.ts
diff --git a/public-typescript/mapSearch.js b/public/javascripts/mapSearch.js
similarity index 100%
rename from public-typescript/mapSearch.js
rename to public/javascripts/mapSearch.js
diff --git a/public/javascripts/mapSearch.min.js b/public/javascripts/mapSearch.min.js
deleted file mode 100644
index 45c3788f..00000000
--- a/public/javascripts/mapSearch.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e;const a=exports.los,s=exports.maps,t=document.querySelector("#searchFilter--map"),n=document.querySelector("#container--searchResults");function i(){var e,i,d,l,r,o,c,p,m,u,h,v,$,L,f,b,y;n.innerHTML=a.getLoadingParagraphHTML(`Loading ${a.escapedAliases.Maps}...`);let H=0;const M=document.createElement("tbody"),g=t.value.trim().toLowerCase().split(" ");for(const t of s){const s=`${null!==(e=t.mapName)&&void 0!==e?e:""} ${null!==(i=t.mapDescription)&&void 0!==i?i:""} ${null!==(d=t.mapAddress1)&&void 0!==d?d:""} ${null!==(l=t.mapAddress2)&&void 0!==l?l:""}`.toLowerCase();let n=!0;for(const e of g)if(!s.includes(e)){n=!1;break}n&&(H+=1,M.insertAdjacentHTML("beforeend",`
`;
+ panelBlockElement
+ .querySelector('.button--reopenMilestone')
+ ?.addEventListener('click', reopenMilestone);
+ panelBlockElement
+ .querySelector('.button--editMilestone')
+ ?.addEventListener('click', editMilestone);
+ panelBlockElement
+ .querySelector('.button--completeMilestone')
+ ?.addEventListener('click', completeMilestone);
+ panelBlockElement
+ .querySelector('.button--deleteMilestone')
+ ?.addEventListener('click', deleteMilestone);
+ milestonesPanelElement.append(panelBlockElement);
+ }
+ bulmaJS.init(milestonesPanelElement);
+ }
+ if (!isCreate) {
+ workOrderMilestones = exports.workOrderMilestones;
+ delete exports.workOrderMilestones;
+ renderMilestones();
+ document
+ .querySelector('#button--addMilestone')
+ ?.addEventListener('click', () => {
+ let addFormElement;
+ let workOrderMilestoneDateStringElement;
+ let addCloseModalFunction;
+ function doAdd(submitEvent) {
+ if (submitEvent) {
+ submitEvent.preventDefault();
+ }
+ const currentDateString = cityssm.dateToString(new Date());
+ function _doAdd() {
+ cityssm.postJSON(`${los.urlPrefix}/workOrders/doAddWorkOrderMilestone`, addFormElement, (rawResponseJSON) => {
+ const responseJSON = rawResponseJSON;
+ processMilestoneResponse(responseJSON);
+ if (responseJSON.success) {
+ addCloseModalFunction();
+ }
+ });
+ }
+ const milestoneDateString = workOrderMilestoneDateStringElement.value;
+ if (milestoneDateString !== '' &&
+ milestoneDateString < currentDateString) {
+ bulmaJS.confirm({
+ title: 'Milestone Date in the Past',
+ message: 'Are you sure you want to create a milestone with a date in the past?',
+ contextualColorName: 'warning',
+ okButton: {
+ text: 'Yes, Create a Past Milestone',
+ callbackFunction: _doAdd
+ }
+ });
+ }
+ else {
+ _doAdd();
+ }
+ }
+ cityssm.openHtmlModal('workOrder-addMilestone', {
+ onshow(modalElement) {
+ ;
+ modalElement.querySelector('#milestoneAdd--workOrderId').value = workOrderId;
+ const milestoneTypeElement = modalElement.querySelector('#milestoneAdd--workOrderMilestoneTypeId');
+ for (const milestoneType of exports.workOrderMilestoneTypes) {
+ const optionElement = document.createElement('option');
+ optionElement.value =
+ milestoneType.workOrderMilestoneTypeId.toString();
+ optionElement.textContent = milestoneType.workOrderMilestoneType;
+ milestoneTypeElement.append(optionElement);
+ }
+ workOrderMilestoneDateStringElement = modalElement.querySelector('#milestoneAdd--workOrderMilestoneDateString');
+ workOrderMilestoneDateStringElement.valueAsDate = new Date();
+ },
+ onshown(modalElement, closeModalFunction) {
+ addCloseModalFunction = closeModalFunction;
+ los.initializeDatePickers(modalElement);
+ // los.initializeTimePickers(modalElement);
+ bulmaJS.toggleHtmlClipped();
+ modalElement.querySelector('#milestoneAdd--workOrderMilestoneTypeId').focus();
+ addFormElement = modalElement.querySelector('form');
+ addFormElement.addEventListener('submit', doAdd);
+ const conflictingMilestonePanelElement = document.querySelector('#milestoneAdd--conflictingMilestonesPanel');
+ workOrderMilestoneDateStringElement.addEventListener('change', () => {
+ refreshConflictingMilestones(workOrderMilestoneDateStringElement.value, conflictingMilestonePanelElement);
+ });
+ refreshConflictingMilestones(workOrderMilestoneDateStringElement.value, conflictingMilestonePanelElement);
+ },
+ onremoved() {
+ bulmaJS.toggleHtmlClipped();
+ document.querySelector('#button--addMilestone').focus();
+ }
+ });
+ });
+ }
+})();
diff --git a/public/javascripts/workOrderEdit.min.js b/public/javascripts/workOrderEdit.min.js
deleted file mode 100644
index e8f865ed..00000000
--- a/public/javascripts/workOrderEdit.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{var e,t;const o=exports.los,n=document.querySelector("#workOrderEdit--workOrderId").value,r=""===n,s=document.querySelector("#form--workOrderEdit");function a(){var e;o.setUnsavedChanges(),null===(e=document.querySelector("button[type='submit'][form='form--workOrderEdit']"))||void 0===e||e.classList.remove("is-light")}function l(){var e;o.clearUnsavedChanges(),null===(e=document.querySelector("button[type='submit'][form='form--workOrderEdit']"))||void 0===e||e.classList.add("is-light")}o.initializeDatePickers(null===(S=s.querySelector("#workOrderEdit--workOrderOpenDateString"))||void 0===S?void 0:S.closest(".field")),o.initializeUnlockFieldButtons(s),s.addEventListener("submit",e=>{e.preventDefault(),cityssm.postJSON(`${o.urlPrefix}/workOrders/${r?"doCreateWorkOrder":"doUpdateWorkOrder"}`,e.currentTarget,e=>{var t;const n=e;n.success?(l(),r?window.location.href=o.getWorkOrderURL(n.workOrderId,!0):bulmaJS.alert({message:"Work Order Updated Successfully",contextualColorName:"success"})):bulmaJS.alert({title:"Error Updating Work Order",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})});const i=s.querySelectorAll("input, select, textarea");for(const e of i)e.addEventListener("change",a);function d(){cityssm.postJSON(`${o.urlPrefix}/workOrders/doCloseWorkOrder`,{workOrderId:n},e=>{var t;const r=e;r.success?(l(),window.location.href=o.getWorkOrderURL(n)):bulmaJS.alert({title:"Error Closing Work Order",message:null!==(t=r.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}function c(){cityssm.postJSON(`${o.urlPrefix}/workOrders/doDeleteWorkOrder`,{workOrderId:n},e=>{var t;const n=e;n.success?(l(),window.location.href=`${o.urlPrefix}/workOrders`):bulmaJS.alert({title:"Error Deleting Work Order",message:null!==(t=n.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})})}let u;if(null===(m=document.querySelector("#button--closeWorkOrder"))||void 0===m||m.addEventListener("click",()=>{u.some(e=>!e.workOrderMilestoneCompletionDate)?bulmaJS.alert({title:"Outstanding Milestones",message:"You cannot close a work order with outstanding milestones.\n Either complete the outstanding milestones, or remove them from the work order.",contextualColorName:"warning"}):bulmaJS.confirm({title:"Close Work Order",message:o.hasUnsavedChanges()?"Are you sure you want to close this work order with unsaved changes?":"Are you sure you want to close this work order?",contextualColorName:o.hasUnsavedChanges()?"warning":"info",okButton:{text:"Yes, Close Work Order",callbackFunction:d}})}),null===(e=document.querySelector("#button--deleteWorkOrder"))||void 0===e||e.addEventListener("click",e=>{e.preventDefault(),bulmaJS.confirm({title:"Delete Work Order",message:"Are you sure you want to delete this work order?",contextualColorName:"warning",okButton:{text:"Yes, Delete Work Order",callbackFunction:c}})}),!r){var m;Object.defineProperty(exports,"__esModule",{value:!0});let e=exports.workOrderLots;delete exports.workOrderLots;let t=exports.workOrderLotOccupancies;function p(e){const r=e.currentTarget.closest(".container--lotOccupancy").dataset.lotOccupancyId;bulmaJS.confirm({title:`Delete ${o.escapedAliases.Occupancy} Relationship`,message:`Are you sure you want to remove the relationship to this ${o.escapedAliases.occupancy} record from this work order? Note that the record will remain.`,contextualColorName:"warning",okButton:{text:"Yes, Delete Relationship",callbackFunction:function(){cityssm.postJSON(`${o.urlPrefix}/workOrders/doDeleteWorkOrderLotOccupancy`,{workOrderId:n,lotOccupancyId:r},e=>{var o;const n=e;n.success?(t=n.workOrderLotOccupancies,g()):bulmaJS.alert({title:"Error Deleting Relationship",message:null!==(o=n.errorMessage)&&void 0!==o?o:"",contextualColorName:"danger"})})}}})}function v(t,r){cityssm.postJSON(`${o.urlPrefix}/workOrders/doAddWorkOrderLot`,{workOrderId:n,lotId:t},t=>{var n;const s=t;s.success?(e=s.workOrderLots,g()):bulmaJS.alert({title:`Error Adding ${o.escapedAliases.Lot}`,message:null!==(n=s.errorMessage)&&void 0!==n?n:"",contextualColorName:"danger"}),void 0!==r&&r(s.success)})}function y(e){var t;v(null!==(t=e.currentTarget.dataset.lotId)&&void 0!==t?t:"")}function O(t){var r;const s=Number.parseInt(null!==(r=t.currentTarget.closest(".container--lot").dataset.lotId)&&void 0!==r?r:"",10),a=e.find(e=>e.lotId===s);let l;function i(t){t.preventDefault(),cityssm.postJSON(`${o.urlPrefix}/workOrders/doUpdateLotStatus`,t.currentTarget,t=>{var o;const n=t;n.success?(e=n.workOrderLots,g(),l()):bulmaJS.alert({title:"Error Deleting Relationship",message:null!==(o=n.errorMessage)&&void 0!==o?o:"",contextualColorName:"danger"})})}cityssm.openHtmlModal("lot-editLotStatus",{onshow(e){var t,r,l;o.populateAliases(e),e.querySelector("#lotStatusEdit--lotId").value=s.toString(),e.querySelector("#lotStatusEdit--lotName").value=null!==(t=a.lotName)&&void 0!==t?t:"";const i=e.querySelector("#lotStatusEdit--lotStatusId");let d=!1;for(const e of exports.lotStatuses){const t=document.createElement("option");t.value=e.lotStatusId.toString(),t.textContent=e.lotStatus,e.lotStatusId===a.lotStatusId&&(d=!0),i.append(t)}if(!d&&a.lotStatusId){const e=document.createElement("option");e.value=a.lotStatusId.toString(),e.textContent=null!==(r=a.lotStatus)&&void 0!==r?r:"",i.append(e)}a.lotStatusId&&(i.value=a.lotStatusId.toString()),null===(l=e.querySelector("form"))||void 0===l||l.insertAdjacentHTML("beforeend",``)},onshown(e,t){var o;l=t,bulmaJS.toggleHtmlClipped(),null===(o=e.querySelector("form"))||void 0===o||o.addEventListener("submit",i)},onremoved(){bulmaJS.toggleHtmlClipped()}})}function h(t){const r=t.currentTarget.closest(".container--lot").dataset.lotId;bulmaJS.confirm({title:`Delete ${o.escapedAliases.Occupancy} Relationship`,message:`Are you sure you want to remove the relationship to this ${o.escapedAliases.occupancy} record from this work order? Note that the record will remain.`,contextualColorName:"warning",okButton:{text:"Yes, Delete Relationship",callbackFunction:function(){cityssm.postJSON(`${o.urlPrefix}/workOrders/doDeleteWorkOrderLot`,{workOrderId:n,lotId:r},t=>{var o;const n=t;n.success?(e=n.workOrderLots,g()):bulmaJS.alert({title:"Error Deleting Relationship",message:null!==(o=n.errorMessage)&&void 0!==o?o:"",contextualColorName:"danger"})})}}})}function g(){!function(){var n,r,s,a,l,i,d,c,u,m;const v=document.querySelector("#container--lotOccupancies");if(document.querySelector(".tabs a[href='#relatedTab--lotOccupancies'] .tag").textContent=t.length.toString(),0===t.length)return void(v.innerHTML=`
\n
There are no ${o.escapedAliases.occupancies} associated with this work order.
\n
`);v.innerHTML=`
\n
\n
\n
${o.escapedAliases.Occupancy} Type
\n
${o.escapedAliases.Lot}
\n
${o.escapedAliases.OccupancyStartDate}
\n
End Date
\n
${o.escapedAliases.Occupants}
\n
\n
\n \n
`;const O=cityssm.dateToString(new Date);for(const h of t){const t=document.createElement("tr");t.className="container--lotOccupancy",t.dataset.lotOccupancyId=h.lotOccupancyId.toString();const g=!(h.occupancyEndDate&&h.occupancyEndDateStringh.lotId===e.lotId);t.innerHTML=`
`;for(const e of l.lotOccupancies){const l=document.createElement("tr");l.className="container--lotOccupancy",l.dataset.lotOccupancyId=e.lotOccupancyId.toString(),l.innerHTML=`
';for(const a of f){const i=document.createElement("tr");i.dataset.workOrderCommentId=null===(e=a.workOrderCommentId)||void 0===e?void 0:e.toString(),i.innerHTML=`
`,null===(n=i.querySelector(".button--edit"))||void 0===n||n.addEventListener("click",b),null===(r=i.querySelector(".button--delete"))||void 0===r||r.addEventListener("click",M),null===(s=l.querySelector("tbody"))||void 0===s||s.append(i)}a.innerHTML="",a.append(l)}function T(e){for(const t of e.querySelectorAll(".panel-block"))t.remove()}function C(e,t){T(t),t.insertAdjacentHTML("beforeend",`
`),cityssm.postJSON(`${o.urlPrefix}/workOrders/doGetWorkOrderMilestones`,{workOrderMilestoneDateFilter:"date",workOrderMilestoneDateString:e},o=>{var r,s,a,l;const i=o.workOrderMilestones.filter(e=>e.workOrderId.toString()!==n);T(t);for(const e of i)t.insertAdjacentHTML("beforeend",`
\n There are no milestones on other work orders scheduled for\n ${cityssm.escapeHTML(e)}.\n
\n
\n
`)})}function $(e){var t;const o=e;o.success?(u=o.workOrderMilestones,q()):bulmaJS.alert({title:"Error Reopening Milestone",message:null!==(t=o.errorMessage)&&void 0!==t?t:"",contextualColorName:"danger"})}function I(e){var t;e.preventDefault();const r=cityssm.dateToString(new Date),s=Number.parseInt(null!==(t=e.currentTarget.closest(".container--milestone").dataset.workOrderMilestoneId)&&void 0!==t?t:"",10),a=u.find(e=>e.workOrderMilestoneId===s);bulmaJS.confirm({title:"Complete Milestone",message:`Are you sure you want to complete this milestone?\n ${void 0!==a.workOrderMilestoneDateString&&""!==a.workOrderMilestoneDateString&&a.workOrderMilestoneDateString>r?" Note that this milestone is expected to be completed in the future.":""}`,messageIsHtml:!0,contextualColorName:"warning",okButton:{text:"Yes, Complete Milestone",callbackFunction:function(){cityssm.postJSON(`${o.urlPrefix}/workOrders/doCompleteWorkOrderMilestone`,{workOrderId:n,workOrderMilestoneId:s},$)}}})}function x(e){e.preventDefault();const t=e.currentTarget.closest(".container--milestone").dataset.workOrderMilestoneId;bulmaJS.confirm({title:"Reopen Milestone",message:"Are you sure you want to remove the completion status from this milestone, and reopen it?",contextualColorName:"warning",okButton:{text:"Yes, Reopen Milestone",callbackFunction:function(){cityssm.postJSON(`${o.urlPrefix}/workOrders/doReopenWorkOrderMilestone`,{workOrderId:n,workOrderMilestoneId:t},$)}}})}function E(e){e.preventDefault();const t=e.currentTarget.closest(".container--milestone").dataset.workOrderMilestoneId;bulmaJS.confirm({title:"Delete Milestone",message:"Are you sure you want to delete this milestone?",contextualColorName:"warning",okButton:{text:"Yes, Delete Milestone",callbackFunction:function(){cityssm.postJSON(`${o.urlPrefix}/workOrders/doDeleteWorkOrderMilestone`,{workOrderMilestoneId:t,workOrderId:n},$)}}})}function D(e){var t;e.preventDefault();const r=Number.parseInt(null!==(t=e.currentTarget.closest(".container--milestone").dataset.workOrderMilestoneId)&&void 0!==t?t:"",10),s=u.find(e=>e.workOrderMilestoneId===r);let a,l;function i(e){e.preventDefault(),cityssm.postJSON(`${o.urlPrefix}/workOrders/doUpdateWorkOrderMilestone`,e.currentTarget,e=>{const t=e;$(t),t.success&&a()})}cityssm.openHtmlModal("workOrder-editMilestone",{onshow(e){var t,o,r,a,i,d;e.querySelector("#milestoneEdit--workOrderId").value=n,e.querySelector("#milestoneEdit--workOrderMilestoneId").value=null!==(o=null===(t=s.workOrderMilestoneId)||void 0===t?void 0:t.toString())&&void 0!==o?o:"";const c=e.querySelector("#milestoneEdit--workOrderMilestoneTypeId");let u=!1;for(const e of exports.workOrderMilestoneTypes){const t=document.createElement("option");t.value=e.workOrderMilestoneTypeId.toString(),t.textContent=e.workOrderMilestoneType,e.workOrderMilestoneTypeId===s.workOrderMilestoneTypeId&&(t.selected=!0,u=!0),c.append(t)}if(!u&&s.workOrderMilestoneTypeId){const e=document.createElement("option");e.value=s.workOrderMilestoneTypeId.toString(),e.textContent=null!==(r=s.workOrderMilestoneType)&&void 0!==r?r:"",e.selected=!0,c.append(e)}(l=e.querySelector("#milestoneEdit--workOrderMilestoneDateString")).value=null!==(a=s.workOrderMilestoneDateString)&&void 0!==a?a:"",s.workOrderMilestoneTime&&(e.querySelector("#milestoneEdit--workOrderMilestoneTimeString").value=null!==(i=s.workOrderMilestoneTimeString)&&void 0!==i?i:""),e.querySelector("#milestoneEdit--workOrderMilestoneDescription").value=null!==(d=s.workOrderMilestoneDescription)&&void 0!==d?d:""},onshown(e,t){var n;a=t,bulmaJS.toggleHtmlClipped(),o.initializeDatePickers(e),null===(n=e.querySelector("form"))||void 0===n||n.addEventListener("submit",i);const r=document.querySelector("#milestoneEdit--conflictingMilestonesPanel");l.addEventListener("change",()=>{C(l.value,r)}),C(l.value,r)},onremoved(){bulmaJS.toggleHtmlClipped()}})}function q(){var e,t,o,n,r,s,a;const l=document.querySelector("#panel--milestones"),i=l.querySelectorAll(".panel-block");for(const e of i)e.remove();for(const i of u){const d=document.createElement("div");d.className="panel-block is-block container--milestone",d.dataset.workOrderMilestoneId=null===(e=i.workOrderMilestoneId)||void 0===e?void 0:e.toString(),d.innerHTML=`
There are no milestones that meet the search criteria.
\n
');a.innerHTML="";const k=cityssm.dateToString(new Date);let g,w="x";for(const y of s){w!==y.workOrderMilestoneDateString&&(g&&a.append(g),(g=document.createElement("div")).className="panel",g.innerHTML=`
\n ${cityssm.escapeHTML(0===y.workOrderMilestoneDate?"No Set Date":null!==(n=y.workOrderMilestoneDateString)&&void 0!==n?n:"")}\n
`,w=null!==(r=y.workOrderMilestoneDateString)&&void 0!==r?r:"");const s=document.createElement("div");s.className="panel-block is-block",!y.workOrderMilestoneCompletionDate&&""!==y.workOrderMilestoneDateString&&y.workOrderMilestoneDateString\n \n \n \n ${cityssm.escapeHTML(null!==(l=s.lotName)&&void 0!==l?l:"")}\n `;for(const s of null!==(o=y.workOrderLotOccupancies)&&void 0!==o?o:[])for(const n of null!==(c=s.lotOccupancyOccupants)&&void 0!==c?c:[])L+=`
`,g.append(s)}a.append(g)}(s.workOrderMilestones)})}n.addEventListener("change",()=>{r.closest("fieldset").disabled="date"!==n.value,i()}),e.initializeDatePickers(s),r.addEventListener("change",i),s.addEventListener("submit",i),i()})();
\ No newline at end of file
diff --git a/public-typescript/workOrderMilestoneCalendar.ts b/public/javascripts/workOrderMilestoneCalendar.ts
similarity index 98%
rename from public-typescript/workOrderMilestoneCalendar.ts
rename to public/javascripts/workOrderMilestoneCalendar.ts
index 20ffd078..be836365 100644
--- a/public-typescript/workOrderMilestoneCalendar.ts
+++ b/public/javascripts/workOrderMilestoneCalendar.ts
@@ -3,8 +3,8 @@
import type { cityssmGlobal } from '@cityssm/bulma-webapp-js/src/types.js'
-import type { LOS } from '../types/globalTypes.js'
-import type { WorkOrderMilestone } from '../types/recordTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
+import type { WorkOrderMilestone } from '../../types/recordTypes.js'
declare const cityssm: cityssmGlobal
diff --git a/public-typescript/workOrderOutlook.d.ts b/public/javascripts/workOrderOutlook.d.ts
similarity index 100%
rename from public-typescript/workOrderOutlook.d.ts
rename to public/javascripts/workOrderOutlook.d.ts
diff --git a/public-typescript/workOrderOutlook.js b/public/javascripts/workOrderOutlook.js
similarity index 100%
rename from public-typescript/workOrderOutlook.js
rename to public/javascripts/workOrderOutlook.js
diff --git a/public/javascripts/workOrderOutlook.min.js b/public/javascripts/workOrderOutlook.min.js
deleted file mode 100644
index 1a814e23..00000000
--- a/public/javascripts/workOrderOutlook.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{const e=exports.los,t=document.querySelector("#icsFilters--workOrderTypeIds"),r=document.querySelector("#icsFilters--workOrderMilestoneTypeIds"),s=document.querySelector("#icsFilters--calendarURL");function o(){let o=`${window.location.href.slice(0,Math.max(0,window.location.href.indexOf(window.location.pathname)+1))+e.urlPrefix}api/${e.apiKey}/milestoneICS/?`;if(!t.disabled&&t.selectedOptions.length>0){o+="workOrderTypeIds=";for(const e of t.selectedOptions)o+=`${e.value},`;o=`${o.slice(0,-1)}&`}if(!r.disabled&&r.selectedOptions.length>0){o+="workOrderMilestoneTypeIds=";for(const e of r.selectedOptions)o+=`${e.value},`;o=`${o.slice(0,-1)}&`}s.value=o.slice(0,-1)}document.querySelector("#icsFilters--workOrderTypeIds-all").addEventListener("change",e=>{t.disabled=e.currentTarget.checked}),document.querySelector("#icsFilters--workOrderMilestoneTypeIds-all").addEventListener("change",e=>{r.disabled=e.currentTarget.checked});const c=document.querySelector("#panel--icsFilters").querySelectorAll("input, select");for(const e of c)e.addEventListener("change",o);o(),s.addEventListener("click",()=>{s.focus(),s.select()})})();
\ No newline at end of file
diff --git a/public-typescript/workOrderOutlook.ts b/public/javascripts/workOrderOutlook.ts
similarity index 97%
rename from public-typescript/workOrderOutlook.ts
rename to public/javascripts/workOrderOutlook.ts
index a52fb67b..a7ce818c 100644
--- a/public-typescript/workOrderOutlook.ts
+++ b/public/javascripts/workOrderOutlook.ts
@@ -1,7 +1,7 @@
// eslint-disable-next-line @eslint-community/eslint-comments/disable-enable-pair
/* eslint-disable unicorn/prefer-module */
-import type { LOS } from '../types/globalTypes.js'
+import type { LOS } from '../../types/globalTypes.js'
declare const exports: Record
;(() => {
diff --git a/public-typescript/workOrderSearch.d.ts b/public/javascripts/workOrderSearch.d.ts
similarity index 100%
rename from public-typescript/workOrderSearch.d.ts
rename to public/javascripts/workOrderSearch.d.ts
diff --git a/public-typescript/workOrderSearch.js b/public/javascripts/workOrderSearch.js
similarity index 100%
rename from public-typescript/workOrderSearch.js
rename to public/javascripts/workOrderSearch.js
diff --git a/public/javascripts/workOrderSearch.min.js b/public/javascripts/workOrderSearch.min.js
deleted file mode 100644
index 1e90c023..00000000
--- a/public/javascripts/workOrderSearch.min.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),(()=>{const e=exports.los,t=exports.workOrderPrints,s=document.querySelector("#form--searchFilters");e.initializeDatePickers(s);const a=document.querySelector("#container--searchResults"),n=Number.parseInt(document.querySelector("#searchFilter--limit").value,10),r=document.querySelector("#searchFilter--offset");function o(s){var r,o,l,i,u,p,f,m,h,v,O,k,$,b,w,y,g,L,M,N;const T=s;if(0===T.workOrders.length)return void(a.innerHTML='
\n
There are no work orders that meet the search criteria.
\n
');const S=document.createElement("tbody");for(const s of T.workOrders){let a="";for(const t of null!==(r=s.workOrderLots)&&void 0!==r?r:[])a+=`
- Find an <%= configFunctions.getConfigProperty("aliases.occupancy") %> Record
+ Find an <%= configFunctions.getConfigProperty("aliases.occupancy") %> Record