diff --git a/public/iconify/system.json b/public/iconify/system.json
new file mode 100644
index 0000000..882dbcd
--- /dev/null
+++ b/public/iconify/system.json
@@ -0,0 +1,16 @@
+{
+ "prefix": "system",
+ "lastModified": 1716123717,
+ "aliases": {},
+ "width": 32,
+ "height": 32,
+ "icons": {
+ "config": {
+ "body": ""
+ },
+ "parameter": {
+ "body": ""
+ }
+
+ }
+}
diff --git a/src/constants/business.ts b/src/constants/business.ts
index 28aa7a5..8eb62ae 100644
--- a/src/constants/business.ts
+++ b/src/constants/business.ts
@@ -289,6 +289,12 @@ export const retryOperationReasonRecord: Record = {
+ 1: 'common.variableType.variableType1',
+ 2: 'common.variableType.variableType2'
+};
+export const systemVariableTypeOptions = transformRecordToNumberOption(systemVariableTypeRecord);
+
export const jobOperationReasonEnum: Workflow.JobTagType = {
0: {
name: operationReasonRecord[0],
diff --git a/src/locales/langs/zh-cn.ts b/src/locales/langs/zh-cn.ts
index faf53dd..01d6294 100644
--- a/src/locales/langs/zh-cn.ts
+++ b/src/locales/langs/zh-cn.ts
@@ -144,6 +144,10 @@ const local: App.I18n.Schema = {
python: 'Python'
}
},
+ variableType:{
+ variableType1: '字符变量',
+ variableType2: '表达式变量'
+ },
taskType: {
label: '任务类型',
form: '请选择任务类型',
@@ -390,7 +394,9 @@ const local: App.I18n.Schema = {
workflow_form_add: '新增工作流',
job: '定时任务',
job_task: '任务管理',
- job_batch: '执行批次'
+ job_batch: '执行批次',
+ system: '系统参数',
+ system_variable: '参数管理'
},
page: {
common: {
@@ -951,6 +957,29 @@ const local: App.I18n.Schema = {
admin: '管理员'
}
},
+ system_variable: {
+ title: '系统参数',
+ variableKey: '变量标识',
+ variableName: '变量名称',
+ variableValue: '变量值',
+ variableType: '变量类型',
+ description:'变量描述',
+ detail: '变量详情',
+ add: '新增',
+ edit: '编辑',
+ addVariable: '新增变量',
+ editVariable: '编辑变量',
+ variableType1: '字符变量',
+ variableType2: '表达式变量',
+
+ form: {
+ variableName: '请输入变量名称',
+ variableKey: '请输入变量标识',
+ variableValue: '请输入变量值',
+ variableType: '请选择变量类型',
+ description: '请输入描述',
+ }
+ },
log: {
title: '日志详情',
view: '查看日志',
diff --git a/src/router/elegant/imports.ts b/src/router/elegant/imports.ts
index d662622..288b1e5 100644
--- a/src/router/elegant/imports.ts
+++ b/src/router/elegant/imports.ts
@@ -34,6 +34,7 @@ export const views: Record Promise import("@/views/retry/info/index.vue"),
retry_scene: () => import("@/views/retry/scene/index.vue"),
retry_task: () => import("@/views/retry/task/index.vue"),
+ system_manager: () => import("@/views/system/manager/index.vue"),
user_manager: () => import("@/views/user/manager/index.vue"),
workflow_batch: () => import("@/views/workflow/batch/index.vue"),
workflow_form_add: () => import("@/views/workflow/form/add/index.vue"),
diff --git a/src/router/elegant/routes.ts b/src/router/elegant/routes.ts
index 1741143..4015790 100644
--- a/src/router/elegant/routes.ts
+++ b/src/router/elegant/routes.ts
@@ -268,6 +268,26 @@ export const generatedRoutes: GeneratedRoute[] = [
}
]
},
+ {
+ name: 'system',
+ path: '/system',
+ component: 'layout.base',
+ meta: {
+ title: 'system',
+ i18nKey: 'route.system'
+ },
+ children: [
+ {
+ name: 'system_manager',
+ path: '/system/manager',
+ component: 'view.system_manager',
+ meta: {
+ title: 'system_manager',
+ i18nKey: 'route.system_manager'
+ }
+ }
+ ]
+ },
{
name: 'user',
path: '/user',
diff --git a/src/service/api/system-variable.ts b/src/service/api/system-variable.ts
new file mode 100644
index 0000000..2a68b5c
--- /dev/null
+++ b/src/service/api/system-variable.ts
@@ -0,0 +1,51 @@
+import { request } from '../request';
+
+export function fetchGetSystemVarPageList(params?: Api.SystemVariable.SystemVariableSearchParams) {
+ return request({
+ url: '/system-variable/page/list',
+ method: 'get',
+ params
+ });
+}
+export function fetchGetSystemVarList() {
+ return request({
+ url: '/system-variable/list',
+ method: 'get'
+ });
+}
+
+/** add Variable */
+export function fetchAddVariable(data: Api.SystemVariable.SystemVariable) {
+ return request({
+ url: '/system-variable',
+ method: 'post',
+ data
+ });
+}
+
+/** edit Variable */
+export function fetchEditVariable(data: Api.SystemVariable.SystemVariable) {
+ return request({
+ url: '/system-variable',
+ method: 'put',
+ data
+ });
+}
+
+
+/** delete Variable */
+export function fetchDelVariable(id: number) {
+ return request({
+ url: `/system-variable/${id}`,
+ method: 'delete'
+ });
+}
+
+/** batch delete Variable */
+export function fetchBatchDelteVariable(data: string[]) {
+ return request({
+ url: `/system-variable/ids`,
+ method: 'delete',
+ data
+ });
+}
diff --git a/src/typings/api.d.ts b/src/typings/api.d.ts
index e91ea86..c7c00bb 100644
--- a/src/typings/api.d.ts
+++ b/src/typings/api.d.ts
@@ -381,7 +381,7 @@ declare namespace Api {
type GroupStatusType = 0 | 1;
type YesOrNoType = 0 | 1;
-
+ type VariableType = 1 | 2;
/** groupConfig */
type GroupConfig = Common.CommonRecord<{
/** 命名空间id */
@@ -1361,4 +1361,30 @@ declare namespace Api {
throwable: string;
};
}
+
+ namespace SystemVariable {
+ type VariableType = 1 | 2;
+
+ type CommonSearchParams = Pick;
+ type SystemVariable = Common.CommonRecord<{
+ /** 显示名:当前时间 */
+ variableName: string;
+ /** key:${date} */
+ variableKey: string;
+ /** value: yyyyMMdd */
+ variableValue: string;
+ /** 变量类型 1-字符串变量 2-表达式变量 */
+ variableType: string;
+ /** 描述 */
+ description: string;
+ }>;
+
+ /**搜索参数*/
+ type SystemVariableSearchParams = CommonType.RecordNullable<
+ Pick &
+ CommonSearchParams
+ >;
+
+ type SystemVariableList = Common.PaginatingQueryRecord;
+ }
}
diff --git a/src/views/system/manager/index.vue b/src/views/system/manager/index.vue
new file mode 100644
index 0000000..e5b261f
--- /dev/null
+++ b/src/views/system/manager/index.vue
@@ -0,0 +1,196 @@
+
+
+
+
+
+
+
diff --git a/src/views/system/manager/modules/system-variable-detail-drawer.vue b/src/views/system/manager/modules/system-variable-detail-drawer.vue
new file mode 100644
index 0000000..2312b2e
--- /dev/null
+++ b/src/views/system/manager/modules/system-variable-detail-drawer.vue
@@ -0,0 +1,52 @@
+
+
+
+
+
+
+ {{ rowData?.variableName }}
+
+
+ {{ rowData?.variableType }}
+
+
+ {{ rowData?.variableKey }}
+
+
+ {{ rowData?.variableValue }}
+
+
+ {{ rowData?.description }}
+
+
+ {{ rowData?.updateDt }}
+
+
+
+
+
+
diff --git a/src/views/system/manager/modules/system-variable-operate-drawer.vue b/src/views/system/manager/modules/system-variable-operate-drawer.vue
new file mode 100644
index 0000000..5c4d300
--- /dev/null
+++ b/src/views/system/manager/modules/system-variable-operate-drawer.vue
@@ -0,0 +1,194 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ $t('common.cancel') }}
+ {{ $t('common.save') }}
+
+
+
+
+
+
diff --git a/src/views/system/manager/modules/system-variable-search.vue b/src/views/system/manager/modules/system-variable-search.vue
new file mode 100644
index 0000000..acad1f1
--- /dev/null
+++ b/src/views/system/manager/modules/system-variable-search.vue
@@ -0,0 +1,44 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+