Просмотр исходного кода

Merge branch 'fix/O2Duty_execption' into 'wrdp'

Merge of fix/O2Duty_execption 修复o2.widget.O2Duty报错的问题  to wrdp

See merge request o2oa/o2oa!2741
蔡祥熠 5 лет назад
Родитель
Сommit
57d476f05e
1 измененных файлов с 21 добавлено и 19 удалено
  1. 21 19
      o2web/source/o2_core/o2/widget/O2Identity.js

+ 21 - 19
o2web/source/o2_core/o2/widget/O2Identity.js

@@ -282,27 +282,29 @@ o2.widget.O2Unit = new Class({
 o2.widget.O2Duty = new Class({
     Extends: o2.widget.O2Identity,
     getPersonData: function(){
-        if (!this.data.woUnit){
-            this.action.actions = {"getUnitduty": {"uri": "/jaxrs/unitduty/{id}"}};
-            this.action.invoke({"name": "getUnitduty", "async": false, "parameter": {"id": (this.data.id || this.data.name)}, "success": function(json){
-                this.data = json.data;
-            }.bind(this)});
-        }
+        return this.data;
+        // if (!this.data.woUnit){
+        //     this.action.actions = {"getUnitduty": {"uri": "/jaxrs/unitduty/{id}"}};
+        //     this.action.invoke({"name": "getUnitduty", "async": false, "parameter": {"id": (this.data.id || this.data.name)}, "success": function(json){
+        //         this.data = json.data;
+        //     }.bind(this)});
+        // }
     },
     createInforNode: function(){
-        this.inforNode = new Element("div", {
-            "styles": this.style.identityInforNode
-        });
-        var nameNode = new Element("div", {
-            "styles": this.style.identityInforNameNode,
-            "text": this.data.woUnit.levelName
-        }).inject(this.inforNode);
-        this.tooltip = new mBox.Tooltip({
-            content: this.inforNode,
-            setStyles: {content: {padding: 15, lineHeight: 20}},
-            attach: this.node,
-            transition: 'flyin'
-        });
+        return false;
+        // this.inforNode = new Element("div", {
+        //     "styles": this.style.identityInforNode
+        // });
+        // var nameNode = new Element("div", {
+        //     "styles": this.style.identityInforNameNode,
+        //     "text": this.data.woUnit.levelName
+        // }).inject(this.inforNode);
+        // this.tooltip = new mBox.Tooltip({
+        //     content: this.inforNode,
+        //     setStyles: {content: {padding: 15, lineHeight: 20}},
+        //     attach: this.node,
+        //     transition: 'flyin'
+        // });
     },
     setText: function(){
         this.node.set("text", this.data.displayName || this.data.name);