From f791db88d83a7ed851b9412d9797ed16b345fe79 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期四, 07 七月 2022 18:39:18 +0800
Subject: [PATCH] 1.项目页面修改2.生产管理工单页面开发

---
 src/utils/global.js |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)

diff --git a/src/utils/global.js b/src/utils/global.js
index 044a6b0..6e641e8 100644
--- a/src/utils/global.js
+++ b/src/utils/global.js
@@ -1,3 +1,5 @@
+import { NewEncodingRules } from '@/api/xtsz'
+
 // 鍏ㄥ眬涓昏棰滆壊
 export function getGlobalColor() {
   return { globalColor: `#42b983` }
@@ -20,9 +22,17 @@
 }
 
 // 鏃堕棿澶勭悊鍑芥暟
-export function handleDatatime(value) {
+export function handleDatetime(value) {
   const data = new Date(value)
   const month = data.getMonth() < 9 ? '0' + (data.getMonth() + 1) : data.getMonth() + 1
   const date = data.getDate() <= 9 ? '0' + data.getDate() : data.getDate()
   return data.getFullYear() + '-' + month + '-' + date
 }
+
+// 鑾峰彇瑙勫垯鐢熸垚鐨勭紪鐮�
+export async function getNewEncodingRules(encode) {
+  const res = await NewEncodingRules({ rightcode: encode })
+  if (res.code === '200') {
+    return { RightCode: res.data[0], numvalue: res.data[1] }
+  }
+}

--
Gitblit v1.9.3