😎增加前端同步民政部行政区划调用
This commit is contained in:
parent
85bcd500ac
commit
56e39efae4
@ -81,7 +81,7 @@
|
|||||||
|
|
||||||
<script lang="ts" setup name="sysRegion">
|
<script lang="ts" setup name="sysRegion">
|
||||||
import { nextTick, onMounted, reactive, ref } from 'vue';
|
import { nextTick, onMounted, reactive, ref } from 'vue';
|
||||||
import { ElMessageBox, ElMessage } from 'element-plus';
|
import { ElMessageBox, ElMessage, ElNotification } from 'element-plus';
|
||||||
import { VxeGridInstance, VxeGridListeners, VxeGridPropTypes } from 'vxe-table';
|
import { VxeGridInstance, VxeGridListeners, VxeGridPropTypes } from 'vxe-table';
|
||||||
import { useVxeTable } from '/@/hooks/useVxeTableOptionsHook';
|
import { useVxeTable } from '/@/hooks/useVxeTableOptionsHook';
|
||||||
import { Local } from '/@/utils/storage';
|
import { Local } from '/@/utils/storage';
|
||||||
@ -242,7 +242,7 @@ const handleNodeChange = async (node: any) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
// 从云端同步点击
|
// 从云端同步点击
|
||||||
const handleCommand = (command: string) => {
|
const handleCommand = async (command: string) => {
|
||||||
if (command === 'amap') {
|
if (command === 'amap') {
|
||||||
state.title = '同步高德地图';
|
state.title = '同步高德地图';
|
||||||
syncGdParamRef.value?.openDialog();
|
syncGdParamRef.value?.openDialog();
|
||||||
@ -253,11 +253,26 @@ const handleCommand = (command: string) => {
|
|||||||
state.title = '同步国家地名信息库';
|
state.title = '同步国家地名信息库';
|
||||||
syncMcaParamRef.value?.openDialog();
|
syncMcaParamRef.value?.openDialog();
|
||||||
} else if (command === 'mzb') {
|
} else if (command === 'mzb') {
|
||||||
state.title = '同步民政部行政区划';
|
// state.title = '同步民政部行政区划';
|
||||||
// syncTdtParamRef.value?.openDialog();
|
// syncTdtParamRef.value?.openDialog();
|
||||||
|
await syncMzbRegion();
|
||||||
} else ElMessage.error(`菜单选择有误`);
|
} else ElMessage.error(`菜单选择有误`);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 同步民政部行政区划
|
||||||
|
const syncMzbRegion = async () => {
|
||||||
|
ElNotification({
|
||||||
|
title: '提示',
|
||||||
|
message: '努力同步中...',
|
||||||
|
type: 'success',
|
||||||
|
position: 'bottom-right',
|
||||||
|
});
|
||||||
|
options.loading = true;
|
||||||
|
await getAPI(SysRegionApi).apiSysRegionSyncRegionMzbPost();
|
||||||
|
options.loading = false;
|
||||||
|
ElMessage.success('生成成功');
|
||||||
|
};
|
||||||
|
|
||||||
// 生成组织架构
|
// 生成组织架构
|
||||||
const genOrg = (row: any) => {
|
const genOrg = (row: any) => {
|
||||||
state.title = '生成/更新系统组织架构';
|
state.title = '生成/更新系统组织架构';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user