Explorar el Código

文件默认标题

liuhh hace 2 años
padre
commit
b2f2820c6b

+ 3 - 3
src/pages/main/departWorkLists/index.vue

@@ -245,7 +245,7 @@
     </div>
 </template>
 <script>
-import simpleSheet from "./sheet1.vue";
+import simpleSheet from "./sheet.vue";
 export default {
     components: {
         simpleSheet
@@ -742,7 +742,7 @@ export default {
         }
 
         .inner-left {
-            width: 25%;
+            width: 20%;
             padding: 0 20px;
             border: 1px solid #ddd;
             border-radius: 5px;
@@ -756,7 +756,7 @@ export default {
         }
 
         .inner-right {
-            width: 73%;
+            width: 80%;
             margin-left: 2%;
             overflow-y: auto;
             //   border-left: 1px solid #ddd;

+ 13 - 22
src/pages/main/departWorkLists/sheet1.vue

@@ -242,7 +242,8 @@ export default {
                     container: "luckysheet",
                     lang: "zh",
                     showsheetbar: false,
-                    userInfo:undefined
+                    userInfo:undefined,
+                    title:"请输入标题"
                 })
             }
             switch (type) {
@@ -298,17 +299,17 @@ export default {
                                             return false;
                                         }
                                     },
-                                    cellRenderAfter: function (cell, position) {
-                                        const { r: row, c: column } = position;
-                                        console.log();
-                                        if (cell) {
-                                            if (!that.handleAllow({ row, column })) {
-                                                cell.bg = "#d5d5d5";
-                                            } else {
-                                                cell.bg = "#ffffff";
-                                            }
-                                        }
-                                    },
+                                    // cellRenderAfter: function (cell, position) {
+                                    //     const { r: row, c: column } = position;
+                                    //     console.log();
+                                    //     // if (cell) {
+                                    //     //     if (!that.handleAllow({ row, column })) {
+                                    //     //         cell.bg = "#d5d5d5";
+                                    //     //     } else {
+                                    //     //         cell.bg = "#ffffff";
+                                    //     //     }
+                                    //     // }
+                                    // },
                                     rangePasteBefore: function ([
                                                                     { row_focus: row, column_focus: column },
                                                                 ]) {
@@ -383,17 +384,7 @@ export default {
             return arr.join(",");
         },
         handleFullscreen() {
-            const sheet_name = window.luckysheet.getSheet().name;
-            const data = window.luckysheet.getSheet(sheet_name);
-            const workbook_name = window.luckysheet.getWorkbookName();
             this.fullscreen = !this.fullscreen
-            this.$nextTick(()=>{
-                this.handleCreate({
-                    json: data,
-                    name: workbook_name,
-                    type: "json",
-                });
-            })
             //   const element = document.getElementById("full-container");
             // const is_fullscreen =
             //   document.fullScreen ||