Merge pull request #1448 from nasa/update-composition-policy

Update composition policy
This commit is contained in:
Andrew Henry
2017-02-21 17:18:59 -08:00
committed by GitHub
23 changed files with 175 additions and 538 deletions

View File

@ -56,16 +56,16 @@ define(
*/
CreateWizard.prototype.getFormStructure = function (includeLocation) {
var sections = [],
type = this.type,
domainObject = this.domainObject,
policyService = this.policyService;
function validateLocation(locatingObject) {
var locatingType = locatingObject &&
locatingObject.getCapability('type');
return locatingType && policyService.allow(
function validateLocation(parent) {
var parentType = parent &&
parent.getCapability('type');
return parentType && policyService.allow(
"composition",
locatingType,
type
parentType,
domainObject
);
}