瀏覽代碼

反审核字段全部变成可编辑问题处理

rainco 7 年之前
父節點
當前提交
a6ba1f620e
共有 1 個文件被更改,包括 5 次插入1 次删除
  1. 5 1
      frontend/saas-web/app/view/core/form/FormPanel.js

+ 5 - 1
frontend/saas-web/app/view/core/form/FormPanel.js

@@ -379,6 +379,10 @@ Ext.define('saas.view.core.form.FormPanel', {
                 return;
                 return;
             }
             }
 
 
+            if(item.readOnly){
+                item.defaultReadOnly = item.readOnly;
+            }
+
             if (bind) {
             if (bind) {
                 if (!Ext.isString(bind)) {
                 if (!Ext.isString(bind)) {
                     Ext.apply(bind, {
                     Ext.apply(bind, {
@@ -433,7 +437,7 @@ Ext.define('saas.view.core.form.FormPanel', {
 
 
         Ext.Array.each(items, function(item) {
         Ext.Array.each(items, function(item) {
             if(typeof item.setReadOnly  == 'function') {
             if(typeof item.setReadOnly  == 'function') {
-               item.setReadOnly (item.readOnly || !able);
+               item.setReadOnly (item.defaultReadOnly || !able);
             }
             }
         });
         });
     },
     },