From a1d7e81859f554f3a53680cc35f0f49bf1f77098 Mon Sep 17 00:00:00 2001
From: wwf <1971391498@qq.com>
Date: 星期四, 14 五月 2026 14:37:02 +0800
Subject: [PATCH] 导入项目

---
 src/api/infra/config/index.ts |   53 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 53 insertions(+), 0 deletions(-)

diff --git a/src/api/infra/config/index.ts b/src/api/infra/config/index.ts
new file mode 100644
index 0000000..c78c2c0
--- /dev/null
+++ b/src/api/infra/config/index.ts
@@ -0,0 +1,53 @@
+import request from '@/config/axios'
+
+export interface ConfigVO {
+  id: number | undefined
+  category: string
+  name: string
+  key: string
+  value: string
+  type: number
+  visible: boolean
+  remark: string
+  createTime: Date
+}
+
+// 鏌ヨ鍙傛暟鍒楄〃
+export const getConfigPage = (params: PageParam) => {
+  return request.get({ url: '/infra/config/page', params })
+}
+
+// 鏌ヨ鍙傛暟璇︽儏
+export const getConfig = (id: number) => {
+  return request.get({ url: '/infra/config/get?id=' + id })
+}
+
+// 鏍规嵁鍙傛暟閿悕鏌ヨ鍙傛暟鍊�
+export const getConfigKey = (configKey: string) => {
+  return request.get({ url: '/infra/config/get-value-by-key?key=' + configKey })
+}
+
+// 鏂板鍙傛暟
+export const createConfig = (data: ConfigVO) => {
+  return request.post({ url: '/infra/config/create', data })
+}
+
+// 淇敼鍙傛暟
+export const updateConfig = (data: ConfigVO) => {
+  return request.put({ url: '/infra/config/update', data })
+}
+
+// 鍒犻櫎鍙傛暟
+export const deleteConfig = (id: number) => {
+  return request.delete({ url: '/infra/config/delete?id=' + id })
+}
+
+// 鎵归噺鍒犻櫎鍙傛暟
+export const deleteConfigList = (ids: number[]) => {
+  return request.delete({ url: '/infra/config/delete-list', params: { ids: ids.join(',') } })
+}
+
+// 瀵煎嚭鍙傛暟
+export const exportConfig = (params) => {
+  return request.download({ url: '/infra/config/export-excel', params })
+}

--
Gitblit v1.8.0