polish
parent
20702c598a
commit
a4e4a11a59
|
|
@ -9,6 +9,7 @@ import exitHook from 'exit-hook';
|
|||
import { initializeDatabase } from '../database/initializeDatabase.js';
|
||||
import { DEBUG_NAMESPACE } from '../debug.config.js';
|
||||
import { getConfigProperty } from '../helpers/config.helpers.js';
|
||||
import version from '../version.js';
|
||||
const debug = Debug(`${DEBUG_NAMESPACE}:www:${process.pid}`);
|
||||
// INITIALIZE THE DATABASE
|
||||
await initializeDatabase();
|
||||
|
|
@ -18,6 +19,7 @@ const applicationName = getConfigProperty('application.applicationName');
|
|||
process.title = `${applicationName} (Primary)`;
|
||||
debug(`Primary pid: ${process.pid}`);
|
||||
debug(`Primary title: ${process.title}`);
|
||||
debug(`Version: ${version}`);
|
||||
debug(`Launching ${processCount} processes`);
|
||||
const clusterSettings = {
|
||||
exec: `${directoryName}/wwwProcess.js`
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ import { initializeDatabase } from '../database/initializeDatabase.js'
|
|||
import { DEBUG_NAMESPACE } from '../debug.config.js'
|
||||
import { getConfigProperty } from '../helpers/config.helpers.js'
|
||||
import type { WorkerMessage } from '../types/applicationTypes.js'
|
||||
import version from '../version.js'
|
||||
|
||||
const debug = Debug(`${DEBUG_NAMESPACE}:www:${process.pid}`)
|
||||
|
||||
|
|
@ -31,6 +32,7 @@ process.title = `${applicationName} (Primary)`
|
|||
|
||||
debug(`Primary pid: ${process.pid}`)
|
||||
debug(`Primary title: ${process.title}`)
|
||||
debug(`Version: ${version}`)
|
||||
debug(`Launching ${processCount} processes`)
|
||||
|
||||
const clusterSettings = {
|
||||
|
|
|
|||
|
|
@ -47,12 +47,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|||
<i class="fas fa-exclamation-triangle" aria-hidden="true"></i>
|
||||
</span>`
|
||||
: ''}
|
||||
</a><br />
|
||||
${cemetery.cemeteryKey === ''
|
||||
? ''
|
||||
: `<span class="tag">${cityssm.escapeHTML(cemetery.cemeteryKey)}</span>`}
|
||||
</a>
|
||||
<br />
|
||||
<span class="is-size-7">
|
||||
${cityssm.escapeHTML(cemetery.cemeteryDescription)}
|
||||
</span>
|
||||
</td><td>
|
||||
${cityssm.escapeHTML(cemetery.cemeteryKey)}
|
||||
</td><td>
|
||||
${cemetery.cemeteryAddress1 === ''
|
||||
? ''
|
||||
|
|
@ -70,19 +72,19 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|||
</td><td class="has-text-centered">
|
||||
${cemetery.parentCemeteryId === null
|
||||
? ''
|
||||
: `<span data-tooltip="Parent: ${cemetery.parentCemeteryName ?? '(No Name)'}">
|
||||
: `<span class="icon" data-tooltip="Parent: ${cemetery.parentCemeteryName ?? '(No Name)'}">
|
||||
<i class="fas fa-turn-up" role="img" aria-label="Parent: ${cemetery.parentCemeteryName ?? '(No Name)'}"></i>
|
||||
</span>`}
|
||||
</td><td class="has-text-centered">
|
||||
${cemetery.cemeteryLatitude && cemetery.cemeteryLongitude
|
||||
? `<span data-tooltip="Has Geographic Coordinates">
|
||||
<i class="fas fa-map-marker-alt" role="img" aria-label="Has Geographic Coordinates"></i>
|
||||
? `<span class="icon" data-tooltip="Geographic Coordinates">
|
||||
<i class="fas fa-map-marker-alt" role="img" aria-label="Geographic Coordinates"></i>
|
||||
</span>`
|
||||
: ''}
|
||||
</td><td class="has-text-centered">
|
||||
${(cemetery.cemeterySvg ?? '') === ''
|
||||
? ''
|
||||
: '<span data-tooltip="Has Image"><i class="fas fa-image" role="img" aria-label="Has Image"></i></span>'}
|
||||
: `<span class="icon" data-tooltip="Image">
|
||||
<i class="fas fa-image" role="img" aria-label="Image"></i>
|
||||
</span>`}
|
||||
</td><td class="has-text-right">
|
||||
<a href="${sunrise.urlPrefix}/burialSites?cemeteryId=${cemetery.cemeteryId}">${cemetery.burialSiteCount}</a>
|
||||
</td>
|
||||
|
|
@ -100,13 +102,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|||
'table is-fullwidth is-striped is-hoverable has-sticky-header';
|
||||
searchResultsTableElement.innerHTML = `<thead><tr>
|
||||
<th>Cemetery</th>
|
||||
<th>Key</th>
|
||||
<th>Address</th>
|
||||
<th>Phone Number</th>
|
||||
<th class="has-text-centered">Parent</th>
|
||||
<th class="has-text-centered">Coordinates</th>
|
||||
<th class="has-text-centered">Image</th>
|
||||
<th class="has-text-right">Burial Site Count</th>
|
||||
<th class="has-text-centered">Features</th>
|
||||
<th class="has-text-right">Burial Sites</th>
|
||||
</tr></thead>`;
|
||||
searchResultsTableElement.append(searchResultsTbodyElement);
|
||||
searchResultsContainerElement.append(searchResultsTableElement);
|
||||
|
|
|
|||
|
|
@ -78,12 +78,16 @@ declare const exports: Record<string, unknown>
|
|||
</span>`
|
||||
: ''
|
||||
}
|
||||
</a><br />
|
||||
${
|
||||
cemetery.cemeteryKey === ''
|
||||
? ''
|
||||
: `<span class="tag">${cityssm.escapeHTML(cemetery.cemeteryKey)}</span>`
|
||||
}
|
||||
</a>
|
||||
<br />
|
||||
<span class="is-size-7">
|
||||
${cityssm.escapeHTML(cemetery.cemeteryDescription)}
|
||||
</span>
|
||||
</td><td>
|
||||
${cityssm.escapeHTML(cemetery.cemeteryKey)}
|
||||
</td><td>
|
||||
${
|
||||
cemetery.cemeteryAddress1 === ''
|
||||
|
|
@ -108,23 +112,23 @@ declare const exports: Record<string, unknown>
|
|||
${
|
||||
cemetery.parentCemeteryId === null
|
||||
? ''
|
||||
: `<span data-tooltip="Parent: ${cemetery.parentCemeteryName ?? '(No Name)'}">
|
||||
: `<span class="icon" data-tooltip="Parent: ${cemetery.parentCemeteryName ?? '(No Name)'}">
|
||||
<i class="fas fa-turn-up" role="img" aria-label="Parent: ${cemetery.parentCemeteryName ?? '(No Name)'}"></i>
|
||||
</span>`
|
||||
}
|
||||
</td><td class="has-text-centered">
|
||||
${
|
||||
cemetery.cemeteryLatitude && cemetery.cemeteryLongitude
|
||||
? `<span data-tooltip="Has Geographic Coordinates">
|
||||
<i class="fas fa-map-marker-alt" role="img" aria-label="Has Geographic Coordinates"></i>
|
||||
? `<span class="icon" data-tooltip="Geographic Coordinates">
|
||||
<i class="fas fa-map-marker-alt" role="img" aria-label="Geographic Coordinates"></i>
|
||||
</span>`
|
||||
: ''
|
||||
}
|
||||
</td><td class="has-text-centered">
|
||||
${
|
||||
(cemetery.cemeterySvg ?? '') === ''
|
||||
? ''
|
||||
: '<span data-tooltip="Has Image"><i class="fas fa-image" role="img" aria-label="Has Image"></i></span>'
|
||||
: `<span class="icon" data-tooltip="Image">
|
||||
<i class="fas fa-image" role="img" aria-label="Image"></i>
|
||||
</span>`
|
||||
}
|
||||
</td><td class="has-text-right">
|
||||
<a href="${sunrise.urlPrefix}/burialSites?cemeteryId=${cemetery.cemeteryId}">${cemetery.burialSiteCount}</a>
|
||||
|
|
@ -147,13 +151,10 @@ declare const exports: Record<string, unknown>
|
|||
|
||||
searchResultsTableElement.innerHTML = `<thead><tr>
|
||||
<th>Cemetery</th>
|
||||
<th>Key</th>
|
||||
<th>Address</th>
|
||||
<th>Phone Number</th>
|
||||
<th class="has-text-centered">Parent</th>
|
||||
<th class="has-text-centered">Coordinates</th>
|
||||
<th class="has-text-centered">Image</th>
|
||||
<th class="has-text-right">Burial Site Count</th>
|
||||
<th class="has-text-centered">Features</th>
|
||||
<th class="has-text-right">Burial Sites</th>
|
||||
</tr></thead>`
|
||||
|
||||
searchResultsTableElement.append(searchResultsTbodyElement)
|
||||
|
|
|
|||
|
|
@ -2,6 +2,10 @@
|
|||
min-height: 100vh;
|
||||
}
|
||||
|
||||
.has-width-1 {
|
||||
width: 1px;
|
||||
}
|
||||
|
||||
/* to fix page titles inside level components, set on .level-left */
|
||||
|
||||
.has-flex-shrink-1 {
|
||||
|
|
|
|||
|
|
@ -1,13 +1,13 @@
|
|||
export function getDeathAgePeriod(legacyDeathAgePeriod) {
|
||||
switch (legacyDeathAgePeriod.toLowerCase()) {
|
||||
case 'yrs': {
|
||||
return 'Years';
|
||||
case 'dys': {
|
||||
return 'Days';
|
||||
}
|
||||
case 'mts': {
|
||||
return 'Months';
|
||||
}
|
||||
case 'dys': {
|
||||
return 'Days';
|
||||
case 'yrs': {
|
||||
return 'Years';
|
||||
}
|
||||
default: {
|
||||
return legacyDeathAgePeriod;
|
||||
|
|
|
|||
|
|
@ -1,13 +1,13 @@
|
|||
export function getDeathAgePeriod(legacyDeathAgePeriod: string): string {
|
||||
switch (legacyDeathAgePeriod.toLowerCase()) {
|
||||
case 'yrs': {
|
||||
return 'Years'
|
||||
case 'dys': {
|
||||
return 'Days'
|
||||
}
|
||||
case 'mts': {
|
||||
return 'Months'
|
||||
}
|
||||
case 'dys': {
|
||||
return 'Days'
|
||||
case 'yrs': {
|
||||
return 'Years'
|
||||
}
|
||||
|
||||
default: {
|
||||
|
|
|
|||
|
|
@ -264,7 +264,7 @@
|
|||
<div class="column">
|
||||
<div class="panel">
|
||||
<div class="panel-heading">
|
||||
<div class="level">
|
||||
<div class="level is-mobile">
|
||||
<div class="level-left">
|
||||
<div class="level-item">
|
||||
<h2 class="title is-5 has-text-weight-bold has-text-white">Image</h2>
|
||||
|
|
@ -345,10 +345,12 @@
|
|||
<thead>
|
||||
<tr>
|
||||
<th>Type</th>
|
||||
<th class="has-text-right">
|
||||
Burial Site Count
|
||||
<th class="has-width-1 has-text-right">
|
||||
Burial Sites
|
||||
</th>
|
||||
<th class="has-width-1 has-text-right">
|
||||
Percentage
|
||||
</th>
|
||||
<th class="has-text-right">Percentage</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
@ -375,10 +377,12 @@
|
|||
<thead>
|
||||
<tr>
|
||||
<th>Status</th>
|
||||
<th class="has-text-right">
|
||||
Burial Site Count
|
||||
<th class="has-width-1 has-text-right">
|
||||
Burial Sites
|
||||
</th>
|
||||
<th class="has-width-1 has-text-right">
|
||||
Percentage
|
||||
</th>
|
||||
<th class="has-text-right">Percentage</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
|
|||
|
|
@ -209,10 +209,12 @@
|
|||
<thead>
|
||||
<tr>
|
||||
<th>Type</th>
|
||||
<th class="has-text-right">
|
||||
Burial Site Count
|
||||
<th class="has-width-1 has-text-right">
|
||||
Burial Sites
|
||||
</th>
|
||||
<th class="has-width-1 has-text-right">
|
||||
Percentage
|
||||
</th>
|
||||
<th class="has-text-right">Percentage</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
@ -239,10 +241,10 @@
|
|||
<thead>
|
||||
<tr>
|
||||
<th>Status</th>
|
||||
<th class="has-text-right">
|
||||
Burial Site Count
|
||||
<th class="has-width-1 has-text-right">
|
||||
Burial Sites
|
||||
</th>
|
||||
<th class="has-text-right">Percentage</th>
|
||||
<th class="has-width-1 has-text-right">Percentage</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
|
|||
Loading…
Reference in New Issue