Compare commits
No commits in common. "b61851e12284fbffa167acc08b94ada6a6936c22" and "5072d473bb83fd5fabed1e213539851bb43e4225" have entirely different histories.
b61851e122
...
5072d473bb
|
@ -54,16 +54,15 @@
|
||||||
<h1>Register for OwlBoard</h1>
|
<h1>Register for OwlBoard</h1>
|
||||||
<br />
|
<br />
|
||||||
<p>
|
<p>
|
||||||
Tap the button to register this device, or scan the barcode with another device.
|
Use the link below or scan the barcode to register for OwlBoard
|
||||||
|
(Staff Version)
|
||||||
</p>
|
</p>
|
||||||
<br />
|
<br />
|
||||||
<a
|
<a
|
||||||
href="https://owlboard.info/more/reg/submit?key=>>ACCESSCODE<<"
|
href="https://owlboard.info/more/reg/submit?key=>>ACCESSCODE<<"
|
||||||
id="button"
|
id="button"
|
||||||
>Register this device</a
|
>Register</a
|
||||||
>
|
>
|
||||||
<br /><br /><br />
|
|
||||||
<p>Or scan with the device you want to register</p>
|
|
||||||
<br />
|
<br />
|
||||||
<img
|
<img
|
||||||
src="https://barcodes.fjla.uk/generate?type=aztec&text=https%3A%2F%2Fowlboard.info%2Fmore%2Freg%2Fsubmit%3Fkey%3D>>ACCESSCODE<<"
|
src="https://barcodes.fjla.uk/generate?type=aztec&text=https%3A%2F%2Fowlboard.info%2Fmore%2Freg%2Fsubmit%3Fkey%3D>>ACCESSCODE<<"
|
||||||
|
|
|
@ -24,9 +24,8 @@ async function query(collection, query, returnId = false) {
|
||||||
log.out(`dbAccess.query: Running Query: ${JSON.stringify(query)}`, "info");
|
log.out(`dbAccess.query: Running Query: ${JSON.stringify(query)}`, "info");
|
||||||
increment(collection);
|
increment(collection);
|
||||||
log.out("dbAccess.query: Query response:");
|
log.out("dbAccess.query: Query response:");
|
||||||
let result = await qcursor.toArray();
|
console.log(await qcursor.toArray());
|
||||||
console.log(result);
|
return await qcursor.toArray();
|
||||||
return result;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async function queryProject(collection, query, projection) {
|
async function queryProject(collection, query, projection) {
|
||||||
|
|
|
@ -34,15 +34,10 @@ export function transform(input: any): StaffLdb | null {
|
||||||
}
|
}
|
||||||
|
|
||||||
function transformDateTime(input: string): Date {
|
function transformDateTime(input: string): Date {
|
||||||
console.log("Transform Date Time Running")
|
|
||||||
return new Date(input);
|
return new Date(input);
|
||||||
}
|
}
|
||||||
|
|
||||||
function transformNrcc(input: any): NrccMessage[] | undefined {
|
function transformNrcc(input: any): NrccMessage[] | undefined {
|
||||||
console.log("Transform Nrcc Running")
|
|
||||||
if (input === undefined) {
|
|
||||||
return input
|
|
||||||
}
|
|
||||||
let output: NrccMessage[] = [];
|
let output: NrccMessage[] = [];
|
||||||
let messages = input;
|
let messages = input;
|
||||||
if (!Array.isArray(input?.message)) {
|
if (!Array.isArray(input?.message)) {
|
||||||
|
@ -62,7 +57,6 @@ function transformNrcc(input: any): NrccMessage[] | undefined {
|
||||||
}
|
}
|
||||||
|
|
||||||
function transformTrainServices(input: any): TrainServices[] {
|
function transformTrainServices(input: any): TrainServices[] {
|
||||||
console.log("Transform Train Services Running")
|
|
||||||
let services: any = input?.service;
|
let services: any = input?.service;
|
||||||
let output: TrainServices[] = [];
|
let output: TrainServices[] = [];
|
||||||
if (services === undefined) {
|
if (services === undefined) {
|
||||||
|
@ -104,7 +98,6 @@ function transformTrainServices(input: any): TrainServices[] {
|
||||||
}
|
}
|
||||||
|
|
||||||
function transformLocation(input: any): ServiceLocation[] {
|
function transformLocation(input: any): ServiceLocation[] {
|
||||||
console.log("Transform Location Running")
|
|
||||||
let output: ServiceLocation[] = [];
|
let output: ServiceLocation[] = [];
|
||||||
let locations: any[] = input.location;
|
let locations: any[] = input.location;
|
||||||
if (!Array.isArray(input.location)) {
|
if (!Array.isArray(input.location)) {
|
||||||
|
@ -123,7 +116,6 @@ function transformLocation(input: any): ServiceLocation[] {
|
||||||
}
|
}
|
||||||
|
|
||||||
export function calculateLength(input: any): number | undefined {
|
export function calculateLength(input: any): number | undefined {
|
||||||
console.log("Calculate Length Running")
|
|
||||||
let length: number;
|
let length: number;
|
||||||
if (input?.length) {
|
if (input?.length) {
|
||||||
length = input.length;
|
length = input.length;
|
||||||
|
@ -137,7 +129,6 @@ export function calculateLength(input: any): number | undefined {
|
||||||
}
|
}
|
||||||
|
|
||||||
function transformUnspecifiedDateTime(input: string): Date | undefined {
|
function transformUnspecifiedDateTime(input: string): Date | undefined {
|
||||||
console.log("Transform Unspecified Date Time Running")
|
|
||||||
if (!input) {
|
if (!input) {
|
||||||
return undefined;
|
return undefined;
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,51 +53,4 @@ export const inputs: any[] = [
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
|
||||||
GetBoardResult: {
|
|
||||||
generatedAt: "2023-08-01T20:37:05.559123+01:00",
|
|
||||||
locationName: "Railway Station",
|
|
||||||
crs: "RLY",
|
|
||||||
stationManager: "Network Rail",
|
|
||||||
stationManagerCode: "RT",
|
|
||||||
isTruncated: "true",
|
|
||||||
trainServices: {
|
|
||||||
service: [
|
|
||||||
{
|
|
||||||
rid: "202308017159276",
|
|
||||||
uid: "G59276",
|
|
||||||
trainid: "1M83",
|
|
||||||
sdd: "2023-08-01",
|
|
||||||
operator: "CrossCountry",
|
|
||||||
operatorCode: "XC",
|
|
||||||
sta: "2023-08-01T20:24:00",
|
|
||||||
ata: "2023-08-01T20:27:22",
|
|
||||||
arrivalType: "Actual",
|
|
||||||
std: "2023-08-01T20:35:00",
|
|
||||||
etd: "2023-08-01T20:35:00",
|
|
||||||
departureType: "Estimated",
|
|
||||||
departureSource: "Darwin",
|
|
||||||
platform: "5",
|
|
||||||
length: "10",
|
|
||||||
origin: {
|
|
||||||
location: {
|
|
||||||
locationName: "Plymouth",
|
|
||||||
crs: "PLY",
|
|
||||||
tiploc: "PLYMTH",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
destination: {
|
|
||||||
location: {
|
|
||||||
locationName: "Birmingham New Street",
|
|
||||||
crs: "BHM",
|
|
||||||
tiploc: "BHAMNWS",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
category: "XX",
|
|
||||||
activities: "T",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
];
|
];
|
||||||
|
|
|
@ -45,37 +45,4 @@ export const outputs: StaffLdb[] = [
|
||||||
busServices: [],
|
busServices: [],
|
||||||
ferryServices: [],
|
ferryServices: [],
|
||||||
},
|
},
|
||||||
{
|
|
||||||
generatedAt: expect.any(Date),
|
|
||||||
locationName: "Railway Station",
|
|
||||||
stationManagerCode: "RT",
|
|
||||||
trainServices: [
|
|
||||||
{
|
|
||||||
rid: "202308017159276",
|
|
||||||
uid: "G59276",
|
|
||||||
trainid: "1M83",
|
|
||||||
operatorCode: "XC",
|
|
||||||
sta: expect.any(Date),
|
|
||||||
ata: expect.any(Date),
|
|
||||||
arrivalType: "Actual",
|
|
||||||
std: expect.any(Date),
|
|
||||||
etd: expect.any(Date),
|
|
||||||
departureType: "Estimated",
|
|
||||||
platform: "5",
|
|
||||||
length: 10,
|
|
||||||
origin: [
|
|
||||||
{
|
|
||||||
tiploc: "PLYMTH",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
destination: [
|
|
||||||
{
|
|
||||||
tiploc: "BHAMNWS",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
busServices: [],
|
|
||||||
ferryServices: [],
|
|
||||||
},
|
|
||||||
];
|
];
|
||||||
|
|
Loading…
Reference in New Issue