From bfdfeb40c7ba97511584a30477acf5ad801398ba Mon Sep 17 00:00:00 2001
From: YangYuGang <1378265336@qq.com>
Date: 星期二, 11 三月 2025 11:26:34 +0800
Subject: [PATCH] 一些更改

---
 src/views/demo/feat/print/index.vue |   61 +++++++++++++-----------------
 1 files changed, 26 insertions(+), 35 deletions(-)

diff --git a/src/views/demo/feat/print/index.vue b/src/views/demo/feat/print/index.vue
index 556a3b7..7fab279 100644
--- a/src/views/demo/feat/print/index.vue
+++ b/src/views/demo/feat/print/index.vue
@@ -7,43 +7,34 @@
     <a-button type="primary" class="mt-5" @click="imagePrint">Image Print</a-button>
   </PageWrapper>
 </template>
-<script lang="ts">
-  import { defineComponent } from 'vue';
-  import { PageWrapper } from '/@/components/Page';
-  import { CollapseContainer } from '/@/components/Container/index';
+<script lang="ts" setup>
+  import { PageWrapper } from '@/components/Page';
+  import { CollapseContainer } from '@/components/Container';
 
   import printJS from 'print-js';
 
-  export default defineComponent({
-    name: 'AppLogo',
-    components: { PageWrapper, CollapseContainer },
-    setup() {
-      function jsonPrint() {
-        printJS({
-          printable: [
-            { name: 'll', email: '123@gmail.com', phone: '123' },
-            { name: 'qq', email: '456@gmail.com', phone: '456' },
-          ],
-          properties: ['name', 'email', 'phone'],
-          type: 'json',
-        });
-      }
+  defineOptions({ name: 'AppLogo' });
 
-      function imagePrint() {
-        printJS({
-          printable: [
-            'https://anncwb.github.io/anncwb/images/preview1.png',
-            'https://anncwb.github.io/anncwb/images/preview2.png',
-          ],
-          type: 'image',
-          header: 'Multiple Images',
-          imageStyle: 'width:100%;',
-        });
-      }
-      return {
-        jsonPrint,
-        imagePrint,
-      };
-    },
-  });
+  function jsonPrint() {
+    printJS({
+      printable: [
+        { name: 'll', email: '123@gmail.com', phone: '123' },
+        { name: 'qq', email: '456@gmail.com', phone: '456' },
+      ],
+      properties: ['name', 'email', 'phone'],
+      type: 'json',
+    });
+  }
+
+  function imagePrint() {
+    printJS({
+      printable: [
+        'https://anncwb.github.io/anncwb/images/preview1.png',
+        'https://anncwb.github.io/anncwb/images/preview2.png',
+      ],
+      type: 'image',
+      header: 'Multiple Images',
+      imageStyle: 'width:100%;',
+    });
+  }
 </script>

--
Gitblit v1.9.3