tabletcommand-backend-models 7.3.32 → 7.3.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/constants.js +1 -0
- package/build/constants.js.map +1 -1
- package/build/models/department.js +27 -1
- package/build/models/department.js.map +1 -1
- package/build/models/incident-filter.js +3 -15
- package/build/models/incident-filter.js.map +1 -1
- package/build/models/location.js +2 -2
- package/build/models/location.js.map +1 -1
- package/build/models/schema/cad-incident.js +6 -0
- package/build/models/schema/cad-incident.js.map +1 -1
- package/build/models/schema/geojson.js +44 -0
- package/build/models/schema/geojson.js.map +1 -0
- package/build/test/mock.js.map +1 -1
- package/build/types/{geojson-point.js → geojson.js} +1 -1
- package/build/types/geojson.js.map +1 -0
- package/cspell.json +1 -0
- package/definitions/constants.d.ts +1 -0
- package/definitions/constants.d.ts.map +1 -1
- package/definitions/models/department.d.ts +5 -0
- package/definitions/models/department.d.ts.map +1 -1
- package/definitions/models/incident-filter.d.ts.map +1 -1
- package/definitions/models/schema/cad-incident.d.ts.map +1 -1
- package/definitions/models/schema/geojson.d.ts +13 -0
- package/definitions/models/schema/geojson.d.ts.map +1 -0
- package/definitions/test/mock.d.ts +2 -26
- package/definitions/test/mock.d.ts.map +1 -1
- package/definitions/types/cad-incident.d.ts +2 -0
- package/definitions/types/cad-incident.d.ts.map +1 -1
- package/definitions/types/common.d.ts +0 -4
- package/definitions/types/common.d.ts.map +1 -1
- package/definitions/types/department.d.ts +6 -0
- package/definitions/types/department.d.ts.map +1 -1
- package/definitions/types/geojson.d.ts +9 -0
- package/definitions/types/geojson.d.ts.map +1 -0
- package/definitions/types/incident-filter.d.ts +1 -1
- package/definitions/types/incident-filter.d.ts.map +1 -1
- package/definitions/types/location.d.ts +2 -2
- package/definitions/types/location.d.ts.map +1 -1
- package/gulpfile.js +1 -1
- package/package.json +10 -11
- package/src/constants.ts +1 -0
- package/src/models/department.ts +29 -0
- package/src/models/incident-filter.ts +3 -17
- package/src/models/location.ts +2 -2
- package/src/models/schema/cad-incident.ts +8 -0
- package/src/models/schema/geojson.ts +51 -0
- package/src/test/mock.ts +2 -1
- package/src/types/cad-incident.ts +2 -0
- package/src/types/common.ts +0 -5
- package/src/types/department.ts +7 -0
- package/src/types/geojson.ts +10 -0
- package/src/types/incident-filter.ts +1 -1
- package/src/types/location.ts +2 -2
- package/test.sh +1 -1
- package/build/models/schema/geojson-point.js +0 -24
- package/build/models/schema/geojson-point.js.map +0 -1
- package/build/types/geojson-point.js.map +0 -1
- package/definitions/models/schema/geojson-point.d.ts +0 -8
- package/definitions/models/schema/geojson-point.d.ts.map +0 -1
- package/definitions/types/geojson-point.d.ts +0 -5
- package/definitions/types/geojson-point.d.ts.map +0 -1
- package/src/models/schema/geojson-point.ts +0 -27
- package/src/types/geojson-point.ts +0 -4
package/src/types/location.ts
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import { Types } from "mongoose";
|
2
|
-
import { GeoJSONPointType } from "./geojson-point";
|
3
2
|
import { ColorSchemaType } from "./color";
|
3
|
+
import { GeoPoint } from "./geojson";
|
4
4
|
|
5
5
|
export interface LocationType {
|
6
6
|
_id: Types.ObjectId,
|
@@ -18,7 +18,7 @@ export interface LocationType {
|
|
18
18
|
heading: number,
|
19
19
|
kindType: string,
|
20
20
|
location?: { latitude: number, longitude: number, }; // provided by virtual.location
|
21
|
-
locationGeoJSON:
|
21
|
+
locationGeoJSON: GeoPoint,
|
22
22
|
modified: Date,
|
23
23
|
movedAt: Date,
|
24
24
|
opAreaCode: string
|
package/test.sh
CHANGED
@@ -1,24 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.default = GeoJSONPointSchema;
|
4
|
-
function GeoJSONPointSchema(mongoose) {
|
5
|
-
const { Schema } = mongoose;
|
6
|
-
const GeoJSONPoint = new Schema({
|
7
|
-
type: {
|
8
|
-
type: String,
|
9
|
-
required: true,
|
10
|
-
enum: ["Point"],
|
11
|
-
default: "Point",
|
12
|
-
},
|
13
|
-
coordinates: {
|
14
|
-
type: [Number],
|
15
|
-
required: true,
|
16
|
-
default: [],
|
17
|
-
},
|
18
|
-
}, {
|
19
|
-
_id: false,
|
20
|
-
id: false,
|
21
|
-
});
|
22
|
-
return GeoJSONPoint;
|
23
|
-
}
|
24
|
-
//# sourceMappingURL=geojson-point.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"geojson-point.js","sourceRoot":"","sources":["../../../src/models/schema/geojson-point.ts"],"names":[],"mappings":";;AAKA,qCAqBC;AArBD,SAAwB,kBAAkB,CAAC,QAAwB;IACjE,MAAM,EAAE,MAAM,EAAE,GAAG,QAAQ,CAAC;IAE5B,MAAM,YAAY,GAAG,IAAI,MAAM,CAAmB;QAChD,IAAI,EAAE;YACJ,IAAI,EAAE,MAAM;YACZ,QAAQ,EAAE,IAAI;YACd,IAAI,EAAE,CAAC,OAAO,CAAC;YACf,OAAO,EAAE,OAAO;SACjB;QACD,WAAW,EAAE;YACX,IAAI,EAAE,CAAC,MAAM,CAAC;YACd,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE,EAAE;SACZ;KACF,EAAE;QACD,GAAG,EAAE,KAAK;QACV,EAAE,EAAE,KAAK;KACV,CAAC,CAAC;IAEH,OAAO,YAAY,CAAC;AACtB,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"geojson-point.js","sourceRoot":"","sources":["../../src/types/geojson-point.ts"],"names":[],"mappings":""}
|
@@ -1,8 +0,0 @@
|
|
1
|
-
import { MongooseModule } from "../../helpers";
|
2
|
-
import { GeoJSONPointType } from "../../types/geojson-point";
|
3
|
-
export default function GeoJSONPointSchema(mongoose: MongooseModule): import("mongoose").Schema<GeoJSONPointType, import("mongoose").Model<GeoJSONPointType, any, any, any, import("mongoose").Document<unknown, any, GeoJSONPointType> & GeoJSONPointType & {
|
4
|
-
_id: import("mongoose").Types.ObjectId;
|
5
|
-
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, GeoJSONPointType, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<GeoJSONPointType>> & import("mongoose").FlatRecord<GeoJSONPointType> & {
|
6
|
-
_id: import("mongoose").Types.ObjectId;
|
7
|
-
}>;
|
8
|
-
//# sourceMappingURL=geojson-point.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"geojson-point.d.ts","sourceRoot":"","sources":["../../../src/models/schema/geojson-point.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACf,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAE7D,MAAM,CAAC,OAAO,UAAU,kBAAkB,CAAC,QAAQ,EAAE,cAAc;;;;GAqBlE"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"geojson-point.d.ts","sourceRoot":"","sources":["../../src/types/geojson-point.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAA;IACZ,WAAW,EAAE,MAAM,EAAE,CAAA;CACtB"}
|
@@ -1,27 +0,0 @@
|
|
1
|
-
import {
|
2
|
-
MongooseModule,
|
3
|
-
} from "../../helpers";
|
4
|
-
import { GeoJSONPointType } from "../../types/geojson-point";
|
5
|
-
|
6
|
-
export default function GeoJSONPointSchema(mongoose: MongooseModule) {
|
7
|
-
const { Schema } = mongoose;
|
8
|
-
|
9
|
-
const GeoJSONPoint = new Schema<GeoJSONPointType>({
|
10
|
-
type: {
|
11
|
-
type: String,
|
12
|
-
required: true,
|
13
|
-
enum: ["Point"],
|
14
|
-
default: "Point",
|
15
|
-
},
|
16
|
-
coordinates: {
|
17
|
-
type: [Number],
|
18
|
-
required: true,
|
19
|
-
default: [],
|
20
|
-
},
|
21
|
-
}, {
|
22
|
-
_id: false,
|
23
|
-
id: false,
|
24
|
-
});
|
25
|
-
|
26
|
-
return GeoJSONPoint;
|
27
|
-
}
|