@tager/admin-import 1.0.0 → 1.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.
- package/dist/dev/App.vue.d.ts +4 -3
- package/dist/index.mjs +277 -311
- package/dist/services/requests.d.ts +2 -2
- package/dist/style.css +1 -1
- package/dist/typings/model.d.ts +2 -2
- package/dist/views/ImportForm/ImportForm.helpers.d.ts +4 -4
- package/dist/views/ImportForm/ImportForm.vue.d.ts +1845 -370
- package/dist/views/ImportList/ImportList.vue.d.ts +5 -4
- package/dist/views/ImportList/components/CellHistory/CellHistory.vue.d.ts +5 -4
- package/package.json +20 -24
- package/src/dev/App.vue +4 -2
- package/src/dev/env.ts +11 -11
- package/src/services/requests.ts +4 -4
- package/src/typings/model.ts +4 -4
- package/src/views/ImportForm/ImportForm.helpers.ts +3 -3
- package/src/views/ImportForm/ImportForm.vue +8 -8
- package/src/views/ImportList/ImportList.vue +2 -3
- package/src/views/ImportList/components/CellHistory/CellHistory.vue +4 -2
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { ColumnDefinition } from '@tager/admin-ui';
|
|
2
|
-
import { ImportType } from '../../typings/model';
|
|
1
|
+
import { type ColumnDefinition } from '@tager/admin-ui';
|
|
2
|
+
import { type ImportType } from '../../typings/model';
|
|
3
3
|
import { getImportFormUrl } from '../../utils/paths';
|
|
4
|
-
declare const _default:
|
|
4
|
+
declare const _default: typeof __VLS_export;
|
|
5
|
+
export default _default;
|
|
6
|
+
declare const __VLS_export: import("vue").DefineComponent<{}, {
|
|
5
7
|
columnDefs: ColumnDefinition<ImportType>[];
|
|
6
8
|
getImportFormUrl: typeof getImportFormUrl;
|
|
7
9
|
rowData: import("vue").Ref<ImportType[]>;
|
|
@@ -13,4 +15,3 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
13
15
|
pageCount: import("vue").ComputedRef<number>;
|
|
14
16
|
pageNumber: import("vue").Ref<number>;
|
|
15
17
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
16
|
-
export default _default;
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { PropType } from "vue";
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
import { type HistoryType } from "../../../../typings/model";
|
|
2
3
|
import { dateTimeFormat } from './CellHistory.helpers';
|
|
3
|
-
|
|
4
|
-
|
|
4
|
+
declare const _default: typeof __VLS_export;
|
|
5
|
+
export default _default;
|
|
6
|
+
declare const __VLS_export: import("vue").DefineComponent<{
|
|
5
7
|
history: {
|
|
6
8
|
type: PropType<HistoryType[]>;
|
|
7
9
|
default: () => never[];
|
|
@@ -16,4 +18,3 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
16
18
|
}>>, {
|
|
17
19
|
history: HistoryType[];
|
|
18
20
|
}>;
|
|
19
|
-
export default _default;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tager/admin-import",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "dist/index.umd.js",
|
|
6
6
|
"module": "dist/index.esm.js",
|
|
@@ -16,11 +16,13 @@
|
|
|
16
16
|
},
|
|
17
17
|
"scripts": {
|
|
18
18
|
"build:js": "vite build",
|
|
19
|
-
"build:package": "
|
|
19
|
+
"build:package": "yarn build:js && (yarn emit-declarations || echo 'vue-tsc: type errors found, declarations emitted anyway')",
|
|
20
20
|
"emit-declarations": "vue-tsc --project tsconfig.json --emitDeclarationOnly",
|
|
21
|
-
"start": "
|
|
21
|
+
"start": "vite",
|
|
22
22
|
"prepare": "yarn build:package",
|
|
23
|
-
"tager:update": "yarn upgrade --latest --scope @tager"
|
|
23
|
+
"tager:update": "yarn upgrade --latest --scope @tager",
|
|
24
|
+
"lint": "eslint .",
|
|
25
|
+
"format": "prettier --write src"
|
|
24
26
|
},
|
|
25
27
|
"dependencies": {
|
|
26
28
|
"lodash.isequal": "^4.5.0",
|
|
@@ -29,9 +31,7 @@
|
|
|
29
31
|
"path-to-regexp": "^6.1.0"
|
|
30
32
|
},
|
|
31
33
|
"devDependencies": {
|
|
32
|
-
"@
|
|
33
|
-
"@babel/eslint-parser": "^7.17.0",
|
|
34
|
-
"@rushstack/eslint-patch": "^1.1.2",
|
|
34
|
+
"@eslint/js": "^9.39.5",
|
|
35
35
|
"@tager/admin-dynamic-field": "^1.0.0",
|
|
36
36
|
"@tager/admin-layout": "^1.0.0",
|
|
37
37
|
"@tager/admin-services": "^1.0.0",
|
|
@@ -39,28 +39,24 @@
|
|
|
39
39
|
"@types/lodash.isequal": "^4.5.6",
|
|
40
40
|
"@types/lodash.pick": "^4.4.7",
|
|
41
41
|
"@types/node": "16.x",
|
|
42
|
-
"@
|
|
43
|
-
"@typescript
|
|
44
|
-
"@vitejs/plugin-vue": "^2.3.1",
|
|
45
|
-
"@vue/cli-plugin-babel": "^5.0.4",
|
|
46
|
-
"@vue/cli-plugin-typescript": "^5.0.4",
|
|
47
|
-
"@vue/cli-service": "~5.0.0",
|
|
48
|
-
"@vue/eslint-config-prettier": "^7.0.0",
|
|
49
|
-
"@vue/eslint-config-typescript": "^10.0.0",
|
|
50
|
-
"concurrently": "^7.1.0",
|
|
42
|
+
"@vitejs/plugin-vue": "^5.2.4",
|
|
43
|
+
"@vue/eslint-config-typescript": "^14.9.0",
|
|
51
44
|
"core-js": "^3.22.3",
|
|
52
|
-
"eslint": "^
|
|
53
|
-
"eslint-config-prettier": "^
|
|
54
|
-
"eslint-
|
|
55
|
-
"eslint-plugin-
|
|
56
|
-
"eslint-plugin-vue": "^
|
|
45
|
+
"eslint": "^9.39.5",
|
|
46
|
+
"eslint-config-prettier": "^10.1.8",
|
|
47
|
+
"eslint-import-resolver-typescript": "^4.4.5",
|
|
48
|
+
"eslint-plugin-import": "^2.32.0",
|
|
49
|
+
"eslint-plugin-vue": "^10.12.0",
|
|
50
|
+
"globals": "^16.5.0",
|
|
51
|
+
"prettier": "^3.9.10",
|
|
57
52
|
"sass": "^1.51.0",
|
|
58
53
|
"sass-loader": "^12.6.0",
|
|
59
|
-
"typescript": "^
|
|
60
|
-
"vite": "^
|
|
54
|
+
"typescript": "^5.9.3",
|
|
55
|
+
"vite": "^6.4.5",
|
|
61
56
|
"vue": "^3.2.31",
|
|
57
|
+
"vue-eslint-parser": "^10.4.1",
|
|
62
58
|
"vue-router": "^4.0.14",
|
|
63
|
-
"vue-tsc": "^
|
|
59
|
+
"vue-tsc": "^3.3.14"
|
|
64
60
|
},
|
|
65
61
|
"peerDependencies": {
|
|
66
62
|
"@tager/admin-layout": "^1.0.0",
|
package/src/dev/App.vue
CHANGED
|
@@ -6,11 +6,13 @@
|
|
|
6
6
|
|
|
7
7
|
<script lang="ts">
|
|
8
8
|
import {defineComponent} from 'vue';
|
|
9
|
-
|
|
9
|
+
|
|
10
|
+
import {type MenuItemType, PageLayout} from "@tager/admin-layout";
|
|
10
11
|
import {ViewListIcon} from "@tager/admin-ui";
|
|
11
|
-
import {getImportListUrl} from '../utils/paths';
|
|
12
12
|
import {useI18n} from "@tager/admin-services";
|
|
13
13
|
|
|
14
|
+
import {getImportListUrl} from '../utils/paths';
|
|
15
|
+
|
|
14
16
|
export default defineComponent({
|
|
15
17
|
name: 'App',
|
|
16
18
|
components: {
|
package/src/dev/env.ts
CHANGED
|
@@ -2,16 +2,16 @@ import { initializeEnvironment } from '@tager/admin-services';
|
|
|
2
2
|
|
|
3
3
|
export function populateEnvironment() {
|
|
4
4
|
initializeEnvironment({
|
|
5
|
-
publicPath:
|
|
6
|
-
appEnv:
|
|
7
|
-
apiUrl:
|
|
8
|
-
accessToken:
|
|
9
|
-
websiteUrl:
|
|
10
|
-
websiteButtonUrl:
|
|
11
|
-
sentryDsn:
|
|
12
|
-
sentryEnv:
|
|
13
|
-
baseUrl:
|
|
14
|
-
nodeEnv:
|
|
15
|
-
version:
|
|
5
|
+
publicPath: import.meta.env.VUE_APP_PUBLIC_PATH,
|
|
6
|
+
appEnv: import.meta.env.VUE_APP_ENV,
|
|
7
|
+
apiUrl: import.meta.env.VUE_APP_API_URL,
|
|
8
|
+
accessToken: import.meta.env.VUE_APP_ACCESS_TOKEN,
|
|
9
|
+
websiteUrl: import.meta.env.VUE_APP_WEBSITE_URL,
|
|
10
|
+
websiteButtonUrl: import.meta.env.VUE_APP_WEBSITE_BUTTON_URL,
|
|
11
|
+
sentryDsn: import.meta.env.VUE_APP_SENTRY_DSN,
|
|
12
|
+
sentryEnv: import.meta.env.VUE_APP_SENTRY_ENVIRONMENT,
|
|
13
|
+
baseUrl: import.meta.env.BASE_URL,
|
|
14
|
+
nodeEnv: import.meta.env.MODE,
|
|
15
|
+
version: import.meta.env.VUE_APP_VERSION,
|
|
16
16
|
});
|
|
17
17
|
}
|
package/src/services/requests.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { request, ResponseBody } from '@tager/admin-services';
|
|
1
|
+
import { request, type ResponseBody } from '@tager/admin-services';
|
|
2
2
|
|
|
3
3
|
import {
|
|
4
|
-
ModuleInfoType,
|
|
5
|
-
ImportCreatePayload,
|
|
6
|
-
ImportType,
|
|
4
|
+
type ModuleInfoType,
|
|
5
|
+
type ImportCreatePayload,
|
|
6
|
+
type ImportType,
|
|
7
7
|
} from '../typings/model';
|
|
8
8
|
|
|
9
9
|
export function getImportList(params?: {
|
package/src/typings/model.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { FileType } from '@tager/admin-services';
|
|
1
|
+
import { type FileType } from '@tager/admin-services';
|
|
2
2
|
import {
|
|
3
|
-
FieldConfigUnion,
|
|
4
|
-
FieldShortType,
|
|
5
|
-
OutgoingValueUnion,
|
|
3
|
+
type FieldConfigUnion,
|
|
4
|
+
type FieldShortType,
|
|
5
|
+
type OutgoingValueUnion,
|
|
6
6
|
} from '@tager/admin-dynamic-field';
|
|
7
7
|
|
|
8
8
|
export interface HistoryType {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { OptionType, SingleFileInputValueType } from '@tager/admin-ui';
|
|
2
|
-
import { FieldUnion, universalFieldUtils } from '@tager/admin-dynamic-field';
|
|
1
|
+
import { type OptionType, type SingleFileInputValueType } from '@tager/admin-ui';
|
|
2
|
+
import { type FieldUnion, universalFieldUtils } from '@tager/admin-dynamic-field';
|
|
3
3
|
|
|
4
|
-
import { ImportCreatePayload, StrategyType } from '../../typings/model';
|
|
4
|
+
import { type ImportCreatePayload, type StrategyType } from '../../typings/model';
|
|
5
5
|
|
|
6
6
|
export type FormValues = {
|
|
7
7
|
strategy: OptionType | null;
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
<template #footer>
|
|
31
31
|
<FormFooter
|
|
32
32
|
:back-href="getImportListUrl()"
|
|
33
|
-
@submit="submitForm"
|
|
34
33
|
:is-submitting="isSubmitting"
|
|
35
34
|
:is-creation="true"
|
|
35
|
+
@submit="submitForm"
|
|
36
36
|
/>
|
|
37
37
|
</template>
|
|
38
38
|
</Page>
|
|
@@ -40,20 +40,22 @@
|
|
|
40
40
|
|
|
41
41
|
<script lang="ts">
|
|
42
42
|
import {defineComponent, watch, computed, onMounted, ref} from 'vue';
|
|
43
|
+
import {useRouter} from "vue-router";
|
|
43
44
|
|
|
44
45
|
import {convertRequestErrorToMap, navigateBack, useI18n, useResource, useToast} from '@tager/admin-services';
|
|
45
46
|
import {
|
|
46
|
-
OptionType,
|
|
47
|
-
TagerFormSubmitEvent,
|
|
47
|
+
type OptionType,
|
|
48
|
+
type TagerFormSubmitEvent,
|
|
48
49
|
FormFooter,
|
|
49
50
|
FormFieldFileInput, FormFieldSelect
|
|
50
51
|
} from '@tager/admin-ui';
|
|
51
52
|
import {
|
|
52
53
|
DynamicField,
|
|
53
|
-
FieldConfigUnion,
|
|
54
|
-
FieldUnion,
|
|
54
|
+
type FieldConfigUnion,
|
|
55
|
+
type FieldUnion,
|
|
55
56
|
universalFieldUtils,
|
|
56
57
|
} from '@tager/admin-dynamic-field';
|
|
58
|
+
import {Page} from "@tager/admin-layout";
|
|
57
59
|
|
|
58
60
|
import {createImport, getModuleInfo} from '../../services/requests';
|
|
59
61
|
import {getImportListUrl} from '../../utils/paths';
|
|
@@ -61,10 +63,8 @@ import {getImportListUrl} from '../../utils/paths';
|
|
|
61
63
|
import {
|
|
62
64
|
convertImportFormValuesToCreationPayload,
|
|
63
65
|
convertStrategiesToStrategyOptionList,
|
|
64
|
-
FormValues,
|
|
66
|
+
type FormValues,
|
|
65
67
|
} from './ImportForm.helpers';
|
|
66
|
-
import {useRouter} from "vue-router";
|
|
67
|
-
import {Page} from "@tager/admin-layout";
|
|
68
68
|
|
|
69
69
|
export default defineComponent({
|
|
70
70
|
name: 'ImportForm',
|
|
@@ -33,18 +33,17 @@
|
|
|
33
33
|
import {defineComponent, onMounted} from 'vue';
|
|
34
34
|
|
|
35
35
|
import {
|
|
36
|
-
ColumnDefinition,
|
|
36
|
+
type ColumnDefinition,
|
|
37
37
|
useDataTable,
|
|
38
38
|
DataTable
|
|
39
39
|
} from '@tager/admin-ui';
|
|
40
|
-
|
|
41
40
|
import {
|
|
42
41
|
Page
|
|
43
42
|
} from '@tager/admin-layout';
|
|
44
43
|
import {useI18n} from "@tager/admin-services";
|
|
45
44
|
|
|
46
45
|
import {getImportList} from '../../services/requests';
|
|
47
|
-
import {ImportType} from '../../typings/model';
|
|
46
|
+
import {type ImportType} from '../../typings/model';
|
|
48
47
|
import {getImportFormUrl} from '../../utils/paths';
|
|
49
48
|
|
|
50
49
|
import {CellHistory} from './components/CellHistory';
|
|
@@ -10,9 +10,11 @@
|
|
|
10
10
|
</template>
|
|
11
11
|
|
|
12
12
|
<script lang="ts">
|
|
13
|
-
import {defineComponent, PropType} from "vue";
|
|
13
|
+
import {defineComponent, type PropType} from "vue";
|
|
14
|
+
|
|
15
|
+
import {type HistoryType} from "../../../../typings/model";
|
|
16
|
+
|
|
14
17
|
import {dateTimeFormat} from './CellHistory.helpers';
|
|
15
|
-
import {HistoryType} from "../../../../typings/model";
|
|
16
18
|
|
|
17
19
|
export default defineComponent({
|
|
18
20
|
name: 'CellHistory',
|