Browse Source

Merge branch 'fix/Selector.select_single_item' into 'wrdp'

Merge of fix/Selector.select_single_item 修复人员选择待选项唯一默认选中可能出现的问题 to wrdp

See merge request o2oa/o2oa!1808
蔡祥熠 5 years ago
parent
commit
22e2b6ddc2
1 changed files with 2 additions and 1 deletions
  1. 2 1
      o2web/source/x_component_Selector/Person.js

+ 2 - 1
o2web/source/x_component_Selector/Person.js

@@ -1471,7 +1471,8 @@ MWF.xApplication.Selector.Person = new Class({
                     if( !category.subItems[0].isSelected )category.subItems[0].clickItem();
                 }
             }else if(category.subCategorys.length === 1){
-                if( !category.subCategorys[0]._hasChild || !category.subCategorys[0]._hasChild() ){ //category.subCategorys[0].isItem &&
+                if( category.subItems && category.subItems.length > 0 ){
+                }else if( !category.subCategorys[0]._hasChild || !category.subCategorys[0]._hasChild() ){ //category.subCategorys[0].isItem &&
                     if( !category.subItems[0].isSelected )category.subItems[0].clickItem();
                 }else{
                     checkCategory( category.subCategorys[0] )