@geelato/gl-runtime-core 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/dist/gl-runtime-core.css +1 -0
  2. package/dist/gl-runtime-core.css.gz +0 -0
  3. package/dist/gl-runtime-core.js +169768 -0
  4. package/dist/gl-runtime-core.js.gz +0 -0
  5. package/dist/gl-runtime-core.umd.cjs +35 -0
  6. package/dist/iconfont-BJ2VOOKJ.js +35 -0
  7. package/dist/iconfont-BJ2VOOKJ.js.gz +0 -0
  8. package/dist/types/actions/JsScriptExecutor.d.ts +291 -0
  9. package/dist/types/actions/fns/datetime.d.ts +22 -0
  10. package/dist/types/actions/fns/device.d.ts +23 -0
  11. package/dist/types/actions/fns/math.d.ts +27 -0
  12. package/dist/types/api/EntityApi.d.ts +143 -0
  13. package/dist/types/api/EntityDataSource.d.ts +272 -0
  14. package/dist/types/api/EntityDeleteService.d.ts +47 -0
  15. package/dist/types/api/EntityQueryCache.d.ts +62 -0
  16. package/dist/types/api/EntityQueryService.d.ts +71 -0
  17. package/dist/types/api/EntityResultMapping.d.ts +11 -0
  18. package/dist/types/api/EntitySaveService.d.ts +46 -0
  19. package/dist/types/api/EntityTypes.d.ts +135 -0
  20. package/dist/types/api/EntityUtilService.d.ts +42 -0
  21. package/dist/types/assets/globalConfig.d.ts +5 -0
  22. package/dist/types/components/AppProvideProxy.d.ts +21 -0
  23. package/dist/types/components/ComponentTreeParser.d.ts +17 -0
  24. package/dist/types/components/FormProvideProxy.d.ts +35 -0
  25. package/dist/types/components/Hooks.d.ts +7 -0
  26. package/dist/types/components/PageDataSourceManager.d.ts +28 -0
  27. package/dist/types/components/PageLoader.d.ts +6 -0
  28. package/dist/types/components/PageProvideProxy.d.ts +413 -0
  29. package/dist/types/components/UiEventNames.d.ts +15 -0
  30. package/dist/types/components/gl-chart/GlChart.vue.d.ts +135 -0
  31. package/dist/types/components/gl-component/GlComponent.vue.d.ts +191 -0
  32. package/dist/types/components/gl-component/GlComponentSupport.d.ts +49 -0
  33. package/dist/types/components/gl-component/GlInsts.vue.d.ts +19 -0
  34. package/dist/types/components/gl-div/GlDiv.vue.d.ts +107 -0
  35. package/dist/types/components/gl-dnd-placeholder/Index.vue.d.ts +112 -0
  36. package/dist/types/components/gl-html/Index.vue.d.ts +7 -0
  37. package/dist/types/components/gl-iconfont/IconsJson.d.ts +15 -0
  38. package/dist/types/components/gl-iconfont/Index.vue.d.ts +19 -0
  39. package/dist/types/components/gl-loader/GlLoader.vue.d.ts +3 -0
  40. package/dist/types/components/gl-login/FloatingActionButton.vue.d.ts +9 -0
  41. package/dist/types/components/gl-login/LoginDialog.vue.d.ts +9 -0
  42. package/dist/types/components/gl-loop/GlLoop.vue.d.ts +230 -0
  43. package/dist/types/components/gl-page-viewer/GlPageViewer.vue.d.ts +221 -0
  44. package/dist/types/components/gl-scanner/GlScanner.vue.d.ts +44 -0
  45. package/dist/types/components/gl-template/GlTemplate.vue.d.ts +154 -0
  46. package/dist/types/components/gl-template/Typs.d.ts +4 -0
  47. package/dist/types/components/gl-virtual/Index.vue.d.ts +3 -0
  48. package/dist/types/components/mixins.d.ts +86 -0
  49. package/dist/types/components/ui-mixins.d.ts +16 -0
  50. package/dist/types/composables/useApiUrl.d.ts +30 -0
  51. package/dist/types/composables/useGlobal.d.ts +21 -0
  52. package/dist/types/composables/useLoading.d.ts +6 -0
  53. package/dist/types/composables/useLogger.d.ts +32 -0
  54. package/dist/types/composables/useMessages.d.ts +15 -0
  55. package/dist/types/composables/useRole.d.ts +5 -0
  56. package/dist/types/locales/index.d.ts +21 -0
  57. package/dist/types/locales/lang/en-US.d.ts +4 -0
  58. package/dist/types/locales/lang/zh-CN.d.ts +4 -0
  59. package/dist/types/m/datasource/ApplicationApi.d.ts +163 -0
  60. package/dist/types/m/datasource/ArcoApi.d.ts +76 -0
  61. package/dist/types/m/datasource/Base.d.ts +99 -0
  62. package/dist/types/m/datasource/BranchApi.d.ts +2 -0
  63. package/dist/types/m/datasource/CompanyApi.d.ts +49 -0
  64. package/dist/types/m/datasource/DictApi.d.ts +127 -0
  65. package/dist/types/m/datasource/DictionaryApi.d.ts +16 -0
  66. package/dist/types/m/datasource/EncodingApi.d.ts +59 -0
  67. package/dist/types/m/datasource/Entry.d.ts +5 -0
  68. package/dist/types/m/datasource/FieldMeta.d.ts +6 -0
  69. package/dist/types/m/datasource/FileApi.d.ts +273 -0
  70. package/dist/types/m/datasource/FileTemplateApi.d.ts +114 -0
  71. package/dist/types/m/datasource/InterApi.d.ts +104 -0
  72. package/dist/types/m/datasource/MarketApi.d.ts +191 -0
  73. package/dist/types/m/datasource/MessageApi.d.ts +27 -0
  74. package/dist/types/m/datasource/ModelApi.d.ts +327 -0
  75. package/dist/types/m/datasource/NoticeApi.d.ts +37 -0
  76. package/dist/types/m/datasource/OcrPdfApi.d.ts +145 -0
  77. package/dist/types/m/datasource/PluginApi.d.ts +35 -0
  78. package/dist/types/m/datasource/ScheduleApi.d.ts +67 -0
  79. package/dist/types/m/datasource/SecurityApi.d.ts +253 -0
  80. package/dist/types/m/datasource/SiteApi.d.ts +38 -0
  81. package/dist/types/m/datasource/SqlApi.d.ts +45 -0
  82. package/dist/types/m/datasource/SysConfigApi.d.ts +52 -0
  83. package/dist/types/m/datasource/TenantApi.d.ts +107 -0
  84. package/dist/types/m/datasource/UserApi.d.ts +173 -0
  85. package/dist/types/m/datasource/VersionApi.d.ts +59 -0
  86. package/dist/types/m/datasource/WeChatApi.d.ts +34 -0
  87. package/dist/types/m/datasource/WorkflowApi.d.ts +317 -0
  88. package/dist/types/m/datasource/ZxingApi.d.ts +38 -0
  89. package/dist/types/main.d.ts +114 -0
  90. package/dist/types/store/index.d.ts +2 -0
  91. package/dist/types/store/modules/user/index.d.ts +16 -0
  92. package/dist/types/types/Operators.d.ts +19 -0
  93. package/dist/types/types/global.d.ts +198 -0
  94. package/dist/types/types/options.d.ts +35 -0
  95. package/dist/types/utils/Auth.d.ts +37 -0
  96. package/dist/types/utils/CacheManager.d.ts +110 -0
  97. package/dist/types/utils/CheckUtil.d.ts +5 -0
  98. package/dist/types/utils/ClipboardUtil.d.ts +24 -0
  99. package/dist/types/utils/ConvertUtil.d.ts +81 -0
  100. package/dist/types/utils/Event.d.ts +2 -0
  101. package/dist/types/utils/FileUtil.d.ts +7 -0
  102. package/dist/types/utils/GenerateUtil.d.ts +14 -0
  103. package/dist/types/utils/IsUtil.d.ts +126 -0
  104. package/dist/types/utils/MixUtil.d.ts +49 -0
  105. package/dist/types/utils/Monitor.d.ts +2 -0
  106. package/dist/types/utils/PageUtil.d.ts +14 -0
  107. package/dist/types/utils/PluginUtil.d.ts +9 -0
  108. package/dist/types/utils/RecordsUtil.d.ts +3 -0
  109. package/dist/types/utils/SseClient.d.ts +34 -0
  110. package/dist/types/utils/StoreUtil.d.ts +8 -0
  111. package/dist/types/utils/StringUtil.d.ts +29 -0
  112. package/dist/types/utils/Utils.d.ts +217 -0
  113. package/dist/types/utils/emitter.d.ts +3 -0
  114. package/dist/types/utils/renderTemplate.d.ts +6 -0
  115. package/dist/types/utils/toChineseCurrency.d.ts +5 -0
  116. package/package.json +76 -0
  117. package/src/main.ts +498 -0
