李林
2024-03-13 eb2f43c595f6e0602c74ba8516b6324ffcab3e59
src/components/tool/excel.vue
@@ -33,10 +33,11 @@
</template>
<script>
// import { data } from 'jquery';
   export default {
      props: ['data','title'],
      data() {
         return {
            data: {}
         }
      },
      mounted() {
@@ -46,11 +47,16 @@
      },
      methods: {
         templateWrite() {
            if(this.data!=null&&this.data!=''){
               let option = JSON.parse(this.data)
               option.title = this.title
               luckysheet.create(option)
            }else{
            $(function() {
               //配置项
               var options = {
                  container: 'luckysheet',
                  title: "模板编制",
                     title: this.title,
                  lang: "zh",
                  showsheetbar: false,
                  showstatisticBarConfig: {
@@ -62,6 +68,7 @@
                  }],
                  enableAddRow: false,
                  row: 100,
                     column: 26,
                  enableAddBackTop: false,
                  showtoolbarConfig: {
                     chart: false, // '图表'
@@ -86,4 +93,5 @@
         }
      }
   }
   }
</script>