Преглед изворни кода

工作内容项目特征等列只读

zhongzewei пре 7 година
родитељ
комит
831f7c68b5

Разлика између датотеке није приказан због своје велике величине
+ 0 - 1
public/web/PerfectLoad.js


+ 2 - 3
public/web/sheet/sheet_common.js

@@ -393,7 +393,7 @@ var sheetCommonObj = {
         }
         sheet.resumePaint();
     },
-    //设置系统粘贴板数据,需要用户触发时间,直接调用会失败
+    //设置系统粘贴板数据,需要用户触发事件,直接调用会失败
     copyTextToClipboard: function(text) {
         var textArea = document.createElement("textarea");
         textArea.style.position = 'fixed';
@@ -419,8 +419,7 @@ var sheetCommonObj = {
         document.body.removeChild(textArea);
     },
     //获取选中区域的表格类型数据(可粘贴到excel)
-    getTableData: function (sheet, colSettings) {
-        console.log(colSettings);
+    getTableData: function (sheet, colSettings = null) {
         let rst = '';
         let sel = sheet.getSelections()[0];
         let vRows = [];

+ 12 - 0
web/building_saas/main/js/views/main_tree_col.js

@@ -185,6 +185,18 @@ let MainTreeCol = {
             }else {
                return calcTools.isRationItem(node);
             }
+        },
+        forContentCharacter: function (node) {
+            return !MainTreeCol.readOnly.bills(node) || (node.data.type !== billType.BILL && node.data.type !== billType.FX);
+        },
+        forRuleText: function (node) {
+            if(MainTreeCol.readOnly.bills(node)){
+                if(node.data.type === billType.FX || (node.data.type === billType.BILL && node.source.children.length === 0)){
+                    console.log('enter');
+                    return false;
+                }
+            }
+            return true;
         }
     },
     cellType: {