@@ -0,0 +1,86 @@
1
+ import { PropType } from 'vue';
2
+ import { ComponentInstance } from '@geelato/gl-ui-schema';
3
+ import { PageCustomType, PagePermission } from './PageProvideProxy';
4
+ import { IComponentInstance } from '@geelato/gl-types';
5
+ declare const _default: {
6
+ props: {
7
+ parentId: {
8
+ type: (StringConstructor | NumberConstructor)[];
9
+ };
10
+ glComponentInst: {
11
+ type: PropType<IComponentInstance>;
12
+ default(): ComponentInstance;
13
+ };
14
+ glChildren: {
15
+ type: PropType<Array<IComponentInstance>>;
16
+ default(): never[];
17
+ };
18
+ glCtx: {
19
+ type: ObjectConstructor;
20
+ default(): {};
21
+ };
22
+ /**
23
+ * 是否运行时,用于组件区分是否按设计时进行渲染
24
+ */
25
+ glIsRuntime: {
26
+ type: BooleanConstructor;
27
+ default(): boolean;
28
+ };
29
+ /**
30
+ * 如果是runtime,则值为‘Runtime’
31
+ * 该属性和glIsRuntime需对应
32
+ */
33
+ glRuntimeFlag: {
34
+ type: StringConstructor;
35
+ default(): string;
36
+ };
37
+ glIndex: {
38
+ type: NumberConstructor;
39
+ };
40
+ /**
41
+ * 组件在loop组件内时,会接收到glLoopItem对象
42
+ */
43
+ glLoopItem: ObjectConstructor;
44
+ /**
45
+ * 组件在loop组件内时,会接收到glLoopIndex索引
46
+ */
47
+ glLoopIndex: NumberConstructor;
48
+ /**
49
+ * 组件忽略注入页面代理
50
+ */
51
+ glIgnoreInjectPageProxy: {
52
+ type: BooleanConstructor;
53
+ default(): boolean;
54
+ };
55
+ componentStoreId: {
56
+ type: StringConstructor;
57
+ default(): string;
58
+ };
59
+ /**
60
+ * 页面自定义配置
61
+ */
62
+ pageCustom: PropType<PageCustomType>;
63
+ /**
64
+ * 页面权限配置
65
+ */
66
+ pagePermission: PropType<PagePermission>;
67
+ /**
68
+ * 执行脚本编排配置的事件
69
+ */
70
+ glDoAction: {
71
+ type: FunctionConstructor;
72
+ required: boolean;
73
+ };
74
+ };
75
+ subFormProps: {
76
+ /**
77
+ * 是否作为子表单
78
+ */
79
+ isSubForm: BooleanConstructor;
80
+ /**
81
+ * 如果作为子表单,那本表单中哪个字段指向父表单的id
82
+ */
83
+ subFormPidName: StringConstructor;
84
+ };
85
+ };
86
+ export default _default;
@@ -0,0 +1,16 @@
1
+ declare const _default: {
2
+ props: {
3
+ fieldId: {
4
+ type: (StringConstructor | NumberConstructor)[];
5
+ };
6
+ className: {
7
+ type: StringConstructor;
8
+ default(): string;
9
+ };
10
+ __style__: {
11
+ type: StringConstructor;
12
+ default(): string;
13
+ };
14
+ };
15
+ };
16
+ export default _default;
@@ -0,0 +1,30 @@
1
+ export declare class ApiPathName {
2
+ metaList: string;
3
+ metaMultiList: string;
4
+ apiMetaSave: string;
5
+ apiMetaBatchSave: string;
6
+ apiMetaMultiSave: string;
7
+ apiMetaDelete: string;
8
+ apiMetaDelete2: string;
9
+ apiMetaEntityNames: string;
10
+ apiEntityLiteMetas: string;
11
+ apiMetaDefined: string;
12
+ apiMetaFullDefined: string;
13
+ apiUpload: string;
14
+ api: string;
15
+ apiSqlKey: string;
16
+ getPageAndCustom: string;
17
+ getPageCustom: string;
18
+ getPageLang: string;
19
+ getPageById: string;
20
+ getPageByExtendId: string;
21
+ notifyUpdatePage: string;
22
+ apiMetaUniqueness: string;
23
+ apiCacheRemove: string;
24
+ }
25
+ declare const _default: () => {
26
+ getApiBaseUrl: () => string;
27
+ getWorkflowApiBaseUrl: () => string;
28
+ getApiPathName: () => ApiPathName;
29
+ };
30
+ export default _default;
@@ -0,0 +1,21 @@
1
+ import { Utils } from '../utils/Utils';
2
+ import { UserState } from './../m/datasource/UserApi';
3
+ import { ComponentCustomProperties } from 'vue';
4
+ export interface GeelatoType {
5
+ user: UserState;
6
+ tenant: any;
7
+ app: any;
8
+ cfg: {
9
+ tenant: Record<string, any>;
10
+ app: Record<string, any>;
11
+ platform: Record<string, any>;
12
+ };
13
+ utils: Utils;
14
+ }
15
+ export default function useGlobal(): ComponentCustomProperties & {
16
+ $gl: GeelatoType & Record<string, any>;
17
+ $notification?: any;
18
+ $message?: any;
19
+ $modal?: any;
20
+ $drawer?: any;
21
+ };
@@ -0,0 +1,6 @@
1
+ import { Ref } from 'vue';
2
+ export default function useLoading(initValue?: boolean): {
3
+ loading: Ref<boolean, boolean>;
4
+ setLoading: (value: boolean) => void;
5
+ toggle: () => void;
6
+ };
@@ -0,0 +1,32 @@
1
+ declare const enum LoggerLevel {
2
+ DEBUG = 0,
3
+ INFO = 1,
4
+ WARNING = 2,
5
+ ERROR = 3
6
+ }
7
+ /**
8
+ * 使用示例
9
+ * const myLogger = new Logger('MyApp')
10
+ * myLogger.debug('Debug message with parameter: {0}', 'paramValue')
11
+ * myLogger.info('This is an info message')
12
+ * myLogger.warning('Warning message')
13
+ * myLogger.error('Error message with {0} and {1}', 'param1', 'param2')
14
+ */
15
+ export declare class Logger {
16
+ private readonly name;
17
+ constructor(name: string);
18
+ getLoglevel(): LoggerLevel;
19
+ debug(message: string, ...optionalParams: any[]): void;
20
+ info(message: string, ...optionalParams: any[]): void;
21
+ warning(message: string, ...optionalParams: any[]): void;
22
+ error(message: string, ...optionalParams: any[]): void;
23
+ private log;
24
+ private getLevelStyle;
25
+ private formatMessage;
26
+ }
27
+ /**
28
+ * 获取日志器
29
+ * @param name 日志器名称,如果为空则使用默认日志器,通过该名称区分不同的日志器
30
+ */
31
+ declare const useLogger: (name?: string) => Logger;
32
+ export default useLogger;
@@ -0,0 +1,15 @@
1
+ interface MessageRule {
2
+ rule: string;
3
+ msg: string;
4
+ extractKeyRules?: Record<string, string[]>;
5
+ }
6
+ export declare const messages: MessageRule[];
7
+ /**
8
+ * 匹配不到时,返回空字符串:''
9
+ * @param data 异常字符串,或对象{code:-2,data:null,msg:"xxxxxxx",status:"fail"}
10
+ */
11
+ export declare const getMessage: (data: string | Record<string, any>) => string;
12
+ declare const _default: () => {
13
+ getMessage: (data: string | Record<string, any>) => string;
14
+ };
15
+ export default _default;
@@ -0,0 +1,5 @@
1
+ export declare function hasRole(code: string): boolean;
2
+ export declare function hasAnyRole(codes: string | string[]): boolean;
3
+ export declare function hasAllRoles(codes: string | string[]): boolean;
4
+ export declare function withoutRole(code: string): boolean;
5
+ export declare function checkRolePermission(routeRoles: string[] | string, userRoleCodes?: string): boolean;
@@ -0,0 +1,21 @@
1
+ import { createI18n } from 'vue-i18n';
2
+ import { ComputedRef } from 'vue';
3
+ type AppI18n = ReturnType<typeof createI18n> & {
4
+ tproxy: (key: string, defaultValue?: string) => string | undefined;
5
+ setI18nLanguage: (lang?: string) => void;
6
+ };
7
+ declare const i18n: AppI18n;
8
+ export declare const setI18nLanguage: (lang?: string) => void;
9
+ export declare function loadLanguageAsync(lang?: string): Promise<string | void>;
10
+ export declare function i18nRender(key: string, values?: any): string;
11
+ export declare function mergeLocaleMessages(lang: string, messages: Record<string, any>): void;
12
+ export declare function mergeMessages(all: Record<string, any>): void;
13
+ declare global {
14
+ interface Window {
15
+ $i18n: AppI18n;
16
+ }
17
+ }
18
+ export default i18n;
19
+ export declare const useLocaleRef: () => ComputedRef<string>;
20
+ export declare function tLabel(value?: string, dict?: Array<Record<string, any>>, locale?: string): any;
21
+ export declare function ensureI18nKeys(props: any): void;
@@ -0,0 +1,4 @@
1
+ declare const _default: {
2
+ [x: string]: any;
3
+ };
4
+ export default _default;
@@ -0,0 +1,4 @@
1
+ declare const _default: {
2
+ [x: string]: any;
3
+ };
4
+ export default _default;
@@ -0,0 +1,163 @@
1
+ import { RouteRecordNormalized } from 'vue-router';
2
+ import { QueryRolePermissionForm } from './SecurityApi';
3
+ import { BaseSortableEntity, PageQueryResponse, QueryResult } from './Base';
4
+ import { AxiosResponse } from 'axios';
5
+ export interface AppState {
6
+ theme: string;
7
+ navStyle: string;
8
+ colorWeak: boolean;
9
+ navbar: boolean;
10
+ menu: boolean;
11
+ topMenu: boolean;
12
+ hideMenu: boolean;
13
+ menuCollapse: boolean;
14
+ footer: boolean;
15
+ themeColor: string;
16
+ menuWidth: number;
17
+ menuCollapseWidth: number;
18
+ globalSettings: boolean;
19
+ device: string;
20
+ tabBar: boolean;
21
+ menuFromServer: boolean;
22
+ serverMenu: RouteRecordNormalized[];
23
+ multiTab: boolean;
24
+ multiTabMax: number;
25
+ [key: string]: unknown;
26
+ }
27
+ export interface QueryAppForm extends BaseSortableEntity {
28
+ name: string;
29
+ type: string;
30
+ code: string;
31
+ icon: string;
32
+ purpose: string;
33
+ appKey: string;
34
+ token: string;
35
+ tree: string;
36
+ logo: string;
37
+ theme: string;
38
+ watermark: number;
39
+ href: string;
40
+ dependAppCode: string;
41
+ powerInfo: string;
42
+ versionInfo: string;
43
+ description: string;
44
+ applyStatus: number;
45
+ designStatus: number;
46
+ appStorage: string;
47
+ ideVersion: string;
48
+ modelColumnPcl: string;
49
+ roles?: string;
50
+ }
51
+ export interface QueryMenuForm {
52
+ id: string;
53
+ pid: string;
54
+ appId: string;
55
+ pageId: string;
56
+ flag: string;
57
+ icon: string;
58
+ iconType: string;
59
+ type: string;
60
+ meta: string;
61
+ url: string;
62
+ treeEntity: string;
63
+ extendEntity: string;
64
+ text: string;
65
+ seqNo: number;
66
+ tenantCode: string;
67
+ children?: QueryMenuForm[];
68
+ }
69
+ export interface QueryMultiLangForm {
70
+ appId: string;
71
+ langType: string;
72
+ langPackage: string;
73
+ purpose: string;
74
+ enableStatus: number;
75
+ }
76
+ /**
77
+ * 查询应用多语言配置
78
+ * @param appId
79
+ * @param langType
80
+ */
81
+ export declare function queryAppMultiLang(appId: string, langType: string): Promise< AxiosResponse<string, any>>;
82
+ /**
83
+ * 分页查询
84
+ * @param params
85
+ */
86
+ export declare function pageQueryMultiLangs(params: Record<string, any>): Promise< AxiosResponse<PageQueryResponse, any>>;
87
+ /**
88
+ * 条件查询
89
+ * @param params
90
+ */
91
+ export declare function queryMultiLangs(params: Record<string, any>): Promise< AxiosResponse<QueryMultiLangForm[], any>>;
92
+ /**
93
+ * 单条查询
94
+ * @param id
95
+ */
96
+ export declare function getMultiLang(id: string): Promise< AxiosResponse<QueryMultiLangForm, any>>;
97
+ /**
98
+ * 创建或更新
99
+ * @param params
100
+ */
101
+ export declare function createOrUpdateMultiLang(params: QueryMultiLangForm): Promise< AxiosResponse<QueryResult, any>>;
102
+ /**
103
+ * 删除
104
+ * @param id
105
+ */
106
+ export declare function deleteMultiLang(id: string): Promise< AxiosResponse<QueryResult, any>>;
107
+ /**
108
+ * 获取应用菜单
109
+ * @param params
110
+ */
111
+ export declare function getMenus(params: QueryMenuForm): Promise< AxiosResponse<QueryMenuForm[], any>>;
112
+ /**
113
+ * 分页查询
114
+ * @param params
115
+ */
116
+ export declare function pageQueryApps(params: Record<string, any>): Promise< AxiosResponse<PageQueryResponse, any>>;
117
+ /**
118
+ * 条件查询
119
+ * @param params
120
+ */
121
+ export declare function queryApps(params: Record<string, any>): Promise< AxiosResponse<QueryAppForm[], any>>;
122
+ /**
123
+ * 单条查询
124
+ * @param id
125
+ */
126
+ export declare function getApp(id: string): Promise< AxiosResponse<QueryAppForm, any>>;
127
+ /**
128
+ * 创建或更新
129
+ * @param params
130
+ */
131
+ export declare function createOrUpdateApp(params: QueryAppForm, userType?: string): Promise< AxiosResponse<QueryResult, any>>;
132
+ /**
133
+ * 删除
134
+ * @param id
135
+ */
136
+ export declare function deleteApp(id: string): Promise< AxiosResponse<QueryResult, any>>;
137
+ export declare function uploadApp(fileId: string): Promise< AxiosResponse<QueryResult, any>>;
138
+ /**
139
+ * 验证应用编码
140
+ * @param params
141
+ */
142
+ export declare function validateAppCode(params: QueryAppForm): Promise< AxiosResponse<boolean, any>>;
143
+ export declare function validateAppId(params: QueryAppForm): Promise< AxiosResponse<boolean, any>>;
144
+ /**
145
+ * 用户拥有权限的应用
146
+ * @param tenantCode
147
+ * @param userId
148
+ */
149
+ export declare function queryAppsByUser(tenantCode: string, userId?: string): Promise< AxiosResponse<QueryAppForm[], any>>;
150
+ export declare function queryPermissionByPage(params: Record<string, any>): Promise< AxiosResponse<QueryResult, any>>;
151
+ export declare function queryRolePermissionByPage(params: Record<string, any>): Promise< AxiosResponse<QueryRolePermissionForm[], any>>;
152
+ /**
153
+ * 应用与数据链接关系表
154
+ * @param params
155
+ */
156
+ export declare function pageQueryAppConnectOf(params: Record<string, any>): Promise< AxiosResponse<PageQueryResponse, any>>;
157
+ /**
158
+ * 查询所有的应用
159
+ * @param params
160
+ * @param successBack
161
+ * @param failBack
162
+ */
163
+ export declare const getAppSelectOptions: (params: Record<string, any>, successBack?: any, failBack?: any) => Promise<void>;
@@ -0,0 +1,76 @@
1
+ import { AxiosResponse } from 'axios';
2
+ import { ComputedRef } from 'vue';
3
+ export declare function getArcoSelectOptionData(type: string): Promise< AxiosResponse<Record<string, any>[], any>>;
4
+ /**
5
+ * 字典类型枚举
6
+ * 使用const枚举提升性能,编译时会被内联
7
+ */
8
+ export declare const enum SelectOptionType {
9
+ PERMISSION_TYPE = "PermissionTypeEnum",
10
+ RESTFUL_CONFIG_TYPE = "RestfulConfigType",
11
+ SYS_CONFIG_VALUE_TYPE = "SysConfigValueTypeEnum",
12
+ SYS_CONFIG_PURPOSE = "SysConfigPurposeEnum",
13
+ SCHEDULE_TYPE = "ScheduleTypeEnum",
14
+ SCHEDULE_LOG_TYPE = "ScheduleLogTypeEnum",
15
+ SCHEDULE_LOG_STATUS = "ScheduleLogStatusEnum",
16
+ RESPONSE_PARAM_TYPE = "ResponseParamTypeEnum",
17
+ MODEL_COLUMN_PCL = "ModelColumnPclEnum",
18
+ APPROVAL_STATUS = "ApprovalStatusEnum",
19
+ APPLICATION_TYPE = "ApplicationTypeEnum",
20
+ APPLICATION_PURPOSE = "ApplicationPurposeEnum",
21
+ APP_MULTI_LANG_TYPE = "AppMultiLangTypeEnum",
22
+ APP_MULTI_LANG_PURPOSE = "AppMultiLangPurposeEnum",
23
+ EXCEL_ALIGNMENT = "ExcelAlignmentEnum",
24
+ EXCEL_MULTI_SCENE_TYPE = "ExcelMultiSceneTypeEnum",
25
+ WORD_TABLE_LOOP_TYPE = "WordTableLoopTypeEnum",
26
+ EXCEL_COLUMN_TYPE_RULE = "ExcelColumnTypeRuleEnum",
27
+ EXCEL_EVALUATION = "ExcelEvaluationEnum",
28
+ EXCEL_COLUMN_TYPE = "ExcelColumnTypeEnum",
29
+ ATTACHMENT_SERVICE = "AttachmentServiceEnum",
30
+ ATTACHMENT_SOURCE = "AttachmentSourceEnum",
31
+ ATTACHMENT_MIME = "AttachmentMimeEnum",
32
+ RULE_TYPE = "RuleTypeEnum",
33
+ META_TYPE = "MetaTypeEnum",
34
+ DICT_DISPOSE = "DictDisposeEnum",
35
+ SCRIPT_RESPONSE_PARAM_TYPE = "ScriptResponseParamTypeEnum",
36
+ ALTERNATE_TYPE = "AlternateTypeEnum",
37
+ ROLE_TYPE = "RoleTypeEnum",
38
+ VALID_TYPE = "ValidTypeEnum",
39
+ ORG_TYPE = "OrgTypeEnum",
40
+ ORG_CATEGORY = "OrgCategoryEnum",
41
+ IS_DEFAULT_ORG = "IsDefaultOrgEnum",// 未使用
42
+ ENCODING_SERIAL_TYPE = "EncodingSerialTypeEnum",
43
+ ENCODING_ITEM_TYPE = "EncodingItemTypeEnum",
44
+ AUTH_CODE_ACTION = "AuthCodeAction",
45
+ MESSAGE_SEND_STATUS = "MessageSendStatus",
46
+ PACKAGE_STATUS = "PackageStatusEnum",
47
+ PACKAGE_SOURCE = "PackageSourceEnum",
48
+ BARCODE_TYPE = "BarcodeTypeEnum",
49
+ BARCODE_SIZE_UNIT = "BarcodeSizeUnitEnum",
50
+ BARCODE_PICTURE_FORMAT = "BarcodePictureFormatEnum",
51
+ BARCODE_FONT_STYLE = "BarcodeFontStyleEnum",
52
+ BARCODE_FONT_POSITION = "BarcodeFontPositionEnum",
53
+ BARCODE_FONT_ALIGN = "BarcodeFontAlignEnum",
54
+ VIEW_TYPE = "ViewTypeEnum",
55
+ MYSQL_DATA_TYPE = "MysqlDataTypeEnum",
56
+ TABLE_SOURCE_TYPE = "TableSourceTypeEnum",
57
+ TABLE_TYPE = "TableTypeEnum",
58
+ TABLE_FOREIGN_ACTION = "TableForeignAction",
59
+ LINKED = "LinkedEnum",
60
+ ENABLE_STATUS = "EnableStatusEnum",
61
+ DIALECTS = "Dialects",
62
+ DELETE_STATUS = "DeleteStatusEnum",
63
+ COLUMN_SYNCED = "ColumnSyncedEnum",
64
+ COLUMN_ENCRYPTED = "ColumnEncryptedEnum",
65
+ TIME_UNIT = "TimeUnitEnum",
66
+ LOCALE = "LocaleEnum"
67
+ }
68
+ /**
69
+ * 获取字典选项
70
+ * @param soType 字典类型
71
+ * @param locale 语言环境
72
+ */
73
+ export declare const useSelectOptionData: (soType: SelectOptionType) => {
74
+ refresh: (locale?: string) => Promise<void>;
75
+ options: ComputedRef<Record<string, any>[]>;
76
+ };
@@ -0,0 +1,99 @@
1
+ export type FormState = 'add' | 'edit' | 'view';
2
+ export interface PageQueryFilter {
3
+ id: string;
4
+ createdTime: string;
5
+ }
6
+ export interface PageQueryRequest extends Partial<PageQueryFilter> {
7
+ current: number;
8
+ pageSize: number;
9
+ order?: string;
10
+ }
11
+ export interface PageQueryResponse {
12
+ items: PageQueryFilter[];
13
+ total: number;
14
+ }
15
+ export interface QueryResult {
16
+ data: any;
17
+ msg: string;
18
+ code: number;
19
+ status: string;
20
+ }
21
+ export interface IdEntity {
22
+ id: string;
23
+ }
24
+ export interface BaseEntity extends IdEntity {
25
+ createAt?: string;
26
+ creator?: string;
27
+ creatorName?: string;
28
+ updateAt?: string;
29
+ updater?: string;
30
+ updaterName?: string;
31
+ deleteAt?: string;
32
+ delStatus?: number;
33
+ buId?: string;
34
+ deptId?: string;
35
+ tenantCode?: string;
36
+ }
37
+ export interface BaseSortableEntity extends BaseEntity {
38
+ seqNo?: number;
39
+ }
40
+ export interface SelectOption {
41
+ value: string | number | Record<string, any>;
42
+ label: string;
43
+ isLeaf?: boolean;
44
+ disabled?: boolean;
45
+ children?: SelectOption[];
46
+ }
47
+ export interface Pagination {
48
+ current: number;
49
+ pageSize: number;
50
+ total?: number;
51
+ showPageSize?: boolean;
52
+ pageSizeOptions?: Array<number>;
53
+ }
54
+ export interface HttpResponse<T = unknown> {
55
+ status: number;
56
+ msg: string;
57
+ code: number;
58
+ data: T;
59
+ }
60
+ export interface ListUrlParams {
61
+ action: 'add' | 'edit' | 'view';
62
+ isModal?: boolean;
63
+ formCol?: 1 | 2;
64
+ pageSize?: 5 | 10 | 20 | 50 | 100 | 1000 | 10000;
65
+ id?: string;
66
+ params?: Record<string, any>;
67
+ closeBack?: any;
68
+ loadSuccessBack?: any;
69
+ loadFailBack?: any;
70
+ modalAddBack?: any;
71
+ modalEditBack?: any;
72
+ modalDeleteBack?: any;
73
+ }
74
+ export interface ListParams {
75
+ visible?: boolean;
76
+ parameter?: Record<string, any>;
77
+ formState?: FormState;
78
+ filterCol?: number;
79
+ pageSize?: number;
80
+ height?: number;
81
+ }
82
+ export interface FormParams {
83
+ visible?: boolean;
84
+ isModal?: boolean;
85
+ title?: string;
86
+ width?: string;
87
+ height?: number | string;
88
+ parameter?: Record<string, any>;
89
+ formState?: FormState;
90
+ id?: string;
91
+ formCol?: number;
92
+ }
93
+ export interface ModelParams {
94
+ visible?: boolean;
95
+ parameter?: Record<string, any>;
96
+ formState?: FormState;
97
+ id?: string;
98
+ formCol?: number;
99
+ }
@@ -0,0 +1,2 @@
1
+ import { ApiResult } from '../../main.ts';
2
+ export declare function getBranch(): Promise< ApiResult<any>>;
@@ -0,0 +1,49 @@
1
+ import { PageQueryResponse, QueryResult } from './Base';
2
+ import { AxiosResponse } from 'axios';
3
+ export interface QueryCompanyForm {
4
+ id: string;
5
+ name: string;
6
+ code: string;
7
+ type: string;
8
+ status: number;
9
+ description: string;
10
+ address: string;
11
+ contact: string;
12
+ phone: string;
13
+ email: string;
14
+ website: string;
15
+ logo: string;
16
+ seqNo: number;
17
+ enableStatus: number;
18
+ appId: string;
19
+ tenantCode: string;
20
+ createAt: string;
21
+ updateAt: string;
22
+ creator: string;
23
+ updater: string;
24
+ }
25
+ /**
26
+ * 分页查询公司列表
27
+ * @param params
28
+ */
29
+ export declare function pageQueryCompany(params: Record<string, any>): Promise< AxiosResponse<PageQueryResponse, any>>;
30
+ /**
31
+ * 查询公司列表
32
+ * @param params
33
+ */
34
+ export declare function queryCompanies(params: Record<string, any>): Promise< AxiosResponse<QueryCompanyForm[], any>>;
35
+ /**
36
+ * 根据ID获取公司信息
37
+ * @param id
38
+ */
39
+ export declare function getCompany(id: string): Promise< AxiosResponse<QueryCompanyForm, any>>;
40
+ /**
41
+ * 创建或更新公司
42
+ * @param params
43
+ */
44
+ export declare function createOrUpdateCompany(params: QueryCompanyForm): Promise< AxiosResponse<QueryResult, any>>;
45
+ /**
46
+ * 删除公司
47
+ * @param id
48
+ */
49
+ export declare function deleteCompany(id: string): Promise< AxiosResponse<QueryResult, any>>;