Revert "Work on selectable container elements."

This reverts commit b639d893c0.

Conflicts:
	src/Orchard.Web/Modules/Orchard.DynamicForms/Scripts/Forms.js
	src/Orchard.Web/Modules/Orchard.DynamicForms/Scripts/Forms.min.js
This commit is contained in:
Sipke Schoorstra 2015-09-02 13:12:11 +01:00
parent 748a354632
commit 3c3ece6404
5 changed files with 4 additions and 12 deletions

View File

@ -33,10 +33,6 @@
});
}
this.allowSealedFocus = function () {
return this.children.length === 0;
};
this.setChildren = function (children) {
this.children = children;
_(this.children).each(function (child) {

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
angular.module("LayoutEditor").directive("orcLayoutFieldset",["$compile","scopeConfigurator","environment",function(e,t,n){return{restrict:"E",scope:{element:"="},controller:["$scope","$element",function(e,n){t.configureForElement(e,n),t.configureForContainer(e,n),e.sortableOptions.axis="y",e.edit=function(){e.$root.editElement(e.element).then(function(t){t.cancel||e.$apply(function(){e.element.data=decodeURIComponent(t.element.data),e.element.applyElementEditorModel(t.elementEditorModel)})})}}],templateUrl:n.templateUrl("Fieldset"),replace:!0}}]),angular.module("LayoutEditor").directive("orcLayoutForm",["$compile","scopeConfigurator","environment",function(e,t,n){return{restrict:"E",scope:{element:"="},controller:["$scope","$element",function(e,n){t.configureForElement(e,n),t.configureForContainer(e,n),e.sortableOptions.axis="y",e.edit=function(){e.$root.editElement(e.element).then(function(t){t.cancel||e.$apply(function(){e.element.data=decodeURIComponent(t.element.data),e.element.applyElementEditorModel(t.elementEditorModel)})})}}],templateUrl:n.templateUrl("Form"),replace:!0}}]);var LayoutEditor;!function(e,t){t.Fieldset=function(n,i,o,r,l,d,a,c,s,h,m){t.Element.call(this,"Fieldset",n,i,o,r,l),t.Container.call(this,["Grid","Content"],m);var u=this;this.isContainable=!0,this.dropTargetClass="layout-common-holder",this.contentType=a,this.contentTypeLabel=c,this.contentTypeClass=s,this.legend=d||"",this.hasEditor=h,this.toObject=function(){var e=this.elementToObject();return e.legend=this.legend,e.children=this.childrenToObject(),e};var p=this.getEditorObject;this.getEditorObject=function(){var t=p();return e.extend(t,{Legend:this.legend})},this.setChildren=function(e){this.children=e,_(this.children).each(function(e){e.parent=u})},this.applyElementEditorModel=function(e){this.legend=e.legend},this.setChildren(m)},t.Fieldset.from=function(e){return new t.Fieldset(e.data,e.htmlId,e.htmlClass,e.htmlStyle,e.isTemplated,e.legend,e.contentType,e.contentTypeLabel,e.contentTypeClass,e.hasEditor,t.childrenFrom(e.children))},t.registerFactory("Fieldset",function(e){return t.Fieldset.from(e)})}(jQuery,LayoutEditor||(LayoutEditor={}));var LayoutEditor;!function(e,t){t.Form=function(n,i,o,r,l,d,a,c,s,h,m,u,p){t.Element.call(this,"Form",n,i,o,r,l,u),t.Container.call(this,["Grid","Content"],p);var f=this;this.isContainable=!0,this.dropTargetClass="layout-common-holder",this.contentType=c,this.contentTypeLabel=s,this.contentTypeClass=h,this.name=d||"Untitled",this.formBindingContentType=a,this.hasEditor=m,this.toObject=function(){var e=this.elementToObject();return e.name=this.name,e.formBindingContentType=this.formBindingContentType,e.children=this.childrenToObject(),e};var y=this.getEditorObject;this.getEditorObject=function(){var t=y();return e.extend(t,{FormName:this.name,FormBindingContentType:this.formBindingContentType})},this.allowSealedFocus=function(){return 0===this.children.length},this.setChildren=function(e){this.children=e,_(this.children).each(function(e){e.setParent(f)})},this.onDescendantAdded=function(t){var n=t.getEditorObject;t.getEditorObject=function(){var t=n();return e.extend(t,{FormBindingContentType:f.formBindingContentType})}},this.applyElementEditorModel=function(e){this.name=e.name,this.formBindingContentType=e.formBindingContentType},this.setChildren(p)},t.Form.from=function(e){return new t.Form(e.data,e.htmlId,e.htmlClass,e.htmlStyle,e.isTemplated,e.name,e.formBindingContentType,e.contentType,e.contentTypeLabel,e.contentTypeClass,e.hasEditor,e.rule,t.childrenFrom(e.children))},t.registerFactory("Form",function(e){return t.Form.from(e)})}(jQuery,LayoutEditor||(LayoutEditor={}));
angular.module("LayoutEditor").directive("orcLayoutFieldset",["$compile","scopeConfigurator","environment",function(e,t,n){return{restrict:"E",scope:{element:"="},controller:["$scope","$element",function(e,n){t.configureForElement(e,n),t.configureForContainer(e,n),e.sortableOptions.axis="y",e.edit=function(){e.$root.editElement(e.element).then(function(t){t.cancel||e.$apply(function(){e.element.data=decodeURIComponent(t.element.data),e.element.applyElementEditorModel(t.elementEditorModel)})})}}],templateUrl:n.templateUrl("Fieldset"),replace:!0}}]),angular.module("LayoutEditor").directive("orcLayoutForm",["$compile","scopeConfigurator","environment",function(e,t,n){return{restrict:"E",scope:{element:"="},controller:["$scope","$element",function(e,n){t.configureForElement(e,n),t.configureForContainer(e,n),e.sortableOptions.axis="y",e.edit=function(){e.$root.editElement(e.element).then(function(t){t.cancel||e.$apply(function(){e.element.data=decodeURIComponent(t.element.data),e.element.applyElementEditorModel(t.elementEditorModel)})})}}],templateUrl:n.templateUrl("Form"),replace:!0}}]);var LayoutEditor;!function(e,t){t.Fieldset=function(n,i,o,r,l,d,a,c,s,h,m){t.Element.call(this,"Fieldset",n,i,o,r,l),t.Container.call(this,["Grid","Content"],m);var u=this;this.isContainable=!0,this.dropTargetClass="layout-common-holder",this.contentType=a,this.contentTypeLabel=c,this.contentTypeClass=s,this.legend=d||"",this.hasEditor=h,this.toObject=function(){var e=this.elementToObject();return e.legend=this.legend,e.children=this.childrenToObject(),e};var p=this.getEditorObject;this.getEditorObject=function(){var t=p();return e.extend(t,{Legend:this.legend})},this.setChildren=function(e){this.children=e,_(this.children).each(function(e){e.parent=u})},this.applyElementEditorModel=function(e){this.legend=e.legend},this.setChildren(m)},t.Fieldset.from=function(e){return new t.Fieldset(e.data,e.htmlId,e.htmlClass,e.htmlStyle,e.isTemplated,e.legend,e.contentType,e.contentTypeLabel,e.contentTypeClass,e.hasEditor,t.childrenFrom(e.children))},t.registerFactory("Fieldset",function(e){return t.Fieldset.from(e)})}(jQuery,LayoutEditor||(LayoutEditor={}));var LayoutEditor;!function(e,t){t.Form=function(n,i,o,r,l,d,a,c,s,h,m,u,p){t.Element.call(this,"Form",n,i,o,r,l,u),t.Container.call(this,["Grid","Content"],p);var f=this;this.isContainable=!0,this.dropTargetClass="layout-common-holder",this.contentType=c,this.contentTypeLabel=s,this.contentTypeClass=h,this.name=d||"Untitled",this.formBindingContentType=a,this.hasEditor=m,this.toObject=function(){var e=this.elementToObject();return e.name=this.name,e.formBindingContentType=this.formBindingContentType,e.children=this.childrenToObject(),e};var y=this.getEditorObject;this.getEditorObject=function(){var t=y();return e.extend(t,{FormName:this.name,FormBindingContentType:this.formBindingContentType})},this.setChildren=function(e){this.children=e,_(this.children).each(function(e){e.setParent(f)})},this.onDescendantAdded=function(t){var n=t.getEditorObject;t.getEditorObject=function(){var t=n();return e.extend(t,{FormBindingContentType:f.formBindingContentType})}},this.applyElementEditorModel=function(e){this.name=e.name,this.formBindingContentType=e.formBindingContentType},this.setChildren(p)},t.Form.from=function(e){return new t.Form(e.data,e.htmlId,e.htmlClass,e.htmlStyle,e.isTemplated,e.name,e.formBindingContentType,e.contentType,e.contentTypeLabel,e.contentTypeClass,e.hasEditor,e.rule,t.childrenFrom(e.children))},t.registerFactory("Form",function(e){return t.Form.from(e)})}(jQuery,LayoutEditor||(LayoutEditor={}));

View File

@ -15,7 +15,7 @@
this.allowSealedFocus = function() {
return this.children.length === 0;
};
}
};
LayoutEditor.Canvas.from = function (value) {

View File

@ -13,7 +13,7 @@
this.allowSealedFocus = function () {
return this.children.length === 0;
};
}
this.beginChange = function () {
if (!!_hasPendingChange)