Validierung Part II, neue Komponenten
This commit is contained in:
@@ -281,3 +281,87 @@ export interface ValidationMessage {
|
||||
field: string;
|
||||
message: string;
|
||||
}
|
||||
export function createDefaultUser(email: string, firstname: string, lastname: string): User {
|
||||
return {
|
||||
id: undefined,
|
||||
email,
|
||||
firstname,
|
||||
lastname,
|
||||
phoneNumber: null,
|
||||
description: null,
|
||||
companyName: null,
|
||||
companyOverview: null,
|
||||
companyWebsite: null,
|
||||
companyLocation: null,
|
||||
offeredServices: null,
|
||||
areasServed: [],
|
||||
hasProfile: false,
|
||||
hasCompanyLogo: false,
|
||||
licensedIn: [],
|
||||
gender: null,
|
||||
customerType: 'buyer',
|
||||
customerSubType: null,
|
||||
created: new Date(),
|
||||
updated: new Date(),
|
||||
};
|
||||
}
|
||||
export function createDefaultCommercialPropertyListing(): CommercialPropertyListing {
|
||||
return {
|
||||
id: undefined,
|
||||
serialId: undefined,
|
||||
email: '',
|
||||
type: null,
|
||||
title: '',
|
||||
description: '',
|
||||
city: '',
|
||||
state: '',
|
||||
price: null,
|
||||
favoritesForUser: [],
|
||||
hideImage: false,
|
||||
draft: false,
|
||||
zipCode: null,
|
||||
county: '',
|
||||
imageOrder: [],
|
||||
imagePath: '',
|
||||
created: null,
|
||||
updated: null,
|
||||
visits: null,
|
||||
lastVisit: null,
|
||||
latitude: null,
|
||||
longitude: null,
|
||||
listingsCategory: 'commercialProperty',
|
||||
};
|
||||
}
|
||||
export function createDefaultBusinessListing(): BusinessListing {
|
||||
return {
|
||||
id: undefined,
|
||||
email: '',
|
||||
type: null,
|
||||
title: '',
|
||||
description: '',
|
||||
city: '',
|
||||
state: '',
|
||||
price: null,
|
||||
favoritesForUser: [],
|
||||
draft: false,
|
||||
realEstateIncluded: false,
|
||||
leasedLocation: false,
|
||||
franchiseResale: false,
|
||||
salesRevenue: null,
|
||||
cashFlow: null,
|
||||
supportAndTraining: '',
|
||||
employees: null,
|
||||
established: null,
|
||||
internalListingNumber: null,
|
||||
reasonForSale: '',
|
||||
brokerLicencing: '',
|
||||
internals: '',
|
||||
created: null,
|
||||
updated: null,
|
||||
visits: null,
|
||||
lastVisit: null,
|
||||
latitude: null,
|
||||
longitude: null,
|
||||
listingsCategory: 'business',
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user