{"action":"opened","issue":{"url":"https://api.github.com/repos/SteveStrong/FoundryX1/issues/11","labels_url":"https://api.github.com/repos/SteveStrong/FoundryX1/issues/11/labels{/name}","comments_url":"https://api.github.com/repos/SteveStrong/FoundryX1/issues/11/comments","events_url":"https://api.github.com/repos/SteveStrong/FoundryX1/issues/11/events","html_url":"https://github.com/SteveStrong/FoundryX1/issues/11","id":122362905,"number":11,"title":"modifing a relationship must Smash every property depending on it.","user":{"login":"SteveStrong","id":500861,"avatar_url":"https://avatars.githubusercontent.com/u/500861?v=3","gravatar_id":"","url":"https://api.github.com/users/SteveStrong","html_url":"https://github.com/SteveStrong","followers_url":"https://api.github.com/users/SteveStrong/followers","following_url":"https://api.github.com/users/SteveStrong/following{/other_user}","gists_url":"https://api.github.com/users/SteveStrong/gists{/gist_id}","starred_url":"https://api.github.com/users/SteveStrong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SteveStrong/subscriptions","organizations_url":"https://api.github.com/users/SteveStrong/orgs","repos_url":"https://api.github.com/users/SteveStrong/repos","events_url":"https://api.github.com/users/SteveStrong/events{/privacy}","received_events_url":"https://api.github.com/users/SteveStrong/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-12-15T20:47:42Z","updated_at":"2015-12-15T20:47:42Z","closed_at":null,"body":"    var airportDB = fo.db.getEntityDB('VaaS::airport');\r\n    fo.establishType('VaaS::airport', {\r\n        id: 1,\r\n        icon: 'images/entity/person.tsdb.png',\r\n\r\n        iataCode: '',\r\n        icaoCode: '',\r\n        faaCode: '',\r\n\r\n        departCount: function() {\r\n            return this.departKnownCount + this.departUnknownCount;\r\n        },\r\n        arrivalCount: function () {\r\n            return this.arrivalKnownCount + this.arrivalUnknownCount;\r\n        },\r\n        departKnownCount: function () {\r\n            return this.hasDepartures ? this.hasDepartures.memberCount() : 0;\r\n        },\r\n        arrivalKnownCount: function () {\r\n            return this.hasArrivals ? this.hasArrivals.memberCount() : 0;\r\n        },\r\n        departUnknownCount: function () {\r\n            return this.hasUnknownDepartures ? this.hasUnknownDepartures.memberCount() : 0;\r\n        },\r\n        arrivalUnknownCount: function () {\r\n            return this.hasUnknownArrivals ? this.hasUnknownArrivals.memberCount() : 0;\r\n        },\r\n        total: function () {\r\n            return this.departCount + this.arrivalCount;\r\n        }\r\n    }, fo.makeNode);\r\n\r\n    fo.establishRelationship('VaaS::departsAirport|VaaS::hasDepartures');\r\n    fo.establishRelationship('VaaS::arrivesAirport|VaaS::hasArrivals');"}}