You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

282 lines
6.8 KiB
JavaScript

// This file was generated by running js_conversion.py
// It converts the neomodel declaration of this element into js classes.
(() => {
const models = window.models || {}
models.Person = class Person extends StructuredNode {
constructor(json) {
super(json)
}
get_name() {
return this.json.name
}
set_name(new_val) {
this._set('name', new_val)
}
get_father() {
return this._get_relation('father')
}
link_father(ref) {
return this._link_relation('father', ref)
}
unlink_father(ref) {
return this._unlink_relation('father', ref)
}
get_mother() {
return this._get_relation('mother')
}
link_mother(ref) {
return this._link_relation('mother', ref)
}
unlink_mother(ref) {
return this._unlink_relation('mother', ref)
}
get_birthdate() {
return this.json.birthdate
}
set_birthdate(new_val) {
this._set('birthdate', new_val)
}
get_deceased() {
return this.json.deceased
}
set_deceased(new_val) {
this._set('deceased', new_val)
}
get_description() {
return this.json.description
}
set_description(new_val) {
this._set('description', new_val)
}
get_picture() {
return this.json.picture
}
set_picture(new_val) {
this._set('picture', new_val)
}
get_places() {
return this._get_relation('places')
}
link_places(ref) {
return this._link_relation('places', ref)
}
unlink_places(ref) {
return this._unlink_relation('places', ref)
}
}
StructuredNode.registerClassDefinition(models.Person, {"uid": {"field": "uid", "type": "UniqueIdProperty", "required": false}, "name": {"field": "name", "type": "StringProperty", "required": true}, "birthdate": {"field": "birthdate", "type": "DateProperty", "required": false}, "deceased": {"field": "deceased", "type": "DateProperty", "required": false}, "description": {"field": "description", "type": "StringProperty", "required": false}, "picture": {"field": "picture", "type": "StringProperty", "required": false}}, {"father": {"field": "father", "target": "Person", "cardinality": "ZeroOrOne"}, "mother": {"field": "mother", "target": "Person", "cardinality": "ZeroOrOne"}, "places": {"field": "places", "target": "Place", "cardinality": "ZeroOrMore"}})
models.Event = class Event extends StructuredNode {
constructor(json) {
super(json)
}
get_name() {
return this.json.name
}
set_name(new_val) {
this._set('name', new_val)
}
get_participants() {
return this._get_relation('participants')
}
link_participants(ref) {
return this._link_relation('participants', ref)
}
unlink_participants(ref) {
return this._unlink_relation('participants', ref)
}
get_places() {
return this._get_relation('places')
}
link_places(ref) {
return this._link_relation('places', ref)
}
unlink_places(ref) {
return this._unlink_relation('places', ref)
}
get_date() {
return this.json.date
}
set_date(new_val) {
this._set('date', new_val)
}
get_end_date() {
return this.json.end_date
}
set_end_date(new_val) {
this._set('end_date', new_val)
}
get_related_events() {
return this._get_relation('related_events')
}
link_related_events(ref) {
return this._link_relation('related_events', ref)
}
unlink_related_events(ref) {
return this._unlink_relation('related_events', ref)
}
}
StructuredNode.registerClassDefinition(models.Event, {"uid": {"field": "uid", "type": "UniqueIdProperty", "required": false}, "name": {"field": "name", "type": "StringProperty", "required": true}, "date": {"field": "date", "type": "DateProperty", "required": false}, "end_date": {"field": "end_date", "type": "DateProperty", "required": false}}, {"participants": {"field": "participants", "target": "Person", "cardinality": "ZeroOrMore"}, "places": {"field": "places", "target": "Place", "cardinality": "ZeroOrMore"}, "related_events": {"field": "related_events", "target": "Event", "cardinality": "ZeroOrMore"}})
models.Place = class Place extends StructuredNode {
constructor(json) {
super(json)
}
get_name() {
return this.json.name
}
set_name(new_val) {
this._set('name', new_val)
}
get_description() {
return this.json.description
}
set_description(new_val) {
this._set('description', new_val)
}
get_visitors() {
return this._get_relation('visitors')
}
link_visitors(ref) {
return this._link_relation('visitors', ref)
}
unlink_visitors(ref) {
return this._unlink_relation('visitors', ref)
}
}
StructuredNode.registerClassDefinition(models.Place, {"uid": {"field": "uid", "type": "UniqueIdProperty", "required": false}, "name": {"field": "name", "type": "StringProperty", "required": true}, "description": {"field": "description", "type": "StringProperty", "required": false}}, {"visitors": {"field": "visitors", "target": "Person", "cardinality": "ZeroOrMore"}})
models.Image = class Image extends StructuredNode {
constructor(json) {
super(json)
}
get_description() {
return this.json.description
}
set_description(new_val) {
this._set('description', new_val)
}
get_pictured() {
return this._get_relation('pictured')
}
link_pictured(ref) {
return this._link_relation('pictured', ref)
}
unlink_pictured(ref) {
return this._unlink_relation('pictured', ref)
}
get_place() {
return this._get_relation('place')
}
link_place(ref) {
return this._link_relation('place', ref)
}
unlink_place(ref) {
return this._unlink_relation('place', ref)
}
get_date() {
return this.json.date
}
set_date(new_val) {
this._set('date', new_val)
}
}
StructuredNode.registerClassDefinition(models.Image, {"uid": {"field": "uid", "type": "StringProperty", "required": true}, "description": {"field": "description", "type": "StringProperty", "required": false}, "date": {"field": "date", "type": "DateProperty", "required": false}}, {"pictured": {"field": "pictured", "target": "Person", "cardinality": "ZeroOrMore"}, "place": {"field": "place", "target": "Place", "cardinality": "ZeroOrMore"}})
window.models = models;
})()