1256 lines
64 KiB
TypeScript
1256 lines
64 KiB
TypeScript
/* tslint:disable */
|
||
/* eslint-disable */
|
||
/**
|
||
* Admin.NET 通用权限开发平台
|
||
* 让 .NET 开发更简单、更通用、更流行。整合最新技术,模块插件式开发,前后端分离,开箱即用。<br/><u><b><font color='FF0000'> 👮不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任!</font></b></u>
|
||
*
|
||
* OpenAPI spec version: 1.0.0
|
||
*
|
||
*
|
||
* NOTE: This class is auto generated by the swagger code generator program.
|
||
* https://github.com/swagger-api/swagger-codegen.git
|
||
* Do not edit the class manually.
|
||
*/
|
||
|
||
import globalAxios, { AxiosResponse, AxiosInstance, AxiosRequestConfig } from 'axios';
|
||
import { Configuration } from '../configuration';
|
||
// Some imports not used depending on template conditions
|
||
// @ts-ignore
|
||
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from '../base';
|
||
import { AddRegionInput } from '../models';
|
||
import { AdminNETResultInt32 } from '../models';
|
||
import { AdminNETResultInt64 } from '../models';
|
||
import { AdminNETResultListSysRegion } from '../models';
|
||
import { AdminNETResultSqlSugarPagedListSysRegion } from '../models';
|
||
import { DeleteRegionInput } from '../models';
|
||
import { GDInput } from '../models';
|
||
import { GenOrgInput } from '../models';
|
||
import { McaInput } from '../models';
|
||
import { MzbInput } from '../models';
|
||
import { PageRegionInput } from '../models';
|
||
import { QueryRegionInput } from '../models';
|
||
import { TiandituInput } from '../models';
|
||
import { UpdateRegionInput } from '../models';
|
||
/**
|
||
* SysRegionApi - axios parameter creator
|
||
* @export
|
||
*/
|
||
export const SysRegionApiAxiosParamCreator = function (configuration?: Configuration) {
|
||
return {
|
||
/**
|
||
*
|
||
* @summary 增加行政区划 🔖
|
||
* @param {AddRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionAddPost: async (body?: AddRegionInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/add`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子列表 🔖
|
||
* @param {number} pid
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionChildListPidGet: async (pid: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
// verify required parameter 'pid' is not null or undefined
|
||
if (pid === null || pid === undefined) {
|
||
throw new RequiredError('pid','Required parameter pid was null or undefined when calling apiSysRegionChildListPidGet.');
|
||
}
|
||
const localVarPath = `/api/sysRegion/childList/{pid}`
|
||
.replace(`{${"pid"}}`, encodeURIComponent(String(pid)));
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'GET', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子树 🔖
|
||
* @param {number} pid
|
||
* @param {number} level
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionChildTreePidLevelGet: async (pid: number, level: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
// verify required parameter 'pid' is not null or undefined
|
||
if (pid === null || pid === undefined) {
|
||
throw new RequiredError('pid','Required parameter pid was null or undefined when calling apiSysRegionChildTreePidLevelGet.');
|
||
}
|
||
// verify required parameter 'level' is not null or undefined
|
||
if (level === null || level === undefined) {
|
||
throw new RequiredError('level','Required parameter level was null or undefined when calling apiSysRegionChildTreePidLevelGet.');
|
||
}
|
||
const localVarPath = `/api/sysRegion/childTree/{pid}/{level}`
|
||
.replace(`{${"pid"}}`, encodeURIComponent(String(pid)))
|
||
.replace(`{${"level"}}`, encodeURIComponent(String(level)));
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'GET', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 删除行政区划 🔖
|
||
* @param {DeleteRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionDeletePost: async (body?: DeleteRegionInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/delete`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 生成组织架构 🔖
|
||
* @param {GenOrgInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionGenOrgPost: async (body?: GenOrgInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/genOrg`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取行政区划列表 🔖
|
||
* @param {number} id 主键Id
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionListGet: async (id: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
// verify required parameter 'id' is not null or undefined
|
||
if (id === null || id === undefined) {
|
||
throw new RequiredError('id','Required parameter id was null or undefined when calling apiSysRegionListGet.');
|
||
}
|
||
const localVarPath = `/api/sysRegion/list`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'GET', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
if (id !== undefined) {
|
||
localVarQueryParameter['Id'] = id;
|
||
}
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取行政区划分页列表 🔖
|
||
* @param {PageRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionPagePost: async (body?: PageRegionInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/page`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 查询行政区划列表 🔖
|
||
* @param {QueryRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionQueryPost: async (body?: QueryRegionInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/query`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 从 china.sqlite 中获取区划数据
|
||
* @param {string} code 区划编码
|
||
* @param {number} level 级数(从当前code所在级别往下级数)
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionRegionTreeCodeLevelGet: async (code: string, level: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
// verify required parameter 'code' is not null or undefined
|
||
if (code === null || code === undefined) {
|
||
throw new RequiredError('code','Required parameter code was null or undefined when calling apiSysRegionRegionTreeCodeLevelGet.');
|
||
}
|
||
// verify required parameter 'level' is not null or undefined
|
||
if (level === null || level === undefined) {
|
||
throw new RequiredError('level','Required parameter level was null or undefined when calling apiSysRegionRegionTreeCodeLevelGet.');
|
||
}
|
||
const localVarPath = `/api/sysRegion/regionTree/{code}/{level}`
|
||
.replace(`{${"code"}}`, encodeURIComponent(String(code)))
|
||
.replace(`{${"level"}}`, encodeURIComponent(String(level)));
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'GET', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(高德) 🔖
|
||
* @param {GDInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionSyncRegionGDPost: async (body?: GDInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/syncRegionGD`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(国家地名信息库,最多支持2级深度) 🔖
|
||
* @param {McaInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionSyncRegionMcaPost: async (body?: McaInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/syncRegionMca`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(民政部) 🔖
|
||
* @param {MzbInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionSyncRegionMzbPost: async (body?: MzbInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/syncRegionMzb`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(天地图行政区划) 🔖
|
||
* @param {TiandituInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionSyncRegionTiandituPost: async (body?: TiandituInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/syncRegionTianditu`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 更新行政区划 🔖
|
||
* @param {UpdateRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
apiSysRegionUpdatePost: async (body?: UpdateRegionInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
||
const localVarPath = `/api/sysRegion/update`;
|
||
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
||
const localVarUrlObj = new URL(localVarPath, 'https://example.com');
|
||
let baseOptions;
|
||
if (configuration) {
|
||
baseOptions = configuration.baseOptions;
|
||
}
|
||
const localVarRequestOptions :AxiosRequestConfig = { method: 'POST', ...baseOptions, ...options};
|
||
const localVarHeaderParameter = {} as any;
|
||
const localVarQueryParameter = {} as any;
|
||
|
||
// authentication Bearer required
|
||
// http bearer authentication required
|
||
if (configuration && configuration.accessToken) {
|
||
const accessToken = typeof configuration.accessToken === 'function'
|
||
? await configuration.accessToken()
|
||
: await configuration.accessToken;
|
||
localVarHeaderParameter["Authorization"] = "Bearer " + accessToken;
|
||
}
|
||
|
||
localVarHeaderParameter['Content-Type'] = 'application/json-patch+json';
|
||
|
||
const query = new URLSearchParams(localVarUrlObj.search);
|
||
for (const key in localVarQueryParameter) {
|
||
query.set(key, localVarQueryParameter[key]);
|
||
}
|
||
for (const key in options.params) {
|
||
query.set(key, options.params[key]);
|
||
}
|
||
localVarUrlObj.search = (new URLSearchParams(query)).toString();
|
||
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
||
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
||
const needsSerialization = (typeof body !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
|
||
localVarRequestOptions.data = needsSerialization ? JSON.stringify(body !== undefined ? body : {}) : (body || "");
|
||
|
||
return {
|
||
url: localVarUrlObj.pathname + localVarUrlObj.search + localVarUrlObj.hash,
|
||
options: localVarRequestOptions,
|
||
};
|
||
},
|
||
}
|
||
};
|
||
|
||
/**
|
||
* SysRegionApi - functional programming interface
|
||
* @export
|
||
*/
|
||
export const SysRegionApiFp = function(configuration?: Configuration) {
|
||
return {
|
||
/**
|
||
*
|
||
* @summary 增加行政区划 🔖
|
||
* @param {AddRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionAddPost(body?: AddRegionInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultInt64>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionAddPost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子列表 🔖
|
||
* @param {number} pid
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionChildListPidGet(pid: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultListSysRegion>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionChildListPidGet(pid, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子树 🔖
|
||
* @param {number} pid
|
||
* @param {number} level
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionChildTreePidLevelGet(pid: number, level: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultListSysRegion>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionChildTreePidLevelGet(pid, level, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 删除行政区划 🔖
|
||
* @param {DeleteRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionDeletePost(body?: DeleteRegionInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionDeletePost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 生成组织架构 🔖
|
||
* @param {GenOrgInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionGenOrgPost(body?: GenOrgInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionGenOrgPost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取行政区划列表 🔖
|
||
* @param {number} id 主键Id
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionListGet(id: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultListSysRegion>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionListGet(id, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取行政区划分页列表 🔖
|
||
* @param {PageRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionPagePost(body?: PageRegionInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultSqlSugarPagedListSysRegion>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionPagePost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 查询行政区划列表 🔖
|
||
* @param {QueryRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionQueryPost(body?: QueryRegionInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultListSysRegion>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionQueryPost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 从 china.sqlite 中获取区划数据
|
||
* @param {string} code 区划编码
|
||
* @param {number} level 级数(从当前code所在级别往下级数)
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionRegionTreeCodeLevelGet(code: string, level: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionRegionTreeCodeLevelGet(code, level, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(高德) 🔖
|
||
* @param {GDInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionGDPost(body?: GDInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionSyncRegionGDPost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(国家地名信息库,最多支持2级深度) 🔖
|
||
* @param {McaInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionMcaPost(body?: McaInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultInt32>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionSyncRegionMcaPost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(民政部) 🔖
|
||
* @param {MzbInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionMzbPost(body?: MzbInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionSyncRegionMzbPost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(天地图行政区划) 🔖
|
||
* @param {TiandituInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionTiandituPost(body?: TiandituInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<AdminNETResultInt32>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionSyncRegionTiandituPost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
/**
|
||
*
|
||
* @summary 更新行政区划 🔖
|
||
* @param {UpdateRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionUpdatePost(body?: UpdateRegionInput, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
||
const localVarAxiosArgs = await SysRegionApiAxiosParamCreator(configuration).apiSysRegionUpdatePost(body, options);
|
||
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
||
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
||
return axios.request(axiosRequestArgs);
|
||
};
|
||
},
|
||
}
|
||
};
|
||
|
||
/**
|
||
* SysRegionApi - factory interface
|
||
* @export
|
||
*/
|
||
export const SysRegionApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
||
return {
|
||
/**
|
||
*
|
||
* @summary 增加行政区划 🔖
|
||
* @param {AddRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionAddPost(body?: AddRegionInput, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultInt64>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionAddPost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子列表 🔖
|
||
* @param {number} pid
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionChildListPidGet(pid: number, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionChildListPidGet(pid, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子树 🔖
|
||
* @param {number} pid
|
||
* @param {number} level
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionChildTreePidLevelGet(pid: number, level: number, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionChildTreePidLevelGet(pid, level, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 删除行政区划 🔖
|
||
* @param {DeleteRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionDeletePost(body?: DeleteRegionInput, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionDeletePost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 生成组织架构 🔖
|
||
* @param {GenOrgInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionGenOrgPost(body?: GenOrgInput, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionGenOrgPost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取行政区划列表 🔖
|
||
* @param {number} id 主键Id
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionListGet(id: number, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionListGet(id, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 获取行政区划分页列表 🔖
|
||
* @param {PageRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionPagePost(body?: PageRegionInput, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultSqlSugarPagedListSysRegion>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionPagePost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 查询行政区划列表 🔖
|
||
* @param {QueryRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionQueryPost(body?: QueryRegionInput, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionQueryPost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 从 china.sqlite 中获取区划数据
|
||
* @param {string} code 区划编码
|
||
* @param {number} level 级数(从当前code所在级别往下级数)
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionRegionTreeCodeLevelGet(code: string, level: number, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionRegionTreeCodeLevelGet(code, level, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(高德) 🔖
|
||
* @param {GDInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionGDPost(body?: GDInput, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionSyncRegionGDPost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(国家地名信息库,最多支持2级深度) 🔖
|
||
* @param {McaInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionMcaPost(body?: McaInput, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultInt32>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionSyncRegionMcaPost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(民政部) 🔖
|
||
* @param {MzbInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionMzbPost(body?: MzbInput, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionSyncRegionMzbPost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(天地图行政区划) 🔖
|
||
* @param {TiandituInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionSyncRegionTiandituPost(body?: TiandituInput, options?: AxiosRequestConfig): Promise<AxiosResponse<AdminNETResultInt32>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionSyncRegionTiandituPost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
/**
|
||
*
|
||
* @summary 更新行政区划 🔖
|
||
* @param {UpdateRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
*/
|
||
async apiSysRegionUpdatePost(body?: UpdateRegionInput, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(configuration).apiSysRegionUpdatePost(body, options).then((request) => request(axios, basePath));
|
||
},
|
||
};
|
||
};
|
||
|
||
/**
|
||
* SysRegionApi - object-oriented interface
|
||
* @export
|
||
* @class SysRegionApi
|
||
* @extends {BaseAPI}
|
||
*/
|
||
export class SysRegionApi extends BaseAPI {
|
||
/**
|
||
*
|
||
* @summary 增加行政区划 🔖
|
||
* @param {AddRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionAddPost(body?: AddRegionInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultInt64>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionAddPost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子列表 🔖
|
||
* @param {number} pid
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionChildListPidGet(pid: number, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionChildListPidGet(pid, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 获取指定层级行政区划子树 🔖
|
||
* @param {number} pid
|
||
* @param {number} level
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionChildTreePidLevelGet(pid: number, level: number, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionChildTreePidLevelGet(pid, level, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 删除行政区划 🔖
|
||
* @param {DeleteRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionDeletePost(body?: DeleteRegionInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionDeletePost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 生成组织架构 🔖
|
||
* @param {GenOrgInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionGenOrgPost(body?: GenOrgInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionGenOrgPost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 获取行政区划列表 🔖
|
||
* @param {number} id 主键Id
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionListGet(id: number, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionListGet(id, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 获取行政区划分页列表 🔖
|
||
* @param {PageRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionPagePost(body?: PageRegionInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultSqlSugarPagedListSysRegion>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionPagePost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 查询行政区划列表 🔖
|
||
* @param {QueryRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionQueryPost(body?: QueryRegionInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultListSysRegion>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionQueryPost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 从 china.sqlite 中获取区划数据
|
||
* @param {string} code 区划编码
|
||
* @param {number} level 级数(从当前code所在级别往下级数)
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionRegionTreeCodeLevelGet(code: string, level: number, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionRegionTreeCodeLevelGet(code, level, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(高德) 🔖
|
||
* @param {GDInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionSyncRegionGDPost(body?: GDInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionSyncRegionGDPost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(国家地名信息库,最多支持2级深度) 🔖
|
||
* @param {McaInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionSyncRegionMcaPost(body?: McaInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultInt32>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionSyncRegionMcaPost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 同步行政区划(民政部) 🔖
|
||
* @param {MzbInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionSyncRegionMzbPost(body?: MzbInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionSyncRegionMzbPost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 同步行政区划数据(天地图行政区划) 🔖
|
||
* @param {TiandituInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionSyncRegionTiandituPost(body?: TiandituInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<AdminNETResultInt32>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionSyncRegionTiandituPost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
/**
|
||
*
|
||
* @summary 更新行政区划 🔖
|
||
* @param {UpdateRegionInput} [body]
|
||
* @param {*} [options] Override http request option.
|
||
* @throws {RequiredError}
|
||
* @memberof SysRegionApi
|
||
*/
|
||
public async apiSysRegionUpdatePost(body?: UpdateRegionInput, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
||
return SysRegionApiFp(this.configuration).apiSysRegionUpdatePost(body, options).then((request) => request(this.axios, this.basePath));
|
||
}
|
||
}
|