@vibe-flats/booking-engine-common-server 1.0.68 → 1.0.70
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.
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import mongoose from 'mongoose';
|
|
2
2
|
import { AreaDocument } from './areas';
|
|
3
3
|
import { CityDocument } from './cities';
|
|
4
|
+
import { MarketDocument } from './markets';
|
|
4
5
|
export interface BuildingDocument extends mongoose.Document {
|
|
5
6
|
name: string;
|
|
6
7
|
externalName: string;
|
|
7
8
|
publicId: string;
|
|
8
9
|
hubspotId: string;
|
|
9
10
|
area: AreaDocument;
|
|
11
|
+
market: MarketDocument;
|
|
10
12
|
city: CityDocument;
|
|
11
13
|
address: string;
|
|
12
14
|
state: string;
|
|
@@ -26,46 +26,17 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
26
26
|
exports.BuildingModel = void 0;
|
|
27
27
|
const mongoose_1 = __importStar(require("mongoose"));
|
|
28
28
|
const schema = new mongoose_1.default.Schema({
|
|
29
|
-
name: {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
},
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
},
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
required: false
|
|
40
|
-
},
|
|
41
|
-
hubspotId: {
|
|
42
|
-
type: String,
|
|
43
|
-
required: false
|
|
44
|
-
},
|
|
45
|
-
area: {
|
|
46
|
-
type: mongoose_1.Schema.Types.ObjectId,
|
|
47
|
-
ref: 'Area',
|
|
48
|
-
required: false
|
|
49
|
-
},
|
|
50
|
-
city: {
|
|
51
|
-
type: mongoose_1.Schema.Types.ObjectId,
|
|
52
|
-
ref: 'City',
|
|
53
|
-
required: false
|
|
54
|
-
},
|
|
55
|
-
address: {
|
|
56
|
-
type: String,
|
|
57
|
-
required: false
|
|
58
|
-
},
|
|
59
|
-
state: {
|
|
60
|
-
type: String,
|
|
61
|
-
required: false
|
|
62
|
-
},
|
|
63
|
-
zip: {
|
|
64
|
-
type: String,
|
|
65
|
-
required: false
|
|
66
|
-
},
|
|
29
|
+
name: { type: String, required: true },
|
|
30
|
+
externalName: { type: String, required: true },
|
|
31
|
+
publicId: { type: String, required: false },
|
|
32
|
+
hubspotId: { type: String, required: false },
|
|
33
|
+
area: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Area', required: false },
|
|
34
|
+
city: { type: mongoose_1.Schema.Types.ObjectId, ref: 'City', required: false },
|
|
35
|
+
market: { type: mongoose_1.Schema.Types.ObjectId, ref: 'Market', required: false },
|
|
36
|
+
address: { type: String, required: false },
|
|
37
|
+
state: { type: String, required: false },
|
|
38
|
+
zip: { type: String, required: false },
|
|
67
39
|
position: {
|
|
68
|
-
// coming from guesty
|
|
69
40
|
type: new mongoose_1.default.Schema({
|
|
70
41
|
lat: { type: Number, required: true },
|
|
71
42
|
lng: { type: Number, required: true }
|