From dc6af48efaca226c01ae07308edff1e46d81f2cc Mon Sep 17 00:00:00 2001 From: lion <120344285@qq.com> Date: Tue, 11 Nov 2025 16:47:42 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=87=E7=AD=BE=E6=89=93=E5=8D=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/print/index.js | 22 + src/router/index.js | 7 +- src/views/myprint/index copy.vue | 422 +++++++++++++++++++ src/views/myprint/index.vue | 534 ++++++++++++++++++++++++ src/views/stocks/component/showRuku.vue | 3 +- src/views/stocks/index.vue | 38 +- vue.config.js | 7 + 7 files changed, 1011 insertions(+), 22 deletions(-) create mode 100644 src/api/print/index.js create mode 100644 src/views/myprint/index copy.vue create mode 100644 src/views/myprint/index.vue diff --git a/src/api/print/index.js b/src/api/print/index.js new file mode 100644 index 0000000..792c148 --- /dev/null +++ b/src/api/print/index.js @@ -0,0 +1,22 @@ +import request from '@/utils/request' + +function generateUniqueId() { + const timestamp = Date.now().toString(36); // 使用36进制,避免出现数字开头的问题 + const randomNum = Math.random().toString(36).substr(2, 9); // 获取随机数的36进制表示,并截取后9位 + return timestamp + randomNum; +} + +export function sendPostRequestApi(funcId, funcName, data) { + const params = JSON.stringify({ + version: "1.0", + seqNo: generateUniqueId(), + funcName: funcId, + inParams: data, + }); + console.log(params) + return request({ + url: 'http://127.0.0.1:9001/', + method: 'post', + data: params + }) +} diff --git a/src/router/index.js b/src/router/index.js index 7ca8a66..d34a188 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -40,12 +40,17 @@ export const constantRoutes = [{ path: '/404', component: () => import('@/views/404'), hidden: true -}, +}, { path: '/leader', component: () => import('@/views/jsc/leader'), hidden: true }, +{ + path: '/myprint', + component: () => import('@/views/myprint/index'), + hidden: true +}, { path: '/stocks', component: () => import('@/views/stocks/index'), diff --git a/src/views/myprint/index copy.vue b/src/views/myprint/index copy.vue new file mode 100644 index 0000000..6baf915 --- /dev/null +++ b/src/views/myprint/index copy.vue @@ -0,0 +1,422 @@ + + + + + \ No newline at end of file diff --git a/src/views/myprint/index.vue b/src/views/myprint/index.vue new file mode 100644 index 0000000..b66d97c --- /dev/null +++ b/src/views/myprint/index.vue @@ -0,0 +1,534 @@ + + + + + \ No newline at end of file diff --git a/src/views/stocks/component/showRuku.vue b/src/views/stocks/component/showRuku.vue index 513af73..2ce510d 100644 --- a/src/views/stocks/component/showRuku.vue +++ b/src/views/stocks/component/showRuku.vue @@ -37,10 +37,9 @@