@tager/admin-administrators 0.2.7 → 1.0.0
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/constants/paths.d.ts +6 -6
- package/dist/constants/routes.d.ts +5 -5
- package/dist/dev/App.vue.d.ts +5 -0
- package/dist/dev/config.d.ts +2 -0
- package/dist/dev/env.d.ts +1 -0
- package/dist/dev/main.d.ts +3 -0
- package/dist/index.mjs +875 -0
- package/dist/locales/apply.d.ts +1 -0
- package/dist/locales/en.d.ts +40 -41
- package/dist/locales/ru.d.ts +2 -3
- package/dist/main.d.ts +3 -3
- package/dist/services/requests.d.ts +32 -32
- package/dist/style.css +1 -0
- package/dist/typings/model.d.ts +25 -25
- package/dist/utils/paths.d.ts +8 -8
- package/dist/views/AdminForm/AdminForm.helpers.d.ts +14 -14
- package/dist/views/AdminForm/AdminForm.vue.d.ts +26 -61
- package/dist/views/AdminForm/index.d.ts +1 -1
- package/dist/views/AdminList/AdminList.vue.d.ts +14 -33
- package/dist/views/AdminList/index.d.ts +1 -1
- package/dist/views/RoleForm/RoleForm.helpers.d.ts +13 -13
- package/dist/views/RoleForm/RoleForm.vue.d.ts +24 -59
- package/dist/views/RoleForm/index.d.ts +1 -1
- package/dist/views/RoleList/RoleList.vue.d.ts +20 -46
- package/dist/views/RoleList/index.d.ts +1 -1
- package/package.json +51 -50
- package/src/constants/routes.ts +19 -19
- package/src/dev/App.vue +57 -0
- package/src/dev/config.ts +23 -0
- package/src/dev/env.ts +17 -0
- package/src/dev/main.ts +46 -0
- package/src/locales/apply.ts +9 -0
- package/src/locales/en.ts +1 -3
- package/src/locales/ru.ts +40 -42
- package/src/main.ts +5 -9
- package/src/views/AdminForm/AdminForm.vue +99 -96
- package/src/views/AdminList/AdminList.vue +54 -49
- package/src/views/RoleForm/RoleForm.vue +82 -79
- package/src/views/RoleList/RoleList.vue +78 -64
- package/CHANGELOG.md +0 -0
- package/dist/dev.d.ts +0 -1
- package/dist/index.esm.js +0 -1350
- package/dist/index.umd.js +0 -1373
- package/src/config/config.json +0 -20
- package/src/dev.ts +0 -51
- package/src/typings/sfc.d.ts +0 -12
- package/src/typings/shims-tsx.d.ts +0 -13
- package/src/typings/shims-vue.d.ts +0 -11
- package/src/views/App.vue +0 -52
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function applyTranslations(): void;
|
package/dist/locales/en.d.ts
CHANGED
|
@@ -1,41 +1,40 @@
|
|
|
1
|
-
declare const EN: {
|
|
2
|
-
home: string;
|
|
3
|
-
administrators: string;
|
|
4
|
-
role: string;
|
|
5
|
-
roles: string;
|
|
6
|
-
admin: string;
|
|
7
|
-
admins: string;
|
|
8
|
-
createRole: string;
|
|
9
|
-
createAdmin: string;
|
|
10
|
-
createAdministrator: string;
|
|
11
|
-
edit: string;
|
|
12
|
-
delete: string;
|
|
13
|
-
email: string;
|
|
14
|
-
actions: string;
|
|
15
|
-
updateRole: string;
|
|
16
|
-
updateAdmin: string;
|
|
17
|
-
password: string;
|
|
18
|
-
newPassword: string;
|
|
19
|
-
name: string;
|
|
20
|
-
success: string;
|
|
21
|
-
adminSuccessfullyCreated: string;
|
|
22
|
-
adminSuccessfullyUpdated: string;
|
|
23
|
-
error: string;
|
|
24
|
-
adminCreationError: string;
|
|
25
|
-
adminUpdateError: string;
|
|
26
|
-
listOfRoles: string;
|
|
27
|
-
addRole: string;
|
|
28
|
-
noPrivileges: string;
|
|
29
|
-
privileges: string;
|
|
30
|
-
all: string;
|
|
31
|
-
roleSuccessfullyCreated: string;
|
|
32
|
-
roleSuccessfullyUpdate: string;
|
|
33
|
-
roleCreationError: string;
|
|
34
|
-
roleUpdateError: string;
|
|
35
|
-
adminList: string;
|
|
36
|
-
adminForm: string;
|
|
37
|
-
roleList: string;
|
|
38
|
-
roleForm: string;
|
|
39
|
-
andMorePrivilege: string;
|
|
40
|
-
};
|
|
41
|
-
export default EN;
|
|
1
|
+
export declare const EN: {
|
|
2
|
+
home: string;
|
|
3
|
+
administrators: string;
|
|
4
|
+
role: string;
|
|
5
|
+
roles: string;
|
|
6
|
+
admin: string;
|
|
7
|
+
admins: string;
|
|
8
|
+
createRole: string;
|
|
9
|
+
createAdmin: string;
|
|
10
|
+
createAdministrator: string;
|
|
11
|
+
edit: string;
|
|
12
|
+
delete: string;
|
|
13
|
+
email: string;
|
|
14
|
+
actions: string;
|
|
15
|
+
updateRole: string;
|
|
16
|
+
updateAdmin: string;
|
|
17
|
+
password: string;
|
|
18
|
+
newPassword: string;
|
|
19
|
+
name: string;
|
|
20
|
+
success: string;
|
|
21
|
+
adminSuccessfullyCreated: string;
|
|
22
|
+
adminSuccessfullyUpdated: string;
|
|
23
|
+
error: string;
|
|
24
|
+
adminCreationError: string;
|
|
25
|
+
adminUpdateError: string;
|
|
26
|
+
listOfRoles: string;
|
|
27
|
+
addRole: string;
|
|
28
|
+
noPrivileges: string;
|
|
29
|
+
privileges: string;
|
|
30
|
+
all: string;
|
|
31
|
+
roleSuccessfullyCreated: string;
|
|
32
|
+
roleSuccessfullyUpdate: string;
|
|
33
|
+
roleCreationError: string;
|
|
34
|
+
roleUpdateError: string;
|
|
35
|
+
adminList: string;
|
|
36
|
+
adminForm: string;
|
|
37
|
+
roleList: string;
|
|
38
|
+
roleForm: string;
|
|
39
|
+
andMorePrivilege: string;
|
|
40
|
+
};
|
package/dist/locales/ru.d.ts
CHANGED
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
import EN from './en';
|
|
2
|
-
declare const RU: typeof EN;
|
|
3
|
-
export default RU;
|
|
1
|
+
import { EN } from './en';
|
|
2
|
+
export declare const RU: typeof EN;
|
package/dist/main.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from
|
|
2
|
-
export * from
|
|
3
|
-
export * from
|
|
1
|
+
export * from "./constants/routes";
|
|
2
|
+
export * from "./utils/paths";
|
|
3
|
+
export * from "./services/requests";
|
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
import { ResponseBody } from '@tager/admin-services';
|
|
2
|
-
import { AdminType, RoleType, ScopeGroupsData } from '../typings/model';
|
|
3
|
-
declare type SuccessData = {
|
|
4
|
-
success: boolean;
|
|
5
|
-
};
|
|
6
|
-
/** Roles */
|
|
7
|
-
export declare function getRoleList(): Promise<ResponseBody<Array<RoleType>>>;
|
|
8
|
-
export declare function getRole(roleId: string | number): Promise<ResponseBody<RoleType>>;
|
|
9
|
-
export declare type RoleCreationPayload = {
|
|
10
|
-
name: string;
|
|
11
|
-
scopes: Array<string>;
|
|
12
|
-
};
|
|
13
|
-
export declare function createRole(payload: RoleCreationPayload): Promise<ResponseBody<RoleType>>;
|
|
14
|
-
export declare type RoleUpdatePayload = RoleCreationPayload;
|
|
15
|
-
export declare function updateRole(roleId: string | number, payload: RoleUpdatePayload): Promise<ResponseBody<RoleType>>;
|
|
16
|
-
export declare function deleteRole(roleId: string | number): Promise<SuccessData>;
|
|
17
|
-
/** Scopes */
|
|
18
|
-
export declare function getScopes(): Promise<ResponseBody<ScopeGroupsData>>;
|
|
19
|
-
/** Admin */
|
|
20
|
-
export declare function getAdminList(): Promise<ResponseBody<Array<AdminType>>>;
|
|
21
|
-
export declare function getAdmin(adminId: string | number): Promise<ResponseBody<AdminType>>;
|
|
22
|
-
export declare type AdminUpdatePayload = {
|
|
23
|
-
name: string;
|
|
24
|
-
email: string;
|
|
25
|
-
roles: Array<number>;
|
|
26
|
-
password: string;
|
|
27
|
-
};
|
|
28
|
-
export declare type AdminCreationPayload = AdminUpdatePayload;
|
|
29
|
-
export declare function createAdmin(payload: AdminCreationPayload): Promise<ResponseBody<AdminType>>;
|
|
30
|
-
export declare function updateAdmin(adminId: string | number, payload: AdminUpdatePayload): Promise<ResponseBody<AdminType>>;
|
|
31
|
-
export declare function deleteAdmin(adminId: string | number): Promise<SuccessData>;
|
|
32
|
-
export {};
|
|
1
|
+
import { ResponseBody } from '@tager/admin-services';
|
|
2
|
+
import { AdminType, RoleType, ScopeGroupsData } from '../typings/model';
|
|
3
|
+
declare type SuccessData = {
|
|
4
|
+
success: boolean;
|
|
5
|
+
};
|
|
6
|
+
/** Roles */
|
|
7
|
+
export declare function getRoleList(): Promise<ResponseBody<Array<RoleType>>>;
|
|
8
|
+
export declare function getRole(roleId: string | number): Promise<ResponseBody<RoleType>>;
|
|
9
|
+
export declare type RoleCreationPayload = {
|
|
10
|
+
name: string;
|
|
11
|
+
scopes: Array<string>;
|
|
12
|
+
};
|
|
13
|
+
export declare function createRole(payload: RoleCreationPayload): Promise<ResponseBody<RoleType>>;
|
|
14
|
+
export declare type RoleUpdatePayload = RoleCreationPayload;
|
|
15
|
+
export declare function updateRole(roleId: string | number, payload: RoleUpdatePayload): Promise<ResponseBody<RoleType>>;
|
|
16
|
+
export declare function deleteRole(roleId: string | number): Promise<SuccessData>;
|
|
17
|
+
/** Scopes */
|
|
18
|
+
export declare function getScopes(): Promise<ResponseBody<ScopeGroupsData>>;
|
|
19
|
+
/** Admin */
|
|
20
|
+
export declare function getAdminList(): Promise<ResponseBody<Array<AdminType>>>;
|
|
21
|
+
export declare function getAdmin(adminId: string | number): Promise<ResponseBody<AdminType>>;
|
|
22
|
+
export declare type AdminUpdatePayload = {
|
|
23
|
+
name: string;
|
|
24
|
+
email: string;
|
|
25
|
+
roles: Array<number>;
|
|
26
|
+
password: string;
|
|
27
|
+
};
|
|
28
|
+
export declare type AdminCreationPayload = AdminUpdatePayload;
|
|
29
|
+
export declare function createAdmin(payload: AdminCreationPayload): Promise<ResponseBody<AdminType>>;
|
|
30
|
+
export declare function updateAdmin(adminId: string | number, payload: AdminUpdatePayload): Promise<ResponseBody<AdminType>>;
|
|
31
|
+
export declare function deleteAdmin(adminId: string | number): Promise<SuccessData>;
|
|
32
|
+
export {};
|
package/dist/style.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.no-scopes{font-style:italic}.scope-group{margin-bottom:.5rem}.module-name{display:block;font-weight:700;margin-bottom:.3rem}.scope-list{padding-left:1rem}.rest-scopes-text{padding-left:35px}[data-v-501ddc14] [data-multi-select-list]{max-height:500px}
|
package/dist/typings/model.d.ts
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
export declare type ScopeType = {
|
|
2
|
-
readonly value: string;
|
|
3
|
-
readonly label: string;
|
|
4
|
-
readonly module: string;
|
|
5
|
-
};
|
|
6
|
-
export declare type RoleType = {
|
|
7
|
-
readonly id: number;
|
|
8
|
-
readonly name: string;
|
|
9
|
-
readonly isSuperAdmin: boolean;
|
|
10
|
-
readonly scopes: Array<ScopeType>;
|
|
11
|
-
};
|
|
12
|
-
export declare type ScopeGroupsData = {
|
|
13
|
-
readonly groups: Array<{
|
|
14
|
-
readonly name: string;
|
|
15
|
-
readonly scopes: Array<ScopeType>;
|
|
16
|
-
}>;
|
|
17
|
-
};
|
|
18
|
-
export declare type AdminType = {
|
|
19
|
-
readonly id: number;
|
|
20
|
-
readonly name: string;
|
|
21
|
-
readonly email: string;
|
|
22
|
-
readonly roles: Array<RoleType>;
|
|
23
|
-
readonly isSelf: boolean;
|
|
24
|
-
readonly isSuperAdmin: boolean;
|
|
25
|
-
};
|
|
1
|
+
export declare type ScopeType = {
|
|
2
|
+
readonly value: string;
|
|
3
|
+
readonly label: string;
|
|
4
|
+
readonly module: string;
|
|
5
|
+
};
|
|
6
|
+
export declare type RoleType = {
|
|
7
|
+
readonly id: number;
|
|
8
|
+
readonly name: string;
|
|
9
|
+
readonly isSuperAdmin: boolean;
|
|
10
|
+
readonly scopes: Array<ScopeType>;
|
|
11
|
+
};
|
|
12
|
+
export declare type ScopeGroupsData = {
|
|
13
|
+
readonly groups: Array<{
|
|
14
|
+
readonly name: string;
|
|
15
|
+
readonly scopes: Array<ScopeType>;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
export declare type AdminType = {
|
|
19
|
+
readonly id: number;
|
|
20
|
+
readonly name: string;
|
|
21
|
+
readonly email: string;
|
|
22
|
+
readonly roles: Array<RoleType>;
|
|
23
|
+
readonly isSelf: boolean;
|
|
24
|
+
readonly isSuperAdmin: boolean;
|
|
25
|
+
};
|
package/dist/utils/paths.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export declare function getRoleListUrl(): "/roles";
|
|
2
|
-
export declare function getRoleFormUrl(params: {
|
|
3
|
-
roleId: string | number;
|
|
4
|
-
}): string;
|
|
5
|
-
export declare function getAdminListUrl(): "/admins";
|
|
6
|
-
export declare function getAdminFormUrl(params: {
|
|
7
|
-
adminId: string | number;
|
|
8
|
-
}): string;
|
|
1
|
+
export declare function getRoleListUrl(): "/roles";
|
|
2
|
+
export declare function getRoleFormUrl(params: {
|
|
3
|
+
roleId: string | number;
|
|
4
|
+
}): string;
|
|
5
|
+
export declare function getAdminListUrl(): "/admins";
|
|
6
|
+
export declare function getAdminFormUrl(params: {
|
|
7
|
+
adminId: string | number;
|
|
8
|
+
}): string;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { Nullable } from '@tager/admin-services';
|
|
2
|
-
import { OptionType } from '@tager/admin-ui';
|
|
3
|
-
import { AdminType, RoleType } from '../../typings/model';
|
|
4
|
-
import { AdminCreationPayload, AdminUpdatePayload } from '../../services/requests';
|
|
5
|
-
export declare type FormValues = {
|
|
6
|
-
name: string;
|
|
7
|
-
email: string;
|
|
8
|
-
password: string;
|
|
9
|
-
roles: Array<OptionType<number>>;
|
|
10
|
-
};
|
|
11
|
-
export declare function convertAdminToFormValues(admin: Nullable<AdminType>, roleOptionList: Array<OptionType<number>>): FormValues;
|
|
12
|
-
export declare function convertFormValuesToAdminUpdatePayload(values: FormValues): AdminUpdatePayload;
|
|
13
|
-
export declare function convertFormValuesToAdminCreationPayload(values: FormValues): AdminCreationPayload;
|
|
14
|
-
export declare function convertRoleListToOptions(roleList: Array<RoleType>): Array<OptionType<number>>;
|
|
1
|
+
import { Nullable } from '@tager/admin-services';
|
|
2
|
+
import { OptionType } from '@tager/admin-ui';
|
|
3
|
+
import { AdminType, RoleType } from '../../typings/model';
|
|
4
|
+
import { AdminCreationPayload, AdminUpdatePayload } from '../../services/requests';
|
|
5
|
+
export declare type FormValues = {
|
|
6
|
+
name: string;
|
|
7
|
+
email: string;
|
|
8
|
+
password: string;
|
|
9
|
+
roles: Array<OptionType<number>>;
|
|
10
|
+
};
|
|
11
|
+
export declare function convertAdminToFormValues(admin: Nullable<AdminType>, roleOptionList: Array<OptionType<number>>): FormValues;
|
|
12
|
+
export declare function convertFormValuesToAdminUpdatePayload(values: FormValues): AdminUpdatePayload;
|
|
13
|
+
export declare function convertFormValuesToAdminCreationPayload(values: FormValues): AdminCreationPayload;
|
|
14
|
+
export declare function convertRoleListToOptions(roleList: Array<RoleType>): Array<OptionType<number>>;
|
|
@@ -1,61 +1,26 @@
|
|
|
1
|
-
import { Nullable } from '@tager/admin-services';
|
|
2
|
-
import { OptionType, TagerFormSubmitEvent } from '@tager/admin-ui';
|
|
3
|
-
import { AdminType } from '../../typings/model';
|
|
4
|
-
declare const _default: import("vue").
|
|
5
|
-
t: import("i18next").TFunction;
|
|
6
|
-
backButtonUrl: "/admins";
|
|
7
|
-
values: import("
|
|
8
|
-
name: string;
|
|
9
|
-
email: string;
|
|
10
|
-
password: string;
|
|
11
|
-
roles: {
|
|
12
|
-
value: number;
|
|
13
|
-
label: string;
|
|
14
|
-
disabled?: boolean | undefined;
|
|
15
|
-
}[];
|
|
16
|
-
}>;
|
|
17
|
-
errors: import("
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
}> & {
|
|
28
|
-
[key: string]: unknown;
|
|
29
|
-
}, {}, {}, unknown, {
|
|
30
|
-
[x: string]: any;
|
|
31
|
-
}> & import("vue").VueConstructor<import("vue").default> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
32
|
-
[x: string]: any;
|
|
33
|
-
}, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
34
|
-
t: import("i18next").TFunction;
|
|
35
|
-
backButtonUrl: "/admins";
|
|
36
|
-
values: import("@vue/composition-api").Ref<{
|
|
37
|
-
name: string;
|
|
38
|
-
email: string;
|
|
39
|
-
password: string;
|
|
40
|
-
roles: {
|
|
41
|
-
value: number;
|
|
42
|
-
label: string;
|
|
43
|
-
disabled?: boolean | undefined;
|
|
44
|
-
}[];
|
|
45
|
-
}>;
|
|
46
|
-
errors: import("@vue/composition-api").Ref<{
|
|
47
|
-
[x: string]: string;
|
|
48
|
-
}>;
|
|
49
|
-
isSubmitting: import("@vue/composition-api").Ref<boolean>;
|
|
50
|
-
submitForm: (event: TagerFormSubmitEvent) => void;
|
|
51
|
-
isContentLoading: import("@vue/composition-api").ComputedRef<boolean>;
|
|
52
|
-
admin: import("@vue/composition-api").Ref<Nullable<AdminType>>;
|
|
53
|
-
pageTitle: import("@vue/composition-api").ComputedRef<string>;
|
|
54
|
-
isCreation: import("@vue/composition-api").ComputedRef<boolean>;
|
|
55
|
-
roleOptionList: import("@vue/composition-api").ComputedRef<OptionType<number>[]>;
|
|
56
|
-
}>, {
|
|
57
|
-
[x: string]: any;
|
|
58
|
-
}, {}, {}, {
|
|
59
|
-
[x: string]: any;
|
|
60
|
-
}, {}, true>);
|
|
61
|
-
export default _default;
|
|
1
|
+
import { Nullable } from '@tager/admin-services';
|
|
2
|
+
import { OptionType, TagerFormSubmitEvent } from '@tager/admin-ui';
|
|
3
|
+
import { AdminType } from '../../typings/model';
|
|
4
|
+
declare const _default: import("vue").DefineComponent<{}, {
|
|
5
|
+
t: import("i18next").TFunction;
|
|
6
|
+
backButtonUrl: "/admins";
|
|
7
|
+
values: import("vue").Ref<{
|
|
8
|
+
name: string;
|
|
9
|
+
email: string;
|
|
10
|
+
password: string;
|
|
11
|
+
roles: {
|
|
12
|
+
value: number;
|
|
13
|
+
label: string;
|
|
14
|
+
disabled?: boolean | undefined;
|
|
15
|
+
}[];
|
|
16
|
+
}>;
|
|
17
|
+
errors: import("vue").Ref<Record<string, string>>;
|
|
18
|
+
isSubmitting: import("vue").Ref<boolean>;
|
|
19
|
+
submitForm: (event: TagerFormSubmitEvent) => void;
|
|
20
|
+
isContentLoading: import("vue").ComputedRef<boolean>;
|
|
21
|
+
admin: import("vue").Ref<Nullable<AdminType>>;
|
|
22
|
+
pageTitle: import("vue").ComputedRef<string>;
|
|
23
|
+
isCreation: import("vue").ComputedRef<boolean>;
|
|
24
|
+
roleOptionList: import("vue").ComputedRef<OptionType<number>[]>;
|
|
25
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
26
|
+
export default _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './AdminForm.vue';
|
|
1
|
+
export { default } from './AdminForm.vue';
|
|
@@ -1,33 +1,14 @@
|
|
|
1
|
-
import { ColumnDefinition } from '@tager/admin-ui';
|
|
2
|
-
import { AdminType } from '../../typings/model';
|
|
3
|
-
import { getAdminFormUrl } from '../../utils/paths';
|
|
4
|
-
declare const _default: import("vue").
|
|
5
|
-
t: import("i18next").TFunction;
|
|
6
|
-
columnDefs: ColumnDefinition<AdminType>[];
|
|
7
|
-
rowData: import("
|
|
8
|
-
isRowDataLoading: import("
|
|
9
|
-
errorMessage: import("
|
|
10
|
-
isBusy: (adminId: number) => boolean;
|
|
11
|
-
handleAdminDelete: (entityId: string | number) => void;
|
|
12
|
-
getAdminFormUrl: typeof getAdminFormUrl;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
}, {}, {}, unknown, {
|
|
16
|
-
[x: string]: any;
|
|
17
|
-
}> & import("vue").VueConstructor<import("vue").default> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
18
|
-
[x: string]: any;
|
|
19
|
-
}, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
20
|
-
t: import("i18next").TFunction;
|
|
21
|
-
columnDefs: ColumnDefinition<AdminType>[];
|
|
22
|
-
rowData: import("@vue/composition-api").Ref<AdminType[]>;
|
|
23
|
-
isRowDataLoading: import("@vue/composition-api").ComputedRef<boolean>;
|
|
24
|
-
errorMessage: import("@vue/composition-api").Ref<import("@tager/admin-services").Nullable<string>>;
|
|
25
|
-
isBusy: (adminId: number) => boolean;
|
|
26
|
-
handleAdminDelete: (entityId: string | number) => void;
|
|
27
|
-
getAdminFormUrl: typeof getAdminFormUrl;
|
|
28
|
-
}>, {
|
|
29
|
-
[x: string]: any;
|
|
30
|
-
}, {}, {}, {
|
|
31
|
-
[x: string]: any;
|
|
32
|
-
}, {}, true>);
|
|
33
|
-
export default _default;
|
|
1
|
+
import { ColumnDefinition } from '@tager/admin-ui';
|
|
2
|
+
import { AdminType } from '../../typings/model';
|
|
3
|
+
import { getAdminFormUrl } from '../../utils/paths';
|
|
4
|
+
declare const _default: import("vue").DefineComponent<{}, {
|
|
5
|
+
t: import("i18next").TFunction;
|
|
6
|
+
columnDefs: ColumnDefinition<AdminType>[];
|
|
7
|
+
rowData: import("vue").Ref<AdminType[]>;
|
|
8
|
+
isRowDataLoading: import("vue").ComputedRef<boolean>;
|
|
9
|
+
errorMessage: import("vue").Ref<import("@tager/admin-services").Nullable<string>>;
|
|
10
|
+
isBusy: (adminId: number) => boolean;
|
|
11
|
+
handleAdminDelete: (entityId: string | number) => void;
|
|
12
|
+
getAdminFormUrl: typeof getAdminFormUrl;
|
|
13
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
14
|
+
export default _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './AdminList.vue';
|
|
1
|
+
export { default } from './AdminList.vue';
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { Nullable } from '@tager/admin-services';
|
|
2
|
-
import { OptionType } from '@tager/admin-ui';
|
|
3
|
-
import { RoleType, ScopeGroupsData } from '../../typings/model';
|
|
4
|
-
import { RoleCreationPayload, RoleUpdatePayload } from '../../services/requests';
|
|
5
|
-
export declare type FormValues = {
|
|
6
|
-
name: string;
|
|
7
|
-
scopes: Array<OptionType>;
|
|
8
|
-
isSuperAdmin: boolean;
|
|
9
|
-
};
|
|
10
|
-
export declare function convertRoleToFormValues(role: Nullable<RoleType>): FormValues;
|
|
11
|
-
export declare function convertFormValuesToRoleCreationPayload(values: FormValues): RoleCreationPayload;
|
|
12
|
-
export declare function convertFormValuesToRoleUpdatePayload(values: FormValues): RoleUpdatePayload;
|
|
13
|
-
export declare function convertScopeDataToOptions(scopeData: Nullable<ScopeGroupsData>): Array<OptionType>;
|
|
1
|
+
import { Nullable } from '@tager/admin-services';
|
|
2
|
+
import { OptionType } from '@tager/admin-ui';
|
|
3
|
+
import { RoleType, ScopeGroupsData } from '../../typings/model';
|
|
4
|
+
import { RoleCreationPayload, RoleUpdatePayload } from '../../services/requests';
|
|
5
|
+
export declare type FormValues = {
|
|
6
|
+
name: string;
|
|
7
|
+
scopes: Array<OptionType>;
|
|
8
|
+
isSuperAdmin: boolean;
|
|
9
|
+
};
|
|
10
|
+
export declare function convertRoleToFormValues(role: Nullable<RoleType>): FormValues;
|
|
11
|
+
export declare function convertFormValuesToRoleCreationPayload(values: FormValues): RoleCreationPayload;
|
|
12
|
+
export declare function convertFormValuesToRoleUpdatePayload(values: FormValues): RoleUpdatePayload;
|
|
13
|
+
export declare function convertScopeDataToOptions(scopeData: Nullable<ScopeGroupsData>): Array<OptionType>;
|
|
@@ -1,59 +1,24 @@
|
|
|
1
|
-
import { Nullable } from '@tager/admin-services';
|
|
2
|
-
import { OptionType, TagerFormSubmitEvent } from '@tager/admin-ui';
|
|
3
|
-
import { RoleType } from '../../typings/model';
|
|
4
|
-
declare const _default: import("vue").
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
scopeOptionList: import("@vue/composition-api").ComputedRef<OptionType<string>[]>;
|
|
26
|
-
}> & {
|
|
27
|
-
[key: string]: unknown;
|
|
28
|
-
}, {}, {}, unknown, {
|
|
29
|
-
[x: string]: any;
|
|
30
|
-
}> & import("vue").VueConstructor<import("vue").default> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
31
|
-
[x: string]: any;
|
|
32
|
-
}, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
33
|
-
t: import("i18next").TFunction;
|
|
34
|
-
backButtonUrl: "/roles";
|
|
35
|
-
values: import("@vue/composition-api").Ref<{
|
|
36
|
-
name: string;
|
|
37
|
-
scopes: {
|
|
38
|
-
value: string;
|
|
39
|
-
label: string;
|
|
40
|
-
disabled?: boolean | undefined;
|
|
41
|
-
}[];
|
|
42
|
-
isSuperAdmin: boolean;
|
|
43
|
-
}>;
|
|
44
|
-
errors: import("@vue/composition-api").Ref<{
|
|
45
|
-
[x: string]: string;
|
|
46
|
-
}>;
|
|
47
|
-
isSubmitting: import("@vue/composition-api").Ref<boolean>;
|
|
48
|
-
submitForm: (event: TagerFormSubmitEvent) => void;
|
|
49
|
-
isContentLoading: import("@vue/composition-api").ComputedRef<boolean>;
|
|
50
|
-
role: import("@vue/composition-api").Ref<Nullable<RoleType>>;
|
|
51
|
-
pageTitle: import("@vue/composition-api").ComputedRef<string>;
|
|
52
|
-
isCreation: import("@vue/composition-api").ComputedRef<boolean>;
|
|
53
|
-
scopeOptionList: import("@vue/composition-api").ComputedRef<OptionType<string>[]>;
|
|
54
|
-
}>, {
|
|
55
|
-
[x: string]: any;
|
|
56
|
-
}, {}, {}, {
|
|
57
|
-
[x: string]: any;
|
|
58
|
-
}, {}, true>);
|
|
59
|
-
export default _default;
|
|
1
|
+
import { Nullable } from '@tager/admin-services';
|
|
2
|
+
import { OptionType, TagerFormSubmitEvent } from '@tager/admin-ui';
|
|
3
|
+
import { RoleType } from '../../typings/model';
|
|
4
|
+
declare const _default: import("vue").DefineComponent<{}, {
|
|
5
|
+
backButtonUrl: "/roles";
|
|
6
|
+
values: import("vue").Ref<{
|
|
7
|
+
name: string;
|
|
8
|
+
scopes: {
|
|
9
|
+
value: string;
|
|
10
|
+
label: string;
|
|
11
|
+
disabled?: boolean | undefined;
|
|
12
|
+
}[];
|
|
13
|
+
isSuperAdmin: boolean;
|
|
14
|
+
}>;
|
|
15
|
+
errors: import("vue").Ref<Record<string, string>>;
|
|
16
|
+
isSubmitting: import("vue").Ref<boolean>;
|
|
17
|
+
submitForm: (event: TagerFormSubmitEvent) => void;
|
|
18
|
+
isContentLoading: import("vue").ComputedRef<boolean>;
|
|
19
|
+
role: import("vue").Ref<Nullable<RoleType>>;
|
|
20
|
+
pageTitle: import("vue").ComputedRef<string>;
|
|
21
|
+
isCreation: import("vue").ComputedRef<boolean>;
|
|
22
|
+
scopeOptionList: import("vue").ComputedRef<OptionType<string>[]>;
|
|
23
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
24
|
+
export default _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './RoleForm.vue';
|
|
1
|
+
export { default } from './RoleForm.vue';
|
|
@@ -1,46 +1,20 @@
|
|
|
1
|
-
/// <reference types="webpack-env" />
|
|
2
|
-
import { ColumnDefinition } from
|
|
3
|
-
import { RoleType, ScopeType } from '../../typings/model';
|
|
4
|
-
import { getRoleFormUrl } from '../../utils/paths';
|
|
5
|
-
declare const _default: import("vue").
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
[key: string]: unknown;
|
|
22
|
-
}, {}, {}, unknown, {
|
|
23
|
-
[x: string]: any;
|
|
24
|
-
}> & import("vue").VueConstructor<import("vue").default> & (new (...args: any[]) => import("@vue/composition-api").ComponentRenderProxy<{
|
|
25
|
-
[x: string]: any;
|
|
26
|
-
}, import("@vue/composition-api").ShallowUnwrapRef<{
|
|
27
|
-
t: import("i18next").TFunction;
|
|
28
|
-
columnDefs: ColumnDefinition<RoleType>[];
|
|
29
|
-
rowData: import("@vue/composition-api").Ref<RoleType[]>;
|
|
30
|
-
isRowDataLoading: import("@vue/composition-api").ComputedRef<boolean>;
|
|
31
|
-
errorMessage: import("@vue/composition-api").Ref<import("@tager/admin-services").Nullable<string>>;
|
|
32
|
-
isBusy: (roleId: number) => boolean;
|
|
33
|
-
handleRoleDelete: (entityId: string | number) => void;
|
|
34
|
-
getRoleFormUrl: typeof getRoleFormUrl;
|
|
35
|
-
getScopeGroupList: (scopes: Array<ScopeType>) => {
|
|
36
|
-
module: string;
|
|
37
|
-
scopes: ScopeType;
|
|
38
|
-
}[];
|
|
39
|
-
getRestScopesText: (restPrivilegesCount: number) => string;
|
|
40
|
-
scopesPerModuleCount: number;
|
|
41
|
-
}>, {
|
|
42
|
-
[x: string]: any;
|
|
43
|
-
}, {}, {}, {
|
|
44
|
-
[x: string]: any;
|
|
45
|
-
}, {}, true>);
|
|
46
|
-
export default _default;
|
|
1
|
+
/// <reference types="webpack-env" />
|
|
2
|
+
import { type ColumnDefinition } from "@tager/admin-ui";
|
|
3
|
+
import { RoleType, ScopeType } from '../../typings/model';
|
|
4
|
+
import { getRoleFormUrl } from '../../utils/paths';
|
|
5
|
+
declare const _default: import("vue").DefineComponent<{}, {
|
|
6
|
+
columnDefs: ColumnDefinition<RoleType>[];
|
|
7
|
+
rowData: import("vue").Ref<RoleType[]>;
|
|
8
|
+
isRowDataLoading: import("vue").ComputedRef<boolean>;
|
|
9
|
+
errorMessage: import("vue").Ref<import("@tager/admin-services").Nullable<string>>;
|
|
10
|
+
isBusy: (roleId: number) => boolean;
|
|
11
|
+
handleRoleDelete: (entityId: string | number) => void;
|
|
12
|
+
getRoleFormUrl: typeof getRoleFormUrl;
|
|
13
|
+
getScopeGroupList: (scopes: Array<ScopeType>) => {
|
|
14
|
+
module: string;
|
|
15
|
+
scopes: ScopeType;
|
|
16
|
+
}[];
|
|
17
|
+
getRestScopesText: (restPrivilegesCount: number) => string;
|
|
18
|
+
scopesPerModuleCount: number;
|
|
19
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
|
20
|
+
export default _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { default } from './RoleList.vue';
|
|
1
|
+
export { default } from './RoleList.vue';
|