提交 a04dfe0a 编写于 作者: U unknown

人员选择增加disable方法

上级 176c91d7
......@@ -1703,6 +1703,14 @@ MWF.xApplication.Selector.Person.Item = new Class({
}
},
loadSubItem: function(){},
disable : function(){
this.node.hide();
this.disabled = true;
},
enable : function(){
this.node.show();
this.disabled = false;
},
check: function(){
//if (this.selector.options.count.toInt()===1){
// this.checkSelectedSingle();
......@@ -2365,7 +2373,7 @@ MWF.xApplication.Selector.Person.ItemCategory = new Class({
if ((count.toInt()===0) || (this.selector.selectedItems.length+(this.subItems.length-selectedSubItemCount))<=count){
var checkedCount = 0;
this.subItems.each( function(item){
if(!item.isSelected)item.selected( false, function () {
if(!item.isSelected && !item.disabled )item.selected( false, function () {
checkedCount++;
if( this.subItems.length === checkedCount ){
if( checkValid )this.selector.fireEvent("valid", [this.selector, this]);
......
......@@ -396,7 +396,7 @@ MWF.xApplication.Selector.Unit.Item = new Class({
this.selectAll(ev, checkValid);
if( this.subCategorys && this.subCategorys.length ){
this.subCategorys.each( function( category ){
if(category.selectAllNested)category.selectAllNestedev, checkValid()
if(category.selectAllNested)category.selectAllNested, checkValid()
})
}
if( this.subItems && this.subItems.length ){
......@@ -427,7 +427,7 @@ MWF.xApplication.Selector.Unit.Item = new Class({
if ((count.toInt()===0) || (this.selector.selectedItems.length+(this.subItems.length-selectedSubItemCount))<=count){
var checkedCount = 0;
this.subItems.each( function(item){
if(!item.isSelected)item.selected(false, function () {
if(!item.isSelected && !item.disabled )item.selected(false, function () {
checkedCount++;
if( this.subItems.length === checkedCount ){
if( checkValid )this.selector.fireEvent("valid", [this.selector, this]);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册