From 6330792804194da272f7f3f436384bfaed8b293e Mon Sep 17 00:00:00 2001
From: "1378012178@qq.com" <1378012178@qq.com>
Date: Fri, 25 Apr 2025 16:18:02 +0800
Subject: [PATCH] =?UTF-8?q?=E6=9C=8D=E5=8A=A1=E6=8C=87=E4=BB=A4=E5=90=8C?=
=?UTF-8?q?=E6=AD=A5?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/components/dataAsync/AsyncMain.api.ts | 72 ++
src/components/dataAsync/AsyncMain.data.ts | 66 +
.../dataAsync/AsyncMainList copy.vue | 260 ++++
src/components/dataAsync/AsyncMainList.vue | 171 +++
src/components/dataAsync/asyncStatus.api.ts | 72 ++
src/components/dataAsync/asyncStatus.data.ts | 42 +
src/components/dataAsync/asyncStatusList.vue | 235 ++++
.../dataAsync/components/AsyncMainForm.vue | 163 +++
.../dataAsync/components/AsyncMainModal.vue | 77 ++
.../dataAsync/components/asyncStatusForm.vue | 170 +++
.../dataAsync/components/asyncStatusModal.vue | 77 ++
src/layouts/default/header/index.vue | 2 +-
.../ConfigServiceDirective.api.ts | 9 +
.../ConfigServiceDirectiveListCom.vue | 128 +-
src/views/synchronization/directive/index.vue | 1107 ++++++++++++-----
.../synchronization/directive/org.data.ts | 82 ++
16 files changed, 2338 insertions(+), 395 deletions(-)
create mode 100644 src/components/dataAsync/AsyncMain.api.ts
create mode 100644 src/components/dataAsync/AsyncMain.data.ts
create mode 100644 src/components/dataAsync/AsyncMainList copy.vue
create mode 100644 src/components/dataAsync/AsyncMainList.vue
create mode 100644 src/components/dataAsync/asyncStatus.api.ts
create mode 100644 src/components/dataAsync/asyncStatus.data.ts
create mode 100644 src/components/dataAsync/asyncStatusList.vue
create mode 100644 src/components/dataAsync/components/AsyncMainForm.vue
create mode 100644 src/components/dataAsync/components/AsyncMainModal.vue
create mode 100644 src/components/dataAsync/components/asyncStatusForm.vue
create mode 100644 src/components/dataAsync/components/asyncStatusModal.vue
create mode 100644 src/views/synchronization/directive/org.data.ts
diff --git a/src/components/dataAsync/AsyncMain.api.ts b/src/components/dataAsync/AsyncMain.api.ts
new file mode 100644
index 0000000..be57271
--- /dev/null
+++ b/src/components/dataAsync/AsyncMain.api.ts
@@ -0,0 +1,72 @@
+import { defHttp } from '/@/utils/http/axios';
+import { useMessage } from "/@/hooks/web/useMessage";
+
+const { createConfirm } = useMessage();
+
+enum Api {
+ list = '/asyncmain/asyncMain/list',
+ save='/asyncmain/asyncMain/add',
+ edit='/asyncmain/asyncMain/edit',
+ deleteOne = '/asyncmain/asyncMain/delete',
+ deleteBatch = '/asyncmain/asyncMain/deleteBatch',
+ importExcel = '/asyncmain/asyncMain/importExcel',
+ exportXls = '/asyncmain/asyncMain/exportXls',
+}
+
+/**
+ * 导出api
+ * @param params
+ */
+export const getExportUrl = Api.exportXls;
+
+/**
+ * 导入api
+ */
+export const getImportUrl = Api.importExcel;
+
+/**
+ * 列表接口
+ * @param params
+ */
+export const list = (params) => defHttp.get({ url: Api.list, params });
+
+/**
+ * 删除单个
+ * @param params
+ * @param handleSuccess
+ */
+export const deleteOne = (params,handleSuccess) => {
+ return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => {
+ handleSuccess();
+ });
+}
+
+/**
+ * 批量删除
+ * @param params
+ * @param handleSuccess
+ */
+export const batchDelete = (params, handleSuccess) => {
+ createConfirm({
+ iconType: 'warning',
+ title: '确认删除',
+ content: '是否删除选中数据',
+ okText: '确认',
+ cancelText: '取消',
+ onOk: () => {
+ return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => {
+ handleSuccess();
+ });
+ }
+ });
+}
+
+/**
+ * 保存或者更新
+ * @param params
+ * @param isUpdate
+ */
+export const saveOrUpdate = (params, isUpdate) => {
+ let url = isUpdate ? Api.edit : Api.save;
+ return defHttp.post({ url: url, params }, { isTransformResponse: false });
+}
diff --git a/src/components/dataAsync/AsyncMain.data.ts b/src/components/dataAsync/AsyncMain.data.ts
new file mode 100644
index 0000000..23acf67
--- /dev/null
+++ b/src/components/dataAsync/AsyncMain.data.ts
@@ -0,0 +1,66 @@
+import { BasicColumn } from '/@/components/Table';
+import { FormSchema } from '/@/components/Table';
+import { rules } from '/@/utils/helper/validator';
+import { render } from '/@/utils/common/renderUtils';
+import { getWeekMonthQuarterYear } from '/@/utils';
+//主列表数据
+export const asyncMaincolumns: BasicColumn[] = [
+ // {
+ // title: '类型',
+ // align: "center",
+ // dataIndex: 'type'
+ // },
+ {
+ title: '同步备注信息',
+ align: 'center',
+ dataIndex: 'descr',
+ },
+ {
+ title: '同步人',
+ align: 'center',
+ dataIndex: 'createBy_dictText',
+ },
+ {
+ title: '开始同步时间',
+ align: 'center',
+ dataIndex: 'createTime',
+ },
+ {
+ title: '同步状态',
+ align: 'center',
+ dataIndex: 'asyncStatusList',
+ },
+];
+//子列表数据
+export const asyncStatusColumns: BasicColumn[] = [
+ {
+ title: '同步内容',
+ align: 'center',
+ dataIndex: 'name',
+ width:'200px'
+ },
+ {
+ title: '同步状态',
+ align: 'center',
+ dataIndex: 'status',
+ width:'100px'
+ },
+ {
+ title: '同步结果',
+ align: 'center',
+ dataIndex: 'msg',
+ },
+ {
+ title: '更新时间',
+ align: 'center',
+ dataIndex: 'updateTime',
+ width:'200px'
+ },
+];
+// 高级查询数据
+export const superQuerySchema = {
+ type: { title: '类型(同步的是什么类型的数据)', order: 0, view: 'text', type: 'string' },
+ descr: { title: '备注/描述', order: 1, view: 'text', type: 'string' },
+ createBy: { title: '创建人', order: 2, view: 'text', type: 'string' },
+ createTime: { title: '创建日期', order: 3, view: 'datetime', type: 'string' },
+};
diff --git a/src/components/dataAsync/AsyncMainList copy.vue b/src/components/dataAsync/AsyncMainList copy.vue
new file mode 100644
index 0000000..9eeb452
--- /dev/null
+++ b/src/components/dataAsync/AsyncMainList copy.vue
@@ -0,0 +1,260 @@
+
+
+
+
+
+
+
+
+ 新增
+ 导出
+ 导入
+
+
+
+
+
+ 删除
+
+
+
+ 批量操作
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/dataAsync/AsyncMainList.vue b/src/components/dataAsync/AsyncMainList.vue
new file mode 100644
index 0000000..22332e8
--- /dev/null
+++ b/src/components/dataAsync/AsyncMainList.vue
@@ -0,0 +1,171 @@
+
+
+
+
+
+
+ 新增
+ 导出
+ 导入
+
+
+
+
+
+ 删除
+
+
+
+ 批量操作
+
+
+
+
+
+
+
+ 点击此行展开/收起同步详情
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/dataAsync/asyncStatus.api.ts b/src/components/dataAsync/asyncStatus.api.ts
new file mode 100644
index 0000000..78052c5
--- /dev/null
+++ b/src/components/dataAsync/asyncStatus.api.ts
@@ -0,0 +1,72 @@
+import { defHttp } from '/@/utils/http/axios';
+import { useMessage } from "/@/hooks/web/useMessage";
+
+const { createConfirm } = useMessage();
+
+enum Api {
+ list = '/asyncstatus/asyncStatus/list',
+ save='/asyncstatus/asyncStatus/add',
+ edit='/asyncstatus/asyncStatus/edit',
+ deleteOne = '/asyncstatus/asyncStatus/delete',
+ deleteBatch = '/asyncstatus/asyncStatus/deleteBatch',
+ importExcel = '/asyncstatus/asyncStatus/importExcel',
+ exportXls = '/asyncstatus/asyncStatus/exportXls',
+}
+
+/**
+ * 导出api
+ * @param params
+ */
+export const getExportUrl = Api.exportXls;
+
+/**
+ * 导入api
+ */
+export const getImportUrl = Api.importExcel;
+
+/**
+ * 列表接口
+ * @param params
+ */
+export const list = (params) => defHttp.get({ url: Api.list, params });
+
+/**
+ * 删除单个
+ * @param params
+ * @param handleSuccess
+ */
+export const deleteOne = (params,handleSuccess) => {
+ return defHttp.delete({url: Api.deleteOne, params}, {joinParamsToUrl: true}).then(() => {
+ handleSuccess();
+ });
+}
+
+/**
+ * 批量删除
+ * @param params
+ * @param handleSuccess
+ */
+export const batchDelete = (params, handleSuccess) => {
+ createConfirm({
+ iconType: 'warning',
+ title: '确认删除',
+ content: '是否删除选中数据',
+ okText: '确认',
+ cancelText: '取消',
+ onOk: () => {
+ return defHttp.delete({url: Api.deleteBatch, data: params}, {joinParamsToUrl: true}).then(() => {
+ handleSuccess();
+ });
+ }
+ });
+}
+
+/**
+ * 保存或者更新
+ * @param params
+ * @param isUpdate
+ */
+export const saveOrUpdate = (params, isUpdate) => {
+ let url = isUpdate ? Api.edit : Api.save;
+ return defHttp.post({ url: url, params }, { isTransformResponse: false });
+}
diff --git a/src/components/dataAsync/asyncStatus.data.ts b/src/components/dataAsync/asyncStatus.data.ts
new file mode 100644
index 0000000..2eb443d
--- /dev/null
+++ b/src/components/dataAsync/asyncStatus.data.ts
@@ -0,0 +1,42 @@
+import {BasicColumn} from '/@/components/Table';
+import {FormSchema} from '/@/components/Table';
+import { rules} from '/@/utils/helper/validator';
+import { render } from '/@/utils/common/renderUtils';
+import { getWeekMonthQuarterYear } from '/@/utils';
+//列表数据
+export const columns: BasicColumn[] = [
+ {
+ title: '同步内容',
+ align: "center",
+ dataIndex: 'name'
+ },
+ {
+ title: '主表id',
+ align: "center",
+ dataIndex: 'pkid'
+ },
+ {
+ title: '状态',
+ align: "center",
+ dataIndex: 'status'
+ },
+ {
+ title: '结果',
+ align: "center",
+ dataIndex: 'msg'
+ },
+ {
+ title: '更新日期',
+ align: "center",
+ dataIndex: 'updateTime'
+ },
+];
+
+// 高级查询数据
+export const superQuerySchema = {
+ name: {title: '同步内容',order: 0,view: 'text', type: 'string',},
+ pkid: {title: '主表id',order: 1,view: 'text', type: 'string',},
+ status: {title: '状态',order: 2,view: 'text', type: 'string',},
+ msg: {title: '结果',order: 3,view: 'textarea', type: 'string',},
+ updateTime: {title: '更新日期',order: 4,view: 'datetime', type: 'string',},
+};
diff --git a/src/components/dataAsync/asyncStatusList.vue b/src/components/dataAsync/asyncStatusList.vue
new file mode 100644
index 0000000..cb8b016
--- /dev/null
+++ b/src/components/dataAsync/asyncStatusList.vue
@@ -0,0 +1,235 @@
+
+
+
+
+
+
+
+
+ 新增
+ 导出
+ 导入
+
+
+
+
+
+ 删除
+
+
+
+ 批量操作
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/dataAsync/components/AsyncMainForm.vue b/src/components/dataAsync/components/AsyncMainForm.vue
new file mode 100644
index 0000000..e0f4595
--- /dev/null
+++ b/src/components/dataAsync/components/AsyncMainForm.vue
@@ -0,0 +1,163 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/dataAsync/components/AsyncMainModal.vue b/src/components/dataAsync/components/AsyncMainModal.vue
new file mode 100644
index 0000000..9e655b0
--- /dev/null
+++ b/src/components/dataAsync/components/AsyncMainModal.vue
@@ -0,0 +1,77 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/dataAsync/components/asyncStatusForm.vue b/src/components/dataAsync/components/asyncStatusForm.vue
new file mode 100644
index 0000000..1b76474
--- /dev/null
+++ b/src/components/dataAsync/components/asyncStatusForm.vue
@@ -0,0 +1,170 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/dataAsync/components/asyncStatusModal.vue b/src/components/dataAsync/components/asyncStatusModal.vue
new file mode 100644
index 0000000..75558ea
--- /dev/null
+++ b/src/components/dataAsync/components/asyncStatusModal.vue
@@ -0,0 +1,77 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/layouts/default/header/index.vue b/src/layouts/default/header/index.vue
index c55e434..10841eb 100644
--- a/src/layouts/default/header/index.vue
+++ b/src/layouts/default/header/index.vue
@@ -39,7 +39,7 @@
-
+
diff --git a/src/views/serviceDirective/serviceDirective/ConfigServiceDirective.api.ts b/src/views/serviceDirective/serviceDirective/ConfigServiceDirective.api.ts
index 2f2fcec..d008acf 100644
--- a/src/views/serviceDirective/serviceDirective/ConfigServiceDirective.api.ts
+++ b/src/views/serviceDirective/serviceDirective/ConfigServiceDirective.api.ts
@@ -11,6 +11,7 @@ enum Api {
deleteBatch = '/serviceDirective/configServiceDirective/deleteBatch',
importExcel = '/serviceDirective/configServiceDirective/importExcel',
exportXls = '/serviceDirective/configServiceDirective/exportXls',
+ async = '/serviceDirective/configServiceDirective/async',
}
/**
@@ -70,3 +71,11 @@ export const saveOrUpdate = (params, isUpdate) => {
let url = isUpdate ? Api.edit : Api.save;
return defHttp.post({ url: url, params }, { isTransformResponse: false });
}
+
+/**
+ * 同步数据
+ * @param params
+ */
+export const asyncFunc = (params) => {
+ return defHttp.post({ url: Api.async, params }, { isTransformResponse: false });
+}
\ No newline at end of file
diff --git a/src/views/serviceDirective/serviceDirective/ConfigServiceDirectiveListCom.vue b/src/views/serviceDirective/serviceDirective/ConfigServiceDirectiveListCom.vue
index b9a3dae..637bd3e 100644
--- a/src/views/serviceDirective/serviceDirective/ConfigServiceDirectiveListCom.vue
+++ b/src/views/serviceDirective/serviceDirective/ConfigServiceDirectiveListCom.vue
@@ -1,19 +1,12 @@
-
+
-
+
-
+
-
+
无文件
@@ -29,16 +22,11 @@
-
+
-
-
+
+