From 3e280975ba21c9b311f3538788c220bdd70e16bc Mon Sep 17 00:00:00 2001
From: WXL <wl_5969728@163.com>
Date: 星期四, 04 六月 2026 10:31:20 +0800
Subject: [PATCH] 青岛维护
---
.env.staging | 2
.env.development | 2
/dev/null | 0
src/views/login.vue | 10 +++-
vue.config.js | 6 +-
src/layout/components/Sidebar/Logo.vue | 2
src/utils/crypto.js | 39 +++++++++++++++++++
管理端.zip | 0
package.json | 1
.env.production | 2
10 files changed, 54 insertions(+), 10 deletions(-)
diff --git a/.env.development b/.env.development
index 7cdd0ab..7da0737 100644
--- a/.env.development
+++ b/.env.development
@@ -1,5 +1,5 @@
# 椤甸潰鏍囬
-VUE_APP_TITLE = 闈掗檮闄PO绠$悊骞冲彴
+VUE_APP_TITLE = 闈掑ぇ闄勯櫌OPO绠$悊骞冲彴
# 寮�鍙戠幆澧冮厤缃�
ENV = 'development'
diff --git a/.env.production b/.env.production
index 7531d06..d64d2b6 100644
--- a/.env.production
+++ b/.env.production
@@ -1,5 +1,5 @@
# 椤甸潰鏍囬
-VUE_APP_TITLE = 闈掗檮闄PO绠$悊骞冲彴
+VUE_APP_TITLE = 闈掑ぇ闄勯櫌OPO绠$悊骞冲彴
# 鐢熶骇鐜閰嶇疆
ENV = 'production'
diff --git a/.env.staging b/.env.staging
index 61907f6..d6bb9b7 100644
--- a/.env.staging
+++ b/.env.staging
@@ -1,5 +1,5 @@
# 椤甸潰鏍囬
-VUE_APP_TITLE = 闈掗檮闄PO绠$悊骞冲彴
+VUE_APP_TITLE = 闈掑ぇ闄勯櫌OPO绠$悊骞冲彴
NODE_ENV = production
diff --git a/package.json b/package.json
index 3dee21b..3a6956f 100644
--- a/package.json
+++ b/package.json
@@ -42,6 +42,7 @@
"build": "^0.1.4",
"clipboard": "2.0.6",
"core-js": "3.8.1",
+ "crypto-js": "^4.2.0",
"dayjs": "^1.11.1",
"dingtalk-jsapi": "^3.1.1",
"echarts": "^4.9.0",
diff --git a/src/layout/components/Sidebar/Logo.vue b/src/layout/components/Sidebar/Logo.vue
index 7aba6a7..f811622 100644
--- a/src/layout/components/Sidebar/Logo.vue
+++ b/src/layout/components/Sidebar/Logo.vue
@@ -36,7 +36,7 @@
},
data() {
return {
- title: '闈掗檮闄PO绠$悊骞冲彴',
+ title: '闈掑ぇ闄勯櫌OPO绠$悊骞冲彴',
logo: logoImg
}
}
diff --git a/src/utils/crypto.js b/src/utils/crypto.js
new file mode 100644
index 0000000..7f6474b
--- /dev/null
+++ b/src/utils/crypto.js
@@ -0,0 +1,39 @@
+// utils/crypto.js
+import CryptoJS from "crypto-js";
+
+// 鉁� 瀵嗛挜锛堝墠鍚庣蹇呴』涓�鑷达級
+const SECRET_KEY = "QfOpO2026@SecretKey#Aes256!00001";
+const IV = "1234567890123456"; // 16浣�
+console.log(SECRET_KEY);
+
+/**
+ * AES 鍔犲瘑
+ */
+export function encrypts(text) {
+ const key = CryptoJS.enc.Utf8.parse(SECRET_KEY);
+ const iv = CryptoJS.enc.Utf8.parse(IV);
+
+ const encrypted = CryptoJS.AES.encrypt(text, key, {
+ iv,
+ mode: CryptoJS.mode.CBC,
+ padding: CryptoJS.pad.Pkcs7,
+ });
+
+ return encrypted.toString(); // Base64
+}
+
+/**
+ * AES 瑙e瘑锛堝彲閫夛紝鐢ㄤ簬璋冭瘯锛�
+ */
+export function decrypt(cipherText) {
+ const key = CryptoJS.enc.Utf8.parse(SECRET_KEY);
+ const iv = CryptoJS.enc.Utf8.parse(IV);
+
+ const decrypted = CryptoJS.AES.decrypt(cipherText, key, {
+ iv,
+ mode: CryptoJS.mode.CBC,
+ padding: CryptoJS.pad.Pkcs7,
+ });
+
+ return decrypted.toString(CryptoJS.enc.Utf8);
+}
diff --git a/src/views/login.vue b/src/views/login.vue
index 0f6a635..61b37c0 100644
--- a/src/views/login.vue
+++ b/src/views/login.vue
@@ -90,7 +90,7 @@
import { getCodeImg } from "@/api/login";
import Cookies from "js-cookie";
import { encrypt, decrypt } from "@/utils/jsencrypt";
-
+import { encrypts } from "@/utils/crypto";
export default {
name: "Login",
data() {
@@ -139,7 +139,7 @@
this.getCode();
this.getCookie();
this.getAuthCode();
- this.loginForm.password='';
+ this.loginForm.password = "";
// this.loginForm.password=this.generatePassword();
// this.avoidLogin();
},
@@ -240,8 +240,12 @@
Cookies.remove("password");
Cookies.remove("rememberMe");
}
+ let loginobj = { username: null, password: null };
+ loginobj.username = encrypts(this.loginForm.username);
+ loginobj.password = encrypts(this.loginForm.password);
+
this.$store
- .dispatch("Login", this.loginForm)
+ .dispatch("Login", loginobj)
.then(res => {
console.log(this.$store.state.user.code, "44");
console.log(this.$store.state.user.msg, "22");
diff --git a/vue.config.js b/vue.config.js
index cb37af7..e5f4f33 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -5,7 +5,7 @@
return path.join(__dirname, dir);
}
-const name = process.env.VUE_APP_TITLE || "闈掗檮闄PO绠$悊骞冲彴"; // 缃戦〉鏍囬
+const name = process.env.VUE_APP_TITLE || "闈掑ぇ闄勯櫌OPO绠$悊骞冲彴"; // 缃戦〉鏍囬
const port = process.env.port || process.env.npm_config_port || 80; // 绔彛
@@ -33,9 +33,9 @@
proxy: {
// detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: {
- target: `http://www.qdopo.com:9095`,
+ // target: `http://www.qdopo.com:9095`,
// target:`http://192.168.76.25:9095`,//鎵撳寘鍦板潃
- // target:`http://192.168.100.10:8080`,
+ target:`http://192.168.100.10:8080`,
// target:`http://192.168.100.137:8080`,
// target: `https://slb.hospitalstar.com:9093`,
changeOrigin: true,
diff --git "a/\347\256\241\347\220\206\347\253\257 \0502\051.zip" "b/\347\256\241\347\220\206\347\253\257 \0502\051.zip"
deleted file mode 100644
index 9da13ee..0000000
--- "a/\347\256\241\347\220\206\347\253\257 \0502\051.zip"
+++ /dev/null
Binary files differ
diff --git "a/\347\256\241\347\220\206\347\253\257 \0503\051.zip" "b/\347\256\241\347\220\206\347\253\257 \0503\051.zip"
deleted file mode 100644
index 75284fb..0000000
--- "a/\347\256\241\347\220\206\347\253\257 \0503\051.zip"
+++ /dev/null
Binary files differ
diff --git "a/\347\256\241\347\220\206\347\253\257.zip" "b/\347\256\241\347\220\206\347\253\257.zip"
index 22d1d2b..f9206e4 100644
--- "a/\347\256\241\347\220\206\347\253\257.zip"
+++ "b/\347\256\241\347\220\206\347\253\257.zip"
Binary files differ
--
Gitblit v1.9.3